diff --git a/.hgtags b/.hgtags index 001205086b5..2276492f1cf 100644 --- a/.hgtags +++ b/.hgtags @@ -1,3 +1,20 @@ +6dd7fda42bab7ecf648cafb0a4e9b4ca11b3094f jdk-9+173 +dad6746278facbbea57dd462cb56fb743dc0a5f0 jdk-9+172 +643b5f18c2656fe91b69fea85b07b98d5fad394d jdk-9+171 +898cbe31fbdae2d25d141384fac746cc244a730c jdk-9+170 +c7efde2b60fc1ec04630be769d9ad60efb39c39c jdk-9+169 +8fd0a4569191f33c98ee90c2709174a342fefb0d jdk-9+167 +fcabc74bd44e56c7419d111d59b95669ecb33c55 jdk-9+168 +d3e973f1809606c67412361041ad197e50fe8cec jdk-9+166 +3965b747cfe1e6cbd66b8739da5a1ea6ec6985e9 jdk-9+165 +d16aebbb56d37f12e0c0b0a4fb427db65e1fb1a8 jdk-9+162 +18c41483a082e097ac2f5f983c1226ed94aa4215 jdk-9+163 +32db52c675e7d5bc413605d2e89b68b608b19be0 jdk-9+164 +fd1497902bbe3aa24b21f270ecdcb8de5f7aa9ac jdk-9+159 +6aa8be0c4e054fe8b3ab016ae00d16d680f92145 jdk-9+160 +f6883b1a5a6478437cd4181c4bd45328ab24feaf jdk-9+161 +fa3e76b477829afc4476f0b725cfaa440a6fd917 jdk-9+157 +b5015f742ba648184bb7fc547197bd33ebfde30d jdk-9+158 1cc8dd79fd1cd13d36b385196271a29632c67c3b jdk7-b24 bf2517e15f0c0f950e5b3143c4ca11e2df73dcc1 jdk7-b25 5ae7db536e3fcf6be78e45b240a9058095e0ed38 jdk7-b26 @@ -399,3 +416,15 @@ d7034ff7f8e257e81c9f95c7785dd4eaaa3c2afc jdk-9+153 8c70d170e62c0c58b5bc3ba666bd140399b98c9c jdk-10+0 45b751afd11e6c05991cf4913c5a0ac3304fcc4e jdk-9+154 f4aff695ffe05cfdb69d8af25a4ddc6a029754ea jdk-9+155 +06bce0388880b5ff8e040e4a9d72a3ea11dac321 jdk-9+156 +74116beae88a8f17a80301aa6c83865c82f10ece jdk-10+1 +4a79ad46e578112fce68f1af9dd931025cc235cb jdk-10+2 +d1cab6c7e608479be4ebfad48a25b0ed48600f62 jdk-10+3 +02253db2ace1422f576f58502fc7831ead77424b jdk-10+4 +f113ce12fe24fbd24acf02711372d9f1e1c12426 jdk-10+5 +1407b19a2ddf6baae162f5a1a5b96af473f4d7d1 jdk-10+6 +30e75693ae99fd8e47fd2f5116527aff1b59aff9 jdk-10+7 +c42dc7b58b4d4301ea676a76326fd9bbd403d595 jdk-10+8 +aa5b01f5e5620438fd39efdb2e2f6365a2c7d898 jdk-10+9 +b0f2b8ff25a2209b2c807785d75f20e5086bbfc2 jdk-10+10 +036dbf8b381798e5d31065109714d04d97bf98a4 jdk-10+11 diff --git a/.hgtags-top-repo b/.hgtags-top-repo index 3d81f131af0..355750fb9b8 100644 --- a/.hgtags-top-repo +++ b/.hgtags-top-repo @@ -396,5 +396,35 @@ b119012d1c2ab2570fe8718633840d0c1f1f441d jdk-9+149 71a766d4c18041a7f833ee22823125b02e1a7f1e jdk-9+151 ef056360ddf3977d7d2ddbeb456a4d612d19ea05 jdk-9+152 816a6d03a7c44edfbd8780110529f1bdc3964fb9 jdk-9+153 +8d22611ffb6540bc1ace64a00c048c8b82d8c69a jdk-10+0 8d26916eaa21b689835ffc1c0dbf12470aa9be61 jdk-9+154 688a3863c00ebc089ab17ee1fc46272cbbd96815 jdk-9+155 +783ec7542cf7154e5d2b87f55bb97d28f81e9ada jdk-9+156 +4df5f619c9ead4604d2f97ed231b3a35ec688c41 jdk-10+1 +4eb77fb98952dc477a4229575c81d2263a9ce711 jdk-9+157 +a4087bc10a88a43ea3ad0919b5b4af1c86977221 jdk-9+158 +fe8466adaef8178dba94be53c789a0aaa87d13bb jdk-9+159 +4d29ee32d926ebc960072d51a3bc558f95c1cbad jdk-9+160 +cda60babd152d889aba4d8f20a8f643ab151d3de jdk-9+161 +21b063d75b3edbffb9bebc8872d990920c4ae1e5 jdk-9+162 +c38c6b270ccc8e2b86d1631bcf42248241b54d2c jdk-9+163 +7810f75d016a52e32295c4233009de5ca90e31af jdk-9+164 +aff4f339acd40942d3dab499846b52acd87b3af1 jdk-9+165 +ba5b16c9c6d80632b61959a33d424b1c3398ce62 jdk-9+166 +35017c286513ddcbcc6b63b99679c604993fc639 jdk-9+167 +143d4c87bc1ef1ed6dadd613cd9dd4488fdefc29 jdk-9+168 +9c7248b787c39b034d4f48d4aa48df903836cca7 jdk-10+2 +06373236a30801f72e2a31ee5c691c2a1e500f57 jdk-10+3 +8ec175c61fc3f58328a3324f07d7ded00e060be3 jdk-10+4 +111e2e7d00f45c983cdbc9c59ae40552152fcc23 jdk-10+5 +03fe61bb7670644cf6e46b5cfafb6b27c0e0157e jdk-10+6 +b25838a28195f4b6dab34668411eedd2d366a16c jdk-9+169 +4d163ec59d989a9261ed7f848bc6303f90869af5 jdk-9+170 +aa3c97810d7c484c93a2fd75d3c76ff574deb6d8 jdk-10+7 +df33ef1dc163f994177fd97d4d0e73a1e3cb5d85 jdk-10+8 +b94be69cbb1d2943b886bf2d458745756df146e4 jdk-10+9 +4c12464a907db4656c1033f56fa49cba643ac629 jdk-9+171 +6558c37afe832582238d338578d598f30c6fdd75 jdk-10+10 +2c25fc24103251f9711a1c280c31e1e41016d90f jdk-9+172 +6b750cdb823a029a25ff2e560302cc2d28a86cb6 jdk-10+11 +88d7fd969e7df0e07a53b201cfd29393ca33ede9 jdk-9+173 diff --git a/.jcheck/conf b/.jcheck/conf index 5c6f62dc12c..b2581358014 100644 --- a/.jcheck/conf +++ b/.jcheck/conf @@ -1 +1 @@ -project=jdk9 +project=jdk10 diff --git a/README b/README index 477b38887fc..537dea30aec 100644 --- a/README +++ b/README @@ -1,40 +1,10 @@ -README: - This file should be located at the top of the OpenJDK Mercurial root - repository. A full OpenJDK repository set (forest) should also include - the following 7 nested repositories: - "jdk", "hotspot", "langtools", "nashorn", "corba", "jaxws" and "jaxp". +Welcome to OpenJDK! +=================== - The root repository can be obtained with something like: - hg clone http://hg.openjdk.java.net/jdk9/jdk9 openjdk9 +For information about building OpenJDK, including how to fully retrieve all +source code, please see either of these: - You can run the get_source.sh script located in the root repository to get - the other needed repositories: - cd openjdk9 && sh ./get_source.sh + * common/doc/building.html (html version) + * common/doc/building.md (markdown version) - People unfamiliar with Mercurial should read the first few chapters of - the Mercurial book: http://hgbook.red-bean.com/read/ - - See http://openjdk.java.net/ for more information about OpenJDK. - -Simple Build Instructions: - - 0. Get the necessary system software/packages installed on your system, see - http://hg.openjdk.java.net/jdk9/jdk9/raw-file/tip/README-builds.html - - 1. If you don't have a jdk8 or newer jdk, download and install it from - http://java.sun.com/javase/downloads/index.jsp - Add the /bin directory of this installation to your PATH environment - variable. - - 2. Configure the build: - bash ./configure - - 3. Build the OpenJDK: - make all - The resulting JDK image should be found in build/*/images/jdk - -where make is GNU make 3.81 or newer, /usr/bin/make on Linux usually -is 3.81 or newer. Note that on Solaris, GNU make is called "gmake". - -Complete details are available in the file: - http://hg.openjdk.java.net/jdk9/jdk9/raw-file/tip/README-builds.html +See http://openjdk.java.net/ for more information about OpenJDK. diff --git a/README-builds.html b/README-builds.html deleted file mode 100644 index 6d7d5b52461..00000000000 --- a/README-builds.html +++ /dev/null @@ -1,1406 +0,0 @@ - - - OpenJDK Build README - - -

OpenJDK

- -

OpenJDK Build README

- -
- -

- -

Introduction

- -

This README file contains build instructions for the -OpenJDK. Building the source code for the OpenJDK -requires a certain degree of technical expertise.

- -

!!!!!!!!!!!!!!! THIS IS A MAJOR RE-WRITE of this document. !!!!!!!!!!!!!

- -

Some Headlines:

- - - -
- -

Contents

- - - -
- - - -
- -

- -

Use of Mercurial

- -

The OpenJDK sources are maintained with the revision control system -Mercurial. If you are new to -Mercurial, please see the Beginner Guides or refer to the Mercurial Book. -The first few chapters of the book provide an excellent overview of Mercurial, -what it is and how it works.

- -

For using Mercurial with the OpenJDK refer to the Developer Guide: Installing -and Configuring Mercurial section for more information.

- -

- -

Getting the Source

- -

To get the entire set of OpenJDK Mercurial repositories use the script -get_source.sh located in the root repository:

- -
  hg clone http://hg.openjdk.java.net/jdk9/jdk9 YourOpenJDK
-  cd YourOpenJDK
-  bash ./get_source.sh
-
- -

Once you have all the repositories, keep in mind that each repository is its -own independent repository. You can also re-run ./get_source.sh anytime to -pull over all the latest changesets in all the repositories. This set of -nested repositories has been given the term "forest" and there are various -ways to apply the same hg command to each of the repositories. For -example, the script make/scripts/hgforest.sh can be used to repeat the -same hg command on every repository, e.g.

- -
  cd YourOpenJDK
-  bash ./make/scripts/hgforest.sh status
-
- -

- -

Repositories

- -

The set of repositories and what they contain:

- - - -

Repository Source Guidelines

- -

There are some very basic guidelines:

- - - -
- -

- -

Building

- -

The very first step in building the OpenJDK is making sure the system itself -has everything it needs to do OpenJDK builds. Once a system is setup, it -generally doesn't need to be done again.

- -

Building the OpenJDK is now done with running a configure script which will -try and find and verify you have everything you need, followed by running -make, e.g.

- -
-

bash ./configure
- make all

-
- -

Where possible the configure script will attempt to located the various -components in the default locations or via component specific variable -settings. When the normal defaults fail or components cannot be found, -additional configure options may be necessary to help configure find the -necessary tools for the build, or you may need to re-visit the setup of your -system due to missing software packages.

- -

NOTE: The configure script file does not have execute permissions and -will need to be explicitly run with bash, see the source guidelines.

- -
- -

- -

System Setup

- -

Before even attempting to use a system to build the OpenJDK there are some very -basic system setups needed. For all systems:

- - - -

And for specific systems:

- - - -

- -

Linux

- -

With Linux, try and favor the system packages over building your own or getting -packages from other areas. Most Linux builds should be possible with the -system's available packages.

- -

Note that some Linux systems have a habit of pre-populating your environment -variables for you, for example JAVA_HOME might get pre-defined for you to -refer to the JDK installed on your Linux system. You will need to unset -JAVA_HOME. It's a good idea to run env and verify the environment variables -you are getting from the default system settings make sense for building the -OpenJDK.

- -

- -

Solaris

- -

- -
Studio Compilers
- -

At a minimum, the Studio 12 Update 4 Compilers (containing -version 5.13 of the C and C++ compilers) is required, including specific -patches.

- -

The Solaris Studio installation should contain at least these packages:

- -
-

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
PackageVersion
developer/solarisstudio-124/backend12.4-1.0.6.0
developer/solarisstudio-124/c++12.4-1.0.10.0
developer/solarisstudio-124/cc12.4-1.0.4.0
developer/solarisstudio-124/library/c++-libs12.4-1.0.10.0
developer/solarisstudio-124/library/math-libs12.4-1.0.0.1
developer/solarisstudio-124/library/studio-gccrt12.4-1.0.0.1
developer/solarisstudio-124/studio-common12.4-1.0.0.1
developer/solarisstudio-124/studio-ja12.4-1.0.0.1
developer/solarisstudio-124/studio-legal12.4-1.0.0.1
developer/solarisstudio-124/studio-zhCN12.4-1.0.0.1

-
- -

In particular backend 12.4-1.0.6.0 contains a critical patch for the sparc -version.

- -

Place the bin directory in PATH.

- -

The Oracle Solaris Studio Express compilers at: Oracle Solaris Studio Express -Download site are also an option, although these compilers -have not been extensively used yet.

- -

- -

Windows

- -
Windows Unix Toolkit
- -

Building on Windows requires a Unix-like environment, notably a Unix-like -shell. There are several such environments available of which -Cygwin and -MinGW/MSYS are currently supported for the -OpenJDK build. One of the differences of these systems from standard Windows -tools is the way they handle Windows path names, particularly path names which -contain spaces, backslashes as path separators and possibly drive letters. -Depending on the use case and the specifics of each environment these path -problems can be solved by a combination of quoting whole paths, translating -backslashes to forward slashes, escaping backslashes with additional -backslashes and translating the path names to their "8.3" -version.

- -

- -
CYGWIN
- -

CYGWIN is an open source, Linux-like environment which tries to emulate a -complete POSIX layer on Windows. It tries to be smart about path names and can -usually handle all kinds of paths if they are correctly quoted or escaped -although internally it maps drive letters <drive>: to a virtual directory -/cygdrive/<drive>.

- -

You can always use the cygpath utility to map pathnames with spaces or the -backslash character into the C:/ style of pathname (called 'mixed'), e.g. -cygpath -s -m "<path>".

- -

Note that the use of CYGWIN creates a unique problem with regards to setting -PATH. Normally on Windows the PATH variable contains directories -separated with the ";" character (Solaris and Linux use ":"). With CYGWIN, it -uses ":", but that means that paths like "C:/path" cannot be placed in the -CYGWIN version of PATH and instead CYGWIN uses something like -/cygdrive/c/path which CYGWIN understands, but only CYGWIN understands.

- -

The OpenJDK build requires CYGWIN version 1.7.16 or newer. Information about -CYGWIN can be obtained from the CYGWIN website at -www.cygwin.com.

- -

By default CYGWIN doesn't install all the tools required for building the -OpenJDK. Along with the default installation, you need to install the following -tools.

- -
-

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Binary NameCategoryPackageDescription
ar.exeDevelbinutilsThe GNU assembler, linker and binary utilities
make.exeDevelmakeThe GNU version of the 'make' utility built for CYGWIN
m4.exeInterpretersm4GNU implementation of the traditional Unix macro processor
cpio.exeUtilscpioA program to manage archives of files
gawk.exeUtilsawkPattern-directed scanning and processing language
file.exeUtilsfileDetermines file type using 'magic' numbers
zip.exeArchivezipPackage and compress (archive) files
unzip.exeArchiveunzipExtract compressed files in a ZIP archive
free.exeSystemprocpsDisplay amount of free and used memory in the system

-
- -

Note that the CYGWIN software can conflict with other non-CYGWIN software on -your Windows system. CYGWIN provides a FAQ for known issues and problems, of particular interest is the -section on BLODA (applications that interfere with -CYGWIN).

- -

- -
MinGW/MSYS
- -

MinGW ("Minimalist GNU for Windows") is a collection of free Windows specific -header files and import libraries combined with GNU toolsets that allow one to -produce native Windows programs that do not rely on any 3rd-party C runtime -DLLs. MSYS is a supplement to MinGW which allows building applications and -programs which rely on traditional UNIX tools to be present. Among others this -includes tools like bash and make. See MinGW/MSYS for more information.

- -

Like Cygwin, MinGW/MSYS can handle different types of path formats. They are -internally converted to paths with forward slashes and drive letters -<drive>: replaced by a virtual directory /<drive>. Additionally, MSYS -automatically detects binaries compiled for the MSYS environment and feeds them -with the internal, Unix-style path names. If native Windows applications are -called from within MSYS programs their path arguments are automatically -converted back to Windows style path names with drive letters and backslashes -as path separators. This may cause problems for Windows applications which use -forward slashes as parameter separator (e.g. cl /nologo /I) because MSYS may -wrongly replace such parameters by drive letters.

- -

In addition to the tools which will be installed by default, you have to -manually install the msys-zip and msys-unzip packages. This can be easily -done with the MinGW command line installer:

- -
  mingw-get.exe install msys-zip
-  mingw-get.exe install msys-unzip
-
- -

- -
Visual Studio 2013 Compilers
- -

The 32-bit and 64-bit OpenJDK Windows build requires Microsoft Visual Studio -C++ 2013 (VS2013) Professional Edition or Express compiler. The compiler and -other tools are expected to reside in the location defined by the variable -VS120COMNTOOLS which is set by the Microsoft Visual Studio installer.

- -

Only the C++ part of VS2013 is needed. Try to let the installation go to the -default install directory. Always reboot your system after installing VS2013. -The system environment variable VS120COMNTOOLS should be set in your -environment.

- -

Make sure that TMP and TEMP are also set in the environment and refer to -Windows paths that exist, like C:\temp, not /tmp, not /cygdrive/c/temp, -and not C:/temp. C:\temp is just an example, it is assumed that this area -is private to the user, so by default after installs you should see a unique -user path in these variables.

- -

- -

Mac OS X

- -

Make sure you get the right XCode version.

- -
- -

- -

Configure

- -

The basic invocation of the configure script looks like:

- -
-

bash ./configure [options]

-
- -

This will create an output directory containing the "configuration" and setup -an area for the build result. This directory typically looks like:

- -
-

build/linux-x64-normal-server-release

-
- -

configure will try to figure out what system you are running on and where all -necessary build components are. If you have all prerequisites for building -installed, it should find everything. If it fails to detect any component -automatically, it will exit and inform you about the problem. When this -happens, read more below in the configure options.

- -

Some examples:

- -
-

Windows 32bit build with freetype specified:
- bash ./configure --with-freetype=/cygdrive/c/freetype-i586 --with-target- -bits=32

- -

Debug 64bit Build:
- bash ./configure --enable-debug --with-target-bits=64

-
- -

- -

Configure Options

- -

Complete details on all the OpenJDK configure options can be seen with:

- -
-

bash ./configure --help=short

-
- -

Use -help to see all the configure options available. You can generate any -number of different configurations, e.g. debug, release, 32, 64, etc.

- -

Some of the more commonly used configure options are:

- -
-

--enable-debug
- set the debug level to fastdebug (this is a shorthand for --with-debug- - level=fastdebug)

-
- -

- -
-

--with-alsa=path
- select the location of the Advanced Linux Sound Architecture (ALSA)

- -

Version 0.9.1 or newer of the ALSA files are required for building the - OpenJDK on Linux. These Linux files are usually available from an "alsa" of - "libasound" development package, and it's highly recommended that you try - and use the package provided by the particular version of Linux that you are - using.

- -

--with-boot-jdk=path
- select the Bootstrap JDK

- -

--with-boot-jdk-jvmargs="args"
- provide the JVM options to be used to run the Bootstrap JDK

- -

--with-cacerts=path
- select the path to the cacerts file.

- -

See Certificate Authority on Wikipedia for a better understanding of the Certificate - Authority (CA). A certificates file named "cacerts" represents a system-wide - keystore with CA certificates. In JDK and JRE binary bundles, the "cacerts" - file contains root CA certificates from several public CAs (e.g., VeriSign, - Thawte, and Baltimore). The source contain a cacerts file without CA root - certificates. Formal JDK builders will need to secure permission from each - public CA and include the certificates into their own custom cacerts file. - Failure to provide a populated cacerts file will result in verification - errors of a certificate chain during runtime. By default an empty cacerts - file is provided and that should be fine for most JDK developers.

-
- -

- -
-

--with-cups=path
- select the CUPS install location

- -

The Common UNIX Printing System (CUPS) Headers are required for building the - OpenJDK on Solaris and Linux. The Solaris header files can be obtained by - installing the package print/cups.

- -

The CUPS header files can always be downloaded from - www.cups.org.

- -

--with-cups-include=path
- select the CUPS include directory location

- -

--with-debug-level=level
- select the debug information level of release, fastdebug, or slowdebug

- -

--with-dev-kit=path
- select location of the compiler install or developer install location

-
- -

- -
-

--with-freetype=path
- select the freetype files to use.

- -

Expecting the freetype libraries under lib/ and the headers under - include/.

- -

Version 2.3 or newer of FreeType is required. On Unix systems required files - can be available as part of your distribution (while you still may need to - upgrade them). Note that you need development version of package that - includes both the FreeType library and header files.

- -

You can always download latest FreeType version from the FreeType - website. Building the freetype 2 libraries from - scratch is also possible, however on Windows refer to the Windows FreeType - DLL build instructions.

- -

Note that by default FreeType is built with byte code hinting support - disabled due to licensing restrictions. In this case, text appearance and - metrics are expected to differ from Sun's official JDK build. See the - SourceForge FreeType2 Home Page - for more information.

- -

--with-import-hotspot=path
- select the location to find hotspot binaries from a previous build to avoid - building hotspot

- -

--with-target-bits=arg
- select 32 or 64 bit build

- -

--with-jvm-variants=variants
- select the JVM variants to build from, comma separated list that can - include: server, client, kernel, zero and zeroshark

- -

--with-memory-size=size
- select the RAM size that GNU make will think this system has

- -

--with-msvcr-dll=path
- select the msvcr100.dll file to include in the Windows builds (C/C++ - runtime library for Visual Studio).

- -

This is usually picked up automatically from the redist directories of - Visual Studio 2013.

- -

--with-num-cores=cores
- select the number of cores to use (processor count or CPU count)

-
- -

- -
-

--with-x=path
- select the location of the X11 and xrender files.

- -

The XRender Extension Headers are required for building the OpenJDK on - Solaris and Linux. The Linux header files are usually available from a - "Xrender" development package, it's recommended that you try and use the - package provided by the particular distribution of Linux that you are using. - The Solaris XRender header files is included with the other X11 header files - in the package SFWxwinc on new enough versions of Solaris and will be - installed in /usr/X11/include/X11/extensions/Xrender.h or - /usr/openwin/share/include/X11/extensions/Xrender.h

-
- -
- -

- -

Make

- -

The basic invocation of the make utility looks like:

- -
-

make all

-
- -

This will start the build to the output directory containing the -"configuration" that was created by the configure script. Run make help for -more information on the available targets.

- -

There are some of the make targets that are of general interest:

- -
-

empty
- build everything but no images

- -

all
- build everything including images

- -

all-conf
- build all configurations

- -

images
- create complete j2sdk and j2re images

- -

install
- install the generated images locally, typically in /usr/local

- -

clean
- remove all files generated by make, but not those generated by configure

- -

dist-clean
- remove all files generated by both and configure (basically killing the - configuration)

- -

help
- give some help on using make, including some interesting make targets

-
- -
- -

- -

Testing

- -

When the build is completed, you should see the generated binaries and -associated files in the j2sdk-image directory in the output directory. In -particular, the build/*/images/j2sdk-image/bin directory should contain -executables for the OpenJDK tools and utilities for that configuration. The -testing tool jtreg will be needed and can be found at: the jtreg -site. The provided regression tests in the -repositories can be run with the command:

- -
-

cd test && make PRODUCT_HOME=`pwd`/../build/*/images/j2sdk-image all

-
- -
- -

- -

Appendix A: Hints and Tips

- -

- -

FAQ

- -

Q: The generated-configure.sh file looks horrible! How are you going to -edit it?
-A: The generated-configure.sh file is generated (think "compiled") by the -autoconf tools. The source code is in configure.ac and various .m4 files in -common/autoconf, which are much more readable.

- -

Q: Why is the generated-configure.sh file checked in, if it is -generated?
-A: If it was not generated, every user would need to have the autoconf -tools installed, and re-generate the configure file as the first step. Our -goal is to minimize the work needed to be done by the user to start building -OpenJDK, and to minimize the number of external dependencies required.

- -

Q: Do you require a specific version of autoconf for regenerating -generated-configure.sh?
-A: Yes, version 2.69 is required and should be easy enough to aquire on all -supported operating systems. The reason for this is to avoid large spurious -changes in generated-configure.sh.

- -

Q: How do you regenerate generated-configure.sh after making changes to -the input files?
-A: Regnerating generated-configure.sh should always be done using the -script common/autoconf/autogen.sh to ensure that the correct files get -updated. This script should also be run after mercurial tries to merge -generated-configure.sh as a merge of the generated file is not guaranteed to -be correct.

- -

Q: What are the files in common/makefiles/support/* for? They look like -gibberish.
-A: They are a somewhat ugly hack to compensate for command line length -limitations on certain platforms (Windows, Solaris). Due to a combination of -limitations in make and the shell, command lines containing too many files will -not work properly. These helper files are part of an elaborate hack that will -compress the command line in the makefile and then uncompress it safely. We're -not proud of it, but it does fix the problem. If you have any better -suggestions, we're all ears! :-)

- -

Q: I want to see the output of the commands that make runs, like in the old -build. How do I do that?
-A: You specify the LOG variable to make. There are several log levels:

- - - -

Q: When do I have to re-run configure?
-A: Normally you will run configure only once for creating a -configuration. You need to re-run configuration only if you want to change any -configuration options, or if you pull down changes to the configure script.

- -

Q: I have added a new source file. Do I need to modify the makefiles?
-A: Normally, no. If you want to create e.g. a new native library, you will -need to modify the makefiles. But for normal file additions or removals, no -changes are needed. There are certan exceptions for some native libraries where -the source files are spread over many directories which also contain sources -for other libraries. In these cases it was simply easier to create include -lists rather than excludes.

- -

Q: When I run configure --help, I see many strange options, like ---dvidir. What is this?
-A: Configure provides a slew of options by default, to all projects that -use autoconf. Most of them are not used in OpenJDK, so you can safely ignore -them. To list only OpenJDK specific features, use configure --help=short -instead.

- -

Q: configure provides OpenJDK-specific features such as --with- -builddeps-server that are not described in this document. What about those?
-A: Try them out if you like! But be aware that most of these are -experimental features. Many of them don't do anything at all at the moment; the -option is just a placeholder. Others depend on pieces of code or infrastructure -that is currently not ready for prime time.

- -

Q: How will you make sure you don't break anything?
-A: We have a script that compares the result of the new build system with -the result of the old. For most part, we aim for (and achieve) byte-by-byte -identical output. There are however technical issues with e.g. native binaries, -which might differ in a byte-by-byte comparison, even when building twice with -the old build system. For these, we compare relevant aspects (e.g. the symbol -table and file size). Note that we still don't have 100% equivalence, but we're -close.

- -

Q: I noticed this thing X in the build that looks very broken by design. -Why don't you fix it?
-A: Our goal is to produce a build output that is as close as technically -possible to the old build output. If things were weird in the old build, they -will be weird in the new build. Often, things were weird before due to -obscurity, but in the new build system the weird stuff comes up to the surface. -The plan is to attack these things at a later stage, after the new build system -is established.

- -

Q: The code in the new build system is not that well-structured. Will you -fix this?
-A: Yes! The new build system has grown bit by bit as we converted the old -system. When all of the old build system is converted, we can take a step back -and clean up the structure of the new build system. Some of this we plan to do -before replacing the old build system and some will need to wait until after.

- -

Q: Is anything able to use the results of the new build's default make -target?
-A: Yes, this is the minimal (or roughly minimal) set of compiled output -needed for a developer to actually execute the newly built JDK. The idea is -that in an incremental development fashion, when doing a normal make, you -should only spend time recompiling what's changed (making it purely -incremental) and only do the work that's needed to actually run and test your -code. The packaging stuff that is part of the images target is not needed for -a normal developer who wants to test his new code. Even if it's quite fast, -it's still unnecessary. We're targeting sub-second incremental rebuilds! ;-) -(Or, well, at least single-digit seconds...)

- -

Q: I usually set a specific environment variable when building, but I can't -find the equivalent in the new build. What should I do?
-A: It might very well be that we have neglected to add support for an -option that was actually used from outside the build system. Email us and we -will add support for it!

- -

- -

Build Performance Tips

- -

Building OpenJDK requires a lot of horsepower. Some of the build tools can be -adjusted to utilize more or less of resources such as parallel threads and -memory. The configure script analyzes your system and selects reasonable -values for such options based on your hardware. If you encounter resource -problems, such as out of memory conditions, you can modify the detected values -with:

- - - -

It might also be necessary to specify the JVM arguments passed to the Bootstrap -JDK, using e.g. --with-boot-jdk-jvmargs="-Xmx8G -enableassertions". Doing -this will override the default JVM arguments passed to the Bootstrap JDK.

- -

One of the top goals of the new build system is to improve the build -performance and decrease the time needed to build. This will soon also apply to -the java compilation when the Smart Javac wrapper is fully supported.

- -

At the end of a successful execution of configure, you will get a performance -summary, indicating how well the build will perform. Here you will also get -performance hints. If you want to build fast, pay attention to those!

- -

Building with ccache

- -

The OpenJDK build supports building with ccache when using gcc or clang. Using -ccache can radically speed up compilation of native code if you often rebuild -the same sources. Your milage may vary however so we recommend evaluating it -for yourself. To enable it, make sure it's on the path and configure with ---enable-ccache.

- -

Building on local disk

- -

If you are using network shares, e.g. via NFS, for your source code, make sure -the build directory is situated on local disk. The performance penalty is -extremely high for building on a network share, close to unusable.

- -

Building only one JVM

- -

The old build builds multiple JVMs on 32-bit systems (client and server; and on -Windows kernel as well). In the new build we have changed this default to only -build server when it's available. This improves build times for those not -interested in multiple JVMs. To mimic the old behavior on platforms that -support it, use --with-jvm-variants=client,server.

- -

Selecting the number of cores to build on

- -

By default, configure will analyze your machine and run the make process in -parallel with as many threads as you have cores. This behavior can be -overridden, either "permanently" (on a configure basis) using ---with-num-cores=N or for a single build only (on a make basis), using -make JOBS=N.

- -

If you want to make a slower build just this time, to save some CPU power for -other processes, you can run e.g. make JOBS=2. This will force the makefiles -to only run 2 parallel processes, or even make JOBS=1 which will disable -parallelism.

- -

If you want to have it the other way round, namely having slow builds default -and override with fast if you're impatient, you should call configure with ---with-num-cores=2, making 2 the default. If you want to run with more cores, -run make JOBS=8

- -

- -

Troubleshooting

- -

Solving build problems

- -

If the build fails (and it's not due to a compilation error in a source file -you've changed), the first thing you should do is to re-run the build with more -verbosity. Do this by adding LOG=debug to your make command line.

- -

The build log (with both stdout and stderr intermingled, basically the same as -you see on your console) can be found as build.log in your build directory.

- -

You can ask for help on build problems with the new build system on either the -build-dev or the -build-infra-dev -mailing lists. Please include the relevant parts of the build log.

- -

A build can fail for any number of reasons. Most failures are a result of -trying to build in an environment in which all the pre-build requirements have -not been met. The first step in troubleshooting a build failure is to recheck -that you have satisfied all the pre-build requirements for your platform. -Scanning the configure log is a good first step, making sure that what it -found makes sense for your system. Look for strange error messages or any -difficulties that configure had in finding things.

- -

Some of the more common problems with builds are briefly described below, with -suggestions for remedies.

- - - -
- -

- -

Appendix B: GNU make

- -

The Makefiles in the OpenJDK are only valid when used with the GNU version of -the utility command make (usually called gmake on Solaris). A few notes -about using GNU make:

- - - -

Information on GNU make, and access to ftp download sites, are available on the -GNU make web site . The latest -source to GNU make is available at -ftp.gnu.org/pub/gnu/make/.

- -

- -

Building GNU make

- -

First step is to get the GNU make 3.81 or newer source from -ftp.gnu.org/pub/gnu/make/. Building is a -little different depending on the OS but is basically done with:

- -
  bash ./configure
-  make
-
- -
- -

- -

Appendix C: Build Environments

- -

Minimum Build Environments

- -

This file often describes specific requirements for what we call the "minimum -build environments" (MBE) for this specific release of the JDK. What is listed -below is what the Oracle Release Engineering Team will use to build the Oracle -JDK product. Building with the MBE will hopefully generate the most compatible -bits that install on, and run correctly on, the most variations of the same -base OS and hardware architecture. In some cases, these represent what is often -called the least common denominator, but each Operating System has different -aspects to it.

- -

In all cases, the Bootstrap JDK version minimum is critical, we cannot -guarantee builds will work with older Bootstrap JDK's. Also in all cases, more -RAM and more processors is better, the minimums listed below are simply -recommendations.

- -

With Solaris and Mac OS X, the version listed below is the oldest release we -can guarantee builds and works, and the specific version of the compilers used -could be critical.

- -

With Windows the critical aspect is the Visual Studio compiler used, which due -to it's runtime, generally dictates what Windows systems can do the builds and -where the resulting bits can be used.

- -

NOTE: We expect a change here off these older Windows OS releases and to a -'less older' one, probably Windows 2008R2 X64.

- -

With Linux, it was just a matter of picking a stable distribution that is a -good representative for Linux in general.

- -

It is understood that most developers will NOT be using these specific -versions, and in fact creating these specific versions may be difficult due to -the age of some of this software. It is expected that developers are more often -using the more recent releases and distributions of these operating systems.

- -

Compilation problems with newer or different C/C++ compilers is a common -problem. Similarly, compilation problems related to changes to the -/usr/include or system header files is also a common problem with older, -newer, or unreleased OS versions. Please report these types of problems as bugs -so that they can be dealt with accordingly.

- -
-

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Base OS and ArchitectureOSC/C++ CompilerBootstrap JDKProcessorsRAM MinimumDISK Needs
Linux X86 (32-bit) and X64 (64-bit)Oracle Enterprise Linux 6.4gcc 4.9.2 JDK 82 or more1 GB6 GB
Solaris SPARCV9 (64-bit)Solaris 11 Update 1Studio 12 Update 4 + patchesJDK 84 or more4 GB8 GB
Solaris X64 (64-bit)Solaris 11 Update 1Studio 12 Update 4 + patchesJDK 84 or more4 GB8 GB
Windows X86 (32-bit)Windows Server 2012 R2 x64Microsoft Visual Studio C++ 2013 Professional EditionJDK 82 or more2 GB6 GB
Windows X64 (64-bit)Windows Server 2012 R2 x64Microsoft Visual Studio C++ 2013 Professional EditionJDK 82 or more2 GB6 GB
Mac OS X X64 (64-bit)Mac OS X 10.9 "Mavericks"Xcode 6.3 or newerJDK 82 or more4 GB6 GB

-
- -
- -

- -

Specific Developer Build Environments

- -

We won't be listing all the possible environments, but we will try to provide -what information we have available to us.

- -

NOTE: The community can help out by updating this part of the document.

- -

Fedora

- -

After installing the latest Fedora you need to -install several build dependencies. The simplest way to do it is to execute the -following commands as user root:

- -
  yum-builddep java-1.7.0-openjdk
-  yum install gcc gcc-c++
-
- -

In addition, it's necessary to set a few environment variables for the build:

- -
  export LANG=C
-  export PATH="/usr/lib/jvm/java-openjdk/bin:${PATH}"
-
- -

CentOS 5.5

- -

After installing CentOS 5.5 you need to make sure you -have the following Development bundles installed:

- - - -

Plus the following packages:

- - - -

The freetype 2.3 packages don't seem to be available, but the freetype 2.3 -sources can be downloaded, built, and installed easily enough from the -freetype site. Build and install -with something like:

- -
  bash ./configure
-  make
-  sudo -u root make install
-
- -

Mercurial packages could not be found easily, but a Google search should find -ones, and they usually include Python if it's needed.

- -

Debian 5.0 (Lenny)

- -

After installing Debian 5 you need to install several -build dependencies. The simplest way to install the build dependencies is to -execute the following commands as user root:

- -
  aptitude build-dep openjdk-7
-  aptitude install openjdk-7-jdk libmotif-dev
-
- -

In addition, it's necessary to set a few environment variables for the build:

- -
  export LANG=C
-  export PATH="/usr/lib/jvm/java-7-openjdk/bin:${PATH}"
-
- -

Ubuntu 12.04

- -

After installing Ubuntu 12.04 you need to install several -build dependencies. The simplest way to do it is to execute the following -commands:

- -
  sudo aptitude build-dep openjdk-7
-  sudo aptitude install openjdk-7-jdk
-
- -

In addition, it's necessary to set a few environment variables for the build:

- -
  export LANG=C
-  export PATH="/usr/lib/jvm/java-7-openjdk/bin:${PATH}"
-
- -

OpenSUSE 11.1

- -

After installing OpenSUSE 11.1 you need to install -several build dependencies. The simplest way to install the build dependencies -is to execute the following commands:

- -
  sudo zypper source-install -d java-1_7_0-openjdk
-  sudo zypper install make
-
- -

In addition, it is necessary to set a few environment variables for the build:

- -
  export LANG=C
-  export PATH="/usr/lib/jvm/java-1.7.0-openjdk/bin:$[PATH}"
-
- -

Finally, you need to unset the JAVA_HOME environment variable:

- -
  export -n JAVA_HOME`
-
- -

Mandriva Linux One 2009 Spring

- -

After installing Mandriva Linux One 2009 Spring you need -to install several build dependencies. The simplest way to install the build -dependencies is to execute the following commands as user root:

- -
  urpmi java-1.7.0-openjdk-devel make gcc gcc-c++ freetype-devel zip unzip
-    libcups2-devel libxrender1-devel libalsa2-devel libstc++-static-devel
-    libxtst6-devel libxi-devel
-
- -

In addition, it is necessary to set a few environment variables for the build:

- -
  export LANG=C
-  export PATH="/usr/lib/jvm/java-1.7.0-openjdk/bin:${PATH}"
-
- -

OpenSolaris 2009.06

- -

After installing OpenSolaris 2009.06 you need to -install several build dependencies. The simplest way to install the build -dependencies is to execute the following commands:

- -
  pfexec pkg install SUNWgmake SUNWj7dev sunstudioexpress SUNWcups SUNWzip
-    SUNWunzip SUNWxwhl SUNWxorg-headers SUNWaudh SUNWfreetype2
-
- -

In addition, it is necessary to set a few environment variables for the build:

- -
  export LANG=C
-  export PATH="/opt/SunStudioExpress/bin:${PATH}"
-
- -
- -

End of the OpenJDK build README document.

- -

Please come again!

- - diff --git a/common/autoconf/basics.m4 b/common/autoconf/basics.m4 index 35e835c3994..0bce558c1c7 100644 --- a/common/autoconf/basics.m4 +++ b/common/autoconf/basics.m4 @@ -530,6 +530,7 @@ AC_DEFUN_ONCE([BASIC_SETUP_FUNDAMENTAL_TOOLS], BASIC_PATH_PROGS(DF, df) BASIC_PATH_PROGS(CPIO, [cpio bsdcpio]) BASIC_PATH_PROGS(NICE, nice) + BASIC_PATH_PROGS(PANDOC, pandoc) ]) # Setup basic configuration paths, and platform-specific stuff related to PATHs. @@ -1094,9 +1095,11 @@ AC_DEFUN_ONCE([BASIC_SETUP_COMPLEX_TOOLS], OTOOL="true" fi BASIC_PATH_PROGS(READELF, [greadelf readelf]) + BASIC_PATH_PROGS(DOT, dot) BASIC_PATH_PROGS(HG, hg) BASIC_PATH_PROGS(STAT, stat) BASIC_PATH_PROGS(TIME, time) + BASIC_PATH_PROGS(FLOCK, flock) # Dtrace is usually found in /usr/sbin on Solaris, but that directory may not # be in the user path. BASIC_PATH_PROGS(DTRACE, dtrace, $PATH:/usr/sbin) @@ -1202,6 +1205,18 @@ AC_DEFUN_ONCE([BASIC_TEST_USABILITY_ISSUES], # Check for support for specific options in bash AC_DEFUN_ONCE([BASIC_CHECK_BASH_OPTIONS], [ + # Check bash version + # Extra [ ] to stop m4 mangling + [ BASH_VER=`$BASH --version | $SED -n -e 's/^.*bash.*ersion *\([0-9.]*\).*$/\1/ p'` ] + AC_MSG_CHECKING([bash version]) + AC_MSG_RESULT([$BASH_VER]) + + BASH_MAJOR=`$ECHO $BASH_VER | $CUT -d . -f 1` + BASH_MINOR=`$ECHO $BASH_VER | $CUT -d . -f 2` + if test $BASH_MAJOR -lt 3 || (test $BASH_MAJOR -eq 3 && test $BASH_MINOR -lt 2); then + AC_MSG_ERROR([bash version 3.2 or better is required]) + fi + # Test if bash supports pipefail. AC_MSG_CHECKING([if bash supports pipefail]) if ${BASH} -c 'set -o pipefail'; then diff --git a/common/autoconf/basics_windows.m4 b/common/autoconf/basics_windows.m4 index 1a79bf8fc86..2ae6e34a556 100644 --- a/common/autoconf/basics_windows.m4 +++ b/common/autoconf/basics_windows.m4 @@ -329,8 +329,8 @@ AC_DEFUN([BASIC_CHECK_PATHS_WINDOWS], AC_MSG_ERROR([Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path]) fi AC_MSG_CHECKING([cygwin root directory as unix-style path]) - # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away - cygwin_winpath_root=`cd / ; cmd /c cd | $GREP ".*"` + # The cmd output ends with Windows line endings (CR/LF) + cygwin_winpath_root=`cd / ; cmd /c cd | $TR -d '\r\n'` # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` AC_MSG_RESULT([$CYGWIN_ROOT_PATH]) diff --git a/common/autoconf/boot-jdk.m4 b/common/autoconf/boot-jdk.m4 index b7ae10542ed..e286603adef 100644 --- a/common/autoconf/boot-jdk.m4 +++ b/common/autoconf/boot-jdk.m4 @@ -318,7 +318,7 @@ AC_DEFUN_ONCE([BOOTJDK_SETUP_BOOT_JDK], AC_SUBST(JAVAC_FLAGS) # Check if the boot jdk is 32 or 64 bit - if "$JAVA" -d64 -version > /dev/null 2>&1; then + if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then BOOT_JDK_BITS="64" else BOOT_JDK_BITS="32" diff --git a/common/autoconf/build-aux/install.sh b/common/autoconf/build-aux/install.sh index 98c1dc444a7..5934326e225 100644 --- a/common/autoconf/build-aux/install.sh +++ b/common/autoconf/build-aux/install.sh @@ -1,5 +1,28 @@ -#!/bin/sh -echo >&2 "No suitable 'install' command found.'" -echo >&2 "If automake is installed, running 'automake -fa'" -echo >&2 "(and ignoring the errors) might produce one." -exit 1 +#!/bin/bash +# +# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Oracle designates this +# particular file as subject to the "Classpath" exception as provided +# by Oracle in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. +# + +# This file is empty on purpose. It's a placeholder which is required by +# autoconf, but it serves no purpose for us. diff --git a/common/autoconf/build-performance.m4 b/common/autoconf/build-performance.m4 index 13578cfa867..72799148692 100644 --- a/common/autoconf/build-performance.m4 +++ b/common/autoconf/build-performance.m4 @@ -417,10 +417,8 @@ AC_DEFUN_ONCE([BPERF_SETUP_SMART_JAVAC], AC_SUBST(SJAVAC_SERVER_JAVA) if test "$MEMORY_SIZE" -gt "3000"; then - ADD_JVM_ARG_IF_OK([-d64],SJAVAC_SERVER_JAVA_FLAGS,[$SJAVAC_SERVER_JAVA]) - if test "$JVM_ARG_OK" = true; then + if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then JVM_64BIT=true - JVM_ARG_OK=false fi fi diff --git a/common/autoconf/flags.m4 b/common/autoconf/flags.m4 index ca7f625664c..a96b74be793 100644 --- a/common/autoconf/flags.m4 +++ b/common/autoconf/flags.m4 @@ -355,7 +355,7 @@ AC_DEFUN([FLAGS_SETUP_COMPILER_FLAGS_FOR_LIBS], SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" fi - SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' + SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or [$]1,/.)' SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/[$]1' SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,[$]1' @@ -375,7 +375,7 @@ AC_DEFUN([FLAGS_SETUP_COMPILER_FLAGS_FOR_LIBS], # Linking is different on MacOSX PICFLAG='' SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" - SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' + SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or [$]1,/.)' SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/[$]1' SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,[$]1' diff --git a/common/autoconf/generated-configure.sh b/common/autoconf/generated-configure.sh index 917181abf10..8a8760f240a 100644 --- a/common/autoconf/generated-configure.sh +++ b/common/autoconf/generated-configure.sh @@ -918,6 +918,7 @@ COMPRESS_JARS INCLUDE_SA UNLIMITED_CRYPTO CACERTS_FILE +ENABLE_FULL_DOCS ENABLE_HEADLESS_ONLY DEFAULT_MAKE_TARGET OS_VERSION_MICRO @@ -932,9 +933,11 @@ DSYMUTIL IS_GNU_TIME PATCH DTRACE +FLOCK TIME STAT HG +DOT READELF OTOOL LDD @@ -993,8 +996,9 @@ OPENJDK_TARGET_CPU_OSARCH OPENJDK_TARGET_CPU_ISADIR OPENJDK_TARGET_CPU_LEGACY_LIB OPENJDK_TARGET_CPU_LEGACY -REQUIRED_OS_VERSION -REQUIRED_OS_NAME +RELEASE_FILE_OS_ARCH +RELEASE_FILE_OS_NAME +OPENJDK_MODULE_TARGET_PLATFORM COMPILE_TYPE OPENJDK_TARGET_CPU_ENDIAN OPENJDK_TARGET_CPU_BITS @@ -1024,6 +1028,7 @@ build_os build_vendor build_cpu build +PANDOC NICE CPIO DF @@ -1136,6 +1141,7 @@ with_conf_name with_output_sync with_default_make_target enable_headless_only +enable_full_docs with_cacerts_file enable_unlimited_crypto with_copyright_year @@ -1281,15 +1287,18 @@ READLINK DF CPIO NICE +PANDOC MAKE UNZIP ZIPEXE LDD OTOOL READELF +DOT HG STAT TIME +FLOCK DTRACE PATCH DSYMUTIL @@ -1967,6 +1976,8 @@ Optional Features: --enable-debug set the debug level to fastdebug (shorthand for --with-debug-level=fastdebug) [disabled] --enable-headless-only only build headless (no GUI) support [disabled] + --enable-full-docs build complete documentation [enabled if all tools + found] --disable-unlimited-crypto Disable unlimited crypto policy [enabled] --disable-keep-packaged-modules @@ -2244,15 +2255,18 @@ Some influential environment variables: DF Override default value for DF CPIO Override default value for CPIO NICE Override default value for NICE + PANDOC Override default value for PANDOC MAKE Override default value for MAKE UNZIP Override default value for UNZIP ZIPEXE Override default value for ZIPEXE LDD Override default value for LDD OTOOL Override default value for OTOOL READELF Override default value for READELF + DOT Override default value for DOT HG Override default value for HG STAT Override default value for STAT TIME Override default value for TIME + FLOCK Override default value for FLOCK DTRACE Override default value for DTRACE PATCH Override default value for PATCH DSYMUTIL Override default value for DSYMUTIL @@ -4887,6 +4901,8 @@ VALID_JVM_VARIANTS="server client minimal core zero zeroshark custom" + + #%%% Build and target systems %%% @@ -5043,7 +5059,7 @@ TOOLCHAIN_MINIMUM_VERSION_xlc="" # # $1 = compiler to test (CC or CXX) # $2 = human readable name of compiler (C or C++) -# $3 = list of compiler names to search for +# $3 = compiler name to search for # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), @@ -5170,7 +5186,7 @@ VS_SDK_PLATFORM_NAME_2013= #CUSTOM_AUTOCONF_INCLUDE # Do not change or remove the following line, it is needed for consistency checks: -DATE_WHEN_GENERATED=1486175373 +DATE_WHEN_GENERATED=1494858828 ############################################################################### # @@ -15358,6 +15374,203 @@ $as_echo "$tool_specified" >&6; } + # Publish this variable in the help. + + + if [ -z "${PANDOC+x}" ]; then + # The variable is not set by user, try to locate tool using the code snippet + for ac_prog in pandoc +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PANDOC+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PANDOC in + [\\/]* | ?:[\\/]*) + ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +PANDOC=$ac_cv_path_PANDOC +if test -n "$PANDOC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 +$as_echo "$PANDOC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$PANDOC" && break +done + + else + # The variable is set, but is it from the command line or the environment? + + # Try to remove the string !PANDOC! from our list. + try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PANDOC!/} + if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then + # If it failed, the variable was not from the command line. Ignore it, + # but warn the user (except for BASH, which is always set by the calling BASH). + if test "xPANDOC" != xBASH; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&5 +$as_echo "$as_me: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&2;} + fi + # Try to locate tool using the code snippet + for ac_prog in pandoc +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PANDOC+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PANDOC in + [\\/]* | ?:[\\/]*) + ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +PANDOC=$ac_cv_path_PANDOC +if test -n "$PANDOC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 +$as_echo "$PANDOC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$PANDOC" && break +done + + else + # If it succeeded, then it was overridden by the user. We will use it + # for the tool. + + # First remove it from the list of overridden variables, so we can test + # for unknown variables in the end. + CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" + + # Check if we try to supply an empty value + if test "x$PANDOC" = x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PANDOC= (no value)" >&5 +$as_echo "$as_me: Setting user supplied tool PANDOC= (no value)" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 +$as_echo_n "checking for PANDOC... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 +$as_echo "disabled" >&6; } + else + # Check if the provided tool contains a complete path. + tool_specified="$PANDOC" + tool_basename="${tool_specified##*/}" + if test "x$tool_basename" = "x$tool_specified"; then + # A command without a complete path is provided, search $PATH. + { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PANDOC=$tool_basename" >&5 +$as_echo "$as_me: Will search for user supplied tool PANDOC=$tool_basename" >&6;} + # Extract the first word of "$tool_basename", so it can be a program name with args. +set dummy $tool_basename; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PANDOC+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PANDOC in + [\\/]* | ?:[\\/]*) + ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +PANDOC=$ac_cv_path_PANDOC +if test -n "$PANDOC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 +$as_echo "$PANDOC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + if test "x$PANDOC" = x; then + as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 + fi + else + # Otherwise we believe it is a complete path. Use it as it is. + { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PANDOC=$tool_specified" >&5 +$as_echo "$as_me: Will use user supplied tool PANDOC=$tool_specified" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 +$as_echo_n "checking for PANDOC... " >&6; } + if test ! -x "$tool_specified"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 +$as_echo "not found" >&6; } + as_fn_error $? "User supplied tool PANDOC=$tool_specified does not exist or is not executable" "$LINENO" 5 + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 +$as_echo "$tool_specified" >&6; } + fi + fi + fi + + fi + + + + # Now we can determine OpenJDK build and target platforms. This is required to # have early on. # Make sure we can run config.sub. @@ -15821,30 +16034,38 @@ $as_echo_n "checking compilation type... " >&6; } $as_echo "$COMPILE_TYPE" >&6; } + if test "x$OPENJDK_TARGET_OS" = xmacosx; then + OPENJDK_MODULE_TARGET_OS_NAME="macos" + else + OPENJDK_MODULE_TARGET_OS_NAME="$OPENJDK_TARGET_OS" + fi + + if test "x$OPENJDK_TARGET_CPU" = xx86_64; then + OPENJDK_MODULE_TARGET_OS_ARCH="amd64" + else + OPENJDK_MODULE_TARGET_OS_ARCH="$OPENJDK_TARGET_CPU" + fi + + OPENJDK_MODULE_TARGET_PLATFORM="${OPENJDK_MODULE_TARGET_OS_NAME}-${OPENJDK_MODULE_TARGET_OS_ARCH}" + + + if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then - REQUIRED_OS_NAME=SunOS - REQUIRED_OS_VERSION=5.10 + RELEASE_FILE_OS_NAME=SunOS fi if test "x$OPENJDK_TARGET_OS" = "xlinux"; then - REQUIRED_OS_NAME=Linux - REQUIRED_OS_VERSION=2.6 + RELEASE_FILE_OS_NAME=Linux fi if test "x$OPENJDK_TARGET_OS" = "xwindows"; then - REQUIRED_OS_NAME=Windows - if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then - REQUIRED_OS_VERSION=5.2 - else - REQUIRED_OS_VERSION=5.1 - fi + RELEASE_FILE_OS_NAME=Windows fi - if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then - REQUIRED_OS_NAME=Darwin - REQUIRED_OS_VERSION=11.2 + if test "x$OPENJDK_TARGET_OS" = xmacosx; then + RELEASE_FILE_OS_NAME="Darwin" fi if test "x$OPENJDK_TARGET_OS" = "xaix"; then - REQUIRED_OS_NAME=AIX - REQUIRED_OS_VERSION=7.1 + RELEASE_FILE_OS_NAME="AIX" fi + RELEASE_FILE_OS_ARCH=${OPENJDK_TARGET_CPU} @@ -16200,8 +16421,8 @@ $as_echo "$as_me: Your cygwin is too old. You are running $CYGWIN_VERSION, but a fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } - # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away - cygwin_winpath_root=`cd / ; cmd /c cd | $GREP ".*"` + # The cmd output ends with Windows line endings (CR/LF) + cygwin_winpath_root=`cd / ; cmd /c cd | $TR -d '\r\n'` # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 @@ -22267,6 +22488,203 @@ $as_echo "$tool_specified" >&6; } + # Publish this variable in the help. + + + if [ -z "${DOT+x}" ]; then + # The variable is not set by user, try to locate tool using the code snippet + for ac_prog in dot +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_DOT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $DOT in + [\\/]* | ?:[\\/]*) + ac_cv_path_DOT="$DOT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +DOT=$ac_cv_path_DOT +if test -n "$DOT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 +$as_echo "$DOT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DOT" && break +done + + else + # The variable is set, but is it from the command line or the environment? + + # Try to remove the string !DOT! from our list. + try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DOT!/} + if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then + # If it failed, the variable was not from the command line. Ignore it, + # but warn the user (except for BASH, which is always set by the calling BASH). + if test "xDOT" != xBASH; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DOT from the environment. Use command line variables instead." >&5 +$as_echo "$as_me: WARNING: Ignoring value of DOT from the environment. Use command line variables instead." >&2;} + fi + # Try to locate tool using the code snippet + for ac_prog in dot +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_DOT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $DOT in + [\\/]* | ?:[\\/]*) + ac_cv_path_DOT="$DOT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +DOT=$ac_cv_path_DOT +if test -n "$DOT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 +$as_echo "$DOT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DOT" && break +done + + else + # If it succeeded, then it was overridden by the user. We will use it + # for the tool. + + # First remove it from the list of overridden variables, so we can test + # for unknown variables in the end. + CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" + + # Check if we try to supply an empty value + if test "x$DOT" = x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DOT= (no value)" >&5 +$as_echo "$as_me: Setting user supplied tool DOT= (no value)" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DOT" >&5 +$as_echo_n "checking for DOT... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 +$as_echo "disabled" >&6; } + else + # Check if the provided tool contains a complete path. + tool_specified="$DOT" + tool_basename="${tool_specified##*/}" + if test "x$tool_basename" = "x$tool_specified"; then + # A command without a complete path is provided, search $PATH. + { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DOT=$tool_basename" >&5 +$as_echo "$as_me: Will search for user supplied tool DOT=$tool_basename" >&6;} + # Extract the first word of "$tool_basename", so it can be a program name with args. +set dummy $tool_basename; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_DOT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $DOT in + [\\/]* | ?:[\\/]*) + ac_cv_path_DOT="$DOT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +DOT=$ac_cv_path_DOT +if test -n "$DOT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 +$as_echo "$DOT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + if test "x$DOT" = x; then + as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 + fi + else + # Otherwise we believe it is a complete path. Use it as it is. + { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DOT=$tool_specified" >&5 +$as_echo "$as_me: Will use user supplied tool DOT=$tool_specified" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DOT" >&5 +$as_echo_n "checking for DOT... " >&6; } + if test ! -x "$tool_specified"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 +$as_echo "not found" >&6; } + as_fn_error $? "User supplied tool DOT=$tool_specified does not exist or is not executable" "$LINENO" 5 + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 +$as_echo "$tool_specified" >&6; } + fi + fi + fi + + fi + + + + # Publish this variable in the help. @@ -22856,6 +23274,203 @@ $as_echo "$tool_specified" >&6; } fi + + + # Publish this variable in the help. + + + if [ -z "${FLOCK+x}" ]; then + # The variable is not set by user, try to locate tool using the code snippet + for ac_prog in flock +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_FLOCK+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $FLOCK in + [\\/]* | ?:[\\/]*) + ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +FLOCK=$ac_cv_path_FLOCK +if test -n "$FLOCK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 +$as_echo "$FLOCK" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$FLOCK" && break +done + + else + # The variable is set, but is it from the command line or the environment? + + # Try to remove the string !FLOCK! from our list. + try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FLOCK!/} + if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then + # If it failed, the variable was not from the command line. Ignore it, + # but warn the user (except for BASH, which is always set by the calling BASH). + if test "xFLOCK" != xBASH; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FLOCK from the environment. Use command line variables instead." >&5 +$as_echo "$as_me: WARNING: Ignoring value of FLOCK from the environment. Use command line variables instead." >&2;} + fi + # Try to locate tool using the code snippet + for ac_prog in flock +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_FLOCK+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $FLOCK in + [\\/]* | ?:[\\/]*) + ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +FLOCK=$ac_cv_path_FLOCK +if test -n "$FLOCK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 +$as_echo "$FLOCK" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$FLOCK" && break +done + + else + # If it succeeded, then it was overridden by the user. We will use it + # for the tool. + + # First remove it from the list of overridden variables, so we can test + # for unknown variables in the end. + CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" + + # Check if we try to supply an empty value + if test "x$FLOCK" = x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FLOCK= (no value)" >&5 +$as_echo "$as_me: Setting user supplied tool FLOCK= (no value)" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FLOCK" >&5 +$as_echo_n "checking for FLOCK... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 +$as_echo "disabled" >&6; } + else + # Check if the provided tool contains a complete path. + tool_specified="$FLOCK" + tool_basename="${tool_specified##*/}" + if test "x$tool_basename" = "x$tool_specified"; then + # A command without a complete path is provided, search $PATH. + { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FLOCK=$tool_basename" >&5 +$as_echo "$as_me: Will search for user supplied tool FLOCK=$tool_basename" >&6;} + # Extract the first word of "$tool_basename", so it can be a program name with args. +set dummy $tool_basename; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_FLOCK+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $FLOCK in + [\\/]* | ?:[\\/]*) + ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +FLOCK=$ac_cv_path_FLOCK +if test -n "$FLOCK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 +$as_echo "$FLOCK" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + if test "x$FLOCK" = x; then + as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 + fi + else + # Otherwise we believe it is a complete path. Use it as it is. + { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FLOCK=$tool_specified" >&5 +$as_echo "$as_me: Will use user supplied tool FLOCK=$tool_specified" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FLOCK" >&5 +$as_echo_n "checking for FLOCK... " >&6; } + if test ! -x "$tool_specified"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 +$as_echo "not found" >&6; } + as_fn_error $? "User supplied tool FLOCK=$tool_specified does not exist or is not executable" "$LINENO" 5 + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 +$as_echo "$tool_specified" >&6; } + fi + fi + fi + + fi + + # Dtrace is usually found in /usr/sbin on Solaris, but that directory may not # be in the user path. @@ -24092,6 +24707,20 @@ $as_echo "$tool_specified" >&6; } fi + # Check bash version + # Extra [ ] to stop m4 mangling + BASH_VER=`$BASH --version | $SED -n -e 's/^.*bash.*ersion *\([0-9.]*\).*$/\1/ p'` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking bash version" >&5 +$as_echo_n "checking bash version... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH_VER" >&5 +$as_echo "$BASH_VER" >&6; } + + BASH_MAJOR=`$ECHO $BASH_VER | $CUT -d . -f 1` + BASH_MINOR=`$ECHO $BASH_VER | $CUT -d . -f 2` + if test $BASH_MAJOR -lt 3 || (test $BASH_MAJOR -eq 3 && test $BASH_MINOR -lt 2); then + as_fn_error $? "bash version 3.2 or better is required" "$LINENO" 5 + fi + # Test if bash supports pipefail. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 $as_echo_n "checking if bash supports pipefail... " >&6; } @@ -24306,6 +24935,101 @@ $as_echo "no" >&6; } + # Should we build the complete docs, or just a lightweight version? + # Check whether --enable-full-docs was given. +if test "${enable_full_docs+set}" = set; then : + enableval=$enable_full_docs; +fi + + + # Verify dependencies + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for graphviz dot" >&5 +$as_echo_n "checking for graphviz dot... " >&6; } + if test "x$DOT" != "x"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, cannot generate full docs" >&5 +$as_echo "no, cannot generate full docs" >&6; } + FULL_DOCS_DEP_MISSING=true + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pandoc" >&5 +$as_echo_n "checking for pandoc... " >&6; } + if test "x$PANDOC" != "x"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, cannot generate full docs" >&5 +$as_echo "no, cannot generate full docs" >&6; } + FULL_DOCS_DEP_MISSING=true + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking full docs" >&5 +$as_echo_n "checking full docs... " >&6; } + if test "x$enable_full_docs" = xyes; then + if test "x$FULL_DOCS_DEP_MISSING" = "xtrue"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 +$as_echo "no, missing dependencies" >&6; } + + # Print a helpful message on how to acquire the necessary build dependency. + # dot is the help tag: freetype, cups, alsa etc + MISSING_DEPENDENCY=dot + + if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then + cygwin_help $MISSING_DEPENDENCY + elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then + msys_help $MISSING_DEPENDENCY + else + PKGHANDLER_COMMAND= + + case $PKGHANDLER in + apt-get) + apt_help $MISSING_DEPENDENCY ;; + yum) + yum_help $MISSING_DEPENDENCY ;; + brew) + brew_help $MISSING_DEPENDENCY ;; + port) + port_help $MISSING_DEPENDENCY ;; + pkgutil) + pkgutil_help $MISSING_DEPENDENCY ;; + pkgadd) + pkgadd_help $MISSING_DEPENDENCY ;; + esac + + if test "x$PKGHANDLER_COMMAND" != x; then + HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." + fi + fi + + as_fn_error $? "Cannot enable full docs with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 + else + ENABLE_FULL_DOCS=true + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 +$as_echo "yes, forced" >&6; } + fi + elif test "x$enable_full_docs" = xno; then + ENABLE_FULL_DOCS=false + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 +$as_echo "no, forced" >&6; } + elif test "x$enable_full_docs" = x; then + # Check for prerequisites + if test "x$FULL_DOCS_DEP_MISSING" = xtrue; then + ENABLE_FULL_DOCS=false + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 +$as_echo "no, missing dependencies" >&6; } + else + ENABLE_FULL_DOCS=true + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 +$as_echo "yes, dependencies present" >&6; } + fi + else + as_fn_error $? "--enable-full-docs can only take yes or no" "$LINENO" 5 + fi + + + # Choose cacerts source file # Check whether --with-cacerts-file was given. @@ -30692,7 +31416,7 @@ $as_echo "no" >&6; } # Check if the boot jdk is 32 or 64 bit - if "$JAVA" -d64 -version > /dev/null 2>&1; then + if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then BOOT_JDK_BITS="64" else BOOT_JDK_BITS="32" @@ -33124,10 +33848,9 @@ done if test -n "$TOOLCHAIN_PATH"; then PATH_save="$PATH" PATH="$TOOLCHAIN_PATH" - for ac_prog in $SEARCH_LIST -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. +set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : @@ -33166,20 +33889,73 @@ $as_echo "no" >&6; } fi - test -n "$TOOLCHAIN_PATH_CC" && break +fi +if test -z "$ac_cv_path_TOOLCHAIN_PATH_CC"; then + ac_pt_TOOLCHAIN_PATH_CC=$TOOLCHAIN_PATH_CC + # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. +set dummy $SEARCH_LIST; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $ac_pt_TOOLCHAIN_PATH_CC in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$ac_pt_TOOLCHAIN_PATH_CC" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_TOOLCHAIN_PATH_CC=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC +if test -n "$ac_pt_TOOLCHAIN_PATH_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CC" >&5 +$as_echo "$ac_pt_TOOLCHAIN_PATH_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_pt_TOOLCHAIN_PATH_CC" = x; then + TOOLCHAIN_PATH_CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + TOOLCHAIN_PATH_CC=$ac_pt_TOOLCHAIN_PATH_CC + fi +else + TOOLCHAIN_PATH_CC="$ac_cv_path_TOOLCHAIN_PATH_CC" +fi CC=$TOOLCHAIN_PATH_CC PATH="$PATH_save" fi - # AC_PATH_PROGS can't be run multiple times with the same variable, + # AC_PATH_TOOL can't be run multiple times with the same variable, # so create a new name for this run. if test "x$CC" = x; then - for ac_prog in $SEARCH_LIST -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. +set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_POTENTIAL_CC+:} false; then : @@ -33218,8 +33994,62 @@ $as_echo "no" >&6; } fi - test -n "$POTENTIAL_CC" && break +fi +if test -z "$ac_cv_path_POTENTIAL_CC"; then + ac_pt_POTENTIAL_CC=$POTENTIAL_CC + # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. +set dummy $SEARCH_LIST; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_ac_pt_POTENTIAL_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $ac_pt_POTENTIAL_CC in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_POTENTIAL_CC="$ac_pt_POTENTIAL_CC" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_pt_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_POTENTIAL_CC=$ac_cv_path_ac_pt_POTENTIAL_CC +if test -n "$ac_pt_POTENTIAL_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CC" >&5 +$as_echo "$ac_pt_POTENTIAL_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_pt_POTENTIAL_CC" = x; then + POTENTIAL_CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + POTENTIAL_CC=$ac_pt_POTENTIAL_CC + fi +else + POTENTIAL_CC="$ac_cv_path_POTENTIAL_CC" +fi CC=$POTENTIAL_CC fi @@ -34425,10 +35255,9 @@ done if test -n "$TOOLCHAIN_PATH"; then PATH_save="$PATH" PATH="$TOOLCHAIN_PATH" - for ac_prog in $SEARCH_LIST -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. +set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : @@ -34467,20 +35296,73 @@ $as_echo "no" >&6; } fi - test -n "$TOOLCHAIN_PATH_CXX" && break +fi +if test -z "$ac_cv_path_TOOLCHAIN_PATH_CXX"; then + ac_pt_TOOLCHAIN_PATH_CXX=$TOOLCHAIN_PATH_CXX + # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. +set dummy $SEARCH_LIST; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $ac_pt_TOOLCHAIN_PATH_CXX in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$ac_pt_TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_TOOLCHAIN_PATH_CXX=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX +if test -n "$ac_pt_TOOLCHAIN_PATH_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CXX" >&5 +$as_echo "$ac_pt_TOOLCHAIN_PATH_CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_pt_TOOLCHAIN_PATH_CXX" = x; then + TOOLCHAIN_PATH_CXX="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + TOOLCHAIN_PATH_CXX=$ac_pt_TOOLCHAIN_PATH_CXX + fi +else + TOOLCHAIN_PATH_CXX="$ac_cv_path_TOOLCHAIN_PATH_CXX" +fi CXX=$TOOLCHAIN_PATH_CXX PATH="$PATH_save" fi - # AC_PATH_PROGS can't be run multiple times with the same variable, + # AC_PATH_TOOL can't be run multiple times with the same variable, # so create a new name for this run. if test "x$CXX" = x; then - for ac_prog in $SEARCH_LIST -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. +set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_POTENTIAL_CXX+:} false; then : @@ -34519,8 +35401,62 @@ $as_echo "no" >&6; } fi - test -n "$POTENTIAL_CXX" && break +fi +if test -z "$ac_cv_path_POTENTIAL_CXX"; then + ac_pt_POTENTIAL_CXX=$POTENTIAL_CXX + # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. +set dummy $SEARCH_LIST; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_ac_pt_POTENTIAL_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $ac_pt_POTENTIAL_CXX in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_POTENTIAL_CXX="$ac_pt_POTENTIAL_CXX" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_pt_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_POTENTIAL_CXX=$ac_cv_path_ac_pt_POTENTIAL_CXX +if test -n "$ac_pt_POTENTIAL_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CXX" >&5 +$as_echo "$ac_pt_POTENTIAL_CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_pt_POTENTIAL_CXX" = x; then + POTENTIAL_CXX="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + POTENTIAL_CXX=$ac_pt_POTENTIAL_CXX + fi +else + POTENTIAL_CXX="$ac_cv_path_POTENTIAL_CXX" +fi CXX=$POTENTIAL_CXX fi @@ -47875,173 +48811,63 @@ $as_echo "yes" >&6; } # Check whether --with-jtreg was given. if test "${with_jtreg+set}" = set; then : withval=$with_jtreg; -else - with_jtreg=no fi if test "x$with_jtreg" = xno; then # jtreg disabled - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 -$as_echo_n "checking for jtreg... " >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 +$as_echo_n "checking for jtreg test harness... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabled" >&5 +$as_echo "no, disabled" >&6; } + elif test "x$with_jtreg" != xyes && test "x$with_jtreg" != x; then + # An explicit path is specified, use it. + JT_HOME="$with_jtreg" + if test ! -d "$JT_HOME"; then + as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg does not exist" "$LINENO" 5 + fi + + if test ! -e "$JT_HOME/lib/jtreg.jar"; then + as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg is not a valid jtreg home" "$LINENO" 5 + fi + + JTREGEXE="$JT_HOME/bin/jtreg" + if test ! -x "$JTREGEXE"; then + as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg does not contain valid jtreg executable" "$LINENO" 5 + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 +$as_echo_n "checking for jtreg test harness... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JT_HOME" >&5 +$as_echo "$JT_HOME" >&6; } else - if test "x$with_jtreg" != xyes; then - # with path specified. - JT_HOME="$with_jtreg" - fi - + # Try to locate jtreg if test "x$JT_HOME" != x; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 -$as_echo_n "checking for jtreg... " >&6; } - - # use JT_HOME enviroment var. - - # Only process if variable expands to non-empty - - if test "x$JT_HOME" != x; then - if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then - - # Input might be given as Windows format, start by converting to - # unix format. - path="$JT_HOME" - 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 JT_HOME, which resolves as \"$path\", is invalid." >&5 -$as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} - as_fn_error $? "Cannot locate the the path of JT_HOME" "$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-style (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 - JT_HOME="$new_path" - { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 -$as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} - fi - - elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then - - path="$JT_HOME" - 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 - JT_HOME="$new_path" - { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 -$as_echo "$as_me: Rewriting JT_HOME 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 unix platform. Hooray! :) - path="$JT_HOME" - has_space=`$ECHO "$path" | $GREP " "` - if test "x$has_space" != x; then - { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 -$as_echo "$as_me: The path of JT_HOME, 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 JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 - fi - - if test -d "$path"; then - JT_HOME="`cd "$path"; $THEPWDCMD -L`" + # JT_HOME set in environment, use it + if test ! -d "$JT_HOME"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME pointing to invalid directory: $JT_HOME" >&5 +$as_echo "$as_me: WARNING: Ignoring JT_HOME pointing to invalid directory: $JT_HOME" >&2;} + JT_HOME= else - dir="`$DIRNAME "$path"`" - base="`$BASENAME "$path"`" - JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" + if test ! -e "$JT_HOME/lib/jtreg.jar"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME" >&5 +$as_echo "$as_me: WARNING: Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME" >&2;} + JT_HOME= + elif test ! -x "$JT_HOME/bin/jtreg"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME" >&5 +$as_echo "$as_me: WARNING: Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME" >&2;} + JT_HOME= + else + JTREGEXE="$JT_HOME/bin/jtreg" + { $as_echo "$as_me:${as_lineno-$LINENO}: Located jtreg using JT_HOME from environment" >&5 +$as_echo "$as_me: Located jtreg using JT_HOME from environment" >&6;} + fi fi fi - fi - - - # jtreg win32 script works for everybody - JTREGEXE="$JT_HOME/bin/jtreg" - - if test ! -f "$JTREGEXE"; then - as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5 - fi - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 -$as_echo "$JTREGEXE" >&6; } - else - # try to find jtreg on path + if test "x$JT_HOME" = x; then + # JT_HOME is not set in environment, or was deemed invalid. + # Try to find jtreg on path # Publish this variable in the help. @@ -48239,13 +49065,451 @@ $as_echo "$tool_specified" >&6; } fi + if test "x$JTREGEXE" != x; then + # That's good, now try to derive JT_HOME + JT_HOME=`(cd $($DIRNAME $JTREGEXE)/.. && pwd)` + if test ! -e "$JT_HOME/lib/jtreg.jar"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring jtreg from path since a valid jtreg home cannot be found" >&5 +$as_echo "$as_me: WARNING: Ignoring jtreg from path since a valid jtreg home cannot be found" >&2;} + JT_HOME= + JTREGEXE= + else + { $as_echo "$as_me:${as_lineno-$LINENO}: Located jtreg using jtreg executable in path" >&5 +$as_echo "$as_me: Located jtreg using jtreg executable in path" >&6;} + fi + fi + fi - if test "x$JTREGEXE" = x; then - as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 +$as_echo_n "checking for jtreg test harness... " >&6; } + if test "x$JT_HOME" != x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JT_HOME" >&5 +$as_echo "$JT_HOME" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found" >&5 +$as_echo "no, not found" >&6; } + + if test "x$with_jtreg" = xyes; then + as_fn_error $? "--with-jtreg was specified, but no jtreg found." "$LINENO" 5 + fi + fi fi - JT_HOME="`$DIRNAME $JTREGEXE`" + # Only process if variable expands to non-empty + + if test "x$JTREGEXE" != x; then + if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then + + # First separate the path from the arguments. This will split at the first + # space. + complete="$JTREGEXE" + path="${complete%% *}" + tmp="$complete EOL" + arguments="${tmp#* }" + + # Input might be given as Windows format, start by converting to + # unix format. + new_path=`$CYGPATH -u "$path"` + + # Now try to locate executable using which + new_path=`$WHICH "$new_path" 2> /dev/null` + # bat and cmd files are not always considered executable in cygwin causing which + # to not find them + if test "x$new_path" = x \ + && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ + && test "x`$LS \"$path\" 2>/dev/null`" != x; then + new_path=`$CYGPATH -u "$path"` + fi + if test "x$new_path" = x; then + # Oops. Which didn't find the executable. + # The splitting of arguments from the executable at a space might have been incorrect, + # since paths with space are more likely in Windows. Give it another try with the whole + # argument. + path="$complete" + arguments="EOL" + new_path=`$CYGPATH -u "$path"` + new_path=`$WHICH "$new_path" 2> /dev/null` + # bat and cmd files are not always considered executable in cygwin causing which + # to not find them + if test "x$new_path" = x \ + && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ + && test "x`$LS \"$path\" 2>/dev/null`" != x; then + new_path=`$CYGPATH -u "$path"` + fi + if test "x$new_path" = x; then + # It's still not found. Now this is an unrecoverable error. + { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 +$as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} + has_space=`$ECHO "$complete" | $GREP " "` + if test "x$has_space" != x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 +$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} + fi + as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 + fi + fi + + # 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 presence. + # 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 + # Short path failed, file does not exist as specified. + # Try adding .exe or .cmd + if test -f "${new_path}.exe"; then + input_to_shortpath="${new_path}.exe" + elif test -f "${new_path}.cmd"; then + input_to_shortpath="${new_path}.cmd" + else + { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$new_path\", is invalid." >&5 +$as_echo "$as_me: The path of JTREGEXE, which resolves as \"$new_path\", is invalid." >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 +$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} + as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 + fi + else + input_to_shortpath="$new_path" + fi + + # Call helper function which possibly converts this using DOS-style short mode. + # If so, the updated path is stored in $new_path. + new_path="$input_to_shortpath" + + input_path="$input_to_shortpath" + # 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-style (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 $input_to_shortpath | $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 + + # remove trailing .exe if any + new_path="${new_path/%.exe/}" + + elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then + + # First separate the path from the arguments. This will split at the first + # space. + complete="$JTREGEXE" + path="${complete%% *}" + tmp="$complete EOL" + arguments="${tmp#* }" + + # Input might be given as Windows format, start by converting to + # unix format. + new_path="$path" + + 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 + + + # Now try to locate executable using which + new_path=`$WHICH "$new_path" 2> /dev/null` + + if test "x$new_path" = x; then + # Oops. Which didn't find the executable. + # The splitting of arguments from the executable at a space might have been incorrect, + # since paths with space are more likely in Windows. Give it another try with the whole + # argument. + path="$complete" + arguments="EOL" + new_path="$path" + + 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 + + + new_path=`$WHICH "$new_path" 2> /dev/null` + # bat and cmd files are not always considered executable in MSYS causing which + # to not find them + if test "x$new_path" = x \ + && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ + && test "x`$LS \"$path\" 2>/dev/null`" != x; then + new_path="$path" + + 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 + + fi + + if test "x$new_path" = x; then + # It's still not found. Now this is an unrecoverable error. + { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 +$as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} + has_space=`$ECHO "$complete" | $GREP " "` + if test "x$has_space" != x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 +$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} + fi + as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 + fi + fi + + # Now new_path has a complete unix path to the binary + if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then + # Keep paths in /bin as-is, but remove trailing .exe if any + new_path="${new_path/%.exe/}" + # Do not save /bin paths to all_fixpath_prefixes! + else + # Not in mixed or Windows style, start by that. + new_path=`cmd //c echo $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 \) + new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + fi + + # Output is in $new_path + + 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 + + # remove trailing .exe if any + new_path="${new_path/%.exe/}" + + # 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}") + fi + + else + # We're on a unix platform. Hooray! :) + # First separate the path from the arguments. This will split at the first + # space. + complete="$JTREGEXE" + path="${complete%% *}" + tmp="$complete EOL" + arguments="${tmp#* }" + + # Cannot rely on the command "which" here since it doesn't always work. + is_absolute_path=`$ECHO "$path" | $GREP ^/` + if test -z "$is_absolute_path"; then + # Path to executable is not absolute. Find it. + IFS_save="$IFS" + IFS=: + for p in $PATH; do + if test -f "$p/$path" && test -x "$p/$path"; then + new_path="$p/$path" + break + fi + done + IFS="$IFS_save" + else + # This is an absolute path, we can use it without further modifications. + new_path="$path" + fi + + if test "x$new_path" = x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 +$as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} + has_space=`$ECHO "$complete" | $GREP " "` + if test "x$has_space" != x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 +$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} + fi + as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 + fi + fi + + # Now join together the path and the arguments once again + if test "x$arguments" != xEOL; then + new_complete="$new_path ${arguments% *}" + else + new_complete="$new_path" + fi + + if test "x$complete" != "x$new_complete"; then + JTREGEXE="$new_complete" + { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JTREGEXE to \"$new_complete\"" >&5 +$as_echo "$as_me: Rewriting JTREGEXE to \"$new_complete\"" >&6;} + fi + fi + + + # Only process if variable expands to non-empty + + if test "x$JT_HOME" != x; then + if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then + + # Input might be given as Windows format, start by converting to + # unix format. + path="$JT_HOME" + 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 JT_HOME, which resolves as \"$path\", is invalid." >&5 +$as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} + as_fn_error $? "Cannot locate the the path of JT_HOME" "$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-style (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 + JT_HOME="$new_path" + { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 +$as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} + fi + + elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then + + path="$JT_HOME" + 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 + JT_HOME="$new_path" + { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 +$as_echo "$as_me: Rewriting JT_HOME 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 unix platform. Hooray! :) + path="$JT_HOME" + has_space=`$ECHO "$path" | $GREP " "` + if test "x$has_space" != x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 +$as_echo "$as_me: The path of JT_HOME, 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 JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 + fi + + if test -d "$path"; then + JT_HOME="`cd "$path"; $THEPWDCMD -L`" + else + dir="`$DIRNAME "$path"`" + base="`$BASENAME "$path"`" + JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" + fi fi fi @@ -49060,7 +50324,7 @@ $as_echo "$ac_cv_c_bigendian" >&6; } SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" fi - SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' + SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' @@ -49080,7 +50344,7 @@ $as_echo "$ac_cv_c_bigendian" >&6; } # Linking is different on MacOSX PICFLAG='' SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" - SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' + SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' @@ -52629,12 +53893,12 @@ $as_echo "no, forced" >&6; } # Only enable AOT on linux-X64. if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = "xlinux-x86_64"; then if test -e "$HOTSPOT_TOPDIR/src/jdk.aot"; then - if test -e "$HOTSPOT_TOPDIR/src/jdk.vm.compiler"; then + if test -e "$HOTSPOT_TOPDIR/src/jdk.internal.vm.compiler"; then ENABLE_AOT="true" else ENABLE_AOT="false" if test "x$enable_aot" = "xyes"; then - as_fn_error $? "Cannot build AOT without hotspot/src/jdk.vm.compiler sources. Remove --enable-aot." "$LINENO" 5 + as_fn_error $? "Cannot build AOT without hotspot/src/jdk.internal.vm.compiler sources. Remove --enable-aot." "$LINENO" 5 fi fi else @@ -64365,8 +65629,8 @@ $as_echo "$JVM_FEATURES" >&6; } JVM_FEATURES_jvmci="" fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jdk.vm.compiler should be built" >&5 -$as_echo_n "checking if jdk.vm.compiler should be built... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jdk.internal.vm.compiler should be built" >&5 +$as_echo_n "checking if jdk.internal.vm.compiler should be built... " >&6; } if [[ " $JVM_FEATURES " =~ " graal " ]] ; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 $as_echo "yes, forced" >&6; } @@ -64998,24 +66262,8 @@ fi if test "$MEMORY_SIZE" -gt "3000"; then - - $ECHO "Check if jvm arg is ok: -d64" >&5 - $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5 - OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1` - FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` - FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` - if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then - SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -d64" - JVM_ARG_OK=true - else - $ECHO "Arg failed:" >&5 - $ECHO "$OUTPUT" >&5 - JVM_ARG_OK=false - fi - - if test "$JVM_ARG_OK" = true; then + if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then JVM_64BIT=true - JVM_ARG_OK=false fi fi diff --git a/common/autoconf/hotspot.m4 b/common/autoconf/hotspot.m4 index b295b015a9f..acf2a5fe185 100644 --- a/common/autoconf/hotspot.m4 +++ b/common/autoconf/hotspot.m4 @@ -215,12 +215,12 @@ AC_DEFUN_ONCE([HOTSPOT_ENABLE_DISABLE_AOT], # Only enable AOT on linux-X64. if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = "xlinux-x86_64"; then if test -e "$HOTSPOT_TOPDIR/src/jdk.aot"; then - if test -e "$HOTSPOT_TOPDIR/src/jdk.vm.compiler"; then + if test -e "$HOTSPOT_TOPDIR/src/jdk.internal.vm.compiler"; then ENABLE_AOT="true" else ENABLE_AOT="false" if test "x$enable_aot" = "xyes"; then - AC_MSG_ERROR([Cannot build AOT without hotspot/src/jdk.vm.compiler sources. Remove --enable-aot.]) + AC_MSG_ERROR([Cannot build AOT without hotspot/src/jdk.internal.vm.compiler sources. Remove --enable-aot.]) fi fi else @@ -327,7 +327,7 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_JVM_FEATURES], JVM_FEATURES_jvmci="" fi - AC_MSG_CHECKING([if jdk.vm.compiler should be built]) + AC_MSG_CHECKING([if jdk.internal.vm.compiler should be built]) if HOTSPOT_CHECK_JVM_FEATURE(graal); then AC_MSG_RESULT([yes, forced]) if test "x$JVM_FEATURES_jvmci" != "xjvmci" ; then diff --git a/common/autoconf/jdk-options.m4 b/common/autoconf/jdk-options.m4 index bb2a49f4980..73e2d74ecd5 100644 --- a/common/autoconf/jdk-options.m4 +++ b/common/autoconf/jdk-options.m4 @@ -154,6 +154,55 @@ AC_DEFUN_ONCE([JDKOPT_SETUP_JDK_OPTIONS], AC_SUBST(ENABLE_HEADLESS_ONLY) + # Should we build the complete docs, or just a lightweight version? + AC_ARG_ENABLE([full-docs], [AS_HELP_STRING([--enable-full-docs], + [build complete documentation @<:@enabled if all tools found@:>@])]) + + # Verify dependencies + AC_MSG_CHECKING([for graphviz dot]) + if test "x$DOT" != "x"; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no, cannot generate full docs]) + FULL_DOCS_DEP_MISSING=true + fi + + AC_MSG_CHECKING([for pandoc]) + if test "x$PANDOC" != "x"; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no, cannot generate full docs]) + FULL_DOCS_DEP_MISSING=true + fi + + AC_MSG_CHECKING([full docs]) + if test "x$enable_full_docs" = xyes; then + if test "x$FULL_DOCS_DEP_MISSING" = "xtrue"; then + AC_MSG_RESULT([no, missing dependencies]) + HELP_MSG_MISSING_DEPENDENCY([dot]) + AC_MSG_ERROR([Cannot enable full docs with missing dependencies. See above. $HELP_MSG]) + else + ENABLE_FULL_DOCS=true + AC_MSG_RESULT([yes, forced]) + fi + elif test "x$enable_full_docs" = xno; then + ENABLE_FULL_DOCS=false + AC_MSG_RESULT([no, forced]) + elif test "x$enable_full_docs" = x; then + # Check for prerequisites + if test "x$FULL_DOCS_DEP_MISSING" = xtrue; then + ENABLE_FULL_DOCS=false + AC_MSG_RESULT([no, missing dependencies]) + else + ENABLE_FULL_DOCS=true + AC_MSG_RESULT([yes, dependencies present]) + fi + else + AC_MSG_ERROR([--enable-full-docs can only take yes or no]) + fi + + AC_SUBST(ENABLE_FULL_DOCS) + # Choose cacerts source file AC_ARG_WITH(cacerts-file, [AS_HELP_STRING([--with-cacerts-file], [specify alternative cacerts file])]) diff --git a/common/autoconf/platform.m4 b/common/autoconf/platform.m4 index 61010279a0e..0dbf74cbe12 100644 --- a/common/autoconf/platform.m4 +++ b/common/autoconf/platform.m4 @@ -436,32 +436,42 @@ AC_DEFUN([PLATFORM_SETUP_LEGACY_VARS_HELPER], AC_DEFUN([PLATFORM_SET_RELEASE_FILE_OS_VALUES], [ if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then - REQUIRED_OS_NAME=SunOS - REQUIRED_OS_VERSION=5.10 + RELEASE_FILE_OS_NAME=SunOS fi if test "x$OPENJDK_TARGET_OS" = "xlinux"; then - REQUIRED_OS_NAME=Linux - REQUIRED_OS_VERSION=2.6 + RELEASE_FILE_OS_NAME=Linux fi if test "x$OPENJDK_TARGET_OS" = "xwindows"; then - REQUIRED_OS_NAME=Windows - if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then - REQUIRED_OS_VERSION=5.2 - else - REQUIRED_OS_VERSION=5.1 - fi + RELEASE_FILE_OS_NAME=Windows fi - if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then - REQUIRED_OS_NAME=Darwin - REQUIRED_OS_VERSION=11.2 + if test "x$OPENJDK_TARGET_OS" = xmacosx; then + RELEASE_FILE_OS_NAME="Darwin" fi if test "x$OPENJDK_TARGET_OS" = "xaix"; then - REQUIRED_OS_NAME=AIX - REQUIRED_OS_VERSION=7.1 + RELEASE_FILE_OS_NAME="AIX" + fi + RELEASE_FILE_OS_ARCH=${OPENJDK_TARGET_CPU} + + AC_SUBST(RELEASE_FILE_OS_NAME) + AC_SUBST(RELEASE_FILE_OS_ARCH) +]) + +AC_DEFUN([PLATFORM_SET_MODULE_TARGET_OS_VALUES], +[ + if test "x$OPENJDK_TARGET_OS" = xmacosx; then + OPENJDK_MODULE_TARGET_OS_NAME="macos" + else + OPENJDK_MODULE_TARGET_OS_NAME="$OPENJDK_TARGET_OS" fi - AC_SUBST(REQUIRED_OS_NAME) - AC_SUBST(REQUIRED_OS_VERSION) + if test "x$OPENJDK_TARGET_CPU" = xx86_64; then + OPENJDK_MODULE_TARGET_OS_ARCH="amd64" + else + OPENJDK_MODULE_TARGET_OS_ARCH="$OPENJDK_TARGET_CPU" + fi + + OPENJDK_MODULE_TARGET_PLATFORM="${OPENJDK_MODULE_TARGET_OS_NAME}-${OPENJDK_MODULE_TARGET_OS_ARCH}" + AC_SUBST(OPENJDK_MODULE_TARGET_PLATFORM) ]) #%%% Build and target systems %%% @@ -478,6 +488,7 @@ AC_DEFUN_ONCE([PLATFORM_SETUP_OPENJDK_BUILD_AND_TARGET], PLATFORM_EXTRACT_TARGET_AND_BUILD PLATFORM_SETUP_TARGET_CPU_BITS + PLATFORM_SET_MODULE_TARGET_OS_VALUES PLATFORM_SET_RELEASE_FILE_OS_VALUES PLATFORM_SETUP_LEGACY_VARS ]) diff --git a/common/autoconf/spec.gmk.in b/common/autoconf/spec.gmk.in index bb6d2209c41..a9dec3b1feb 100644 --- a/common/autoconf/spec.gmk.in +++ b/common/autoconf/spec.gmk.in @@ -48,7 +48,7 @@ MAKE := @MAKE@ # The default make arguments MAKE_ARGS = $(MAKE_LOG_FLAGS) -r -R -I $(TOPDIR)/make/common SPEC=$(SPEC) \ - MAKE_LOG_FLAGS="$(MAKE_LOG_FLAGS)" LOG_LEVEL=$(LOG_LEVEL) + MAKE_LOG_FLAGS="$(MAKE_LOG_FLAGS)" $(MAKE_LOG_VARS) OUTPUT_SYNC_SUPPORTED:=@OUTPUT_SYNC_SUPPORTED@ OUTPUT_SYNC:=@OUTPUT_SYNC@ @@ -101,9 +101,12 @@ OPENJDK_BUILD_CPU_ARCH:=@OPENJDK_BUILD_CPU_ARCH@ OPENJDK_BUILD_CPU_BITS:=@OPENJDK_BUILD_CPU_BITS@ OPENJDK_BUILD_CPU_ENDIAN:=@OPENJDK_BUILD_CPU_ENDIAN@ -# Legacy OS values for use in release file. -REQUIRED_OS_NAME:=@REQUIRED_OS_NAME@ -REQUIRED_OS_VERSION:=@REQUIRED_OS_VERSION@ +# Target platform value in ModuleTarget class file attribute. +OPENJDK_MODULE_TARGET_PLATFORM:=@OPENJDK_MODULE_TARGET_PLATFORM@ + +# OS_* properties in release file +RELEASE_FILE_OS_NAME:=@RELEASE_FILE_OS_NAME@ +RELEASE_FILE_OS_ARCH:=@RELEASE_FILE_OS_ARCH@ LIBM:=@LIBM@ LIBDL:=@LIBDL@ @@ -244,6 +247,8 @@ USE_PRECOMPILED_HEADER := @USE_PRECOMPILED_HEADER@ # Only build headless support or not ENABLE_HEADLESS_ONLY := @ENABLE_HEADLESS_ONLY@ +ENABLE_FULL_DOCS := @ENABLE_FULL_DOCS@ + # JDK_OUTPUTDIR specifies where a working jvm is built. # You can run $(JDK_OUTPUTDIR)/bin/java # Though the layout of the contents of $(JDK_OUTPUTDIR) is not @@ -266,9 +271,6 @@ BUNDLES_OUTPUTDIR=$(BUILD_OUTPUT)/bundles TESTMAKE_OUTPUTDIR=$(BUILD_OUTPUT)/test-make MAKESUPPORT_OUTPUTDIR=$(BUILD_OUTPUT)/make-support -# By default, output javadoc directly into image -JAVADOC_OUTPUTDIR = $(DOCS_IMAGE_DIR) - # This does not get overridden in a bootcycle build CONFIGURESUPPORT_OUTPUTDIR:=@CONFIGURESUPPORT_OUTPUTDIR@ BUILDJDK_OUTPUTDIR=$(BUILD_OUTPUT)/buildjdk @@ -574,20 +576,31 @@ BUILD_JAVA=@FIXPATH@ $(BUILD_JDK)/bin/java $(BUILD_JAVA_FLAGS) # Use ?= as this can be overridden from bootcycle-spec.gmk BOOT_JDK_MODULAR ?= @BOOT_JDK_MODULAR@ -INTERIM_OVERRIDE_MODULES := java.compiler jdk.compiler \ - jdk.jdeps jdk.javadoc jdk.rmic +INTERIM_LANGTOOLS_OVERRIDE_MODULES := java.compiler jdk.compiler \ + jdk.jdeps jdk.javadoc +INTERIM_RMIC_OVERRIDE_MODULES := jdk.rmic ifeq ($(BOOT_JDK_MODULAR), true) - INTERIM_OVERRIDE_MODULES_ARGS = $(foreach m, $(INTERIM_OVERRIDE_MODULES), \ + INTERIM_LANGTOOLS_OVERRIDE_MODULES_ARGS = $(foreach m, \ + $(INTERIM_LANGTOOLS_OVERRIDE_MODULES), \ --patch-module $m=$(BUILDTOOLS_OUTPUTDIR)/override_modules/$m) - INTERIM_LANGTOOLS_ARGS = $(INTERIM_OVERRIDE_MODULES_ARGS) + INTERIM_RMIC_OVERRIDE_MODULES_ARGS = $(foreach m, \ + $(INTERIM_LANGTOOLS_OVERRIDE_MODULES) \ + $(INTERIM_RMIC_OVERRIDE_MODULES), \ + --patch-module $m=$(BUILDTOOLS_OUTPUTDIR)/override_modules/$m) + INTERIM_LANGTOOLS_ARGS = $(INTERIM_LANGTOOLS_OVERRIDE_MODULES_ARGS) JAVAC_MAIN_CLASS = -m jdk.compiler/com.sun.tools.javac.Main JAVADOC_MAIN_CLASS = -m jdk.javadoc/jdk.javadoc.internal.tool.Main else - INTERIM_OVERRIDE_MODULES_ARGS = \ + INTERIM_LANGTOOLS_OVERRIDE_MODULES_ARGS = \ -Xbootclasspath/p:$(call PathList, \ $(addprefix $(BUILDTOOLS_OUTPUTDIR)/override_modules/, \ - $(INTERIM_OVERRIDE_MODULES))) - INTERIM_LANGTOOLS_ARGS = $(INTERIM_OVERRIDE_MODULES_ARGS) \ + $(INTERIM_LANGTOOLS_OVERRIDE_MODULES))) + INTERIM_RMIC_OVERRIDE_MODULES_ARGS = \ + -Xbootclasspath/p:$(call PathList, \ + $(addprefix $(BUILDTOOLS_OUTPUTDIR)/override_modules/, \ + $(INTERIM_LANGTOOLS_OVERRIDE_MODULES) \ + $(INTERIM_RMIC_OVERRIDE_MODULES))) + INTERIM_LANGTOOLS_ARGS = $(INTERIM_LANGTOOLS_OVERRIDE_MODULES_ARGS) \ -cp $(BUILDTOOLS_OUTPUTDIR)/override_modules/jdk.compiler JAVAC_MAIN_CLASS = com.sun.tools.javac.Main JAVADOC_MAIN_CLASS = jdk.javadoc.internal.tool.Main @@ -625,6 +638,7 @@ DIRNAME:=@DIRNAME@ DSYMUTIL:=@DSYMUTIL@ FIND:=@FIND@ FIND_DELETE:=@FIND_DELETE@ +FLOCK:=@FLOCK@ ECHO:=@ECHO@ EGREP:=@EGREP@ FGREP:=@FGREP@ @@ -637,6 +651,7 @@ MKDIR:=@MKDIR@ MV:=@MV@ NAWK:=@NAWK@ NICE:=@NICE@ +PANDOC:=@FIXPATH@ @PANDOC@ PATCH:=@PATCH@ PRINTF:=@PRINTF@ RM:=@RM@ @@ -665,6 +680,7 @@ OTOOL:=@OTOOL@ READELF:=@READELF@ EXPR:=@EXPR@ FILE:=@FILE@ +DOT:=@DOT@ HG:=@HG@ OBJCOPY:=@OBJCOPY@ SETFILE:=@SETFILE@ @@ -800,6 +816,8 @@ INTERIM_IMAGE_DIR := $(SUPPORT_OUTPUTDIR)/interim-image # Docs image DOCS_IMAGE_SUBDIR := docs DOCS_IMAGE_DIR = $(IMAGES_OUTPUTDIR)/$(DOCS_IMAGE_SUBDIR) +# Output docs directly into image +DOCS_OUTPUTDIR := $(DOCS_IMAGE_DIR) # Macosx bundles directory definitions JDK_MACOSX_BUNDLE_SUBDIR=jdk-bundle @@ -828,11 +846,6 @@ JRE_COMPACT3_BUNDLE_NAME := \ jre-$(VERSION_SHORT)+$(VERSION_BUILD)-compact3_$(OPENJDK_TARGET_BUNDLE_PLATFORM)_bin$(DEBUG_PART).tar.gz JDK_SYMBOLS_BUNDLE_NAME := jdk-$(BASE_NAME)_bin$(DEBUG_PART)-symbols.tar.gz JRE_SYMBOLS_BUNDLE_NAME := jre-$(BASE_NAME)_bin$(DEBUG_PART)-symbols.tar.gz -ifeq ($(OPENJDK_TARGET_OS), windows) - DEMOS_BUNDLE_NAME := jdk-$(BASE_NAME)_demo$(DEBUG_PART).zip -else - DEMOS_BUNDLE_NAME := jdk-$(BASE_NAME)_demo$(DEBUG_PART).tar.gz -endif TEST_BUNDLE_NAME := jdk-$(BASE_NAME)_bin-tests$(DEBUG_PART).tar.gz DOCS_BUNDLE_NAME := jdk-$(BASE_NAME)_doc-api-spec$(DEBUG_PART).tar.gz @@ -840,7 +853,6 @@ JDK_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JDK_BUNDLE_NAME) JRE_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JRE_BUNDLE_NAME) JDK_SYMBOLS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JDK_SYMBOLS_BUNDLE_NAME) JRE_SYMBOLS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(JRE_SYMBOLS_BUNDLE_NAME) -DEMOS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(DEMOS_BUNDLE_NAME) TEST_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(TEST_BUNDLE_NAME) DOCS_BUNDLE := $(BUNDLES_OUTPUTDIR)/$(DOCS_BUNDLE_NAME) diff --git a/common/autoconf/toolchain.m4 b/common/autoconf/toolchain.m4 index 16b0df04b4f..fca9b065aab 100644 --- a/common/autoconf/toolchain.m4 +++ b/common/autoconf/toolchain.m4 @@ -440,7 +440,7 @@ AC_DEFUN([TOOLCHAIN_EXTRACT_COMPILER_VERSION], # # $1 = compiler to test (CC or CXX) # $2 = human readable name of compiler (C or C++) -# $3 = list of compiler names to search for +# $3 = compiler name to search for AC_DEFUN([TOOLCHAIN_FIND_COMPILER], [ COMPILER_NAME=$2 @@ -482,15 +482,15 @@ AC_DEFUN([TOOLCHAIN_FIND_COMPILER], if test -n "$TOOLCHAIN_PATH"; then PATH_save="$PATH" PATH="$TOOLCHAIN_PATH" - AC_PATH_PROGS(TOOLCHAIN_PATH_$1, $SEARCH_LIST) + AC_PATH_TOOL(TOOLCHAIN_PATH_$1, $SEARCH_LIST) $1=$TOOLCHAIN_PATH_$1 PATH="$PATH_save" fi - # AC_PATH_PROGS can't be run multiple times with the same variable, + # AC_PATH_TOOL can't be run multiple times with the same variable, # so create a new name for this run. if test "x[$]$1" = x; then - AC_PATH_PROGS(POTENTIAL_$1, $SEARCH_LIST) + AC_PATH_TOOL(POTENTIAL_$1, $SEARCH_LIST) $1=$POTENTIAL_$1 fi @@ -926,41 +926,82 @@ AC_DEFUN_ONCE([TOOLCHAIN_MISC_CHECKS], AC_DEFUN_ONCE([TOOLCHAIN_SETUP_JTREG], [ AC_ARG_WITH(jtreg, [AS_HELP_STRING([--with-jtreg], - [Regression Test Harness @<:@probed@:>@])], - [], - [with_jtreg=no]) + [Regression Test Harness @<:@probed@:>@])]) if test "x$with_jtreg" = xno; then # jtreg disabled - AC_MSG_CHECKING([for jtreg]) - AC_MSG_RESULT(no) - else - if test "x$with_jtreg" != xyes; then - # with path specified. - JT_HOME="$with_jtreg" + AC_MSG_CHECKING([for jtreg test harness]) + AC_MSG_RESULT([no, disabled]) + elif test "x$with_jtreg" != xyes && test "x$with_jtreg" != x; then + # An explicit path is specified, use it. + JT_HOME="$with_jtreg" + if test ! -d "$JT_HOME"; then + AC_MSG_ERROR([jtreg home directory from --with-jtreg=$with_jtreg does not exist]) fi + if test ! -e "$JT_HOME/lib/jtreg.jar"; then + AC_MSG_ERROR([jtreg home directory from --with-jtreg=$with_jtreg is not a valid jtreg home]) + fi + + JTREGEXE="$JT_HOME/bin/jtreg" + if test ! -x "$JTREGEXE"; then + AC_MSG_ERROR([jtreg home directory from --with-jtreg=$with_jtreg does not contain valid jtreg executable]) + fi + + AC_MSG_CHECKING([for jtreg test harness]) + AC_MSG_RESULT([$JT_HOME]) + else + # Try to locate jtreg if test "x$JT_HOME" != x; then - AC_MSG_CHECKING([for jtreg]) - - # use JT_HOME enviroment var. - BASIC_FIXUP_PATH([JT_HOME]) - - # jtreg win32 script works for everybody - JTREGEXE="$JT_HOME/bin/jtreg" - - if test ! -f "$JTREGEXE"; then - AC_MSG_ERROR([JTReg executable does not exist: $JTREGEXE]) + # JT_HOME set in environment, use it + if test ! -d "$JT_HOME"; then + AC_MSG_WARN([Ignoring JT_HOME pointing to invalid directory: $JT_HOME]) + JT_HOME= + else + if test ! -e "$JT_HOME/lib/jtreg.jar"; then + AC_MSG_WARN([Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME]) + JT_HOME= + elif test ! -x "$JT_HOME/bin/jtreg"; then + AC_MSG_WARN([Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME]) + JT_HOME= + else + JTREGEXE="$JT_HOME/bin/jtreg" + AC_MSG_NOTICE([Located jtreg using JT_HOME from environment]) + fi fi + fi - AC_MSG_RESULT($JTREGEXE) + if test "x$JT_HOME" = x; then + # JT_HOME is not set in environment, or was deemed invalid. + # Try to find jtreg on path + BASIC_PATH_PROGS(JTREGEXE, jtreg) + if test "x$JTREGEXE" != x; then + # That's good, now try to derive JT_HOME + JT_HOME=`(cd $($DIRNAME $JTREGEXE)/.. && pwd)` + if test ! -e "$JT_HOME/lib/jtreg.jar"; then + AC_MSG_WARN([Ignoring jtreg from path since a valid jtreg home cannot be found]) + JT_HOME= + JTREGEXE= + else + AC_MSG_NOTICE([Located jtreg using jtreg executable in path]) + fi + fi + fi + + AC_MSG_CHECKING([for jtreg test harness]) + if test "x$JT_HOME" != x; then + AC_MSG_RESULT([$JT_HOME]) else - # try to find jtreg on path - BASIC_REQUIRE_PROGS(JTREGEXE, jtreg) - JT_HOME="`$DIRNAME $JTREGEXE`" + AC_MSG_RESULT([no, not found]) + + if test "x$with_jtreg" = xyes; then + AC_MSG_ERROR([--with-jtreg was specified, but no jtreg found.]) + fi fi fi + BASIC_FIXUP_EXECUTABLE(JTREGEXE) + BASIC_FIXUP_PATH(JT_HOME) AC_SUBST(JT_HOME) AC_SUBST(JTREGEXE) ]) diff --git a/common/autoconf/version-numbers b/common/autoconf/version-numbers index 4cb54671183..dc6e06253d7 100644 --- a/common/autoconf/version-numbers +++ b/common/autoconf/version-numbers @@ -1,5 +1,5 @@ # -# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,7 @@ # Default version numbers to use unless overridden by configure -DEFAULT_VERSION_MAJOR=9 +DEFAULT_VERSION_MAJOR=10 DEFAULT_VERSION_MINOR=0 DEFAULT_VERSION_SECURITY=0 DEFAULT_VERSION_PATCH=0 diff --git a/common/bin/compare_exceptions.sh.incl b/common/bin/compare_exceptions.sh.incl index 8aa1df11f8d..f3158f3b4e5 100644 --- a/common/bin/compare_exceptions.sh.incl +++ b/common/bin/compare_exceptions.sh.incl @@ -38,25 +38,9 @@ fi if [ "$OPENJDK_TARGET_OS" = "linux" ]; then STRIP_BEFORE_COMPARE=" - ./demo/jvmti/compiledMethodLoad/lib/libcompiledMethodLoad.so - ./demo/jvmti/gctest/lib/libgctest.so - ./demo/jvmti/heapTracker/lib/libheapTracker.so - ./demo/jvmti/heapViewer/lib/libheapViewer.so - ./demo/jvmti/minst/lib/libminst.so - ./demo/jvmti/mtrace/lib/libmtrace.so - ./demo/jvmti/versionCheck/lib/libversionCheck.so - ./demo/jvmti/waiters/lib/libwaiters.so " ACCEPTED_BIN_DIFF=" - ./demo/jvmti/compiledMethodLoad/lib/libcompiledMethodLoad.so - ./demo/jvmti/gctest/lib/libgctest.so - ./demo/jvmti/heapTracker/lib/libheapTracker.so - ./demo/jvmti/heapViewer/lib/libheapViewer.so - ./demo/jvmti/minst/lib/libminst.so - ./demo/jvmti/mtrace/lib/libmtrace.so - ./demo/jvmti/versionCheck/lib/libversionCheck.so - ./demo/jvmti/waiters/lib/libwaiters.so ./lib/client/libjsig.so ./lib/client/libjvm.so ./lib/libattach.so @@ -151,15 +135,6 @@ fi if [ "$OPENJDK_TARGET_OS" = "solaris" ] && [ "$OPENJDK_TARGET_CPU" = "x86_64" ]; then STRIP_BEFORE_COMPARE=" - ./demo/jni/Poller/lib/libPoller.so - ./demo/jvmti/compiledMethodLoad/lib/libcompiledMethodLoad.so - ./demo/jvmti/gctest/lib/libgctest.so - ./demo/jvmti/heapTracker/lib/libheapTracker.so - ./demo/jvmti/heapViewer/lib/libheapViewer.so - ./demo/jvmti/minst/lib/libminst.so - ./demo/jvmti/mtrace/lib/libmtrace.so - ./demo/jvmti/versionCheck/lib/libversionCheck.so - ./demo/jvmti/waiters/lib/libwaiters.so " SORT_SYMBOLS=" @@ -174,15 +149,6 @@ if [ "$OPENJDK_TARGET_OS" = "solaris" ] && [ "$OPENJDK_TARGET_CPU" = "x86_64" ]; SKIP_BIN_DIFF="true" ACCEPTED_SMALL_SIZE_DIFF=" - ./demo/jni/Poller/lib/libPoller.so - ./demo/jvmti/compiledMethodLoad/lib/libcompiledMethodLoad.so - ./demo/jvmti/gctest/lib/libgctest.so - ./demo/jvmti/heapTracker/lib/libheapTracker.so - ./demo/jvmti/heapViewer/lib/libheapViewer.so - ./demo/jvmti/minst/lib/libminst.so - ./demo/jvmti/mtrace/lib/libmtrace.so - ./demo/jvmti/versionCheck/lib/libversionCheck.so - ./demo/jvmti/waiters/lib/libwaiters.so ./lib/jli/libjli.so ./lib/jspawnhelper ./lib/libJdbcOdbc.so @@ -279,19 +245,9 @@ fi if [ "$OPENJDK_TARGET_OS" = "solaris" ] && [ "$OPENJDK_TARGET_CPU" = "sparcv9" ]; then STRIP_BEFORE_COMPARE=" - ./demo/jni/Poller/lib/libPoller.so - ./demo/jvmti/compiledMethodLoad/lib/libcompiledMethodLoad.so - ./demo/jvmti/gctest/lib/libgctest.so - ./demo/jvmti/heapTracker/lib/libheapTracker.so - ./demo/jvmti/heapViewer/lib/libheapViewer.so - ./demo/jvmti/minst/lib/libminst.so - ./demo/jvmti/mtrace/lib/libmtrace.so - ./demo/jvmti/versionCheck/lib/libversionCheck.so - ./demo/jvmti/waiters/lib/libwaiters.so " SORT_SYMBOLS=" - ./demo/jvmti/waiters/lib/libwaiters.so ./lib/libjsig.so ./lib/libfontmanager.so ./lib/libjimage.so @@ -305,15 +261,6 @@ if [ "$OPENJDK_TARGET_OS" = "solaris" ] && [ "$OPENJDK_TARGET_CPU" = "sparcv9" ] SKIP_BIN_DIFF="true" ACCEPTED_SMALL_SIZE_DIFF=" - ./demo/jni/Poller/lib/libPoller.so - ./demo/jvmti/compiledMethodLoad/lib/libcompiledMethodLoad.so - ./demo/jvmti/gctest/lib/libgctest.so - ./demo/jvmti/heapTracker/lib/libheapTracker.so - ./demo/jvmti/heapViewer/lib/libheapViewer.so - ./demo/jvmti/minst/lib/libminst.so - ./demo/jvmti/mtrace/lib/libmtrace.so - ./demo/jvmti/versionCheck/lib/libversionCheck.so - ./demo/jvmti/waiters/lib/libwaiters.so ./lib/client/libjvm.so ./lib/jli/libjli.so ./lib/jspawnhelper @@ -438,9 +385,6 @@ if [ "$OPENJDK_TARGET_OS" = "windows" ]; then # Probably should add all libs here ACCEPTED_SMALL_SIZE_DIFF=" - ./demo/jvmti/gctest/lib/gctest.dll - ./demo/jvmti/heapTracker/lib/heapTracker.dll - ./demo/jvmti/minst/lib/minst.dll ./bin/attach.dll ./bin/jsoundds.dll ./bin/client/jvm.dll @@ -579,14 +523,6 @@ if [ "$OPENJDK_TARGET_OS" = "macosx" ]; then ./bin/wsgen ./bin/wsimport ./bin/xjc - ./demo/jvmti/compiledMethodLoad/lib/libcompiledMethodLoad.dylib - ./demo/jvmti/gctest/lib/libgctest.dylib - ./demo/jvmti/heapTracker/lib/libheapTracker.dylib - ./demo/jvmti/heapViewer/lib/libheapViewer.dylib - ./demo/jvmti/minst/lib/libminst.dylib - ./demo/jvmti/mtrace/lib/libmtrace.dylib - ./demo/jvmti/versionCheck/lib/libversionCheck.dylib - ./demo/jvmti/waiters/lib/libwaiters.dylib ./Contents/Home/bin/_javaws ./Contents/Home/bin/javaws ./Contents/Home/bin/idlj diff --git a/common/bin/hgforest.sh b/common/bin/hgforest.sh index 5d4f8eb7156..b5d6a6c938c 100644 --- a/common/bin/hgforest.sh +++ b/common/bin/hgforest.sh @@ -1,6 +1,6 @@ #!/bin/sh # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -183,7 +183,7 @@ trap 'nice_exit' EXIT subrepos="corba jaxp jaxws langtools jdk hotspot nashorn" jdk_subrepos_extra="closed jdk/src/closed jdk/make/closed jdk/test/closed hotspot/make/closed hotspot/src/closed hotspot/test/closed" -subrepos_extra="$jdk_subrepos_extra deploy install sponsors pubs" +subrepos_extra="$jdk_subrepos_extra deploy install sponsors" # Only look in specific locations for possible forests (avoids long searches) pull_default="" diff --git a/common/bin/shell-tracer.sh b/common/bin/shell-profiler.sh similarity index 52% rename from common/bin/shell-tracer.sh rename to common/bin/shell-profiler.sh index 5c7cc449f9c..d4a39dd8d1b 100644 --- a/common/bin/shell-tracer.sh +++ b/common/bin/shell-profiler.sh @@ -22,26 +22,48 @@ # questions. # -# Usage: sh shell-tracer.sh +# Usage: sh shell-tracer.sh # # This shell script is supposed to be set as a replacement for SHELL in make, # causing it to be called whenever make wants to execute shell commands. # The is suitable for passing on to the old shell, # typically beginning with -c. # -# This script will make sure the shell command line is executed with -# OLD_SHELL -x, and it will also store a simple log of the the time it takes to -# execute the command in the OUTPUT_FILE, using the "time" utility as pointed -# to by TIME_CMD. If TIME_CMD is "-", no timestamp will be stored. +# This script will run the shell command line and it will also store a simple +# log of the the time it takes to execute the command in the OUTPUT_FILE, using +# utility for time measure specified with TIME_CMD option. +# +# Type of time measure utility is specified with TIME_CMD_TYPE option. +# Recognized options values of TIME_CMD_TYPE option: "gnutime", "flock". -TIME_CMD="$1" -OUTPUT_FILE="$2" -OLD_SHELL="$3" +TIME_CMD_TYPE="$1" +TIME_CMD="$2" +OUTPUT_FILE="$3" shift shift shift -if [ "$TIME_CMD" != "-" ]; then -"$TIME_CMD" -f "[TIME:%E] $*" -a -o "$OUTPUT_FILE" "$OLD_SHELL" -x "$@" +if [ "$TIME_CMD_TYPE" = "gnutime" ]; then + # Escape backslashes (\) and percent chars (%). See man for GNU 'time'. + msg=${@//\\/\\\\} + msg=${msg//%/%%} + "$TIME_CMD" -f "[TIME:%E] $msg" -a -o "$OUTPUT_FILE" "$@" +elif [ "$TIME_CMD_TYPE" = "flock" ]; then + # Emulated GNU 'time' with 'flock' and 'date'. + ts=`date +%s%3N` + "$@" + status=$? + ts2=`date +%s%3N` + millis=$((ts2 - ts)) + ms=$(($millis % 1000)) + seconds=$((millis / 1000)) + ss=$(($seconds % 60)) + minutes=$(($seconds / 60)) + mm=$(($minutes % 60)) + hh=$(($minutes / 60)): + [ $hh != "0:" ] || hh= + # Synchronize on this script. + flock -w 10 "$0" printf "[TIME:${hh}${mm}:${ss}.%.2s] %s\n" $ms "$*" >> "$OUTPUT_FILE" || true + exit $status else -"$OLD_SHELL" -x "$@" + "$@" fi diff --git a/common/bin/unshuffle_list.txt b/common/bin/unshuffle_list.txt index e5fe5af121d..73ccb0a0136 100644 --- a/common/bin/unshuffle_list.txt +++ b/common/bin/unshuffle_list.txt @@ -361,8 +361,8 @@ jdk/src/java.base/share/native/libverify/check_code.c : jdk/src/share/native/com jdk/src/java.base/share/native/libverify/check_format.c : jdk/src/share/native/common/check_format.c jdk/src/java.base/share/native/libverify/opcodes.in_out : jdk/src/share/native/common/opcodes.in_out jdk/src/java.base/share/native/libzip : jdk/src/share/native/java/util/zip -jdk/src/java.base/share/native/libzip/zlib-1.2.8 : jdk/src/share/native/java/util/zip/zlib-1.2.8 -jdk/src/java.base/share/native/libzip/zlib-1.2.8/patches/ChangeLog_java : jdk/src/share/native/java/util/zip/zlib-1.2.8/patches/ChangeLog_java +jdk/src/java.base/share/native/libzip/zlib : jdk/src/share/native/java/util/zip/zlib +jdk/src/java.base/share/native/libzip/zlib/patches/ChangeLog_java : jdk/src/share/native/java/util/zip/zlib/patches/ChangeLog_java jdk/src/java.base/unix/classes/java/io : jdk/src/solaris/classes/java/io jdk/src/java.base/unix/classes/java/lang : jdk/src/solaris/classes/java/lang jdk/src/java.base/unix/classes/java/net : jdk/src/solaris/classes/java/net diff --git a/common/bin/update-build-readme.sh b/common/bin/update-build-readme.sh deleted file mode 100644 index 9d1968a4c60..00000000000 --- a/common/bin/update-build-readme.sh +++ /dev/null @@ -1,62 +0,0 @@ -#!/bin/bash - -# Get an absolute path to this script, since that determines the top-level -# directory. -this_script_dir=`dirname $0` -TOPDIR=`cd $this_script_dir/../.. > /dev/null && pwd` - -GREP=grep -MD_FILE=$TOPDIR/README-builds.md -HTML_FILE=$TOPDIR/README-builds.html - -# Locate the markdown processor tool and check that it is the correct version. -locate_markdown_processor() { - if [ -z "$MARKDOWN" ]; then - MARKDOWN=`which markdown 2> /dev/null` - if [ -z "$MARKDOWN" ]; then - echo "Error: Cannot locate markdown processor" 1>&2 - exit 1 - fi - fi - - # Test version - MARKDOWN_VERSION=`$MARKDOWN -version | $GREP version` - if [ "x$MARKDOWN_VERSION" != "xThis is Markdown, version 1.0.1." ]; then - echo "Error: Expected markdown version 1.0.1." 1>&2 - echo "Actual version found: $MARKDOWN_VERSION" 1>&2 - echo "Download markdown here: https://daringfireball.net/projects/markdown/" 1>&2 - exit 1 - fi - -} - -# Verify that the source markdown file looks sound. -verify_source_code() { - TOO_LONG_LINES=`$GREP -E -e '^.{80}.+$' $MD_FILE` - if [ "x$TOO_LONG_LINES" != x ]; then - echo "Warning: The following lines are longer than 80 characters:" - $GREP -E -e '^.{80}.+$' $MD_FILE - fi -} - -# Convert the markdown file to html format. -process_source() { - echo "Generating html file from markdown" - cat > $HTML_FILE << END - - - OpenJDK Build README - - -END - markdown $MD_FILE >> $HTML_FILE - cat >> $HTML_FILE < - -END - echo "Done" -} - -locate_markdown_processor -verify_source_code -process_source diff --git a/common/conf/jib-profiles.js b/common/conf/jib-profiles.js index ff86de23a31..8f940224465 100644 --- a/common/conf/jib-profiles.js +++ b/common/conf/jib-profiles.js @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -231,18 +231,16 @@ var getJibProfilesCommon = function (input, data) { // List of the main profile names used for iteration common.main_profile_names = [ "linux-x64", "linux-x86", "macosx-x64", "solaris-x64", - "solaris-sparcv9", "windows-x64", "windows-x86" + "solaris-sparcv9", "windows-x64", "windows-x86", + "linux-arm64", "linux-arm-vfp-hflt", "linux-arm-vfp-hflt-dyn" ]; // These are the base setttings for all the main build profiles. common.main_profile_base = { dependencies: ["boot_jdk", "gnumake", "jtreg"], default_make_targets: ["product-bundles", "test-bundles"], - configure_args: [ - "--with-version-opt=" + common.build_id, - "--enable-jtreg-failure-handler", - "--with-version-build=" + common.build_number - ] + configure_args: concat(["--enable-jtreg-failure-handler"], + versionArgs(input, common)) }; // Extra settings for debug profiles common.debug_suffix = "-debug"; @@ -268,10 +266,12 @@ var getJibProfilesCommon = function (input, data) { /** * Define common artifacts template for all main profiles - * @param pf - Name of platform in bundle names - * @param demo_ext - Type of extension for demo bundle + * @param o - Object containing data for artifacts */ - common.main_profile_artifacts = function (pf, demo_ext) { + common.main_profile_artifacts = function (o) { + var jdk_subdir = (o.jdk_subdir != null ? o.jdk_subdir : "jdk-" + data.version); + var jre_subdir = (o.jre_subdir != null ? o.jre_subdir : "jre-" + data.version); + var pf = o.platform return { artifacts: { jdk: { @@ -280,7 +280,7 @@ var getJibProfilesCommon = function (input, data) { "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jdk-" + data.version, + subdir: jdk_subdir, exploded: "images/jdk" }, jre: { @@ -289,7 +289,7 @@ var getJibProfilesCommon = function (input, data) { "bundles/" + pf + "/jre-" + data.version + "_" + pf + "_bin.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jre-" + data.version, + subdir: jre_subdir, exploded: "images/jre" }, test: { @@ -306,7 +306,7 @@ var getJibProfilesCommon = function (input, data) { "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-symbols.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jdk-" + data.version, + subdir: jdk_subdir, exploded: "images/jdk" }, jre_symbols: { @@ -315,15 +315,8 @@ var getJibProfilesCommon = function (input, data) { "bundles/" + pf + "/jre-" + data.version + "_" + pf + "_bin-symbols.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jre-" + data.version, + subdir: jre_subdir, exploded: "images/jre" - }, - demo: { - local: "bundles/\\(jdk.*demo." + demo_ext + "\\)", - remote: [ - "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_demo." + demo_ext, - "bundles/" + pf + "/\\1" - ], } } }; @@ -332,9 +325,12 @@ var getJibProfilesCommon = function (input, data) { /** * Define common artifacts template for all debug profiles - * @param pf - Name of platform in bundle names + * @param o - Object containing data for artifacts */ - common.debug_profile_artifacts = function (pf) { + common.debug_profile_artifacts = function (o) { + var jdk_subdir = "jdk-" + data.version + "/fastdebug"; + var jre_subdir = "jre-" + data.version + "/fastdebug"; + var pf = o.platform return { artifacts: { jdk: { @@ -343,7 +339,7 @@ var getJibProfilesCommon = function (input, data) { "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-debug.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jdk-" + data.version, + subdir: jdk_subdir, exploded: "images/jdk" }, jre: { @@ -352,7 +348,7 @@ var getJibProfilesCommon = function (input, data) { "bundles/" + pf + "/jre-" + data.version + "_" + pf + "_bin-debug.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jre-" + data.version, + subdir: jre_subdir, exploded: "images/jre" }, test: { @@ -369,7 +365,7 @@ var getJibProfilesCommon = function (input, data) { "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-debug-symbols.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jdk-" + data.version, + subdir: jdk_subdir, exploded: "images/jdk" }, jre_symbols: { @@ -378,7 +374,7 @@ var getJibProfilesCommon = function (input, data) { "bundles/" + pf + "/jre-" + data.version + "_" + pf + "_bin-debug-symbols.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jre-" + data.version, + subdir: jre_subdir, exploded: "images/jre" } } @@ -391,7 +387,7 @@ var getJibProfilesCommon = function (input, data) { // on such hardware. if (input.build_cpu == "sparcv9") { var cpu_brand = $EXEC("bash -c \"kstat -m cpu_info | grep brand | head -n1 | awk '{ print \$2 }'\""); - if (cpu_brand.trim() == 'SPARC-M7') { + if (cpu_brand.trim().match('SPARC-.[78]')) { boot_jdk_revision = "8u20"; boot_jdk_subdirpart = "1.8.0_20"; } @@ -401,6 +397,8 @@ var getJibProfilesCommon = function (input, data) { common.boot_jdk_home = input.get("boot_jdk", "home_path") + "/jdk" + common.boot_jdk_subdirpart + (input.build_os == "macosx" ? ".jdk/Contents/Home" : ""); + common.boot_jdk_platform = input.build_os + "-" + + (input.build_cpu == "x86" ? "i586" : input.build_cpu); return common; }; @@ -419,8 +417,9 @@ var getJibProfilesProfiles = function (input, common, data) { "linux-x64": { target_os: "linux", target_cpu: "x64", - dependencies: ["devkit"], - configure_args: concat(common.configure_args_64bit, "--with-zlib=system"), + dependencies: ["devkit", "graphviz", "pandoc"], + configure_args: concat(common.configure_args_64bit, + "--enable-full-docs", "--with-zlib=system"), default_make_targets: ["docs-bundles"], }, @@ -469,8 +468,43 @@ var getJibProfilesProfiles = function (input, common, data) { build_cpu: "x64", dependencies: ["devkit", "freetype"], configure_args: concat(common.configure_args_32bit), + }, + + "linux-arm64": { + target_os: "linux", + target_cpu: "aarch64", + build_cpu: "x64", + dependencies: ["devkit", "build_devkit", "cups", "headless_stubs"], + configure_args: [ + "--with-cpu-port=arm64", + "--with-jvm-variants=server", + "--openjdk-target=aarch64-linux-gnu", + "--enable-headless-only" + ], + }, + + "linux-arm-vfp-hflt": { + target_os: "linux", + target_cpu: "arm", + build_cpu: "x64", + dependencies: ["devkit", "build_devkit", "cups"], + configure_args: [ + "--with-jvm-variants=minimal1,client", + "--with-x=" + input.get("devkit", "install_path") + "/arm-linux-gnueabihf/libc/usr/X11R6-PI", + "--openjdk-target=arm-linux-gnueabihf", + "--with-abi-profile=arm-vfp-hflt" + ], + }, + + // Special version of the SE profile adjusted to be testable on arm64 hardware. + "linux-arm-vfp-hflt-dyn": { + configure_args: "--with-stdc++lib=dynamic" } }; + // Let linux-arm-vfp-hflt-dyn inherit everything from linux-arm-vfp-hflt + profiles["linux-arm-vfp-hflt-dyn"] = concatObjects( + profiles["linux-arm-vfp-hflt-dyn"], profiles["linux-arm-vfp-hflt"]); + // Add the base settings to all the main profiles common.main_profile_names.forEach(function (name) { profiles[name] = concatObjects(common.main_profile_base, profiles[name]); @@ -582,7 +616,7 @@ var getJibProfilesProfiles = function (input, common, data) { var testOnlyProfilesPrebuilt = { "run-test-prebuilt": { src: "src.conf", - dependencies: [ "jtreg", "gnumake", testedProfile + ".jdk", + dependencies: [ "jtreg", "gnumake", "boot_jdk", testedProfile + ".jdk", testedProfile + ".test", "src.full" ], work_dir: input.get("src.full", "install_path") + "/test", @@ -626,49 +660,53 @@ var getJibProfilesProfiles = function (input, common, data) { // // Define artifacts for profiles // - // Macosx bundles are named osx and Windows demo bundles use zip instead of + // Macosx bundles are named osx // tar.gz. var artifactData = { "linux-x64": { platform: "linux-x64", - demo_ext: "tar.gz" }, "linux-x86": { platform: "linux-x86", - demo_ext: "tar.gz" }, "macosx-x64": { platform: "osx-x64", - demo_ext: "tar.gz" + jdk_subdir: "jdk-" + data.version + ".jdk/Contents/Home", + jre_subdir: "jre-" + data.version + ".jre/Contents/Home" }, "solaris-x64": { platform: "solaris-x64", - demo_ext: "tar.gz" }, "solaris-sparcv9": { platform: "solaris-sparcv9", - demo_ext: "tar.gz" }, "windows-x64": { platform: "windows-x64", - demo_ext: "zip" }, "windows-x86": { platform: "windows-x86", - demo_ext: "zip" + }, + "linux-arm64": { + platform: "linux-arm64-vfp-hflt", + }, + "linux-arm-vfp-hflt": { + platform: "linux-arm32-vfp-hflt", + }, + "linux-arm-vfp-hflt-dyn": { + platform: "linux-arm32-vfp-hflt-dyn", } } // Generate common artifacts for all main profiles - common.main_profile_names.forEach(function (name) { + Object.keys(artifactData).forEach(function (name) { profiles[name] = concatObjects(profiles[name], - common.main_profile_artifacts(artifactData[name].platform, artifactData[name].demo_ext)); + common.main_profile_artifacts(artifactData[name])); }); // Generate common artifacts for all debug profiles - common.main_profile_names.forEach(function (name) { + Object.keys(artifactData).forEach(function (name) { var debugName = name + common.debug_suffix; profiles[debugName] = concatObjects(profiles[debugName], - common.debug_profile_artifacts(artifactData[name].platform)); + common.debug_profile_artifacts(artifactData[name])); }); // Extra profile specific artifacts @@ -689,7 +727,12 @@ var getJibProfilesProfiles = function (input, common, data) { artifacts: { jdk: { local: "bundles/\\(jdk.*bin.tar.gz\\)", - remote: "bundles/openjdk/GPL/linux-x64/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x64/jdk-" + data.version + + "_linux-x64_bin.tar.gz", + "bundles/openjdk/GPL/linux-x64/\\1" + ], + subdir: "jdk-" + data.version }, jre: { local: "bundles/\\(jre.*bin.tar.gz\\)", @@ -697,20 +740,25 @@ var getJibProfilesProfiles = function (input, common, data) { }, test: { local: "bundles/\\(jdk.*bin-tests.tar.gz\\)", - remote: "bundles/openjdk/GPL/linux-x64/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x64/jdk-" + data.version + + "_linux-x64_bin-tests.tar.gz", + "bundles/openjdk/GPL/linux-x64/\\1" + ] }, jdk_symbols: { local: "bundles/\\(jdk.*bin-symbols.tar.gz\\)", - remote: "bundles/openjdk/GPL/linux-x64/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x64/jdk-" + data.version + + "_linux-x64_bin-symbols.tar.gz", + "bundles/openjdk/GPL/linux-x64/\\1" + ], + subdir: "jdk-" + data.version }, jre_symbols: { local: "bundles/\\(jre.*bin-symbols.tar.gz\\)", remote: "bundles/openjdk/GPL/linux-x64/\\1", }, - demo: { - local: "bundles/\\(jdk.*demo.tar.gz\\)", - remote: "bundles/openjdk/GPL/linux-x64/\\1", - }, doc_api_spec: { local: "bundles/\\(jdk.*doc-api-spec.tar.gz\\)", remote: "bundles/openjdk/GPL/linux-x64/\\1", @@ -722,11 +770,29 @@ var getJibProfilesProfiles = function (input, common, data) { artifacts: { jdk: { local: "bundles/\\(jdk.*bin.tar.gz\\)", - remote: "bundles/openjdk/GPL/profile/linux-x86/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x86/jdk-" + data.version + + "_linux-x86_bin.tar.gz", + "bundles/openjdk/GPL/linux-x86/\\1" + ], + subdir: "jdk-" + data.version }, jdk_symbols: { local: "bundles/\\(jdk.*bin-symbols.tar.gz\\)", - remote: "bundles/openjdk/GPL/profile/linux-x86/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x86/jdk-" + data.version + + "_linux-x86_bin-symbols.tar.gz", + "bundles/openjdk/GPL/linux-x86/\\1" + ], + subdir: "jdk-" + data.version + }, + test: { + local: "bundles/\\(jdk.*bin-tests.tar.gz\\)", + remote: [ + "bundles/openjdk/GPL/linux-x86/jdk-" + data.version + + "_linux-x86_bin-tests.tar.gz", + "bundles/openjdk/GPL/linux-x86/\\1" + ] }, jre: { // This regexp needs to not match the compact* files below @@ -752,7 +818,12 @@ var getJibProfilesProfiles = function (input, common, data) { artifacts: { jdk: { local: "bundles/\\(jdk.*bin.tar.gz\\)", - remote: "bundles/openjdk/GPL/windows-x86/\\1", + remote: [ + "bundles/openjdk/GPL/windows-x86/jdk-" + data.version + + "_windows-x86_bin.tar.gz", + "bundles/openjdk/GPL/windows-x86/\\1" + ], + subdir: "jdk-" + data.version }, jre: { local: "bundles/\\(jre.*bin.tar.gz\\)", @@ -760,19 +831,24 @@ var getJibProfilesProfiles = function (input, common, data) { }, test: { local: "bundles/\\(jdk.*bin-tests.tar.gz\\)", - remote: "bundles/openjdk/GPL/windows-x86/\\1", + remote: [ + "bundles/openjdk/GPL/windows-x86/jdk-" + data.version + + "_windows-x86_bin-tests.tar.gz", + "bundles/openjdk/GPL/windows-x86/\\1" + ] }, jdk_symbols: { local: "bundles/\\(jdk.*bin-symbols.tar.gz\\)", - remote: "bundles/openjdk/GPL/windows-x86/\\1" + remote: [ + "bundles/openjdk/GPL/windows-x86/jdk-" + data.version + + "_windows-x86_bin-symbols.tar.gz", + "bundles/openjdk/GPL/windows-x86/\\1" + ], + subdir: "jdk-" + data.version }, jre_symbols: { local: "bundles/\\(jre.*bin-symbols.tar.gz\\)", remote: "bundles/openjdk/GPL/windows-x86/\\1", - }, - demo: { - local: "bundles/\\(jdk.*demo.zip\\)", - remote: "bundles/openjdk/GPL/windows-x86/\\1", } } }, @@ -832,15 +908,16 @@ var getJibProfilesProfiles = function (input, common, data) { */ var getJibProfilesDependencies = function (input, common) { - var boot_jdk_platform = input.build_os + "-" - + (input.build_cpu == "x86" ? "i586" : input.build_cpu); - var devkit_platform_revisions = { linux_x64: "gcc4.9.2-OEL6.4+1.1", macosx_x64: "Xcode6.3-MacOSX10.9+1.0", solaris_x64: "SS12u4-Solaris11u1+1.0", solaris_sparcv9: "SS12u4-Solaris11u1+1.0", - windows_x64: "VS2013SP4+1.0" + windows_x64: "VS2013SP4+1.0", + linux_aarch64: "gcc-linaro-aarch64-linux-gnu-4.8-2013.11_linux+1.0", + linux_arm: (input.profile != null && input.profile.indexOf("hflt") >= 0 + ? "gcc-linaro-arm-linux-gnueabihf-raspbian-2012.09-20120921_linux+1.0" + : "arm-linaro-4.7+1.0") }; var devkit_platform = (input.target_cpu == "x86" @@ -853,9 +930,9 @@ var getJibProfilesDependencies = function (input, common) { server: "javare", module: "jdk", revision: common.boot_jdk_revision, - checksum_file: boot_jdk_platform + "/MD5_VALUES", - file: boot_jdk_platform + "/jdk-" + common.boot_jdk_revision - + "-" + boot_jdk_platform + ".tar.gz", + checksum_file: common.boot_jdk_platform + "/MD5_VALUES", + file: common.boot_jdk_platform + "/jdk-" + common.boot_jdk_revision + + "-" + common.boot_jdk_platform + ".tar.gz", configure_args: "--with-boot-jdk=" + common.boot_jdk_home, environment_path: common.boot_jdk_home + "/bin" }, @@ -883,7 +960,7 @@ var getJibProfilesDependencies = function (input, common) { jtreg: { server: "javare", revision: "4.2", - build_number: "b05", + build_number: "b07", checksum_file: "MD5_VALUES", file: "jtreg_bin-4.2.zip", environment_name: "JT_HOME", @@ -911,9 +988,27 @@ var getJibProfilesDependencies = function (input, common) { freetype: { organization: common.organization, ext: "tar.gz", - revision: "2.3.4+1.0", + revision: "2.7.1-v120+1.0", module: "freetype-" + input.target_platform - } + }, + + graphviz: { + organization: common.organization, + ext: "tar.gz", + revision: "2.38.0-1+1.1", + module: "graphviz-" + input.target_platform, + configure_args: "DOT=" + input.get("graphviz", "install_path") + "/dot", + environment_path: input.get("graphviz", "install_path") + }, + + pandoc: { + organization: common.organization, + ext: "tar.gz", + revision: "1.17.2+1.0", + module: "pandoc-" + input.target_platform, + configure_args: "PANDOC=" + input.get("pandoc", "install_path") + "/pandoc/pandoc", + environment_path: input.get("pandoc", "install_path") + "/pandoc" + }, }; return dependencies; @@ -1080,12 +1175,29 @@ var getVersion = function (major, minor, security, patch) { + "." + (minor != null ? minor : version_numbers.get("DEFAULT_VERSION_MINOR")) + "." + (security != null ? security : version_numbers.get("DEFAULT_VERSION_SECURITY")) + "." + (patch != null ? patch : version_numbers.get("DEFAULT_VERSION_PATCH")); - while (version.match(".*\.0$")) { + while (version.match(".*\\.0$")) { version = version.substring(0, version.length - 2); } return version; }; +/** + * Constructs the common version configure args based on build type and + * other version inputs + */ +var versionArgs = function(input, common) { + var args = ["--with-version-build=" + common.build_number]; + if (input.build_type == "promoted") { + args = concat(args, + // This needs to be changed when we start building release candidates + "--with-version-pre=ea", + "--without-version-opt"); + } else { + args = concat(args, "--with-version-opt=" + common.build_id); + } + return args; +} + // Properties representation of the common/autoconf/version-numbers file. Lazily // initiated by the function below. var version_numbers; diff --git a/common/doc/building.html b/common/doc/building.html new file mode 100644 index 00000000000..624c3e8e853 --- /dev/null +++ b/common/doc/building.html @@ -0,0 +1,752 @@ + + + + + + + OpenJDK Build README + + + + + +
+

OpenJDK Build README

+
+
+OpenJDK
OpenJDK
+
+
+

Introduction

+

This README file contains build instructions for the OpenJDK. Building the source code for the OpenJDK requires a certain degree of technical expertise.

+

!!!!!!!!!!!!!!! THIS IS A MAJOR RE-WRITE of this document. !!!!!!!!!!!!!

+

Some Headlines:

+
    +
  • The build is now a "configure && make" style build
  • +
  • Any GNU make 3.81 or newer should work, except on Windows where 4.0 or newer is recommended.
  • +
  • The build should scale, i.e. more processors should cause the build to be done in less wall-clock time
  • +
  • Nested or recursive make invocations have been significantly reduced, as has the total fork/exec or spawning of sub processes during the build
  • +
  • Windows MKS usage is no longer supported
  • +
  • Windows Visual Studio vsvars*.bat and vcvars*.bat files are run automatically
  • +
  • Ant is no longer used when building the OpenJDK
  • +
  • Use of ALT_* environment variables for configuring the build is no longer supported
  • +
+
+

Contents

+ +
+ +
+

Use of Mercurial

+

The OpenJDK sources are maintained with the revision control system Mercurial. If you are new to Mercurial, please see the Beginner Guides or refer to the Mercurial Book. The first few chapters of the book provide an excellent overview of Mercurial, what it is and how it works.

+

For using Mercurial with the OpenJDK refer to the Developer Guide: Installing and Configuring Mercurial section for more information.

+

Getting the Source

+

To get the entire set of OpenJDK Mercurial repositories use the script get_source.sh located in the root repository:

+
  hg clone http://hg.openjdk.java.net/jdk9/jdk9 YourOpenJDK
+  cd YourOpenJDK
+  bash ./get_source.sh
+

Once you have all the repositories, keep in mind that each repository is its own independent repository. You can also re-run ./get_source.sh anytime to pull over all the latest changesets in all the repositories. This set of nested repositories has been given the term "forest" and there are various ways to apply the same hg command to each of the repositories. For example, the script make/scripts/hgforest.sh can be used to repeat the same hg command on every repository, e.g.

+
  cd YourOpenJDK
+  bash ./make/scripts/hgforest.sh status
+

Repositories

+

The set of repositories and what they contain:

+
    +
  • . (root) contains common configure and makefile logic
  • +
  • hotspot contains source code and make files for building the OpenJDK Hotspot Virtual Machine
  • +
  • langtools contains source code for the OpenJDK javac and language tools
  • +
  • jdk contains source code and make files for building the OpenJDK runtime libraries and misc files
  • +
  • jaxp contains source code for the OpenJDK JAXP functionality
  • +
  • jaxws contains source code for the OpenJDK JAX-WS functionality
  • +
  • corba contains source code for the OpenJDK Corba functionality
  • +
  • nashorn contains source code for the OpenJDK JavaScript implementation
  • +
+

Repository Source Guidelines

+

There are some very basic guidelines:

+
    +
  • Use of whitespace in source files (.java, .c, .h, .cpp, and .hpp files) is restricted. No TABs, no trailing whitespace on lines, and files should not terminate in more than one blank line.
  • +
  • Files with execute permissions should not be added to the source repositories.
  • +
  • All generated files need to be kept isolated from the files maintained or managed by the source control system. The standard area for generated files is the top level build/ directory.
  • +
  • The default build process should be to build the product and nothing else, in one form, e.g. a product (optimized), debug (non-optimized, -g plus assert logic), or fastdebug (optimized, -g plus assert logic).
  • +
  • The .hgignore file in each repository must exist and should include ^build/, ^dist/ and optionally any nbproject/private directories. It should NEVER include anything in the src/ or test/ or any managed directory area of a repository.
  • +
  • Directory names and file names should never contain blanks or non-printing characters.
  • +
  • Generated source or binary files should NEVER be added to the repository (that includes javah output). There are some exceptions to this rule, in particular with some of the generated configure scripts.
  • +
  • Files not needed for typical building or testing of the repository should not be added to the repository.
  • +
+
+

Building

+

The very first step in building the OpenJDK is making sure the system itself has everything it needs to do OpenJDK builds. Once a system is setup, it generally doesn't need to be done again.

+

Building the OpenJDK is now done with running a configure script which will try and find and verify you have everything you need, followed by running make, e.g.

+
+

bash ./configure
+make all

+
+

Where possible the configure script will attempt to located the various components in the default locations or via component specific variable settings. When the normal defaults fail or components cannot be found, additional configure options may be necessary to help configure find the necessary tools for the build, or you may need to re-visit the setup of your system due to missing software packages.

+

NOTE: The configure script file does not have execute permissions and will need to be explicitly run with bash, see the source guidelines.

+
+

System Setup

+

Before even attempting to use a system to build the OpenJDK there are some very basic system setups needed. For all systems:

+
    +
  • Be sure the GNU make utility is version 3.81 (4.0 on windows) or newer, e.g. run "make -version"
  • +
+

* Install a Bootstrap JDK. All OpenJDK builds require access to a previously released JDK called the bootstrap JDK or boot JDK. The general rule is that the bootstrap JDK must be an instance of the previous major release of the JDK. In addition, there may be a requirement to use a release at or beyond a particular update level.

+

Building JDK 9 requires JDK 8. JDK 9 developers should not use JDK 9 as the boot JDK, to ensure that JDK 9 dependencies are not introduced into the parts of the system that are built with JDK 8.

+

The JDK 8 binaries can be downloaded from Oracle's JDK 8 download site. For build performance reasons it is very important that this bootstrap JDK be made available on the local disk of the machine doing the build. You should add its bin directory to the PATH environment variable. If configure has any issues finding this JDK, you may need to use the configure option --with-boot-jdk.

+
    +
  • Ensure that GNU make, the Bootstrap JDK, and the compilers are all in your PATH environment variable.
  • +
+

And for specific systems:

+
    +
  • Linux
  • +
+

Install all the software development packages needed including alsa, freetype, cups, and xrender. See specific system packages.

+
    +
  • Solaris
  • +
+

Install all the software development packages needed including Studio Compilers, freetype, cups, and xrender. See specific system packages.

+ +

Install XCode 6.3

+

Linux

+

With Linux, try and favor the system packages over building your own or getting packages from other areas. Most Linux builds should be possible with the system's available packages.

+

Note that some Linux systems have a habit of pre-populating your environment variables for you, for example JAVA_HOME might get pre-defined for you to refer to the JDK installed on your Linux system. You will need to unset JAVA_HOME. It's a good idea to run env and verify the environment variables you are getting from the default system settings make sense for building the OpenJDK.

+

Solaris

+
Studio Compilers
+

At a minimum, the Studio 12 Update 4 Compilers (containing version 5.13 of the C and C++ compilers) is required, including specific patches.

+

The Solaris Studio installation should contain at least these packages:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
PackageVersion
developer/solarisstudio-124/backend12.4-1.0.6.0
developer/solarisstudio-124/c++12.4-1.0.10.0
developer/solarisstudio-124/cc12.4-1.0.4.0
developer/solarisstudio-124/library/c++-libs12.4-1.0.10.0
developer/solarisstudio-124/library/math-libs12.4-1.0.0.1
developer/solarisstudio-124/library/studio-gccrt12.4-1.0.0.1
developer/solarisstudio-124/studio-common12.4-1.0.0.1
developer/solarisstudio-124/studio-ja12.4-1.0.0.1
developer/solarisstudio-124/studio-legal12.4-1.0.0.1
developer/solarisstudio-124/studio-zhCN12.4-1.0.0.1
+

In particular backend 12.4-1.0.6.0 contains a critical patch for the sparc version.

+

Place the bin directory in PATH.

+

The Oracle Solaris Studio Express compilers at: Oracle Solaris Studio Express Download site are also an option, although these compilers have not been extensively used yet.

+

Windows

+
Windows Unix Toolkit
+

Building on Windows requires a Unix-like environment, notably a Unix-like shell. There are several such environments available of which Cygwin and MinGW/MSYS are currently supported for the OpenJDK build. One of the differences of these systems from standard Windows tools is the way they handle Windows path names, particularly path names which contain spaces, backslashes as path separators and possibly drive letters. Depending on the use case and the specifics of each environment these path problems can be solved by a combination of quoting whole paths, translating backslashes to forward slashes, escaping backslashes with additional backslashes and translating the path names to their "8.3" version.

+
CYGWIN
+

CYGWIN is an open source, Linux-like environment which tries to emulate a complete POSIX layer on Windows. It tries to be smart about path names and can usually handle all kinds of paths if they are correctly quoted or escaped although internally it maps drive letters <drive>: to a virtual directory /cygdrive/<drive>.

+

You can always use the cygpath utility to map pathnames with spaces or the backslash character into the C:/ style of pathname (called 'mixed'), e.g. cygpath -s -m "<path>".

+

Note that the use of CYGWIN creates a unique problem with regards to setting PATH. Normally on Windows the PATH variable contains directories separated with the ";" character (Solaris and Linux use ":"). With CYGWIN, it uses ":", but that means that paths like "C:/path" cannot be placed in the CYGWIN version of PATH and instead CYGWIN uses something like /cygdrive/c/path which CYGWIN understands, but only CYGWIN understands.

+

The OpenJDK build requires CYGWIN version 1.7.16 or newer. Information about CYGWIN can be obtained from the CYGWIN website at www.cygwin.com.

+

By default CYGWIN doesn't install all the tools required for building the OpenJDK. Along with the default installation, you need to install the following tools.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Binary NameCategoryPackageDescription
ar.exeDevelbinutilsThe GNU assembler, linker and binary utilities
make.exeDevelmakeThe GNU version of the 'make' utility built for CYGWIN
m4.exeInterpretersm4GNU implementation of the traditional Unix macro processor
cpio.exeUtilscpioA program to manage archives of files
gawk.exeUtilsawkPattern-directed scanning and processing language
file.exeUtilsfileDetermines file type using 'magic' numbers
zip.exeArchivezipPackage and compress (archive) files
unzip.exeArchiveunzipExtract compressed files in a ZIP archive
free.exeSystemprocpsDisplay amount of free and used memory in the system
+

Note that the CYGWIN software can conflict with other non-CYGWIN software on your Windows system. CYGWIN provides a FAQ for known issues and problems, of particular interest is the section on BLODA (applications that interfere with CYGWIN).

+
MinGW/MSYS
+

MinGW ("Minimalist GNU for Windows") is a collection of free Windows specific header files and import libraries combined with GNU toolsets that allow one to produce native Windows programs that do not rely on any 3rd-party C runtime DLLs. MSYS is a supplement to MinGW which allows building applications and programs which rely on traditional UNIX tools to be present. Among others this includes tools like bash and make. See MinGW/MSYS for more information.

+

Like Cygwin, MinGW/MSYS can handle different types of path formats. They are internally converted to paths with forward slashes and drive letters <drive>: replaced by a virtual directory /<drive>. Additionally, MSYS automatically detects binaries compiled for the MSYS environment and feeds them with the internal, Unix-style path names. If native Windows applications are called from within MSYS programs their path arguments are automatically converted back to Windows style path names with drive letters and backslashes as path separators. This may cause problems for Windows applications which use forward slashes as parameter separator (e.g. cl /nologo /I) because MSYS may wrongly replace such parameters by drive letters.

+

In addition to the tools which will be installed by default, you have to manually install the msys-zip and msys-unzip packages. This can be easily done with the MinGW command line installer:

+
  mingw-get.exe install msys-zip
+  mingw-get.exe install msys-unzip
+
Visual Studio 2013 Compilers
+

The 32-bit and 64-bit OpenJDK Windows build requires Microsoft Visual Studio C++ 2013 (VS2013) Professional Edition or Express compiler. The compiler and other tools are expected to reside in the location defined by the variable VS120COMNTOOLS which is set by the Microsoft Visual Studio installer.

+

Only the C++ part of VS2013 is needed. Try to let the installation go to the default install directory. Always reboot your system after installing VS2013. The system environment variable VS120COMNTOOLS should be set in your environment.

+

Make sure that TMP and TEMP are also set in the environment and refer to Windows paths that exist, like C:\temp, not /tmp, not /cygdrive/c/temp, and not C:/temp. C:\temp is just an example, it is assumed that this area is private to the user, so by default after installs you should see a unique user path in these variables.

+

Mac OS X

+

Make sure you get the right XCode version.

+
+

Configure

+

The basic invocation of the configure script looks like:

+
+

bash ./configure [options]

+
+

This will create an output directory containing the "configuration" and setup an area for the build result. This directory typically looks like:

+
+

build/linux-x64-normal-server-release

+
+

configure will try to figure out what system you are running on and where all necessary build components are. If you have all prerequisites for building installed, it should find everything. If it fails to detect any component automatically, it will exit and inform you about the problem. When this happens, read more below in the configure options.

+

Some examples:

+
+

Windows 32bit build with freetype specified:
+bash ./configure --with-freetype=/cygdrive/c/freetype-i586 --with-target-bits=32

+
+
+

Debug 64bit Build:
+bash ./configure --enable-debug --with-target-bits=64

+
+

Configure Options

+

Complete details on all the OpenJDK configure options can be seen with:

+
+

bash ./configure --help=short

+
+

Use -help to see all the configure options available. You can generate any number of different configurations, e.g. debug, release, 32, 64, etc.

+

Some of the more commonly used configure options are:

+
+

--enable-debug
+set the debug level to fastdebug (this is a shorthand for --with-debug-level=fastdebug)

+
+

+
+

--with-alsa=path
+select the location of the Advanced Linux Sound Architecture (ALSA)

+
+
+

Version 0.9.1 or newer of the ALSA files are required for building the OpenJDK on Linux. These Linux files are usually available from an "alsa" of "libasound" development package, and it's highly recommended that you try and use the package provided by the particular version of Linux that you are using.

+
+
+

--with-boot-jdk=path
+select the Bootstrap JDK

+
+
+

--with-boot-jdk-jvmargs="args"
+provide the JVM options to be used to run the Bootstrap JDK

+
+
+

--with-cacerts=path
+select the path to the cacerts file.

+
+
+

See Certificate Authority on Wikipedia for a better understanding of the Certificate Authority (CA). A certificates file named "cacerts" represents a system-wide keystore with CA certificates. In JDK and JRE binary bundles, the "cacerts" file contains root CA certificates from several public CAs (e.g., VeriSign, Thawte, and Baltimore). The source contain a cacerts file without CA root certificates. Formal JDK builders will need to secure permission from each public CA and include the certificates into their own custom cacerts file. Failure to provide a populated cacerts file will result in verification errors of a certificate chain during runtime. By default an empty cacerts file is provided and that should be fine for most JDK developers.

+
+

+
+

--with-cups=path
+select the CUPS install location

+
+
+

The Common UNIX Printing System (CUPS) Headers are required for building the OpenJDK on Solaris and Linux. The Solaris header files can be obtained by installing the package print/cups.

+
+
+

The CUPS header files can always be downloaded from www.cups.org.

+
+
+

--with-cups-include=path
+select the CUPS include directory location

+
+
+

--with-debug-level=level
+select the debug information level of release, fastdebug, or slowdebug

+
+
+

--with-dev-kit=path
+select location of the compiler install or developer install location

+
+

+
+

--with-freetype=path
+select the freetype files to use.

+
+
+

Expecting the freetype libraries under lib/ and the headers under include/.

+
+
+

Version 2.3 or newer of FreeType is required. On Unix systems required files can be available as part of your distribution (while you still may need to upgrade them). Note that you need development version of package that includes both the FreeType library and header files.

+
+
+

You can always download latest FreeType version from the FreeType website. Building the freetype 2 libraries from scratch is also possible, however on Windows refer to the Windows FreeType DLL build instructions.

+
+
+

Note that by default FreeType is built with byte code hinting support disabled due to licensing restrictions. In this case, text appearance and metrics are expected to differ from Sun's official JDK build. See the SourceForge FreeType2 Home Page for more information.

+
+
+

--with-import-hotspot=path
+select the location to find hotspot binaries from a previous build to avoid building hotspot

+
+
+

--with-target-bits=arg
+select 32 or 64 bit build

+
+
+

--with-jvm-variants=variants
+select the JVM variants to build from, comma separated list that can include: server, client, kernel, zero and zeroshark

+
+
+

--with-memory-size=size
+select the RAM size that GNU make will think this system has

+
+
+

--with-msvcr-dll=path
+select the msvcr100.dll file to include in the Windows builds (C/C++ runtime library for Visual Studio).

+
+
+

This is usually picked up automatically from the redist directories of Visual Studio 2013.

+
+
+

--with-num-cores=cores
+select the number of cores to use (processor count or CPU count)

+
+

+
+

--with-x=path
+select the location of the X11 and xrender files.

+
+
+

The XRender Extension Headers are required for building the OpenJDK on Solaris and Linux. The Linux header files are usually available from a "Xrender" development package, it's recommended that you try and use the package provided by the particular distribution of Linux that you are using. The Solaris XRender header files is included with the other X11 header files in the package SFWxwinc on new enough versions of Solaris and will be installed in /usr/X11/include/X11/extensions/Xrender.h or /usr/openwin/share/include/X11/extensions/Xrender.h

+
+
+

Make

+

The basic invocation of the make utility looks like:

+
+

make all

+
+

This will start the build to the output directory containing the "configuration" that was created by the configure script. Run make help for more information on the available targets.

+

There are some of the make targets that are of general interest:

+
+

empty
+build everything but no images

+
+
+

all
+build everything including images

+
+
+

all-conf
+build all configurations

+
+
+

images
+create complete j2sdk and j2re images

+
+
+

install
+install the generated images locally, typically in /usr/local

+
+
+

clean
+remove all files generated by make, but not those generated by configure

+
+
+

dist-clean
+remove all files generated by both and configure (basically killing the configuration)

+
+
+

help
+give some help on using make, including some interesting make targets

+
+
+

Testing

+

When the build is completed, you should see the generated binaries and associated files in the j2sdk-image directory in the output directory. In particular, the build/*/images/j2sdk-image/bin directory should contain executables for the OpenJDK tools and utilities for that configuration. The testing tool jtreg will be needed and can be found at: the jtreg site. The provided regression tests in the repositories can be run with the command:

+
+

cd test && make PRODUCT_HOME=`pwd`/../build/*/images/j2sdk-image all

+
+
+

Appendix A: Hints and Tips

+

FAQ

+

Q: The generated-configure.sh file looks horrible! How are you going to edit it?
+A: The generated-configure.sh file is generated (think "compiled") by the autoconf tools. The source code is in configure.ac and various .m4 files in common/autoconf, which are much more readable.

+

Q: Why is the generated-configure.sh file checked in, if it is generated?
+A: If it was not generated, every user would need to have the autoconf tools installed, and re-generate the configure file as the first step. Our goal is to minimize the work needed to be done by the user to start building OpenJDK, and to minimize the number of external dependencies required.

+

Q: Do you require a specific version of autoconf for regenerating generated-configure.sh?
+A: Yes, version 2.69 is required and should be easy enough to aquire on all supported operating systems. The reason for this is to avoid large spurious changes in generated-configure.sh.

+

Q: How do you regenerate generated-configure.sh after making changes to the input files?
+A: Regnerating generated-configure.sh should always be done using the script common/autoconf/autogen.sh to ensure that the correct files get updated. This script should also be run after mercurial tries to merge generated-configure.sh as a merge of the generated file is not guaranteed to be correct.

+

Q: What are the files in common/makefiles/support/* for? They look like gibberish.
+A: They are a somewhat ugly hack to compensate for command line length limitations on certain platforms (Windows, Solaris). Due to a combination of limitations in make and the shell, command lines containing too many files will not work properly. These helper files are part of an elaborate hack that will compress the command line in the makefile and then uncompress it safely. We're not proud of it, but it does fix the problem. If you have any better suggestions, we're all ears! :-)

+

Q: I want to see the output of the commands that make runs, like in the old build. How do I do that?
+A: You specify the LOG variable to make. There are several log levels:

+
    +
  • warn -- Default and very quiet.
  • +
  • info -- Shows more progress information than warn.
  • +
  • debug -- Echos all command lines and prints all macro calls for compilation definitions.
  • +
  • trace -- Echos all $(shell) command lines as well.
  • +
+

Q: When do I have to re-run configure?
+A: Normally you will run configure only once for creating a configuration. You need to re-run configuration only if you want to change any configuration options, or if you pull down changes to the configure script.

+

Q: I have added a new source file. Do I need to modify the makefiles?
+A: Normally, no. If you want to create e.g. a new native library, you will need to modify the makefiles. But for normal file additions or removals, no changes are needed. There are certan exceptions for some native libraries where the source files are spread over many directories which also contain sources for other libraries. In these cases it was simply easier to create include lists rather than excludes.

+

Q: When I run configure --help, I see many strange options, like --dvidir. What is this?
+A: Configure provides a slew of options by default, to all projects that use autoconf. Most of them are not used in OpenJDK, so you can safely ignore them. To list only OpenJDK specific features, use configure --help=short instead.

+

Q: configure provides OpenJDK-specific features such as --with-builddeps-server that are not described in this document. What about those?
+A: Try them out if you like! But be aware that most of these are experimental features. Many of them don't do anything at all at the moment; the option is just a placeholder. Others depend on pieces of code or infrastructure that is currently not ready for prime time.

+

Q: How will you make sure you don't break anything?
+A: We have a script that compares the result of the new build system with the result of the old. For most part, we aim for (and achieve) byte-by-byte identical output. There are however technical issues with e.g. native binaries, which might differ in a byte-by-byte comparison, even when building twice with the old build system. For these, we compare relevant aspects (e.g. the symbol table and file size). Note that we still don't have 100% equivalence, but we're close.

+

Q: I noticed this thing X in the build that looks very broken by design. Why don't you fix it?
+A: Our goal is to produce a build output that is as close as technically possible to the old build output. If things were weird in the old build, they will be weird in the new build. Often, things were weird before due to obscurity, but in the new build system the weird stuff comes up to the surface. The plan is to attack these things at a later stage, after the new build system is established.

+

Q: The code in the new build system is not that well-structured. Will you fix this?
+A: Yes! The new build system has grown bit by bit as we converted the old system. When all of the old build system is converted, we can take a step back and clean up the structure of the new build system. Some of this we plan to do before replacing the old build system and some will need to wait until after.

+

Q: Is anything able to use the results of the new build's default make target?
+A: Yes, this is the minimal (or roughly minimal) set of compiled output needed for a developer to actually execute the newly built JDK. The idea is that in an incremental development fashion, when doing a normal make, you should only spend time recompiling what's changed (making it purely incremental) and only do the work that's needed to actually run and test your code. The packaging stuff that is part of the images target is not needed for a normal developer who wants to test his new code. Even if it's quite fast, it's still unnecessary. We're targeting sub-second incremental rebuilds! ;-) (Or, well, at least single-digit seconds...)

+

Q: I usually set a specific environment variable when building, but I can't find the equivalent in the new build. What should I do?
+A: It might very well be that we have neglected to add support for an option that was actually used from outside the build system. Email us and we will add support for it!

+

Build Performance Tips

+

Building OpenJDK requires a lot of horsepower. Some of the build tools can be adjusted to utilize more or less of resources such as parallel threads and memory. The configure script analyzes your system and selects reasonable values for such options based on your hardware. If you encounter resource problems, such as out of memory conditions, you can modify the detected values with:

+
    +
  • --with-num-cores -- number of cores in the build system, e.g. --with-num-cores=8
  • +
  • --with-memory-size -- memory (in MB) available in the build system, e.g. --with-memory-size=1024
  • +
+

It might also be necessary to specify the JVM arguments passed to the Bootstrap JDK, using e.g. --with-boot-jdk-jvmargs="-Xmx8G -enableassertions". Doing this will override the default JVM arguments passed to the Bootstrap JDK.

+

One of the top goals of the new build system is to improve the build performance and decrease the time needed to build. This will soon also apply to the java compilation when the Smart Javac wrapper is fully supported.

+

At the end of a successful execution of configure, you will get a performance summary, indicating how well the build will perform. Here you will also get performance hints. If you want to build fast, pay attention to those!

+

Building with ccache

+

The OpenJDK build supports building with ccache when using gcc or clang. Using ccache can radically speed up compilation of native code if you often rebuild the same sources. Your milage may vary however so we recommend evaluating it for yourself. To enable it, make sure it's on the path and configure with --enable-ccache.

+

Building on local disk

+

If you are using network shares, e.g. via NFS, for your source code, make sure the build directory is situated on local disk. The performance penalty is extremely high for building on a network share, close to unusable.

+

Building only one JVM

+

The old build builds multiple JVMs on 32-bit systems (client and server; and on Windows kernel as well). In the new build we have changed this default to only build server when it's available. This improves build times for those not interested in multiple JVMs. To mimic the old behavior on platforms that support it, use --with-jvm-variants=client,server.

+

Selecting the number of cores to build on

+

By default, configure will analyze your machine and run the make process in parallel with as many threads as you have cores. This behavior can be overridden, either "permanently" (on a configure basis) using --with-num-cores=N or for a single build only (on a make basis), using make JOBS=N.

+

If you want to make a slower build just this time, to save some CPU power for other processes, you can run e.g. make JOBS=2. This will force the makefiles to only run 2 parallel processes, or even make JOBS=1 which will disable parallelism.

+

If you want to have it the other way round, namely having slow builds default and override with fast if you're impatient, you should call configure with --with-num-cores=2, making 2 the default. If you want to run with more cores, run make JOBS=8

+

Troubleshooting

+

Solving build problems

+

If the build fails (and it's not due to a compilation error in a source file you've changed), the first thing you should do is to re-run the build with more verbosity. Do this by adding LOG=debug to your make command line.

+

The build log (with both stdout and stderr intermingled, basically the same as you see on your console) can be found as build.log in your build directory.

+

You can ask for help on build problems with the new build system on either the build-dev or the build-infra-dev mailing lists. Please include the relevant parts of the build log.

+

A build can fail for any number of reasons. Most failures are a result of trying to build in an environment in which all the pre-build requirements have not been met. The first step in troubleshooting a build failure is to recheck that you have satisfied all the pre-build requirements for your platform. Scanning the configure log is a good first step, making sure that what it found makes sense for your system. Look for strange error messages or any difficulties that configure had in finding things.

+

Some of the more common problems with builds are briefly described below, with suggestions for remedies.

+
    +
  • Corrupted Bundles on Windows:
    +Some virus scanning software has been known to corrupt the downloading of zip bundles. It may be necessary to disable the 'on access' or 'real time' virus scanning features to prevent this corruption. This type of 'real time' virus scanning can also slow down the build process significantly. Temporarily disabling the feature, or excluding the build output directory may be necessary to get correct and faster builds.

  • +
  • Slow Builds:
    +If your build machine seems to be overloaded from too many simultaneous C++ compiles, try setting the JOBS=1 on the make command line. Then try increasing the count slowly to an acceptable level for your system. Also:

  • +
+

Creating the javadocs can be very slow, if you are running javadoc, consider skipping that step.

+

Faster CPUs, more RAM, and a faster DISK usually helps. The VM build tends to be CPU intensive (many C++ compiles), and the rest of the JDK will often be disk intensive.

+

Faster compiles are possible using a tool called ccache.

+
    +
  • File time issues:
    +If you see warnings that refer to file time stamps, e.g.
  • +
+
+

Warning message: File 'xxx' has modification time in the future.
+Warning message: Clock skew detected. Your build may be incomplete.

+
+

These warnings can occur when the clock on the build machine is out of sync with the timestamps on the source files. Other errors, apparently unrelated but in fact caused by the clock skew, can occur along with the clock skew warnings. These secondary errors may tend to obscure the fact that the true root cause of the problem is an out-of-sync clock.

+

If you see these warnings, reset the clock on the build machine, run "gmake clobber" or delete the directory containing the build output, and restart the build from the beginning.

+
    +
  • Error message: Trouble writing out table to disk
    +Increase the amount of swap space on your build machine. This could be caused by overloading the system and it may be necessary to use:
  • +
+
+

make JOBS=1

+
+

to reduce the load on the system.

+
    +
  • Error Message: libstdc++ not found:
    +This is caused by a missing libstdc++.a library. This is installed as part of a specific package (e.g. libstdc++.so.devel.386). By default some 64-bit Linux versions (e.g. Fedora) only install the 64-bit version of the libstdc++ package. Various parts of the JDK build require a static link of the C++ runtime libraries to allow for maximum portability of the built images.

  • +
  • Linux Error Message: cannot restore segment prot after reloc
    +This is probably an issue with SELinux (See SELinux on Wikipedia). Parts of the VM is built without the -fPIC for performance reasons.

  • +
+

To completely disable SELinux:

+
    +
  1. $ su root
  2. +
  3. # system-config-securitylevel
  4. +
  5. In the window that appears, select the SELinux tab
  6. +
  7. Disable SELinux
  8. +
+

Alternatively, instead of completely disabling it you could disable just this one check.

+
    +
  1. Select System->Administration->SELinux Management
  2. +
  3. In the SELinux Management Tool which appears, select "Boolean" from the menu on the left
  4. +
  5. Expand the "Memory Protection" group
  6. +
  7. Check the first item, labeled "Allow all unconfined executables to use libraries requiring text relocation ..."
  8. +
+
    +
  • Windows Error Messages:
    +*** fatal error - couldn't allocate heap, ...
    +rm fails with "Directory not empty"
    +unzip fails with "cannot create ... Permission denied"
    +unzip fails with "cannot create ... Error 50"
  • +
+

The CYGWIN software can conflict with other non-CYGWIN software. See the CYGWIN FAQ section on BLODA (applications that interfere with CYGWIN).

+
    +
  • Windows Error Message: spawn failed
    +Try rebooting the system, or there could be some kind of issue with the disk or disk partition being used. Sometimes it comes with a "Permission Denied" message.
  • +
+
+

Appendix B: GNU make

+

The Makefiles in the OpenJDK are only valid when used with the GNU version of the utility command make (usually called gmake on Solaris). A few notes about using GNU make:

+
    +
  • You need GNU make version 3.81 or newer. On Windows 4.0 or newer is recommended. If the GNU make utility on your systems is not of a suitable version, see "Building GNU make".
  • +
  • Place the location of the GNU make binary in the PATH.
  • +
  • Solaris: Do NOT use /usr/bin/make on Solaris. If your Solaris system has the software from the Solaris Developer Companion CD installed, you should try and use /usr/bin/gmake or /usr/gnu/bin/make.
  • +
  • Windows: Make sure you start your build inside a bash shell.
  • +
  • Mac OS X: The XCode "command line tools" must be installed on your Mac.
  • +
+

Information on GNU make, and access to ftp download sites, are available on the GNU make web site. The latest source to GNU make is available at ftp.gnu.org/pub/gnu/make/.

+

Building GNU make

+

First step is to get the GNU make 3.81 or newer source from ftp.gnu.org/pub/gnu/make/. Building is a little different depending on the OS but is basically done with:

+
  bash ./configure
+  make
+
+

Appendix C: Build Environments

+

Minimum Build Environments

+

This file often describes specific requirements for what we call the "minimum build environments" (MBE) for this specific release of the JDK. What is listed below is what the Oracle Release Engineering Team will use to build the Oracle JDK product. Building with the MBE will hopefully generate the most compatible bits that install on, and run correctly on, the most variations of the same base OS and hardware architecture. In some cases, these represent what is often called the least common denominator, but each Operating System has different aspects to it.

+

In all cases, the Bootstrap JDK version minimum is critical, we cannot guarantee builds will work with older Bootstrap JDK's. Also in all cases, more RAM and more processors is better, the minimums listed below are simply recommendations.

+

With Solaris and Mac OS X, the version listed below is the oldest release we can guarantee builds and works, and the specific version of the compilers used could be critical.

+

With Windows the critical aspect is the Visual Studio compiler used, which due to it's runtime, generally dictates what Windows systems can do the builds and where the resulting bits can be used.

+

NOTE: We expect a change here off these older Windows OS releases and to a 'less older' one, probably Windows 2008R2 X64.

+

With Linux, it was just a matter of picking a stable distribution that is a good representative for Linux in general.

+

It is understood that most developers will NOT be using these specific versions, and in fact creating these specific versions may be difficult due to the age of some of this software. It is expected that developers are more often using the more recent releases and distributions of these operating systems.

+

Compilation problems with newer or different C/C++ compilers is a common problem. Similarly, compilation problems related to changes to the /usr/include or system header files is also a common problem with older, newer, or unreleased OS versions. Please report these types of problems as bugs so that they can be dealt with accordingly.

+

Bootstrap JDK: JDK 8

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Base OS and ArchitectureOSC/C++ CompilerProcessorsRAM MinimumDISK Needs
Linux X86 (32-bit) and X64 (64-bit)Oracle Enterprise Linux 6.4gcc 4.9.22 or more1 GB6 GB
Solaris SPARCV9 (64-bit)Solaris 11 Update 1Studio 12 Update 4 + patches4 or more4 GB8 GB
Solaris X64 (64-bit)Solaris 11 Update 1Studio 12 Update 4 + patches4 or more4 GB8 GB
Windows X86 (32-bit)Windows Server 2012 R2 x64Microsoft Visual Studio C++ 2013 Professional Edition2 or more2 GB6 GB
Windows X64 (64-bit)Windows Server 2012 R2 x64Microsoft Visual Studio C++ 2013 Professional Edition2 or more2 GB6 GB
Mac OS X X64 (64-bit)Mac OS X 10.9 "Mavericks"Xcode 6.3 or newer2 or more4 GB6 GB
+
+

Specific Developer Build Environments

+

We won't be listing all the possible environments, but we will try to provide what information we have available to us.

+

NOTE: The community can help out by updating this part of the document.

+

Fedora

+

After installing the latest Fedora you need to install several build dependencies. The simplest way to do it is to execute the following commands as user root:

+
  yum-builddep java-1.7.0-openjdk
+  yum install gcc gcc-c++
+

In addition, it's necessary to set a few environment variables for the build:

+
  export LANG=C
+  export PATH="/usr/lib/jvm/java-openjdk/bin:${PATH}"
+

CentOS 5.5

+

After installing CentOS 5.5 you need to make sure you have the following Development bundles installed:

+
    +
  • Development Libraries
  • +
  • Development Tools
  • +
  • Java Development
  • +
  • X Software Development (Including XFree86-devel)
  • +
+

Plus the following packages:

+
    +
  • cups devel: Cups Development Package
  • +
  • alsa devel: Alsa Development Package
  • +
  • Xi devel: libXi.so Development Package
  • +
+

The freetype 2.3 packages don't seem to be available, but the freetype 2.3 sources can be downloaded, built, and installed easily enough from the freetype site. Build and install with something like:

+
  bash ./configure
+  make
+  sudo -u root make install
+

Mercurial packages could not be found easily, but a Google search should find ones, and they usually include Python if it's needed.

+

Debian 5.0 (Lenny)

+

After installing Debian 5 you need to install several build dependencies. The simplest way to install the build dependencies is to execute the following commands as user root:

+
  aptitude build-dep openjdk-7
+  aptitude install openjdk-7-jdk libmotif-dev
+

In addition, it's necessary to set a few environment variables for the build:

+
  export LANG=C
+  export PATH="/usr/lib/jvm/java-7-openjdk/bin:${PATH}"
+

Ubuntu 12.04

+

After installing Ubuntu 12.04 you need to install several build dependencies. The simplest way to do it is to execute the following commands:

+
  sudo aptitude build-dep openjdk-7
+  sudo aptitude install openjdk-7-jdk
+

In addition, it's necessary to set a few environment variables for the build:

+
  export LANG=C
+  export PATH="/usr/lib/jvm/java-7-openjdk/bin:${PATH}"
+

OpenSUSE 11.1

+

After installing OpenSUSE 11.1 you need to install several build dependencies. The simplest way to install the build dependencies is to execute the following commands:

+
  sudo zypper source-install -d java-1_7_0-openjdk
+  sudo zypper install make
+

In addition, it is necessary to set a few environment variables for the build:

+
  export LANG=C
+  export PATH="/usr/lib/jvm/java-1.7.0-openjdk/bin:$[PATH}"
+

Finally, you need to unset the JAVA_HOME environment variable:

+
  export -n JAVA_HOME`
+

Mandriva Linux One 2009 Spring

+

After installing Mandriva Linux One 2009 Spring you need to install several build dependencies. The simplest way to install the build dependencies is to execute the following commands as user root:

+
  urpmi java-1.7.0-openjdk-devel make gcc gcc-c++ freetype-devel zip unzip
+    libcups2-devel libxrender1-devel libalsa2-devel libstc++-static-devel
+    libxtst6-devel libxi-devel
+

In addition, it is necessary to set a few environment variables for the build:

+
  export LANG=C
+  export PATH="/usr/lib/jvm/java-1.7.0-openjdk/bin:${PATH}"
+

OpenSolaris 2009.06

+

After installing OpenSolaris 2009.06 you need to install several build dependencies. The simplest way to install the build dependencies is to execute the following commands:

+
  pfexec pkg install SUNWgmake SUNWj7dev sunstudioexpress SUNWcups SUNWzip
+    SUNWunzip SUNWxwhl SUNWxorg-headers SUNWaudh SUNWfreetype2
+

In addition, it is necessary to set a few environment variables for the build:

+
  export LANG=C
+  export PATH="/opt/SunStudioExpress/bin:${PATH}"
+
+

End of the OpenJDK build README document.

+

Please come again!

+ + diff --git a/README-builds.md b/common/doc/building.md similarity index 77% rename from README-builds.md rename to common/doc/building.md index c6907cd7ab2..3eb96dfd6e1 100644 --- a/README-builds.md +++ b/common/doc/building.md @@ -1,9 +1,9 @@ +% OpenJDK Build README + ![OpenJDK](http://openjdk.java.net/images/openjdk.png) -# OpenJDK Build README -***** +-------------------------------------------------------------------------------- - ## Introduction This README file contains build instructions for the @@ -19,34 +19,34 @@ Some Headlines: is recommended. * The build should scale, i.e. more processors should cause the build to be done in less wall-clock time - * Nested or recursive make invocations have been significantly reduced, - as has the total fork/exec or spawning of sub processes during the build + * Nested or recursive make invocations have been significantly reduced, as + has the total fork/exec or spawning of sub processes during the build * Windows MKS usage is no longer supported * Windows Visual Studio `vsvars*.bat` and `vcvars*.bat` files are run automatically * Ant is no longer used when building the OpenJDK - * Use of ALT_* environment variables for configuring the build is no longer + * Use of ALT\_\* environment variables for configuring the build is no longer supported -***** +------------------------------------------------------------------------------- ## Contents * [Introduction](#introduction) * [Use of Mercurial](#hg) - * [Getting the Source](#get_source) - * [Repositories](#repositories) + * [Getting the Source](#get_source) + * [Repositories](#repositories) * [Building](#building) - * [System Setup](#setup) - * [Linux](#linux) - * [Solaris](#solaris) - * [Mac OS X](#macosx) - * [Windows](#windows) - * [Configure](#configure) - * [Make](#make) + * [System Setup](#setup) + * [Linux](#linux) + * [Solaris](#solaris) + * [Mac OS X](#macosx) + * [Windows](#windows) + * [Configure](#configure) + * [Make](#make) * [Testing](#testing) -***** +------------------------------------------------------------------------------- * [Appendix A: Hints and Tips](#hints) * [FAQ](#faq) @@ -55,23 +55,22 @@ Some Headlines: * [Appendix B: GNU Make Information](#gmake) * [Appendix C: Build Environments](#buildenvironments) -***** +------------------------------------------------------------------------------- - ## Use of Mercurial The OpenJDK sources are maintained with the revision control system [Mercurial](http://mercurial.selenic.com/wiki/Mercurial). If you are new to -Mercurial, please see the [Beginner Guides](http://mercurial.selenic.com/wiki/ -BeginnersGuides) or refer to the [Mercurial Book](http://hgbook.red-bean.com/). -The first few chapters of the book provide an excellent overview of Mercurial, -what it is and how it works. +Mercurial, please see the [Beginner +Guides](http://mercurial.selenic.com/wiki/BeginnersGuides) or refer to the +[Mercurial Book](http://hgbook.red-bean.com/). The first few chapters of the +book provide an excellent overview of Mercurial, what it is and how it works. For using Mercurial with the OpenJDK refer to the [Developer Guide: Installing -and Configuring Mercurial](http://openjdk.java.net/guide/ -repositories.html#installConfig) section for more information. +and Configuring +Mercurial](http://openjdk.java.net/guide/repositories.html#installConfig) +section for more information. - ### Getting the Source To get the entire set of OpenJDK Mercurial repositories use the script @@ -83,16 +82,15 @@ To get the entire set of OpenJDK Mercurial repositories use the script Once you have all the repositories, keep in mind that each repository is its own independent repository. You can also re-run `./get_source.sh` anytime to -pull over all the latest changesets in all the repositories. This set of -nested repositories has been given the term "forest" and there are various -ways to apply the same `hg` command to each of the repositories. For -example, the script `make/scripts/hgforest.sh` can be used to repeat the -same `hg` command on every repository, e.g. +pull over all the latest changesets in all the repositories. This set of nested +repositories has been given the term "forest" and there are various ways to +apply the same `hg` command to each of the repositories. For example, the +script `make/scripts/hgforest.sh` can be used to repeat the same `hg` command +on every repository, e.g. cd YourOpenJDK bash ./make/scripts/hgforest.sh status - ### Repositories The set of repositories and what they contain: @@ -135,9 +133,8 @@ There are some very basic guidelines: * Files not needed for typical building or testing of the repository should not be added to the repository. -***** +------------------------------------------------------------------------------- - ## Building The very first step in building the OpenJDK is making sure the system itself @@ -148,7 +145,7 @@ Building the OpenJDK is now done with running a `configure` script which will try and find and verify you have everything you need, followed by running `make`, e.g. -> **`bash ./configure`** +> **`bash ./configure`** \ > **`make all`** Where possible the `configure` script will attempt to located the various @@ -161,9 +158,8 @@ system due to missing software packages. **NOTE:** The `configure` script file does not have execute permissions and will need to be explicitly run with `bash`, see the source guidelines. -***** +------------------------------------------------------------------------------- - ### System Setup Before even attempting to use a system to build the OpenJDK there are some very @@ -174,14 +170,14 @@ basic system setups needed. For all systems: * Install a Bootstrap JDK. All OpenJDK builds require access to a previously - released JDK called the _bootstrap JDK_ or _boot JDK._ The general rule is + released JDK called the *bootstrap JDK* or *boot JDK.* The general rule is that the bootstrap JDK must be an instance of the previous major release of the JDK. In addition, there may be a requirement to use a release at or beyond a particular update level. - **_Building JDK 9 requires JDK 8. JDK 9 developers should not use JDK 9 as + ***Building JDK 9 requires JDK 8. JDK 9 developers should not use JDK 9 as the boot JDK, to ensure that JDK 9 dependencies are not introduced into the - parts of the system that are built with JDK 8._** + parts of the system that are built with JDK 8.*** The JDK 8 binaries can be downloaded from Oracle's [JDK 8 download site](http://www.oracle.com/technetwork/java/javase/downloads/index.html). @@ -217,7 +213,6 @@ And for specific systems: Install [XCode 6.3](https://developer.apple.com/xcode/) - #### Linux With Linux, try and favor the system packages over building your own or getting @@ -231,69 +226,29 @@ refer to the JDK installed on your Linux system. You will need to unset you are getting from the default system settings make sense for building the OpenJDK. - #### Solaris - ##### Studio Compilers -At a minimum, the [Studio 12 Update 4 Compilers](http://www.oracle.com/ -technetwork/server-storage/solarisstudio/downloads/index.htm) (containing -version 5.13 of the C and C++ compilers) is required, including specific -patches. +At a minimum, the [Studio 12 Update 4 +Compilers](http://www.oracle.com/technetwork/server-storage/solarisstudio/downloads/index.htm) +(containing version 5.13 of the C and C++ compilers) is required, including +specific patches. The Solaris Studio installation should contain at least these packages: -> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
**Package****Version**
developer/solarisstudio-124/backend12.4-1.0.6.0
developer/solarisstudio-124/c++12.4-1.0.10.0
developer/solarisstudio-124/cc12.4-1.0.4.0
developer/solarisstudio-124/library/c++-libs12.4-1.0.10.0
developer/solarisstudio-124/library/math-libs12.4-1.0.0.1
developer/solarisstudio-124/library/studio-gccrt12.4-1.0.0.1
developer/solarisstudio-124/studio-common12.4-1.0.0.1
developer/solarisstudio-124/studio-ja12.4-1.0.0.1
developer/solarisstudio-124/studio-legal12.4-1.0.0.1
developer/solarisstudio-124/studio-zhCN12.4-1.0.0.1
+ Package Version + -------------------------------------------------- --------------- + developer/solarisstudio-124/backend 12.4-1.0.6.0 + developer/solarisstudio-124/c++ 12.4-1.0.10.0 + developer/solarisstudio-124/cc 12.4-1.0.4.0 + developer/solarisstudio-124/library/c++-libs 12.4-1.0.10.0 + developer/solarisstudio-124/library/math-libs 12.4-1.0.0.1 + developer/solarisstudio-124/library/studio-gccrt 12.4-1.0.0.1 + developer/solarisstudio-124/studio-common 12.4-1.0.0.1 + developer/solarisstudio-124/studio-ja 12.4-1.0.0.1 + developer/solarisstudio-124/studio-legal 12.4-1.0.0.1 + developer/solarisstudio-124/studio-zhCN 12.4-1.0.0.1 In particular backend 12.4-1.0.6.0 contains a critical patch for the sparc version. @@ -301,11 +256,11 @@ version. Place the `bin` directory in `PATH`. The Oracle Solaris Studio Express compilers at: [Oracle Solaris Studio Express -Download site](http://www.oracle.com/technetwork/server-storage/solarisstudio/ -downloads/index-jsp-142582.html) are also an option, although these compilers -have not been extensively used yet. +Download +site](http://www.oracle.com/technetwork/server-storage/solarisstudio/downloads/index-jsp-142582.html) +are also an option, although these compilers have not been extensively used +yet. - #### Windows ##### Windows Unix Toolkit @@ -323,7 +278,6 @@ backslashes to forward slashes, escaping backslashes with additional backslashes and translating the path names to their ["8.3" version](http://en.wikipedia.org/wiki/8.3_filename). - ###### CYGWIN CYGWIN is an open source, Linux-like environment which tries to emulate a @@ -351,80 +305,24 @@ By default CYGWIN doesn't install all the tools required for building the OpenJDK. Along with the default installation, you need to install the following tools. -> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Binary NameCategoryPackageDescription
ar.exeDevelbinutilsThe GNU assembler, linker and binary utilities
make.exeDevelmakeThe GNU version of the 'make' utility built for CYGWIN
m4.exeInterpretersm4GNU implementation of the traditional Unix macro processor
cpio.exeUtilscpioA program to manage archives of files
gawk.exeUtilsawkPattern-directed scanning and processing language
file.exeUtilsfileDetermines file type using 'magic' numbers
zip.exeArchivezipPackage and compress (archive) files
unzip.exeArchiveunzipExtract compressed files in a ZIP archive
free.exeSystemprocpsDisplay amount of free and used memory in the system
+ Binary Name Category Package Description + ------------- -------------- ---------- ------------------------------------------------------------ + ar.exe Devel binutils The GNU assembler, linker and binary utilities + make.exe Devel make The GNU version of the 'make' utility built for CYGWIN + m4.exe Interpreters m4 GNU implementation of the traditional Unix macro processor + cpio.exe Utils cpio A program to manage archives of files + gawk.exe Utils awk Pattern-directed scanning and processing language + file.exe Utils file Determines file type using 'magic' numbers + zip.exe Archive zip Package and compress (archive) files + unzip.exe Archive unzip Extract compressed files in a ZIP archive + free.exe System procps Display amount of free and used memory in the system Note that the CYGWIN software can conflict with other non-CYGWIN software on -your Windows system. CYGWIN provides a [FAQ](http://cygwin.com/faq/ -faq.using.html) for known issues and problems, of particular interest is the -section on [BLODA (applications that interfere with -CYGWIN)](http://cygwin.com/faq/faq.using.html#faq.using.bloda). +your Windows system. CYGWIN provides a +[FAQ](http://cygwin.com/faq/faq.using.html) for known issues and problems, +of particular interest is the section on [BLODA (applications that interfere +with CYGWIN)](http://cygwin.com/faq/faq.using.html#faq.using.bloda). - ###### MinGW/MSYS MinGW ("Minimalist GNU for Windows") is a collection of free Windows specific @@ -432,20 +330,20 @@ header files and import libraries combined with GNU toolsets that allow one to produce native Windows programs that do not rely on any 3rd-party C runtime DLLs. MSYS is a supplement to MinGW which allows building applications and programs which rely on traditional UNIX tools to be present. Among others this -includes tools like `bash` and `make`. See [MinGW/MSYS](http://www.mingw.org/ -wiki/MSYS) for more information. +includes tools like `bash` and `make`. See +[MinGW/MSYS](http://www.mingw.org/wiki/MSYS) for more information. Like Cygwin, MinGW/MSYS can handle different types of path formats. They are -internally converted to paths with forward slashes and drive letters -`:` replaced by a virtual directory `/`. Additionally, MSYS -automatically detects binaries compiled for the MSYS environment and feeds them -with the internal, Unix-style path names. If native Windows applications are -called from within MSYS programs their path arguments are automatically -converted back to Windows style path names with drive letters and backslashes -as path separators. This may cause problems for Windows applications which use -forward slashes as parameter separator (e.g. `cl /nologo /I`) because MSYS may -wrongly [replace such parameters by drive letters](http://mingw.org/wiki/ -Posix_path_conversion). +internally converted to paths with forward slashes and drive letters `:` +replaced by a virtual directory `/`. Additionally, MSYS automatically +detects binaries compiled for the MSYS environment and feeds them with the +internal, Unix-style path names. If native Windows applications are called from +within MSYS programs their path arguments are automatically converted back to +Windows style path names with drive letters and backslashes as path separators. +This may cause problems for Windows applications which use forward slashes as +parameter separator (e.g. `cl /nologo /I`) because MSYS may wrongly [replace +such parameters by drive +letters](http://mingw.org/wiki/Posix_path_conversion). In addition to the tools which will be installed by default, you have to manually install the `msys-zip` and `msys-unzip` packages. This can be easily @@ -454,7 +352,6 @@ done with the MinGW command line installer: mingw-get.exe install msys-zip mingw-get.exe install msys-unzip - ##### Visual Studio 2013 Compilers The 32-bit and 64-bit OpenJDK Windows build requires Microsoft Visual Studio @@ -473,14 +370,12 @@ and not `C:/temp`. `C:\temp` is just an example, it is assumed that this area is private to the user, so by default after installs you should see a unique user path in these variables. - #### Mac OS X Make sure you get the right XCode version. -***** +------------------------------------------------------------------------------- - ### Configure The basic invocation of the `configure` script looks like: @@ -500,14 +395,12 @@ happens, read more below in [the `configure` options](#configureoptions). Some examples: -> **Windows 32bit build with freetype specified:** -> `bash ./configure --with-freetype=/cygdrive/c/freetype-i586 --with-target- -bits=32` +> **Windows 32bit build with freetype specified:** \ +> `bash ./configure --with-freetype=/cygdrive/c/freetype-i586 --with-target-bits=32` -> **Debug 64bit Build:** +> **Debug 64bit Build:** \ > `bash ./configure --enable-debug --with-target-bits=64` - #### Configure Options Complete details on all the OpenJDK `configure` options can be seen with: @@ -519,12 +412,13 @@ number of different configurations, e.g. debug, release, 32, 64, etc. Some of the more commonly used `configure` options are: -> **`--enable-debug`** -> set the debug level to fastdebug (this is a shorthand for `--with-debug- - level=fastdebug`) +> **`--enable-debug`** \ +> set the debug level to fastdebug (this is a shorthand for +> `--with-debug-level=fastdebug`) -> **`--with-alsa=`**_path_ + +> **`--with-alsa=`**_path_ \ > select the location of the Advanced Linux Sound Architecture (ALSA) > Version 0.9.1 or newer of the ALSA files are required for building the @@ -533,29 +427,31 @@ Some of the more commonly used `configure` options are: and use the package provided by the particular version of Linux that you are using. -> **`--with-boot-jdk=`**_path_ +> **`--with-boot-jdk=`**_path_ \ > select the [Bootstrap JDK](#bootjdk) -> **`--with-boot-jdk-jvmargs=`**"_args_" +> **`--with-boot-jdk-jvmargs=`**"_args_" \ > provide the JVM options to be used to run the [Bootstrap JDK](#bootjdk) -> **`--with-cacerts=`**_path_ +> **`--with-cacerts=`**_path_ \ > select the path to the cacerts file. -> See [Certificate Authority on Wikipedia](http://en.wikipedia.org/wiki/ - Certificate_Authority) for a better understanding of the Certificate - Authority (CA). A certificates file named "cacerts" represents a system-wide - keystore with CA certificates. In JDK and JRE binary bundles, the "cacerts" - file contains root CA certificates from several public CAs (e.g., VeriSign, - Thawte, and Baltimore). The source contain a cacerts file without CA root - certificates. Formal JDK builders will need to secure permission from each - public CA and include the certificates into their own custom cacerts file. - Failure to provide a populated cacerts file will result in verification - errors of a certificate chain during runtime. By default an empty cacerts - file is provided and that should be fine for most JDK developers. +> See [Certificate Authority on + Wikipedia](http://en.wikipedia.org/wiki/Certificate_Authority) for a + better understanding of the Certificate Authority (CA). A certificates file + named "cacerts" represents a system-wide keystore with CA certificates. In + JDK and JRE binary bundles, the "cacerts" file contains root CA certificates + from several public CAs (e.g., VeriSign, Thawte, and Baltimore). The source + contain a cacerts file without CA root certificates. Formal JDK builders will + need to secure permission from each public CA and include the certificates + into their own custom cacerts file. Failure to provide a populated cacerts + file will result in verification errors of a certificate chain during + runtime. By default an empty cacerts file is provided and that should be fine + for most JDK developers. -> **`--with-cups=`**_path_ + +> **`--with-cups=`**_path_ \ > select the CUPS install location > The Common UNIX Printing System (CUPS) Headers are required for building the @@ -565,17 +461,18 @@ Some of the more commonly used `configure` options are: > The CUPS header files can always be downloaded from [www.cups.org](http://www.cups.org). -> **`--with-cups-include=`**_path_ +> **`--with-cups-include=`**_path_ \ > select the CUPS include directory location -> **`--with-debug-level=`**_level_ +> **`--with-debug-level=`**_level_ \ > select the debug information level of release, fastdebug, or slowdebug -> **`--with-dev-kit=`**_path_ +> **`--with-dev-kit=`**_path_ \ > select location of the compiler install or developer install location -> **`--with-freetype=`**_path_ + +> **`--with-freetype=`**_path_ \ > select the freetype files to use. > Expecting the freetype libraries under `lib/` and the headers under @@ -597,32 +494,33 @@ Some of the more commonly used `configure` options are: [SourceForge FreeType2 Home Page](http://freetype.sourceforge.net/freetype2) for more information. -> **`--with-import-hotspot=`**_path_ +> **`--with-import-hotspot=`**_path_ \ > select the location to find hotspot binaries from a previous build to avoid building hotspot -> **`--with-target-bits=`**_arg_ +> **`--with-target-bits=`**_arg_ \ > select 32 or 64 bit build -> **`--with-jvm-variants=`**_variants_ +> **`--with-jvm-variants=`**_variants_ \ > select the JVM variants to build from, comma separated list that can include: server, client, kernel, zero and zeroshark -> **`--with-memory-size=`**_size_ +> **`--with-memory-size=`**_size_ \ > select the RAM size that GNU make will think this system has -> **`--with-msvcr-dll=`**_path_ +> **`--with-msvcr-dll=`**_path_ \ > select the `msvcr100.dll` file to include in the Windows builds (C/C++ runtime library for Visual Studio). > This is usually picked up automatically from the redist directories of Visual Studio 2013. -> **`--with-num-cores=`**_cores_ +> **`--with-num-cores=`**_cores_ \ > select the number of cores to use (processor count or CPU count) -> **`--with-x=`**_path_ + +> **`--with-x=`**_path_ \ > select the location of the X11 and xrender files. > The XRender Extension Headers are required for building the OpenJDK on @@ -634,9 +532,8 @@ Some of the more commonly used `configure` options are: installed in `/usr/X11/include/X11/extensions/Xrender.h` or `/usr/openwin/share/include/X11/extensions/Xrender.h` -***** +------------------------------------------------------------------------------- - ### Make The basic invocation of the `make` utility looks like: @@ -649,34 +546,33 @@ more information on the available targets. There are some of the make targets that are of general interest: -> _empty_ +> _empty_ \ > build everything but no images -> **`all`** +> **`all`** \ > build everything including images -> **`all-conf`** +> **`all-conf`** \ > build all configurations -> **`images`** +> **`images`** \ > create complete j2sdk and j2re images -> **`install`** +> **`install`** \ > install the generated images locally, typically in `/usr/local` -> **`clean`** +> **`clean`** \ > remove all files generated by make, but not those generated by `configure` -> **`dist-clean`** +> **`dist-clean`** \ > remove all files generated by both and `configure` (basically killing the configuration) -> **`help`** +> **`help`** \ > give some help on using `make`, including some interesting make targets -***** +------------------------------------------------------------------------------- - ## Testing When the build is completed, you should see the generated binaries and @@ -689,35 +585,33 @@ repositories can be run with the command: > **``cd test && make PRODUCT_HOME=`pwd`/../build/*/images/j2sdk-image all``** -***** +------------------------------------------------------------------------------- - ## Appendix A: Hints and Tips - ### FAQ **Q:** The `generated-configure.sh` file looks horrible! How are you going to -edit it? +edit it? \ **A:** The `generated-configure.sh` file is generated (think "compiled") by the autoconf tools. The source code is in `configure.ac` and various .m4 files in common/autoconf, which are much more readable. -**Q:** Why is the `generated-configure.sh` file checked in, if it is -generated? +**Q:** Why is the `generated-configure.sh` file checked in, if it is +generated? \ **A:** If it was not generated, every user would need to have the autoconf tools installed, and re-generate the `configure` file as the first step. Our goal is to minimize the work needed to be done by the user to start building OpenJDK, and to minimize the number of external dependencies required. **Q:** Do you require a specific version of autoconf for regenerating -`generated-configure.sh`? +`generated-configure.sh`? \ **A:** Yes, version 2.69 is required and should be easy enough to aquire on all supported operating systems. The reason for this is to avoid large spurious changes in `generated-configure.sh`. **Q:** How do you regenerate `generated-configure.sh` after making changes to -the input files? +the input files? \ **A:** Regnerating `generated-configure.sh` should always be done using the script `common/autoconf/autogen.sh` to ensure that the correct files get updated. This script should also be run after mercurial tries to merge @@ -725,7 +619,7 @@ updated. This script should also be run after mercurial tries to merge be correct. **Q:** What are the files in `common/makefiles/support/*` for? They look like -gibberish. +gibberish. \ **A:** They are a somewhat ugly hack to compensate for command line length limitations on certain platforms (Windows, Solaris). Due to a combination of limitations in make and the shell, command lines containing too many files will @@ -735,21 +629,21 @@ not proud of it, but it does fix the problem. If you have any better suggestions, we're all ears! :-) **Q:** I want to see the output of the commands that make runs, like in the old -build. How do I do that? +build. How do I do that? \ **A:** You specify the `LOG` variable to make. There are several log levels: * **`warn`** -- Default and very quiet. * **`info`** -- Shows more progress information than warn. * **`debug`** -- Echos all command lines and prints all macro calls for compilation definitions. - * **`trace`** -- Echos all $(shell) command lines as well. + * **`trace`** -- Echos all \$(shell) command lines as well. -**Q:** When do I have to re-run `configure`? +**Q:** When do I have to re-run `configure`? \ **A:** Normally you will run `configure` only once for creating a configuration. You need to re-run configuration only if you want to change any configuration options, or if you pull down changes to the `configure` script. -**Q:** I have added a new source file. Do I need to modify the makefiles? +**Q:** I have added a new source file. Do I need to modify the makefiles? \ **A:** Normally, no. If you want to create e.g. a new native library, you will need to modify the makefiles. But for normal file additions or removals, no changes are needed. There are certan exceptions for some native libraries where @@ -758,20 +652,21 @@ for other libraries. In these cases it was simply easier to create include lists rather than excludes. **Q:** When I run `configure --help`, I see many strange options, like -`--dvidir`. What is this? +`--dvidir`. What is this? \ **A:** Configure provides a slew of options by default, to all projects that use autoconf. Most of them are not used in OpenJDK, so you can safely ignore them. To list only OpenJDK specific features, use `configure --help=short` instead. -**Q:** `configure` provides OpenJDK-specific features such as `--with- -builddeps-server` that are not described in this document. What about those? +**Q:** `configure` provides OpenJDK-specific features such as +`--with-builddeps-server` that are not described in this document. What about +those? \ **A:** Try them out if you like! But be aware that most of these are experimental features. Many of them don't do anything at all at the moment; the option is just a placeholder. Others depend on pieces of code or infrastructure that is currently not ready for prime time. -**Q:** How will you make sure you don't break anything? +**Q:** How will you make sure you don't break anything? \ **A:** We have a script that compares the result of the new build system with the result of the old. For most part, we aim for (and achieve) byte-by-byte identical output. There are however technical issues with e.g. native binaries, @@ -781,7 +676,7 @@ table and file size). Note that we still don't have 100% equivalence, but we're close. **Q:** I noticed this thing X in the build that looks very broken by design. -Why don't you fix it? +Why don't you fix it? \ **A:** Our goal is to produce a build output that is as close as technically possible to the old build output. If things were weird in the old build, they will be weird in the new build. Often, things were weird before due to @@ -790,14 +685,14 @@ The plan is to attack these things at a later stage, after the new build system is established. **Q:** The code in the new build system is not that well-structured. Will you -fix this? +fix this? \ **A:** Yes! The new build system has grown bit by bit as we converted the old system. When all of the old build system is converted, we can take a step back and clean up the structure of the new build system. Some of this we plan to do before replacing the old build system and some will need to wait until after. **Q:** Is anything able to use the results of the new build's default make -target? +target? \ **A:** Yes, this is the minimal (or roughly minimal) set of compiled output needed for a developer to actually execute the newly built JDK. The idea is that in an incremental development fashion, when doing a normal make, you @@ -809,12 +704,11 @@ it's still unnecessary. We're targeting sub-second incremental rebuilds! ;-) (Or, well, at least single-digit seconds...) **Q:** I usually set a specific environment variable when building, but I can't -find the equivalent in the new build. What should I do? +find the equivalent in the new build. What should I do? \ **A:** It might very well be that we have neglected to add support for an option that was actually used from outside the build system. Email us and we will add support for it! - ### Build Performance Tips Building OpenJDK requires a lot of horsepower. Some of the build tools can be @@ -881,7 +775,6 @@ and override with fast if you're impatient, you should call `configure` with `--with-num-cores=2`, making 2 the default. If you want to run with more cores, run `make JOBS=8` - ### Troubleshooting #### Solving build problems @@ -909,7 +802,7 @@ difficulties that `configure` had in finding things. Some of the more common problems with builds are briefly described below, with suggestions for remedies. - * **Corrupted Bundles on Windows:** + * **Corrupted Bundles on Windows:** \ Some virus scanning software has been known to corrupt the downloading of zip bundles. It may be necessary to disable the 'on access' or 'real time' virus scanning features to prevent this corruption. This type of 'real time' @@ -917,7 +810,7 @@ suggestions for remedies. Temporarily disabling the feature, or excluding the build output directory may be necessary to get correct and faster builds. - * **Slow Builds:** + * **Slow Builds:** \ If your build machine seems to be overloaded from too many simultaneous C++ compiles, try setting the `JOBS=1` on the `make` command line. Then try increasing the count slowly to an acceptable level for your system. Also: @@ -932,10 +825,10 @@ suggestions for remedies. Faster compiles are possible using a tool called [ccache](http://ccache.samba.org/). - * **File time issues:** + * **File time issues:** \ If you see warnings that refer to file time stamps, e.g. - > _Warning message:_ ` File 'xxx' has modification time in the future.` + > _Warning message:_ ` File 'xxx' has modification time in the future.` \ > _Warning message:_ ` Clock skew detected. Your build may be incomplete.` These warnings can occur when the clock on the build machine is out of sync @@ -948,7 +841,7 @@ suggestions for remedies. "`gmake clobber`" or delete the directory containing the build output, and restart the build from the beginning. - * **Error message: `Trouble writing out table to disk`** + * **Error message: `Trouble writing out table to disk`** \ Increase the amount of swap space on your build machine. This could be caused by overloading the system and it may be necessary to use: @@ -956,7 +849,7 @@ suggestions for remedies. to reduce the load on the system. - * **Error Message: `libstdc++ not found`:** + * **Error Message: `libstdc++ not found`:** \ This is caused by a missing libstdc++.a library. This is installed as part of a specific package (e.g. libstdc++.so.devel.386). By default some 64-bit Linux versions (e.g. Fedora) only install the 64-bit version of the @@ -964,7 +857,7 @@ suggestions for remedies. the C++ runtime libraries to allow for maximum portability of the built images. - * **Linux Error Message: `cannot restore segment prot after reloc`** + * **Linux Error Message: `cannot restore segment prot after reloc`** \ This is probably an issue with SELinux (See [SELinux on Wikipedia](http://en.wikipedia.org/wiki/SELinux)). Parts of the VM is built without the `-fPIC` for performance reasons. @@ -979,31 +872,30 @@ suggestions for remedies. Alternatively, instead of completely disabling it you could disable just this one check. - 1. Select System->Administration->SELinux Management + 1. Select System->Administration->SELinux Management 2. In the SELinux Management Tool which appears, select "Boolean" from the menu on the left 3. Expand the "Memory Protection" group 4. Check the first item, labeled "Allow all unconfined executables to use libraries requiring text relocation ..." - * **Windows Error Messages:** - `*** fatal error - couldn't allocate heap, ... ` - `rm fails with "Directory not empty"` - `unzip fails with "cannot create ... Permission denied"` + * **Windows Error Messages:** \ + `*** fatal error - couldn't allocate heap, ... ` \ + `rm fails with "Directory not empty"` \ + `unzip fails with "cannot create ... Permission denied"` \ `unzip fails with "cannot create ... Error 50"` The CYGWIN software can conflict with other non-CYGWIN software. See the CYGWIN FAQ section on [BLODA (applications that interfere with CYGWIN)](http://cygwin.com/faq/faq.using.html#faq.using.bloda). - * **Windows Error Message: `spawn failed`** + * **Windows Error Message: `spawn failed`** \ Try rebooting the system, or there could be some kind of issue with the disk or disk partition being used. Sometimes it comes with a "Permission Denied" message. -***** +------------------------------------------------------------------------------- - ## Appendix B: GNU make The Makefiles in the OpenJDK are only valid when used with the GNU version of @@ -1021,11 +913,10 @@ about using GNU make: * **Mac OS X:** The XCode "command line tools" must be installed on your Mac. Information on GNU make, and access to ftp download sites, are available on the -[GNU make web site ](http://www.gnu.org/software/make/make.html). The latest +[GNU make web site](http://www.gnu.org/software/make/make.html). The latest source to GNU make is available at [ftp.gnu.org/pub/gnu/make/](http://ftp.gnu.org/pub/gnu/make/). - ### Building GNU make First step is to get the GNU make 3.81 or newer source from @@ -1035,9 +926,8 @@ little different depending on the OS but is basically done with: bash ./configure make -***** +------------------------------------------------------------------------------- - ## Appendix C: Build Environments ### Minimum Build Environments @@ -1081,79 +971,19 @@ problem. Similarly, compilation problems related to changes to the newer, or unreleased OS versions. Please report these types of problems as bugs so that they can be dealt with accordingly. -> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Base OS and ArchitectureOSC/C++ CompilerBootstrap JDKProcessorsRAM MinimumDISK Needs
Linux X86 (32-bit) and X64 (64-bit)Oracle Enterprise Linux 6.4gcc 4.9.2 JDK 82 or more1 GB6 GB
Solaris SPARCV9 (64-bit)Solaris 11 Update 1Studio 12 Update 4 + patchesJDK 84 or more4 GB8 GB
Solaris X64 (64-bit)Solaris 11 Update 1Studio 12 Update 4 + patchesJDK 84 or more4 GB8 GB
Windows X86 (32-bit)Windows Server 2012 R2 x64Microsoft Visual Studio C++ 2013 Professional EditionJDK 82 or more2 GB6 GB
Windows X64 (64-bit)Windows Server 2012 R2 x64Microsoft Visual Studio C++ 2013 Professional EditionJDK 82 or more2 GB6 GB
Mac OS X X64 (64-bit)Mac OS X 10.9 "Mavericks"Xcode 6.3 or newerJDK 82 or more4 GB6 GB
+Bootstrap JDK: JDK 8 -***** + Base OS and Architecture OS C/C++ Compiler Processors RAM Minimum DISK Needs + ------------------------------------- ----------------------------- ------------------------------------------------------- ------------ ------------- ------------ + Linux X86 (32-bit) and X64 (64-bit) Oracle Enterprise Linux 6.4 gcc 4.9.2 2 or more 1 GB 6 GB + Solaris SPARCV9 (64-bit) Solaris 11 Update 1 Studio 12 Update 4 + patches 4 or more 4 GB 8 GB + Solaris X64 (64-bit) Solaris 11 Update 1 Studio 12 Update 4 + patches 4 or more 4 GB 8 GB + Windows X86 (32-bit) Windows Server 2012 R2 x64 Microsoft Visual Studio C++ 2013 Professional Edition 2 or more 2 GB 6 GB + Windows X64 (64-bit) Windows Server 2012 R2 x64 Microsoft Visual Studio C++ 2013 Professional Edition 2 or more 2 GB 6 GB + Mac OS X X64 (64-bit) Mac OS X 10.9 "Mavericks" Xcode 6.3 or newer 2 or more 4 GB 6 GB + +------------------------------------------------------------------------------- - ### Specific Developer Build Environments We won't be listing all the possible environments, but we will try to provide @@ -1278,7 +1108,7 @@ In addition, it is necessary to set a few environment variables for the build: export LANG=C export PATH="/opt/SunStudioExpress/bin:${PATH}" -***** +------------------------------------------------------------------------------- End of the OpenJDK build README document. diff --git a/common/doc/testing.html b/common/doc/testing.html new file mode 100644 index 00000000000..777e6a3217f --- /dev/null +++ b/common/doc/testing.html @@ -0,0 +1,116 @@ + + + + + + + Testing OpenJDK + + + + + + +
+

Testing OpenJDK

+
+ +

Using the run-test framework

+

This new way of running tests is developer-centric. It assumes that you have built a jdk locally and want to test it. Running common test targets is simple, and more complex ad-hoc combination of tests is possible. The user interface is forgiving, and clearly report errors it cannot resolve.

+

The main target "run-test" uses the jdk-image as the tested product. There is also an alternate target "exploded-run-test" that uses the exploded image instead. Not all tests will run successfully on the exploded image, but using this target can greatly improve rebuild times for certain workflows.

+

Some example command-lines:

+
$ make run-test-tier1
+$ make run-test-jdk_lang JTREG="JOBS=8"
+$ make run-test TEST=jdk_lang
+$ make run-test-only TEST="gtest:LogTagSet gtest:LogTagSetDescriptions" GTEST="REPEAT=-1"
+$ make run-test TEST="hotspot/test:hotspot_gc" JTREG="JOBS=1;TIMEOUT=8;VM_OTIONS=-XshowSettings -Xlog:gc+ref=debug"
+$ make run-test TEST="jtreg:hotspot/test:hotspot_gc hotspot/test/native_sanity/JniVersion.java"
+$ make exploded-run-test TEST=hotspot_tier1
+

Test selection

+

All functionality is available using the run-test make target. In this use case, the test or tests to be executed is controlled using the TEST variable. To speed up subsequent test runs with no source code changes, run-test-only can be used instead, which do not depend on the source and test image build.

+

For some common top-level tests, direct make targets have been generated. This includes all JTreg test groups, the hotspot gtest, and custom tests (if present). This means that make run-test-tier1 is equivalent to make run-test TEST="tier1", but the latter is more tab-completion friendly. For more complex test runs, the run-test TEST="x" solution needs to be used.

+

The test specifications given in TEST is parsed into fully qualified test descriptors, which clearly and unambigously show which tests will be run. As an example, :tier1 will expand to jtreg:jdk/test:tier1 jtreg:langtools/test:tier1 jtreg:nashorn/test:tier1 jtreg:jaxp/test:tier1. You can always submit a list of fully qualified test descriptors in the TEST variable if you want to shortcut the parser.

+

JTreg

+

JTreg test groups can be specified either without a test root, e.g. :tier1 (or tier1, the initial colon is optional), or with, e.g. hotspot/test:tier1, jdk/test:jdk_util.

+

When specified without a test root, all matching groups from all tests roots will be added. Otherwise, only the group from the specified test root will be added.

+

Individual JTreg tests or directories containing JTreg tests can also be specified, like hotspot/test/native_sanity/JniVersion.java or hotspot/test/native_sanity. You can also specify an absolute path, to point to a JTreg test outside the source tree.

+

As long as the test groups or test paths can be uniquely resolved, you do not need to enter the jtreg: prefix. If this is not possible, or if you want to use a fully qualified test descriptor, add jtreg:, e.g. jtreg:hotspot/test/native_sanity.

+

Gtest

+

Since the Hotspot Gtest suite is so quick, the default is to run all tests. This is specified by just gtest, or as a fully qualified test descriptor gtest:all.

+

If you want, you can single out an individual test or a group of tests, for instance gtest:LogDecorations or gtest:LogDecorations.level_test_vm. This can be particularly useful if you want to run a shaky test repeatedly.

+

Test results and summary

+

At the end of the test run, a summary of all tests run will be presented. This will have a consistent look, regardless of what test suites were used. This is a sample summary:

+
==============================
+Test summary
+==============================
+   TEST                                          TOTAL  PASS  FAIL ERROR
+>> jtreg:jdk/test:tier1                           1867  1865     2     0 <<
+   jtreg:langtools/test:tier1                     4711  4711     0     0
+   jtreg:nashorn/test:tier1                        133   133     0     0
+==============================
+TEST FAILURE
+

Tests where the number of TOTAL tests does not equal the number of PASSed tests will be considered a test failure. These are marked with the >> ... << marker for easy identification.

+

The classification of non-passed tests differs a bit between test suites. In the summary, ERROR is used as a catch-all for tests that neither passed nor are classified as failed by the framework. This might indicate test framework error, timeout or other problems.

+

In case of test failures, make run-test will exit with a non-zero exit value.

+

All tests have their result stored in build/$BUILD/test-result/$TEST_ID, where TEST_ID is a path-safe conversion from the fully qualified test descriptor, e.g. for jtreg:jdk/test:tier1 the TEST_ID is jtreg_jdk_test_tier1. This path is also printed in the log at the end of the test run.

+

Additional work data is stored in build/$BUILD/test-support/$TEST_ID. For some frameworks, this directory might contain information that is useful in determining the cause of a failed test.

+

Test suite control

+

It is possible to control various aspects of the test suites using make control variables.

+

These variables use a keyword=value approach to allow multiple values to be set. So, for instance, JTREG="JOBS=1;TIMEOUT=8" will set the JTreg concurrency level to 1 and the timeout factor to 8. This is equivalent to setting JTREG_JOBS=1 JTREG_TIMEOUT=8, but using the keyword format means that the JTREG variable is parsed and verified for correctness, so JTREG="TMIEOUT=8" would give an error, while JTREG_TMIEOUT=8 would just pass unnoticed.

+

To separate multiple keyword=value pairs, use ; (semicolon). Since the shell normally eats ;, the recommended usage is to write the assignment inside qoutes, e.g. JTREG="...;...". This will also make sure spaces are preserved, as in JTREG="VM_OTIONS=-XshowSettings -Xlog:gc+ref=debug".

+

(Other ways are possible, e.g. using backslash: JTREG=JOBS=1\;TIMEOUT=8. Also, as a special technique, the string %20 will be replaced with space for certain options, e.g. JTREG=VM_OTIONS=-XshowSettings%20-Xlog:gc+ref=debug. This can be useful if you have layers of scripts and have trouble getting proper quoting of command line arguments through.)

+

As far as possible, the names of the keywords have been standardized between test suites.

+

JTreg keywords

+

JOBS

+

The test concurrency (-concurrency).

+

Defaults to TEST_JOBS (if set by --with-test-jobs=), otherwise it defaults to JOBS, except for Hotspot, where the default is number of CPU cores/2, but never more than 12.

+

TIMEOUT

+

The timeout factor (-timeoutFactor).

+

Defaults to 4.

+

TEST_MODE

+

The test mode (-agentvm, -samevm or -othervm).

+

Defaults to -agentvm.

+

ASSERT

+

Enable asserts (-ea -esa, or none).

+

Set to true or false. If true, adds -ea -esa. Defaults to true, except for hotspot.

+

VERBOSE

+

The verbosity level (-verbose).

+

Defaults to fail,error,summary.

+

RETAIN

+

What test data to retain (-retain).

+

Defaults to fail,error.

+

MAX_MEM

+

Limit memory consumption (-Xmx and -vmoption:-Xmx, or none).

+

Limit memory consumption for JTreg test framework and VM under test. Set to 0 to disable the limits.

+

Defaults to 512m, except for hotspot, where it defaults to 0 (no limit).

+

OPTIONS

+

Additional options to the JTreg test framework.

+

Use JTREG="OPTIONS=--help all" to see all available JTreg options.

+

JAVA_OPTIONS

+

Additional Java options to JTreg (-javaoption).

+

VM_OPTIONS

+

Additional VM options to JTreg (-vmoption).

+

Gtest keywords

+

REPEAT

+

The number of times to repeat the tests (--gtest_repeat).

+

Default is 1. Set to -1 to repeat indefinitely. This can be especially useful combined with OPTIONS=--gtest_break_on_failure to reproduce an intermittent problem.

+

OPTIONS

+

Additional options to the Gtest test framework.

+

Use GTEST="OPTIONS=--help" to see all available Gtest options.

+ + diff --git a/common/doc/testing.md b/common/doc/testing.md new file mode 100644 index 00000000000..231755c92b1 --- /dev/null +++ b/common/doc/testing.md @@ -0,0 +1,212 @@ +% Testing OpenJDK + +## Using the run-test framework + +This new way of running tests is developer-centric. It assumes that you have +built a jdk locally and want to test it. Running common test targets is simple, +and more complex ad-hoc combination of tests is possible. The user interface is +forgiving, and clearly report errors it cannot resolve. + +The main target "run-test" uses the jdk-image as the tested product. There is +also an alternate target "exploded-run-test" that uses the exploded image +instead. Not all tests will run successfully on the exploded image, but using +this target can greatly improve rebuild times for certain workflows. + +Some example command-lines: + + $ make run-test-tier1 + $ make run-test-jdk_lang JTREG="JOBS=8" + $ make run-test TEST=jdk_lang + $ make run-test-only TEST="gtest:LogTagSet gtest:LogTagSetDescriptions" GTEST="REPEAT=-1" + $ make run-test TEST="hotspot/test:hotspot_gc" JTREG="JOBS=1;TIMEOUT=8;VM_OTIONS=-XshowSettings -Xlog:gc+ref=debug" + $ make run-test TEST="jtreg:hotspot/test:hotspot_gc hotspot/test/native_sanity/JniVersion.java" + $ make exploded-run-test TEST=hotspot_tier1 + +## Test selection + +All functionality is available using the run-test make target. In this use +case, the test or tests to be executed is controlled using the `TEST` variable. +To speed up subsequent test runs with no source code changes, run-test-only can +be used instead, which do not depend on the source and test image build. + +For some common top-level tests, direct make targets have been generated. This +includes all JTreg test groups, the hotspot gtest, and custom tests (if +present). This means that `make run-test-tier1` is equivalent to `make run-test +TEST="tier1"`, but the latter is more tab-completion friendly. For more complex +test runs, the `run-test TEST="x"` solution needs to be used. + +The test specifications given in `TEST` is parsed into fully qualified test +descriptors, which clearly and unambigously show which tests will be run. As an +example, `:tier1` will expand to `jtreg:jdk/test:tier1 +jtreg:langtools/test:tier1 jtreg:nashorn/test:tier1 jtreg:jaxp/test:tier1`. You +can always submit a list of fully qualified test descriptors in the `TEST` +variable if you want to shortcut the parser. + +### JTreg + +JTreg test groups can be specified either without a test root, e.g. `:tier1` +(or `tier1`, the initial colon is optional), or with, e.g. +`hotspot/test:tier1`, `jdk/test:jdk_util`. + +When specified without a test root, all matching groups from all tests roots +will be added. Otherwise, only the group from the specified test root will be +added. + +Individual JTreg tests or directories containing JTreg tests can also be +specified, like `hotspot/test/native_sanity/JniVersion.java` or +`hotspot/test/native_sanity`. You can also specify an absolute path, to point +to a JTreg test outside the source tree. + +As long as the test groups or test paths can be uniquely resolved, you do not +need to enter the `jtreg:` prefix. If this is not possible, or if you want to +use a fully qualified test descriptor, add `jtreg:`, e.g. +`jtreg:hotspot/test/native_sanity`. + +### Gtest + +Since the Hotspot Gtest suite is so quick, the default is to run all tests. +This is specified by just `gtest`, or as a fully qualified test descriptor +`gtest:all`. + +If you want, you can single out an individual test or a group of tests, for +instance `gtest:LogDecorations` or `gtest:LogDecorations.level_test_vm`. This +can be particularly useful if you want to run a shaky test repeatedly. + +## Test results and summary + +At the end of the test run, a summary of all tests run will be presented. This +will have a consistent look, regardless of what test suites were used. This is +a sample summary: + + ============================== + Test summary + ============================== + TEST TOTAL PASS FAIL ERROR + >> jtreg:jdk/test:tier1 1867 1865 2 0 << + jtreg:langtools/test:tier1 4711 4711 0 0 + jtreg:nashorn/test:tier1 133 133 0 0 + ============================== + TEST FAILURE + +Tests where the number of TOTAL tests does not equal the number of PASSed tests +will be considered a test failure. These are marked with the `>> ... <<` marker +for easy identification. + +The classification of non-passed tests differs a bit between test suites. In +the summary, ERROR is used as a catch-all for tests that neither passed nor are +classified as failed by the framework. This might indicate test framework +error, timeout or other problems. + +In case of test failures, `make run-test` will exit with a non-zero exit value. + +All tests have their result stored in `build/$BUILD/test-result/$TEST_ID`, +where TEST_ID is a path-safe conversion from the fully qualified test +descriptor, e.g. for `jtreg:jdk/test:tier1` the TEST_ID is +`jtreg_jdk_test_tier1`. This path is also printed in the log at the end of the +test run. + +Additional work data is stored in `build/$BUILD/test-support/$TEST_ID`. For +some frameworks, this directory might contain information that is useful in +determining the cause of a failed test. + +## Test suite control + +It is possible to control various aspects of the test suites using make control +variables. + +These variables use a keyword=value approach to allow multiple values to be +set. So, for instance, `JTREG="JOBS=1;TIMEOUT=8"` will set the JTreg +concurrency level to 1 and the timeout factor to 8. This is equivalent to +setting `JTREG_JOBS=1 JTREG_TIMEOUT=8`, but using the keyword format means that +the `JTREG` variable is parsed and verified for correctness, so +`JTREG="TMIEOUT=8"` would give an error, while `JTREG_TMIEOUT=8` would just +pass unnoticed. + +To separate multiple keyword=value pairs, use `;` (semicolon). Since the shell +normally eats `;`, the recommended usage is to write the assignment inside +qoutes, e.g. `JTREG="...;..."`. This will also make sure spaces are preserved, +as in `JTREG="VM_OTIONS=-XshowSettings -Xlog:gc+ref=debug"`. + +(Other ways are possible, e.g. using backslash: `JTREG=JOBS=1\;TIMEOUT=8`. +Also, as a special technique, the string `%20` will be replaced with space for +certain options, e.g. `JTREG=VM_OTIONS=-XshowSettings%20-Xlog:gc+ref=debug`. +This can be useful if you have layers of scripts and have trouble getting +proper quoting of command line arguments through.) + +As far as possible, the names of the keywords have been standardized between +test suites. + +### JTreg keywords + +#### JOBS +The test concurrency (`-concurrency`). + +Defaults to TEST_JOBS (if set by `--with-test-jobs=`), otherwise it defaults to +JOBS, except for Hotspot, where the default is *number of CPU cores/2*, but +never more than 12. + +#### TIMEOUT +The timeout factor (`-timeoutFactor`). + +Defaults to 4. + +#### TEST_MODE +The test mode (`-agentvm`, `-samevm` or `-othervm`). + +Defaults to `-agentvm`. + +#### ASSERT +Enable asserts (`-ea -esa`, or none). + +Set to `true` or `false`. If true, adds `-ea -esa`. Defaults to true, except +for hotspot. + +#### VERBOSE +The verbosity level (`-verbose`). + +Defaults to `fail,error,summary`. + +#### RETAIN +What test data to retain (`-retain`). + +Defaults to `fail,error`. + +#### MAX_MEM +Limit memory consumption (`-Xmx` and `-vmoption:-Xmx`, or none). + +Limit memory consumption for JTreg test framework and VM under test. Set to 0 +to disable the limits. + +Defaults to 512m, except for hotspot, where it defaults to 0 (no limit). + +#### OPTIONS +Additional options to the JTreg test framework. + +Use `JTREG="OPTIONS=--help all"` to see all available JTreg options. + +#### JAVA_OPTIONS +Additional Java options to JTreg (`-javaoption`). + +#### VM_OPTIONS +Additional VM options to JTreg (`-vmoption`). + +### Gtest keywords + +#### REPEAT +The number of times to repeat the tests (`--gtest_repeat`). + +Default is 1. Set to -1 to repeat indefinitely. This can be especially useful +combined with `OPTIONS=--gtest_break_on_failure` to reproduce an intermittent +problem. + +#### OPTIONS +Additional options to the Gtest test framework. + +Use `GTEST="OPTIONS=--help"` to see all available Gtest options. + +--- +# Override some definitions in the global css file that are not optimal for +# this document. +header-includes: + - '' +--- diff --git a/common/nb_native/nbproject/configurations.xml b/common/nb_native/nbproject/configurations.xml index 170dc36b3b8..5aebfbd85a4 100644 --- a/common/nb_native/nbproject/configurations.xml +++ b/common/nb_native/nbproject/configurations.xml @@ -982,52 +982,6 @@ - - - - - agent_util.c - - - compiledMethodLoad.c - - - gctest.c - - - heapTracker.c - - - heapViewer.c - - - java_crw_demo.c - - - minst.c - - - mtrace.c - - - versionCheck.c - - - Agent.cpp - Monitor.cpp - Thread.cpp - waiters.cpp - - - - - - - Poller.c - - - - @@ -1223,7 +1177,7 @@ check_format.c - + compress.c deflate.c gzclose.c @@ -21533,89 +21487,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - DEBUG - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/demo/share/jvmti/waiters - ../../jdk/src/java.base/macosx/native/include - ../../jdk/make - - - DEBUG - - - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/macosx/native/include - ../../jdk/make - - - - - - - ../../jdk/src/demo/share/jvmti/compiledMethodLoad - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/macosx/native/include - ../../jdk/make - - - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/macosx/native/include - ../../jdk/src/demo/share/jvmti/gctest - ../../jdk/make - - - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/macosx/native/include - ../../jdk/src/demo/share/jvmti/heapTracker - ../../jdk/make - - - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/demo/share/jvmti/heapViewer - ../../jdk/src/java.base/macosx/native/include - ../../jdk/make - - - - - - - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/make - - - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/macosx/native/include - ../../jdk/src/demo/share/jvmti/minst - ../../jdk/make - - - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/macosx/native/include - ../../jdk/src/demo/share/jvmti/mtrace - ../../jdk/make - - - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/demo/share/jvmti/versionCheck - ../../jdk/src/java.base/macosx/native/include - ../../jdk/make - - - @@ -36906,106 +36670,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - THIS_FILE="Monitor.cpp" - - - - - - - THIS_FILE="Thread.cpp" - - - - - - - THIS_FILE="waiters.cpp" - - - ../../jdk/src/java.base/unix/native/include ../../jdk/src/java.base/share/native/libjava ../../jdk/src/java.base/unix/native/libjava - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../build/support/headers/java.base ../../make @@ -38304,7 +37968,7 @@ ../../jdk/src/java.base/unix/native/include ../../jdk/src/java.base/share/native/libjava ../../jdk/src/java.base/unix/native/libjava - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../build/support/headers/java.base ../../make @@ -38325,7 +37989,7 @@ ../../jdk/src/java.base/unix/native/include ../../jdk/src/java.base/share/native/libjava ../../jdk/src/java.base/unix/native/libjava - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../build/support/headers/java.base ../../make @@ -38346,7 +38010,7 @@ ../../jdk/src/java.base/unix/native/include ../../jdk/src/java.base/share/native/libjava ../../jdk/src/java.base/unix/native/libjava - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../build/support/headers/java.base ../../make @@ -38367,7 +38031,7 @@ ../../jdk/src/java.base/unix/native/include ../../jdk/src/java.base/share/native/libjava ../../jdk/src/java.base/unix/native/libjava - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../build/support/headers/java.base ../../make @@ -38377,14 +38041,14 @@ - - @@ -38394,7 +38058,7 @@ - @@ -38404,7 +38068,7 @@ - @@ -38414,7 +38078,7 @@ - @@ -38424,7 +38088,7 @@ - @@ -38434,7 +38098,7 @@ - @@ -38444,7 +38108,7 @@ - @@ -38454,7 +38118,7 @@ - @@ -38464,7 +38128,7 @@ - @@ -38474,7 +38138,7 @@ - @@ -38484,7 +38148,7 @@ - @@ -38494,7 +38158,7 @@ - @@ -38504,7 +38168,7 @@ - @@ -38514,7 +38178,7 @@ - @@ -41203,7 +40867,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41232,7 +40896,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41261,7 +40925,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41290,7 +40954,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41319,7 +40983,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41348,7 +41012,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41377,7 +41041,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41406,7 +41070,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41435,7 +41099,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41464,7 +41128,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41493,7 +41157,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41522,7 +41186,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41551,7 +41215,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41580,7 +41244,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41609,7 +41273,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41638,7 +41302,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41667,7 +41331,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41696,7 +41360,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41725,7 +41389,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41754,7 +41418,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41783,7 +41447,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41812,7 +41476,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41841,7 +41505,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41870,7 +41534,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41899,7 +41563,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41928,7 +41592,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41957,7 +41621,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -41986,7 +41650,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42015,7 +41679,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42044,7 +41708,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42073,7 +41737,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42102,7 +41766,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42131,7 +41795,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42160,7 +41824,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42189,7 +41853,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42218,7 +41882,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42247,7 +41911,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42276,7 +41940,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42305,7 +41969,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42334,7 +41998,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42363,7 +42027,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42413,7 +42077,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42442,7 +42106,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -42471,7 +42135,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -46197,183 +45861,6 @@ - - - - DEBUG - - - - - ../../jdk/src/demo/share/jvmti/waiters - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - DEBUG - - - - - - - ../../jdk/src/demo/share/jvmti/heapTracker - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - - - - - ../../jdk/src/demo/share/jvmti/compiledMethodLoad - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="compiledMethodLoad.c" - - - - - - - ../../jdk/src/demo/share/jvmti/gctest - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="gctest.c" - - - - - - - ../../jdk/src/demo/share/jvmti/heapTracker - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="heapTracker.c" - - - - - - - ../../jdk/src/demo/share/jvmti/heapViewer - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="heapViewer.c" - - - - - - - ../../jdk/src/demo/share/jvmti/heapTracker - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="java_crw_demo.c" - - - - - - - ../../jdk/src/demo/share/jvmti/minst - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="minst.c" - - - - - - - ../../jdk/src/demo/share/jvmti/mtrace - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="mtrace.c" - - - - - - - ../../jdk/src/demo/share/jvmti/versionCheck - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/linux/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="versionCheck.c" - - - @@ -46557,7 +46044,7 @@ ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/unix/native/libjli ../../jdk/src/java.base/share/native/libjli - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../make @@ -46639,7 +46126,7 @@ - + ../../jdk/src/java.desktop/share/native/libsplashscreen/giflib @@ -46647,7 +46134,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -46712,7 +46199,7 @@ ../../jdk/src/java.base/unix/native/libjli ../../jdk/src/java.base/share/native/libjli - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../make @@ -47250,7 +46737,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -47598,7 +47085,7 @@ ../../jdk/src/java.desktop/share/native/libsplashscreen ../../jdk/src/java.desktop/share/native/libsplashscreen/libpng ../../jdk/src/java.desktop/unix/native/libsplashscreen - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/linux/native/libjava ../../jdk/src/java.base/unix/native/libjava ../../jdk/src/java.base/share/native/libjava @@ -47996,7 +47483,7 @@ ../../jdk/src/jdk.pack/share/native/common-unpack ../../jdk/src/java.base/share/native/libjava ../../jdk/src/java.base/unix/native/libjava - ../../jdk/src/java.base/share/native/libzip/zlib-1.2.8 + ../../jdk/src/java.base/share/native/libzip/zlib ../../jdk/src/java.base/share/native/include ../../jdk/src/java.base/linux/native/include ../../jdk/src/java.base/unix/native/include @@ -55235,113 +54722,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - THIS_FILE="Monitor.cpp" - - - - - - - THIS_FILE="Thread.cpp" - - - - - - - THIS_FILE="waiters.cpp" - - - - - - - - ../../jdk/src/demo/share/jvmti/waiters - ../../jdk/src/demo/share/jvmti/agent_util ../../jdk/src/java.base/share/native/include ../../jdk/src/java.base/solaris/native/include ../../jdk/src/java.base/unix/native/include @@ -64699,189 +64077,6 @@ - - - - DEBUG - - - - - DEBUG - - - - - - - ../../jdk/src/demo/share/jvmti/heapTracker - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - - - - - ../../jdk/src/demo/share/jvmti/compiledMethodLoad - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="compiledMethodLoad.c" - - - - - - - ../../jdk/src/demo/share/jvmti/gctest - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="gctest.c" - - - - - - - ../../jdk/src/demo/share/jvmti/heapTracker - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="heapTracker.c" - - - - - - - ../../jdk/src/demo/share/jvmti/heapViewer - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="heapViewer.c" - - - - - - - ../../jdk/src/demo/share/jvmti/heapTracker - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="java_crw_demo.c" - - - - - - - ../../jdk/src/demo/share/jvmti/minst - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="minst.c" - - - - - - - ../../jdk/src/demo/share/jvmti/mtrace - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/demo/share/jvmti/java_crw_demo - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="mtrace.c" - - - - - - - ../../jdk/src/demo/share/jvmti/versionCheck - ../../jdk/src/demo/share/jvmti/agent_util - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../jdk/make - - - THIS_FILE="versionCheck.c" - - - - - - - ../../jdk/src/java.base/share/native/include - ../../jdk/src/java.base/solaris/native/include - ../../jdk/src/java.base/unix/native/include - ../../jdk/src/java.base/share/native/libjava - ../../jdk/src/java.base/unix/native/libjava - ../../build/support/demos/classes/jni/Poller - ../../jdk/make - - - THIS_FILE="Poller.c" - - - diff --git a/corba/.hgtags b/corba/.hgtags index 7a24e3f5f23..713dcfc422b 100644 --- a/corba/.hgtags +++ b/corba/.hgtags @@ -396,5 +396,35 @@ f95cc86b6ac22ec1ade5d4f825dc7782adeea228 jdk-9+148 77f827f5bbad3ef795664bc675f72d98d156b9f8 jdk-9+151 ff8cb43c07c069b1debdee44cb88ca22db1ec757 jdk-9+152 68a8e8658511093b322a46ed04b2a321e1da2a43 jdk-9+153 +d66f97a610a6beac987740edc2bf6a70f46ba574 jdk-10+0 078ebe23b584466dc8346e620d7821d91751e5a9 jdk-9+154 a545f54babfa31aa7eb611f36031609acd617cbc jdk-9+155 +907c26240cd481579e919bfd23740797ff8ce1c8 jdk-9+156 +37c9962586a4d3498fa673d93eab1a336acd7652 jdk-10+1 +9383da04b385cca46b7ca67f3a39ac1b673e09fe jdk-9+157 +de6bdf38935fa753183ca288bed5c06a23c0bb12 jdk-9+158 +6feea77d2083c99e44aa3e272d07b7fb3b801683 jdk-9+159 +c7688f2fa07936b089ca0e9a0a0eff68ff37a542 jdk-9+160 +18f02bc43fe96aef36791d0df7aca748485210cc jdk-9+161 +18ffcf99a3b4a10457853d94190e825bdf07e39b jdk-9+162 +493011dee80e51c2a2b064d049183c047df36d80 jdk-9+163 +965bbae3072702f7c0d95c240523b65e6bb19261 jdk-9+164 +a510b2201154abdd12ede42788086b5283bfb9a6 jdk-9+165 +934c18145915b06d3fcc0de1a30f91f5aab8a192 jdk-9+166 +56a8bf5322684e9a31cda64c336c32bcdb592211 jdk-10+2 +3813c94c8585dd7507887916c6943f45051f1b55 jdk-10+3 +5d6d891bb36dbeeacaffa06b5a3e3b4e44b35fbd jdk-10+4 +7c5328012799923d45d1cf87e8725e725b3d298b jdk-10+5 +c7358d703e1282af3dcd8af6c037dc4342de9054 jdk-10+6 +43de67f51801b9e16507865fcb7e8344f4ca4aa9 jdk-9+167 +03a2cc9c8a1e8f87924c9863e917bc8b91770d5f jdk-9+168 +b2218d41edef02ee8f94bb438f885b2ba79bfa08 jdk-9+169 +8a4ab3b0ab9a86df73d9a1e337134f2dbe006725 jdk-9+170 +aed5a4edc8275c1c50195503756ff92bfe0197f5 jdk-10+7 +648b0a00824eb29e71936bc3258d309a25e3b8c0 jdk-10+8 +54c6621f7b34cc6ce6c0882d047f61fe0962c257 jdk-10+9 +c62e5964cfcf144d8f72e9ba69757897785349a9 jdk-9+171 +080c37fd77e2c4629b91059298e37758afbdbc46 jdk-10+10 +95ed14547ca9246baed34f90ef3ca13217538a8c jdk-9+172 +8ef8a0f1c4dfea17e10125e1f885920538e63085 jdk-10+11 +534ba4f8cfcf12accc5b9adb943103f2ff79fe16 jdk-9+173 diff --git a/corba/.jcheck/conf b/corba/.jcheck/conf index 5c6f62dc12c..b2581358014 100644 --- a/corba/.jcheck/conf +++ b/corba/.jcheck/conf @@ -1 +1 @@ -project=jdk9 +project=jdk10 diff --git a/corba/README b/corba/README deleted file mode 100644 index 56825f5ca08..00000000000 --- a/corba/README +++ /dev/null @@ -1,14 +0,0 @@ -README: - This file should be located at the top of the corba Mercurial repository. - - See http://openjdk.java.net/ for more information about the OpenJDK. - - See ../README-builds.html for complete details on build machine requirements. - -Simple Build Instructions: - - cd make && gnumake - - The files that will be imported into the jdk build will be in the "dist" - directory. - diff --git a/corba/src/java.corba/share/classes/com/sun/corba/se/spi/monitoring/package.html b/corba/src/java.corba/share/classes/com/sun/corba/se/spi/monitoring/package.html index 4a72719c0cf..f73b0cbb907 100644 --- a/corba/src/java.corba/share/classes/com/sun/corba/se/spi/monitoring/package.html +++ b/corba/src/java.corba/share/classes/com/sun/corba/se/spi/monitoring/package.html @@ -1,4 +1,4 @@ - + @@ -6,7 +6,7 @@ package - -Provides the mapping of the OMG CORBA APIs to the JavaTM + +Provides the mapping of the OMG CORBA APIs to the Java™ programming language, including the class ORB, which is implemented so that a programmer can use it as a fully-functional Object Request Broker (ORB). @@ -147,9 +147,7 @@ resolve initial object references. These are: register_initial_reference(String id, org.omg.CORBA.Object obj) -

An example that uses some of these methods is -Getting Started with Java IDL. +

An example that uses some of these methods is {@extLink idl_getting_started Getting Started with Java IDL}.

Exceptions

@@ -158,9 +156,8 @@ Java programming language. If a method is defined to throw an exception, then any code using that method must have a try/catch block and handle that exception when it is thrown. -

The documentation on Java -IDL exceptions has more information and explains the difference between +

The documentation on {@extLink jidlexception Java IDL exceptions } +has more information and explains the difference between system exceptions and user-defined exceptions.

The following is a list of the system exceptions (which are unchecked @@ -427,7 +424,7 @@ will contain the static methods needed for manipulating instances of the type, in this case, Account objects. - +

The narrow Method

When an object is the return value for a method, it is returned in the form of a generic object, either an org.omg.CORBA.Object object @@ -447,8 +444,8 @@ object, whereas the narrow method for an interface that is abstract will take an object in the Java programming language. The helper class for a non-abstract interface that has at least one abstract base interface will provide both versions of the narrow method. -

The Hello World -tutorial uses a narrow method that looks like this: +

The {@extLink idl_guides Hello World tutorial} +uses a narrow method that looks like this:

         // create and initialize the ORB
         ORB orb = ORB.init(args, null);
@@ -465,7 +462,7 @@ tutorial uses a narrow method that looks like this:
         helloImpl = HelloHelper.narrow(ncRef.resolve_str(name));
 
- +

Example of a Basic Helper Class

A basic helper class, for purposes of this explanation, is one with the methods that are provided by every helper class, plus a narrow @@ -548,6 +545,7 @@ abstract public class AccountHelper } +

Value Type Helper Classes

A helper class for a value type includes different renderings of the same methods generated for non-value type methods. The main difference @@ -671,7 +669,7 @@ abstract public class AddressHelper      WStringSeqHelper      WStringValueHelper - +

Other Classes

The other classes and interfaces in the CORBA package, which are @@ -861,24 +859,24 @@ ValueMember Related Documentation For overviews, guides, and a tutorial, please see:
    -
  • -Java IDL home page +
  • {@extLink idl_guides Java IDL tutorial page}.
  • +
  • {@extLink rmi_iiop_guides RMI-IIOP developer's guide}.
-

+

CORBA Features Not Implemented in Java IDL

Some of the API included in org.omg subpackages is provided for conformance with the current OMG CORBA specification but is not implemented -in Sun's release of the JDKTM. This enables +in Sun's release of the JDK™. This enables other JDK licensees to provide implementations of this API in standard extensions and products. -

+

Features That Throw NO_IMPLEMENT

Some of the API included in org.omg subpackages throw diff --git a/corba/src/java.corba/share/classes/org/omg/CORBA/portable/package.html b/corba/src/java.corba/share/classes/org/omg/CORBA/portable/package.html index c8f6b33ae37..e0f5cbb0372 100644 --- a/corba/src/java.corba/share/classes/org/omg/CORBA/portable/package.html +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/portable/package.html @@ -1,8 +1,8 @@ - + - + Provides a portability layer, that is, a set of ORB APIs that makes it possible for code generated @@ -38,7 +38,7 @@ can call into these ORB APIs.

- +


CORBA Features Throwing NO_IMPLEMENT() Exceptions


diff --git a/corba/src/java.corba/share/classes/org/omg/CORBA_2_3/package.html b/corba/src/java.corba/share/classes/org/omg/CORBA_2_3/package.html index c1869b1c512..7a82edb9275 100644 --- a/corba/src/java.corba/share/classes/org/omg/CORBA_2_3/package.html +++ b/corba/src/java.corba/share/classes/org/omg/CORBA_2_3/package.html @@ -1,4 +1,4 @@ - + @@ -6,7 +6,7 @@ package - + The CORBA_2_3 package defines additions to existing CORBA interfaces in the Java[tm] Standard Edition 6.   These changes occurred in recent revisions to the CORBA API defined by the OMG.  The new methods were @@ -46,7 +46,7 @@ the Java[tm] Platform, Standard Edition 6, ORB complies, see Official Specifications for CORBA support in Java[tm] SE 6.

- + The following methods in the abstract class org.omg.CORBA_2_3.ORB are unimplemented:

    diff --git a/corba/src/java.corba/share/classes/org/omg/CosNaming/package.html b/corba/src/java.corba/share/classes/org/omg/CosNaming/package.html index 3e13aef2342..265485464f1 100644 --- a/corba/src/java.corba/share/classes/org/omg/CosNaming/package.html +++ b/corba/src/java.corba/share/classes/org/omg/CosNaming/package.html @@ -3,7 +3,7 @@ - + Provides a mechanism to register ORB hooks through which ORB services can intercept the normal flow of execution of the ORB. @@ -52,7 +52,7 @@ See the javadocs for class {@link org.omg.PortableInterceptor.ORBInitializer ORBInitializer} for how to go about registering interceptors. - +

    Known limitations / unimplemented methods in package org.omg.PortableInterceptor

    diff --git a/corba/src/java.corba/share/classes/org/omg/PortableServer/package.html b/corba/src/java.corba/share/classes/org/omg/PortableServer/package.html index cabb3b46055..ab441f9cee8 100644 --- a/corba/src/java.corba/share/classes/org/omg/PortableServer/package.html +++ b/corba/src/java.corba/share/classes/org/omg/PortableServer/package.html @@ -1,9 +1,9 @@ - + - + Provides classes and interfaces for making the server side of your applications portable across multivendor ORBs. @@ -157,10 +157,10 @@ follows exactly the same pattern as the other holder classes for basic types.

    Related Documentation

    For an overview of Java IDL, please see: -Java IDL home page. +{@extLink idl_guides Java IDL home page}.

    Example Code

    - +

    Example Server Code

     import javax.naming.InitialContext;
    diff --git a/corba/src/java.corba/share/classes/sun/corba/Bridge.java b/corba/src/java.corba/share/classes/sun/corba/Bridge.java
    index 1b3a086c088..e22240e2a9f 100644
    --- a/corba/src/java.corba/share/classes/sun/corba/Bridge.java
    +++ b/corba/src/java.corba/share/classes/sun/corba/Bridge.java
    @@ -59,10 +59,10 @@ import sun.reflect.ReflectionFactory;
      * 
* The code that calls Bridge.get() must have the following Permissions: *
    - *
  • RuntimePermission "reflectionFactoryAccess"
  • *
  • BridgePermission "getBridge"
  • *
  • ReflectPermission "suppressAccessChecks"
  • - *
  • StackFramePermission "retainClassReference"
  • + *
  • RuntimePermission "getStackWalkerWithClassReference"
  • + *
  • RuntimePermission "reflectionFactoryAccess"
  • *
*

* All of these permissions are required to obtain and correctly initialize @@ -105,10 +105,10 @@ public final class Bridge /** Fetch the Bridge singleton. This requires the following * permissions: *

    - *
  • RuntimePermission "reflectionFactoryAccess"
  • *
  • BridgePermission "getBridge"
  • *
  • ReflectPermission "suppressAccessChecks"
  • - *
  • StackFramePermission "retainClassReference"
  • + *
  • RuntimePermission "getStackWalkerWithClassReference"
  • + *
  • RuntimePermission "reflectionFactoryAccess"
  • *
* @return The singleton instance of the Bridge class * @throws SecurityException if the caller does not have the diff --git a/hotspot/.hgignore b/hotspot/.hgignore index 0c053adb87c..db11ccf9c54 100644 --- a/hotspot/.hgignore +++ b/hotspot/.hgignore @@ -15,10 +15,10 @@ ^\.mx.jvmci/hotspot/eclipse/.* ^\.idea/ ^workingsets.xml -^src/jdk.vm.ci/share/classes/\w[\w\.]*/.*\.xml -^src/jdk.vm.ci/share/classes/\w[\w\.]*/.*\.iml -^src/jdk.vm.ci/share/classes/\w[\w\.]*/nbproject -^src/jdk.vm.ci/share/classes/\w[\w\.]*/\..* +^src/jdk.internal.vm.ci/share/classes/\w[\w\.]*/.*\.xml +^src/jdk.internal.vm.ci/share/classes/\w[\w\.]*/.*\.iml +^src/jdk.internal.vm.ci/share/classes/\w[\w\.]*/nbproject +^src/jdk.internal.vm.ci/share/classes/\w[\w\.]*/\..* ^test/compiler/jvmci/\w[\w\.]*/.*\.xml ^test/compiler/jvmci/\w[\w\.]*/.*\.iml ^test/compiler/jvmci/\w[\w\.]*/nbproject @@ -27,15 +27,15 @@ ^test/compiler/aot/\w[\w\.]*/.*\.iml ^test/compiler/aot/\w[\w\.]*/nbproject ^test/compiler/aot/\w[\w\.]*/\..* -^src/jdk.vm.compiler/\.mx.graal/env -^src/jdk.vm.compiler/\.mx.graal/.*\.pyc -^src/jdk.vm.compiler/\.mx.graal/eclipse-launches/.* +^src/jdk.internal.vm.compiler/\.mx.graal/env +^src/jdk.internal.vm.compiler/\.mx.graal/.*\.pyc +^src/jdk.internal.vm.compiler/\.mx.graal/eclipse-launches/.* ^src/jdk.aot/share/classes/\w[\w\.]*/.*\.xml ^src/jdk.aot/share/classes/\w[\w\.]*/.*\.iml ^src/jdk.aot/share/classes/\w[\w\.]*/nbproject ^src/jdk.aot/share/classes/\w[\w\.]*/\..* -^src/jdk.vm.compiler/share/classes/\w[\w\.]*/.*\.xml -^src/jdk.vm.compiler/share/classes/\w[\w\.]*/.*\.iml -^src/jdk.vm.compiler/share/classes/\w[\w\.]*/nbproject -^src/jdk.vm.compiler/share/classes/\w[\w\.]*/\..* +^src/jdk.internal.vm.compiler/share/classes/\w[\w\.]*/.*\.xml +^src/jdk.internal.vm.compiler/share/classes/\w[\w\.]*/.*\.iml +^src/jdk.internal.vm.compiler/share/classes/\w[\w\.]*/nbproject +^src/jdk.internal.vm.compiler/share/classes/\w[\w\.]*/\..* diff --git a/hotspot/.hgtags b/hotspot/.hgtags index 66afb5ed54b..d5ca9df7b00 100644 --- a/hotspot/.hgtags +++ b/hotspot/.hgtags @@ -556,5 +556,35 @@ a82cb5350cad96a0b4de496afebe3ded89f27efa jdk-9+146 2a2ac7d9f52c8cb2b80077e515b5840b947e640c jdk-9+151 31f1d26c60df7b2e516a4f84160d76ba017d4e09 jdk-9+152 217ba81b9a4ce8698200370175aa2db86a39f66c jdk-9+153 +fc7e94cb748507366b839e859f865f724467446a jdk-10+0 a9fdfd55835ef9dccb7f317b07249bd66653b874 jdk-9+154 f3b3d77a1751897413aae43ac340a130b6fa2ae1 jdk-9+155 +43139c588ea48b6504e52b6c3dec530b17b1fdb4 jdk-9+156 +1ea217626ba0995dd03127f8322ba3687926a085 jdk-10+1 +b2d0a906afd73dcf27f572217eb1be0f196ec16c jdk-9+157 +4e78f30935229f13ce7c43089621cf7169f5abac jdk-9+158 +9211c2e89c1cd11ec2d5752b0f97131a7d7525c7 jdk-9+159 +94b4e2e5331d38eab6a3639c3511b2e0715df0e9 jdk-9+160 +191ffbdb3d7b734288daa7fb76b37a0a85dfe7eb jdk-9+161 +b01c519b715ef6f785d0631adee0a6537cf6c12e jdk-9+162 +983fe207555724d98f4876991e1cbafbcf2733e8 jdk-9+163 +0af429be8bbaeaaf0cb838e9af28c953dda6a9c8 jdk-9+164 +c92c6416ca03b1464d5ed99cf6201e52b5ba0a70 jdk-9+165 +560d7aa083a24b6a56443feb8de0f40435d33aa9 jdk-9+166 +48809c513ed5ebb4d4dbf2f454afcce2780db6db jdk-10+2 +6c3b6b3438c4a63e619f00bd5732d1260ffd5600 jdk-10+3 +8295ca08f5cb09c090eb048bbdd338d7e270c8bf jdk-10+4 +7b5ca2ff1f78873ca3ee99b6589d3cb4dde2e454 jdk-10+5 +762465099d938fd96cd1efda193bc1fa23d070d3 jdk-10+6 +1ca7ed1b17b5776930d641d1379834f3140a74e4 jdk-9+167 +fbb9c802649585d19f6d7e81b4a519d44806225a jdk-9+168 +16d692be099c5c38eb48cc9aca78b0c900910d5b jdk-9+169 +38a240fd58a287acb1963920b92ed4d9c2fd39e3 jdk-9+170 +9d4746eca95aec3e5a344bf2520745dcc1d17eed jdk-10+7 +f5ded0cf954c770deeecb80f2ba1ba6a05cd979b jdk-10+8 +233647e3d3800e76d7612014b745b37a88098f63 jdk-10+9 +d53171650a2cc6c6f699c966c533b914ca9c0602 jdk-9+171 +c6cd3ec8d46b034e57c86399380ffcf7f25706e4 jdk-10+10 +1ae9e84f68b359420d2d153ecfe5ee2903e33a2e jdk-9+172 +7f14e550f1e8abea41c223e5fdad2261e99ba929 jdk-10+11 +e64b1cb48d6e7703928a9d1da106fc27f8cb65fd jdk-9+173 diff --git a/hotspot/.jcheck/conf b/hotspot/.jcheck/conf index 5c6f62dc12c..b2581358014 100644 --- a/hotspot/.jcheck/conf +++ b/hotspot/.jcheck/conf @@ -1 +1 @@ -project=jdk9 +project=jdk10 diff --git a/hotspot/.mx.jvmci/.pydevproject b/hotspot/.mx.jvmci/.pydevproject index b127d241c79..3f852ee834a 100644 --- a/hotspot/.mx.jvmci/.pydevproject +++ b/hotspot/.mx.jvmci/.pydevproject @@ -3,7 +3,7 @@ Default python 2.7 -/.mx.jvmci +/mx.jvmci /mx diff --git a/hotspot/.mx.jvmci/mx_jvmci.py b/hotspot/.mx.jvmci/mx_jvmci.py index daa27f5d607..37a9baff97e 100644 --- a/hotspot/.mx.jvmci/mx_jvmci.py +++ b/hotspot/.mx.jvmci/mx_jvmci.py @@ -158,8 +158,8 @@ To build hotspot and import it into the JDK: "mx make hotspot import-hotspot" # JDK9 must be bootstrapped with a JDK8 compliance = mx.JavaCompliance('8') jdk8 = mx.get_jdk(compliance.exactMatch, versionDescription=compliance.value) - cmd = ['sh', 'configure', '--with-debug-level=' + _vm.debugLevel, '--with-native-debug-symbols=external', '--disable-precompiled-headers', - '--with-jvm-variants=' + _vm.jvmVariant, '--disable-warnings-as-errors', '--with-boot-jdk=' + jdk8.home] + cmd = ['sh', 'configure', '--with-debug-level=' + _vm.debugLevel, '--with-native-debug-symbols=external', '--disable-precompiled-headers', '--with-jvm-features=graal', + '--with-jvm-variants=' + _vm.jvmVariant, '--disable-warnings-as-errors', '--with-boot-jdk=' + jdk8.home, '--with-jvm-features=graal'] mx.run(cmd, cwd=_jdkSourceRoot) cmd = [mx.gmake_cmd(), 'CONF=' + _vm.debugLevel] if mx.get_opts().verbose: @@ -176,66 +176,6 @@ To build hotspot and import it into the JDK: "mx make hotspot import-hotspot" mx.run(cmd, cwd=_jdkSourceRoot) - if 'images' in cmd: - jdkImageDir = join(jdkBuildDir, 'images', 'jdk') - - # The OpenJDK build creates an empty cacerts file so copy one from - # the default JDK (which is assumed to be an OracleJDK) - srcCerts = join(mx.get_jdk(tag='default').home, 'lib', 'security', 'cacerts') - if not exists(srcCerts): - # Might be building with JDK8 which has cacerts under jre/ - srcCerts = join(mx.get_jdk(tag='default').home, 'jre', 'lib', 'security', 'cacerts') - dstCerts = join(jdkImageDir, 'lib', 'security', 'cacerts') - if srcCerts != dstCerts: - shutil.copyfile(srcCerts, dstCerts) - - _create_jdk_bundle(jdkBuildDir, _vm.debugLevel, jdkImageDir) - -def _get_jdk_bundle_arches(): - """ - Gets a list of names that will be the part of a JDK bundle's file name denoting the architecture. - The first element in the list is the canonical name. Symlinks should be created for the - remaining names. - """ - cpu = mx.get_arch() - if cpu == 'amd64': - return ['x64', 'x86_64', 'amd64'] - elif cpu == 'sparcv9': - return ['sparcv9'] - mx.abort('Unsupported JDK bundle arch: ' + cpu) - -def _create_jdk_bundle(jdkBuildDir, debugLevel, jdkImageDir): - """ - Creates a tar.gz JDK archive, an accompanying tar.gz.sha1 file with its - SHA1 signature plus symlinks to the archive for non-canonical architecture names. - """ - - arches = _get_jdk_bundle_arches() - jdkTgzPath = join(_suite.get_output_root(), 'jdk-bundles', 'jdk9-{}-{}-{}.tar.gz'.format(debugLevel, _get_openjdk_os(), arches[0])) - with mx.Archiver(jdkTgzPath, kind='tgz') as arc: - mx.log('Creating ' + jdkTgzPath) - for root, _, filenames in os.walk(jdkImageDir): - for name in filenames: - f = join(root, name) - arcname = 'jdk1.9.0/' + os.path.relpath(f, jdkImageDir) - arc.zf.add(name=f, arcname=arcname, recursive=False) - - with open(jdkTgzPath + '.sha1', 'w') as fp: - mx.log('Creating ' + jdkTgzPath + '.sha1') - fp.write(mx.sha1OfFile(jdkTgzPath)) - - def _create_link(source, link_name): - if exists(link_name): - os.remove(link_name) - mx.log('Creating ' + link_name + ' -> ' + source) - os.symlink(source, link_name) - - for arch in arches[1:]: - link_name = join(_suite.get_output_root(), 'jdk-bundles', 'jdk9-{}-{}-{}.tar.gz'.format(debugLevel, _get_openjdk_os(), arch)) - jdkTgzName = os.path.basename(jdkTgzPath) - _create_link(jdkTgzName, link_name) - _create_link(jdkTgzName + '.sha1', link_name + '.sha1') - def _runmultimake(args): """run the JDK make process for one or more configurations""" @@ -363,9 +303,9 @@ class HotSpotProject(mx.NativeProject): out.close('link') out.open('link') - out.element('name', data='generated') + out.element('name', data='gensrc') out.element('type', data='2') - generated = join(_get_hotspot_build_dir(jvmVariant, debugLevel), 'generated') + generated = join(_get_hotspot_build_dir(jvmVariant, debugLevel), 'gensrc') out.element('locationURI', data=mx.get_eclipse_project_rel_locationURI(generated, eclProjectDir)) out.close('link') @@ -680,18 +620,12 @@ _jvmci_bootclasspath_prepends = [] def _get_hotspot_build_dir(jvmVariant=None, debugLevel=None): """ Gets the directory in which a particular HotSpot configuration is built - (e.g., /build/macosx-x86_64-normal-server-release/hotspot/bsd_amd64_compiler2) + (e.g., /build/macosx-x86_64-normal-server-release/hotspot/variant-) """ if jvmVariant is None: jvmVariant = _vm.jvmVariant - os = mx.get_os() - if os == 'darwin': - os = 'bsd' - arch = mx.get_arch() - buildname = {'client': 'compiler1', 'server': 'compiler2'}.get(jvmVariant, jvmVariant) - - name = '{}_{}_{}'.format(os, arch, buildname) + name = 'variant-{}'.format(jvmVariant) return join(_get_jdk_build_dir(debugLevel=debugLevel), 'hotspot', name) class JVMCI9JDKConfig(mx.JDKConfig): diff --git a/hotspot/.mx.jvmci/suite.py b/hotspot/.mx.jvmci/suite.py index 359c2b2ae3a..9415623d92b 100644 --- a/hotspot/.mx.jvmci/suite.py +++ b/hotspot/.mx.jvmci/suite.py @@ -43,7 +43,7 @@ suite = { # ------------- JVMCI:Service ------------- "jdk.vm.ci.services" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "javaCompliance" : "9", "workingSets" : "API,JVMCI", @@ -52,7 +52,7 @@ suite = { # ------------- JVMCI:API ------------- "jdk.vm.ci.common" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "checkstyle" : "jdk.vm.ci.services", "javaCompliance" : "9", @@ -60,7 +60,7 @@ suite = { }, "jdk.vm.ci.meta" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "checkstyle" : "jdk.vm.ci.services", "javaCompliance" : "9", @@ -68,7 +68,7 @@ suite = { }, "jdk.vm.ci.code" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : ["jdk.vm.ci.meta"], "checkstyle" : "jdk.vm.ci.services", @@ -92,7 +92,7 @@ suite = { }, "jdk.vm.ci.runtime" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : [ "jdk.vm.ci.code", @@ -119,7 +119,7 @@ suite = { # ------------- JVMCI:HotSpot ------------- "jdk.vm.ci.aarch64" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : ["jdk.vm.ci.code"], "checkstyle" : "jdk.vm.ci.services", @@ -128,7 +128,7 @@ suite = { }, "jdk.vm.ci.amd64" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : ["jdk.vm.ci.code"], "checkstyle" : "jdk.vm.ci.services", @@ -137,7 +137,7 @@ suite = { }, "jdk.vm.ci.sparc" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : ["jdk.vm.ci.code"], "checkstyle" : "jdk.vm.ci.services", @@ -146,7 +146,7 @@ suite = { }, "jdk.vm.ci.hotspot" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : [ "jdk.vm.ci.common", @@ -175,7 +175,7 @@ suite = { }, "jdk.vm.ci.hotspot.aarch64" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : [ "jdk.vm.ci.aarch64", @@ -187,7 +187,7 @@ suite = { }, "jdk.vm.ci.hotspot.amd64" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : [ "jdk.vm.ci.amd64", @@ -199,7 +199,7 @@ suite = { }, "jdk.vm.ci.hotspot.sparc" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "sourceDirs" : ["src"], "dependencies" : [ "jdk.vm.ci.sparc", @@ -221,12 +221,12 @@ suite = { # ------------- Distributions ------------- "JVMCI_SERVICES" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "dependencies" : ["jdk.vm.ci.services"], }, "JVMCI_API" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "dependencies" : [ "jdk.vm.ci.runtime", "jdk.vm.ci.common", @@ -240,7 +240,7 @@ suite = { }, "JVMCI_HOTSPOT" : { - "subDir" : "src/jdk.vm.ci/share/classes", + "subDir" : "src/jdk.internal.vm.ci/share/classes", "dependencies" : [ "jdk.vm.ci.hotspot.aarch64", "jdk.vm.ci.hotspot.amd64", diff --git a/hotspot/README b/hotspot/README deleted file mode 100644 index 19afb261fc3..00000000000 --- a/hotspot/README +++ /dev/null @@ -1,14 +0,0 @@ -README: - This file should be located at the top of the hotspot Mercurial repository. - - See http://openjdk.java.net/ for more information about the OpenJDK. - - See ../README-builds.html for complete details on build machine requirements. - -Simple Build Instructions: - - cd make && gnumake - - The files that will be imported into the jdk build will be in the "build" - directory. - diff --git a/hotspot/make/CompileTools.gmk b/hotspot/make/CompileTools.gmk index ea6c504e283..c80632226cf 100644 --- a/hotspot/make/CompileTools.gmk +++ b/hotspot/make/CompileTools.gmk @@ -38,9 +38,9 @@ TARGETS := $(eval $(call IncludeCustomExtension, hotspot, CompileTools.gmk)) ifeq ($(INCLUDE_GRAAL), true) - VM_CI_SRC_DIR := $(HOTSPOT_TOPDIR)/src/jdk.vm.ci/share/classes + VM_CI_SRC_DIR := $(HOTSPOT_TOPDIR)/src/jdk.internal.vm.ci/share/classes - SRC_DIR := $(HOTSPOT_TOPDIR)/src/jdk.vm.compiler/share/classes + SRC_DIR := $(HOTSPOT_TOPDIR)/src/jdk.internal.vm.compiler/share/classes ############################################################################## # Compile the annotation processors diff --git a/hotspot/make/gensrc/Gensrc-jdk.vm.compiler.gmk b/hotspot/make/gensrc/Gensrc-jdk.internal.vm.compiler.gmk similarity index 77% rename from hotspot/make/gensrc/Gensrc-jdk.vm.compiler.gmk rename to hotspot/make/gensrc/Gensrc-jdk.internal.vm.compiler.gmk index f12a2e9a5a2..a8e60309b1c 100644 --- a/hotspot/make/gensrc/Gensrc-jdk.vm.compiler.gmk +++ b/hotspot/make/gensrc/Gensrc-jdk.internal.vm.compiler.gmk @@ -28,7 +28,7 @@ default: all include $(SPEC) include MakeBase.gmk -$(eval $(call IncludeCustomExtension, hotspot, gensrc/Gensrc-jdk.vm.compiler.gmk)) +$(eval $(call IncludeCustomExtension, hotspot, gensrc/Gensrc-jdk.internal.vm.compiler.gmk)) GENSRC_DIR := $(SUPPORT_OUTPUTDIR)/gensrc/$(MODULE) SRC_DIR := $(HOTSPOT_TOPDIR)/src/$(MODULE)/share/classes @@ -81,23 +81,24 @@ PROCESSOR_JARS := \ PROCESSOR_PATH := $(call PathList, $(PROCESSOR_JARS)) ADD_EXPORTS := \ - --add-exports jdk.vm.ci/jdk.vm.ci.aarch64=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.amd64=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.code=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.code.site=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.code.stack=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.common=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.hotspot=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.hotspot.aarch64=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.hotspot.amd64=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.hotspot.events=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.hotspot.sparc=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.hotspotvmconfig=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.inittimer=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.meta=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.runtime=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.services=ALL-UNNAMED \ - --add-exports jdk.vm.ci/jdk.vm.ci.sparc=ALL-UNNAMED \ + --add-modules jdk.internal.vm.ci \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.aarch64=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.amd64=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code.site=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code.stack=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.common=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.aarch64=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.amd64=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.events=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.sparc=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspotvmconfig=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.inittimer=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.meta=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.runtime=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.services=ALL-UNNAMED \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.sparc=ALL-UNNAMED \ # $(GENSRC_DIR)/_gensrc_proc_done: $(PROC_SRCS) $(PROCESSOR_JARS) @@ -138,7 +139,7 @@ $(GENSRC_DIR)/module-info.java.extra: $(GENSRC_DIR)/_gensrc_proc_done $(ECHO) "uses org.graalvm.compiler.options.OptionDescriptors;" >> $@; \ $(ECHO) "provides org.graalvm.compiler.options.OptionDescriptors with" >> $@; \ for i in $$($(FIND) $(GENSRC_DIR) -name '*_OptionDescriptors.java'); do \ - c=$$($(ECHO) $$i | $(SED) 's:.*/jdk\.vm\.compiler/\(.*\)\.java:\1:' | $(TR) '/' '.'); \ + c=$$($(ECHO) $$i | $(SED) 's:.*/jdk\.internal\.vm\.compiler/\(.*\)\.java:\1:' | $(TR) '/' '.'); \ $(ECHO) " $$c," >> $@; \ done; \ $(ECHO) " ;" >> $@; diff --git a/hotspot/make/ide/CreateVSProject.gmk b/hotspot/make/ide/CreateVSProject.gmk index db0aca87e28..2a9da913ab7 100644 --- a/hotspot/make/ide/CreateVSProject.gmk +++ b/hotspot/make/ide/CreateVSProject.gmk @@ -112,8 +112,10 @@ ifeq ($(OPENJDK_TARGET_OS), windows) -relativeSrcInclude src \ -hidePath .hg \ -hidePath .jcheck \ + -hidePath jdk.aot \ -hidePath jdk.hotspot.agent \ - -hidePath jdk.vm.ci \ + -hidePath jdk.internal.vm.ci \ + -hidePath jdk.internal.vm.compiler \ -hidePath jdk.jfr \ -compiler VC10 \ -jdkTargetRoot $(call FixPath, $(JDK_OUTPUTDIR)) \ diff --git a/hotspot/make/lib/CompileJvm.gmk b/hotspot/make/lib/CompileJvm.gmk index 36d955807ad..4eb2cbc1013 100644 --- a/hotspot/make/lib/CompileJvm.gmk +++ b/hotspot/make/lib/CompileJvm.gmk @@ -118,6 +118,12 @@ ifeq ($(OPENJDK_TARGET_CPU), x86_64) OPENJDK_TARGET_CPU_VM_VERSION := amd64 else ifeq ($(OPENJDK_TARGET_CPU), sparcv9) OPENJDK_TARGET_CPU_VM_VERSION := sparc +else ifeq ($(HOTSPOT_TARGET_CPU_ARCH), arm) + ifeq ($(OPENJDK_TARGET_CPU), aarch64) + # This sets the Oracle Aarch64 port to use arm64 + # while the original Aarch64 port uses aarch64 + OPENJDK_TARGET_CPU_VM_VERSION := arm64 + endif else OPENJDK_TARGET_CPU_VM_VERSION := $(OPENJDK_TARGET_CPU) endif diff --git a/hotspot/make/templates/gpl-cp-header b/hotspot/make/templates/gpl-cp-header deleted file mode 100644 index f5b3943c4c9..00000000000 --- a/hotspot/make/templates/gpl-cp-header +++ /dev/null @@ -1,22 +0,0 @@ -Copyright (c) %YEARS%, Oracle and/or its affiliates. All rights reserved. -DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - -This code is free software; you can redistribute it and/or modify it -under the terms of the GNU General Public License version 2 only, as -published by the Free Software Foundation. Oracle designates this -particular file as subject to the "Classpath" exception as provided -by Oracle in the LICENSE file that accompanied this code. - -This code is distributed in the hope that it will be useful, but WITHOUT -ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -version 2 for more details (a copy is included in the LICENSE file that -accompanied this code). - -You should have received a copy of the GNU General Public License version -2 along with this work; if not, write to the Free Software Foundation, -Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - -Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -or visit www.oracle.com if you need additional information or have any -questions. diff --git a/hotspot/make/templates/gpl-header b/hotspot/make/templates/gpl-header deleted file mode 100644 index 9eadb48b613..00000000000 --- a/hotspot/make/templates/gpl-header +++ /dev/null @@ -1,20 +0,0 @@ -Copyright (c) %YEARS%, Oracle and/or its affiliates. All rights reserved. -DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - -This code is free software; you can redistribute it and/or modify it -under the terms of the GNU General Public License version 2 only, as -published by the Free Software Foundation. - -This code is distributed in the hope that it will be useful, but WITHOUT -ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -version 2 for more details (a copy is included in the LICENSE file that -accompanied this code). - -You should have received a copy of the GNU General Public License version -2 along with this work; if not, write to the Free Software Foundation, -Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - -Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -or visit www.oracle.com if you need additional information or have any -questions. diff --git a/hotspot/make/test/JtregNative.gmk b/hotspot/make/test/JtregNative.gmk index 7223733367a..42eb76af57e 100644 --- a/hotspot/make/test/JtregNative.gmk +++ b/hotspot/make/test/JtregNative.gmk @@ -1,5 +1,5 @@ # -# Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -48,6 +48,8 @@ BUILD_HOTSPOT_JTREG_NATIVE_SRC := \ $(HOTSPOT_TOPDIR)/test/runtime/jni/PrivateInterfaceMethods \ $(HOTSPOT_TOPDIR)/test/runtime/jni/ToStringInInterfaceTest \ $(HOTSPOT_TOPDIR)/test/runtime/jni/CalleeSavedRegisters \ + $(HOTSPOT_TOPDIR)/test/runtime/jni/CallWithJNIWeak \ + $(HOTSPOT_TOPDIR)/test/runtime/jni/ReturnJNIWeak \ $(HOTSPOT_TOPDIR)/test/runtime/modules/getModuleJNI \ $(HOTSPOT_TOPDIR)/test/runtime/SameObject \ $(HOTSPOT_TOPDIR)/test/runtime/BoolReturn \ diff --git a/hotspot/src/cpu/aarch64/vm/aarch64.ad b/hotspot/src/cpu/aarch64/vm/aarch64.ad index 37e63dc9aba..cf3fd216364 100644 --- a/hotspot/src/cpu/aarch64/vm/aarch64.ad +++ b/hotspot/src/cpu/aarch64/vm/aarch64.ad @@ -577,7 +577,7 @@ reg_class no_special_reg32_with_fp( R26 /* R27, */ // heapbase /* R28, */ // thread - /* R29, */ // fp + R29, // fp /* R30, */ // lr /* R31 */ // sp ); @@ -646,7 +646,7 @@ reg_class no_special_reg_with_fp( R26, R26_H, /* R27, R27_H, */ // heapbase /* R28, R28_H, */ // thread - /* R29, R29_H, */ // fp + R29, R29_H, // fp /* R30, R30_H, */ // lr /* R31, R31_H */ // sp ); @@ -14021,10 +14021,12 @@ instruct clearArray_reg_reg(iRegL_R11 cnt, iRegP_R10 base, Universe dummy, rFlag ins_pipe(pipe_class_memory); %} -instruct clearArray_imm_reg(immL cnt, iRegP_R10 base, iRegL_R11 tmp, Universe dummy, rFlagsReg cr) +instruct clearArray_imm_reg(immL cnt, iRegP_R10 base, Universe dummy, rFlagsReg cr) %{ + predicate((u_int64_t)n->in(2)->get_long() + < (u_int64_t)(BlockZeroingLowLimit >> LogBytesPerWord)); match(Set dummy (ClearArray cnt base)); - effect(USE_KILL base, TEMP tmp); + effect(USE_KILL base); ins_cost(4 * INSN_COST); format %{ "ClearArray $cnt, $base" %} @@ -15501,7 +15503,7 @@ instruct string_compareLU(iRegP_R1 str1, iRegI_R2 cnt1, iRegP_R3 str2, iRegI_R4 %} instruct string_indexofUU(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, iRegI_R2 cnt2, - iRegI_R0 result, iRegI tmp1, iRegI tmp2, iRegI tmp3, iRegI tmp4, rFlagsReg cr) + iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, iRegINoSp tmp3, iRegINoSp tmp4, rFlagsReg cr) %{ predicate(((StrIndexOfNode*)n)->encoding() == StrIntrinsicNode::UU); match(Set result (StrIndexOf (Binary str1 cnt1) (Binary str2 cnt2))); @@ -15520,7 +15522,7 @@ instruct string_indexofUU(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, iRegI_R2 %} instruct string_indexofLL(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, iRegI_R2 cnt2, - iRegI_R0 result, iRegI tmp1, iRegI tmp2, iRegI tmp3, iRegI tmp4, rFlagsReg cr) + iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, iRegINoSp tmp3, iRegINoSp tmp4, rFlagsReg cr) %{ predicate(((StrIndexOfNode*)n)->encoding() == StrIntrinsicNode::LL); match(Set result (StrIndexOf (Binary str1 cnt1) (Binary str2 cnt2))); @@ -15539,7 +15541,7 @@ instruct string_indexofLL(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, iRegI_R2 %} instruct string_indexofUL(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, iRegI_R2 cnt2, - iRegI_R0 result, iRegI tmp1, iRegI tmp2, iRegI tmp3, iRegI tmp4, rFlagsReg cr) + iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, iRegINoSp tmp3, iRegINoSp tmp4, rFlagsReg cr) %{ predicate(((StrIndexOfNode*)n)->encoding() == StrIntrinsicNode::UL); match(Set result (StrIndexOf (Binary str1 cnt1) (Binary str2 cnt2))); @@ -15558,7 +15560,7 @@ instruct string_indexofUL(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, iRegI_R2 %} instruct string_indexofLU(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, iRegI_R2 cnt2, - iRegI_R0 result, iRegI tmp1, iRegI tmp2, iRegI tmp3, iRegI tmp4, rFlagsReg cr) + iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, iRegINoSp tmp3, iRegINoSp tmp4, rFlagsReg cr) %{ predicate(((StrIndexOfNode*)n)->encoding() == StrIntrinsicNode::LU); match(Set result (StrIndexOf (Binary str1 cnt1) (Binary str2 cnt2))); @@ -15577,8 +15579,8 @@ instruct string_indexofLU(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, iRegI_R2 %} instruct string_indexof_conUU(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, - immI_le_4 int_cnt2, iRegI_R0 result, iRegI tmp1, iRegI tmp2, - iRegI tmp3, iRegI tmp4, rFlagsReg cr) + immI_le_4 int_cnt2, iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, + iRegINoSp tmp3, iRegINoSp tmp4, rFlagsReg cr) %{ predicate(((StrIndexOfNode*)n)->encoding() == StrIntrinsicNode::UU); match(Set result (StrIndexOf (Binary str1 cnt1) (Binary str2 int_cnt2))); @@ -15598,8 +15600,8 @@ instruct string_indexof_conUU(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, %} instruct string_indexof_conLL(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, - immI_le_4 int_cnt2, iRegI_R0 result, iRegI tmp1, iRegI tmp2, - iRegI tmp3, iRegI tmp4, rFlagsReg cr) + immI_le_4 int_cnt2, iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, + iRegINoSp tmp3, iRegINoSp tmp4, rFlagsReg cr) %{ predicate(((StrIndexOfNode*)n)->encoding() == StrIntrinsicNode::LL); match(Set result (StrIndexOf (Binary str1 cnt1) (Binary str2 int_cnt2))); @@ -15619,8 +15621,8 @@ instruct string_indexof_conLL(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, %} instruct string_indexof_conUL(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, - immI_1 int_cnt2, iRegI_R0 result, iRegI tmp1, iRegI tmp2, - iRegI tmp3, iRegI tmp4, rFlagsReg cr) + immI_1 int_cnt2, iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, + iRegINoSp tmp3, iRegINoSp tmp4, rFlagsReg cr) %{ predicate(((StrIndexOfNode*)n)->encoding() == StrIntrinsicNode::UL); match(Set result (StrIndexOf (Binary str1 cnt1) (Binary str2 int_cnt2))); @@ -15640,8 +15642,8 @@ instruct string_indexof_conUL(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, %} instruct string_indexof_conLU(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, - immI_1 int_cnt2, iRegI_R0 result, iRegI tmp1, iRegI tmp2, - iRegI tmp3, iRegI tmp4, rFlagsReg cr) + immI_1 int_cnt2, iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, + iRegINoSp tmp3, iRegINoSp tmp4, rFlagsReg cr) %{ predicate(((StrIndexOfNode*)n)->encoding() == StrIntrinsicNode::LU); match(Set result (StrIndexOf (Binary str1 cnt1) (Binary str2 int_cnt2))); @@ -15661,8 +15663,8 @@ instruct string_indexof_conLU(iRegP_R1 str1, iRegI_R4 cnt1, iRegP_R3 str2, %} instruct string_indexofU_char(iRegP_R1 str1, iRegI_R2 cnt1, iRegI_R3 ch, - iRegI_R0 result, iRegI tmp1, iRegI tmp2, - iRegI tmp3, rFlagsReg cr) + iRegI_R0 result, iRegINoSp tmp1, iRegINoSp tmp2, + iRegINoSp tmp3, rFlagsReg cr) %{ match(Set result (StrIndexOfChar (Binary str1 cnt1) ch)); effect(USE_KILL str1, USE_KILL cnt1, USE_KILL ch, @@ -16101,7 +16103,7 @@ instruct replicate2D(vecX dst, vRegD src) // ====================REDUCTION ARITHMETIC==================================== -instruct reduce_add2I(iRegINoSp dst, iRegIorL2I src1, vecD src2, iRegI tmp, iRegI tmp2) +instruct reduce_add2I(iRegINoSp dst, iRegIorL2I src1, vecD src2, iRegINoSp tmp, iRegINoSp tmp2) %{ match(Set dst (AddReductionVI src1 src2)); ins_cost(INSN_COST); @@ -16120,7 +16122,7 @@ instruct reduce_add2I(iRegINoSp dst, iRegIorL2I src1, vecD src2, iRegI tmp, iReg ins_pipe(pipe_class_default); %} -instruct reduce_add4I(iRegINoSp dst, iRegIorL2I src1, vecX src2, vecX tmp, iRegI tmp2) +instruct reduce_add4I(iRegINoSp dst, iRegIorL2I src1, vecX src2, vecX tmp, iRegINoSp tmp2) %{ match(Set dst (AddReductionVI src1 src2)); ins_cost(INSN_COST); @@ -16138,7 +16140,7 @@ instruct reduce_add4I(iRegINoSp dst, iRegIorL2I src1, vecX src2, vecX tmp, iRegI ins_pipe(pipe_class_default); %} -instruct reduce_mul2I(iRegINoSp dst, iRegIorL2I src1, vecD src2, iRegI tmp) +instruct reduce_mul2I(iRegINoSp dst, iRegIorL2I src1, vecD src2, iRegINoSp tmp) %{ match(Set dst (MulReductionVI src1 src2)); ins_cost(INSN_COST); @@ -16157,7 +16159,7 @@ instruct reduce_mul2I(iRegINoSp dst, iRegIorL2I src1, vecD src2, iRegI tmp) ins_pipe(pipe_class_default); %} -instruct reduce_mul4I(iRegINoSp dst, iRegIorL2I src1, vecX src2, vecX tmp, iRegI tmp2) +instruct reduce_mul4I(iRegINoSp dst, iRegIorL2I src1, vecX src2, vecX tmp, iRegINoSp tmp2) %{ match(Set dst (MulReductionVI src1 src2)); ins_cost(INSN_COST); diff --git a/hotspot/src/cpu/aarch64/vm/assembler_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/assembler_aarch64.cpp index ceaec5d53ec..57bc7b2d340 100644 --- a/hotspot/src/cpu/aarch64/vm/assembler_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/assembler_aarch64.cpp @@ -1,8 +1,7 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights All rights reserved. + * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2014, Red Hat Inc. All rights reserved. - * 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 * under the terms of the GNU General Public License version 2 only, as @@ -21,7 +20,6 @@ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. - * */ #include diff --git a/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.cpp index b139a44f9a1..0016aa9ba6a 100644 --- a/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.cpp @@ -1922,12 +1922,17 @@ void LIR_Assembler::comp_op(LIR_Condition condition, LIR_Opr opr1, LIR_Opr opr2, } if (opr2->is_constant()) { + bool is_32bit = false; // width of register operand jlong imm; + switch(opr2->type()) { + case T_INT: + imm = opr2->as_constant_ptr()->as_jint(); + is_32bit = true; + break; case T_LONG: imm = opr2->as_constant_ptr()->as_jlong(); break; - case T_INT: case T_ADDRESS: imm = opr2->as_constant_ptr()->as_jint(); break; @@ -1942,14 +1947,14 @@ void LIR_Assembler::comp_op(LIR_Condition condition, LIR_Opr opr1, LIR_Opr opr2, } if (Assembler::operand_valid_for_add_sub_immediate(imm)) { - if (type2aelembytes(opr1->type()) <= 4) + if (is_32bit) __ cmpw(reg1, imm); else __ cmp(reg1, imm); return; } else { __ mov(rscratch1, imm); - if (type2aelembytes(opr1->type()) <= 4) + if (is_32bit) __ cmpw(reg1, rscratch1); else __ cmp(reg1, rscratch1); diff --git a/hotspot/src/cpu/aarch64/vm/c1_LIRGenerator_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/c1_LIRGenerator_aarch64.cpp index 96793e632b9..5abe4281aa2 100644 --- a/hotspot/src/cpu/aarch64/vm/c1_LIRGenerator_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/c1_LIRGenerator_aarch64.cpp @@ -1221,12 +1221,19 @@ void LIRGenerator::do_CheckCast(CheckCast* x) { obj.load_item(); // info for exceptions - CodeEmitInfo* info_for_exception = state_for(x); + CodeEmitInfo* info_for_exception = + (x->needs_exception_state() ? state_for(x) : + state_for(x, x->state_before(), true /*ignore_xhandler*/)); CodeStub* stub; if (x->is_incompatible_class_change_check()) { assert(patching_info == NULL, "can't patch this"); stub = new SimpleExceptionStub(Runtime1::throw_incompatible_class_change_error_id, LIR_OprFact::illegalOpr, info_for_exception); + } else if (x->is_invokespecial_receiver_check()) { + assert(patching_info == NULL, "can't patch this"); + stub = new DeoptimizeStub(info_for_exception, + Deoptimization::Reason_class_check, + Deoptimization::Action_none); } else { stub = new SimpleExceptionStub(Runtime1::throw_class_cast_exception_id, obj.result(), info_for_exception); } @@ -1340,6 +1347,16 @@ void LIRGenerator::volatile_field_store(LIR_Opr value, LIR_Address* address, void LIRGenerator::volatile_field_load(LIR_Address* address, LIR_Opr result, CodeEmitInfo* info) { + // 8179954: We need to make sure that the code generated for + // volatile accesses forms a sequentially-consistent set of + // operations when combined with STLR and LDAR. Without a leading + // membar it's possible for a simple Dekker test to fail if loads + // use LD;DMB but stores use STLR. This can happen if C2 compiles + // the stores in one method and C1 compiles the loads in another. + if (! UseBarriersForVolatile) { + __ membar(); + } + __ volatile_load_mem_reg(address, result, info); } diff --git a/hotspot/src/cpu/aarch64/vm/c1_globals_aarch64.hpp b/hotspot/src/cpu/aarch64/vm/c1_globals_aarch64.hpp index 71d7819561e..3177a8980b9 100644 --- a/hotspot/src/cpu/aarch64/vm/c1_globals_aarch64.hpp +++ b/hotspot/src/cpu/aarch64/vm/c1_globals_aarch64.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2014, Red Hat Inc. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -45,10 +45,8 @@ define_pd_global(bool, TieredCompilation, false); // We compile very aggressively with the builtin simulator because // doing so greatly reduces run times and tests more code. define_pd_global(intx, CompileThreshold, 150 ); -define_pd_global(intx, BackEdgeThreshold, 500); #else define_pd_global(intx, CompileThreshold, 1500 ); -define_pd_global(intx, BackEdgeThreshold, 100000); #endif define_pd_global(intx, OnStackReplacePercentage, 933 ); @@ -76,6 +74,4 @@ define_pd_global(bool, OptimizeSinglePrecision, true ); define_pd_global(bool, CSEArrayLength, false); define_pd_global(bool, TwoOperandLIRForm, false ); -define_pd_global(intx, SafepointPollOffset, 0 ); - #endif // CPU_AARCH64_VM_C1_GLOBALS_AARCH64_HPP diff --git a/hotspot/src/cpu/aarch64/vm/c2_globals_aarch64.hpp b/hotspot/src/cpu/aarch64/vm/c2_globals_aarch64.hpp index 9a16dd76967..5a5d8ac4f95 100644 --- a/hotspot/src/cpu/aarch64/vm/c2_globals_aarch64.hpp +++ b/hotspot/src/cpu/aarch64/vm/c2_globals_aarch64.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2014, Red Hat Inc. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -43,7 +43,6 @@ define_pd_global(bool, UseOnStackReplacement, true); define_pd_global(bool, ProfileInterpreter, true); define_pd_global(bool, TieredCompilation, trueInTiered); define_pd_global(intx, CompileThreshold, 10000); -define_pd_global(intx, BackEdgeThreshold, 100000); define_pd_global(intx, OnStackReplacePercentage, 140); define_pd_global(intx, ConditionalMoveLimit, 3); diff --git a/hotspot/src/cpu/aarch64/vm/globalDefinitions_aarch64.hpp b/hotspot/src/cpu/aarch64/vm/globalDefinitions_aarch64.hpp index 0d78e2da1fe..ad6b12de22d 100644 --- a/hotspot/src/cpu/aarch64/vm/globalDefinitions_aarch64.hpp +++ b/hotspot/src/cpu/aarch64/vm/globalDefinitions_aarch64.hpp @@ -34,10 +34,6 @@ const bool CCallingConventionRequiresIntsAsLongs = false; #define SUPPORTS_NATIVE_CX8 -// The maximum B/BL offset range on AArch64 is 128MB. -#undef CODE_CACHE_DEFAULT_LIMIT -#define CODE_CACHE_DEFAULT_LIMIT (128*M) - // According to the ARMv8 ARM, "Concurrent modification and execution // of instructions can lead to the resulting instruction performing // any behavior that can be achieved by executing any sequence of diff --git a/hotspot/src/cpu/aarch64/vm/jniFastGetField_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/jniFastGetField_aarch64.cpp index b2f21031f18..a09c5230dc4 100644 --- a/hotspot/src/cpu/aarch64/vm/jniFastGetField_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/jniFastGetField_aarch64.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2014, Red Hat Inc. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -82,6 +82,11 @@ address JNI_FastGetField::generate_fast_get_int_field0(BasicType type) { __ eor(robj, robj, rcounter); // obj, since // robj ^ rcounter ^ rcounter == robj // robj is address dependent on rcounter. + + // If mask changes we need to ensure that the inverse is still encodable as an immediate + STATIC_ASSERT(JNIHandles::weak_tag_mask == 1); + __ andr(robj, robj, ~JNIHandles::weak_tag_mask); + __ ldr(robj, Address(robj, 0)); // *obj __ lsr(roffset, c_rarg2, 2); // offset diff --git a/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.cpp index 1c955d5afe3..303c2f5eb8e 100644 --- a/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.cpp @@ -698,6 +698,7 @@ void MacroAssembler::call_VM_helper(Register oop_result, address entry_point, in // trampolines won't be emitted. address MacroAssembler::trampoline_call(Address entry, CodeBuffer *cbuf) { + assert(JavaThread::current()->is_Compiler_thread(), "just checking"); assert(entry.rspec().type() == relocInfo::runtime_call_type || entry.rspec().type() == relocInfo::opt_virtual_call_type || entry.rspec().type() == relocInfo::static_call_type @@ -4944,34 +4945,67 @@ void MacroAssembler::arrays_equals(Register a1, Register a2, } -// base: Address of a buffer to be zeroed, 8 bytes aligned. -// cnt: Count in HeapWords. -// is_large: True when 'cnt' is known to be >= BlockZeroingLowLimit. -void MacroAssembler::zero_words(Register base, Register cnt) +// The size of the blocks erased by the zero_blocks stub. We must +// handle anything smaller than this ourselves in zero_words(). +const int MacroAssembler::zero_words_block_size = 8; + +// zero_words() is used by C2 ClearArray patterns. It is as small as +// possible, handling small word counts locally and delegating +// anything larger to the zero_blocks stub. It is expanded many times +// in compiled code, so it is important to keep it short. + +// ptr: Address of a buffer to be zeroed. +// cnt: Count in HeapWords. +// +// ptr, cnt, rscratch1, and rscratch2 are clobbered. +void MacroAssembler::zero_words(Register ptr, Register cnt) { - if (UseBlockZeroing) { - block_zero(base, cnt); - } else { - fill_words(base, cnt, zr); + assert(is_power_of_2(zero_words_block_size), "adjust this"); + assert(ptr == r10 && cnt == r11, "mismatch in register usage"); + + BLOCK_COMMENT("zero_words {"); + cmp(cnt, zero_words_block_size); + Label around, done, done16; + br(LO, around); + { + RuntimeAddress zero_blocks = RuntimeAddress(StubRoutines::aarch64::zero_blocks()); + assert(zero_blocks.target() != NULL, "zero_blocks stub has not been generated"); + if (StubRoutines::aarch64::complete()) { + trampoline_call(zero_blocks); + } else { + bl(zero_blocks); + } } + bind(around); + for (int i = zero_words_block_size >> 1; i > 1; i >>= 1) { + Label l; + tbz(cnt, exact_log2(i), l); + for (int j = 0; j < i; j += 2) { + stp(zr, zr, post(ptr, 16)); + } + bind(l); + } + { + Label l; + tbz(cnt, 0, l); + str(zr, Address(ptr)); + bind(l); + } + BLOCK_COMMENT("} zero_words"); } -// r10 = base: Address of a buffer to be zeroed, 8 bytes aligned. +// base: Address of a buffer to be zeroed, 8 bytes aligned. // cnt: Immediate count in HeapWords. -// r11 = tmp: For use as cnt if we need to call out -#define ShortArraySize (18 * BytesPerLong) +#define SmallArraySize (18 * BytesPerLong) void MacroAssembler::zero_words(Register base, u_int64_t cnt) { - Register tmp = r11; + BLOCK_COMMENT("zero_words {"); int i = cnt & 1; // store any odd word to start if (i) str(zr, Address(base)); - if (cnt <= ShortArraySize / BytesPerLong) { + if (cnt <= SmallArraySize / BytesPerLong) { for (; i < (int)cnt; i += 2) stp(zr, zr, Address(base, i * wordSize)); - } else if (UseBlockZeroing && cnt >= (u_int64_t)(BlockZeroingLowLimit >> LogBytesPerWord)) { - mov(tmp, cnt); - block_zero(base, tmp, true); } else { const int unroll = 4; // Number of stp(zr, zr) instructions we'll unroll int remainder = cnt % (2 * unroll); @@ -4992,6 +5026,51 @@ void MacroAssembler::zero_words(Register base, u_int64_t cnt) stp(zr, zr, Address(pre(loop_base, 2 * unroll * wordSize))); cbnz(cnt_reg, loop); } + BLOCK_COMMENT("} zero_words"); +} + +// Zero blocks of memory by using DC ZVA. +// +// Aligns the base address first sufficently for DC ZVA, then uses +// DC ZVA repeatedly for every full block. cnt is the size to be +// zeroed in HeapWords. Returns the count of words left to be zeroed +// in cnt. +// +// NOTE: This is intended to be used in the zero_blocks() stub. If +// you want to use it elsewhere, note that cnt must be >= 2*zva_length. +void MacroAssembler::zero_dcache_blocks(Register base, Register cnt) { + Register tmp = rscratch1; + Register tmp2 = rscratch2; + int zva_length = VM_Version::zva_length(); + Label initial_table_end, loop_zva; + Label fini; + + // Base must be 16 byte aligned. If not just return and let caller handle it + tst(base, 0x0f); + br(Assembler::NE, fini); + // Align base with ZVA length. + neg(tmp, base); + andr(tmp, tmp, zva_length - 1); + + // tmp: the number of bytes to be filled to align the base with ZVA length. + add(base, base, tmp); + sub(cnt, cnt, tmp, Assembler::ASR, 3); + adr(tmp2, initial_table_end); + sub(tmp2, tmp2, tmp, Assembler::LSR, 2); + br(tmp2); + + for (int i = -zva_length + 16; i < 0; i += 16) + stp(zr, zr, Address(base, i)); + bind(initial_table_end); + + sub(cnt, cnt, zva_length >> 3); + bind(loop_zva); + dc(Assembler::ZVA, base); + subs(cnt, cnt, zva_length >> 3); + add(base, base, zva_length); + br(Assembler::GE, loop_zva); + add(cnt, cnt, zva_length >> 3); // count not zeroed by DC ZVA + bind(fini); } // base: Address of a buffer to be filled, 8 bytes aligned. @@ -5052,69 +5131,6 @@ void MacroAssembler::fill_words(Register base, Register cnt, Register value) bind(fini); } -// Use DC ZVA to do fast zeroing. -// base: Address of a buffer to be zeroed, 8 bytes aligned. -// cnt: Count in HeapWords. -// is_large: True when 'cnt' is known to be >= BlockZeroingLowLimit. -void MacroAssembler::block_zero(Register base, Register cnt, bool is_large) -{ - Label small; - Label store_pair, loop_store_pair, done; - Label base_aligned; - - assert_different_registers(base, cnt, rscratch1); - guarantee(base == r10 && cnt == r11, "fix register usage"); - - Register tmp = rscratch1; - Register tmp2 = rscratch2; - int zva_length = VM_Version::zva_length(); - - // Ensure ZVA length can be divided by 16. This is required by - // the subsequent operations. - assert (zva_length % 16 == 0, "Unexpected ZVA Length"); - - if (!is_large) cbz(cnt, done); - tbz(base, 3, base_aligned); - str(zr, Address(post(base, 8))); - sub(cnt, cnt, 1); - bind(base_aligned); - - // Ensure count >= zva_length * 2 so that it still deserves a zva after - // alignment. - if (!is_large || !(BlockZeroingLowLimit >= zva_length * 2)) { - int low_limit = MAX2(zva_length * 2, (int)BlockZeroingLowLimit); - subs(tmp, cnt, low_limit >> 3); - br(Assembler::LT, small); - } - - far_call(StubRoutines::aarch64::get_zero_longs()); - - bind(small); - - const int unroll = 8; // Number of stp instructions we'll unroll - Label small_loop, small_table_end; - - andr(tmp, cnt, (unroll-1) * 2); - sub(cnt, cnt, tmp); - add(base, base, tmp, Assembler::LSL, 3); - adr(tmp2, small_table_end); - sub(tmp2, tmp2, tmp, Assembler::LSL, 1); - br(tmp2); - - bind(small_loop); - add(base, base, unroll * 16); - for (int i = -unroll; i < 0; i++) - stp(zr, zr, Address(base, i * 16)); - bind(small_table_end); - subs(cnt, cnt, unroll * 2); - br(Assembler::GE, small_loop); - - tbz(cnt, 0, done); - str(zr, Address(post(base, 8))); - - bind(done); -} - // Intrinsic for sun/nio/cs/ISO_8859_1$Encoder.implEncodeISOArray and // java/lang/StringUTF16.compress. void MacroAssembler::encode_iso_array(Register src, Register dst, diff --git a/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.hpp b/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.hpp index 2f17699a262..59171e5dd19 100644 --- a/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.hpp +++ b/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.hpp @@ -1213,8 +1213,10 @@ public: void fill_words(Register base, Register cnt, Register value); void zero_words(Register base, u_int64_t cnt); - void zero_words(Register base, Register cnt); - void block_zero(Register base, Register cnt, bool is_large = false); + void zero_words(Register ptr, Register cnt); + void zero_dcache_blocks(Register base, Register cnt); + + static const int zero_words_block_size; void byte_array_inflate(Register src, Register dst, Register len, FloatRegister vtmp1, FloatRegister vtmp2, diff --git a/hotspot/src/cpu/aarch64/vm/sharedRuntime_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/sharedRuntime_aarch64.cpp index 01e0eeb1fc1..a286102e7b1 100644 --- a/hotspot/src/cpu/aarch64/vm/sharedRuntime_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/sharedRuntime_aarch64.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2014, 2015, Red Hat Inc. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -2052,13 +2052,31 @@ nmethod* SharedRuntime::generate_native_wrapper(MacroAssembler* masm, __ reset_last_Java_frame(false); - // Unpack oop result + // Unbox oop result, e.g. JNIHandles::resolve result. if (ret_type == T_OBJECT || ret_type == T_ARRAY) { - Label L; - __ cbz(r0, L); - __ ldr(r0, Address(r0, 0)); - __ bind(L); - __ verify_oop(r0); + Label done, not_weak; + __ cbz(r0, done); // Use NULL as-is. + STATIC_ASSERT(JNIHandles::weak_tag_mask == 1u); + __ tbz(r0, 0, not_weak); // Test for jweak tag. + // Resolve jweak. + __ ldr(r0, Address(r0, -JNIHandles::weak_tag_value)); + __ verify_oop(r0); +#if INCLUDE_ALL_GCS + if (UseG1GC) { + __ g1_write_barrier_pre(noreg /* obj */, + r0 /* pre_val */, + rthread /* thread */, + rscratch1 /* tmp */, + true /* tosca_live */, + true /* expand_call */); + } +#endif // INCLUDE_ALL_GCS + __ b(done); + __ bind(not_weak); + // Resolve (untagged) jobject. + __ ldr(r0, Address(r0, 0)); + __ verify_oop(r0); + __ bind(done); } if (CheckJNICalls) { diff --git a/hotspot/src/cpu/aarch64/vm/stubGenerator_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/stubGenerator_aarch64.cpp index 3143fe97d88..650c374371d 100644 --- a/hotspot/src/cpu/aarch64/vm/stubGenerator_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/stubGenerator_aarch64.cpp @@ -719,48 +719,74 @@ class StubGenerator: public StubCodeGenerator { } } - address generate_zero_longs(Register base, Register cnt) { - Register tmp = rscratch1; - Register tmp2 = rscratch2; - int zva_length = VM_Version::zva_length(); - Label initial_table_end, loop_zva; - Label fini; + // The inner part of zero_words(). This is the bulk operation, + // zeroing words in blocks, possibly using DC ZVA to do it. The + // caller is responsible for zeroing the last few words. + // + // Inputs: + // r10: the HeapWord-aligned base address of an array to zero. + // r11: the count in HeapWords, r11 > 0. + // + // Returns r10 and r11, adjusted for the caller to clear. + // r10: the base address of the tail of words left to clear. + // r11: the number of words in the tail. + // r11 < MacroAssembler::zero_words_block_size. + + address generate_zero_blocks() { + Label store_pair, loop_store_pair, done; + Label base_aligned; + + Register base = r10, cnt = r11; __ align(CodeEntryAlignment); - StubCodeMark mark(this, "StubRoutines", "zero_longs"); + StubCodeMark mark(this, "StubRoutines", "zero_blocks"); address start = __ pc(); - // Base must be 16 byte aligned. If not just return and let caller handle it - __ tst(base, 0x0f); - __ br(Assembler::NE, fini); - // Align base with ZVA length. - __ neg(tmp, base); - __ andr(tmp, tmp, zva_length - 1); + if (UseBlockZeroing) { + int zva_length = VM_Version::zva_length(); - // tmp: the number of bytes to be filled to align the base with ZVA length. - __ add(base, base, tmp); - __ sub(cnt, cnt, tmp, Assembler::ASR, 3); - __ adr(tmp2, initial_table_end); - __ sub(tmp2, tmp2, tmp, Assembler::LSR, 2); - __ br(tmp2); + // Ensure ZVA length can be divided by 16. This is required by + // the subsequent operations. + assert (zva_length % 16 == 0, "Unexpected ZVA Length"); - for (int i = -zva_length + 16; i < 0; i += 16) - __ stp(zr, zr, Address(base, i)); - __ bind(initial_table_end); + __ tbz(base, 3, base_aligned); + __ str(zr, Address(__ post(base, 8))); + __ sub(cnt, cnt, 1); + __ bind(base_aligned); + + // Ensure count >= zva_length * 2 so that it still deserves a zva after + // alignment. + Label small; + int low_limit = MAX2(zva_length * 2, (int)BlockZeroingLowLimit); + __ cmp(cnt, low_limit >> 3); + __ br(Assembler::LT, small); + __ zero_dcache_blocks(base, cnt); + __ bind(small); + } + + { + // Number of stp instructions we'll unroll + const int unroll = + MacroAssembler::zero_words_block_size / 2; + // Clear the remaining blocks. + Label loop; + __ subs(cnt, cnt, unroll * 2); + __ br(Assembler::LT, done); + __ bind(loop); + for (int i = 0; i < unroll; i++) + __ stp(zr, zr, __ post(base, 16)); + __ subs(cnt, cnt, unroll * 2); + __ br(Assembler::GE, loop); + __ bind(done); + __ add(cnt, cnt, unroll * 2); + } - __ sub(cnt, cnt, zva_length >> 3); - __ bind(loop_zva); - __ dc(Assembler::ZVA, base); - __ subs(cnt, cnt, zva_length >> 3); - __ add(base, base, zva_length); - __ br(Assembler::GE, loop_zva); - __ add(cnt, cnt, zva_length >> 3); // count not zeroed by DC ZVA - __ bind(fini); __ ret(lr); return start; } + typedef enum { copy_forwards = 1, copy_backwards = -1 @@ -2346,20 +2372,16 @@ class StubGenerator: public StubCodeGenerator { __ subw(count, count, cnt_words, Assembler::LSL, 3 - shift); if (UseBlockZeroing) { Label non_block_zeroing, rest; - Register tmp = rscratch1; - // count >= BlockZeroingLowLimit && value == 0 - __ subs(tmp, cnt_words, BlockZeroingLowLimit >> 3); - __ ccmp(value, 0 /* comparing value */, 0 /* NZCV */, Assembler::GE); - __ br(Assembler::NE, non_block_zeroing); + // If the fill value is zero we can use the fast zero_words(). + __ cbnz(value, non_block_zeroing); __ mov(bz_base, to); - __ block_zero(bz_base, cnt_words, true); - __ mov(to, bz_base); + __ add(to, to, cnt_words, Assembler::LSL, LogBytesPerWord); + __ zero_words(bz_base, cnt_words); __ b(rest); __ bind(non_block_zeroing); __ fill_words(to, cnt_words, value); __ bind(rest); - } - else { + } else { __ fill_words(to, cnt_words, value); } @@ -2420,7 +2442,7 @@ class StubGenerator: public StubCodeGenerator { generate_copy_longs(copy_f, r0, r1, rscratch2, copy_forwards); generate_copy_longs(copy_b, r0, r1, rscratch2, copy_backwards); - StubRoutines::aarch64::_zero_longs = generate_zero_longs(r10, r11); + StubRoutines::aarch64::_zero_blocks = generate_zero_blocks(); //*** jbyte // Always need aligned and unaligned versions @@ -4769,6 +4791,7 @@ class StubGenerator: public StubCodeGenerator { &StubRoutines::_safefetchN_fault_pc, &StubRoutines::_safefetchN_continuation_pc); #endif + StubRoutines::aarch64::set_completed(); } public: diff --git a/hotspot/src/cpu/aarch64/vm/stubRoutines_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/stubRoutines_aarch64.cpp index f5727ee03c6..9bcbe1e1e1d 100644 --- a/hotspot/src/cpu/aarch64/vm/stubRoutines_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/stubRoutines_aarch64.cpp @@ -43,7 +43,8 @@ address StubRoutines::aarch64::_float_sign_mask = NULL; address StubRoutines::aarch64::_float_sign_flip = NULL; address StubRoutines::aarch64::_double_sign_mask = NULL; address StubRoutines::aarch64::_double_sign_flip = NULL; -address StubRoutines::aarch64::_zero_longs = NULL; +address StubRoutines::aarch64::_zero_blocks = NULL; +bool StubRoutines::aarch64::_completed = false; /** * crc_table[] from jdk/src/share/native/java/util/zip/zlib-1.2.5/crc32.h diff --git a/hotspot/src/cpu/aarch64/vm/stubRoutines_aarch64.hpp b/hotspot/src/cpu/aarch64/vm/stubRoutines_aarch64.hpp index 1355a6836df..fc86d04a648 100644 --- a/hotspot/src/cpu/aarch64/vm/stubRoutines_aarch64.hpp +++ b/hotspot/src/cpu/aarch64/vm/stubRoutines_aarch64.hpp @@ -61,7 +61,8 @@ class aarch64 { static address _double_sign_mask; static address _double_sign_flip; - static address _zero_longs; + static address _zero_blocks; + static bool _completed; public: @@ -115,12 +116,19 @@ class aarch64 { return _double_sign_flip; } - static address get_zero_longs() - { - return _zero_longs; + static address zero_blocks() { + return _zero_blocks; } - private: + static bool complete() { + return _completed; + } + + static void set_completed() { + _completed = true; + } + +private: static juint _crc_table[]; }; diff --git a/hotspot/src/cpu/aarch64/vm/templateInterpreterGenerator_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/templateInterpreterGenerator_aarch64.cpp index 90dcd6c1a2c..6f44292c55a 100644 --- a/hotspot/src/cpu/aarch64/vm/templateInterpreterGenerator_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/templateInterpreterGenerator_aarch64.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2014, Red Hat Inc. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -1399,13 +1399,32 @@ address TemplateInterpreterGenerator::generate_native_entry(bool synchronized) { // and result handler will pick it up { - Label no_oop, store_result; + Label no_oop, not_weak, store_result; __ adr(t, ExternalAddress(AbstractInterpreter::result_handler(T_OBJECT))); __ cmp(t, result_handler); __ br(Assembler::NE, no_oop); - // retrieve result + // Unbox oop result, e.g. JNIHandles::resolve result. __ pop(ltos); - __ cbz(r0, store_result); + __ cbz(r0, store_result); // Use NULL as-is. + STATIC_ASSERT(JNIHandles::weak_tag_mask == 1u); + __ tbz(r0, 0, not_weak); // Test for jweak tag. + // Resolve jweak. + __ ldr(r0, Address(r0, -JNIHandles::weak_tag_value)); +#if INCLUDE_ALL_GCS + if (UseG1GC) { + __ enter(); // Barrier may call runtime. + __ g1_write_barrier_pre(noreg /* obj */, + r0 /* pre_val */, + rthread /* thread */, + t /* tmp */, + true /* tosca_live */, + true /* expand_call */); + __ leave(); + } +#endif // INCLUDE_ALL_GCS + __ b(store_result); + __ bind(not_weak); + // Resolve (untagged) jobject. __ ldr(r0, Address(r0, 0)); __ bind(store_result); __ str(r0, Address(rfp, frame::interpreter_frame_oop_temp_offset*wordSize)); diff --git a/hotspot/src/cpu/aarch64/vm/templateTable_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/templateTable_aarch64.cpp index 471a94511ad..f0f0f5a6ee5 100644 --- a/hotspot/src/cpu/aarch64/vm/templateTable_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/templateTable_aarch64.cpp @@ -2389,17 +2389,31 @@ void TemplateTable::getfield_or_static(int byte_no, bool is_static, RewriteContr const Register obj = r4; const Register off = r19; const Register flags = r0; + const Register raw_flags = r6; const Register bc = r4; // uses same reg as obj, so don't mix them resolve_cache_and_index(byte_no, cache, index, sizeof(u2)); jvmti_post_field_access(cache, index, is_static, false); - load_field_cp_cache_entry(obj, cache, index, off, flags, is_static); + load_field_cp_cache_entry(obj, cache, index, off, raw_flags, is_static); if (!is_static) { // obj is on the stack pop_and_check_object(obj); } + // 8179954: We need to make sure that the code generated for + // volatile accesses forms a sequentially-consistent set of + // operations when combined with STLR and LDAR. Without a leading + // membar it's possible for a simple Dekker test to fail if loads + // use LDR;DMB but stores use STLR. This can happen if C2 compiles + // the stores in one method and we interpret the loads in another. + if (! UseBarriersForVolatile) { + Label notVolatile; + __ tbz(raw_flags, ConstantPoolCacheEntry::is_volatile_shift, notVolatile); + __ membar(MacroAssembler::AnyAny); + __ bind(notVolatile); + } + const Address field(obj, off); Label Done, notByte, notBool, notInt, notShort, notChar, @@ -2407,7 +2421,8 @@ void TemplateTable::getfield_or_static(int byte_no, bool is_static, RewriteContr // x86 uses a shift and mask or wings it with a shift plus assert // the mask is not needed. aarch64 just uses bitfield extract - __ ubfxw(flags, flags, ConstantPoolCacheEntry::tos_state_shift, ConstantPoolCacheEntry::tos_state_bits); + __ ubfxw(flags, raw_flags, ConstantPoolCacheEntry::tos_state_shift, + ConstantPoolCacheEntry::tos_state_bits); assert(btos == 0, "change code, btos != 0"); __ cbnz(flags, notByte); @@ -2529,9 +2544,11 @@ void TemplateTable::getfield_or_static(int byte_no, bool is_static, RewriteContr #endif __ bind(Done); - // It's really not worth bothering to check whether this field - // really is volatile in the slow case. + + Label notVolatile; + __ tbz(raw_flags, ConstantPoolCacheEntry::is_volatile_shift, notVolatile); __ membar(MacroAssembler::LoadLoad | MacroAssembler::LoadStore); + __ bind(notVolatile); } @@ -2979,6 +2996,19 @@ void TemplateTable::fast_accessfield(TosState state) __ null_check(r0); const Address field(r0, r1); + // 8179954: We need to make sure that the code generated for + // volatile accesses forms a sequentially-consistent set of + // operations when combined with STLR and LDAR. Without a leading + // membar it's possible for a simple Dekker test to fail if loads + // use LDR;DMB but stores use STLR. This can happen if C2 compiles + // the stores in one method and we interpret the loads in another. + if (! UseBarriersForVolatile) { + Label notVolatile; + __ tbz(r3, ConstantPoolCacheEntry::is_volatile_shift, notVolatile); + __ membar(MacroAssembler::AnyAny); + __ bind(notVolatile); + } + // access field switch (bytecode()) { case Bytecodes::_fast_agetfield: @@ -3027,6 +3057,22 @@ void TemplateTable::fast_xaccess(TosState state) __ get_cache_and_index_at_bcp(r2, r3, 2); __ ldr(r1, Address(r2, in_bytes(ConstantPoolCache::base_offset() + ConstantPoolCacheEntry::f2_offset()))); + + // 8179954: We need to make sure that the code generated for + // volatile accesses forms a sequentially-consistent set of + // operations when combined with STLR and LDAR. Without a leading + // membar it's possible for a simple Dekker test to fail if loads + // use LDR;DMB but stores use STLR. This can happen if C2 compiles + // the stores in one method and we interpret the loads in another. + if (! UseBarriersForVolatile) { + Label notVolatile; + __ ldrw(r3, Address(r2, in_bytes(ConstantPoolCache::base_offset() + + ConstantPoolCacheEntry::flags_offset()))); + __ tbz(r3, ConstantPoolCacheEntry::is_volatile_shift, notVolatile); + __ membar(MacroAssembler::AnyAny); + __ bind(notVolatile); + } + // make sure exception is reported in correct bcp range (getfield is // next instruction) __ increment(rbcp); diff --git a/hotspot/src/cpu/arm/vm/c1_LIRAssembler_arm.cpp b/hotspot/src/cpu/arm/vm/c1_LIRAssembler_arm.cpp index 4d45cfb0481..caf00718656 100644 --- a/hotspot/src/cpu/arm/vm/c1_LIRAssembler_arm.cpp +++ b/hotspot/src/cpu/arm/vm/c1_LIRAssembler_arm.cpp @@ -1453,10 +1453,11 @@ void LIR_Assembler::emit_opTypeCheck(LIR_OpTypeCheck* op) { ciKlass* k = op->klass(); assert_different_registers(res, k_RInfo, klass_RInfo, Rtemp); + if (stub->is_simple_exception_stub()) { // TODO: ARM - Late binding is used to prevent confusion of register allocator assert(stub->is_exception_throw_stub(), "must be"); ((SimpleExceptionStub*)stub)->set_obj(op->result_opr()); - + } ciMethodData* md; ciProfileData* data; int mdo_offset_bias = 0; diff --git a/hotspot/src/cpu/arm/vm/c1_LIRGenerator_arm.cpp b/hotspot/src/cpu/arm/vm/c1_LIRGenerator_arm.cpp index 539a8faf880..c614e137091 100644 --- a/hotspot/src/cpu/arm/vm/c1_LIRGenerator_arm.cpp +++ b/hotspot/src/cpu/arm/vm/c1_LIRGenerator_arm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1412,12 +1412,20 @@ void LIRGenerator::do_CheckCast(CheckCast* x) { obj.load_item(); - CodeEmitInfo* info_for_exception = state_for(x); + CodeEmitInfo* info_for_exception = + (x->needs_exception_state() ? state_for(x) : + state_for(x, x->state_before(), true /*ignore_xhandler*/)); + CodeStub* stub; if (x->is_incompatible_class_change_check()) { assert(patching_info == NULL, "can't patch this"); stub = new SimpleExceptionStub(Runtime1::throw_incompatible_class_change_error_id, LIR_OprFact::illegalOpr, info_for_exception); + } else if (x->is_invokespecial_receiver_check()) { + assert(patching_info == NULL, "can't patch this"); + stub = new DeoptimizeStub(info_for_exception, + Deoptimization::Reason_class_check, + Deoptimization::Action_none); } else { stub = new SimpleExceptionStub(Runtime1::throw_class_cast_exception_id, LIR_OprFact::illegalOpr, info_for_exception); diff --git a/hotspot/src/cpu/arm/vm/c1_Runtime1_arm.cpp b/hotspot/src/cpu/arm/vm/c1_Runtime1_arm.cpp index 9f17c8fc810..5e793e16bd7 100644 --- a/hotspot/src/cpu/arm/vm/c1_Runtime1_arm.cpp +++ b/hotspot/src/cpu/arm/vm/c1_Runtime1_arm.cpp @@ -618,7 +618,7 @@ OopMapSet* Runtime1::generate_code_for(StubID id, StubAssembler* sasm) { Address buffer(Rthread, in_bytes(JavaThread::dirty_card_queue_offset() + DirtyCardQueue::byte_offset_of_buf())); - AddressLiteral cardtable((address)ct->byte_map_base); + AddressLiteral cardtable((address)ct->byte_map_base, relocInfo::none); assert(sizeof(*ct->byte_map_base) == sizeof(jbyte), "adjust this code"); // save at least the registers that need saving if the runtime is called @@ -645,7 +645,7 @@ OopMapSet* Runtime1::generate_code_for(StubID id, StubAssembler* sasm) { // Note: there is a comment in x86 code about not using // ExternalAddress / lea, due to relocation not working // properly for that address. Should be OK for arm, where we - // explicitly specify that 'cartable' has a relocInfo::none + // explicitly specify that 'cardtable' has a relocInfo::none // type. __ lea(r_card_base_1, cardtable); __ add(r_card_addr_0, r_card_base_1, AsmOperand(r_obj_0, lsr, CardTableModRefBS::card_shift)); diff --git a/hotspot/src/cpu/arm/vm/compiledIC_arm.cpp b/hotspot/src/cpu/arm/vm/compiledIC_arm.cpp index de7249f277a..abbd673b6ba 100644 --- a/hotspot/src/cpu/arm/vm/compiledIC_arm.cpp +++ b/hotspot/src/cpu/arm/vm/compiledIC_arm.cpp @@ -85,17 +85,17 @@ address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf, address mark) } #undef __ -// size of C2 call stub, compiled java to interpretor -int CompiledStaticCall::to_interp_stub_size() { - return 8 * NativeInstruction::instruction_size; -} - // Relocation entries for call stub, compiled java to interpreter. int CompiledStaticCall::reloc_to_interp_stub() { return 10; // 4 in emit_to_interp_stub + 1 in Java_Static_Call } #endif // COMPILER2 || JVMCI +// size of C2 call stub, compiled java to interpretor +int CompiledStaticCall::to_interp_stub_size() { + return 8 * NativeInstruction::instruction_size; +} + void CompiledDirectStaticCall::set_to_interpreted(const methodHandle& callee, address entry) { address stub = find_stub(/*is_aot*/ false); guarantee(stub != NULL, "stub not found"); @@ -125,6 +125,8 @@ void CompiledDirectStaticCall::set_to_interpreted(const methodHandle& callee, ad method_holder->set_data((intptr_t)callee()); jump->set_jump_destination(entry); + ICache::invalidate_range(stub, to_interp_stub_size()); + // Update jump to call. set_destination_mt_safe(stub); } diff --git a/hotspot/src/cpu/arm/vm/interp_masm_arm.cpp b/hotspot/src/cpu/arm/vm/interp_masm_arm.cpp index 2f41b102a85..96df37c275e 100644 --- a/hotspot/src/cpu/arm/vm/interp_masm_arm.cpp +++ b/hotspot/src/cpu/arm/vm/interp_masm_arm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -476,185 +476,6 @@ void InterpreterMacroAssembler::set_card(Register card_table_base, Address card_ } ////////////////////////////////////////////////////////////////////////////////// -#if INCLUDE_ALL_GCS - -// G1 pre-barrier. -// Blows all volatile registers (R0-R3 on 32-bit ARM, R0-R18 on AArch64, Rtemp, LR). -// If store_addr != noreg, then previous value is loaded from [store_addr]; -// in such case store_addr and new_val registers are preserved; -// otherwise pre_val register is preserved. -void InterpreterMacroAssembler::g1_write_barrier_pre(Register store_addr, - Register new_val, - Register pre_val, - Register tmp1, - Register tmp2) { - Label done; - Label runtime; - - if (store_addr != noreg) { - assert_different_registers(store_addr, new_val, pre_val, tmp1, tmp2, noreg); - } else { - assert (new_val == noreg, "should be"); - assert_different_registers(pre_val, tmp1, tmp2, noreg); - } - - Address in_progress(Rthread, in_bytes(JavaThread::satb_mark_queue_offset() + - SATBMarkQueue::byte_offset_of_active())); - Address index(Rthread, in_bytes(JavaThread::satb_mark_queue_offset() + - SATBMarkQueue::byte_offset_of_index())); - Address buffer(Rthread, in_bytes(JavaThread::satb_mark_queue_offset() + - SATBMarkQueue::byte_offset_of_buf())); - - // Is marking active? - assert(in_bytes(SATBMarkQueue::byte_width_of_active()) == 1, "adjust this code"); - ldrb(tmp1, in_progress); - cbz(tmp1, done); - - // Do we need to load the previous value? - if (store_addr != noreg) { - load_heap_oop(pre_val, Address(store_addr, 0)); - } - - // Is the previous value null? - cbz(pre_val, done); - - // Can we store original value in the thread's buffer? - // Is index == 0? - // (The index field is typed as size_t.) - - ldr(tmp1, index); // tmp1 := *index_adr - ldr(tmp2, buffer); - - subs(tmp1, tmp1, wordSize); // tmp1 := tmp1 - wordSize - b(runtime, lt); // If negative, goto runtime - - str(tmp1, index); // *index_adr := tmp1 - - // Record the previous value - str(pre_val, Address(tmp2, tmp1)); - b(done); - - bind(runtime); - - // save the live input values -#ifdef AARCH64 - if (store_addr != noreg) { - raw_push(store_addr, new_val); - } else { - raw_push(pre_val, ZR); - } -#else - if (store_addr != noreg) { - // avoid raw_push to support any ordering of store_addr and new_val - push(RegisterSet(store_addr) | RegisterSet(new_val)); - } else { - push(pre_val); - } -#endif // AARCH64 - - if (pre_val != R0) { - mov(R0, pre_val); - } - mov(R1, Rthread); - - call_VM_leaf(CAST_FROM_FN_PTR(address, SharedRuntime::g1_wb_pre), R0, R1); - -#ifdef AARCH64 - if (store_addr != noreg) { - raw_pop(store_addr, new_val); - } else { - raw_pop(pre_val, ZR); - } -#else - if (store_addr != noreg) { - pop(RegisterSet(store_addr) | RegisterSet(new_val)); - } else { - pop(pre_val); - } -#endif // AARCH64 - - bind(done); -} - -// G1 post-barrier. -// Blows all volatile registers (R0-R3 on 32-bit ARM, R0-R18 on AArch64, Rtemp, LR). -void InterpreterMacroAssembler::g1_write_barrier_post(Register store_addr, - Register new_val, - Register tmp1, - Register tmp2, - Register tmp3) { - - Address queue_index(Rthread, in_bytes(JavaThread::dirty_card_queue_offset() + - DirtyCardQueue::byte_offset_of_index())); - Address buffer(Rthread, in_bytes(JavaThread::dirty_card_queue_offset() + - DirtyCardQueue::byte_offset_of_buf())); - - BarrierSet* bs = Universe::heap()->barrier_set(); - CardTableModRefBS* ct = (CardTableModRefBS*)bs; - Label done; - Label runtime; - - // Does store cross heap regions? - - eor(tmp1, store_addr, new_val); -#ifdef AARCH64 - logical_shift_right(tmp1, tmp1, HeapRegion::LogOfHRGrainBytes); - cbz(tmp1, done); -#else - movs(tmp1, AsmOperand(tmp1, lsr, HeapRegion::LogOfHRGrainBytes)); - b(done, eq); -#endif - - // crosses regions, storing NULL? - - cbz(new_val, done); - - // storing region crossing non-NULL, is card already dirty? - const Register card_addr = tmp1; - assert(sizeof(*ct->byte_map_base) == sizeof(jbyte), "adjust this code"); - - mov_address(tmp2, (address)ct->byte_map_base, symbolic_Relocation::card_table_reference); - add(card_addr, tmp2, AsmOperand(store_addr, lsr, CardTableModRefBS::card_shift)); - - ldrb(tmp2, Address(card_addr)); - cmp(tmp2, (int)G1SATBCardTableModRefBS::g1_young_card_val()); - b(done, eq); - - membar(MacroAssembler::Membar_mask_bits(MacroAssembler::StoreLoad), tmp2); - - assert(CardTableModRefBS::dirty_card_val() == 0, "adjust this code"); - ldrb(tmp2, Address(card_addr)); - cbz(tmp2, done); - - // storing a region crossing, non-NULL oop, card is clean. - // dirty card and log. - - strb(zero_register(tmp2), Address(card_addr)); - - ldr(tmp2, queue_index); - ldr(tmp3, buffer); - - subs(tmp2, tmp2, wordSize); - b(runtime, lt); // go to runtime if now negative - - str(tmp2, queue_index); - - str(card_addr, Address(tmp3, tmp2)); - b(done); - - bind(runtime); - - if (card_addr != R0) { - mov(R0, card_addr); - } - mov(R1, Rthread); - call_VM_leaf(CAST_FROM_FN_PTR(address, SharedRuntime::g1_wb_post), R0, R1); - - bind(done); -} - -#endif // INCLUDE_ALL_GCS -////////////////////////////////////////////////////////////////////////////////// // Java Expression Stack diff --git a/hotspot/src/cpu/arm/vm/interp_masm_arm.hpp b/hotspot/src/cpu/arm/vm/interp_masm_arm.hpp index 5c753753f95..39e60226bf6 100644 --- a/hotspot/src/cpu/arm/vm/interp_masm_arm.hpp +++ b/hotspot/src/cpu/arm/vm/interp_masm_arm.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -146,27 +146,6 @@ class InterpreterMacroAssembler: public MacroAssembler { void set_card(Register card_table_base, Address card_table_addr, Register tmp); -#if INCLUDE_ALL_GCS - // G1 pre-barrier. - // Blows all volatile registers (R0-R3 on 32-bit ARM, R0-R18 on AArch64, Rtemp, LR). - // If store_addr != noreg, then previous value is loaded from [store_addr]; - // in such case store_addr and new_val registers are preserved; - // otherwise pre_val register is preserved. - void g1_write_barrier_pre(Register store_addr, - Register new_val, - Register pre_val, - Register tmp1, - Register tmp2); - - // G1 post-barrier. - // Blows all volatile registers (R0-R3 on 32-bit ARM, R0-R18 on AArch64, Rtemp, LR). - void g1_write_barrier_post(Register store_addr, - Register new_val, - Register tmp1, - Register tmp2, - Register tmp3); -#endif // INCLUDE_ALL_GCS - void pop_ptr(Register r); void pop_i(Register r = R0_tos); #ifdef AARCH64 diff --git a/hotspot/src/cpu/arm/vm/jniFastGetField_arm.cpp b/hotspot/src/cpu/arm/vm/jniFastGetField_arm.cpp index f9bd9f37970..65f929b1025 100644 --- a/hotspot/src/cpu/arm/vm/jniFastGetField_arm.cpp +++ b/hotspot/src/cpu/arm/vm/jniFastGetField_arm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -119,6 +119,14 @@ address JNI_FastGetField::generate_fast_get_int_field0(BasicType type) { __ ldr_s32(Rsafept_cnt, Address(Rsafepoint_counter_addr)); __ tbnz(Rsafept_cnt, 0, slow_case); +#ifdef AARCH64 + // If mask changes we need to ensure that the inverse is still encodable as an immediate + STATIC_ASSERT(JNIHandles::weak_tag_mask == 1); + __ andr(R1, R1, ~JNIHandles::weak_tag_mask); +#else + __ bic(R1, R1, JNIHandles::weak_tag_mask); +#endif + if (os::is_MP()) { // Address dependency restricts memory access ordering. It's cheaper than explicit LoadLoad barrier __ andr(Rtmp1, Rsafept_cnt, (unsigned)1); diff --git a/hotspot/src/cpu/arm/vm/macroAssembler_arm.cpp b/hotspot/src/cpu/arm/vm/macroAssembler_arm.cpp index ada7d3fc485..2eb2a551002 100644 --- a/hotspot/src/cpu/arm/vm/macroAssembler_arm.cpp +++ b/hotspot/src/cpu/arm/vm/macroAssembler_arm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2211,6 +2211,219 @@ void MacroAssembler::biased_locking_exit(Register obj_reg, Register tmp_reg, Lab b(done, eq); } + +void MacroAssembler::resolve_jobject(Register value, + Register tmp1, + Register tmp2) { + assert_different_registers(value, tmp1, tmp2); + Label done, not_weak; + cbz(value, done); // Use NULL as-is. + STATIC_ASSERT(JNIHandles::weak_tag_mask == 1u); + tbz(value, 0, not_weak); // Test for jweak tag. + // Resolve jweak. + ldr(value, Address(value, -JNIHandles::weak_tag_value)); + verify_oop(value); +#if INCLUDE_ALL_GCS + if (UseG1GC) { + g1_write_barrier_pre(noreg, // store_addr + noreg, // new_val + value, // pre_val + tmp1, // tmp1 + tmp2); // tmp2 + } +#endif // INCLUDE_ALL_GCS + b(done); + bind(not_weak); + // Resolve (untagged) jobject. + ldr(value, Address(value)); + verify_oop(value); + bind(done); +} + + +////////////////////////////////////////////////////////////////////////////////// + +#if INCLUDE_ALL_GCS + +// G1 pre-barrier. +// Blows all volatile registers (R0-R3 on 32-bit ARM, R0-R18 on AArch64, Rtemp, LR). +// If store_addr != noreg, then previous value is loaded from [store_addr]; +// in such case store_addr and new_val registers are preserved; +// otherwise pre_val register is preserved. +void MacroAssembler::g1_write_barrier_pre(Register store_addr, + Register new_val, + Register pre_val, + Register tmp1, + Register tmp2) { + Label done; + Label runtime; + + if (store_addr != noreg) { + assert_different_registers(store_addr, new_val, pre_val, tmp1, tmp2, noreg); + } else { + assert (new_val == noreg, "should be"); + assert_different_registers(pre_val, tmp1, tmp2, noreg); + } + + Address in_progress(Rthread, in_bytes(JavaThread::satb_mark_queue_offset() + + SATBMarkQueue::byte_offset_of_active())); + Address index(Rthread, in_bytes(JavaThread::satb_mark_queue_offset() + + SATBMarkQueue::byte_offset_of_index())); + Address buffer(Rthread, in_bytes(JavaThread::satb_mark_queue_offset() + + SATBMarkQueue::byte_offset_of_buf())); + + // Is marking active? + assert(in_bytes(SATBMarkQueue::byte_width_of_active()) == 1, "adjust this code"); + ldrb(tmp1, in_progress); + cbz(tmp1, done); + + // Do we need to load the previous value? + if (store_addr != noreg) { + load_heap_oop(pre_val, Address(store_addr, 0)); + } + + // Is the previous value null? + cbz(pre_val, done); + + // Can we store original value in the thread's buffer? + // Is index == 0? + // (The index field is typed as size_t.) + + ldr(tmp1, index); // tmp1 := *index_adr + ldr(tmp2, buffer); + + subs(tmp1, tmp1, wordSize); // tmp1 := tmp1 - wordSize + b(runtime, lt); // If negative, goto runtime + + str(tmp1, index); // *index_adr := tmp1 + + // Record the previous value + str(pre_val, Address(tmp2, tmp1)); + b(done); + + bind(runtime); + + // save the live input values +#ifdef AARCH64 + if (store_addr != noreg) { + raw_push(store_addr, new_val); + } else { + raw_push(pre_val, ZR); + } +#else + if (store_addr != noreg) { + // avoid raw_push to support any ordering of store_addr and new_val + push(RegisterSet(store_addr) | RegisterSet(new_val)); + } else { + push(pre_val); + } +#endif // AARCH64 + + if (pre_val != R0) { + mov(R0, pre_val); + } + mov(R1, Rthread); + + call_VM_leaf(CAST_FROM_FN_PTR(address, SharedRuntime::g1_wb_pre), R0, R1); + +#ifdef AARCH64 + if (store_addr != noreg) { + raw_pop(store_addr, new_val); + } else { + raw_pop(pre_val, ZR); + } +#else + if (store_addr != noreg) { + pop(RegisterSet(store_addr) | RegisterSet(new_val)); + } else { + pop(pre_val); + } +#endif // AARCH64 + + bind(done); +} + +// G1 post-barrier. +// Blows all volatile registers (R0-R3 on 32-bit ARM, R0-R18 on AArch64, Rtemp, LR). +void MacroAssembler::g1_write_barrier_post(Register store_addr, + Register new_val, + Register tmp1, + Register tmp2, + Register tmp3) { + + Address queue_index(Rthread, in_bytes(JavaThread::dirty_card_queue_offset() + + DirtyCardQueue::byte_offset_of_index())); + Address buffer(Rthread, in_bytes(JavaThread::dirty_card_queue_offset() + + DirtyCardQueue::byte_offset_of_buf())); + + BarrierSet* bs = Universe::heap()->barrier_set(); + CardTableModRefBS* ct = (CardTableModRefBS*)bs; + Label done; + Label runtime; + + // Does store cross heap regions? + + eor(tmp1, store_addr, new_val); +#ifdef AARCH64 + logical_shift_right(tmp1, tmp1, HeapRegion::LogOfHRGrainBytes); + cbz(tmp1, done); +#else + movs(tmp1, AsmOperand(tmp1, lsr, HeapRegion::LogOfHRGrainBytes)); + b(done, eq); +#endif + + // crosses regions, storing NULL? + + cbz(new_val, done); + + // storing region crossing non-NULL, is card already dirty? + const Register card_addr = tmp1; + assert(sizeof(*ct->byte_map_base) == sizeof(jbyte), "adjust this code"); + + mov_address(tmp2, (address)ct->byte_map_base, symbolic_Relocation::card_table_reference); + add(card_addr, tmp2, AsmOperand(store_addr, lsr, CardTableModRefBS::card_shift)); + + ldrb(tmp2, Address(card_addr)); + cmp(tmp2, (int)G1SATBCardTableModRefBS::g1_young_card_val()); + b(done, eq); + + membar(MacroAssembler::Membar_mask_bits(MacroAssembler::StoreLoad), tmp2); + + assert(CardTableModRefBS::dirty_card_val() == 0, "adjust this code"); + ldrb(tmp2, Address(card_addr)); + cbz(tmp2, done); + + // storing a region crossing, non-NULL oop, card is clean. + // dirty card and log. + + strb(zero_register(tmp2), Address(card_addr)); + + ldr(tmp2, queue_index); + ldr(tmp3, buffer); + + subs(tmp2, tmp2, wordSize); + b(runtime, lt); // go to runtime if now negative + + str(tmp2, queue_index); + + str(card_addr, Address(tmp3, tmp2)); + b(done); + + bind(runtime); + + if (card_addr != R0) { + mov(R0, card_addr); + } + mov(R1, Rthread); + call_VM_leaf(CAST_FROM_FN_PTR(address, SharedRuntime::g1_wb_post), R0, R1); + + bind(done); +} + +#endif // INCLUDE_ALL_GCS + +////////////////////////////////////////////////////////////////////////////////// + #ifdef AARCH64 void MacroAssembler::load_sized_value(Register dst, Address src, size_t size_in_bytes, bool is_signed) { diff --git a/hotspot/src/cpu/arm/vm/macroAssembler_arm.hpp b/hotspot/src/cpu/arm/vm/macroAssembler_arm.hpp index 770bba6c8a1..e6f73353cb9 100644 --- a/hotspot/src/cpu/arm/vm/macroAssembler_arm.hpp +++ b/hotspot/src/cpu/arm/vm/macroAssembler_arm.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -402,6 +402,29 @@ public: void biased_locking_enter_with_cas(Register obj_reg, Register old_mark_reg, Register new_mark_reg, Register tmp, Label& slow_case, int* counter_addr); + void resolve_jobject(Register value, Register tmp1, Register tmp2); + +#if INCLUDE_ALL_GCS + // G1 pre-barrier. + // Blows all volatile registers (R0-R3 on 32-bit ARM, R0-R18 on AArch64, Rtemp, LR). + // If store_addr != noreg, then previous value is loaded from [store_addr]; + // in such case store_addr and new_val registers are preserved; + // otherwise pre_val register is preserved. + void g1_write_barrier_pre(Register store_addr, + Register new_val, + Register pre_val, + Register tmp1, + Register tmp2); + + // G1 post-barrier. + // Blows all volatile registers (R0-R3 on 32-bit ARM, R0-R18 on AArch64, Rtemp, LR). + void g1_write_barrier_post(Register store_addr, + Register new_val, + Register tmp1, + Register tmp2, + Register tmp3); +#endif // INCLUDE_ALL_GCS + #ifndef AARCH64 void nop() { mov(R0, R0); diff --git a/hotspot/src/cpu/arm/vm/relocInfo_arm.cpp b/hotspot/src/cpu/arm/vm/relocInfo_arm.cpp index e17c5843cae..3eed9f846a2 100644 --- a/hotspot/src/cpu/arm/vm/relocInfo_arm.cpp +++ b/hotspot/src/cpu/arm/vm/relocInfo_arm.cpp @@ -139,7 +139,7 @@ void metadata_Relocation::pd_fix_value(address x) { #ifdef AARCH64 #ifdef COMPILER2 NativeMovConstReg* ni = nativeMovConstReg_at(addr()); - if (ni->is_movz()) { + if (ni->is_mov_slow()) { return; } #endif diff --git a/hotspot/src/cpu/arm/vm/sharedRuntime_arm.cpp b/hotspot/src/cpu/arm/vm/sharedRuntime_arm.cpp index 9b37b4fe6dc..48f096473c3 100644 --- a/hotspot/src/cpu/arm/vm/sharedRuntime_arm.cpp +++ b/hotspot/src/cpu/arm/vm/sharedRuntime_arm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1732,14 +1732,7 @@ nmethod* SharedRuntime::generate_native_wrapper(MacroAssembler* masm, case T_FLOAT : // fall through case T_DOUBLE : /* nothing to do */ break; case T_OBJECT : // fall through - case T_ARRAY : { - Label L; - __ cbz(R0, L); - __ ldr(R0, Address(R0)); - __ verify_oop(R0); - __ bind(L); - break; - } + case T_ARRAY : break; // See JNIHandles::resolve below default: ShouldNotReachHere(); } @@ -1748,14 +1741,15 @@ nmethod* SharedRuntime::generate_native_wrapper(MacroAssembler* masm, if (CheckJNICalls) { __ str(__ zero_register(Rtemp), Address(Rthread, JavaThread::pending_jni_exception_check_fn_offset())); } - - // Unhandle the result - if (ret_type == T_OBJECT || ret_type == T_ARRAY) { - __ cmp(R0, 0); - __ ldr(R0, Address(R0), ne); - } #endif // AARCH64 + // Unbox oop result, e.g. JNIHandles::resolve value in R0. + if (ret_type == T_OBJECT || ret_type == T_ARRAY) { + __ resolve_jobject(R0, // value + Rtemp, // tmp1 + R1_tmp); // tmp2 + } + // Any exception pending? __ ldr(Rtemp, Address(Rthread, Thread::pending_exception_offset())); __ mov(SP, FP); diff --git a/hotspot/src/cpu/arm/vm/templateInterpreterGenerator_arm.cpp b/hotspot/src/cpu/arm/vm/templateInterpreterGenerator_arm.cpp index 743510e09a7..7fda747ad48 100644 --- a/hotspot/src/cpu/arm/vm/templateInterpreterGenerator_arm.cpp +++ b/hotspot/src/cpu/arm/vm/templateInterpreterGenerator_arm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1240,28 +1240,25 @@ address TemplateInterpreterGenerator::generate_native_entry(bool synchronized) { __ str(__ zero_register(Rtemp), Address(Rthread, JavaThread::pending_jni_exception_check_fn_offset())); } - // Unbox if the result is non-zero object -#ifdef AARCH64 + // Unbox oop result, e.g. JNIHandles::resolve result if it's an oop. { - Label L, Lnull; + Label Lnot_oop; +#ifdef AARCH64 __ mov_slow(Rtemp, AbstractInterpreter::result_handler(T_OBJECT)); __ cmp(Rresult_handler, Rtemp); - __ b(L, ne); - __ cbz(Rsaved_result, Lnull); - __ ldr(Rsaved_result, Address(Rsaved_result)); - __ bind(Lnull); - // Store oop on the stack for GC - __ str(Rsaved_result, Address(FP, frame::interpreter_frame_oop_temp_offset * wordSize)); - __ bind(L); + __ b(Lnot_oop, ne); +#else // !AARCH64 + // For ARM32, Rresult_handler is -1 for oop result, 0 otherwise. + __ cbz(Rresult_handler, Lnot_oop); +#endif // !AARCH64 + Register value = AARCH64_ONLY(Rsaved_result) NOT_AARCH64(Rsaved_result_lo); + __ resolve_jobject(value, // value + Rtemp, // tmp1 + R1_tmp); // tmp2 + // Store resolved result in frame for GC visibility. + __ str(value, Address(FP, frame::interpreter_frame_oop_temp_offset * wordSize)); + __ bind(Lnot_oop); } -#else - __ tst(Rsaved_result_lo, Rresult_handler); - __ ldr(Rsaved_result_lo, Address(Rsaved_result_lo), ne); - - // Store oop on the stack for GC - __ cmp(Rresult_handler, 0); - __ str(Rsaved_result_lo, Address(FP, frame::interpreter_frame_oop_temp_offset * wordSize), ne); -#endif // AARCH64 #ifdef AARCH64 // Restore SP (drop native parameters area), to keep SP in sync with extended_sp in frame diff --git a/hotspot/src/cpu/ppc/vm/c1_LIRGenerator_ppc.cpp b/hotspot/src/cpu/ppc/vm/c1_LIRGenerator_ppc.cpp index 86eacda77f1..5bcd457e7e0 100644 --- a/hotspot/src/cpu/ppc/vm/c1_LIRGenerator_ppc.cpp +++ b/hotspot/src/cpu/ppc/vm/c1_LIRGenerator_ppc.cpp @@ -1131,12 +1131,19 @@ void LIRGenerator::do_CheckCast(CheckCast* x) { obj.load_item(); LIR_Opr out_reg = rlock_result(x); CodeStub* stub; - CodeEmitInfo* info_for_exception = state_for(x); + CodeEmitInfo* info_for_exception = + (x->needs_exception_state() ? state_for(x) : + state_for(x, x->state_before(), true /*ignore_xhandler*/)); if (x->is_incompatible_class_change_check()) { assert(patching_info == NULL, "can't patch this"); stub = new SimpleExceptionStub(Runtime1::throw_incompatible_class_change_error_id, LIR_OprFact::illegalOpr, info_for_exception); + } else if (x->is_invokespecial_receiver_check()) { + assert(patching_info == NULL, "can't patch this"); + stub = new DeoptimizeStub(info_for_exception, + Deoptimization::Reason_class_check, + Deoptimization::Action_none); } else { stub = new SimpleExceptionStub(Runtime1::throw_class_cast_exception_id, obj.result(), info_for_exception); } diff --git a/hotspot/src/cpu/ppc/vm/frame_ppc.cpp b/hotspot/src/cpu/ppc/vm/frame_ppc.cpp index 131a931c2c1..b6a538681f6 100644 --- a/hotspot/src/cpu/ppc/vm/frame_ppc.cpp +++ b/hotspot/src/cpu/ppc/vm/frame_ppc.cpp @@ -1,6 +1,6 @@ /* - * Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2015 SAP SE. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -171,10 +171,7 @@ BasicType frame::interpreter_frame_result(oop* oop_result, jvalue* value_result) switch (method->result_type()) { case T_OBJECT: case T_ARRAY: { - oop* obj_p = *(oop**)lresult; - oop obj = (obj_p == NULL) ? (oop)NULL : *obj_p; - assert(obj == NULL || Universe::heap()->is_in(obj), "sanity check"); - *oop_result = obj; + *oop_result = JNIHandles::resolve(*(jobject*)lresult); break; } // We use std/stfd to store the values. diff --git a/hotspot/src/cpu/ppc/vm/macroAssembler_ppc.cpp b/hotspot/src/cpu/ppc/vm/macroAssembler_ppc.cpp index a5d5613a414..6eb27c78f17 100644 --- a/hotspot/src/cpu/ppc/vm/macroAssembler_ppc.cpp +++ b/hotspot/src/cpu/ppc/vm/macroAssembler_ppc.cpp @@ -1,6 +1,6 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 SAP SE. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -3033,6 +3033,34 @@ void MacroAssembler::card_table_write(jbyte* byte_map_base, Register Rtmp, Regis stbx(R0, Rtmp, Robj); } +// Kills R31 if value is a volatile register. +void MacroAssembler::resolve_jobject(Register value, Register tmp1, Register tmp2, bool needs_frame) { + Label done; + cmpdi(CCR0, value, 0); + beq(CCR0, done); // Use NULL as-is. + + clrrdi(tmp1, value, JNIHandles::weak_tag_size); +#if INCLUDE_ALL_GCS + if (UseG1GC) { andi_(tmp2, value, JNIHandles::weak_tag_mask); } +#endif + ld(value, 0, tmp1); // Resolve (untagged) jobject. + +#if INCLUDE_ALL_GCS + if (UseG1GC) { + Label not_weak; + beq(CCR0, not_weak); // Test for jweak tag. + verify_oop(value); + g1_write_barrier_pre(noreg, // obj + noreg, // offset + value, // pre_val + tmp1, tmp2, needs_frame); + bind(not_weak); + } +#endif // INCLUDE_ALL_GCS + verify_oop(value); + bind(done); +} + #if INCLUDE_ALL_GCS // General G1 pre-barrier generator. // Goal: record the previous value if it is not null. @@ -3094,7 +3122,7 @@ void MacroAssembler::g1_write_barrier_pre(Register Robj, RegisterOrConstant offs bind(runtime); - // VM call need frame to access(write) O register. + // May need to preserve LR. Also needed if current frame is not compatible with C calling convention. if (needs_frame) { save_LR_CR(Rtmp1); push_frame_reg_args(0, Rtmp2); diff --git a/hotspot/src/cpu/ppc/vm/macroAssembler_ppc.hpp b/hotspot/src/cpu/ppc/vm/macroAssembler_ppc.hpp index 11b966a82c9..0b1b2a0befa 100644 --- a/hotspot/src/cpu/ppc/vm/macroAssembler_ppc.hpp +++ b/hotspot/src/cpu/ppc/vm/macroAssembler_ppc.hpp @@ -1,6 +1,6 @@ /* - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 SAP SE. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -649,6 +649,8 @@ class MacroAssembler: public Assembler { void card_write_barrier_post(Register Rstore_addr, Register Rnew_val, Register Rtmp); void card_table_write(jbyte* byte_map_base, Register Rtmp, Register Robj); + void resolve_jobject(Register value, Register tmp1, Register tmp2, bool needs_frame); + #if INCLUDE_ALL_GCS // General G1 pre-barrier generator. void g1_write_barrier_pre(Register Robj, RegisterOrConstant offset, Register Rpre_val, diff --git a/hotspot/src/cpu/ppc/vm/sharedRuntime_ppc.cpp b/hotspot/src/cpu/ppc/vm/sharedRuntime_ppc.cpp index 784595f11be..dc36aa77da2 100644 --- a/hotspot/src/cpu/ppc/vm/sharedRuntime_ppc.cpp +++ b/hotspot/src/cpu/ppc/vm/sharedRuntime_ppc.cpp @@ -1,6 +1,6 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 SAP SE. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2477,16 +2477,11 @@ nmethod *SharedRuntime::generate_native_wrapper(MacroAssembler *masm, __ reset_last_Java_frame(); - // Unpack oop result. + // Unbox oop result, e.g. JNIHandles::resolve value. // -------------------------------------------------------------------------- if (ret_type == T_OBJECT || ret_type == T_ARRAY) { - Label skip_unboxing; - __ cmpdi(CCR0, R3_RET, 0); - __ beq(CCR0, skip_unboxing); - __ ld(R3_RET, 0, R3_RET); - __ bind(skip_unboxing); - __ verify_oop(R3_RET); + __ resolve_jobject(R3_RET, r_temp_1, r_temp_2, /* needs_frame */ false); // kills R31 } if (CheckJNICalls) { diff --git a/hotspot/src/cpu/ppc/vm/templateInterpreterGenerator_ppc.cpp b/hotspot/src/cpu/ppc/vm/templateInterpreterGenerator_ppc.cpp index 56810938a53..ab87c204018 100644 --- a/hotspot/src/cpu/ppc/vm/templateInterpreterGenerator_ppc.cpp +++ b/hotspot/src/cpu/ppc/vm/templateInterpreterGenerator_ppc.cpp @@ -1,6 +1,6 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2015, 2016 SAP SE. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -401,11 +401,8 @@ address TemplateInterpreterGenerator::generate_result_handler_for(BasicType type case T_LONG: break; case T_OBJECT: - // unbox result if not null - __ cmpdi(CCR0, R3_RET, 0); - __ beq(CCR0, done); - __ ld(R3_RET, 0, R3_RET); - __ verify_oop(R3_RET); + // JNIHandles::resolve result. + __ resolve_jobject(R3_RET, R11_scratch1, R12_scratch2, /* needs_frame */ true); // kills R31 break; case T_FLOAT: break; diff --git a/hotspot/src/cpu/s390/vm/c1_LIRGenerator_s390.cpp b/hotspot/src/cpu/s390/vm/c1_LIRGenerator_s390.cpp index 98489aa7371..0ec97da6230 100644 --- a/hotspot/src/cpu/s390/vm/c1_LIRGenerator_s390.cpp +++ b/hotspot/src/cpu/s390/vm/c1_LIRGenerator_s390.cpp @@ -993,12 +993,19 @@ void LIRGenerator::do_CheckCast(CheckCast* x) { obj.load_item(); // info for exceptions - CodeEmitInfo* info_for_exception = state_for (x); + CodeEmitInfo* info_for_exception = + (x->needs_exception_state() ? state_for(x) : + state_for(x, x->state_before(), true /*ignore_xhandler*/)); CodeStub* stub; if (x->is_incompatible_class_change_check()) { assert(patching_info == NULL, "can't patch this"); stub = new SimpleExceptionStub(Runtime1::throw_incompatible_class_change_error_id, LIR_OprFact::illegalOpr, info_for_exception); + } else if (x->is_invokespecial_receiver_check()) { + assert(patching_info == NULL, "can't patch this"); + stub = new DeoptimizeStub(info_for_exception, + Deoptimization::Reason_class_check, + Deoptimization::Action_none); } else { stub = new SimpleExceptionStub(Runtime1::throw_class_cast_exception_id, obj.result(), info_for_exception); } diff --git a/hotspot/src/cpu/s390/vm/c1_Runtime1_s390.cpp b/hotspot/src/cpu/s390/vm/c1_Runtime1_s390.cpp index 7b65476212f..4f3c0950ad2 100644 --- a/hotspot/src/cpu/s390/vm/c1_Runtime1_s390.cpp +++ b/hotspot/src/cpu/s390/vm/c1_Runtime1_s390.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, 2017 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2016 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * diff --git a/hotspot/src/cpu/s390/vm/macroAssembler_s390.cpp b/hotspot/src/cpu/s390/vm/macroAssembler_s390.cpp index 0f78e5a6250..d5776117436 100644 --- a/hotspot/src/cpu/s390/vm/macroAssembler_s390.cpp +++ b/hotspot/src/cpu/s390/vm/macroAssembler_s390.cpp @@ -3439,6 +3439,34 @@ void MacroAssembler::card_write_barrier_post(Register store_addr, Register tmp) z_mvi(0, store_addr, 0); // Store byte 0. } +void MacroAssembler::resolve_jobject(Register value, Register tmp1, Register tmp2) { + NearLabel Ldone; + z_ltgr(tmp1, value); + z_bre(Ldone); // Use NULL result as-is. + + z_nill(value, ~JNIHandles::weak_tag_mask); + z_lg(value, 0, value); // Resolve (untagged) jobject. + +#if INCLUDE_ALL_GCS + if (UseG1GC) { + NearLabel Lnot_weak; + z_tmll(tmp1, JNIHandles::weak_tag_mask); // Test for jweak tag. + z_braz(Lnot_weak); + verify_oop(value); + g1_write_barrier_pre(noreg /* obj */, + noreg /* offset */, + value /* pre_val */, + noreg /* val */, + tmp1 /* tmp1 */, + tmp2 /* tmp2 */, + true /* pre_val_needed */); + bind(Lnot_weak); + } +#endif // INCLUDE_ALL_GCS + verify_oop(value); + bind(Ldone); +} + #if INCLUDE_ALL_GCS //------------------------------------------------------ diff --git a/hotspot/src/cpu/s390/vm/macroAssembler_s390.hpp b/hotspot/src/cpu/s390/vm/macroAssembler_s390.hpp index 588bde6207e..2b4002a3bf4 100644 --- a/hotspot/src/cpu/s390/vm/macroAssembler_s390.hpp +++ b/hotspot/src/cpu/s390/vm/macroAssembler_s390.hpp @@ -726,6 +726,8 @@ class MacroAssembler: public Assembler { // Write to card table for modification at store_addr - register is destroyed afterwards. void card_write_barrier_post(Register store_addr, Register tmp); + void resolve_jobject(Register value, Register tmp1, Register tmp2); + #if INCLUDE_ALL_GCS // General G1 pre-barrier generator. // Purpose: record the previous value if it is not null. diff --git a/hotspot/src/cpu/s390/vm/sharedRuntime_s390.cpp b/hotspot/src/cpu/s390/vm/sharedRuntime_s390.cpp index ea498e3399c..89c3ae4032a 100644 --- a/hotspot/src/cpu/s390/vm/sharedRuntime_s390.cpp +++ b/hotspot/src/cpu/s390/vm/sharedRuntime_s390.cpp @@ -1,6 +1,6 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2016 SAP SE. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2272,13 +2272,9 @@ nmethod *SharedRuntime::generate_native_wrapper(MacroAssembler *masm, __ reset_last_Java_frame(); - // Unpack oop result + // Unpack oop result, e.g. JNIHandles::resolve result. if (ret_type == T_OBJECT || ret_type == T_ARRAY) { - NearLabel L; - __ compare64_and_branch(Z_RET, (RegisterOrConstant)0L, Assembler::bcondEqual, L); - __ z_lg(Z_RET, 0, Z_RET); - __ bind(L); - __ verify_oop(Z_RET); + __ resolve_jobject(Z_RET, /* tmp1 */ Z_R13, /* tmp2 */ Z_R7); } if (CheckJNICalls) { diff --git a/hotspot/src/cpu/s390/vm/templateInterpreterGenerator_s390.cpp b/hotspot/src/cpu/s390/vm/templateInterpreterGenerator_s390.cpp index 2084f36006f..20a9a3e9571 100644 --- a/hotspot/src/cpu/s390/vm/templateInterpreterGenerator_s390.cpp +++ b/hotspot/src/cpu/s390/vm/templateInterpreterGenerator_s390.cpp @@ -1,6 +1,6 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2016 SAP SE. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1695,14 +1695,11 @@ address TemplateInterpreterGenerator::generate_native_entry(bool synchronized) { // from the jni handle to z_ijava_state.oop_temp. This is // necessary, because we reset the jni handle block below. // NOTE: frame::interpreter_frame_result() depends on this, too. - { NearLabel no_oop_result, store_oop_result; + { NearLabel no_oop_result; __ load_absolute_address(Z_R1, AbstractInterpreter::result_handler(T_OBJECT)); __ compareU64_and_branch(Z_R1, Rresult_handler, Assembler::bcondNotEqual, no_oop_result); - __ compareU64_and_branch(Rlresult, (intptr_t)0L, Assembler::bcondEqual, store_oop_result); - __ z_lg(Rlresult, 0, Rlresult); // unbox - __ bind(store_oop_result); + __ resolve_jobject(Rlresult, /* tmp1 */ Rmethod, /* tmp2 */ Z_R1); __ z_stg(Rlresult, oop_tmp_offset, Z_fp); - __ verify_oop(Rlresult); __ bind(no_oop_result); } diff --git a/hotspot/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp b/hotspot/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp index 36d3059739c..069b9a2f46e 100644 --- a/hotspot/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp +++ b/hotspot/src/cpu/sparc/vm/c1_LIRGenerator_sparc.cpp @@ -1196,11 +1196,18 @@ void LIRGenerator::do_CheckCast(CheckCast* x) { obj.load_item(); LIR_Opr out_reg = rlock_result(x); CodeStub* stub; - CodeEmitInfo* info_for_exception = state_for(x); + CodeEmitInfo* info_for_exception = + (x->needs_exception_state() ? state_for(x) : + state_for(x, x->state_before(), true /*ignore_xhandler*/)); if (x->is_incompatible_class_change_check()) { assert(patching_info == NULL, "can't patch this"); stub = new SimpleExceptionStub(Runtime1::throw_incompatible_class_change_error_id, LIR_OprFact::illegalOpr, info_for_exception); + } else if (x->is_invokespecial_receiver_check()) { + assert(patching_info == NULL, "can't patch this"); + stub = new DeoptimizeStub(info_for_exception, + Deoptimization::Reason_class_check, + Deoptimization::Action_none); } else { stub = new SimpleExceptionStub(Runtime1::throw_class_cast_exception_id, obj.result(), info_for_exception); } diff --git a/hotspot/src/cpu/sparc/vm/jniFastGetField_sparc.cpp b/hotspot/src/cpu/sparc/vm/jniFastGetField_sparc.cpp index 6d3f05a2aab..ff9fcd69472 100644 --- a/hotspot/src/cpu/sparc/vm/jniFastGetField_sparc.cpp +++ b/hotspot/src/cpu/sparc/vm/jniFastGetField_sparc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -68,6 +68,7 @@ address JNI_FastGetField::generate_fast_get_int_field0(BasicType type) { __ andcc (G4, 1, G0); __ br (Assembler::notZero, false, Assembler::pn, label1); __ delayed()->srl (O2, 2, O4); + __ andn (O1, JNIHandles::weak_tag_mask, O1); __ ld_ptr (O1, 0, O5); assert(count < LIST_CAPACITY, "LIST_CAPACITY too small"); @@ -147,6 +148,7 @@ address JNI_FastGetField::generate_fast_get_long_field() { __ andcc (G4, 1, G0); __ br (Assembler::notZero, false, Assembler::pn, label1); __ delayed()->srl (O2, 2, O4); + __ andn (O1, JNIHandles::weak_tag_mask, O1); __ ld_ptr (O1, 0, O5); __ add (O5, O4, O5); @@ -219,6 +221,7 @@ address JNI_FastGetField::generate_fast_get_float_field0(BasicType type) { __ andcc (G4, 1, G0); __ br (Assembler::notZero, false, Assembler::pn, label1); __ delayed()->srl (O2, 2, O4); + __ andn (O1, JNIHandles::weak_tag_mask, O1); __ ld_ptr (O1, 0, O5); assert(count < LIST_CAPACITY, "LIST_CAPACITY too small"); diff --git a/hotspot/src/cpu/sparc/vm/sharedRuntime_sparc.cpp b/hotspot/src/cpu/sparc/vm/sharedRuntime_sparc.cpp index 7b4dcf193d3..613e662d65c 100644 --- a/hotspot/src/cpu/sparc/vm/sharedRuntime_sparc.cpp +++ b/hotspot/src/cpu/sparc/vm/sharedRuntime_sparc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2754,15 +2754,30 @@ nmethod* SharedRuntime::generate_native_wrapper(MacroAssembler* masm, __ verify_thread(); // G2_thread must be correct __ reset_last_Java_frame(); - // Unpack oop result + // Unbox oop result, e.g. JNIHandles::resolve value in I0. if (ret_type == T_OBJECT || ret_type == T_ARRAY) { - Label L; - __ addcc(G0, I0, G0); - __ brx(Assembler::notZero, true, Assembler::pt, L); - __ delayed()->ld_ptr(I0, 0, I0); - __ mov(G0, I0); - __ bind(L); - __ verify_oop(I0); + Label done, not_weak; + __ br_null(I0, false, Assembler::pn, done); // Use NULL as-is. + __ delayed()->andcc(I0, JNIHandles::weak_tag_mask, G0); // Test for jweak + __ brx(Assembler::zero, true, Assembler::pt, not_weak); + __ delayed()->ld_ptr(I0, 0, I0); // Maybe resolve (untagged) jobject. + // Resolve jweak. + __ ld_ptr(I0, -JNIHandles::weak_tag_value, I0); +#if INCLUDE_ALL_GCS + if (UseG1GC) { + // Copy to O0 because macro doesn't allow pre_val in input reg. + __ mov(I0, O0); + __ g1_write_barrier_pre(noreg /* obj */, + noreg /* index */, + 0 /* offset */, + O0 /* pre_val */, + G3_scratch /* tmp */, + true /* preserve_o_regs */); + } +#endif // INCLUDE_ALL_GCS + __ bind(not_weak); + __ verify_oop(I0); + __ bind(done); } if (CheckJNICalls) { diff --git a/hotspot/src/cpu/sparc/vm/templateInterpreterGenerator_sparc.cpp b/hotspot/src/cpu/sparc/vm/templateInterpreterGenerator_sparc.cpp index b677a1dd662..fd4e3ffd149 100644 --- a/hotspot/src/cpu/sparc/vm/templateInterpreterGenerator_sparc.cpp +++ b/hotspot/src/cpu/sparc/vm/templateInterpreterGenerator_sparc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1516,11 +1516,23 @@ address TemplateInterpreterGenerator::generate_native_entry(bool synchronized) { __ set((intptr_t)AbstractInterpreter::result_handler(T_OBJECT), G3_scratch); __ cmp_and_brx_short(G3_scratch, Lscratch, Assembler::notEqual, Assembler::pt, no_oop); - __ addcc(G0, O0, O0); - __ brx(Assembler::notZero, true, Assembler::pt, store_result); // if result is not NULL: - __ delayed()->ld_ptr(O0, 0, O0); // unbox it - __ mov(G0, O0); - + // Unbox oop result, e.g. JNIHandles::resolve value in O0. + __ br_null(O0, false, Assembler::pn, store_result); // Use NULL as-is. + __ delayed()->andcc(O0, JNIHandles::weak_tag_mask, G0); // Test for jweak + __ brx(Assembler::zero, true, Assembler::pt, store_result); + __ delayed()->ld_ptr(O0, 0, O0); // Maybe resolve (untagged) jobject. + // Resolve jweak. + __ ld_ptr(O0, -JNIHandles::weak_tag_value, O0); +#if INCLUDE_ALL_GCS + if (UseG1GC) { + __ g1_write_barrier_pre(noreg /* obj */, + noreg /* index */, + 0 /* offset */, + O0 /* pre_val */, + G3_scratch /* tmp */, + true /* preserve_o_regs */); + } +#endif // INCLUDE_ALL_GCS __ bind(store_result); // Store it where gc will look for it and result handler expects it. __ st_ptr(O0, FP, (frame::interpreter_frame_oop_temp_offset*wordSize) + STACK_BIAS); diff --git a/hotspot/src/cpu/x86/vm/assembler_x86.cpp b/hotspot/src/cpu/x86/vm/assembler_x86.cpp index c819ffe9462..3c6d7b5cdd6 100644 --- a/hotspot/src/cpu/x86/vm/assembler_x86.cpp +++ b/hotspot/src/cpu/x86/vm/assembler_x86.cpp @@ -917,7 +917,7 @@ address Assembler::locate_operand(address inst, WhichOperand which) { break; case 0x62: // EVEX_4bytes - assert((UseAVX > 0), "shouldn't have EVEX prefix"); + assert(VM_Version::supports_evex(), "shouldn't have EVEX prefix"); assert(ip == inst+1, "no prefixes allowed"); // no EVEX collisions, all instructions that have 0x62 opcodes // have EVEX versions and are subopcodes of 0x66 diff --git a/hotspot/src/cpu/x86/vm/c1_LIRGenerator_x86.cpp b/hotspot/src/cpu/x86/vm/c1_LIRGenerator_x86.cpp index c5bec4b7e0b..39718a34acf 100644 --- a/hotspot/src/cpu/x86/vm/c1_LIRGenerator_x86.cpp +++ b/hotspot/src/cpu/x86/vm/c1_LIRGenerator_x86.cpp @@ -1429,12 +1429,17 @@ void LIRGenerator::do_CheckCast(CheckCast* x) { obj.load_item(); // info for exceptions - CodeEmitInfo* info_for_exception = state_for(x); + CodeEmitInfo* info_for_exception = + (x->needs_exception_state() ? state_for(x) : + state_for(x, x->state_before(), true /*ignore_xhandler*/)); CodeStub* stub; if (x->is_incompatible_class_change_check()) { assert(patching_info == NULL, "can't patch this"); stub = new SimpleExceptionStub(Runtime1::throw_incompatible_class_change_error_id, LIR_OprFact::illegalOpr, info_for_exception); + } else if (x->is_invokespecial_receiver_check()) { + assert(patching_info == NULL, "can't patch this"); + stub = new DeoptimizeStub(info_for_exception, Deoptimization::Reason_class_check, Deoptimization::Action_none); } else { stub = new SimpleExceptionStub(Runtime1::throw_class_cast_exception_id, obj.result(), info_for_exception); } diff --git a/hotspot/src/cpu/x86/vm/jniFastGetField_x86_32.cpp b/hotspot/src/cpu/x86/vm/jniFastGetField_x86_32.cpp index a45e0eb9aa3..719bf8ce560 100644 --- a/hotspot/src/cpu/x86/vm/jniFastGetField_x86_32.cpp +++ b/hotspot/src/cpu/x86/vm/jniFastGetField_x86_32.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -85,6 +85,9 @@ address JNI_FastGetField::generate_fast_get_int_field0(BasicType type) { __ movptr (rdx, Address(rsp, 2*wordSize)); // obj } __ movptr(rax, Address(rsp, 3*wordSize)); // jfieldID + + __ clear_jweak_tag(rdx); + __ movptr(rdx, Address(rdx, 0)); // *obj __ shrptr (rax, 2); // offset @@ -202,6 +205,9 @@ address JNI_FastGetField::generate_fast_get_long_field() { __ movptr(rdx, Address(rsp, 3*wordSize)); // obj } __ movptr(rsi, Address(rsp, 4*wordSize)); // jfieldID + + __ clear_jweak_tag(rdx); + __ movptr(rdx, Address(rdx, 0)); // *obj __ shrptr(rsi, 2); // offset @@ -291,6 +297,9 @@ address JNI_FastGetField::generate_fast_get_float_field0(BasicType type) { __ movptr(rdx, Address(rsp, 2*wordSize)); // obj } __ movptr(rax, Address(rsp, 3*wordSize)); // jfieldID + + __ clear_jweak_tag(rdx); + __ movptr(rdx, Address(rdx, 0)); // *obj __ shrptr(rax, 2); // offset diff --git a/hotspot/src/cpu/x86/vm/jniFastGetField_x86_64.cpp b/hotspot/src/cpu/x86/vm/jniFastGetField_x86_64.cpp index 7286fd124b8..f18aa684266 100644 --- a/hotspot/src/cpu/x86/vm/jniFastGetField_x86_64.cpp +++ b/hotspot/src/cpu/x86/vm/jniFastGetField_x86_64.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -80,6 +80,9 @@ address JNI_FastGetField::generate_fast_get_int_field0(BasicType type) { // robj ^ rcounter ^ rcounter == robj // robj is data dependent on rcounter. } + + __ clear_jweak_tag(robj); + __ movptr(robj, Address(robj, 0)); // *obj __ mov (roffset, c_rarg2); __ shrptr(roffset, 2); // offset @@ -178,6 +181,9 @@ address JNI_FastGetField::generate_fast_get_float_field0(BasicType type) { // robj ^ rcounter ^ rcounter == robj // robj is data dependent on rcounter. } + + __ clear_jweak_tag(robj); + __ movptr(robj, Address(robj, 0)); // *obj __ mov (roffset, c_rarg2); __ shrptr(roffset, 2); // offset diff --git a/hotspot/src/cpu/x86/vm/macroAssembler_x86.cpp b/hotspot/src/cpu/x86/vm/macroAssembler_x86.cpp index b6d32631582..6b7f947de6b 100644 --- a/hotspot/src/cpu/x86/vm/macroAssembler_x86.cpp +++ b/hotspot/src/cpu/x86/vm/macroAssembler_x86.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -4134,28 +4134,33 @@ void MacroAssembler::vabsss(XMMRegister dst, XMMRegister nds, XMMRegister src, A if ((dst_enc < 16) && (nds_enc < 16)) { vandps(dst, nds, negate_field, vector_len); } else if ((src_enc < 16) && (dst_enc < 16)) { - movss(src, nds); + evmovdqul(src, nds, Assembler::AVX_512bit); vandps(dst, src, negate_field, vector_len); } else if (src_enc < 16) { - movss(src, nds); + evmovdqul(src, nds, Assembler::AVX_512bit); vandps(src, src, negate_field, vector_len); - movss(dst, src); + evmovdqul(dst, src, Assembler::AVX_512bit); } else if (dst_enc < 16) { - movdqu(src, xmm0); - movss(xmm0, nds); + evmovdqul(src, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, nds, Assembler::AVX_512bit); vandps(dst, xmm0, negate_field, vector_len); - movdqu(xmm0, src); - } else if (nds_enc < 16) { - movdqu(src, xmm0); - vandps(xmm0, nds, negate_field, vector_len); - movss(dst, xmm0); - movdqu(xmm0, src); + evmovdqul(xmm0, src, Assembler::AVX_512bit); } else { - movdqu(src, xmm0); - movss(xmm0, nds); - vandps(xmm0, xmm0, negate_field, vector_len); - movss(dst, xmm0); - movdqu(xmm0, src); + if (src_enc != dst_enc) { + evmovdqul(src, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, nds, Assembler::AVX_512bit); + vandps(xmm0, xmm0, negate_field, vector_len); + evmovdqul(dst, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, src, Assembler::AVX_512bit); + } else { + subptr(rsp, 64); + evmovdqul(Address(rsp, 0), xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, nds, Assembler::AVX_512bit); + vandps(xmm0, xmm0, negate_field, vector_len); + evmovdqul(dst, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, Address(rsp, 0), Assembler::AVX_512bit); + addptr(rsp, 64); + } } } @@ -4166,28 +4171,33 @@ void MacroAssembler::vabssd(XMMRegister dst, XMMRegister nds, XMMRegister src, A if ((dst_enc < 16) && (nds_enc < 16)) { vandpd(dst, nds, negate_field, vector_len); } else if ((src_enc < 16) && (dst_enc < 16)) { - movsd(src, nds); + evmovdqul(src, nds, Assembler::AVX_512bit); vandpd(dst, src, negate_field, vector_len); } else if (src_enc < 16) { - movsd(src, nds); + evmovdqul(src, nds, Assembler::AVX_512bit); vandpd(src, src, negate_field, vector_len); - movsd(dst, src); + evmovdqul(dst, src, Assembler::AVX_512bit); } else if (dst_enc < 16) { - movdqu(src, xmm0); - movsd(xmm0, nds); + evmovdqul(src, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, nds, Assembler::AVX_512bit); vandpd(dst, xmm0, negate_field, vector_len); - movdqu(xmm0, src); - } else if (nds_enc < 16) { - movdqu(src, xmm0); - vandpd(xmm0, nds, negate_field, vector_len); - movsd(dst, xmm0); - movdqu(xmm0, src); + evmovdqul(xmm0, src, Assembler::AVX_512bit); } else { - movdqu(src, xmm0); - movsd(xmm0, nds); - vandpd(xmm0, xmm0, negate_field, vector_len); - movsd(dst, xmm0); - movdqu(xmm0, src); + if (src_enc != dst_enc) { + evmovdqul(src, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, nds, Assembler::AVX_512bit); + vandpd(xmm0, xmm0, negate_field, vector_len); + evmovdqul(dst, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, src, Assembler::AVX_512bit); + } else { + subptr(rsp, 64); + evmovdqul(Address(rsp, 0), xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, nds, Assembler::AVX_512bit); + vandpd(xmm0, xmm0, negate_field, vector_len); + evmovdqul(dst, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, Address(rsp, 0), Assembler::AVX_512bit); + addptr(rsp, 64); + } } } @@ -4934,6 +4944,24 @@ void MacroAssembler::punpcklbw(XMMRegister dst, XMMRegister src) { } } +void MacroAssembler::pshufd(XMMRegister dst, Address src, int mode) { + if (VM_Version::supports_avx512vl()) { + Assembler::pshufd(dst, src, mode); + } else { + int dst_enc = dst->encoding(); + if (dst_enc < 16) { + Assembler::pshufd(dst, src, mode); + } else { + subptr(rsp, 64); + evmovdqul(Address(rsp, 0), xmm0, Assembler::AVX_512bit); + Assembler::pshufd(xmm0, src, mode); + evmovdqul(dst, xmm0, Assembler::AVX_512bit); + evmovdqul(xmm0, Address(rsp, 0), Assembler::AVX_512bit); + addptr(rsp, 64); + } + } +} + // This instruction exists within macros, ergo we cannot control its input // when emitted through those patterns. void MacroAssembler::pshuflw(XMMRegister dst, XMMRegister src, int mode) { @@ -5129,6 +5157,43 @@ void MacroAssembler::vxorps(XMMRegister dst, XMMRegister nds, AddressLiteral src } +void MacroAssembler::resolve_jobject(Register value, + Register thread, + Register tmp) { + assert_different_registers(value, thread, tmp); + Label done, not_weak; + testptr(value, value); + jcc(Assembler::zero, done); // Use NULL as-is. + testptr(value, JNIHandles::weak_tag_mask); // Test for jweak tag. + jcc(Assembler::zero, not_weak); + // Resolve jweak. + movptr(value, Address(value, -JNIHandles::weak_tag_value)); + verify_oop(value); +#if INCLUDE_ALL_GCS + if (UseG1GC) { + g1_write_barrier_pre(noreg /* obj */, + value /* pre_val */, + thread /* thread */, + tmp /* tmp */, + true /* tosca_live */, + true /* expand_call */); + } +#endif // INCLUDE_ALL_GCS + jmp(done); + bind(not_weak); + // Resolve (untagged) jobject. + movptr(value, Address(value, 0)); + verify_oop(value); + bind(done); +} + +void MacroAssembler::clear_jweak_tag(Register possibly_jweak) { + const int32_t inverted_jweak_mask = ~static_cast(JNIHandles::weak_tag_mask); + STATIC_ASSERT(inverted_jweak_mask == -2); // otherwise check this code + // The inverted mask is sign-extended + andptr(possibly_jweak, inverted_jweak_mask); +} + ////////////////////////////////////////////////////////////////////////////////// #if INCLUDE_ALL_GCS diff --git a/hotspot/src/cpu/x86/vm/macroAssembler_x86.hpp b/hotspot/src/cpu/x86/vm/macroAssembler_x86.hpp index a3e81e58dc5..2c2b17c06ad 100644 --- a/hotspot/src/cpu/x86/vm/macroAssembler_x86.hpp +++ b/hotspot/src/cpu/x86/vm/macroAssembler_x86.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -297,6 +297,9 @@ class MacroAssembler: public Assembler { void store_check(Register obj); // store check for obj - register is destroyed afterwards void store_check(Register obj, Address dst); // same as above, dst is exact store location (reg. is destroyed) + void resolve_jobject(Register value, Register thread, Register tmp); + void clear_jweak_tag(Register possibly_jweak); + #if INCLUDE_ALL_GCS void g1_write_barrier_pre(Register obj, @@ -1229,6 +1232,9 @@ public: void punpcklbw(XMMRegister dst, XMMRegister src); void punpcklbw(XMMRegister dst, Address src) { Assembler::punpcklbw(dst, src); } + void pshufd(XMMRegister dst, Address src, int mode); + void pshufd(XMMRegister dst, XMMRegister src, int mode) { Assembler::pshufd(dst, src, mode); } + void pshuflw(XMMRegister dst, XMMRegister src, int mode); void pshuflw(XMMRegister dst, Address src, int mode) { Assembler::pshuflw(dst, src, mode); } diff --git a/hotspot/src/cpu/x86/vm/nativeInst_x86.cpp b/hotspot/src/cpu/x86/vm/nativeInst_x86.cpp index cb8c08f4652..fc7fcba2fc7 100644 --- a/hotspot/src/cpu/x86/vm/nativeInst_x86.cpp +++ b/hotspot/src/cpu/x86/vm/nativeInst_x86.cpp @@ -365,6 +365,10 @@ int NativeMovRegMem::instruction_start() const { NOT_LP64(assert((0xC0 & ubyte_at(1)) == 0xC0, "shouldn't have LDS and LES instructions")); return 3; } + if (instr_0 == instruction_EVEX_prefix_4bytes) { + assert(VM_Version::supports_evex(), "shouldn't have EVEX prefix"); + return 4; + } // First check to see if we have a (prefixed or not) xor if (instr_0 >= instruction_prefix_wide_lo && // 0x40 diff --git a/hotspot/src/cpu/x86/vm/nativeInst_x86.hpp b/hotspot/src/cpu/x86/vm/nativeInst_x86.hpp index 7db3ccb9d3c..ef87c17807c 100644 --- a/hotspot/src/cpu/x86/vm/nativeInst_x86.hpp +++ b/hotspot/src/cpu/x86/vm/nativeInst_x86.hpp @@ -356,6 +356,7 @@ class NativeMovRegMem: public NativeInstruction { instruction_VEX_prefix_2bytes = Assembler::VEX_2bytes, instruction_VEX_prefix_3bytes = Assembler::VEX_3bytes, + instruction_EVEX_prefix_4bytes = Assembler::EVEX_4bytes, instruction_size = 4, instruction_offset = 0, diff --git a/hotspot/src/cpu/x86/vm/sharedRuntime_x86_32.cpp b/hotspot/src/cpu/x86/vm/sharedRuntime_x86_32.cpp index ed317550e08..47b9fe5c627 100644 --- a/hotspot/src/cpu/x86/vm/sharedRuntime_x86_32.cpp +++ b/hotspot/src/cpu/x86/vm/sharedRuntime_x86_32.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2226,14 +2226,11 @@ nmethod* SharedRuntime::generate_native_wrapper(MacroAssembler* masm, __ reset_last_Java_frame(thread, false); - // Unpack oop result + // Unbox oop result, e.g. JNIHandles::resolve value. if (ret_type == T_OBJECT || ret_type == T_ARRAY) { - Label L; - __ cmpptr(rax, (int32_t)NULL_WORD); - __ jcc(Assembler::equal, L); - __ movptr(rax, Address(rax, 0)); - __ bind(L); - __ verify_oop(rax); + __ resolve_jobject(rax /* value */, + thread /* thread */, + rcx /* tmp */); } if (CheckJNICalls) { diff --git a/hotspot/src/cpu/x86/vm/sharedRuntime_x86_64.cpp b/hotspot/src/cpu/x86/vm/sharedRuntime_x86_64.cpp index 4587b8caba6..d81e965d05d 100644 --- a/hotspot/src/cpu/x86/vm/sharedRuntime_x86_64.cpp +++ b/hotspot/src/cpu/x86/vm/sharedRuntime_x86_64.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2579,14 +2579,11 @@ nmethod* SharedRuntime::generate_native_wrapper(MacroAssembler* masm, __ reset_last_Java_frame(false); - // Unpack oop result + // Unbox oop result, e.g. JNIHandles::resolve value. if (ret_type == T_OBJECT || ret_type == T_ARRAY) { - Label L; - __ testptr(rax, rax); - __ jcc(Assembler::zero, L); - __ movptr(rax, Address(rax, 0)); - __ bind(L); - __ verify_oop(rax); + __ resolve_jobject(rax /* value */, + r15_thread /* thread */, + rcx /* tmp */); } if (CheckJNICalls) { diff --git a/hotspot/src/cpu/x86/vm/templateInterpreterGenerator_x86.cpp b/hotspot/src/cpu/x86/vm/templateInterpreterGenerator_x86.cpp index eb5661bee00..9c02d44cdb8 100644 --- a/hotspot/src/cpu/x86/vm/templateInterpreterGenerator_x86.cpp +++ b/hotspot/src/cpu/x86/vm/templateInterpreterGenerator_x86.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1193,16 +1193,16 @@ address TemplateInterpreterGenerator::generate_native_entry(bool synchronized) { // and result handler will pick it up { - Label no_oop, store_result; + Label no_oop, not_weak, store_result; __ lea(t, ExternalAddress(AbstractInterpreter::result_handler(T_OBJECT))); __ cmpptr(t, Address(rbp, frame::interpreter_frame_result_handler_offset*wordSize)); __ jcc(Assembler::notEqual, no_oop); // retrieve result __ pop(ltos); - __ testptr(rax, rax); - __ jcc(Assembler::zero, store_result); - __ movptr(rax, Address(rax, 0)); - __ bind(store_result); + // Unbox oop result, e.g. JNIHandles::resolve value. + __ resolve_jobject(rax /* value */, + thread /* thread */, + t /* tmp */); __ movptr(Address(rbp, frame::interpreter_frame_oop_temp_offset*wordSize), rax); // keep stack depth as expected by pushing oop which will eventually be discarded __ push(ltos); diff --git a/hotspot/src/cpu/x86/vm/templateTable_x86.cpp b/hotspot/src/cpu/x86/vm/templateTable_x86.cpp index 5f1c935f944..3d2f57f37bc 100644 --- a/hotspot/src/cpu/x86/vm/templateTable_x86.cpp +++ b/hotspot/src/cpu/x86/vm/templateTable_x86.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2210,7 +2210,6 @@ void TemplateTable::branch(bool is_jsr, bool is_wide) { // Out-of-line code to allocate method data oop. __ bind(profile_method); __ call_VM(noreg, CAST_FROM_FN_PTR(address, InterpreterRuntime::profile_method)); - __ load_unsigned_byte(rbx, Address(rbcp, 0)); // restore target bytecode __ set_method_data_pointer_for_bcp(); __ jmp(dispatch); } @@ -2225,10 +2224,8 @@ void TemplateTable::branch(bool is_jsr, bool is_wide) { CAST_FROM_FN_PTR(address, InterpreterRuntime::frequency_counter_overflow), rdx); - __ load_unsigned_byte(rbx, Address(rbcp, 0)); // restore target bytecode // rax: osr nmethod (osr ok) or NULL (osr not possible) - // rbx: target bytecode // rdx: scratch // r14: locals pointer // r13: bcp @@ -2238,12 +2235,13 @@ void TemplateTable::branch(bool is_jsr, bool is_wide) { __ cmpb(Address(rax, nmethod::state_offset()), nmethod::in_use); __ jcc(Assembler::notEqual, dispatch); - // We have the address of an on stack replacement routine in rax - // We need to prepare to execute the OSR method. First we must - // migrate the locals and monitors off of the stack. + // We have the address of an on stack replacement routine in rax. + // In preparation of invoking it, first we must migrate the locals + // and monitors from off the interpreter frame on the stack. + // Ensure to save the osr nmethod over the migration call, + // it will be preserved in rbx. + __ mov(rbx, rax); - LP64_ONLY(__ mov(r13, rax)); // save the nmethod - NOT_LP64(__ mov(rbx, rax)); // save the nmethod NOT_LP64(__ get_thread(rcx)); call_VM(noreg, CAST_FROM_FN_PTR(address, SharedRuntime::OSR_migration_begin)); @@ -2258,7 +2256,6 @@ void TemplateTable::branch(bool is_jsr, bool is_wide) { const Register retaddr = LP64_ONLY(j_rarg2) NOT_LP64(rdi); const Register sender_sp = LP64_ONLY(j_rarg1) NOT_LP64(rdx); - // pop the interpreter frame __ movptr(sender_sp, Address(rbp, frame::interpreter_frame_sender_sp_offset * wordSize)); // get sender sp __ leave(); // remove frame anchor @@ -2274,8 +2271,7 @@ void TemplateTable::branch(bool is_jsr, bool is_wide) { __ push(retaddr); // and begin the OSR nmethod - LP64_ONLY(__ jmp(Address(r13, nmethod::osr_entry_point_offset()))); - NOT_LP64(__ jmp(Address(rbx, nmethod::osr_entry_point_offset()))); + __ jmp(Address(rbx, nmethod::osr_entry_point_offset())); } } } diff --git a/hotspot/src/cpu/x86/vm/vm_version_x86.cpp b/hotspot/src/cpu/x86/vm/vm_version_x86.cpp index 7bed10749f7..197079ba1c7 100644 --- a/hotspot/src/cpu/x86/vm/vm_version_x86.cpp +++ b/hotspot/src/cpu/x86/vm/vm_version_x86.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -763,12 +763,11 @@ void VM_Version::get_processor_features() { FLAG_SET_DEFAULT(UseCRC32Intrinsics, false); } - if (supports_sse4_2()) { + if (supports_sse4_2() && supports_clmul()) { if (FLAG_IS_DEFAULT(UseCRC32CIntrinsics)) { UseCRC32CIntrinsics = true; } - } - else if (UseCRC32CIntrinsics) { + } else if (UseCRC32CIntrinsics) { if (!FLAG_IS_DEFAULT(UseCRC32CIntrinsics)) { warning("CRC32C intrinsics are not available on this CPU"); } @@ -850,6 +849,12 @@ void VM_Version::get_processor_features() { #if INCLUDE_RTM_OPT if (UseRTMLocking) { + if (is_client_compilation_mode_vm()) { + // Only C2 does RTM locking optimization. + // Can't continue because UseRTMLocking affects UseBiasedLocking flag + // setting during arguments processing. See use_biased_locking(). + vm_exit_during_initialization("RTM locking optimization is not supported in emulated client VM"); + } if (is_intel_family_core()) { if ((_model == CPU_MODEL_HASWELL_E3) || (_model == CPU_MODEL_HASWELL_E7 && _stepping < 3) || diff --git a/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp b/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp index 1fcf7d9984b..f7c51092c82 100644 --- a/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp +++ b/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright 2007, 2008, 2009, 2010, 2011 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -406,10 +406,12 @@ int CppInterpreter::native_entry(Method* method, intptr_t UNUSED, TRAPS) { // oop_temp where the garbage collector can see it before // we release the handle it might be protected by. if (handler->result_type() == &ffi_type_pointer) { - if (result[0]) - istate->set_oop_temp(*(oop *) result[0]); - else + if (result[0] == 0) { istate->set_oop_temp(NULL); + } else { + jobject handle = reinterpret_cast(result[0]); + istate->set_oop_temp(JNIHandles::resolve(handle)); + } } // Reset handle block diff --git a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/AOTStub.java b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/AOTStub.java index b7ba5e87e72..1eabbdc3a78 100644 --- a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/AOTStub.java +++ b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/AOTStub.java @@ -25,6 +25,7 @@ package jdk.tools.jaotc; import org.graalvm.compiler.code.CompilationResult; import org.graalvm.compiler.core.target.Backend; +import org.graalvm.compiler.hotspot.HotSpotCompiledCodeBuilder; import org.graalvm.compiler.hotspot.stubs.Stub; import jdk.vm.ci.hotspot.HotSpotCompiledCode; @@ -48,7 +49,7 @@ public class AOTStub implements JavaMethodInfo { } public HotSpotCompiledCode compiledCode(CompilationResult result) { - return stub.getCompiledCode(backend); + return HotSpotCompiledCodeBuilder.createCompiledCode(null, null, result); } } diff --git a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/CallSiteRelocationSymbol.java b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/CallSiteRelocationSymbol.java index 68f86ef65e3..5fce078a470 100644 --- a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/CallSiteRelocationSymbol.java +++ b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/CallSiteRelocationSymbol.java @@ -59,12 +59,6 @@ abstract class CallSiteRelocationSymbol { addExternalPltToGotRelocation(binaryContainer, symbol, relocationOffset); } - protected static void addMetaspaceGotRelocation(BinaryContainer binaryContainer, String symbolName, int symbolOffset, int relocationOffset) { - ByteContainer container = binaryContainer.getMetaspaceGotContainer(); - Symbol symbol = container.createGotSymbol(symbolOffset, symbolName); - addExternalPltToGotRelocation(binaryContainer, symbol, relocationOffset); - } - /** * Add an {@link RelocType#EXTERNAL_GOT_TO_PLT} relocation to the * {@link BinaryContainer#getExtLinkageGOTContainer()}. diff --git a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/DataBuilder.java b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/DataBuilder.java index 350ee46921a..159955c6bda 100644 --- a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/DataBuilder.java +++ b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/DataBuilder.java @@ -70,8 +70,8 @@ class DataBuilder { */ private void fillVMAddresses(HotSpotVMConfigStore config) { for (VMField vmField : config.getFields().values()) { - if (vmField.value != null) { - final long address = vmField.value; + if (vmField.value != null && vmField.value instanceof Long) { + final long address = (Long) vmField.value; String value = vmField.name; /* * Some fields don't contain addresses but integer values. At least don't add zero diff --git a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/JavaCallSiteRelocationSymbol.java b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/JavaCallSiteRelocationSymbol.java index a14049dd87f..f589610ded8 100644 --- a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/JavaCallSiteRelocationSymbol.java +++ b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/JavaCallSiteRelocationSymbol.java @@ -37,6 +37,7 @@ import jdk.vm.ci.hotspot.HotSpotResolvedJavaMethod; final class JavaCallSiteRelocationSymbol extends CallSiteRelocationSymbol { private static final byte[] zeroSlot = new byte[8]; + // -1 represents Universe::non_oop_word() value private static final byte[] minusOneSlot = {-1, -1, -1, -1, -1, -1, -1, -1}; public JavaCallSiteRelocationSymbol(CompiledMethodInfo mi, Call call, CallSiteRelocationInfo callSiteRelocation, BinaryContainer binaryContainer) { @@ -79,30 +80,39 @@ final class JavaCallSiteRelocationSymbol extends CallSiteRelocationSymbol { } // Add relocation to GOT cell for call resolution jump. + // This GOT cell will be initialized during JVM startup with address + // of JVM runtime call resolution function. String gotSymbolName = "got." + getResolveSymbolName(binaryContainer, mi, call); Symbol gotSymbol = binaryContainer.getGotSymbol(gotSymbolName); addExternalPltToGotRelocation(binaryContainer, gotSymbol, stub.getResolveJumpOffset()); // Add relocation to resolve call jump instruction address for GOT cell. + // This GOT cell will be initialized with address of resolution jump instruction and + // will be updated with call destination address by JVM runtime call resolution code. String pltJmpSymbolName = relocationSymbolName("plt.jmp", mi, call, callSiteRelocation); addCodeContainerRelocation(binaryContainer, pltJmpSymbolName, stub.getResolveJumpStart(), gotStartOffset); // Add relocation to GOT cell for dispatch jump. + // The dispatch jump loads destination address from this GOT cell. String gotEntrySymbolName = relocationSymbolName("got.entry", mi, call, callSiteRelocation); addExtLinkageGotContainerRelocation(binaryContainer, gotEntrySymbolName, gotStartOffset, stub.getDispatchJumpOffset()); - // Virtual call needs initial -1 value. + // Virtual call needs initial -1 value for Klass pointer. + // Non virtual call needs initial 0 value for Method pointer to call c2i adapter. byte[] slot = isVirtualCall ? minusOneSlot : zeroSlot; - final int gotMetaOffset = binaryContainer.appendMetaspaceGotBytes(slot, 0, slot.length); + final int gotMetaOffset = binaryContainer.appendExtLinkageGotBytes(slot, 0, slot.length); // Add relocation to GOT cell for move instruction (Klass* for virtual, Method* otherwise). String gotMoveSymbolName = relocationSymbolName("got.move", mi, call, callSiteRelocation); - addMetaspaceGotRelocation(binaryContainer, gotMoveSymbolName, gotMetaOffset, stub.getMovOffset()); + addExtLinkageGotContainerRelocation(binaryContainer, gotMoveSymbolName, gotMetaOffset, stub.getMovOffset()); if (isVirtualCall) { // Nothing. } else { // Add relocation to GOT cell for c2i adapter jump. + // The c2i jump instruction loads destination address from this GOT cell. + // This GOT cell is initialized with -1 and will be updated + // by JVM runtime call resolution code. String gotC2ISymbolName = relocationSymbolName("got.c2i", mi, call, callSiteRelocation); addExtLinkageGotContainerRelocation(binaryContainer, gotC2ISymbolName, gotStartOffset + 8, stub.getC2IJumpOffset()); } diff --git a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/Main.java b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/Main.java index a98dc8d2d81..933e91acaf4 100644 --- a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/Main.java +++ b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/Main.java @@ -625,7 +625,9 @@ public class Main implements LogPrinter { private void reportError(Throwable e) { log.println("Error: " + e.getMessage()); - e.printStackTrace(log); + if (options.info) { + e.printStackTrace(log); + } log.flush(); } diff --git a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/ClassSearch.java b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/ClassSearch.java index 3fd63b2c0b8..603da038e80 100644 --- a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/ClassSearch.java +++ b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/ClassSearch.java @@ -77,7 +77,7 @@ public class ClassSearch { } if (found == null) { - throw new InternalError("Failed to find: " + searchFor.toString()); + throw new InternalError("Failed to find " + searchFor.getType() + " file: " + searchFor.getName()); } return found; } diff --git a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/SearchFor.java b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/SearchFor.java index 49e0cdd9945..cf6a583ae61 100644 --- a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/SearchFor.java +++ b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/SearchFor.java @@ -27,7 +27,7 @@ public class SearchFor { private final String type; public SearchFor(String name) { - this(name, "unknown"); + this(name, ""); } public SearchFor(String name, String type) { @@ -36,7 +36,7 @@ public class SearchFor { } public boolean isUnknown() { - return "unknown".equals(type); + return "".equals(type); } public String getType() { @@ -49,6 +49,6 @@ public class SearchFor { @Override public String toString() { - return type + ":" + name; + return type + ": " + name; } } diff --git a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/classname/ClassNameSourceProvider.java b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/classname/ClassNameSourceProvider.java index b5bc2804ed4..e46060848fa 100644 --- a/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/classname/ClassNameSourceProvider.java +++ b/hotspot/src/jdk.aot/share/classes/jdk.tools.jaotc/src/jdk/tools/jaotc/collect/classname/ClassNameSourceProvider.java @@ -31,7 +31,7 @@ import java.nio.file.Path; import java.nio.file.Paths; public class ClassNameSourceProvider implements SourceProvider { - public final static String TYPE = "classname"; + public final static String TYPE = "class"; private final ClassLoader classLoader; public ClassNameSourceProvider(FileSupport fileSupport) { @@ -47,6 +47,10 @@ public class ClassNameSourceProvider implements SourceProvider { @Override public ClassSource findSource(String name, SearchPath searchPath) { + Path path = Paths.get(name); + if (ClassSource.pathIsClassFile(path)) { + name = ClassSource.makeClassName(path); + } try { classLoader.loadClass(name); return new ClassNameSource(name, classLoader); diff --git a/hotspot/src/jdk.aot/share/classes/module-info.java b/hotspot/src/jdk.aot/share/classes/module-info.java index 3105d8b6bef..14d11197356 100644 --- a/hotspot/src/jdk.aot/share/classes/module-info.java +++ b/hotspot/src/jdk.aot/share/classes/module-info.java @@ -25,6 +25,6 @@ module jdk.aot { requires jdk.management; - requires jdk.vm.ci; - requires jdk.vm.compiler; + requires jdk.internal.vm.ci; + requires jdk.internal.vm.compiler; } diff --git a/hotspot/src/jdk.aot/unix/native/libjelfshim/jdk_tools_jaotc_jnilibelf_JNILibELFAPI.c b/hotspot/src/jdk.aot/unix/native/libjelfshim/jdk_tools_jaotc_jnilibelf_JNILibELFAPI.c index d6d69cb439a..b64bc2dfdbc 100644 --- a/hotspot/src/jdk.aot/unix/native/libjelfshim/jdk_tools_jaotc_jnilibelf_JNILibELFAPI.c +++ b/hotspot/src/jdk.aot/unix/native/libjelfshim/jdk_tools_jaotc_jnilibelf_JNILibELFAPI.c @@ -70,18 +70,17 @@ JNIEXPORT jint JNICALL Java_jdk_tools_jaotc_jnilibelf_JNILibELFAPI_elf_1version */ static jlong getNativeAddress(JNIEnv* env, jobject ptrObj) { - jclass ptrClass; - jfieldID fidNumber; jlong nativeAddress = -1; - assert (ptrObj != NULL); + assert (ptrObj != NULL); // Get a reference to ptr object's class - ptrClass = (*env)->GetObjectClass(env, ptrObj); - - // Get the Field ID of the instance variables "address" - fidNumber = (*env)->GetFieldID(env, ptrClass, "address", "J"); - if (fidNumber != NULL) { - // Get the long given the Field ID - nativeAddress = (*env)->GetLongField(env, ptrObj, fidNumber); + jclass ptrClass = (*env)->GetObjectClass(env, ptrObj); + if (ptrClass != NULL) { + // Get the Field ID of the instance variables "address" + jfieldID fidNumber = (*env)->GetFieldID(env, ptrClass, "address", "J"); + if (fidNumber != NULL) { + // Get the long given the Field ID + nativeAddress = (*env)->GetLongField(env, ptrObj, fidNumber); + } } // fprintf(stderr, "Native address : %lx\n", nativeAddress); return nativeAddress; @@ -91,10 +90,15 @@ static jlong getNativeAddress(JNIEnv* env, jobject ptrObj) { * Box the nativeAddress as a Pointer object. */ static jobject makePointerObject(JNIEnv* env, jlong nativeAddr) { + jobject retObj = NULL; jclass ptrClass = (*env)->FindClass(env, "jdk/tools/jaotc/jnilibelf/Pointer"); - // Call back constructor to allocate a Pointer object, with an int argument - jmethodID constructorId = (*env)->GetMethodID(env, ptrClass, "", "(J)V"); - jobject retObj = (*env)->NewObject(env, ptrClass, constructorId, nativeAddr); + if (ptrClass != NULL) { + // Call back constructor to allocate a Pointer object, with an int argument + jmethodID constructorId = (*env)->GetMethodID(env, ptrClass, "", "(J)V"); + if (constructorId != NULL) { + retObj = (*env)->NewObject(env, ptrClass, constructorId, nativeAddr); + } + } return retObj; } diff --git a/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/elfmacros.h b/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/elfmacros.h index 15bf64032f7..2dc0b611c2e 100644 --- a/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/elfmacros.h +++ b/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/elfmacros.h @@ -33,6 +33,7 @@ #define ELF_NHDR Elf64_Nhdr #define ELF_DYN Elf64_Dyn #define ELF_ADDR Elf64_Addr +#define ELF_AUXV Elf64_auxv_t #define ELF_ST_TYPE ELF64_ST_TYPE @@ -45,6 +46,7 @@ #define ELF_NHDR Elf32_Nhdr #define ELF_DYN Elf32_Dyn #define ELF_ADDR Elf32_Addr +#define ELF_AUXV Elf32_auxv_t #define ELF_ST_TYPE ELF32_ST_TYPE diff --git a/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/libproc_impl.c b/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/libproc_impl.c index c12f82d1bf6..3e3758b0cf6 100644 --- a/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/libproc_impl.c +++ b/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/libproc_impl.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -50,7 +50,7 @@ int pathmap_open(const char* name) { } - if (strlen(alt_root) + strlen(name) < PATH_MAX) { + if (strlen(alt_root) + strlen(name) > PATH_MAX) { // Buffer too small. return -1; } diff --git a/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/ps_core.c b/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/ps_core.c index 6c39d0c43f5..12a6347b366 100644 --- a/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/ps_core.c +++ b/hotspot/src/jdk.hotspot.agent/linux/native/libsaproc/ps_core.c @@ -642,6 +642,18 @@ static bool core_handle_note(struct ps_prochandle* ph, ELF_PHDR* note_phdr) { if (core_handle_prstatus(ph, descdata, notep->n_descsz) != true) { return false; } + } else if (notep->n_type == NT_AUXV) { + // Get first segment from entry point + ELF_AUXV *auxv = (ELF_AUXV *)descdata; + while (auxv->a_type != AT_NULL) { + if (auxv->a_type == AT_ENTRY) { + // Set entry point address to address of dynamic section. + // We will adjust it in read_exec_segments(). + ph->core->dynamic_addr = auxv->a_un.a_val; + break; + } + auxv++; + } } p = descdata + ROUNDUP(notep->n_descsz, 4); } @@ -832,7 +844,13 @@ static bool read_exec_segments(struct ps_prochandle* ph, ELF_EHDR* exec_ehdr) { // from PT_DYNAMIC we want to read address of first link_map addr case PT_DYNAMIC: { - ph->core->dynamic_addr = exec_php->p_vaddr; + if (exec_ehdr->e_type == ET_EXEC) { + ph->core->dynamic_addr = exec_php->p_vaddr; + } else { // ET_DYN + // dynamic_addr has entry point of executable. + // Thus we should substract it. + ph->core->dynamic_addr += exec_php->p_vaddr - exec_ehdr->e_entry; + } print_debug("address of _DYNAMIC is 0x%lx\n", ph->core->dynamic_addr); break; } @@ -1030,8 +1048,9 @@ struct ps_prochandle* Pgrab_core(const char* exec_file, const char* core_file) { goto err; } - if (read_elf_header(ph->core->exec_fd, &exec_ehdr) != true || exec_ehdr.e_type != ET_EXEC) { - print_debug("executable file is not a valid ELF ET_EXEC file\n"); + if (read_elf_header(ph->core->exec_fd, &exec_ehdr) != true || + ((exec_ehdr.e_type != ET_EXEC) && (exec_ehdr.e_type != ET_DYN))) { + print_debug("executable file is not a valid ELF file\n"); goto err; } diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/module-info.java b/hotspot/src/jdk.hotspot.agent/share/classes/module-info.java index dbf9587b307..a5308d46ea2 100644 --- a/hotspot/src/jdk.hotspot.agent/share/classes/module-info.java +++ b/hotspot/src/jdk.hotspot.agent/share/classes/module-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,6 +23,12 @@ * questions. */ +/** + * Defines the implementation of the HotSpot Serviceability Agent. + * + * @moduleGraph + * @since 9 + */ module jdk.hotspot.agent { requires java.datatransfer; requires java.desktop; diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/memory/AltHashing.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/memory/AltHashing.java new file mode 100644 index 00000000000..e3ff237815a --- /dev/null +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/memory/AltHashing.java @@ -0,0 +1,94 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + * + */ + +package sun.jvm.hotspot.memory; + +public class AltHashing { + public static long murmur3_32(long seed, byte[] data) { + long h1 = seed; + int len = data.length; + int count = len; + + int offset = 0; + + // body + while (count >= 4) { + long k1 = (data[offset] & 0x0FF) + | (data[offset + 1] & 0x0FF) << 8 + | (data[offset + 2] & 0x0FF) << 16 + | data[offset + 3] << 24; + + count -= 4; + offset += 4; + + k1 *= 0xcc9e2d51; + k1 = Integer.rotateLeft((int)k1, 15); + k1 *= 0x1b873593; + k1 &= 0xFFFFFFFFL; + + h1 ^= k1; + h1 = Integer.rotateLeft((int)h1, 13); + h1 = h1 * 5 + 0xe6546b64; + h1 &= 0xFFFFFFFFL; + } + + //tail + if (count > 0) { + long k1 = 0; + + switch (count) { + case 3: + k1 ^= (data[offset + 2] & 0xff) << 16; + // fall through + case 2: + k1 ^= (data[offset + 1] & 0xff) << 8; + // fall through + case 1: + k1 ^= (data[offset] & 0xff); + // fall through + default: + k1 *= 0xcc9e2d51; + k1 = Integer.rotateLeft((int)k1, 15); + k1 *= 0x1b873593; + k1 &= 0xFFFFFFFFL; + h1 ^= k1; + h1 &= 0xFFFFFFFFL; + } + } + + // finalization + h1 ^= len; + + // finalization mix force all bits of a hash block to avalanche + h1 ^= h1 >> 16; + h1 *= 0x85ebca6b; + h1 &= 0xFFFFFFFFL; + h1 ^= h1 >> 13; + h1 *= 0xc2b2ae35; + h1 &= 0xFFFFFFFFL; + h1 ^= h1 >> 16; + + return h1 & 0xFFFFFFFFL; + } +} diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/memory/SymbolTable.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/memory/SymbolTable.java index 46d087332ac..e2231b53ecb 100644 --- a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/memory/SymbolTable.java +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/memory/SymbolTable.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -45,11 +45,14 @@ public class SymbolTable extends sun.jvm.hotspot.utilities.Hashtable { Type type = db.lookupType("SymbolTable"); theTableField = type.getAddressField("_the_table"); sharedTableField = type.getAddressField("_shared_table"); + type = db.lookupType("RehashableSymbolHashtable"); + seedField = type.getCIntegerField("_seed"); } // Fields private static AddressField theTableField; private static AddressField sharedTableField; + private static CIntegerField seedField; private CompactHashTable sharedTable; @@ -62,6 +65,17 @@ public class SymbolTable extends sun.jvm.hotspot.utilities.Hashtable { return table; } + public static long getSeed() { + return (long) seedField.getValue(); + } + + public static boolean useAlternateHashcode() { + if (getSeed() != 0) { + return true; + } + return false; + } + public SymbolTable(Address addr) { super(addr); } @@ -86,11 +100,17 @@ public class SymbolTable extends sun.jvm.hotspot.utilities.Hashtable { public Symbol probe(byte[] name) { long hashValue = hashSymbol(name); + // shared table does not use alternate hashing algorithm, + // it always uses the same original hash code. Symbol s = sharedTable.probe(name, hashValue); if (s != null) { return s; } + if (useAlternateHashcode()) { + hashValue = AltHashing.murmur3_32(getSeed(), name); + } + for (HashtableEntry e = (HashtableEntry) bucket(hashToIndex(hashValue)); e != null; e = (HashtableEntry) e.next()) { if (e.hash() == hashValue) { Symbol sym = Symbol.create(e.literalValue()); diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/JavaThread.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/JavaThread.java index 406b6d775b9..654948fba53 100644 --- a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/JavaThread.java +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/JavaThread.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -50,6 +50,7 @@ public class JavaThread extends Thread { private static AddressField osThreadField; private static AddressField stackBaseField; private static CIntegerField stackSizeField; + private static CIntegerField terminatedField; private static JavaThreadPDAccess access; @@ -66,6 +67,9 @@ public class JavaThread extends Thread { private static int BLOCKED; private static int BLOCKED_TRANS; + private static int NOT_TERMINATED; + private static int EXITING; + static { VM.registerVMInitializedObserver(new Observer() { public void update(Observable o, Object data) { @@ -87,6 +91,7 @@ public class JavaThread extends Thread { osThreadField = type.getAddressField("_osthread"); stackBaseField = type.getAddressField("_stack_base"); stackSizeField = type.getCIntegerField("_stack_size"); + terminatedField = type.getCIntegerField("_terminated"); UNINITIALIZED = db.lookupIntConstant("_thread_uninitialized").intValue(); NEW = db.lookupIntConstant("_thread_new").intValue(); @@ -99,6 +104,10 @@ public class JavaThread extends Thread { IN_JAVA_TRANS = db.lookupIntConstant("_thread_in_Java_trans").intValue(); BLOCKED = db.lookupIntConstant("_thread_blocked").intValue(); BLOCKED_TRANS = db.lookupIntConstant("_thread_blocked_trans").intValue(); + + NOT_TERMINATED = db.lookupIntConstant("JavaThread::_not_terminated").intValue(); + EXITING = db.lookupIntConstant("JavaThread::_thread_exiting").intValue(); + } public JavaThread(Address addr) { @@ -128,6 +137,14 @@ public class JavaThread extends Thread { example, "SolarisSPARCCompilerThread".) */ public boolean isJavaThread() { return true; } + public boolean isExiting () { + return (getTerminated() == EXITING) || isTerminated(); + } + + public boolean isTerminated() { + return (getTerminated() != NOT_TERMINATED) && (getTerminated() != EXITING); + } + public static AddressField getAnchorField() { return anchorField; } /** Get the last Java stack pointer */ @@ -329,6 +346,10 @@ public class JavaThread extends Thread { return stackSizeField.getValue(addr); } + public int getTerminated() { + return (int) terminatedField.getValue(addr); + } + /** Gets the Java-side thread object for this JavaThread */ public Oop getThreadObj() { Oop obj = null; diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/StackFrameInfo.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/StackFrameInfo.java new file mode 100644 index 00000000000..9bc5d655f86 --- /dev/null +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/StackFrameInfo.java @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + * + */ + +package sun.jvm.hotspot.runtime; + +import sun.jvm.hotspot.oops.*; + +public class StackFrameInfo { + private Method method; + int bci; + Oop classHolder; + + public StackFrameInfo(JavaVFrame vf) { + this.method = vf.getMethod(); + this.bci = vf.getBCI(); + } + + public Method getMethod() { + return method; + } + + public int getBCI() { + return bci; + } +} diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/ThreadStackTrace.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/ThreadStackTrace.java new file mode 100644 index 00000000000..a599a171a57 --- /dev/null +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/ThreadStackTrace.java @@ -0,0 +1,69 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + * + */ + +package sun.jvm.hotspot.runtime; + +import java.util.*; + +public class ThreadStackTrace { + private JavaThread thread; + private int depth; // number of stack frames added + private ArrayList frames; + + public ThreadStackTrace(JavaThread t) { + this.thread = t; + this.depth = 0; + this.frames = new ArrayList(); + } + + public int getStackDepth() { + return depth; + } + + public StackFrameInfo stackFrameAt(int index) { + return frames.get(index); + } + + public void dumpStack(int maxDepth) { + if (!thread.isJavaThread()) { + System.out.println("dumpStack: not java Thread returning"); + return; + } + try { + for (JavaVFrame vf = thread.getLastJavaVFrameDbg(); vf != null; vf = vf.javaSender()) { + StackFrameInfo frame = new StackFrameInfo(vf); + frames.add(frame); + depth++; + + if (maxDepth > 0 && depth == maxDepth) { + // Skip frames if more than maxDepth + break; + } + } + } catch (Exception e) { + System.out.println("Error occurred during stack walking:"); + e.printStackTrace(); + } + } +} diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/ppc64/PPC64RegisterMap.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/ppc64/PPC64RegisterMap.java index ca06fc413e2..abe5e0c6730 100644 --- a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/ppc64/PPC64RegisterMap.java +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/ppc64/PPC64RegisterMap.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 20014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/tools/HeapSummary.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/tools/HeapSummary.java index 643109bc1e9..09a382f9439 100644 --- a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/tools/HeapSummary.java +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/tools/HeapSummary.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -150,13 +150,7 @@ public class HeapSummary extends Tool { // Helper methods private void printGCAlgorithm(Map flagMap) { - // print about new generation - long l = getFlagValue("UseParNewGC", flagMap); - if (l == 1L) { - System.out.println("using parallel threads in the new generation."); - } - - l = getFlagValue("UseTLAB", flagMap); + long l = getFlagValue("UseTLAB", flagMap); if (l == 1L) { System.out.println("using thread-local object allocation."); } diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/AbstractHeapGraphWriter.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/AbstractHeapGraphWriter.java index 5dbf8984158..eb3aad9495a 100644 --- a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/AbstractHeapGraphWriter.java +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/AbstractHeapGraphWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -114,6 +114,8 @@ public abstract class AbstractHeapGraphWriter implements HeapGraphWriter { } }); + writeHeapRecordPrologue(); + // write JavaThreads writeJavaThreads(); diff --git a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/HeapHprofBinWriter.java b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/HeapHprofBinWriter.java index 9da43745388..c9e3c122310 100644 --- a/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/HeapHprofBinWriter.java +++ b/hotspot/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/HeapHprofBinWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -45,8 +45,8 @@ import sun.jvm.hotspot.classfile.*; * WARNING: This format is still under development, and is subject to * change without notice. * - * header "JAVA PROFILE 1.0.1" or "JAVA PROFILE 1.0.2" (0-terminated) - * u4 size of identifiers. Identifiers are used to represent + * header "JAVA PROFILE 1.0.2" (0-terminated) + * u4 size of identifiers. Identifiers are used to represent * UTF8 strings, objects, stack traces, etc. They usually * have the same size as host pointers. For example, on * Solaris and Win32, the size is 4. @@ -294,10 +294,9 @@ import sun.jvm.hotspot.classfile.*; * u2 stack trace depth * * - * When the header is "JAVA PROFILE 1.0.2" a heap dump can optionally - * be generated as a sequence of heap dump segments. This sequence is - * terminated by an end record. The additional tags allowed by format - * "JAVA PROFILE 1.0.2" are: + * A heap dump can optionally be generated as a sequence of heap dump + * segments. This sequence is terminated by an end record. The additional + * tags allowed by format "JAVA PROFILE 1.0.2" are: * * HPROF_HEAP_DUMP_SEGMENT denote a heap dump segment * @@ -310,8 +309,6 @@ import sun.jvm.hotspot.classfile.*; public class HeapHprofBinWriter extends AbstractHeapGraphWriter { - // The heap size threshold used to determine if segmented format - // ("JAVA PROFILE 1.0.2") should be used. private static final long HPROF_SEGMENTED_HEAP_DUMP_THRESHOLD = 2L * 0x40000000; // The approximate size of a heap segment. Used to calculate when to create @@ -319,7 +316,6 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { private static final long HPROF_SEGMENTED_HEAP_DUMP_SEGMENT_SIZE = 1L * 0x40000000; // hprof binary file header - private static final String HPROF_HEADER_1_0_1 = "JAVA PROFILE 1.0.1"; private static final String HPROF_HEADER_1_0_2 = "JAVA PROFILE 1.0.2"; // constants in enum HprofTag @@ -380,8 +376,13 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { private static final int JVM_SIGNATURE_ARRAY = '['; private static final int JVM_SIGNATURE_CLASS = 'L'; + private static final long MAX_U4_VALUE = 0xFFFFFFFFL; int serialNum = 1; + public HeapHprofBinWriter() { + this.KlassMap = new ArrayList(); + } + public synchronized void write(String fileName) throws IOException { // open file stream and create buffered data output stream fos = new FileOutputStream(fileName); @@ -429,6 +430,9 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { // HPROF_LOAD_CLASS records for all classes writeClasses(); + // write HPROF_FRAME and HPROF_TRACE records + dumpStackTraces(); + // write CLASS_DUMP records writeClassDumpRecords(); @@ -469,7 +473,6 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { // length later - hprof format requires length. out.flush(); currentSegmentStart = fos.getChannel().position(); - // write dummy length of 0 and we'll fix it later. out.writeInt(0); } @@ -479,7 +482,7 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { protected void writeHeapRecordEpilogue() throws IOException { if (useSegmentedHeapDump) { out.flush(); - if ((fos.getChannel().position() - currentSegmentStart - 4) >= HPROF_SEGMENTED_HEAP_DUMP_SEGMENT_SIZE) { + if ((fos.getChannel().position() - currentSegmentStart - 4L) >= HPROF_SEGMENTED_HEAP_DUMP_SEGMENT_SIZE) { fillInHeapRecordLength(); currentSegmentStart = 0; } @@ -488,14 +491,14 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { private void fillInHeapRecordLength() throws IOException { - // now get current position to calculate length + // now get the current position to calculate length long dumpEnd = fos.getChannel().position(); - // calculate length of heap data + // calculate the length of heap data long dumpLenLong = (dumpEnd - currentSegmentStart - 4L); // Check length boundary, overflow could happen but is _very_ unlikely - if(dumpLenLong >= (4L * 0x40000000)){ + if (dumpLenLong >= (4L * 0x40000000)) { throw new RuntimeException("Heap segment size overflow."); } @@ -517,6 +520,71 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { fos.getChannel().position(currentPosition); } + // get the size in bytes for the requested type + private long getSizeForType(int type) throws IOException { + switch (type) { + case TypeArrayKlass.T_BOOLEAN: + return BOOLEAN_SIZE; + case TypeArrayKlass.T_INT: + return INT_SIZE; + case TypeArrayKlass.T_CHAR: + return CHAR_SIZE; + case TypeArrayKlass.T_SHORT: + return SHORT_SIZE; + case TypeArrayKlass.T_BYTE: + return BYTE_SIZE; + case TypeArrayKlass.T_LONG: + return LONG_SIZE; + case TypeArrayKlass.T_FLOAT: + return FLOAT_SIZE; + case TypeArrayKlass.T_DOUBLE: + return DOUBLE_SIZE; + default: + throw new RuntimeException( + "Should not reach here: Unknown type: " + type); + } + } + + private int getArrayHeaderSize(boolean isObjectAarray) { + return isObjectAarray? + ((int) BYTE_SIZE + 2 * (int) INT_SIZE + 2 * (int) OBJ_ID_SIZE): + (2 * (int) BYTE_SIZE + 2 * (int) INT_SIZE + (int) OBJ_ID_SIZE); + } + + // Check if we need to truncate an array + private int calculateArrayMaxLength(long originalArrayLength, + int headerSize, + long typeSize, + String typeName) throws IOException { + + long length = originalArrayLength; + + // now get the current position to calculate length + long dumpEnd = fos.getChannel().position(); + long originalLengthInBytes = originalArrayLength * typeSize; + + // calculate the length of heap data + long currentRecordLength = (dumpEnd - currentSegmentStart - 4L); + if (currentRecordLength > 0 && + (currentRecordLength + headerSize + originalLengthInBytes) > MAX_U4_VALUE) { + fillInHeapRecordLength(); + currentSegmentStart = 0; + writeHeapRecordPrologue(); + currentRecordLength = 0; + } + + // Calculate the max bytes we can use. + long maxBytes = (MAX_U4_VALUE - (headerSize + currentRecordLength)); + + if (originalLengthInBytes > maxBytes) { + length = maxBytes/typeSize; + System.err.println("WARNING: Cannot dump array of type " + typeName + + " with length " + originalArrayLength + + "; truncating to length " + length); + } + return (int) length; + } + private void writeClassDumpRecords() throws IOException { SystemDictionary sysDict = VM.getVM().getSystemDictionary(); ClassLoaderDataGraph cldGraph = VM.getVM().getClassLoaderDataGraph(); @@ -639,6 +707,67 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { } } + private void dumpStackTraces() throws IOException { + // write a HPROF_TRACE record without any frames to be referenced as object alloc sites + writeHeader(HPROF_TRACE, 3 * (int)INT_SIZE ); + out.writeInt(DUMMY_STACK_TRACE_ID); + out.writeInt(0); // thread number + out.writeInt(0); // frame count + + int frameSerialNum = 0; + int numThreads = 0; + Threads threads = VM.getVM().getThreads(); + + for (JavaThread thread = threads.first(); thread != null; thread = thread.next()) { + Oop threadObj = thread.getThreadObj(); + if (threadObj != null && !thread.isExiting() && !thread.isHiddenFromExternalView()) { + + // dump thread stack trace + ThreadStackTrace st = new ThreadStackTrace(thread); + st.dumpStack(-1); + numThreads++; + + // write HPROF_FRAME records for this thread's stack trace + int depth = st.getStackDepth(); + int threadFrameStart = frameSerialNum; + for (int j=0; j < depth; j++) { + StackFrameInfo frame = st.stackFrameAt(j); + Method m = frame.getMethod(); + int classSerialNum = KlassMap.indexOf(m.getMethodHolder()) + 1; + // the class serial number starts from 1 + assert classSerialNum > 0:"class not found"; + dumpStackFrame(++frameSerialNum, classSerialNum, m, frame.getBCI()); + } + + // write HPROF_TRACE record for one thread + writeHeader(HPROF_TRACE, 3 * (int)INT_SIZE + depth * (int)VM.getVM().getOopSize()); + int stackSerialNum = numThreads + DUMMY_STACK_TRACE_ID; + out.writeInt(stackSerialNum); // stack trace serial number + out.writeInt(numThreads); // thread serial number + out.writeInt(depth); // frame count + for (int j=1; j <= depth; j++) { + writeObjectID(threadFrameStart + j); + } + } + } + } + + private void dumpStackFrame(int frameSN, int classSN, Method m, int bci) throws IOException { + int lineNumber; + if (m.isNative()) { + lineNumber = -3; // native frame + } else { + lineNumber = m.getLineNumberFromBCI(bci); + } + writeHeader(HPROF_FRAME, 4 * (int)VM.getVM().getOopSize() + 2 * (int)INT_SIZE); + writeObjectID(frameSN); // frame serial number + writeSymbolID(m.getName()); // method's name + writeSymbolID(m.getSignature()); // method's signature + writeSymbolID(m.getMethodHolder().getSourceFileName()); // source file name + out.writeInt(classSN); // class serial number + out.writeInt(lineNumber); // line number + } + protected void writeJavaThread(JavaThread jt, int index) throws IOException { out.writeByte((byte) HPROF_GC_ROOT_THREAD_OBJ); writeObjectID(jt.getThreadObj()); @@ -694,12 +823,16 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { } protected void writeObjectArray(ObjArray array) throws IOException { + int headerSize = getArrayHeaderSize(true); + final int length = calculateArrayMaxLength(array.getLength(), + headerSize, + OBJ_ID_SIZE, + "Object"); out.writeByte((byte) HPROF_GC_OBJ_ARRAY_DUMP); writeObjectID(array); out.writeInt(DUMMY_STACK_TRACE_ID); - out.writeInt((int) array.getLength()); + out.writeInt(length); writeObjectID(array.getKlass().getJavaMirror()); - final int length = (int) array.getLength(); for (int index = 0; index < length; index++) { OopHandle handle = array.getOopHandleAt(index); writeObjectID(getAddressValue(handle)); @@ -707,101 +840,101 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { } protected void writePrimitiveArray(TypeArray array) throws IOException { + int headerSize = getArrayHeaderSize(false); + TypeArrayKlass tak = (TypeArrayKlass) array.getKlass(); + final int type = (int) tak.getElementType(); + final String typeName = tak.getElementTypeName(); + final long typeSize = getSizeForType(type); + final int length = calculateArrayMaxLength(array.getLength(), + headerSize, + typeSize, + typeName); out.writeByte((byte) HPROF_GC_PRIM_ARRAY_DUMP); writeObjectID(array); out.writeInt(DUMMY_STACK_TRACE_ID); - out.writeInt((int) array.getLength()); - TypeArrayKlass tak = (TypeArrayKlass) array.getKlass(); - final int type = (int) tak.getElementType(); + out.writeInt(length); out.writeByte((byte) type); switch (type) { case TypeArrayKlass.T_BOOLEAN: - writeBooleanArray(array); + writeBooleanArray(array, length); break; case TypeArrayKlass.T_CHAR: - writeCharArray(array); + writeCharArray(array, length); break; case TypeArrayKlass.T_FLOAT: - writeFloatArray(array); + writeFloatArray(array, length); break; case TypeArrayKlass.T_DOUBLE: - writeDoubleArray(array); + writeDoubleArray(array, length); break; case TypeArrayKlass.T_BYTE: - writeByteArray(array); + writeByteArray(array, length); break; case TypeArrayKlass.T_SHORT: - writeShortArray(array); + writeShortArray(array, length); break; case TypeArrayKlass.T_INT: - writeIntArray(array); + writeIntArray(array, length); break; case TypeArrayKlass.T_LONG: - writeLongArray(array); + writeLongArray(array, length); break; default: - throw new RuntimeException("should not reach here"); + throw new RuntimeException( + "Should not reach here: Unknown type: " + type); } } - private void writeBooleanArray(TypeArray array) throws IOException { - final int length = (int) array.getLength(); + private void writeBooleanArray(TypeArray array, int length) throws IOException { for (int index = 0; index < length; index++) { long offset = BOOLEAN_BASE_OFFSET + index * BOOLEAN_SIZE; out.writeBoolean(array.getHandle().getJBooleanAt(offset)); } } - private void writeByteArray(TypeArray array) throws IOException { - final int length = (int) array.getLength(); + private void writeByteArray(TypeArray array, int length) throws IOException { for (int index = 0; index < length; index++) { long offset = BYTE_BASE_OFFSET + index * BYTE_SIZE; out.writeByte(array.getHandle().getJByteAt(offset)); } } - private void writeShortArray(TypeArray array) throws IOException { - final int length = (int) array.getLength(); + private void writeShortArray(TypeArray array, int length) throws IOException { for (int index = 0; index < length; index++) { long offset = SHORT_BASE_OFFSET + index * SHORT_SIZE; out.writeShort(array.getHandle().getJShortAt(offset)); } } - private void writeIntArray(TypeArray array) throws IOException { - final int length = (int) array.getLength(); + private void writeIntArray(TypeArray array, int length) throws IOException { for (int index = 0; index < length; index++) { long offset = INT_BASE_OFFSET + index * INT_SIZE; out.writeInt(array.getHandle().getJIntAt(offset)); } } - private void writeLongArray(TypeArray array) throws IOException { - final int length = (int) array.getLength(); + private void writeLongArray(TypeArray array, int length) throws IOException { for (int index = 0; index < length; index++) { long offset = LONG_BASE_OFFSET + index * LONG_SIZE; out.writeLong(array.getHandle().getJLongAt(offset)); } } - private void writeCharArray(TypeArray array) throws IOException { - final int length = (int) array.getLength(); + private void writeCharArray(TypeArray array, int length) throws IOException { for (int index = 0; index < length; index++) { long offset = CHAR_BASE_OFFSET + index * CHAR_SIZE; out.writeChar(array.getHandle().getJCharAt(offset)); } } - private void writeFloatArray(TypeArray array) throws IOException { - final int length = (int) array.getLength(); + private void writeFloatArray(TypeArray array, int length) throws IOException { for (int index = 0; index < length; index++) { long offset = FLOAT_BASE_OFFSET + index * FLOAT_SIZE; out.writeFloat(array.getHandle().getJFloatAt(offset)); } } - private void writeDoubleArray(TypeArray array) throws IOException { - final int length = (int) array.getLength(); + private void writeDoubleArray(TypeArray array, int length) throws IOException { for (int index = 0; index < length; index++) { long offset = DOUBLE_BASE_OFFSET + index * DOUBLE_SIZE; out.writeDouble(array.getHandle().getJDoubleAt(offset)); @@ -965,6 +1098,7 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { writeHeader(HPROF_LOAD_CLASS, 2 * (OBJ_ID_SIZE + 4)); out.writeInt(serialNum); writeObjectID(clazz); + KlassMap.add(serialNum - 1, k); out.writeInt(DUMMY_STACK_TRACE_ID); writeSymbolID(k.getName()); serialNum++; @@ -980,6 +1114,7 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { writeHeader(HPROF_LOAD_CLASS, 2 * (OBJ_ID_SIZE + 4)); out.writeInt(serialNum); writeObjectID(clazz); + KlassMap.add(serialNum - 1, k); out.writeInt(DUMMY_STACK_TRACE_ID); writeSymbolID(k.getName()); serialNum++; @@ -996,12 +1131,7 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { // writes hprof binary file header private void writeFileHeader() throws IOException { // version string - if(useSegmentedHeapDump) { - out.writeBytes(HPROF_HEADER_1_0_2); - } - else { - out.writeBytes(HPROF_HEADER_1_0_1); - } + out.writeBytes(HPROF_HEADER_1_0_2); out.writeByte((byte)'\0'); // write identifier size. we use pointers as identifiers. @@ -1097,6 +1227,7 @@ public class HeapHprofBinWriter extends AbstractHeapGraphWriter { private Debugger dbg; private ObjectHeap objectHeap; private SymbolTable symTbl; + private ArrayList KlassMap; // oopSize of the debuggee private int OBJ_ID_SIZE; diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.aarch64/src/jdk/vm/ci/aarch64/AArch64.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.aarch64/src/jdk/vm/ci/aarch64/AArch64.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.aarch64/src/jdk/vm/ci/aarch64/AArch64.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.aarch64/src/jdk/vm/ci/aarch64/AArch64.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.aarch64/src/jdk/vm/ci/aarch64/AArch64Kind.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.aarch64/src/jdk/vm/ci/aarch64/AArch64Kind.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.aarch64/src/jdk/vm/ci/aarch64/AArch64Kind.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.aarch64/src/jdk/vm/ci/aarch64/AArch64Kind.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.amd64/src/jdk/vm/ci/amd64/AMD64.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.amd64/src/jdk/vm/ci/amd64/AMD64.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.amd64/src/jdk/vm/ci/amd64/AMD64.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.amd64/src/jdk/vm/ci/amd64/AMD64.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.amd64/src/jdk/vm/ci/amd64/AMD64Kind.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.amd64/src/jdk/vm/ci/amd64/AMD64Kind.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.amd64/src/jdk/vm/ci/amd64/AMD64Kind.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.amd64/src/jdk/vm/ci/amd64/AMD64Kind.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/overview.html b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/overview.html similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/overview.html rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/overview.html diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Architecture.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Architecture.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Architecture.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Architecture.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BailoutException.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BailoutException.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BailoutException.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BailoutException.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BytecodeFrame.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BytecodeFrame.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BytecodeFrame.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BytecodeFrame.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BytecodePosition.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BytecodePosition.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BytecodePosition.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/BytecodePosition.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CallingConvention.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CallingConvention.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CallingConvention.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CallingConvention.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CodeCacheProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CodeCacheProvider.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CodeCacheProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CodeCacheProvider.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CodeUtil.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CodeUtil.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CodeUtil.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CodeUtil.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompilationRequest.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompilationRequest.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompilationRequest.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompilationRequest.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompilationRequestResult.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompilationRequestResult.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompilationRequestResult.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompilationRequestResult.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompiledCode.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompiledCode.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompiledCode.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/CompiledCode.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/DebugInfo.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/DebugInfo.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/DebugInfo.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/DebugInfo.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/InstalledCode.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/InstalledCode.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/InstalledCode.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/InstalledCode.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/InvalidInstalledCodeException.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/InvalidInstalledCodeException.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/InvalidInstalledCodeException.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/InvalidInstalledCodeException.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Location.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Location.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Location.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Location.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/MemoryBarriers.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/MemoryBarriers.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/MemoryBarriers.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/MemoryBarriers.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ReferenceMap.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ReferenceMap.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ReferenceMap.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ReferenceMap.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Register.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Register.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Register.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/Register.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterArray.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterArray.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterArray.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterArray.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterAttributes.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterAttributes.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterAttributes.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterAttributes.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterConfig.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterConfig.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterSaveLayout.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterSaveLayout.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterSaveLayout.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterSaveLayout.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterValue.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterValue.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterValue.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/RegisterValue.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/StackLockValue.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/StackLockValue.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/StackLockValue.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/StackLockValue.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/StackSlot.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/StackSlot.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/StackSlot.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/StackSlot.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/SuppressFBWarnings.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/SuppressFBWarnings.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/SuppressFBWarnings.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/SuppressFBWarnings.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/TargetDescription.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/TargetDescription.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/TargetDescription.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/TargetDescription.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ValueKindFactory.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ValueKindFactory.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ValueKindFactory.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ValueKindFactory.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ValueUtil.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ValueUtil.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ValueUtil.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/ValueUtil.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/VirtualObject.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/VirtualObject.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/VirtualObject.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/VirtualObject.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/package-info.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/package-info.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/package-info.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/package-info.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Call.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Call.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Call.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Call.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/ConstantReference.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/ConstantReference.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/ConstantReference.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/ConstantReference.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/DataPatch.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/DataPatch.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/DataPatch.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/DataPatch.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/DataSectionReference.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/DataSectionReference.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/DataSectionReference.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/DataSectionReference.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/ExceptionHandler.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/ExceptionHandler.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/ExceptionHandler.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/ExceptionHandler.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Infopoint.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Infopoint.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Infopoint.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Infopoint.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/InfopointReason.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/InfopointReason.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/InfopointReason.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/InfopointReason.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Mark.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Mark.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Mark.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Mark.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Reference.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Reference.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Reference.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Reference.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Site.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Site.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Site.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/site/Site.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/InspectedFrame.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/InspectedFrame.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/InspectedFrame.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/InspectedFrame.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/InspectedFrameVisitor.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/InspectedFrameVisitor.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/InspectedFrameVisitor.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/InspectedFrameVisitor.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/StackIntrospection.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/StackIntrospection.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/StackIntrospection.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.code/src/jdk/vm/ci/code/stack/StackIntrospection.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/InitTimer.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/InitTimer.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/InitTimer.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/InitTimer.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/JVMCIError.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/JVMCIError.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/JVMCIError.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/JVMCIError.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/SuppressFBWarnings.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/SuppressFBWarnings.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/SuppressFBWarnings.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.common/src/jdk/vm/ci/common/SuppressFBWarnings.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotJVMCIBackendFactory.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotJVMCIBackendFactory.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotJVMCIBackendFactory.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotJVMCIBackendFactory.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotRegisterConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotRegisterConfig.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotRegisterConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotRegisterConfig.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotVMConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotVMConfig.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotVMConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.aarch64/src/jdk/vm/ci/hotspot/aarch64/AArch64HotSpotVMConfig.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotJVMCIBackendFactory.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotJVMCIBackendFactory.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotJVMCIBackendFactory.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotJVMCIBackendFactory.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotRegisterConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotRegisterConfig.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotRegisterConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotRegisterConfig.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotVMConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotVMConfig.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotVMConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.amd64/src/jdk/vm/ci/hotspot/amd64/AMD64HotSpotVMConfig.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotJVMCIBackendFactory.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotJVMCIBackendFactory.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotJVMCIBackendFactory.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotJVMCIBackendFactory.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotRegisterConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotRegisterConfig.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotRegisterConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotRegisterConfig.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotVMConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotVMConfig.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotVMConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot.sparc/src/jdk/vm/ci/hotspot/sparc/SPARCHotSpotVMConfig.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java similarity index 97% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java index e0b5acb426f..a5c0c7c3b62 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java @@ -278,8 +278,10 @@ final class CompilerToVM { * {@code info} are: * *
-     *     [(int) flags,   // only valid if field is resolved
-     *      (int) offset]  // only valid if field is resolved
+     *     [ flags,  // fieldDescriptor::access_flags()
+     *       offset, // fieldDescriptor::offset()
+     *       index   // fieldDescriptor::index()
+     *     ]
      * 
* * The behavior of this method is undefined if {@code cpi} does not denote a @@ -288,7 +290,7 @@ final class CompilerToVM { * @param info an array in which the details of the field are returned * @return the type defining the field if resolution is successful, 0 otherwise */ - native HotSpotResolvedObjectTypeImpl resolveFieldInPool(HotSpotConstantPool constantPool, int cpi, HotSpotResolvedJavaMethodImpl method, byte opcode, long[] info); + native HotSpotResolvedObjectTypeImpl resolveFieldInPool(HotSpotConstantPool constantPool, int cpi, HotSpotResolvedJavaMethodImpl method, byte opcode, int[] info); /** * Converts {@code cpci} from an index into the cache for {@code constantPool} to an index @@ -631,4 +633,15 @@ final class CompilerToVM { * {@code lambdaForm} (which must be a {@code java.lang.invoke.LambdaForm} instance). */ native void compileToBytecode(Object lambdaForm); + + /** + * Gets the value of the VM flag named {@code name}. + * + * @param name name of a VM option + * @return {@code this} if the named VM option doesn't exist, a {@link String} or {@code null} + * if its type is {@code ccstr} or {@code ccstrlist}, a {@link Double} if its type is + * {@code double}, a {@link Boolean} if its type is {@code bool} otherwise a + * {@link Long} + */ + native Object getFlagValue(String name); } diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EmptyEventProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EmptyEventProvider.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EmptyEventProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EmptyEventProvider.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EventProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EventProvider.java similarity index 98% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EventProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EventProvider.java index 0f46e5e4a07..2aa77349734 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EventProvider.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/EventProvider.java @@ -24,7 +24,6 @@ package jdk.vm.ci.hotspot; import jdk.vm.ci.hotspot.EmptyEventProvider.EmptyCompilationEvent; import jdk.vm.ci.hotspot.EmptyEventProvider.EmptyCompilerFailureEvent; -import jdk.vm.ci.services.JVMCIPermission; /** * Service-provider class for logging compiler related events. diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCallingConventionType.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCallingConventionType.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCallingConventionType.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCallingConventionType.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCodeCacheProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCodeCacheProvider.java similarity index 99% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCodeCacheProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCodeCacheProvider.java index f5489fb18c5..b77ed14ca8e 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCodeCacheProvider.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCodeCacheProvider.java @@ -76,7 +76,7 @@ public class HotSpotCodeCacheProvider implements CodeCacheProvider { HotSpotVMConfigStore store = runtime.getConfigStore(); for (Map.Entry e : store.getFields().entrySet()) { VMField field = e.getValue(); - if (field.isStatic() && field.value != null && field.value == address) { + if (field.isStatic() && field.value != null && field.value instanceof Long && ((Long) field.value) == address) { return e.getValue() + ":0x" + Long.toHexString(address); } } diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompilationRequest.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompilationRequest.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompilationRequest.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompilationRequest.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompilationRequestResult.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompilationRequestResult.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompilationRequestResult.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompilationRequestResult.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompiledCode.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompiledCode.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompiledCode.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompiledCode.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompiledNmethod.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompiledNmethod.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompiledNmethod.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompiledNmethod.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompressedNullConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompressedNullConstant.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompressedNullConstant.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotCompressedNullConstant.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstant.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstant.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstant.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantPool.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantPool.java similarity index 98% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantPool.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantPool.java index 957f66516b9..d88a8468e73 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantPool.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantPool.java @@ -298,7 +298,7 @@ final class HotSpotConstantPool implements ConstantPool, MetaspaceWrapperObject * @param index constant pool index * @return constant pool entry */ - private long getEntryAt(int index) { + long getEntryAt(int index) { assert checkBounds(index); int offset = index * runtime().getHostJVMCIBackend().getTarget().wordSize; return UNSAFE.getAddress(getMetaspaceConstantPool() + config().constantPoolSize + offset); @@ -605,8 +605,6 @@ final class HotSpotConstantPool implements ConstantPool, MetaspaceWrapperObject public JavaField lookupField(int cpi, ResolvedJavaMethod method, int opcode) { final int index = rawIndexToConstantPoolIndex(cpi, opcode); final int nameAndTypeIndex = getNameAndTypeRefIndexAt(index); - final int nameIndex = getNameRefIndexAt(nameAndTypeIndex); - String name = lookupUtf8(nameIndex); final int typeIndex = getSignatureRefIndexAt(nameAndTypeIndex); String typeName = lookupUtf8(typeIndex); JavaType type = runtime().lookupType(typeName, getHolder(), false); @@ -615,7 +613,7 @@ final class HotSpotConstantPool implements ConstantPool, MetaspaceWrapperObject JavaType holder = lookupType(holderIndex, opcode); if (holder instanceof HotSpotResolvedObjectTypeImpl) { - long[] info = new long[2]; + int[] info = new int[3]; HotSpotResolvedObjectTypeImpl resolvedHolder; try { resolvedHolder = compilerToVM().resolveFieldInPool(this, index, (HotSpotResolvedJavaMethodImpl) method, (byte) opcode, info); @@ -624,14 +622,15 @@ final class HotSpotConstantPool implements ConstantPool, MetaspaceWrapperObject * If there was an exception resolving the field we give up and return an unresolved * field. */ - return new HotSpotUnresolvedField(holder, name, type); + return new HotSpotUnresolvedField(holder, lookupUtf8(getNameRefIndexAt(nameAndTypeIndex)), type); } - final int flags = (int) info[0]; - final long offset = info[1]; - HotSpotResolvedJavaField result = resolvedHolder.createField(name, type, offset, flags); + final int flags = info[0]; + final int offset = info[1]; + final int fieldIndex = info[2]; + HotSpotResolvedJavaField result = resolvedHolder.createField(type, offset, flags, fieldIndex); return result; } else { - return new HotSpotUnresolvedField(holder, name, type); + return new HotSpotUnresolvedField(holder, lookupUtf8(getNameRefIndexAt(nameAndTypeIndex)), type); } } diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantReflectionProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantReflectionProvider.java similarity index 94% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantReflectionProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantReflectionProvider.java index e74027f2dd1..1256cf02584 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantReflectionProvider.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotConstantReflectionProvider.java @@ -179,11 +179,14 @@ public class HotSpotConstantReflectionProvider implements ConstantReflectionProv if (hotspotField.isStatic()) { HotSpotResolvedJavaType holder = (HotSpotResolvedJavaType) hotspotField.getDeclaringClass(); if (holder.isInitialized()) { - return memoryAccess.readUnsafeConstant(hotspotField.getJavaKind(), HotSpotObjectConstantImpl.forObject(holder.mirror()), hotspotField.offset()); + return memoryAccess.readFieldValue(hotspotField, holder.mirror()); } } else { - if (receiver.isNonNull() && hotspotField.isInObject(((HotSpotObjectConstantImpl) receiver).object())) { - return memoryAccess.readUnsafeConstant(hotspotField.getJavaKind(), receiver, hotspotField.offset()); + if (receiver.isNonNull()) { + Object object = ((HotSpotObjectConstantImpl) receiver).object(); + if (hotspotField.isInObject(object)) { + return memoryAccess.readFieldValue(hotspotField, object); + } } } return null; diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotForeignCallTarget.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotForeignCallTarget.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotForeignCallTarget.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotForeignCallTarget.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotInstalledCode.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotInstalledCode.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotInstalledCode.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotInstalledCode.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIBackendFactory.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIBackendFactory.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIBackendFactory.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIBackendFactory.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerConfig.java similarity index 83% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerConfig.java index 366fe5f25a9..3f04f6ec2fe 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerConfig.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerConfig.java @@ -28,9 +28,9 @@ import jdk.vm.ci.hotspot.HotSpotJVMCIRuntime.Option; import jdk.vm.ci.runtime.JVMCICompiler; import jdk.vm.ci.runtime.JVMCICompilerFactory; import jdk.vm.ci.runtime.JVMCIRuntime; -import jdk.vm.ci.services.JVMCIServiceLocator; import jdk.vm.ci.services.JVMCIPermission; -import jdk.vm.ci.services.Services; +import jdk.vm.ci.services.JVMCIServiceLocator; +import jdk.vm.ci.services.internal.ReflectionAccessJDK; final class HotSpotJVMCICompilerConfig { @@ -47,7 +47,7 @@ final class HotSpotJVMCICompilerConfig { @Override public String getCompilerName() { - return ""; + return "null"; } @Override @@ -73,19 +73,23 @@ final class HotSpotJVMCICompilerConfig { JVMCICompilerFactory factory = null; String compilerName = Option.Compiler.getString(); if (compilerName != null) { - for (JVMCICompilerFactory f : JVMCIServiceLocator.getProviders(JVMCICompilerFactory.class)) { - if (f.getCompilerName().equals(compilerName)) { - factory = f; + if (compilerName.isEmpty() || compilerName.equals("null")) { + factory = new DummyCompilerFactory(); + } else { + for (JVMCICompilerFactory f : JVMCIServiceLocator.getProviders(JVMCICompilerFactory.class)) { + if (f.getCompilerName().equals(compilerName)) { + factory = f; + } + } + if (factory == null) { + throw new JVMCIError("JVMCI compiler '%s' not found", compilerName); } - } - if (factory == null) { - throw new JVMCIError("JVMCI compiler '%s' not found", compilerName); } } else { // Auto select a single available compiler for (JVMCICompilerFactory f : JVMCIServiceLocator.getProviders(JVMCICompilerFactory.class)) { if (factory == null) { - Services.exportJVMCITo(f.getClass()); + ReflectionAccessJDK.openJVMCITo(f.getClass()); factory = f; } else { // Multiple factories seen - cancel auto selection diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerFactory.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerFactory.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerFactory.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCICompilerFactory.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIMetaAccessContext.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIMetaAccessContext.java similarity index 88% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIMetaAccessContext.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIMetaAccessContext.java index 529a561eb5e..cf5ef10ccf2 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIMetaAccessContext.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIMetaAccessContext.java @@ -27,8 +27,6 @@ import java.lang.ref.ReferenceQueue; import java.lang.ref.WeakReference; import java.util.Arrays; import java.util.Iterator; -import java.util.Map; -import java.util.WeakHashMap; import jdk.vm.ci.meta.JavaKind; import jdk.vm.ci.meta.ResolvedJavaType; @@ -147,21 +145,34 @@ public class HotSpotJVMCIMetaAccessContext { } } - private final Map, WeakReference> typeMap = new WeakHashMap<>(); + private final ClassValue> resolvedJavaType = new ClassValue>() { + @Override + protected WeakReference computeValue(Class type) { + return new WeakReference<>(createClass(type)); + } + }; /** * Gets the JVMCI mirror for a {@link Class} object. * * @return the {@link ResolvedJavaType} corresponding to {@code javaClass} */ - public synchronized ResolvedJavaType fromClass(Class javaClass) { - WeakReference typeRef = typeMap.get(javaClass); - ResolvedJavaType type = typeRef != null ? typeRef.get() : null; - if (type == null) { - type = createClass(javaClass); - typeMap.put(javaClass, new WeakReference<>(type)); + public ResolvedJavaType fromClass(Class javaClass) { + ResolvedJavaType javaType = null; + while (javaType == null) { + WeakReference type = resolvedJavaType.get(javaClass); + javaType = type.get(); + if (javaType == null) { + /* + * If the referent has become null, clear out the current value + * and let computeValue above create a new value. Reload the + * value in a loop because in theory the WeakReference referent + * can be reclaimed at any point. + */ + resolvedJavaType.remove(javaClass); + } } - return type; + return javaType; } /** diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntime.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntime.java similarity index 96% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntime.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntime.java index f6c97ecb07f..ab7dba465cc 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntime.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntime.java @@ -32,6 +32,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.Objects; +import java.util.ServiceLoader; import java.util.TreeMap; import jdk.internal.misc.VM; @@ -50,7 +51,6 @@ import jdk.vm.ci.runtime.JVMCIBackend; import jdk.vm.ci.runtime.JVMCICompiler; import jdk.vm.ci.runtime.JVMCICompilerFactory; import jdk.vm.ci.services.JVMCIServiceLocator; -import jdk.vm.ci.services.Services; /** * HotSpot implementation of a JVMCI runtime. @@ -88,7 +88,10 @@ public final class HotSpotJVMCIRuntime implements HotSpotJVMCIRuntimeProvider { */ public enum Option { // @formatter:off - Compiler(String.class, null, "Selects the system compiler."), + Compiler(String.class, null, "Selects the system compiler. This must match the getCompilerName() value returned " + + "by a jdk.vm.ci.runtime.JVMCICompilerFactory provider. " + + "An empty string or the value \"null\" selects a compiler " + + "that will raise an exception upon receiving a compilation request."), // Note: The following one is not used (see InitTimer.ENABLED). It is added here // so that -XX:+JVMCIPrintProperties shows the option. InitTimer(Boolean.class, false, "Specifies if initialization timing is enabled."), @@ -208,7 +211,7 @@ public final class HotSpotJVMCIRuntime implements HotSpotJVMCIRuntimeProvider { } public static HotSpotJVMCIBackendFactory findFactory(String architecture) { - for (HotSpotJVMCIBackendFactory factory : Services.load(HotSpotJVMCIBackendFactory.class)) { + for (HotSpotJVMCIBackendFactory factory : ServiceLoader.load(HotSpotJVMCIBackendFactory.class, ClassLoader.getSystemClassLoader())) { if (factory.getArchitecture().equalsIgnoreCase(architecture)) { return factory; } @@ -497,7 +500,7 @@ public final class HotSpotJVMCIRuntime implements HotSpotJVMCIRuntimeProvider { if (!field.isStatic()) { printConfigLine(vm, "[vmconfig:instance field] %s %s {offset=%d[0x%x]}%n", field.type, field.name, field.offset, field.offset); } else { - String value = field.value == null ? "null" : String.format("%d[0x%x]", field.value, field.value); + String value = field.value == null ? "null" : field.value instanceof Boolean ? field.value.toString() : String.format("%d[0x%x]", field.value, field.value); printConfigLine(vm, "[vmconfig:static field] %s %s = %s {address=0x%x}%n", field.type, field.name, value, field.address); } } @@ -513,10 +516,6 @@ public final class HotSpotJVMCIRuntime implements HotSpotJVMCIRuntimeProvider { for (Map.Entry e : constants.entrySet()) { printConfigLine(vm, "[vmconfig:constant] %s = %d[0x%x]%n", e.getKey(), e.getValue(), e.getValue()); } - TreeMap typeSizes = new TreeMap<>(store.getTypeSizes()); - for (Map.Entry e : typeSizes.entrySet()) { - printConfigLine(vm, "[vmconfig:type size] %s = %d%n", e.getKey(), e.getValue()); - } for (VMIntrinsicMethod e : store.getIntrinsics()) { printConfigLine(vm, "[vmconfig:intrinsic] %d = %s.%s %s%n", e.id, e.declaringClass, e.name, e.descriptor); } diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntimeProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntimeProvider.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntimeProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntimeProvider.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJavaType.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJavaType.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJavaType.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJavaType.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProvider.java similarity index 89% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProvider.java index a4d68b56f19..15250e2c7d1 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProvider.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProvider.java @@ -31,6 +31,10 @@ import jdk.vm.ci.meta.MemoryAccessProvider; */ public interface HotSpotMemoryAccessProvider extends MemoryAccessProvider { + /** + * @throws IllegalArgumentException if the address computed from {@code base} and + * {@code displacement} does not denote a location holding a narrow oop + */ JavaConstant readNarrowOopConstant(Constant base, long displacement); Constant readKlassPointerConstant(Constant base, long displacement); diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java similarity index 55% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java index be8e3a32067..e3ad9c834c2 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java @@ -22,13 +22,21 @@ */ package jdk.vm.ci.hotspot; +import static jdk.vm.ci.hotspot.HotSpotJVMCIRuntimeProvider.getArrayBaseOffset; +import static jdk.vm.ci.hotspot.HotSpotJVMCIRuntimeProvider.getArrayIndexScale; import static jdk.vm.ci.hotspot.UnsafeAccess.UNSAFE; +import java.lang.reflect.Array; + +import jdk.vm.ci.common.JVMCIError; import jdk.vm.ci.meta.Constant; import jdk.vm.ci.meta.JavaConstant; import jdk.vm.ci.meta.JavaKind; import jdk.vm.ci.meta.MemoryAccessProvider; +import jdk.vm.ci.meta.MetaAccessProvider; import jdk.vm.ci.meta.PrimitiveConstant; +import jdk.vm.ci.meta.ResolvedJavaField; +import jdk.vm.ci.meta.ResolvedJavaType; /** * HotSpot implementation of {@link MemoryAccessProvider}. @@ -41,12 +49,93 @@ class HotSpotMemoryAccessProviderImpl implements HotSpotMemoryAccessProvider { this.runtime = runtime; } - private static Object asObject(Constant base) { + /** + * Gets the object boxed by {@code base} that is about to have a value of kind {@code kind} read + * from it at the offset {@code displacement}. + * + * @param base constant value containing the base address for a pending read + * @return {@code null} if {@code base} does not box an object otherwise the object boxed in + * {@code base} + */ + private Object asObject(Constant base, JavaKind kind, long displacement) { if (base instanceof HotSpotObjectConstantImpl) { - return ((HotSpotObjectConstantImpl) base).object(); - } else { - return null; + HotSpotObjectConstantImpl constant = (HotSpotObjectConstantImpl) base; + HotSpotResolvedObjectType type = constant.getType(); + Object object = constant.object(); + checkRead(kind, displacement, type, object); + return object; } + return null; + } + + /** + * Offset of injected {@code java.lang.Class::oop_size} field. No need to make {@code volatile} + * as initialization is idempotent. + */ + private long oopSizeOffset; + + private static int computeOopSizeOffset(HotSpotJVMCIRuntimeProvider runtime) { + MetaAccessProvider metaAccess = runtime.getHostJVMCIBackend().getMetaAccess(); + ResolvedJavaType staticType = metaAccess.lookupJavaType(Class.class); + for (ResolvedJavaField f : staticType.getInstanceFields(false)) { + if (f.getName().equals("oop_size")) { + int offset = ((HotSpotResolvedJavaField) f).offset(); + assert offset != 0 : "not expecting offset of java.lang.Class::oop_size to be 0"; + return offset; + } + } + throw new JVMCIError("Could not find injected java.lang.Class::oop_size field"); + } + + private boolean checkRead(JavaKind kind, long displacement, HotSpotResolvedObjectType type, Object object) { + if (type.isArray()) { + ResolvedJavaType componentType = type.getComponentType(); + JavaKind componentKind = componentType.getJavaKind(); + final int headerSize = getArrayBaseOffset(componentKind); + int sizeOfElement = getArrayIndexScale(componentKind); + int length = Array.getLength(object); + long arrayEnd = headerSize + (sizeOfElement * length); + boolean aligned = ((displacement - headerSize) % sizeOfElement) == 0; + if (displacement < 0 || displacement > (arrayEnd - sizeOfElement) || (kind == JavaKind.Object && !aligned)) { + int index = (int) ((displacement - headerSize) / sizeOfElement); + throw new IllegalArgumentException("Unsafe array access: reading element of kind " + kind + + " at offset " + displacement + " (index ~ " + index + ") in " + + type.toJavaName() + " object of length " + length); + } + } else if (kind != JavaKind.Object) { + long size; + if (object instanceof Class) { + if (oopSizeOffset == 0) { + oopSizeOffset = computeOopSizeOffset(runtime); + } + int wordSize = runtime.getHostJVMCIBackend().getCodeCache().getTarget().wordSize; + size = UNSAFE.getInt(object, oopSizeOffset) * wordSize; + } else { + size = Math.abs(type.instanceSize()); + } + int bytesToRead = kind.getByteCount(); + if (displacement + bytesToRead > size || displacement < 0) { + throw new IllegalArgumentException("Unsafe access: reading " + bytesToRead + " bytes at offset " + displacement + " in " + + type.toJavaName() + " object of size " + size); + } + } else { + ResolvedJavaField field = type.findInstanceFieldWithOffset(displacement, JavaKind.Object); + if (field == null && object instanceof Class) { + // Read of a static field + MetaAccessProvider metaAccess = runtime.getHostJVMCIBackend().getMetaAccess(); + HotSpotResolvedObjectTypeImpl staticFieldsHolder = (HotSpotResolvedObjectTypeImpl) metaAccess.lookupJavaType((Class) object); + field = staticFieldsHolder.findStaticFieldWithOffset(displacement, JavaKind.Object); + } + if (field == null) { + throw new IllegalArgumentException("Unsafe object access: field not found for read of kind Object" + + " at offset " + displacement + " in " + type.toJavaName() + " object"); + } + if (field.getJavaKind() != JavaKind.Object) { + throw new IllegalArgumentException("Unsafe object access: field " + field.format("%H.%n:%T") + " not of expected kind Object" + + " at offset " + displacement + " in " + type.toJavaName() + " object"); + } + } + return true; } private boolean isValidObjectFieldDisplacement(Constant base, long displacement) { @@ -77,8 +166,8 @@ class HotSpotMemoryAccessProviderImpl implements HotSpotMemoryAccessProvider { throw new IllegalArgumentException(String.valueOf(base)); } - private static long readRawValue(Constant baseConstant, long displacement, int bits) { - Object base = asObject(baseConstant); + private long readRawValue(Constant baseConstant, long displacement, JavaKind kind, int bits) { + Object base = asObject(baseConstant, kind, displacement); if (base != null) { switch (bits) { case Byte.SIZE: @@ -123,9 +212,8 @@ class HotSpotMemoryAccessProviderImpl implements HotSpotMemoryAccessProvider { private Object readRawObject(Constant baseConstant, long initialDisplacement, boolean compressed) { long displacement = initialDisplacement; - Object ret; - Object base = asObject(baseConstant); + Object base = asObject(baseConstant, JavaKind.Object, displacement); if (base == null) { assert !compressed; displacement += asRawPointer(baseConstant); @@ -138,34 +226,43 @@ class HotSpotMemoryAccessProviderImpl implements HotSpotMemoryAccessProvider { return ret; } - /** - * Reads a value of this kind using a base address and a displacement. No bounds checking or - * type checking is performed. Returns {@code null} if the value is not available at this point. - * - * @param baseConstant the base address from which the value is read. - * @param displacement the displacement within the object in bytes - * @return the read value encapsulated in a {@link JavaConstant} object, or {@code null} if the - * value cannot be read. - * @throws IllegalArgumentException if {@code kind} is {@code null}, {@link JavaKind#Void}, not - * {@link JavaKind#Object} or not {@linkplain JavaKind#isPrimitive() primitive} kind - */ - JavaConstant readUnsafeConstant(JavaKind kind, JavaConstant baseConstant, long displacement) { - if (kind == null) { - throw new IllegalArgumentException("null JavaKind"); - } - if (kind == JavaKind.Object) { - Object o = readRawObject(baseConstant, displacement, runtime.getConfig().useCompressedOops); + JavaConstant readFieldValue(HotSpotResolvedJavaField field, Object obj) { + assert obj != null; + assert !field.isStatic() || obj instanceof Class; + long displacement = field.offset(); + assert checkRead(field.getJavaKind(), displacement, (HotSpotResolvedObjectType) runtime.getHostJVMCIBackend().getMetaAccess().lookupJavaType(obj.getClass()), obj); + if (field.getJavaKind() == JavaKind.Object) { + Object o = UNSAFE.getObject(obj, displacement); return HotSpotObjectConstantImpl.forObject(o); } else { - int bits = kind.getByteCount() * Byte.SIZE; - return readPrimitiveConstant(kind, baseConstant, displacement, bits); + JavaKind kind = field.getJavaKind(); + switch (kind) { + case Boolean: + return JavaConstant.forBoolean(UNSAFE.getBoolean(obj, displacement)); + case Byte: + return JavaConstant.forByte(UNSAFE.getByte(obj, displacement)); + case Char: + return JavaConstant.forChar(UNSAFE.getChar(obj, displacement)); + case Short: + return JavaConstant.forShort(UNSAFE.getShort(obj, displacement)); + case Int: + return JavaConstant.forInt(UNSAFE.getInt(obj, displacement)); + case Long: + return JavaConstant.forLong(UNSAFE.getLong(obj, displacement)); + case Float: + return JavaConstant.forFloat(UNSAFE.getFloat(obj, displacement)); + case Double: + return JavaConstant.forDouble(UNSAFE.getDouble(obj, displacement)); + default: + throw new IllegalArgumentException("Unsupported kind: " + kind); + } } } @Override public JavaConstant readPrimitiveConstant(JavaKind kind, Constant baseConstant, long initialDisplacement, int bits) { try { - long rawValue = readRawValue(baseConstant, initialDisplacement, bits); + long rawValue = readRawValue(baseConstant, initialDisplacement, kind, bits); switch (kind) { case Boolean: return JavaConstant.forBoolean(rawValue != 0); @@ -193,6 +290,10 @@ class HotSpotMemoryAccessProviderImpl implements HotSpotMemoryAccessProvider { @Override public JavaConstant readObjectConstant(Constant base, long displacement) { + if (base instanceof HotSpotObjectConstantImpl) { + Object o = readRawObject(base, displacement, runtime.getConfig().useCompressedOops); + return HotSpotObjectConstantImpl.forObject(o); + } if (!isValidObjectFieldDisplacement(base, displacement)) { return null; } diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaAccessProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaAccessProvider.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaAccessProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaAccessProvider.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaData.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaData.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaData.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaData.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaspaceConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaspaceConstant.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaspaceConstant.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaspaceConstant.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaspaceConstantImpl.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaspaceConstantImpl.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaspaceConstantImpl.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMetaspaceConstantImpl.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethod.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethod.java similarity index 94% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethod.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethod.java index da04107bc1a..aca3b3ddb4d 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethod.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethod.java @@ -59,23 +59,12 @@ abstract class HotSpotMethod implements JavaMethod, Formattable { return res; } - protected String name; - /** * Controls whether {@link #toString()} includes the qualified or simple name of the class in * which the method is declared. */ public static final boolean FULLY_QUALIFIED_METHOD_NAME = false; - protected HotSpotMethod(String name) { - this.name = name; - } - - @Override - public final String getName() { - return name; - } - @Override public final String toString() { char h = FULLY_QUALIFIED_METHOD_NAME ? 'H' : 'h'; diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodData.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodData.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodData.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodData.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodDataAccessor.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodDataAccessor.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodDataAccessor.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodDataAccessor.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodHandleAccessProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodHandleAccessProvider.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodHandleAccessProvider.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodHandleAccessProvider.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodUnresolved.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodUnresolved.java similarity index 94% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodUnresolved.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodUnresolved.java index e68c7fef8c1..7eb437929c3 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodUnresolved.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMethodUnresolved.java @@ -31,15 +31,21 @@ import jdk.vm.ci.meta.Signature; */ final class HotSpotMethodUnresolved extends HotSpotMethod { + private final String name; private final Signature signature; protected JavaType holder; HotSpotMethodUnresolved(String name, Signature signature, JavaType holder) { - super(name); + this.name = name; this.holder = holder; this.signature = signature; } + @Override + public String getName() { + return name; + } + @Override public Signature getSignature() { return signature; diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotModifiers.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotModifiers.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotModifiers.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotModifiers.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotNmethod.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotNmethod.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotNmethod.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotNmethod.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotObjectConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotObjectConstant.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotObjectConstant.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotObjectConstant.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotObjectConstantImpl.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotObjectConstantImpl.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotObjectConstantImpl.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotObjectConstantImpl.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotProfilingInfo.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotProfilingInfo.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotProfilingInfo.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotProfilingInfo.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotReferenceMap.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotReferenceMap.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotReferenceMap.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotReferenceMap.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaField.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaField.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaField.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaField.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaFieldImpl.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaFieldImpl.java similarity index 91% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaFieldImpl.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaFieldImpl.java index 24287261984..737135a8e52 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaFieldImpl.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaFieldImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -38,19 +38,20 @@ import jdk.vm.ci.meta.ResolvedJavaType; class HotSpotResolvedJavaFieldImpl implements HotSpotResolvedJavaField { private final HotSpotResolvedObjectTypeImpl holder; - private final String name; private JavaType type; private final int offset; + private final short index; /** * This value contains all flags as stored in the VM including internal ones. */ private final int modifiers; - HotSpotResolvedJavaFieldImpl(HotSpotResolvedObjectTypeImpl holder, String name, JavaType type, long offset, int modifiers) { + HotSpotResolvedJavaFieldImpl(HotSpotResolvedObjectTypeImpl holder, JavaType type, long offset, int modifiers, int index) { this.holder = holder; - this.name = name; this.type = type; + this.index = (short) index; + assert this.index == index; assert offset != -1; assert offset == (int) offset : "offset larger than int"; this.offset = (int) offset; @@ -67,7 +68,6 @@ class HotSpotResolvedJavaFieldImpl implements HotSpotResolvedJavaField { if (that.offset != this.offset || that.isStatic() != this.isStatic()) { return false; } else if (this.holder.equals(that.holder)) { - assert this.name.equals(that.name) && this.type.equals(that.type); return true; } } @@ -76,7 +76,7 @@ class HotSpotResolvedJavaFieldImpl implements HotSpotResolvedJavaField { @Override public int hashCode() { - return name.hashCode(); + return offset ^ modifiers; } @Override @@ -109,7 +109,7 @@ class HotSpotResolvedJavaFieldImpl implements HotSpotResolvedJavaField { @Override public String getName() { - return name; + return holder.createFieldInfo(index).getName(); } @Override @@ -178,18 +178,12 @@ class HotSpotResolvedJavaFieldImpl implements HotSpotResolvedJavaField { return null; } - private Field toJavaCache; - private Field toJava() { - if (toJavaCache != null) { - return toJavaCache; - } - if (isInternal()) { return null; } try { - return toJavaCache = holder.mirror().getDeclaredField(name); + return holder.mirror().getDeclaredField(getName()); } catch (NoSuchFieldException | NoClassDefFoundError e) { return null; } diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethod.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethod.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethod.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethod.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethodImpl.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethodImpl.java similarity index 95% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethodImpl.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethodImpl.java index 393b740a71e..f831db4c5f9 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethodImpl.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaMethodImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -75,6 +75,12 @@ final class HotSpotResolvedJavaMethodImpl extends HotSpotMethod implements HotSp private byte[] code; private Executable toJavaCache; + /** + * Only 30% of {@link HotSpotResolvedJavaMethodImpl}s have their name accessed so compute it + * lazily and cache it. + */ + private String nameCache; + /** * Gets the holder of a HotSpot metaspace method native object. * @@ -106,8 +112,6 @@ final class HotSpotResolvedJavaMethodImpl extends HotSpotMethod implements HotSp } HotSpotResolvedJavaMethodImpl(HotSpotResolvedObjectTypeImpl holder, long metaspaceMethod) { - // It would be too much work to get the method name here so we fill it in later. - super(null); this.metaspaceMethod = metaspaceMethod; this.holder = holder; @@ -126,9 +130,6 @@ final class HotSpotResolvedJavaMethodImpl extends HotSpotMethod implements HotSp this.constantPool = compilerToVM().getConstantPool(this); } - final int nameIndex = UNSAFE.getChar(constMethod + config.constMethodNameIndexOffset); - this.name = constantPool.lookupUtf8(nameIndex); - final int signatureIndex = UNSAFE.getChar(constMethod + config.constMethodSignatureIndexOffset); this.signature = (HotSpotSignature) constantPool.lookupSignature(signatureIndex); } @@ -146,6 +147,15 @@ final class HotSpotResolvedJavaMethodImpl extends HotSpotMethod implements HotSp return UNSAFE.getAddress(metaspaceMethod + config().methodConstMethodOffset); } + @Override + public String getName() { + if (nameCache == null) { + final int nameIndex = UNSAFE.getChar(getConstMethod() + config().constMethodNameIndexOffset); + nameCache = constantPool.lookupUtf8(nameIndex); + } + return nameCache; + } + @Override public boolean equals(Object obj) { if (this == obj) { @@ -326,12 +336,24 @@ final class HotSpotResolvedJavaMethodImpl extends HotSpotMethod implements HotSp @Override public boolean isClassInitializer() { - return "".equals(name) && isStatic(); + if (isStatic()) { + final int nameIndex = UNSAFE.getChar(getConstMethod() + config().constMethodNameIndexOffset); + long nameSymbol = constantPool.getEntryAt(nameIndex); + long clinitSymbol = config().symbolClinit; + return nameSymbol == clinitSymbol; + } + return false; } @Override public boolean isConstructor() { - return "".equals(name) && !isStatic(); + if (!isStatic()) { + final int nameIndex = UNSAFE.getChar(getConstMethod() + config().constMethodNameIndexOffset); + long nameSymbol = constantPool.getEntryAt(nameIndex); + long initSymbol = config().symbolInit; + return nameSymbol == initSymbol; + } + return false; } @Override @@ -472,7 +494,7 @@ final class HotSpotResolvedJavaMethodImpl extends HotSpotMethod implements HotSp @Override public Annotation[][] getParameterAnnotations() { Executable javaMethod = toJava(); - return javaMethod == null ? null : javaMethod.getParameterAnnotations(); + return javaMethod == null ? new Annotation[signature.getParameterCount(false)][0] : javaMethod.getParameterAnnotations(); } @Override @@ -513,9 +535,6 @@ final class HotSpotResolvedJavaMethodImpl extends HotSpotMethod implements HotSp } public boolean isDefault() { - if (isConstructor()) { - return false; - } // Copied from java.lang.Method.isDefault() int mask = Modifier.ABSTRACT | Modifier.PUBLIC | Modifier.STATIC; return ((getModifiers() & mask) == Modifier.PUBLIC) && getDeclaringClass().isInterface(); @@ -562,7 +581,7 @@ final class HotSpotResolvedJavaMethodImpl extends HotSpotMethod implements HotSp } else { // Do not use Method.getDeclaredMethod() as it can return a bridge method // when this.isBridge() is false and vice versa. - result = searchMethods(holder.mirror().getDeclaredMethods(), name, returnType, parameterTypes); + result = searchMethods(holder.mirror().getDeclaredMethods(), getName(), returnType, parameterTypes); } toJavaCache = result; return result; diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaType.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaType.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaType.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedJavaType.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectType.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectType.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectType.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectType.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectTypeImpl.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectTypeImpl.java similarity index 84% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectTypeImpl.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectTypeImpl.java index a0a3bc7a7a5..a6d3428cccf 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectTypeImpl.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedObjectTypeImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,8 +36,6 @@ import java.lang.reflect.Constructor; import java.lang.reflect.Method; import java.lang.reflect.Modifier; import java.nio.ByteOrder; -import java.util.ArrayList; -import java.util.Arrays; import java.util.HashMap; import jdk.vm.ci.common.JVMCIError; @@ -59,12 +57,15 @@ import jdk.vm.ci.meta.ResolvedJavaType; */ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implements HotSpotResolvedObjectType, MetaspaceWrapperObject { + private static final HotSpotResolvedJavaField[] NO_FIELDS = new HotSpotResolvedJavaField[0]; + private static final int METHOD_CACHE_ARRAY_CAPACITY = 8; + /** * The Java class this type represents. */ private final Class javaClass; - private HashMap fieldCache; - private HashMap methodCache; + private HotSpotResolvedJavaMethodImpl[] methodCacheArray; + private HashMap methodCacheHashMap; private HotSpotResolvedJavaField[] instanceFields; private HotSpotResolvedObjectTypeImpl[] interfaces; private HotSpotConstantPool constantPool; @@ -255,7 +256,7 @@ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implem * @return true if the type is a leaf class */ private boolean isLeafClass() { - return getSubklass() == null; + return UNSAFE.getLong(this.getMetaspaceKlass() + config().subklassOffset) == 0; } /** @@ -484,18 +485,38 @@ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implem } synchronized HotSpotResolvedJavaMethod createMethod(long metaspaceMethod) { - HotSpotResolvedJavaMethodImpl method = null; - if (methodCache == null) { - methodCache = new HashMap<>(8); + // Maintain cache as array. + if (methodCacheArray == null) { + methodCacheArray = new HotSpotResolvedJavaMethodImpl[METHOD_CACHE_ARRAY_CAPACITY]; + } + + int i = 0; + for (; i < methodCacheArray.length; ++i) { + HotSpotResolvedJavaMethodImpl curMethod = methodCacheArray[i]; + if (curMethod == null) { + HotSpotResolvedJavaMethodImpl newMethod = new HotSpotResolvedJavaMethodImpl(this, metaspaceMethod); + methodCacheArray[i] = newMethod; + context.add(newMethod); + return newMethod; + } else if (curMethod.getMetaspacePointer() == metaspaceMethod) { + return curMethod; + } + } + + // Fall-back to hash table. + if (methodCacheHashMap == null) { + methodCacheHashMap = new HashMap<>(); + } + + HotSpotResolvedJavaMethodImpl lookupResult = methodCacheHashMap.get(metaspaceMethod); + if (lookupResult == null) { + HotSpotResolvedJavaMethodImpl newMethod = new HotSpotResolvedJavaMethodImpl(this, metaspaceMethod); + methodCacheHashMap.put(metaspaceMethod, newMethod); + context.add(lookupResult); + return newMethod; } else { - method = methodCache.get(metaspaceMethod); + return lookupResult; } - if (method == null) { - method = new HotSpotResolvedJavaMethodImpl(this, metaspaceMethod); - methodCache.put(metaspaceMethod, method); - context.add(method); - } - return method; } public int getVtableLength() { @@ -509,37 +530,8 @@ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implem return result; } - synchronized HotSpotResolvedJavaField createField(String fieldName, JavaType type, long offset, int rawFlags) { - HotSpotResolvedJavaField result = null; - - final int flags = rawFlags & HotSpotModifiers.jvmFieldModifiers(); - - final long id = offset + ((long) flags << 32); - - // Must cache the fields, because the local load elimination only works if the - // objects from two field lookups are identical. - if (fieldCache == null) { - fieldCache = new HashMap<>(8); - } else { - result = fieldCache.get(id); - } - - if (result == null) { - result = new HotSpotResolvedJavaFieldImpl(this, fieldName, type, offset, rawFlags); - fieldCache.put(id, result); - } else { - assert result.getName().equals(fieldName); - /* - * Comparing the types directly is too strict, because the type in the cache could be - * resolved while the incoming type is unresolved. The name comparison is sufficient - * because the type will always be resolved in the context of the holder. - */ - assert result.getType().getName().equals(type.getName()); - assert result.offset() == offset; - assert result.getModifiers() == flags; - } - - return result; + synchronized HotSpotResolvedJavaField createField(JavaType type, long offset, int rawFlags, int index) { + return new HotSpotResolvedJavaFieldImpl(this, type, offset, rawFlags, index); } @Override @@ -577,11 +569,15 @@ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implem return null; } + FieldInfo createFieldInfo(int index) { + return new FieldInfo(index); + } + /** * This class represents the field information for one field contained in the fields array of an * {@code InstanceKlass}. The implementation is similar to the native {@code FieldInfo} class. */ - private class FieldInfo { + class FieldInfo { /** * Native pointer into the array of Java shorts. */ @@ -666,61 +662,31 @@ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implem } } - @SuppressFBWarnings(value = "SE_COMPARATOR_SHOULD_BE_SERIALIZABLE", justification = "comparator is only used transiently") - private static class OffsetComparator implements java.util.Comparator { - @Override - public int compare(HotSpotResolvedJavaField o1, HotSpotResolvedJavaField o2) { - return o1.offset() - o2.offset(); - } - } - @Override public ResolvedJavaField[] getInstanceFields(boolean includeSuperclasses) { if (instanceFields == null) { if (isArray() || isInterface()) { - instanceFields = new HotSpotResolvedJavaField[0]; + instanceFields = NO_FIELDS; } else { - final int fieldCount = getFieldCount(); - ArrayList fieldsArray = new ArrayList<>(fieldCount); - - for (int i = 0; i < fieldCount; i++) { - FieldInfo field = new FieldInfo(i); - - // We are only interested in instance fields. - if (!field.isStatic()) { - HotSpotResolvedJavaField resolvedJavaField = createField(field.getName(), field.getType(), field.getOffset(), field.getAccessFlags()); - fieldsArray.add(resolvedJavaField); - } + HotSpotResolvedJavaField[] prepend = NO_FIELDS; + if (getSuperclass() != null) { + prepend = (HotSpotResolvedJavaField[]) getSuperclass().getInstanceFields(true); } - - fieldsArray.sort(new OffsetComparator()); - - HotSpotResolvedJavaField[] myFields = fieldsArray.toArray(new HotSpotResolvedJavaField[0]); - - if (mirror() != Object.class) { - HotSpotResolvedJavaField[] superFields = (HotSpotResolvedJavaField[]) getSuperclass().getInstanceFields(true); - HotSpotResolvedJavaField[] fields = Arrays.copyOf(superFields, superFields.length + myFields.length); - System.arraycopy(myFields, 0, fields, superFields.length, myFields.length); - instanceFields = fields; - } else { - assert myFields.length == 0 : "java.lang.Object has fields!"; - instanceFields = myFields; - } - + instanceFields = getFields(false, prepend); } } - if (!includeSuperclasses) { - int myFieldsStart = 0; - while (myFieldsStart < instanceFields.length && !instanceFields[myFieldsStart].getDeclaringClass().equals(this)) { - myFieldsStart++; + if (!includeSuperclasses && getSuperclass() != null) { + int superClassFieldCount = getSuperclass().getInstanceFields(true).length; + if (superClassFieldCount == instanceFields.length) { + // This class does not have any instance fields of its own. + return NO_FIELDS; + } else if (superClassFieldCount != 0) { + HotSpotResolvedJavaField[] result = new HotSpotResolvedJavaField[instanceFields.length - superClassFieldCount]; + System.arraycopy(instanceFields, superClassFieldCount, result, 0, result.length); + return result; + } else { + // The super classes of this class do not have any instance fields. } - if (myFieldsStart == 0) { - return instanceFields; - } - if (myFieldsStart == instanceFields.length) { - return new HotSpotResolvedJavaField[0]; - } - return Arrays.copyOfRange(instanceFields, myFieldsStart, instanceFields.length); } return instanceFields; } @@ -730,45 +696,63 @@ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implem if (isArray()) { return new HotSpotResolvedJavaField[0]; } else { - final int fieldCount = getFieldCount(); - ArrayList fieldsArray = new ArrayList<>(fieldCount); - - for (int i = 0; i < fieldCount; i++) { - FieldInfo field = new FieldInfo(i); - - // We are only interested in static fields. - if (field.isStatic()) { - HotSpotResolvedJavaField resolvedJavaField = createField(field.getName(), field.getType(), field.getOffset(), field.getAccessFlags()); - fieldsArray.add(resolvedJavaField); - } - } - - fieldsArray.sort(new OffsetComparator()); - return fieldsArray.toArray(new HotSpotResolvedJavaField[fieldsArray.size()]); + return getFields(true, NO_FIELDS); } } /** - * Returns the actual field count of this class's internal {@code InstanceKlass::_fields} array - * by walking the array and discounting the generic signature slots at the end of the array. + * Gets the instance or static fields of this class. * - *

- * See {@code FieldStreamBase::init_generic_signature_start_slot} + * @param retrieveStaticFields specifies whether to return instance or static fields + * @param prepend an array to be prepended to the returned result */ - private int getFieldCount() { + private HotSpotResolvedJavaField[] getFields(boolean retrieveStaticFields, HotSpotResolvedJavaField[] prepend) { HotSpotVMConfig config = config(); final long metaspaceFields = UNSAFE.getAddress(getMetaspaceKlass() + config.instanceKlassFieldsOffset); int metaspaceFieldsLength = UNSAFE.getInt(metaspaceFields + config.arrayU1LengthOffset); - int fieldCount = 0; - - for (int i = 0, index = 0; i < metaspaceFieldsLength; i += config.fieldInfoFieldSlots, index++) { + int resultCount = 0; + int index = 0; + for (int i = 0; i < metaspaceFieldsLength; i += config.fieldInfoFieldSlots, index++) { FieldInfo field = new FieldInfo(index); if (field.hasGenericSignature()) { metaspaceFieldsLength--; } - fieldCount++; + + if (field.isStatic() == retrieveStaticFields) { + resultCount++; + } } - return fieldCount; + + if (resultCount == 0) { + return prepend; + } + + int prependLength = prepend.length; + resultCount += prependLength; + + HotSpotResolvedJavaField[] result = new HotSpotResolvedJavaField[resultCount]; + if (prependLength != 0) { + System.arraycopy(prepend, 0, result, 0, prependLength); + } + + int resultIndex = prependLength; + for (int i = 0; i < index; ++i) { + FieldInfo field = new FieldInfo(i); + if (field.isStatic() == retrieveStaticFields) { + int offset = field.getOffset(); + HotSpotResolvedJavaField resolvedJavaField = createField(field.getType(), offset, field.getAccessFlags(), i); + + // Make sure the result is sorted by offset. + int j; + for (j = resultIndex - 1; j >= prependLength && result[j].offset() > offset; j--) { + result[j + 1] = result[j]; + } + result[j + 1] = resolvedJavaField; + resultIndex++; + } + } + + return result; } @Override @@ -817,8 +801,7 @@ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implem } if (elementType.getName().startsWith("Ljava/")) { // Classes in a java.* package can only be defined by the - // boot class loader. This is enforced by ClassLoader.preDefineClass() - assert mirror().getClassLoader() == null; + // boot or platform class loader. return true; } ClassLoader thisCl = mirror().getClassLoader(); @@ -863,6 +846,15 @@ final class HotSpotResolvedObjectTypeImpl extends HotSpotResolvedJavaType implem @Override public ResolvedJavaField findInstanceFieldWithOffset(long offset, JavaKind expectedEntryKind) { ResolvedJavaField[] declaredFields = getInstanceFields(true); + return findFieldWithOffset(offset, expectedEntryKind, declaredFields); + } + + public ResolvedJavaField findStaticFieldWithOffset(long offset, JavaKind expectedEntryKind) { + ResolvedJavaField[] declaredFields = getStaticFields(); + return findFieldWithOffset(offset, expectedEntryKind, declaredFields); + } + + private static ResolvedJavaField findFieldWithOffset(long offset, JavaKind expectedEntryKind, ResolvedJavaField[] declaredFields) { for (ResolvedJavaField field : declaredFields) { HotSpotResolvedJavaField resolvedField = (HotSpotResolvedJavaField) field; long resolvedFieldOffset = resolvedField.offset(); diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedPrimitiveType.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedPrimitiveType.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedPrimitiveType.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotResolvedPrimitiveType.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotRuntimeStub.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotRuntimeStub.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotRuntimeStub.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotRuntimeStub.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSentinelConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSentinelConstant.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSentinelConstant.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSentinelConstant.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSignature.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSignature.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSignature.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSignature.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSpeculationLog.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSpeculationLog.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSpeculationLog.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotSpeculationLog.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotStackFrameReference.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotStackFrameReference.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotStackFrameReference.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotStackFrameReference.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotStackIntrospection.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotStackIntrospection.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotStackIntrospection.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotStackIntrospection.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotUnresolvedField.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotUnresolvedField.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotUnresolvedField.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotUnresolvedField.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotUnresolvedJavaType.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotUnresolvedJavaType.java similarity index 100% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotUnresolvedJavaType.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotUnresolvedJavaType.java diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfig.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfig.java similarity index 96% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfig.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfig.java index c598f8a6f3f..25f6153f54e 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfig.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfig.java @@ -85,7 +85,7 @@ class HotSpotVMConfig extends HotSpotVMConfigAccess { final int klassLayoutHelperNeutralValue = getConstant("Klass::_lh_neutral_value", Integer.class); final int klassLayoutHelperInstanceSlowPathBit = getConstant("Klass::_lh_instance_slow_path_bit", Integer.class); - final int vtableEntrySize = getTypeSize("vtableEntry"); + final int vtableEntrySize = getFieldValue("CompilerToVM::Data::sizeof_vtableEntry", Integer.class, "int"); final int vtableEntryMethodOffset = getFieldOffset("vtableEntry::_method", Integer.class, "Method*"); final int instanceKlassSourceFileNameIndexOffset = getFieldOffset("InstanceKlass::_source_file_name_index", Integer.class, "u2"); @@ -192,20 +192,20 @@ class HotSpotVMConfig extends HotSpotVMConfigAccess { final int constMethodHasLocalVariableTable = getConstant("ConstMethod::_has_localvariable_table", Integer.class); final int constMethodHasExceptionTable = getConstant("ConstMethod::_has_exception_table", Integer.class); - final int exceptionTableElementSize = getTypeSize("ExceptionTableElement"); + final int exceptionTableElementSize = getFieldValue("CompilerToVM::Data::sizeof_ExceptionTableElement", Integer.class, "int"); final int exceptionTableElementStartPcOffset = getFieldOffset("ExceptionTableElement::start_pc", Integer.class, "u2"); final int exceptionTableElementEndPcOffset = getFieldOffset("ExceptionTableElement::end_pc", Integer.class, "u2"); final int exceptionTableElementHandlerPcOffset = getFieldOffset("ExceptionTableElement::handler_pc", Integer.class, "u2"); final int exceptionTableElementCatchTypeIndexOffset = getFieldOffset("ExceptionTableElement::catch_type_index", Integer.class, "u2"); - final int localVariableTableElementSize = getTypeSize("LocalVariableTableElement"); + final int localVariableTableElementSize = getFieldValue("CompilerToVM::Data::sizeof_LocalVariableTableElement", Integer.class, "int"); final int localVariableTableElementStartBciOffset = getFieldOffset("LocalVariableTableElement::start_bci", Integer.class, "u2"); final int localVariableTableElementLengthOffset = getFieldOffset("LocalVariableTableElement::length", Integer.class, "u2"); final int localVariableTableElementNameCpIndexOffset = getFieldOffset("LocalVariableTableElement::name_cp_index", Integer.class, "u2"); final int localVariableTableElementDescriptorCpIndexOffset = getFieldOffset("LocalVariableTableElement::descriptor_cp_index", Integer.class, "u2"); final int localVariableTableElementSlotOffset = getFieldOffset("LocalVariableTableElement::slot", Integer.class, "u2"); - final int constantPoolSize = getTypeSize("ConstantPool"); + final int constantPoolSize = getFieldValue("CompilerToVM::Data::sizeof_ConstantPool", Integer.class, "int"); final int constantPoolTagsOffset = getFieldOffset("ConstantPool::_tags", Integer.class, "Array*"); final int constantPoolHolderOffset = getFieldOffset("ConstantPool::_pool_holder", Integer.class, "InstanceKlass*"); final int constantPoolLengthOffset = getFieldOffset("ConstantPool::_length", Integer.class, "int"); @@ -237,12 +237,15 @@ class HotSpotVMConfig extends HotSpotVMConfigAccess { final int heapWordSize = getConstant("HeapWordSize", Integer.class); - final int symbolPointerSize = getTypeSize("Symbol*"); + final int symbolPointerSize = getFieldValue("CompilerToVM::Data::sizeof_SymbolPointer", Integer.class, "int"); final long vmSymbolsSymbols = getFieldAddress("vmSymbols::_symbols[0]", "Symbol*"); final int vmSymbolsFirstSID = getConstant("vmSymbols::FIRST_SID", Integer.class); final int vmSymbolsSIDLimit = getConstant("vmSymbols::SID_LIMIT", Integer.class); + final long symbolInit = getFieldValue("CompilerToVM::Data::symbol_init", Long.class); + final long symbolClinit = getFieldValue("CompilerToVM::Data::symbol_clinit", Long.class); + /** * Returns the symbol in the {@code vmSymbols} table at position {@code index} as a * {@link String}. diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigAccess.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigAccess.java similarity index 94% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigAccess.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigAccess.java index 9bb538d587b..33a07bcb9a9 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigAccess.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigAccess.java @@ -66,21 +66,6 @@ public class HotSpotVMConfigAccess { return getAddress(name, null); } - /** - * Gets the size of a C++ type. - * - * @param name name of the type - * @return the size in bytes of the requested field - * @throws JVMCIError if the field is not present and {@code notPresent} is null - */ - public int getTypeSize(String name) { - Long entry = store.vmTypeSizes.get(name); - if (entry == null) { - throw new JVMCIError("expected VM type not found: " + name); - } - return (int) (long) entry; - } - /** * Gets the value of a C++ constant. * @@ -291,13 +276,24 @@ public class HotSpotVMConfigAccess { */ public T getFlag(String name, Class type, T notPresent) { VMFlag entry = store.vmFlags.get(name); + Object value; + String cppType; if (entry == null) { - if (notPresent != null) { - return notPresent; + // Fall back to VM call + value = store.compilerToVm.getFlagValue(name); + if (value == store.compilerToVm) { + if (notPresent != null) { + return notPresent; + } + throw new JVMCIError("expected VM flag not found: " + name); + } else { + cppType = null; } - throw new JVMCIError("expected VM flag not found: " + name); + } else { + value = entry.value; + cppType = entry.type; } - return type.cast(convertValue(name, type, entry.value, entry.type)); + return type.cast(convertValue(name, type, value, cppType)); } private static Object convertValue(String name, Class toType, Object value, String cppType) throws JVMCIError { @@ -319,6 +315,10 @@ public class HotSpotVMConfigAccess { } else if (value instanceof Long) { return (int) (long) value; } + } else if (toType == String.class) { + if (value == null || value instanceof String) { + return value; + } } else if (toType == Long.class) { return value; } diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigStore.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigStore.java similarity index 83% rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigStore.java rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigStore.java index e6f074d948f..c388bbfa7c4 100644 --- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigStore.java +++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMConfigStore.java @@ -46,15 +46,6 @@ public final class HotSpotVMConfigStore { return Collections.unmodifiableMap(vmAddresses); } - /** - * Gets the C++ type sizes exposed by this object. - * - * @return an unmodifiable map from C++ type names to their sizes in bytes - */ - public Map getTypeSizes() { - return Collections.unmodifiableMap(vmTypeSizes); - } - /** * Gets the C++ constants exposed by this object. * @@ -90,11 +81,11 @@ public final class HotSpotVMConfigStore { } final HashMap vmFields; - final HashMap vmTypeSizes; final HashMap vmConstants; final HashMap vmAddresses; final HashMap vmFlags; final List vmIntrinsics; + final CompilerToVM compilerToVm; /** * Reads the database of VM info. The return value encodes the info in a nested object array @@ -103,7 +94,6 @@ public final class HotSpotVMConfigStore { *

      *     info = [
      *         VMField[] vmFields,
-     *         [String name, Long size, ...] vmTypeSizes,
      *         [String name, Long value, ...] vmConstants,
      *         [String name, Long value, ...] vmAddresses,
      *         VMFlag[] vmFlags
@@ -113,25 +103,24 @@ public final class HotSpotVMConfigStore {
      */
     @SuppressWarnings("try")
     HotSpotVMConfigStore(CompilerToVM compilerToVm) {
+        this.compilerToVm = compilerToVm;
         Object[] data;
         try (InitTimer t = timer("CompilerToVm readConfiguration")) {
             data = compilerToVm.readConfiguration();
         }
-        assert data.length == 6 : data.length;
+        assert data.length == 5 : data.length;
 
         // @formatter:off
         VMField[] vmFieldsInfo    = (VMField[]) data[0];
-        Object[] vmTypesSizesInfo = (Object[])  data[1];
-        Object[] vmConstantsInfo  = (Object[])  data[2];
-        Object[] vmAddressesInfo  = (Object[])  data[3];
-        VMFlag[] vmFlagsInfo      = (VMFlag[])  data[4];
+        Object[] vmConstantsInfo  = (Object[])  data[1];
+        Object[] vmAddressesInfo  = (Object[])  data[2];
+        VMFlag[] vmFlagsInfo      = (VMFlag[])  data[3];
 
         vmFields     = new HashMap<>(vmFieldsInfo.length);
-        vmTypeSizes  = new HashMap<>(vmTypesSizesInfo.length);
         vmConstants  = new HashMap<>(vmConstantsInfo.length);
         vmAddresses  = new HashMap<>(vmAddressesInfo.length);
         vmFlags      = new HashMap<>(vmFlagsInfo.length);
-        vmIntrinsics = Arrays.asList((VMIntrinsicMethod[]) data[5]);
+        vmIntrinsics = Arrays.asList((VMIntrinsicMethod[]) data[4]);
         // @formatter:on
 
         try (InitTimer t = timer("HotSpotVMConfigStore fill maps")) {
@@ -139,12 +128,6 @@ public final class HotSpotVMConfigStore {
                 vmFields.put(vmField.name, vmField);
             }
 
-            for (int i = 0; i < vmTypesSizesInfo.length / 2; i++) {
-                String name = (String) vmTypesSizesInfo[i * 2];
-                Long size = (Long) vmTypesSizesInfo[i * 2 + 1];
-                vmTypeSizes.put(name, size);
-            }
-
             for (int i = 0; i < vmConstantsInfo.length / 2; i++) {
                 String name = (String) vmConstantsInfo[i * 2];
                 Long value = (Long) vmConstantsInfo[i * 2 + 1];
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMEventListener.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMEventListener.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMEventListener.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotVMEventListener.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/MetaspaceWrapperObject.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/MetaspaceWrapperObject.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/MetaspaceWrapperObject.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/MetaspaceWrapperObject.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/SuppressFBWarnings.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/SuppressFBWarnings.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/SuppressFBWarnings.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/SuppressFBWarnings.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/UnsafeAccess.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/UnsafeAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/UnsafeAccess.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/UnsafeAccess.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMField.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMField.java
similarity index 81%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMField.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMField.java
index 094d92cdd32..ce8b54139df 100644
--- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMField.java
+++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMField.java
@@ -38,22 +38,22 @@ public final class VMField {
     public final String type;
 
     /**
-     * If represented field is non-static, this is its offset within the containing structure.
+     * If the represented field is non-static, this is its offset within the containing structure.
      */
     public final long offset;
 
     /**
-     * If represented field is static, this is its address. Otherwise, this field is 0.
+     * If the represented field is static, this is its address. Otherwise, this is 0.
      */
     public final long address;
 
     /**
-     * Value of the field represented as a boxed long; only valid for non-oop static fields. This
-     * value is only captured once, during JVMCI initialization. If {@link #type} cannot be
-     * meaningfully (e.g., a struct) or safely (e.g., an oop) expressed as a boxed long, this is
-     * {@code null}.
+     * Value of the field represented as a boxed boolean if its C++ type is bool otherwise as a
+     * boxed long; only valid for non-oop static fields. This value is only captured once, during
+     * JVMCI initialization. If {@link #type} cannot be meaningfully (e.g., a struct) or safely
+     * (e.g., an oop) expressed as a boxed object, this is {@code null}.
      */
-    public final Long value;
+    public final Object value;
 
     /**
      * Determines if the represented field is static.
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMFlag.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMFlag.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMFlag.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMFlag.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMIntrinsicMethod.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMIntrinsicMethod.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMIntrinsicMethod.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/VMIntrinsicMethod.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/overview.html b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/overview.html
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/overview.html
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/overview.html
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AbstractJavaProfile.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AbstractJavaProfile.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AbstractJavaProfile.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AbstractJavaProfile.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AbstractProfiledItem.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AbstractProfiledItem.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AbstractProfiledItem.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AbstractProfiledItem.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AllocatableValue.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AllocatableValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AllocatableValue.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/AllocatableValue.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Assumptions.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Assumptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Assumptions.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Assumptions.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Constant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Constant.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Constant.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Constant.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ConstantPool.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ConstantPool.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ConstantPool.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ConstantPool.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ConstantReflectionProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ConstantReflectionProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ConstantReflectionProvider.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ConstantReflectionProvider.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DefaultProfilingInfo.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DefaultProfilingInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DefaultProfilingInfo.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DefaultProfilingInfo.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DeoptimizationAction.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DeoptimizationAction.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DeoptimizationAction.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DeoptimizationAction.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DeoptimizationReason.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DeoptimizationReason.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DeoptimizationReason.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/DeoptimizationReason.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ExceptionHandler.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ExceptionHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ExceptionHandler.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ExceptionHandler.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/InvokeTarget.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/InvokeTarget.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/InvokeTarget.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/InvokeTarget.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaConstant.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaConstant.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaField.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaField.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaField.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaField.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaKind.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaKind.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaKind.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaKind.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaMethod.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaMethod.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaMethod.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaMethod.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaMethodProfile.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaMethodProfile.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaMethodProfile.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaMethodProfile.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaType.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaType.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaType.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaType.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaTypeProfile.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaTypeProfile.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaTypeProfile.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaTypeProfile.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaValue.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaValue.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/JavaValue.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/LineNumberTable.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/LineNumberTable.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/LineNumberTable.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/LineNumberTable.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Local.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Local.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Local.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Local.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/LocalVariableTable.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/LocalVariableTable.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/LocalVariableTable.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/LocalVariableTable.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MemoryAccessProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MemoryAccessProvider.java
similarity index 82%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MemoryAccessProvider.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MemoryAccessProvider.java
index 81c5f395549..9eba9d0f8ac 100644
--- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MemoryAccessProvider.java
+++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MemoryAccessProvider.java
@@ -35,9 +35,9 @@ public interface MemoryAccessProvider {
      * @param displacement the displacement within the object in bytes
      * @param bits the number of bits to read from memory
      * @return the read value encapsulated in a {@link JavaConstant} object of {@link JavaKind} kind
-     * @throws IllegalArgumentException if {@code kind} is {@link JavaKind#Void} or not
-     *             {@linkplain JavaKind#isPrimitive() primitive} kind or {@code bits} is not 8, 16,
-     *             32 or 64
+     * @throws IllegalArgumentException if the read is out of bounds of the object or {@code kind}
+     *             is {@link JavaKind#Void} or not {@linkplain JavaKind#isPrimitive() primitive}
+     *             kind or {@code bits} is not 8, 16, 32 or 64
      */
     JavaConstant readPrimitiveConstant(JavaKind kind, Constant base, long displacement, int bits) throws IllegalArgumentException;
 
@@ -46,9 +46,9 @@ public interface MemoryAccessProvider {
      *
      * @param base the base address from which the value is read
      * @param displacement the displacement within the object in bytes
-     * @return the read value encapsulated in a {@link Constant} object or {@code null} if the
-     *         address computed from {@code base} and {@code displacement} does not denote a
-     *         location holding an {@code Object} value
+     * @return the read value encapsulated in a {@link Constant} object
+     * @throws IllegalArgumentException if the address computed from {@code base} and
+     *             {@code displacement} does not denote a location holding an {@code Object} value
      */
     JavaConstant readObjectConstant(Constant base, long displacement);
 }
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MetaAccessProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MetaAccessProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MetaAccessProvider.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MetaAccessProvider.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MetaUtil.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MetaUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MetaUtil.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MetaUtil.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MethodHandleAccessProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MethodHandleAccessProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MethodHandleAccessProvider.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/MethodHandleAccessProvider.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ModifiersProvider.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ModifiersProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ModifiersProvider.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ModifiersProvider.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/NullConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/NullConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/NullConstant.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/NullConstant.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/PlatformKind.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/PlatformKind.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/PlatformKind.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/PlatformKind.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/PrimitiveConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/PrimitiveConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/PrimitiveConstant.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/PrimitiveConstant.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ProfilingInfo.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ProfilingInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ProfilingInfo.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ProfilingInfo.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/RawConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/RawConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/RawConstant.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/RawConstant.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaField.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaField.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaField.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaField.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaMethod.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaMethod.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaMethod.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaMethod.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaType.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaType.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaType.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ResolvedJavaType.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SerializableConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SerializableConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SerializableConstant.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SerializableConstant.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Signature.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Signature.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Signature.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Signature.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SpeculationLog.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SpeculationLog.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SpeculationLog.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SpeculationLog.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SuppressFBWarnings.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SuppressFBWarnings.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SuppressFBWarnings.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/SuppressFBWarnings.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/TriState.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/TriState.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/TriState.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/TriState.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/VMConstant.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/VMConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/VMConstant.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/VMConstant.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Value.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Value.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Value.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/Value.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ValueKind.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ValueKind.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ValueKind.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/ValueKind.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/package-info.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/package-info.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.meta/src/jdk/vm/ci/meta/package-info.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCI.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCI.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCI.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCI.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCIBackend.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCIBackend.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCIBackend.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCIBackend.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCICompiler.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCICompiler.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCICompiler.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCICompiler.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCICompilerFactory.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCICompilerFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCICompilerFactory.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCICompilerFactory.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCIRuntime.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCIRuntime.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCIRuntime.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.runtime/src/jdk/vm/ci/runtime/JVMCIRuntime.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/.checkstyle_checks.xml b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/.checkstyle_checks.xml
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/.checkstyle_checks.xml
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/.checkstyle_checks.xml
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIPermission.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIPermission.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIPermission.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIPermission.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIServiceLocator.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIServiceLocator.java
similarity index 72%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIServiceLocator.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIServiceLocator.java
index 7d695ea27d7..530d6e0a033 100644
--- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIServiceLocator.java
+++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/JVMCIServiceLocator.java
@@ -24,12 +24,15 @@ package jdk.vm.ci.services;
 
 import java.util.ArrayList;
 import java.util.List;
+import java.util.ServiceLoader;
+
+import jdk.vm.ci.services.internal.ReflectionAccessJDK;
 
 /**
  * Service-provider class for the runtime to locate providers of JVMCI services where the latter are
- * not in packages exported by the JVMCI module. As part of instantiating
- * {@link JVMCIServiceLocator}, all JVMCI packages will be {@linkplain Services#exportJVMCITo(Class)
- * exported} to the module defining the class of the instantiated object.
+ * not in packages exported by the JVMCI module. As part of instantiating a
+ * {@link JVMCIServiceLocator}, all JVMCI packages will be opened to the module defining the class
+ * of the instantiated object.
  *
  * While the {@link #getProvider(Class)} method can be used directly, it's usually easier to use
  * {@link #getProviders(Class)}.
@@ -49,30 +52,39 @@ public abstract class JVMCIServiceLocator {
     }
 
     /**
-     * Creates a capability for accessing JVMCI. Once successfully instantiated, JVMCI exports all
-     * its packages to the module defining the type of this object.
+     * Creates a capability for accessing JVMCI. Once successfully instantiated, JVMCI opens all its
+     * packages to the module defining the type of this object.
      *
      * @throws SecurityException if a security manager has been installed and it denies
      *             {@link JVMCIPermission}
      */
     protected JVMCIServiceLocator() {
         this(checkPermission());
-        Services.exportJVMCITo(getClass());
+        Services.checkJVMCIEnabled();
+        ReflectionAccessJDK.openJVMCITo(getClass());
     }
 
     /**
      * Gets the provider of the service defined by {@code service} or {@code null} if this object
      * does not have a provider for {@code service}.
      */
-    public abstract  S getProvider(Class service);
+    protected abstract  S getProvider(Class service);
 
     /**
-     * Gets the providers of the service defined by {@code service} by querying the
-     * {@link JVMCIServiceLocator} providers obtained by {@link Services#load(Class)}.
+     * Gets the providers of the service defined by {@code service} by querying the available
+     * {@link JVMCIServiceLocator} providers.
+     *
+     * @throws SecurityException if a security manager is present and it denies
+     *             {@link JVMCIPermission}
      */
     public static  List getProviders(Class service) {
+        Services.checkJVMCIEnabled();
+        SecurityManager sm = System.getSecurityManager();
+        if (sm != null) {
+            sm.checkPermission(new JVMCIPermission());
+        }
         List providers = new ArrayList<>();
-        for (JVMCIServiceLocator access : Services.load(JVMCIServiceLocator.class)) {
+        for (JVMCIServiceLocator access : ServiceLoader.load(JVMCIServiceLocator.class, ClassLoader.getSystemClassLoader())) {
             S provider = access.getProvider(service);
             if (provider != null) {
                 providers.add(provider);
diff --git a/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java
new file mode 100644
index 00000000000..6d59fe6eef9
--- /dev/null
+++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java
@@ -0,0 +1,85 @@
+/*
+ * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+package jdk.vm.ci.services;
+
+import java.lang.reflect.Method;
+import java.util.Map;
+
+/**
+ * Provides utilities needed by JVMCI clients.
+ */
+public final class Services {
+
+    // This class must be compilable and executable on JDK 8 since it's used in annotation
+    // processors while building JDK 9 so use of API added in JDK 9 is made via reflection.
+
+    private Services() {
+    }
+
+    @SuppressWarnings("unchecked")
+    private static Map initSavedProperties() throws InternalError {
+        try {
+            Class vmClass = Class.forName("jdk.internal.misc.VM");
+            Method m = vmClass.getMethod("getSavedProperties");
+            return (Map) m.invoke(null);
+        } catch (Exception e) {
+            throw new InternalError(e);
+        }
+    }
+
+    static final Map SAVED_PROPERTIES = initSavedProperties();
+    static final boolean JVMCI_ENABLED = Boolean.parseBoolean(SAVED_PROPERTIES.get("jdk.internal.vm.ci.enabled"));
+
+    /**
+     * Checks that JVMCI is enabled in the VM and throws an error if it isn't.
+     */
+    static void checkJVMCIEnabled() {
+        if (!JVMCI_ENABLED) {
+            throw new Error("The EnableJVMCI VM option must be true (i.e., -XX:+EnableJVMCI) to use JVMCI");
+        }
+    }
+
+    /**
+     * Gets an unmodifiable copy of the system properties saved when {@link System} is initialized.
+     */
+    public static Map getSavedProperties() {
+        checkJVMCIEnabled();
+        SecurityManager sm = System.getSecurityManager();
+        if (sm != null) {
+            sm.checkPermission(new JVMCIPermission());
+        }
+        return SAVED_PROPERTIES;
+    }
+
+    /**
+     * Causes the JVMCI subsystem to be initialized if it isn't already initialized.
+     */
+    public static void initializeJVMCI() {
+        checkJVMCIEnabled();
+        try {
+            Class.forName("jdk.vm.ci.runtime.JVMCI");
+        } catch (ClassNotFoundException e) {
+            throw new InternalError(e);
+        }
+    }
+}
diff --git a/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/internal/ReflectionAccessJDK.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/internal/ReflectionAccessJDK.java
new file mode 100644
index 00000000000..6cbf12273ab
--- /dev/null
+++ b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/internal/ReflectionAccessJDK.java
@@ -0,0 +1,91 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+package jdk.vm.ci.services.internal;
+
+import java.lang.reflect.Method;
+import java.util.Set;
+
+import jdk.vm.ci.services.Services;
+
+/**
+ * Reflection based access to API introduced in JDK 9. This allows the API to be used in code that
+ * must be compiled (but not executed) on JDK 8.
+ */
+public final class ReflectionAccessJDK {
+
+    /**
+     * {@code Class.getModule()}.
+     */
+    private static final Method getModule;
+
+    /**
+     * {@code java.lang.Module.addOpens(String, Module)}.
+     */
+    private static final Method addOpens;
+
+    /**
+     * {@code java.lang.Module.getPackages(Module, String, Module)}.
+     */
+    private static final Method getPackages;
+
+    /**
+     * {@code java.lang.Module.isOpen(String, Module)}.
+     */
+    private static final Method isOpenTo;
+
+    /**
+     * Opens all JVMCI packages to the module of a given class.
+     *
+     * @param other all JVMCI packages will be opened to the module of this class
+     */
+    @SuppressWarnings("unchecked")
+    public static void openJVMCITo(Class other) {
+        try {
+            Object jvmci = getModule.invoke(Services.class);
+            Object otherModule = getModule.invoke(other);
+            if (jvmci != otherModule) {
+                Set packages = (Set) getPackages.invoke(jvmci);
+                for (String pkg : packages) {
+                    boolean opened = (Boolean) isOpenTo.invoke(jvmci, pkg, otherModule);
+                    if (!opened) {
+                        addOpens.invoke(jvmci, pkg, otherModule);
+                    }
+                }
+            }
+        } catch (Exception e) {
+            throw new InternalError(e);
+        }
+    }
+
+    static {
+        try {
+            getModule = Class.class.getMethod("getModule");
+            Class moduleClass = getModule.getReturnType();
+            getPackages = moduleClass.getMethod("getPackages");
+            isOpenTo = moduleClass.getMethod("isOpen", String.class, moduleClass);
+            addOpens = moduleClass.getDeclaredMethod("addOpens", String.class, moduleClass);
+        } catch (NoSuchMethodException | SecurityException e) {
+            throw new InternalError(e);
+        }
+    }
+}
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.sparc/src/jdk/vm/ci/sparc/SPARC.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.sparc/src/jdk/vm/ci/sparc/SPARC.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.sparc/src/jdk/vm/ci/sparc/SPARC.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.sparc/src/jdk/vm/ci/sparc/SPARC.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.sparc/src/jdk/vm/ci/sparc/SPARCKind.java b/hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.sparc/src/jdk/vm/ci/sparc/SPARCKind.java
similarity index 100%
rename from hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.sparc/src/jdk/vm/ci/sparc/SPARCKind.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.sparc/src/jdk/vm/ci/sparc/SPARCKind.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/module-info.java b/hotspot/src/jdk.internal.vm.ci/share/classes/module-info.java
similarity index 63%
rename from hotspot/src/jdk.vm.ci/share/classes/module-info.java
rename to hotspot/src/jdk.internal.vm.ci/share/classes/module-info.java
index 744442b1cdb..e6001b18f37 100644
--- a/hotspot/src/jdk.vm.ci/share/classes/module-info.java
+++ b/hotspot/src/jdk.internal.vm.ci/share/classes/module-info.java
@@ -23,8 +23,8 @@
  * questions.
  */
 
-module jdk.vm.ci {
-    exports jdk.vm.ci.services;
+module jdk.internal.vm.ci {
+    exports jdk.vm.ci.services to jdk.internal.vm.compiler;
 
     uses jdk.vm.ci.services.JVMCIServiceLocator;
     uses jdk.vm.ci.hotspot.HotSpotJVMCIBackendFactory;
@@ -33,37 +33,4 @@ module jdk.vm.ci {
         jdk.vm.ci.hotspot.aarch64.AArch64HotSpotJVMCIBackendFactory,
         jdk.vm.ci.hotspot.amd64.AMD64HotSpotJVMCIBackendFactory,
         jdk.vm.ci.hotspot.sparc.SPARCHotSpotJVMCIBackendFactory;
-
-    exports jdk.vm.ci.aarch64 to
-        jdk.vm.compiler;
-    exports jdk.vm.ci.amd64 to
-        jdk.aot,
-        jdk.vm.compiler;
-    exports jdk.vm.ci.code to
-        jdk.aot,
-        jdk.vm.compiler;
-    exports jdk.vm.ci.code.site to
-        jdk.aot,
-        jdk.vm.compiler;
-    exports jdk.vm.ci.code.stack to
-        jdk.vm.compiler;
-    exports jdk.vm.ci.common to
-        jdk.vm.compiler;
-    exports jdk.vm.ci.hotspot to
-        jdk.aot,
-        jdk.vm.compiler;
-    exports jdk.vm.ci.hotspot.aarch64 to
-        jdk.vm.compiler;
-    exports jdk.vm.ci.hotspot.amd64 to
-        jdk.vm.compiler;
-    exports jdk.vm.ci.hotspot.sparc to
-        jdk.vm.compiler;
-    exports jdk.vm.ci.meta to
-        jdk.aot,
-        jdk.vm.compiler;
-    exports jdk.vm.ci.runtime to
-        jdk.aot,
-        jdk.vm.compiler;
-    exports jdk.vm.ci.sparc to
-        jdk.vm.compiler;
 }
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/.project b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/.project
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/.project
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/.project
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/.pydevproject b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/.pydevproject
similarity index 84%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/.pydevproject
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/.pydevproject
index c2a81b0a6a5..10c514a61b2 100644
--- a/hotspot/src/jdk.vm.compiler/.mx.graal/.pydevproject
+++ b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/.pydevproject
@@ -3,9 +3,9 @@
 Default
 python 2.7
 
-/mx.graal
-/mx.graal
-/mx.graal
+/.mx.graal
+/.mx.graal
+/.mx.graal
 
 
 
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/eclipse-settings/org.eclipse.jdt.core.prefs b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/eclipse-settings/org.eclipse.jdt.core.prefs
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/eclipse-settings/org.eclipse.jdt.core.prefs
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/eclipse-settings/org.eclipse.jdt.core.prefs
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/mx_graal.py b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/mx_graal.py
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/mx_graal.py
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/mx_graal.py
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/mx_graal_9.py b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/mx_graal_9.py
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/mx_graal_9.py
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/mx_graal_9.py
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/mx_graal_bench.py b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/mx_graal_bench.py
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/mx_graal_bench.py
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/mx_graal_bench.py
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/outputparser.py b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/outputparser.py
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/outputparser.py
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/outputparser.py
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/sanitycheck.py b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/sanitycheck.py
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/sanitycheck.py
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/sanitycheck.py
diff --git a/hotspot/src/jdk.vm.compiler/.mx.graal/suite.py b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/suite.py
similarity index 95%
rename from hotspot/src/jdk.vm.compiler/.mx.graal/suite.py
rename to hotspot/src/jdk.internal.vm.compiler/.mx.graal/suite.py
index dda989acedf..b7f897c0862 100644
--- a/hotspot/src/jdk.vm.compiler/.mx.graal/suite.py
+++ b/hotspot/src/jdk.internal.vm.compiler/.mx.graal/suite.py
@@ -8,6 +8,36 @@ suite = {
   # (e.g., macosx-x86_64-normal-server-release).
   "outputRoot" : "../../../build/mx/hotspot",
 
+  "jdklibraries" : {
+    "JVMCI_SERVICES" : {
+      "path" : "lib/jvmci-services.jar",
+      "sourcePath" : "lib/jvmci-services.src.zip",
+      "optional" : False,
+      "jdkStandardizedSince" : "9",
+      "module" : "jdk.internal.vm.ci"
+    },
+    "JVMCI_API" : {
+      "path" : "lib/jvmci/jvmci-api.jar",
+      "sourcePath" : "lib/jvmci/jvmci-api.src.zip",
+      "dependencies" : [
+        "JVMCI_SERVICES",
+      ],
+      "optional" : False,
+      "jdkStandardizedSince" : "9",
+      "module" : "jdk.internal.vm.ci"
+    },
+    "JVMCI_HOTSPOT" : {
+      "path" : "lib/jvmci/jvmci-hotspot.jar",
+      "sourcePath" : "lib/jvmci/jvmci-hotspot.src.zip",
+      "dependencies" : [
+        "JVMCI_API",
+      ],
+      "optional" : False,
+      "jdkStandardizedSince" : "9",
+      "module" : "jdk.internal.vm.ci"
+    },
+  },
+
   "libraries" : {
 
     # ------------- Libraries -------------
@@ -17,6 +47,16 @@ suite = {
       "sha1" : "476d9a44cd19d6b55f81571077dfa972a4f8a083",
       "bootClassPathAgent" : "true",
     },
+    "ASM5" : {
+      "sha1" : "0da08b8cce7bbf903602a25a3a163ae252435795",
+      "urls" : ["https://lafo.ssw.uni-linz.ac.at/pub/graal-external-deps/asm-5.0.4.jar"],
+    },
+
+    "ASM_TREE5" : {
+      "sha1" : "396ce0c07ba2b481f25a70195c7c94922f0d1b0b",
+      "urls" : ["https://lafo.ssw.uni-linz.ac.at/pub/graal-external-deps/asm-tree-5.0.4.jar"],
+      "dependencies" : ["ASM5"],
+    },
   },
 
   "projects" : {
@@ -32,6 +72,7 @@ suite = {
 
     "org.graalvm.compiler.serviceprovider" : {
       "subDir" : "share/classes",
+      "dependencies" : ["JVMCI_SERVICES"],
       "sourceDirs" : ["src"],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
@@ -49,6 +90,7 @@ suite = {
 
     "org.graalvm.compiler.options" : {
       "subDir" : "share/classes",
+      "dependencies" : ["JVMCI_SERVICES", "JVMCI_API"],
       "sourceDirs" : ["src"],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
@@ -83,6 +125,7 @@ suite = {
       "sourceDirs" : ["src"],
       "checkstyle" : "org.graalvm.compiler.graph",
       "dependencies" : [
+        "JVMCI_API",
         "org.graalvm.compiler.serviceprovider",
         "org.graalvm.compiler.options"
       ],
@@ -137,6 +180,7 @@ suite = {
       "sourceDirs" : ["src"],
       "checkstyle" : "org.graalvm.compiler.graph",
       "dependencies" : [
+        "JVMCI_HOTSPOT",
         "org.graalvm.compiler.core.test",
       ],
       "javaCompliance" : "1.8",
@@ -146,6 +190,9 @@ suite = {
     "org.graalvm.compiler.api.runtime" : {
       "subDir" : "share/classes",
       "sourceDirs" : ["src"],
+      "dependencies" : [
+        "JVMCI_API",
+      ],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
       "workingSets" : "API,Graal",
@@ -156,6 +203,7 @@ suite = {
       "sourceDirs" : ["src"],
       "dependencies" : [
         "mx:JUNIT",
+        "JVMCI_SERVICES",
         "org.graalvm.compiler.api.runtime",
       ],
       "checkstyle" : "org.graalvm.compiler.graph",
@@ -166,6 +214,7 @@ suite = {
     "org.graalvm.compiler.api.replacements" : {
       "subDir" : "share/classes",
       "sourceDirs" : ["src"],
+      "dependencies" : ["JVMCI_API"],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
       "workingSets" : "API,Graal,Replacements",
@@ -175,6 +224,7 @@ suite = {
       "subDir" : "share/classes",
       "sourceDirs" : ["src"],
       "dependencies" : [
+        "JVMCI_HOTSPOT",
         "org.graalvm.compiler.api.runtime",
         "org.graalvm.compiler.replacements",
         "org.graalvm.compiler.runtime",
@@ -261,6 +311,8 @@ suite = {
         "org.graalvm.compiler.hotspot",
         "org.graalvm.compiler.lir.jtt",
         "org.graalvm.compiler.lir.test",
+        "JVMCI_API",
+        "JVMCI_HOTSPOT",
       ],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
@@ -347,6 +399,9 @@ suite = {
     "org.graalvm.compiler.asm" : {
       "subDir" : "share/classes",
       "sourceDirs" : ["src"],
+      "dependencies" : [
+        "JVMCI_API",
+      ],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
       "workingSets" : "Graal,Assembler",
@@ -403,6 +458,7 @@ suite = {
     "org.graalvm.compiler.bytecode" : {
       "subDir" : "share/classes",
       "sourceDirs" : ["src"],
+      "dependencies" : ["JVMCI_API"],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
       "workingSets" : "Graal,Java",
@@ -774,6 +830,7 @@ suite = {
       "dependencies" : [
         "org.graalvm.compiler.lir.jtt",
         "org.graalvm.compiler.lir.aarch64",
+        "JVMCI_HOTSPOT"
       ],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
@@ -803,6 +860,7 @@ suite = {
       "dependencies" : [
         "org.graalvm.compiler.lir.jtt",
         "org.graalvm.compiler.lir.amd64",
+        "JVMCI_HOTSPOT"
       ],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
@@ -831,6 +889,7 @@ suite = {
       "sourceDirs" : ["src"],
       "dependencies" : [
         "org.graalvm.compiler.lir.jtt",
+        "JVMCI_HOTSPOT"
       ],
       "checkstyle" : "org.graalvm.compiler.graph",
       "javaCompliance" : "1.8",
@@ -908,6 +967,7 @@ suite = {
         "org.graalvm.compiler.graph.test",
         "org.graalvm.compiler.printer",
         "JAVA_ALLOCATION_INSTRUMENTER",
+        "ASM_TREE5",
       ],
       "annotationProcessors" : ["GRAAL_NODEINFO_PROCESSOR"],
       "checkstyle" : "org.graalvm.compiler.graph",
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/module-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/module-info.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/module-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/module-info.java
index 7c456485659..783eef09fa5 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/module-info.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/module-info.java
@@ -23,11 +23,11 @@
  * questions.
  */
 
-module jdk.vm.compiler {
+module jdk.internal.vm.compiler {
     requires java.instrument;
     requires java.management;
     requires jdk.management;
-    requires jdk.vm.ci;
+    requires jdk.internal.vm.ci;
 
     // sun.misc.Unsafe is used
     requires jdk.unsupported;
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.collections/src/org/graalvm/compiler/api/collections/CollectionsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.collections/src/org/graalvm/compiler/api/collections/CollectionsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.collections/src/org/graalvm/compiler/api/collections/CollectionsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.collections/src/org/graalvm/compiler/api/collections/CollectionsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.collections/src/org/graalvm/compiler/api/collections/DefaultCollectionsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.collections/src/org/graalvm/compiler/api/collections/DefaultCollectionsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.collections/src/org/graalvm/compiler/api/collections/DefaultCollectionsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.collections/src/org/graalvm/compiler/api/collections/DefaultCollectionsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/AllocationInstrumentationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/AllocationInstrumentationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/AllocationInstrumentationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/AllocationInstrumentationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/BlackholeDirectiveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/BlackholeDirectiveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/BlackholeDirectiveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/BlackholeDirectiveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/ControlFlowAnchorDirectiveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/ControlFlowAnchorDirectiveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/ControlFlowAnchorDirectiveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/ControlFlowAnchorDirectiveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/DeoptimizeDirectiveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/DeoptimizeDirectiveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/DeoptimizeDirectiveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/DeoptimizeDirectiveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/IsMethodInlineDirectiveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/IsMethodInlineDirectiveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/IsMethodInlineDirectiveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/IsMethodInlineDirectiveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/IterationDirectiveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/IterationDirectiveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/IterationDirectiveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/IterationDirectiveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/LockInstrumentationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/LockInstrumentationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/LockInstrumentationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/LockInstrumentationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/OpaqueDirectiveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/OpaqueDirectiveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/OpaqueDirectiveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/OpaqueDirectiveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/ProbabilityDirectiveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/ProbabilityDirectiveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/ProbabilityDirectiveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/ProbabilityDirectiveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/RootNameDirectiveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/RootNameDirectiveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/RootNameDirectiveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/RootNameDirectiveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/TinyInstrumentor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/TinyInstrumentor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/TinyInstrumentor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives.test/src/org/graalvm/compiler/api/directives/test/TinyInstrumentor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives/src/org/graalvm/compiler/api/directives/GraalDirectives.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives/src/org/graalvm/compiler/api/directives/GraalDirectives.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.directives/src/org/graalvm/compiler/api/directives/GraalDirectives.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.directives/src/org/graalvm/compiler/api/directives/GraalDirectives.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/ClassSubstitution.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/ClassSubstitution.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/ClassSubstitution.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/ClassSubstitution.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/Fold.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/Fold.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/Fold.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/Fold.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/MethodSubstitution.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/MethodSubstitution.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/MethodSubstitution.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/MethodSubstitution.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/MethodSubstitutionRegistry.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/MethodSubstitutionRegistry.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/MethodSubstitutionRegistry.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/MethodSubstitutionRegistry.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/Snippet.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/Snippet.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/Snippet.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/Snippet.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/SnippetReflectionProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/SnippetReflectionProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/SnippetReflectionProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/SnippetReflectionProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/SnippetTemplateCache.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/SnippetTemplateCache.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/SnippetTemplateCache.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.replacements/src/org/graalvm/compiler/api/replacements/SnippetTemplateCache.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.runtime/src/org/graalvm/compiler/api/runtime/GraalJVMCICompiler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.runtime/src/org/graalvm/compiler/api/runtime/GraalJVMCICompiler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.runtime/src/org/graalvm/compiler/api/runtime/GraalJVMCICompiler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.runtime/src/org/graalvm/compiler/api/runtime/GraalJVMCICompiler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.runtime/src/org/graalvm/compiler/api/runtime/GraalRuntime.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.runtime/src/org/graalvm/compiler/api/runtime/GraalRuntime.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.runtime/src/org/graalvm/compiler/api/runtime/GraalRuntime.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.runtime/src/org/graalvm/compiler/api/runtime/GraalRuntime.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/Graal.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/Graal.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/Graal.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/Graal.java
index 01746c74bf8..82268194cbd 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/Graal.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/Graal.java
@@ -40,7 +40,7 @@ public class Graal {
     private static final GraalRuntime runtime = initializeRuntime();
 
     private static GraalRuntime initializeRuntime() {
-        Services.exportJVMCITo(Graal.class);
+        Services.initializeJVMCI();
         JVMCICompiler compiler = JVMCI.getRuntime().getCompiler();
         if (compiler instanceof GraalJVMCICompiler) {
             GraalJVMCICompiler graal = (GraalJVMCICompiler) compiler;
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/GraalAPITest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/GraalAPITest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/GraalAPITest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.api.test/src/org/graalvm/compiler/api/test/GraalAPITest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64.test/src/org/graalvm/compiler/asm/aarch64/test/AArch64MacroAssemblerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64.test/src/org/graalvm/compiler/asm/aarch64/test/AArch64MacroAssemblerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64.test/src/org/graalvm/compiler/asm/aarch64/test/AArch64MacroAssemblerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64.test/src/org/graalvm/compiler/asm/aarch64/test/AArch64MacroAssemblerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64.test/src/org/graalvm/compiler/asm/aarch64/test/TestProtectedAssembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64.test/src/org/graalvm/compiler/asm/aarch64/test/TestProtectedAssembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64.test/src/org/graalvm/compiler/asm/aarch64/test/TestProtectedAssembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64.test/src/org/graalvm/compiler/asm/aarch64/test/TestProtectedAssembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64Address.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64Address.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64Address.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64Address.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64Assembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64Assembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64Assembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64Assembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64MacroAssembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64MacroAssembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64MacroAssembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.aarch64/src/org/graalvm/compiler/asm/aarch64/AArch64MacroAssembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/BitOpsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/BitOpsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/BitOpsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/BitOpsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/IncrementDecrementMacroTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/IncrementDecrementMacroTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/IncrementDecrementMacroTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/IncrementDecrementMacroTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/SimpleAssemblerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/SimpleAssemblerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/SimpleAssemblerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64.test/src/org/graalvm/compiler/asm/amd64/test/SimpleAssemblerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64Address.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64Address.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64Address.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64Address.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64AsmOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64AsmOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64AsmOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64AsmOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64Assembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64Assembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64Assembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64Assembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64InstructionAttr.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64InstructionAttr.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64InstructionAttr.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64InstructionAttr.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64MacroAssembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64MacroAssembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64MacroAssembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.amd64/src/org/graalvm/compiler/asm/amd64/AMD64MacroAssembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc.test/src/org/graalvm/compiler/asm/sparc/test/BitSpecTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc.test/src/org/graalvm/compiler/asm/sparc/test/BitSpecTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc.test/src/org/graalvm/compiler/asm/sparc/test/BitSpecTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc.test/src/org/graalvm/compiler/asm/sparc/test/BitSpecTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc.test/src/org/graalvm/compiler/asm/sparc/test/SPARCAssemblerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc.test/src/org/graalvm/compiler/asm/sparc/test/SPARCAssemblerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc.test/src/org/graalvm/compiler/asm/sparc/test/SPARCAssemblerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc.test/src/org/graalvm/compiler/asm/sparc/test/SPARCAssemblerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCAddress.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCAddress.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCAddress.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCAddress.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCAssembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCAssembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCAssembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCAssembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCInstructionCounter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCInstructionCounter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCInstructionCounter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCInstructionCounter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCMacroAssembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCMacroAssembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCMacroAssembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.sparc/src/org/graalvm/compiler/asm/sparc/SPARCMacroAssembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.test/src/org/graalvm/compiler/asm/test/AssemblerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.test/src/org/graalvm/compiler/asm/test/AssemblerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm.test/src/org/graalvm/compiler/asm/test/AssemblerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm.test/src/org/graalvm/compiler/asm/test/AssemblerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/AbstractAddress.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/AbstractAddress.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/AbstractAddress.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/AbstractAddress.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/AsmOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/AsmOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/AsmOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/AsmOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Assembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Assembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Assembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Assembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Buffer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Buffer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Buffer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Buffer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Label.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Label.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Label.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/Label.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/NumUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/NumUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/NumUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.asm/src/org/graalvm/compiler/asm/NumUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BridgeMethodUtils.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BridgeMethodUtils.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BridgeMethodUtils.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BridgeMethodUtils.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytecode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytecode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytecode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytecode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeDisassembler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeDisassembler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeDisassembler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeDisassembler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeLookupSwitch.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeLookupSwitch.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeLookupSwitch.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeLookupSwitch.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeStream.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeStream.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeStream.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeStream.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeSwitch.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeSwitch.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeSwitch.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeSwitch.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeTableSwitch.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeTableSwitch.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeTableSwitch.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/BytecodeTableSwitch.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytecodes.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytecodes.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytecodes.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytecodes.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytes.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytes.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytes.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/Bytes.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/ResolvedJavaMethodBytecode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/ResolvedJavaMethodBytecode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/ResolvedJavaMethodBytecode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/ResolvedJavaMethodBytecode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/ResolvedJavaMethodBytecodeProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/ResolvedJavaMethodBytecodeProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/ResolvedJavaMethodBytecodeProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.bytecode/src/org/graalvm/compiler/bytecode/ResolvedJavaMethodBytecodeProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/CompilationResult.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/CompilationResult.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/CompilationResult.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/CompilationResult.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/DataSection.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/DataSection.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/DataSection.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/DataSection.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/DisassemblerProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/DisassemblerProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/DisassemblerProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/DisassemblerProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/HexCodeFile.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/HexCodeFile.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/HexCodeFile.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/HexCodeFile.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/HexCodeFileDisassemblerProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/HexCodeFileDisassemblerProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/HexCodeFileDisassemblerProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/HexCodeFileDisassemblerProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/SourceMapping.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/SourceMapping.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/SourceMapping.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/SourceMapping.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/SourceStackTraceBailoutException.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/SourceStackTraceBailoutException.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/SourceStackTraceBailoutException.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.code/src/org/graalvm/compiler/code/SourceStackTraceBailoutException.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.common/src/org/graalvm/compiler/common/PermanentBailoutException.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.common/src/org/graalvm/compiler/common/PermanentBailoutException.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.common/src/org/graalvm/compiler/common/PermanentBailoutException.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.common/src/org/graalvm/compiler/common/PermanentBailoutException.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.common/src/org/graalvm/compiler/common/RetryableBailoutException.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.common/src/org/graalvm/compiler/common/RetryableBailoutException.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.common/src/org/graalvm/compiler/common/RetryableBailoutException.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.common/src/org/graalvm/compiler/common/RetryableBailoutException.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64AddressLowering.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64AddressLowering.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64AddressLowering.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64AddressLowering.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64AddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64AddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64AddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64AddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64ArithmeticLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64ArithmeticLIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64ArithmeticLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64ArithmeticLIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64FloatConvertOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64FloatConvertOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64FloatConvertOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64FloatConvertOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64LIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64LIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64LIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64LIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64LIRKindTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64LIRKindTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64LIRKindTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64LIRKindTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64MoveFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64MoveFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64MoveFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64MoveFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64NodeLIRBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64NodeLIRBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64NodeLIRBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64NodeLIRBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64NodeMatchRules.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64NodeMatchRules.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64NodeMatchRules.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64NodeMatchRules.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64SuitesProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64SuitesProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64SuitesProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.aarch64/src/org/graalvm/compiler/core/aarch64/AArch64SuitesProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/AMD64AllocatorTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/AMD64AllocatorTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/AMD64AllocatorTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/AMD64AllocatorTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/ConstantStackMoveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/ConstantStackMoveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/ConstantStackMoveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/ConstantStackMoveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/MatchRuleTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/MatchRuleTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/MatchRuleTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/MatchRuleTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/StackStoreTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/StackStoreTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/StackStoreTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64.test/src/org/graalvm/compiler/core/amd64/test/StackStoreTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64AddressLowering.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64AddressLowering.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64AddressLowering.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64AddressLowering.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64AddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64AddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64AddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64AddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64ArithmeticLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64ArithmeticLIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64ArithmeticLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64ArithmeticLIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64LIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64LIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64LIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64LIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64LIRKindTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64LIRKindTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64LIRKindTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64LIRKindTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64MoveFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64MoveFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64MoveFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64MoveFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64MoveFactoryBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64MoveFactoryBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64MoveFactoryBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64MoveFactoryBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64NodeLIRBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64NodeLIRBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64NodeLIRBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64NodeLIRBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64NodeMatchRules.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64NodeMatchRules.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64NodeMatchRules.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64NodeMatchRules.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64SuitesProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64SuitesProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64SuitesProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.amd64/src/org/graalvm/compiler/core/amd64/AMD64SuitesProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CollectionsFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CollectionsFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CollectionsFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CollectionsFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CompilationIdentifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CompilationIdentifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CompilationIdentifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CompilationIdentifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CompilationRequestIdentifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CompilationRequestIdentifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CompilationRequestIdentifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/CompilationRequestIdentifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/FieldIntrospection.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/FieldIntrospection.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/FieldIntrospection.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/FieldIntrospection.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/Fields.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/Fields.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/Fields.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/Fields.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/FieldsScanner.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/FieldsScanner.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/FieldsScanner.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/FieldsScanner.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/GraalOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/GraalOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/GraalOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/GraalOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LIRKind.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LIRKind.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LIRKind.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LIRKind.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LinkedIdentityHashMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LinkedIdentityHashMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LinkedIdentityHashMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LinkedIdentityHashMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LocationIdentity.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LocationIdentity.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LocationIdentity.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/LocationIdentity.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/SuppressFBWarnings.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/SuppressFBWarnings.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/SuppressFBWarnings.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/SuppressFBWarnings.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/UnsafeAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/UnsafeAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/UnsafeAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/UnsafeAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/BiDirectionalTraceBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/BiDirectionalTraceBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/BiDirectionalTraceBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/BiDirectionalTraceBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/ComputeBlockOrder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/ComputeBlockOrder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/ComputeBlockOrder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/ComputeBlockOrder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/RegisterAllocationConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/RegisterAllocationConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/RegisterAllocationConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/RegisterAllocationConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/SingleBlockTraceBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/SingleBlockTraceBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/SingleBlockTraceBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/SingleBlockTraceBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/Trace.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/Trace.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/Trace.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/Trace.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceBuilderResult.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceBuilderResult.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceBuilderResult.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceBuilderResult.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceStatisticsPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceStatisticsPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceStatisticsPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/TraceStatisticsPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/UniDirectionalTraceBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/UniDirectionalTraceBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/UniDirectionalTraceBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/alloc/UniDirectionalTraceBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/Condition.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/Condition.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/Condition.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/Condition.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/FloatConvert.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/FloatConvert.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/FloatConvert.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/FloatConvert.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/UnsignedMath.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/UnsignedMath.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/UnsignedMath.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/calc/UnsignedMath.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/AbstractBlockBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/AbstractBlockBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/AbstractBlockBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/AbstractBlockBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/AbstractControlFlowGraph.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/AbstractControlFlowGraph.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/AbstractControlFlowGraph.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/AbstractControlFlowGraph.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/BlockMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/BlockMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/BlockMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/BlockMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/CFGVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/CFGVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/CFGVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/CFGVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/DominatorOptimizationProblem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/DominatorOptimizationProblem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/DominatorOptimizationProblem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/DominatorOptimizationProblem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/Loop.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/Loop.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/Loop.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/Loop.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PrintableCFG.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PrintableCFG.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PrintableCFG.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PrintableCFG.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PrintableDominatorOptimizationProblem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PrintableDominatorOptimizationProblem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PrintableDominatorOptimizationProblem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PrintableDominatorOptimizationProblem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PropertyConsumable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PropertyConsumable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PropertyConsumable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/cfg/PropertyConsumable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/CodeGenProviders.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/CodeGenProviders.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/CodeGenProviders.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/CodeGenProviders.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ConstantFieldProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ConstantFieldProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ConstantFieldProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ConstantFieldProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallDescriptor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallDescriptor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallDescriptor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallDescriptor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallLinkage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallLinkage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallLinkage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallLinkage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/ForeignCallsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/JavaConstantFieldProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/JavaConstantFieldProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/JavaConstantFieldProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/JavaConstantFieldProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/LIRKindTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/LIRKindTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/LIRKindTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/spi/LIRKindTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/AbstractObjectStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/AbstractObjectStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/AbstractObjectStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/AbstractObjectStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/AbstractPointerStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/AbstractPointerStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/AbstractPointerStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/AbstractPointerStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ArithmeticOpTable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ArithmeticOpTable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ArithmeticOpTable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ArithmeticOpTable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ArithmeticStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ArithmeticStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ArithmeticStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ArithmeticStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/DataPointerConstant.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/DataPointerConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/DataPointerConstant.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/DataPointerConstant.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/FloatStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/FloatStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/FloatStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/FloatStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/IllegalStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/IllegalStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/IllegalStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/IllegalStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/IntegerStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/IntegerStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/IntegerStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/IntegerStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ObjectStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ObjectStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ObjectStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/ObjectStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/PrimitiveStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/PrimitiveStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/PrimitiveStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/PrimitiveStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/RawPointerStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/RawPointerStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/RawPointerStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/RawPointerStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/Stamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/Stamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/Stamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/Stamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/StampFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/StampFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/StampFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/StampFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/StampPair.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/StampPair.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/StampPair.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/StampPair.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/TypeReference.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/TypeReference.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/TypeReference.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/TypeReference.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/VoidStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/VoidStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/VoidStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/type/VoidStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ArrayMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ArrayMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ArrayMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ArrayMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ArraySet.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ArraySet.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ArraySet.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ArraySet.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/BitMap2D.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/BitMap2D.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/BitMap2D.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/BitMap2D.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/CompilationAlarm.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/CompilationAlarm.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/CompilationAlarm.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/CompilationAlarm.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/FrequencyEncoder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/FrequencyEncoder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/FrequencyEncoder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/FrequencyEncoder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/IntList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/IntList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/IntList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/IntList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ModuleAPI.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ModuleAPI.java
similarity index 83%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ModuleAPI.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ModuleAPI.java
index 240fdc07fb6..86e1bac530a 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ModuleAPI.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/ModuleAPI.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -53,27 +53,22 @@ public final class ModuleAPI {
     public static final ModuleAPI getModule;
 
     /**
-     * {@code jdk.internal.module.Modules.addExports(Module, String, Module)}.
-     */
-    public static final ModuleAPI addExports;
-
-    /**
-     * {@code java.lang.reflect.Module.getResourceAsStream(String)}.
+     * {@code java.lang.Module.getResourceAsStream(String)}.
      */
     public static final ModuleAPI getResourceAsStream;
 
     /**
-     * {@code java.lang.reflect.Module.canRead(Module)}.
+     * {@code java.lang.Module.canRead(Module)}.
      */
     public static final ModuleAPI canRead;
 
     /**
-     * {@code java.lang.reflect.Module.isExported(String)}.
+     * {@code java.lang.Module.isExported(String)}.
      */
     public static final ModuleAPI isExported;
 
     /**
-     * {@code java.lang.reflect.Module.isExported(String, Module)}.
+     * {@code java.lang.Module.isExported(String, Module)}.
      */
     public static final ModuleAPI isExportedTo;
 
@@ -116,13 +111,11 @@ public final class ModuleAPI {
             try {
                 getModule = new ModuleAPI(Class.class.getMethod("getModule"));
                 Class moduleClass = getModule.method.getReturnType();
-                Class modulesClass = Class.forName("jdk.internal.module.Modules");
                 getResourceAsStream = new ModuleAPI(moduleClass.getMethod("getResourceAsStream", String.class));
                 canRead = new ModuleAPI(moduleClass.getMethod("canRead", moduleClass));
                 isExported = new ModuleAPI(moduleClass.getMethod("isExported", String.class));
                 isExportedTo = new ModuleAPI(moduleClass.getMethod("isExported", String.class, moduleClass));
-                addExports = new ModuleAPI(modulesClass.getDeclaredMethod("addExports", moduleClass, String.class, moduleClass));
-            } catch (NoSuchMethodException | SecurityException | ClassNotFoundException e) {
+            } catch (NoSuchMethodException | SecurityException e) {
                 throw new InternalError(e);
             }
         } else {
@@ -132,8 +125,6 @@ public final class ModuleAPI {
             canRead = unavailable;
             isExported = unavailable;
             isExportedTo = unavailable;
-            addExports = unavailable;
         }
-
     }
 }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeConversion.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeConversion.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeConversion.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeConversion.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeReader.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeReader.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeReader.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeReader.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeWriter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeWriter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeWriter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/TypeWriter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeArrayTypeReader.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeArrayTypeReader.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeArrayTypeReader.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeArrayTypeReader.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeArrayTypeWriter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeArrayTypeWriter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeArrayTypeWriter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/UnsafeArrayTypeWriter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/Util.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/Util.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/Util.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.common/src/org/graalvm/compiler/core/common/util/Util.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.match.processor/src/META-INF/services/javax.annotation.processing.Processor b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.match.processor/src/META-INF/services/javax.annotation.processing.Processor
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.match.processor/src/META-INF/services/javax.annotation.processing.Processor
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.match.processor/src/META-INF/services/javax.annotation.processing.Processor
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.match.processor/src/org/graalvm/compiler/core/match/processor/MatchProcessor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.match.processor/src/org/graalvm/compiler/core/match/processor/MatchProcessor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.match.processor/src/org/graalvm/compiler/core/match/processor/MatchProcessor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.match.processor/src/org/graalvm/compiler/core/match/processor/MatchProcessor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc.test/src/org/graalvm/compiler/core/sparc/test/SPARCAllocatorTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc.test/src/org/graalvm/compiler/core/sparc/test/SPARCAllocatorTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc.test/src/org/graalvm/compiler/core/sparc/test/SPARCAllocatorTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc.test/src/org/graalvm/compiler/core/sparc/test/SPARCAllocatorTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCAddressLowering.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCAddressLowering.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCAddressLowering.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCAddressLowering.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCArithmeticLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCArithmeticLIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCArithmeticLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCArithmeticLIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCImmediateAddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCImmediateAddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCImmediateAddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCImmediateAddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCIndexedAddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCIndexedAddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCIndexedAddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCIndexedAddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCIntegerCompareCanonicalizationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCIntegerCompareCanonicalizationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCIntegerCompareCanonicalizationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCIntegerCompareCanonicalizationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCLIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCLIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCLIRKindTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCLIRKindTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCLIRKindTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCLIRKindTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCMoveFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCMoveFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCMoveFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCMoveFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCNodeLIRBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCNodeLIRBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCNodeLIRBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCNodeLIRBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCNodeMatchRules.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCNodeMatchRules.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCNodeMatchRules.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCNodeMatchRules.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCSuitesProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCSuitesProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCSuitesProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.sparc/src/org/graalvm/compiler/core/sparc/SPARCSuitesProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/AllocSpy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/AllocSpy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/AllocSpy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/AllocSpy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/BoxingEliminationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/BoxingEliminationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/BoxingEliminationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/BoxingEliminationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/BoxingTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/BoxingTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/BoxingTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/BoxingTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CheckGraalInvariants.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CheckGraalInvariants.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CheckGraalInvariants.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CheckGraalInvariants.java
index 8c8c74f3442..405652ed1e3 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CheckGraalInvariants.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CheckGraalInvariants.java
@@ -127,7 +127,7 @@ public class CheckGraalInvariants extends GraalTest {
         MetaAccessProvider metaAccess = providers.getMetaAccess();
 
         PhaseSuite graphBuilderSuite = new PhaseSuite<>();
-        Plugins plugins = new Plugins(new InvocationPlugins(metaAccess));
+        Plugins plugins = new Plugins(new InvocationPlugins());
         GraphBuilderConfiguration config = GraphBuilderConfiguration.getDefault(plugins).withEagerResolving(true);
         graphBuilderSuite.appendPhase(new GraphBuilderPhase(config));
         HighTierContext context = new HighTierContext(providers, graphBuilderSuite, OptimisticOptimizations.NONE);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CommonedConstantsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CommonedConstantsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CommonedConstantsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CommonedConstantsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CompareCanonicalizerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CompareCanonicalizerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CompareCanonicalizerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CompareCanonicalizerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConcreteSubtypeTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConcreteSubtypeTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConcreteSubtypeTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConcreteSubtypeTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationLoadFieldConstantFoldTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationLoadFieldConstantFoldTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationLoadFieldConstantFoldTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationLoadFieldConstantFoldTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationMulTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationMulTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationMulTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationMulTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest10.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest10.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest10.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest10.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest11.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest11.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest11.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest11.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest5.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest5.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest5.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest5.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest6.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest6.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest6.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest6.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest7.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest7.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest7.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest7.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest8.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest8.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest8.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest8.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest9.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest9.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest9.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTest9.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTestBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTestBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTestBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConditionalEliminationTestBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConstantArrayReadFoldingTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConstantArrayReadFoldingTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConstantArrayReadFoldingTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ConstantArrayReadFoldingTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CooperativePhaseTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CooperativePhaseTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CooperativePhaseTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CooperativePhaseTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CopyOfVirtualizationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CopyOfVirtualizationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CopyOfVirtualizationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CopyOfVirtualizationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CountedLoopTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CountedLoopTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CountedLoopTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/CountedLoopTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/DegeneratedLoopsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/DegeneratedLoopsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/DegeneratedLoopsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/DegeneratedLoopsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/DontReuseArgumentSpaceTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/DontReuseArgumentSpaceTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/DontReuseArgumentSpaceTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/DontReuseArgumentSpaceTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/EnumSwitchTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/EnumSwitchTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/EnumSwitchTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/EnumSwitchTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FinalizableSubclassTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FinalizableSubclassTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FinalizableSubclassTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FinalizableSubclassTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FindUniqueConcreteMethodBugTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FindUniqueConcreteMethodBugTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FindUniqueConcreteMethodBugTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FindUniqueConcreteMethodBugTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FindUniqueDefaultMethodTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FindUniqueDefaultMethodTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FindUniqueDefaultMethodTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FindUniqueDefaultMethodTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FloatOptimizationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FloatOptimizationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FloatOptimizationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FloatOptimizationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FloatingReadTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FloatingReadTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FloatingReadTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/FloatingReadTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraalCompilerAssumptionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraalCompilerAssumptionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraalCompilerAssumptionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraalCompilerAssumptionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraalCompilerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraalCompilerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraalCompilerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraalCompilerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraphEncoderTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraphEncoderTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraphEncoderTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraphEncoderTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraphScheduleTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraphScheduleTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraphScheduleTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GraphScheduleTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GuardEliminationCornerCasesTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GuardEliminationCornerCasesTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GuardEliminationCornerCasesTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GuardEliminationCornerCasesTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GuardedIntrinsicTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GuardedIntrinsicTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GuardedIntrinsicTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/GuardedIntrinsicTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/HashCodeTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/HashCodeTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/HashCodeTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/HashCodeTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IfCanonicalizerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IfCanonicalizerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IfCanonicalizerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IfCanonicalizerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IfReorderTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IfReorderTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IfReorderTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IfReorderTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ImplicitNullCheckTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ImplicitNullCheckTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ImplicitNullCheckTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ImplicitNullCheckTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InfopointReasonTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InfopointReasonTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InfopointReasonTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InfopointReasonTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InstalledCodeInvalidationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InstalledCodeInvalidationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InstalledCodeInvalidationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InstalledCodeInvalidationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IntegerEqualsCanonicalizerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IntegerEqualsCanonicalizerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IntegerEqualsCanonicalizerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IntegerEqualsCanonicalizerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IntegerStampMulFoldTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IntegerStampMulFoldTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IntegerStampMulFoldTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/IntegerStampMulFoldTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InterfaceMethodHandleTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InterfaceMethodHandleTest.java
similarity index 97%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InterfaceMethodHandleTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InterfaceMethodHandleTest.java
index f580313a3fd..601fc26ad90 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InterfaceMethodHandleTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InterfaceMethodHandleTest.java
@@ -26,15 +26,14 @@ import java.lang.invoke.MethodHandle;
 import java.lang.invoke.MethodHandles;
 import java.lang.invoke.MethodType;
 
-import org.junit.Test;
-
 import org.graalvm.compiler.code.CompilationResult;
 import org.graalvm.compiler.test.ExportingClassLoader;
+import org.junit.Test;
+import org.objectweb.asm.ClassWriter;
+import org.objectweb.asm.Label;
+import org.objectweb.asm.MethodVisitor;
+import org.objectweb.asm.Opcodes;
 
-import jdk.internal.org.objectweb.asm.ClassWriter;
-import jdk.internal.org.objectweb.asm.Label;
-import jdk.internal.org.objectweb.asm.MethodVisitor;
-import jdk.internal.org.objectweb.asm.Opcodes;
 import jdk.vm.ci.code.InstalledCode;
 import jdk.vm.ci.meta.ResolvedJavaMethod;
 
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InvokeExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InvokeExceptionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InvokeExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InvokeExceptionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InvokeHintsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InvokeHintsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InvokeHintsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/InvokeHintsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LockEliminationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LockEliminationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LockEliminationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LockEliminationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LongNodeChainTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LongNodeChainTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LongNodeChainTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LongNodeChainTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LoopUnswitchTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LoopUnswitchTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LoopUnswitchTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/LoopUnswitchTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MarkUnsafeAccessTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MarkUnsafeAccessTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MarkUnsafeAccessTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MarkUnsafeAccessTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MemoryArithmeticTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MemoryArithmeticTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MemoryArithmeticTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MemoryArithmeticTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MemoryScheduleTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MemoryScheduleTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MemoryScheduleTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MemoryScheduleTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MergeCanonicalizerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MergeCanonicalizerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MergeCanonicalizerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MergeCanonicalizerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MethodHandleEagerResolution.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MethodHandleEagerResolution.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MethodHandleEagerResolution.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MethodHandleEagerResolution.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MonitorGraphTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MonitorGraphTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MonitorGraphTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/MonitorGraphTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NestedLoopTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NestedLoopTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NestedLoopTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NestedLoopTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NodePosIteratorTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NodePosIteratorTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NodePosIteratorTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NodePosIteratorTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NodePropertiesTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NodePropertiesTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NodePropertiesTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/NodePropertiesTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OnStackReplacementTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OnStackReplacementTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OnStackReplacementTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OnStackReplacementTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OptionsVerifierTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OptionsVerifierTest.java
similarity index 97%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OptionsVerifierTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OptionsVerifierTest.java
index ea1de661d3f..ccd10019b0d 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OptionsVerifierTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/OptionsVerifierTest.java
@@ -44,19 +44,17 @@ import java.util.Objects;
 import java.util.ServiceLoader;
 import java.util.Set;
 
-import org.junit.Test;
-
 import org.graalvm.compiler.options.OptionDescriptor;
 import org.graalvm.compiler.options.OptionDescriptors;
 import org.graalvm.compiler.options.OptionValue;
 import org.graalvm.compiler.test.GraalTest;
-
-import jdk.internal.org.objectweb.asm.ClassReader;
-import jdk.internal.org.objectweb.asm.ClassVisitor;
-import jdk.internal.org.objectweb.asm.Label;
-import jdk.internal.org.objectweb.asm.MethodVisitor;
-import jdk.internal.org.objectweb.asm.Opcodes;
-import jdk.internal.org.objectweb.asm.Type;
+import org.junit.Test;
+import org.objectweb.asm.ClassReader;
+import org.objectweb.asm.ClassVisitor;
+import org.objectweb.asm.Label;
+import org.objectweb.asm.MethodVisitor;
+import org.objectweb.asm.Opcodes;
+import org.objectweb.asm.Type;
 
 /**
  * Verifies a class declaring one or more {@linkplain OptionValue options} has a class initializer
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PhiCreationTests.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PhiCreationTests.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PhiCreationTests.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PhiCreationTests.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ProfilingInfoTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ProfilingInfoTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ProfilingInfoTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ProfilingInfoTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PushNodesThroughPiTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PushNodesThroughPiTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PushNodesThroughPiTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PushNodesThroughPiTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PushThroughIfTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PushThroughIfTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PushThroughIfTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/PushThroughIfTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReadAfterCheckCastTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReadAfterCheckCastTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReadAfterCheckCastTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReadAfterCheckCastTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReassociateAndCanonicalTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReassociateAndCanonicalTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReassociateAndCanonicalTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReassociateAndCanonicalTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReentrantBlockIteratorTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReentrantBlockIteratorTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReentrantBlockIteratorTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReentrantBlockIteratorTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReferenceGetLoopTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReferenceGetLoopTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReferenceGetLoopTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ReferenceGetLoopTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ScalarTypeSystemTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ScalarTypeSystemTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ScalarTypeSystemTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ScalarTypeSystemTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SchedulingTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SchedulingTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SchedulingTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SchedulingTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SchedulingTest2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SchedulingTest2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SchedulingTest2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SchedulingTest2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ShortCircuitNodeTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ShortCircuitNodeTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ShortCircuitNodeTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ShortCircuitNodeTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SimpleCFGTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SimpleCFGTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SimpleCFGTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/SimpleCFGTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StampCanonicalizerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StampCanonicalizerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StampCanonicalizerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StampCanonicalizerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StaticInterfaceFieldTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StaticInterfaceFieldTest.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StaticInterfaceFieldTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StaticInterfaceFieldTest.java
index 235f31292e6..27af889f90a 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StaticInterfaceFieldTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StaticInterfaceFieldTest.java
@@ -83,7 +83,7 @@ public class StaticInterfaceFieldTest extends GraalTest {
         MetaAccessProvider metaAccess = providers.getMetaAccess();
 
         PhaseSuite graphBuilderSuite = new PhaseSuite<>();
-        Plugins plugins = new Plugins(new InvocationPlugins(metaAccess));
+        Plugins plugins = new Plugins(new InvocationPlugins());
         GraphBuilderConfiguration config = GraphBuilderConfiguration.getDefault(plugins).withEagerResolving(true);
         graphBuilderSuite.appendPhase(new GraphBuilderPhase(config));
         HighTierContext context = new HighTierContext(providers, graphBuilderSuite, OptimisticOptimizations.NONE);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StraighteningTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StraighteningTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StraighteningTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/StraighteningTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/TypeSystemTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/TypeSystemTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/TypeSystemTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/TypeSystemTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/TypeWriterTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/TypeWriterTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/TypeWriterTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/TypeWriterTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnbalancedMonitorsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnbalancedMonitorsTest.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnbalancedMonitorsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnbalancedMonitorsTest.java
index 2c96072aa48..633441b981d 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnbalancedMonitorsTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnbalancedMonitorsTest.java
@@ -24,10 +24,10 @@ package org.graalvm.compiler.core.test;
 
 import jdk.vm.ci.code.BailoutException;
 import jdk.vm.ci.meta.ResolvedJavaMethod;
-import jdk.internal.org.objectweb.asm.ClassWriter;
-import jdk.internal.org.objectweb.asm.Label;
-import jdk.internal.org.objectweb.asm.MethodVisitor;
-import jdk.internal.org.objectweb.asm.Opcodes;
+import org.objectweb.asm.ClassWriter;
+import org.objectweb.asm.Label;
+import org.objectweb.asm.MethodVisitor;
+import org.objectweb.asm.Opcodes;
 
 import static org.graalvm.compiler.core.common.CompilationIdentifier.INVALID_COMPILATION_ID;
 
@@ -86,7 +86,7 @@ public class UnbalancedMonitorsTest extends GraalCompilerTest implements Opcodes
         ResolvedJavaMethod method = getResolvedJavaMethod(LOADER.findClass(INNER_CLASS_NAME), name);
         try {
             StructuredGraph graph = new StructuredGraph(method, AllowAssumptions.NO, INVALID_COMPILATION_ID);
-            Plugins plugins = new Plugins(new InvocationPlugins(getMetaAccess()));
+            Plugins plugins = new Plugins(new InvocationPlugins());
             GraphBuilderConfiguration graphBuilderConfig = GraphBuilderConfiguration.getDefault(plugins).withEagerResolving(true);
             OptimisticOptimizations optimisticOpts = OptimisticOptimizations.NONE;
 
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnsafeReadEliminationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnsafeReadEliminationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnsafeReadEliminationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/UnsafeReadEliminationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyBailoutUsageTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyBailoutUsageTest.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyBailoutUsageTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyBailoutUsageTest.java
index 0a50d9192cf..ff82e1aabf2 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyBailoutUsageTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyBailoutUsageTest.java
@@ -122,7 +122,7 @@ public class VerifyBailoutUsageTest {
         Providers providers = rt.getHostBackend().getProviders();
         MetaAccessProvider metaAccess = providers.getMetaAccess();
         PhaseSuite graphBuilderSuite = new PhaseSuite<>();
-        Plugins plugins = new Plugins(new InvocationPlugins(metaAccess));
+        Plugins plugins = new Plugins(new InvocationPlugins());
         GraphBuilderConfiguration config = GraphBuilderConfiguration.getDefault(plugins).withEagerResolving(true);
         graphBuilderSuite.appendPhase(new GraphBuilderPhase(config));
         HighTierContext context = new HighTierContext(providers, graphBuilderSuite, OptimisticOptimizations.NONE);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyDebugUsageTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyDebugUsageTest.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyDebugUsageTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyDebugUsageTest.java
index 00df7430a07..47aba0895c8 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyDebugUsageTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyDebugUsageTest.java
@@ -300,7 +300,7 @@ public class VerifyDebugUsageTest {
         Providers providers = rt.getHostBackend().getProviders();
         MetaAccessProvider metaAccess = providers.getMetaAccess();
         PhaseSuite graphBuilderSuite = new PhaseSuite<>();
-        Plugins plugins = new Plugins(new InvocationPlugins(metaAccess));
+        Plugins plugins = new Plugins(new InvocationPlugins());
         GraphBuilderConfiguration config = GraphBuilderConfiguration.getDefault(plugins).withEagerResolving(true);
         graphBuilderSuite.appendPhase(new GraphBuilderPhase(config));
         HighTierContext context = new HighTierContext(providers, graphBuilderSuite, OptimisticOptimizations.NONE);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyVirtualizableTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyVirtualizableTest.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyVirtualizableTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyVirtualizableTest.java
index 855be893315..0b6669b70a5 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyVirtualizableTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/VerifyVirtualizableTest.java
@@ -267,7 +267,7 @@ public class VerifyVirtualizableTest {
         Providers providers = rt.getHostBackend().getProviders();
         MetaAccessProvider metaAccess = providers.getMetaAccess();
         PhaseSuite graphBuilderSuite = new PhaseSuite<>();
-        Plugins plugins = new Plugins(new InvocationPlugins(metaAccess));
+        Plugins plugins = new Plugins(new InvocationPlugins());
         GraphBuilderConfiguration config = GraphBuilderConfiguration.getDefault(plugins).withEagerResolving(true);
         graphBuilderSuite.appendPhase(new GraphBuilderPhase(config));
         HighTierContext context = new HighTierContext(providers, graphBuilderSuite, OptimisticOptimizations.NONE);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/backend/AllocatorTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/backend/AllocatorTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/backend/AllocatorTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/backend/AllocatorTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/backend/BackendTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/backend/BackendTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/backend/BackendTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/backend/BackendTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest5.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest5.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest5.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest5.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest6.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest6.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest6.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTest6.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTestInterception01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTestInterception01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTestInterception01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTestInterception01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTestInterception02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTestInterception02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTestInterception02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/MethodMetricsTestInterception02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/VerifyMethodMetricsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/VerifyMethodMetricsTest.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/VerifyMethodMetricsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/VerifyMethodMetricsTest.java
index ccfc04fd822..69826384295 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/VerifyMethodMetricsTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/debug/VerifyMethodMetricsTest.java
@@ -249,7 +249,7 @@ public class VerifyMethodMetricsTest {
         Providers providers = rt.getHostBackend().getProviders();
         MetaAccessProvider metaAccess = providers.getMetaAccess();
         PhaseSuite graphBuilderSuite = new PhaseSuite<>();
-        Plugins plugins = new Plugins(new InvocationPlugins(metaAccess));
+        Plugins plugins = new Plugins(new InvocationPlugins());
         GraphBuilderConfiguration config = GraphBuilderConfiguration.getDefault(plugins).withEagerResolving(true);
         graphBuilderSuite.appendPhase(new GraphBuilderPhase(config));
         HighTierContext context = new HighTierContext(providers, graphBuilderSuite, OptimisticOptimizations.NONE);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/CompiledMethodTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/CompiledMethodTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/CompiledMethodTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/CompiledMethodTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/MonitorDeoptTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/MonitorDeoptTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/MonitorDeoptTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/MonitorDeoptTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/SafepointRethrowDeoptTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/SafepointRethrowDeoptTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/SafepointRethrowDeoptTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/SafepointRethrowDeoptTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/SynchronizedMethodDeoptimizationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/SynchronizedMethodDeoptimizationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/SynchronizedMethodDeoptimizationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/deopt/SynchronizedMethodDeoptimizationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EAMergingTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EAMergingTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EAMergingTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EAMergingTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EATestBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EATestBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EATestBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EATestBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EarlyReadEliminationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EarlyReadEliminationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EarlyReadEliminationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EarlyReadEliminationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EscapeAnalysisTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EscapeAnalysisTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EscapeAnalysisTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/EscapeAnalysisTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/NestedBoxingTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/NestedBoxingTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/NestedBoxingTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/NestedBoxingTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PEAAssertionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PEAAssertionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PEAAssertionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PEAAssertionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PEAReadEliminationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PEAReadEliminationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PEAReadEliminationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PEAReadEliminationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PartialEscapeAnalysisTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PartialEscapeAnalysisTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PartialEscapeAnalysisTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PartialEscapeAnalysisTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PoorMansEATest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PoorMansEATest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PoorMansEATest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/PoorMansEATest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/UnsafeEATest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/UnsafeEATest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/UnsafeEATest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ea/UnsafeEATest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/inlining/InliningTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/inlining/InliningTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/inlining/InliningTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/inlining/InliningTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/inlining/RecursiveInliningTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/inlining/RecursiveInliningTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/inlining/RecursiveInliningTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/inlining/RecursiveInliningTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/GraalTutorial.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/GraalTutorial.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/GraalTutorial.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/GraalTutorial.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/InvokeGraal.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/InvokeGraal.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/InvokeGraal.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/InvokeGraal.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysis.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysis.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysis.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysis.java
index 92898acf01e..4f8a61e1901 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysis.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysis.java
@@ -253,7 +253,7 @@ public class StaticAnalysis {
                      * the code before static analysis, the classes would otherwise be not loaded
                      * yet and the bytecode parser would only create a graph.
                      */
-                    Plugins plugins = new Plugins(new InvocationPlugins(metaAccess));
+                    Plugins plugins = new Plugins(new InvocationPlugins());
                     GraphBuilderConfiguration graphBuilderConfig = GraphBuilderConfiguration.getDefault(plugins).withEagerResolving(true);
                     /*
                      * For simplicity, we ignore all exception handling during the static analysis.
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysisTests.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysisTests.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysisTests.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/tutorial/StaticAnalysisTests.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/CompilerThread.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/CompilerThread.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/CompilerThread.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/CompilerThread.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/CompilerThreadFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/CompilerThreadFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/CompilerThreadFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/CompilerThreadFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalCompiler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalCompiler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalCompiler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalCompiler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalCompilerOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalCompilerOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalCompilerOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalCompilerOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalDebugInitializationParticipant.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalDebugInitializationParticipant.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalDebugInitializationParticipant.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/GraalDebugInitializationParticipant.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/LIRGenerationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/LIRGenerationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/LIRGenerationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/LIRGenerationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/BytecodeParserTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/BytecodeParserTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/BytecodeParserTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/BytecodeParserTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/DebugInfoBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/DebugInfoBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/DebugInfoBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/DebugInfoBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/InstructionPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/InstructionPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/InstructionPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/InstructionPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/NodeLIRBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/NodeLIRBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/NodeLIRBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/NodeLIRBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/NodeMatchRules.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/NodeMatchRules.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/NodeMatchRules.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/NodeMatchRules.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/package-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/package-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/gen/package-info.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/ComplexMatchResult.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/ComplexMatchResult.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/ComplexMatchResult.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/ComplexMatchResult.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/ComplexMatchValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/ComplexMatchValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/ComplexMatchValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/ComplexMatchValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchPattern.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchPattern.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchPattern.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchPattern.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRule.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRule.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRule.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRule.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRuleRegistry.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRuleRegistry.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRuleRegistry.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRuleRegistry.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRules.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRules.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRules.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchRules.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchStatement.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchStatement.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchStatement.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchStatement.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchStatementSet.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchStatementSet.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchStatementSet.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchStatementSet.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchableNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchableNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchableNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchableNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchableNodes.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchableNodes.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchableNodes.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/match/MatchableNodes.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/package-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/package-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/package-info.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/CoreCompilerConfiguration.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/CoreCompilerConfiguration.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/CoreCompilerConfiguration.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/CoreCompilerConfiguration.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyCompilerConfiguration.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyCompilerConfiguration.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyCompilerConfiguration.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyCompilerConfiguration.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyHighTier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyHighTier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyHighTier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyHighTier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyLowTier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyLowTier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyLowTier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyLowTier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyMidTier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyMidTier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyMidTier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/EconomyMidTier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/GraphChangeMonitoringPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/GraphChangeMonitoringPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/GraphChangeMonitoringPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/GraphChangeMonitoringPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/HighTier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/HighTier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/HighTier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/HighTier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/LowTier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/LowTier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/LowTier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/LowTier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/MidTier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/MidTier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/MidTier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/phases/MidTier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/target/Backend.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/target/Backend.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/target/Backend.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.core/src/org/graalvm/compiler/core/target/Backend.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/CSVUtilTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/CSVUtilTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/CSVUtilTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/CSVUtilTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/DebugHistogramTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/DebugHistogramTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/DebugHistogramTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/DebugHistogramTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/DebugTimerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/DebugTimerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/DebugTimerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug.test/src/org/graalvm/compiler/debug/test/DebugTimerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/CSVUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/CSVUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/CSVUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/CSVUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Debug.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Debug.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Debug.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Debug.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugCloseable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugCloseable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugCloseable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugCloseable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfigCustomizer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfigCustomizer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfigCustomizer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfigCustomizer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfigScope.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfigScope.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfigScope.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugConfigScope.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugCounter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugCounter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugCounter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugCounter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugDumpHandler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugDumpHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugDumpHandler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugDumpHandler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugDumpScope.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugDumpScope.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugDumpScope.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugDumpScope.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugEnvironment.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugEnvironment.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugEnvironment.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugEnvironment.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugFilter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugFilter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugFilter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugFilter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugHistogram.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugHistogram.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugHistogram.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugHistogram.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugInitializationParticipant.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugInitializationParticipant.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugInitializationParticipant.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugInitializationParticipant.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugMemUseTracker.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugMemUseTracker.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugMemUseTracker.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugMemUseTracker.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugMethodMetrics.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugMethodMetrics.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugMethodMetrics.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugMethodMetrics.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugTimer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugTimer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugTimer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugTimer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugValueFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugValueFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugValueFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugValueFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugVerifyHandler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugVerifyHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugVerifyHandler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DebugVerifyHandler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DelegatingDebugConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DelegatingDebugConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DelegatingDebugConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/DelegatingDebugConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Fingerprint.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Fingerprint.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Fingerprint.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Fingerprint.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/GraalDebugConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/GraalDebugConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/GraalDebugConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/GraalDebugConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/GraalError.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/GraalError.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/GraalError.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/GraalError.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Indent.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Indent.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Indent.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Indent.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/JavaMethodContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/JavaMethodContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/JavaMethodContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/JavaMethodContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/LogStream.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/LogStream.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/LogStream.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/LogStream.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Management.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Management.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Management.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/Management.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/MethodFilter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/MethodFilter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/MethodFilter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/MethodFilter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TTY.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TTY.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TTY.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TTY.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TTYStreamProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TTYStreamProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TTYStreamProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TTYStreamProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TimeSource.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TimeSource.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TimeSource.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TimeSource.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TopLevelDebugConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TopLevelDebugConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TopLevelDebugConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/TopLevelDebugConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/AccumulatedDebugValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/AccumulatedDebugValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/AccumulatedDebugValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/AccumulatedDebugValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/CloseableCounterImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/CloseableCounterImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/CloseableCounterImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/CloseableCounterImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/CounterImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/CounterImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/CounterImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/CounterImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramAsciiPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramAsciiPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramAsciiPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramAsciiPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramRPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramRPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramRPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugHistogramRPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugScope.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugScope.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugScope.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugScope.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValueMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValueMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValueMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValueMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValuesPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValuesPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValuesPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/DebugValuesPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/KeyRegistry.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/KeyRegistry.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/KeyRegistry.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/KeyRegistry.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/MemUseTrackerImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/MemUseTrackerImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/MemUseTrackerImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/MemUseTrackerImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/TimerImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/TimerImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/TimerImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/TimerImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsInlineeScopeInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsInlineeScopeInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsInlineeScopeInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsInlineeScopeInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsRootScopeInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsRootScopeInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsRootScopeInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.debug/src/org/graalvm/compiler/debug/internal/method/MethodMetricsRootScopeInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeMapTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeMapTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeMapTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeMapTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeUsagesTests.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeUsagesTests.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeUsagesTests.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeUsagesTests.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeValidationChecksTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeValidationChecksTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeValidationChecksTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/NodeValidationChecksTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TestNodeInterface.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TestNodeInterface.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TestNodeInterface.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TestNodeInterface.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TypedNodeIteratorTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TypedNodeIteratorTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TypedNodeIteratorTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TypedNodeIteratorTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TypedNodeIteratorTest2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TypedNodeIteratorTest2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TypedNodeIteratorTest2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/TypedNodeIteratorTest2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableContains.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableContains.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableContains.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableContains.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableCount.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableCount.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableCount.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableCount.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableIsEmpty.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableIsEmpty.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableIsEmpty.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph.test/src/org/graalvm/compiler/graph/test/matchers/NodeIterableIsEmpty.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/.checkstyle_checks.xml b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/.checkstyle_checks.xml
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/.checkstyle_checks.xml
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/.checkstyle_checks.xml
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/CachedGraph.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/CachedGraph.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/CachedGraph.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/CachedGraph.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/DefaultNodeCollectionsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/DefaultNodeCollectionsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/DefaultNodeCollectionsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/DefaultNodeCollectionsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Edges.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Edges.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Edges.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Edges.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/GraalGraphError.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/GraalGraphError.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/GraalGraphError.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/GraalGraphError.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Graph.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Graph.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Graph.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Graph.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/GraphNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/GraphNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/GraphNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/GraphNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/InputEdges.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/InputEdges.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/InputEdges.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/InputEdges.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/IterableNodeType.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/IterableNodeType.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/IterableNodeType.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/IterableNodeType.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Node.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Node.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Node.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Node.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeBitMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeBitMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeBitMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeBitMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeClass.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeClass.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeClass.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeClass.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeCollectionsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeCollectionsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeCollectionsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeCollectionsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeFlood.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeFlood.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeFlood.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeFlood.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeIdAccessor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeIdAccessor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeIdAccessor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeIdAccessor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeInputList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeInputList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeInputList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeInputList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeInterface.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeInterface.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeInterface.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeInterface.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeNodeMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeNodeMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeNodeMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeNodeMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeSourcePosition.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeSourcePosition.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeSourcePosition.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeSourcePosition.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeStack.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeStack.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeStack.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeStack.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeSuccessorList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeSuccessorList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeSuccessorList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeSuccessorList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUnionFind.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUnionFind.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUnionFind.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUnionFind.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageIterable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageIterable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageIterable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageIterable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageWithModCountIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageWithModCountIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageWithModCountIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeUsageWithModCountIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeWorkList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeWorkList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeWorkList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/NodeWorkList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Position.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Position.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Position.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/Position.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/SuccessorEdges.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/SuccessorEdges.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/SuccessorEdges.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/SuccessorEdges.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/TypedGraphNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/TypedGraphNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/TypedGraphNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/TypedGraphNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/UnsafeAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/UnsafeAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/UnsafeAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/UnsafeAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/VerificationError.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/VerificationError.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/VerificationError.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/VerificationError.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/FilteredNodeIterable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/FilteredNodeIterable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/FilteredNodeIterable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/FilteredNodeIterable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodeIterable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodeIterable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodeIterable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodeIterable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodePredicate.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodePredicate.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodePredicate.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodePredicate.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodePredicates.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodePredicates.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodePredicates.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/NodePredicates.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/PredicatedProxyNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/PredicatedProxyNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/PredicatedProxyNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/iterators/PredicatedProxyNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/package-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/package-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/package-info.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/Canonicalizable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/Canonicalizable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/Canonicalizable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/Canonicalizable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/CanonicalizerTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/CanonicalizerTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/CanonicalizerTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/CanonicalizerTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/Simplifiable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/Simplifiable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/Simplifiable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/Simplifiable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/SimplifierTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/SimplifierTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/SimplifierTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.graph/src/org/graalvm/compiler/graph/spi/SimplifierTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotBackend.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotBackend.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotBackend.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotBackend.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotBackendFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotBackendFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotBackendFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotBackendFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotCRuntimeCallEpilogueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotCRuntimeCallEpilogueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotCRuntimeCallEpilogueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotCRuntimeCallEpilogueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotCRuntimeCallPrologueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotCRuntimeCallPrologueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotCRuntimeCallPrologueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotCRuntimeCallPrologueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDeoptimizeCallerOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDeoptimizeCallerOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDeoptimizeCallerOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDeoptimizeCallerOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDeoptimizeOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDeoptimizeOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDeoptimizeOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDeoptimizeOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDirectStaticCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDirectStaticCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDirectStaticCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDirectStaticCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDirectVirtualCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDirectVirtualCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDirectVirtualCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotDirectVirtualCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotEpilogueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotEpilogueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotEpilogueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotEpilogueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotForeignCallsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotForeignCallsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotForeignCallsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotForeignCallsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotJumpToExceptionHandlerInCallerOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotJumpToExceptionHandlerInCallerOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotJumpToExceptionHandlerInCallerOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotJumpToExceptionHandlerInCallerOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLIRKindTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLIRKindTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLIRKindTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLIRKindTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLoweringProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLoweringProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLoweringProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotLoweringProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotMove.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotMove.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotMove.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotMove.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotMoveFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotMoveFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotMoveFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotMoveFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotNodeLIRBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotNodeLIRBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotNodeLIRBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotNodeLIRBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotPatchReturnAddressOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotPatchReturnAddressOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotPatchReturnAddressOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotPatchReturnAddressOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotRegisterAllocationConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotRegisterAllocationConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotRegisterAllocationConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotRegisterAllocationConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotReturnOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotReturnOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotReturnOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotReturnOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotSafepointOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotSafepointOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotSafepointOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotSafepointOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotStrategySwitchOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotStrategySwitchOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotStrategySwitchOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotStrategySwitchOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotUnwindOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotUnwindOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotUnwindOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64HotSpotUnwindOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64IndirectCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64IndirectCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64IndirectCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArch64IndirectCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArchHotSpotNodeCostProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArchHotSpotNodeCostProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArchHotSpotNodeCostProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.aarch64/src/org/graalvm/compiler/hotspot/aarch64/AArchHotSpotNodeCostProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/AMD64HotSpotFrameOmissionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/AMD64HotSpotFrameOmissionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/AMD64HotSpotFrameOmissionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/AMD64HotSpotFrameOmissionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/CompressedNullCheckTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/CompressedNullCheckTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/CompressedNullCheckTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/CompressedNullCheckTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/DataPatchInConstantsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/DataPatchInConstantsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/DataPatchInConstantsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/DataPatchInConstantsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/StubAVXTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/StubAVXTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/StubAVXTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64.test/src/org/graalvm/compiler/hotspot/amd64/test/StubAVXTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64DeoptimizationStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64DeoptimizationStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64DeoptimizationStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64DeoptimizationStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64DeoptimizeOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64DeoptimizeOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64DeoptimizeOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64DeoptimizeOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotAddressLowering.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotAddressLowering.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotAddressLowering.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotAddressLowering.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotArithmeticLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotArithmeticLIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotArithmeticLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotArithmeticLIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotBackend.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotBackend.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotBackend.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotBackend.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotBackendFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotBackendFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotBackendFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotBackendFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCRuntimeCallEpilogueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCRuntimeCallEpilogueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCRuntimeCallEpilogueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCRuntimeCallEpilogueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCRuntimeCallPrologueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCRuntimeCallPrologueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCRuntimeCallPrologueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCRuntimeCallPrologueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotConstantRetrievalOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotConstantRetrievalOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotConstantRetrievalOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotConstantRetrievalOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCounterOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCounterOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCounterOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotCounterOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotDeoptimizeCallerOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotDeoptimizeCallerOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotDeoptimizeCallerOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotDeoptimizeCallerOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotDirectStaticCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotDirectStaticCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotDirectStaticCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotDirectStaticCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEnterUnpackFramesStackFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEnterUnpackFramesStackFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEnterUnpackFramesStackFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEnterUnpackFramesStackFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEpilogueBlockEndOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEpilogueBlockEndOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEpilogueBlockEndOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEpilogueBlockEndOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEpilogueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEpilogueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEpilogueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotEpilogueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotForeignCallsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotForeignCallsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotForeignCallsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotForeignCallsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotJumpToExceptionHandlerInCallerOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotJumpToExceptionHandlerInCallerOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotJumpToExceptionHandlerInCallerOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotJumpToExceptionHandlerInCallerOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRGenerator.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRGenerator.java
index 850faa1c525..bd87349a2d4 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRGenerator.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRGenerator.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -497,9 +497,8 @@ public class AMD64HotSpotLIRGenerator extends AMD64LIRGenerator implements HotSp
     }
 
     @Override
-    public Value emitLoadConfigValue(int markId) {
-        // Globals are always full-pointer width.
-        Variable result = newVariable(LIRKind.value(target().arch.getWordKind()));
+    public Value emitLoadConfigValue(int markId, LIRKind kind) {
+        Variable result = newVariable(kind);
         append(new AMD64HotSpotLoadConfigValueOp(markId, result));
         return result;
     }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRKindTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRKindTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRKindTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLIRKindTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveCurrentStackFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveCurrentStackFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveCurrentStackFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveCurrentStackFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveDeoptimizedStackFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveDeoptimizedStackFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveDeoptimizedStackFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveDeoptimizedStackFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveUnpackFramesStackFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveUnpackFramesStackFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveUnpackFramesStackFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLeaveUnpackFramesStackFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadAddressOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadAddressOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadAddressOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadAddressOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadConfigValueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadConfigValueOp.java
similarity index 70%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadConfigValueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadConfigValueOp.java
index 28e2c0d6ba6..24b11237bda 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadConfigValueOp.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoadConfigValueOp.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -24,8 +24,12 @@ package org.graalvm.compiler.hotspot.amd64;
 
 import static org.graalvm.compiler.core.common.GraalOptions.GeneratePIC;
 import static jdk.vm.ci.code.ValueUtil.asRegister;
+
+import jdk.vm.ci.amd64.AMD64Kind;
+import jdk.vm.ci.code.Register;
 import jdk.vm.ci.meta.AllocatableValue;
 
+import org.graalvm.compiler.asm.amd64.AMD64Address;
 import org.graalvm.compiler.asm.amd64.AMD64MacroAssembler;
 import org.graalvm.compiler.debug.GraalError;
 import org.graalvm.compiler.lir.LIRInstructionClass;
@@ -48,7 +52,25 @@ public final class AMD64HotSpotLoadConfigValueOp extends AMD64LIRInstruction {
     @Override
     public void emitCode(CompilationResultBuilder crb, AMD64MacroAssembler masm) {
         if (GeneratePIC.getValue()) {
-            masm.movq(asRegister(result), masm.getPlaceholder(-1));
+            AMD64Kind kind = (AMD64Kind) result.getPlatformKind();
+            Register reg = asRegister(result);
+            AMD64Address placeholder = masm.getPlaceholder(-1);
+            switch (kind) {
+                case BYTE:
+                    masm.movsbl(reg, placeholder);
+                    break;
+                case WORD:
+                    masm.movswl(reg, placeholder);
+                    break;
+                case DWORD:
+                    masm.movl(reg, placeholder);
+                    break;
+                case QWORD:
+                    masm.movq(reg, placeholder);
+                    break;
+                default:
+                    throw GraalError.unimplemented();
+            }
         } else {
             throw GraalError.unimplemented();
         }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoweringProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoweringProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoweringProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotLoweringProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMathIntrinsicOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMathIntrinsicOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMathIntrinsicOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMathIntrinsicOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMove.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMove.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMove.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMove.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMoveFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMoveFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMoveFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotMoveFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotNodeCostProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotNodeCostProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotNodeCostProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotNodeCostProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotNodeLIRBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotNodeLIRBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotNodeLIRBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotNodeLIRBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotPatchReturnAddressOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotPatchReturnAddressOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotPatchReturnAddressOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotPatchReturnAddressOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotPushInterpreterFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotPushInterpreterFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotPushInterpreterFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotPushInterpreterFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotRegisterAllocationConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotRegisterAllocationConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotRegisterAllocationConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotRegisterAllocationConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotRestoreRbpOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotRestoreRbpOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotRestoreRbpOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotRestoreRbpOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotReturnOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotReturnOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotReturnOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotReturnOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotSafepointOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotSafepointOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotSafepointOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotSafepointOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotStrategySwitchOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotStrategySwitchOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotStrategySwitchOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotStrategySwitchOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotSuitesProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotSuitesProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotSuitesProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotSuitesProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotUnwindOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotUnwindOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotUnwindOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotSpotUnwindOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotspotDirectVirtualCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotspotDirectVirtualCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotspotDirectVirtualCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64HotspotDirectVirtualCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64IndirectCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64IndirectCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64IndirectCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64IndirectCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64MathStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64MathStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64MathStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64MathStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64RawNativeCallNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64RawNativeCallNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64RawNativeCallNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64RawNativeCallNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64TailcallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64TailcallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64TailcallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64TailcallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64UncommonTrapStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64UncommonTrapStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64UncommonTrapStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.amd64/src/org/graalvm/compiler/hotspot/amd64/AMD64UncommonTrapStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.lir.test/src/org/graalvm/compiler/hotspot/lir/test/ExceedMaxOopMapStackOffset.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.lir.test/src/org/graalvm/compiler/hotspot/lir/test/ExceedMaxOopMapStackOffset.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.lir.test/src/org/graalvm/compiler/hotspot/lir/test/ExceedMaxOopMapStackOffset.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.lir.test/src/org/graalvm/compiler/hotspot/lir/test/ExceedMaxOopMapStackOffset.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCDeoptimizationStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCDeoptimizationStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCDeoptimizationStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCDeoptimizationStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCDeoptimizeOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCDeoptimizeOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCDeoptimizeOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCDeoptimizeOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotBackend.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotBackend.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotBackend.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotBackend.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotBackendFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotBackendFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotBackendFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotBackendFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCRuntimeCallEpilogueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCRuntimeCallEpilogueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCRuntimeCallEpilogueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCRuntimeCallEpilogueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCRuntimeCallPrologueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCRuntimeCallPrologueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCRuntimeCallPrologueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCRuntimeCallPrologueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCounterOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCounterOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCounterOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotCounterOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotDeoptimizeCallerOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotDeoptimizeCallerOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotDeoptimizeCallerOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotDeoptimizeCallerOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotEnterUnpackFramesStackFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotEnterUnpackFramesStackFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotEnterUnpackFramesStackFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotEnterUnpackFramesStackFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotEpilogueOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotEpilogueOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotEpilogueOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotEpilogueOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotForeignCallsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotForeignCallsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotForeignCallsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotForeignCallsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotJumpToExceptionHandlerInCallerOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotJumpToExceptionHandlerInCallerOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotJumpToExceptionHandlerInCallerOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotJumpToExceptionHandlerInCallerOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotJumpToExceptionHandlerOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotJumpToExceptionHandlerOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotJumpToExceptionHandlerOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotJumpToExceptionHandlerOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLIRKindTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLIRKindTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLIRKindTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLIRKindTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveCurrentStackFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveCurrentStackFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveCurrentStackFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveCurrentStackFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveDeoptimizedStackFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveDeoptimizedStackFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveDeoptimizedStackFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveDeoptimizedStackFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveUnpackFramesStackFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveUnpackFramesStackFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveUnpackFramesStackFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLeaveUnpackFramesStackFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLoweringProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLoweringProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLoweringProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotLoweringProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotMove.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotMove.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotMove.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotMove.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotMoveFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotMoveFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotMoveFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotMoveFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotNodeCostProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotNodeCostProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotNodeCostProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotNodeCostProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotNodeLIRBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotNodeLIRBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotNodeLIRBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotNodeLIRBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotPatchReturnAddressOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotPatchReturnAddressOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotPatchReturnAddressOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotPatchReturnAddressOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotPushInterpreterFrameOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotPushInterpreterFrameOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotPushInterpreterFrameOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotPushInterpreterFrameOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotRegisterAllocationConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotRegisterAllocationConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotRegisterAllocationConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotRegisterAllocationConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotReturnOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotReturnOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotReturnOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotReturnOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotSafepointOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotSafepointOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotSafepointOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotSafepointOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotStrategySwitchOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotStrategySwitchOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotStrategySwitchOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotStrategySwitchOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotUnwindOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotUnwindOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotUnwindOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotSpotUnwindOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotspotDirectStaticCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotspotDirectStaticCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotspotDirectStaticCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotspotDirectStaticCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotspotDirectVirtualCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotspotDirectVirtualCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotspotDirectVirtualCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCHotspotDirectVirtualCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCIndirectCallOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCIndirectCallOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCIndirectCallOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCIndirectCallOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCUncommonTrapStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCUncommonTrapStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCUncommonTrapStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.sparc/src/org/graalvm/compiler/hotspot/sparc/SPARCUncommonTrapStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/AheadOfTimeCompilationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/AheadOfTimeCompilationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/AheadOfTimeCompilationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/AheadOfTimeCompilationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ArrayCopyIntrinsificationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ArrayCopyIntrinsificationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ArrayCopyIntrinsificationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ArrayCopyIntrinsificationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CRC32SubstitutionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CRC32SubstitutionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CRC32SubstitutionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CRC32SubstitutionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CheckGraalIntrinsics.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CheckGraalIntrinsics.java
similarity index 89%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CheckGraalIntrinsics.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CheckGraalIntrinsics.java
index 42d4dd453c4..9a73893a4f5 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CheckGraalIntrinsics.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CheckGraalIntrinsics.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -29,15 +29,12 @@ import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collection;
 import java.util.Collections;
-import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
 import java.util.TreeSet;
 import java.util.stream.Collectors;
 
-import org.junit.Test;
-
 import org.graalvm.compiler.api.test.Graal;
 import org.graalvm.compiler.hotspot.GraalHotSpotVMConfig;
 import org.graalvm.compiler.hotspot.HotSpotGraalRuntimeProvider;
@@ -45,12 +42,15 @@ import org.graalvm.compiler.hotspot.meta.HotSpotProviders;
 import org.graalvm.compiler.nodes.graphbuilderconf.GraphBuilderConfiguration.Plugins;
 import org.graalvm.compiler.nodes.graphbuilderconf.InvocationPlugin;
 import org.graalvm.compiler.nodes.graphbuilderconf.InvocationPlugins;
+import org.graalvm.compiler.nodes.graphbuilderconf.InvocationPlugins.Binding;
 import org.graalvm.compiler.runtime.RuntimeProvider;
 import org.graalvm.compiler.test.GraalTest;
+import org.junit.Test;
 
 import jdk.vm.ci.hotspot.HotSpotVMConfigStore;
 import jdk.vm.ci.hotspot.VMIntrinsicMethod;
 import jdk.vm.ci.meta.MetaAccessProvider;
+import jdk.vm.ci.meta.MetaUtil;
 import jdk.vm.ci.meta.MethodHandleAccessProvider.IntrinsicMethod;
 import jdk.vm.ci.meta.ResolvedJavaMethod;
 
@@ -63,11 +63,10 @@ import jdk.vm.ci.meta.ResolvedJavaMethod;
  */
 public class CheckGraalIntrinsics extends GraalTest {
 
-    public static boolean match(ResolvedJavaMethod method, VMIntrinsicMethod intrinsic) {
-        if (intrinsic.name.equals(method.getName())) {
-            if (intrinsic.descriptor.equals(method.getSignature().toMethodDescriptor())) {
-                String declaringClass = method.getDeclaringClass().toClassName().replace('.', '/');
-                if (declaringClass.equals(intrinsic.declaringClass)) {
+    public static boolean match(String type, Binding binding, VMIntrinsicMethod intrinsic) {
+        if (intrinsic.name.equals(binding.name)) {
+            if (intrinsic.descriptor.startsWith(binding.argumentsDescriptor)) {
+                if (type.equals(intrinsic.declaringClass)) {
                     return true;
                 }
             }
@@ -75,16 +74,20 @@ public class CheckGraalIntrinsics extends GraalTest {
         return false;
     }
 
-    private static ResolvedJavaMethod findMethod(Set methods, VMIntrinsicMethod intrinsic) {
-        for (ResolvedJavaMethod method : methods) {
-            if (match(method, intrinsic)) {
-                return method;
+    public static InvocationPlugin findPlugin(Map> bindings, VMIntrinsicMethod intrinsic) {
+        for (Map.Entry> e : bindings.entrySet()) {
+            // Match format of VMIntrinsicMethod.declaringClass
+            String type = MetaUtil.internalNameToJava(e.getKey(), true, false).replace('.', '/');
+            for (Binding binding : e.getValue()) {
+                if (match(type, binding, intrinsic)) {
+                    return binding.plugin;
+                }
             }
         }
         return null;
     }
 
-    private static ResolvedJavaMethod resolveIntrinsic(MetaAccessProvider metaAccess, VMIntrinsicMethod intrinsic) throws ClassNotFoundException {
+    public static ResolvedJavaMethod resolveIntrinsic(MetaAccessProvider metaAccess, VMIntrinsicMethod intrinsic) throws ClassNotFoundException {
         Class c = Class.forName(intrinsic.declaringClass.replace('/', '.'), false, CheckGraalIntrinsics.class.getClassLoader());
         for (Method javaMethod : c.getDeclaredMethods()) {
             if (javaMethod.getName().equals(intrinsic.name)) {
@@ -243,21 +246,21 @@ public class CheckGraalIntrinsics extends GraalTest {
                         "jdk/internal/misc/Unsafe.allocateUninitializedArray0(Ljava/lang/Class;I)Ljava/lang/Object;",
                         "jdk/internal/misc/Unsafe.compareAndExchangeByteAcquire(Ljava/lang/Object;JBB)B",
                         "jdk/internal/misc/Unsafe.compareAndExchangeByteRelease(Ljava/lang/Object;JBB)B",
-                        "jdk/internal/misc/Unsafe.compareAndExchangeByteVolatile(Ljava/lang/Object;JBB)B",
+                        "jdk/internal/misc/Unsafe.compareAndExchangeByte(Ljava/lang/Object;JBB)B",
                         "jdk/internal/misc/Unsafe.compareAndExchangeIntAcquire(Ljava/lang/Object;JII)I",
                         "jdk/internal/misc/Unsafe.compareAndExchangeIntRelease(Ljava/lang/Object;JII)I",
-                        "jdk/internal/misc/Unsafe.compareAndExchangeIntVolatile(Ljava/lang/Object;JII)I",
+                        "jdk/internal/misc/Unsafe.compareAndExchangeInt(Ljava/lang/Object;JII)I",
                         "jdk/internal/misc/Unsafe.compareAndExchangeLongAcquire(Ljava/lang/Object;JJJ)J",
                         "jdk/internal/misc/Unsafe.compareAndExchangeLongRelease(Ljava/lang/Object;JJJ)J",
-                        "jdk/internal/misc/Unsafe.compareAndExchangeLongVolatile(Ljava/lang/Object;JJJ)J",
+                        "jdk/internal/misc/Unsafe.compareAndExchangeLong(Ljava/lang/Object;JJJ)J",
                         "jdk/internal/misc/Unsafe.compareAndExchangeObjectAcquire(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;",
                         "jdk/internal/misc/Unsafe.compareAndExchangeObjectRelease(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;",
-                        "jdk/internal/misc/Unsafe.compareAndExchangeObjectVolatile(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;",
+                        "jdk/internal/misc/Unsafe.compareAndExchangeObject(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;",
                         "jdk/internal/misc/Unsafe.compareAndExchangeShortAcquire(Ljava/lang/Object;JSS)S",
                         "jdk/internal/misc/Unsafe.compareAndExchangeShortRelease(Ljava/lang/Object;JSS)S",
-                        "jdk/internal/misc/Unsafe.compareAndExchangeShortVolatile(Ljava/lang/Object;JSS)S",
-                        "jdk/internal/misc/Unsafe.compareAndSwapByte(Ljava/lang/Object;JBB)Z",
-                        "jdk/internal/misc/Unsafe.compareAndSwapShort(Ljava/lang/Object;JSS)Z",
+                        "jdk/internal/misc/Unsafe.compareAndExchangeShort(Ljava/lang/Object;JSS)S",
+                        "jdk/internal/misc/Unsafe.compareAndSetByte(Ljava/lang/Object;JBB)Z",
+                        "jdk/internal/misc/Unsafe.compareAndSetShort(Ljava/lang/Object;JSS)Z",
                         "jdk/internal/misc/Unsafe.copyMemory0(Ljava/lang/Object;JLjava/lang/Object;JJ)V",
                         "jdk/internal/misc/Unsafe.getAndAddByte(Ljava/lang/Object;JB)B",
                         "jdk/internal/misc/Unsafe.getAndAddShort(Ljava/lang/Object;JS)S",
@@ -292,26 +295,26 @@ public class CheckGraalIntrinsics extends GraalTest {
                         "jdk/internal/misc/Unsafe.putObjectOpaque(Ljava/lang/Object;JLjava/lang/Object;)V",
                         "jdk/internal/misc/Unsafe.putShortOpaque(Ljava/lang/Object;JS)V",
                         "jdk/internal/misc/Unsafe.unpark(Ljava/lang/Object;)V",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapByte(Ljava/lang/Object;JBB)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapByteAcquire(Ljava/lang/Object;JBB)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapByteRelease(Ljava/lang/Object;JBB)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapByteVolatile(Ljava/lang/Object;JBB)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapInt(Ljava/lang/Object;JII)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapIntAcquire(Ljava/lang/Object;JII)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapIntRelease(Ljava/lang/Object;JII)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapIntVolatile(Ljava/lang/Object;JII)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapLong(Ljava/lang/Object;JJJ)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapLongAcquire(Ljava/lang/Object;JJJ)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapLongRelease(Ljava/lang/Object;JJJ)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapLongVolatile(Ljava/lang/Object;JJJ)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapObject(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapObjectAcquire(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapObjectRelease(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapObjectVolatile(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapShort(Ljava/lang/Object;JSS)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapShortAcquire(Ljava/lang/Object;JSS)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapShortRelease(Ljava/lang/Object;JSS)Z",
-                        "jdk/internal/misc/Unsafe.weakCompareAndSwapShortVolatile(Ljava/lang/Object;JSS)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetBytePlain(Ljava/lang/Object;JBB)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetByteAcquire(Ljava/lang/Object;JBB)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetByteRelease(Ljava/lang/Object;JBB)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetByte(Ljava/lang/Object;JBB)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetIntPlain(Ljava/lang/Object;JII)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetIntAcquire(Ljava/lang/Object;JII)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetIntRelease(Ljava/lang/Object;JII)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetInt(Ljava/lang/Object;JII)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetLongPlain(Ljava/lang/Object;JJJ)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetLongAcquire(Ljava/lang/Object;JJJ)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetLongRelease(Ljava/lang/Object;JJJ)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetLong(Ljava/lang/Object;JJJ)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetObjectPlain(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetObjectAcquire(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetObjectRelease(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetObject(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetShortPlain(Ljava/lang/Object;JSS)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetShortAcquire(Ljava/lang/Object;JSS)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetShortRelease(Ljava/lang/Object;JSS)Z",
+                        "jdk/internal/misc/Unsafe.weakCompareAndSetShort(Ljava/lang/Object;JSS)Z",
                         "jdk/internal/util/Preconditions.checkIndex(IILjava/util/function/BiFunction;)I",
                         "jdk/jfr/internal/JVM.counterTime()J",
                         "jdk/jfr/internal/JVM.getBufferWriter()Ljava/lang/Object;",
@@ -425,28 +428,20 @@ public class CheckGraalIntrinsics extends GraalTest {
     public void test() throws ClassNotFoundException {
         HotSpotGraalRuntimeProvider rt = (HotSpotGraalRuntimeProvider) Graal.getRequiredCapability(RuntimeProvider.class);
         HotSpotProviders providers = rt.getHostBackend().getProviders();
-        Map impl = new HashMap<>();
         Plugins graphBuilderPlugins = providers.getGraphBuilderPlugins();
         InvocationPlugins invocationPlugins = graphBuilderPlugins.getInvocationPlugins();
-        for (ResolvedJavaMethod method : invocationPlugins.getMethods()) {
-            InvocationPlugin plugin = invocationPlugins.lookupInvocation(method);
-            assert plugin != null;
-            impl.put(method, plugin);
-        }
 
-        Set methods = invocationPlugins.getMethods();
         HotSpotVMConfigStore store = rt.getVMConfig().getStore();
         List intrinsics = store.getIntrinsics();
 
         List missing = new ArrayList<>();
+        Map> bindings = invocationPlugins.getBindings(true);
         for (VMIntrinsicMethod intrinsic : intrinsics) {
-            ResolvedJavaMethod method = findMethod(methods, intrinsic);
-            if (method == null) {
-                method = resolveIntrinsic(providers.getMetaAccess(), intrinsic);
-
-                IntrinsicMethod intrinsicMethod = null;
+            InvocationPlugin plugin = findPlugin(bindings, intrinsic);
+            if (plugin == null) {
+                ResolvedJavaMethod method = resolveIntrinsic(providers.getMetaAccess(), intrinsic);
                 if (method != null) {
-                    intrinsicMethod = providers.getConstantReflection().getMethodHandleAccess().lookupMethodHandleIntrinsic(method);
+                    IntrinsicMethod intrinsicMethod = providers.getConstantReflection().getMethodHandleAccess().lookupMethodHandleIntrinsic(method);
                     if (intrinsicMethod != null) {
                         continue;
                     }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ClassSubstitutionsTests.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ClassSubstitutionsTests.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ClassSubstitutionsTests.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ClassSubstitutionsTests.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CompileTheWorldTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CompileTheWorldTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CompileTheWorldTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CompileTheWorldTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CompressedOopTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CompressedOopTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CompressedOopTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/CompressedOopTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ConstantPoolSubstitutionsTests.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ConstantPoolSubstitutionsTests.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ConstantPoolSubstitutionsTests.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ConstantPoolSubstitutionsTests.java
index 2585d36f861..3edc637a362 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ConstantPoolSubstitutionsTests.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ConstantPoolSubstitutionsTests.java
@@ -39,9 +39,9 @@ import org.graalvm.compiler.nodes.StructuredGraph.AllowAssumptions;
 import org.junit.BeforeClass;
 import org.junit.Test;
 
-import jdk.internal.org.objectweb.asm.ClassWriter;
-import jdk.internal.org.objectweb.asm.MethodVisitor;
-import jdk.internal.org.objectweb.asm.Opcodes;
+import org.objectweb.asm.ClassWriter;
+import org.objectweb.asm.MethodVisitor;
+import org.objectweb.asm.Opcodes;
 import jdk.vm.ci.meta.ResolvedJavaMethod;
 
 public class ConstantPoolSubstitutionsTests extends GraalCompilerTest implements Opcodes {
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/DataPatchTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/DataPatchTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/DataPatchTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/DataPatchTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ExplicitExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ExplicitExceptionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ExplicitExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ExplicitExceptionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ForeignCallDeoptimizeTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ForeignCallDeoptimizeTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ForeignCallDeoptimizeTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ForeignCallDeoptimizeTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRLockTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRLockTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRLockTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRLockTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRTestBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRTestBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRTestBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/GraalOSRTestBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotCryptoSubstitutionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotCryptoSubstitutionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotCryptoSubstitutionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotCryptoSubstitutionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotGraalCompilerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotGraalCompilerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotGraalCompilerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotGraalCompilerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotMethodSubstitutionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotMethodSubstitutionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotMethodSubstitutionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotMethodSubstitutionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotMonitorValueTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotMonitorValueTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotMonitorValueTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotMonitorValueTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotNmethodTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotNmethodTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotNmethodTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotNmethodTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotNodeSubstitutionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotNodeSubstitutionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotNodeSubstitutionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotNodeSubstitutionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotResolvedJavaFieldTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotResolvedJavaFieldTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotResolvedJavaFieldTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotResolvedJavaFieldTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotResolvedObjectTypeTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotResolvedObjectTypeTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotResolvedObjectTypeTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/HotSpotResolvedObjectTypeTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/InstalledCodeExecuteHelperTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/InstalledCodeExecuteHelperTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/InstalledCodeExecuteHelperTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/InstalledCodeExecuteHelperTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/JVMCIInfopointErrorTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/JVMCIInfopointErrorTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/JVMCIInfopointErrorTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/JVMCIInfopointErrorTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/LoadJavaMirrorWithKlassTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/LoadJavaMirrorWithKlassTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/LoadJavaMirrorWithKlassTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/LoadJavaMirrorWithKlassTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/MemoryUsageBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/MemoryUsageBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/MemoryUsageBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/MemoryUsageBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestIntrinsicCompiles.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestIntrinsicCompiles.java
similarity index 66%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestIntrinsicCompiles.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestIntrinsicCompiles.java
index 3185b44d826..0333f9a973f 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestIntrinsicCompiles.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestIntrinsicCompiles.java
@@ -22,13 +22,12 @@
  */
 package org.graalvm.compiler.hotspot.test;
 
-import java.util.List;
-import java.util.Set;
+import static org.graalvm.compiler.core.common.CompilationIdentifier.INVALID_COMPILATION_ID;
 
-import org.junit.Test;
+import java.util.List;
+import java.util.Map;
 
 import org.graalvm.compiler.api.test.Graal;
-import org.graalvm.compiler.core.common.CompilationIdentifier;
 import org.graalvm.compiler.core.test.GraalCompilerTest;
 import org.graalvm.compiler.hotspot.HotSpotGraalCompiler;
 import org.graalvm.compiler.hotspot.HotSpotGraalRuntimeProvider;
@@ -37,8 +36,10 @@ import org.graalvm.compiler.nodes.StructuredGraph;
 import org.graalvm.compiler.nodes.graphbuilderconf.GraphBuilderConfiguration.Plugins;
 import org.graalvm.compiler.nodes.graphbuilderconf.InvocationPlugin;
 import org.graalvm.compiler.nodes.graphbuilderconf.InvocationPlugins;
+import org.graalvm.compiler.nodes.graphbuilderconf.InvocationPlugins.Binding;
 import org.graalvm.compiler.nodes.graphbuilderconf.MethodSubstitutionPlugin;
 import org.graalvm.compiler.runtime.RuntimeProvider;
+import org.junit.Test;
 
 import jdk.vm.ci.hotspot.HotSpotVMConfigStore;
 import jdk.vm.ci.hotspot.VMIntrinsicMethod;
@@ -50,46 +51,27 @@ import jdk.vm.ci.runtime.JVMCI;
  */
 public class TestIntrinsicCompiles extends GraalCompilerTest {
 
-    private static boolean match(ResolvedJavaMethod method, VMIntrinsicMethod intrinsic) {
-        if (intrinsic.name.equals(method.getName())) {
-            if (intrinsic.descriptor.equals(method.getSignature().toMethodDescriptor())) {
-                String declaringClass = method.getDeclaringClass().toClassName().replace('.', '/');
-                if (declaringClass.equals(intrinsic.declaringClass)) {
-                    return true;
-                }
-            }
-        }
-        return false;
-    }
-
-    private static ResolvedJavaMethod findMethod(Set methods, VMIntrinsicMethod intrinsic) {
-        for (ResolvedJavaMethod method : methods) {
-            if (match(method, intrinsic)) {
-                return method;
-            }
-        }
-        return null;
-    }
-
     @Test
     @SuppressWarnings("try")
-    public void test() {
+    public void test() throws ClassNotFoundException {
         HotSpotGraalCompiler compiler = (HotSpotGraalCompiler) JVMCI.getRuntime().getCompiler();
         HotSpotGraalRuntimeProvider rt = (HotSpotGraalRuntimeProvider) Graal.getRequiredCapability(RuntimeProvider.class);
         HotSpotProviders providers = rt.getHostBackend().getProviders();
         Plugins graphBuilderPlugins = providers.getGraphBuilderPlugins();
         InvocationPlugins invocationPlugins = graphBuilderPlugins.getInvocationPlugins();
 
-        Set pluginMethods = invocationPlugins.getMethods();
+        Map> bindings = invocationPlugins.getBindings(true);
         HotSpotVMConfigStore store = rt.getVMConfig().getStore();
         List intrinsics = store.getIntrinsics();
         for (VMIntrinsicMethod intrinsic : intrinsics) {
-            ResolvedJavaMethod method = findMethod(pluginMethods, intrinsic);
-            if (method != null) {
-                InvocationPlugin plugin = invocationPlugins.lookupInvocation(method);
-                if (plugin instanceof MethodSubstitutionPlugin && !method.isNative()) {
-                    StructuredGraph graph = compiler.getIntrinsicGraph(method, providers, CompilationIdentifier.INVALID_COMPILATION_ID);
-                    getCode(method, graph);
+            InvocationPlugin plugin = CheckGraalIntrinsics.findPlugin(bindings, intrinsic);
+            if (plugin != null) {
+                if (plugin instanceof MethodSubstitutionPlugin) {
+                    ResolvedJavaMethod method = CheckGraalIntrinsics.resolveIntrinsic(getMetaAccess(), intrinsic);
+                    if (!method.isNative()) {
+                        StructuredGraph graph = compiler.getIntrinsicGraph(method, providers, INVALID_COMPILATION_ID);
+                        getCode(method, graph);
+                    }
                 }
             }
         }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestSHASubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestSHASubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestSHASubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/TestSHASubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/WriteBarrierAdditionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/WriteBarrierAdditionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/WriteBarrierAdditionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/WriteBarrierAdditionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/WriteBarrierVerificationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/WriteBarrierVerificationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/WriteBarrierVerificationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/WriteBarrierVerificationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/AOTGraalHotSpotVMConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/AOTGraalHotSpotVMConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/AOTGraalHotSpotVMConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/AOTGraalHotSpotVMConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/BootstrapWatchDog.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/BootstrapWatchDog.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/BootstrapWatchDog.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/BootstrapWatchDog.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationCounters.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationCounters.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationCounters.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationCounters.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationStatistics.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationStatistics.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationStatistics.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationStatistics.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationTask.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationTask.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationTask.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationTask.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationWatchDog.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationWatchDog.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationWatchDog.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilationWatchDog.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorld.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorld.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorld.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorld.java
index fae52a2f352..b2542607a3f 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorld.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorld.java
@@ -102,7 +102,6 @@ import jdk.vm.ci.meta.ConstantPool;
 import jdk.vm.ci.meta.MetaAccessProvider;
 import jdk.vm.ci.runtime.JVMCI;
 import jdk.vm.ci.runtime.JVMCICompiler;
-import jdk.vm.ci.services.Services;
 
 /**
  * This class implements compile-the-world functionality with JVMCI.
@@ -785,7 +784,6 @@ public final class CompileTheWorld {
     }
 
     public static void main(String[] args) throws Throwable {
-        Services.exportJVMCITo(CompileTheWorld.class);
         HotSpotGraalCompiler compiler = (HotSpotGraalCompiler) HotSpotJVMCIRuntime.runtime().getCompiler();
         compiler.compileTheWorld();
     }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorldOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorldOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorldOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompileTheWorldOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilerConfigurationFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilerConfigurationFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilerConfigurationFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilerConfigurationFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilerRuntimeHotSpotVMConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilerRuntimeHotSpotVMConfig.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilerRuntimeHotSpotVMConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompilerRuntimeHotSpotVMConfig.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompressEncoding.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompressEncoding.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompressEncoding.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CompressEncoding.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CoreCompilerConfigurationFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CoreCompilerConfigurationFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CoreCompilerConfigurationFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/CoreCompilerConfigurationFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/EconomyCompilerConfigurationFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/EconomyCompilerConfigurationFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/EconomyCompilerConfigurationFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/EconomyCompilerConfigurationFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/FingerprintUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/FingerprintUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/FingerprintUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/FingerprintUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/GraalHotSpotVMConfig.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/GraalHotSpotVMConfig.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/GraalHotSpotVMConfig.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/GraalHotSpotVMConfig.java
index 898d688747d..40cd58ce8c2 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/GraalHotSpotVMConfig.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/GraalHotSpotVMConfig.java
@@ -244,7 +244,7 @@ public class GraalHotSpotVMConfig extends HotSpotVMConfigAccess {
         return (int) (Math.log(objectAlignment) / Math.log(2));
     }
 
-    public final int narrowKlassSize = getTypeSize("narrowKlass");
+    public final int narrowKlassSize = getFieldValue("CompilerToVM::Data::sizeof_narrowKlass", Integer.class, "int");
     public final long narrowKlassBase = getFieldValue("CompilerToVM::Data::Universe_narrow_klass_base", Long.class, "address");
     public final int narrowKlassShift = getFieldValue("CompilerToVM::Data::Universe_narrow_klass_shift", Integer.class, "int");
     public final int logKlassAlignment = getConstant("LogKlassAlignmentInBytes", Integer.class);
@@ -290,7 +290,7 @@ public class GraalHotSpotVMConfig extends HotSpotVMConfigAccess {
         return (layoutHelperArrayTagTypeValue & ~layoutHelperArrayTagObjectValue) << layoutHelperArrayTagShift;
     }
 
-    public final int vtableEntrySize = getTypeSize("vtableEntry");
+    public final int vtableEntrySize = getFieldValue("CompilerToVM::Data::sizeof_vtableEntry", Integer.class, "int");
     public final int vtableEntryMethodOffset = getFieldOffset("vtableEntry::_method", Integer.class, "Method*");
 
     public final int instanceKlassInitStateOffset = getFieldOffset("InstanceKlass::_init_state", Integer.class, "u1");
@@ -302,7 +302,7 @@ public class GraalHotSpotVMConfig extends HotSpotVMConfigAccess {
     public final int instanceKlassStateLinked = getConstant("InstanceKlass::linked", Integer.class);
     public final int instanceKlassStateFullyInitialized = getConstant("InstanceKlass::fully_initialized", Integer.class);
 
-    public final int arrayOopDescSize = getTypeSize("arrayOopDesc");
+    public final int arrayOopDescSize = getFieldValue("CompilerToVM::Data::sizeof_arrayOopDesc", Integer.class, "int");
 
     /**
      * The offset of the array length word in an array object's header.
@@ -496,7 +496,7 @@ public class GraalHotSpotVMConfig extends HotSpotVMConfigAccess {
     public final int compilationLevelFullOptimization = getConstant("CompLevel_full_optimization",
                     Integer.class);
 
-    public final int constantPoolSize = getTypeSize("ConstantPool");
+    public final int constantPoolSize = getFieldValue("CompilerToVM::Data::sizeof_ConstantPool", Integer.class, "int");
     public final int constantPoolLengthOffset = getFieldOffset("ConstantPool::_length",
                     Integer.class, "int");
 
@@ -553,7 +553,7 @@ public class GraalHotSpotVMConfig extends HotSpotVMConfigAccess {
     public final int klassOffset = getFieldValue("java_lang_Class::_klass_offset", Integer.class, "int");
     public final int arrayKlassOffset = getFieldValue("java_lang_Class::_array_klass_offset", Integer.class, "int");
 
-    public final int basicLockSize = getTypeSize("BasicLock");
+    public final int basicLockSize = getFieldValue("CompilerToVM::Data::sizeof_BasicLock", Integer.class, "int");
     public final int basicLockDisplacedHeaderOffset = getFieldOffset("BasicLock::_displaced_header", Integer.class, "markOop");
 
     public final int threadAllocatedBytesOffset = getFieldOffset("Thread::_allocated_bytes", Integer.class, "jlong");
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotBackend.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotBackend.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotBackend.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotBackend.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotBackendFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotBackendFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotBackendFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotBackendFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompilationIdentifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompilationIdentifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompilationIdentifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompilationIdentifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompiledCodeBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompiledCodeBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompiledCodeBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCompiledCodeBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCounterOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCounterOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCounterOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotCounterOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotDataBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotDataBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotDataBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotDataBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotDebugInfoBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotDebugInfoBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotDebugInfoBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotDebugInfoBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotForeignCallLinkage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotForeignCallLinkage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotForeignCallLinkage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotForeignCallLinkage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotForeignCallLinkageImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotForeignCallLinkageImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotForeignCallLinkageImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotForeignCallLinkageImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompiler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompiler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompiler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompiler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompilerFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompilerFactory.java
similarity index 92%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompilerFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompilerFactory.java
index e7ca2262368..cab5141f0ad 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompilerFactory.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalCompilerFactory.java
@@ -22,21 +22,19 @@
  */
 package org.graalvm.compiler.hotspot;
 
-import static org.graalvm.compiler.core.common.util.Util.Java8OrEarlier;
-import static org.graalvm.compiler.options.OptionValue.PROFILE_OPTIONVALUE_PROPERTY_NAME;
 import static jdk.vm.ci.common.InitTimer.timer;
+import static org.graalvm.compiler.options.OptionValue.PROFILE_OPTIONVALUE_PROPERTY_NAME;
 
 import java.io.File;
 import java.io.FileReader;
 import java.io.IOException;
 import java.io.PrintStream;
-import java.lang.reflect.Field;
 import java.util.HashMap;
 import java.util.Map;
+import java.util.Map.Entry;
 import java.util.Properties;
 import java.util.ServiceLoader;
 
-import org.graalvm.compiler.debug.GraalError;
 import org.graalvm.compiler.debug.MethodFilter;
 import org.graalvm.compiler.options.Option;
 import org.graalvm.compiler.options.OptionDescriptors;
@@ -46,10 +44,11 @@ import org.graalvm.compiler.options.OptionsParser;
 import org.graalvm.compiler.phases.tiers.CompilerConfiguration;
 
 import jdk.vm.ci.common.InitTimer;
+import jdk.vm.ci.hotspot.HotSpotJVMCICompilerFactory;
 import jdk.vm.ci.hotspot.HotSpotJVMCIRuntime;
 import jdk.vm.ci.hotspot.HotSpotSignature;
-import jdk.vm.ci.hotspot.HotSpotJVMCICompilerFactory;
 import jdk.vm.ci.runtime.JVMCIRuntime;
+import jdk.vm.ci.services.Services;
 
 public final class HotSpotGraalCompilerFactory extends HotSpotJVMCICompilerFactory {
 
@@ -135,8 +134,8 @@ public final class HotSpotGraalCompilerFactory extends HotSpotJVMCICompilerFacto
         if (allOptionsSettings == null) {
             try (InitTimer t = timer("InitializeOptions")) {
                 ServiceLoader loader = ServiceLoader.load(OptionDescriptors.class, OptionDescriptors.class.getClassLoader());
-                Properties savedProps = getSavedProperties(Java8OrEarlier);
-                String optionsFile = savedProps.getProperty(GRAAL_OPTIONS_FILE_PROPERTY_NAME);
+                Map savedProps = Services.getSavedProperties();
+                String optionsFile = savedProps.get(GRAAL_OPTIONS_FILE_PROPERTY_NAME);
 
                 if (optionsFile != null) {
                     File graalOptions = new File(optionsFile);
@@ -165,15 +164,15 @@ public final class HotSpotGraalCompilerFactory extends HotSpotJVMCICompilerFacto
                 }
 
                 Map optionSettings = new HashMap<>();
-                for (Map.Entry e : savedProps.entrySet()) {
-                    String name = (String) e.getKey();
+                for (Entry e : savedProps.entrySet()) {
+                    String name = e.getKey();
                     if (name.startsWith(GRAAL_OPTION_PROPERTY_PREFIX)) {
                         if (name.equals("graal.PrintFlags") || name.equals("graal.ShowFlags")) {
                             System.err.println("The " + name + " option has been removed and will be ignored. Use -XX:+JVMCIPrintProperties instead.");
                         } else if (name.equals(GRAAL_OPTIONS_FILE_PROPERTY_NAME) || name.equals(GRAAL_VERSION_PROPERTY_NAME) || name.equals(PROFILE_OPTIONVALUE_PROPERTY_NAME)) {
                             // Ignore well known properties that do not denote an option
                         } else {
-                            String value = (String) e.getValue();
+                            String value = e.getValue();
                             optionSettings.put(name.substring(GRAAL_OPTION_PROPERTY_PREFIX.length()), value);
                         }
                     }
@@ -206,18 +205,6 @@ public final class HotSpotGraalCompilerFactory extends HotSpotJVMCICompilerFacto
         }
     }
 
-    private static Properties getSavedProperties(boolean jdk8OrEarlier) {
-        try {
-            String vmClassName = jdk8OrEarlier ? "sun.misc.VM" : "jdk.internal.misc.VM";
-            Class vmClass = Class.forName(vmClassName);
-            Field savedPropsField = vmClass.getDeclaredField("savedProps");
-            savedPropsField.setAccessible(true);
-            return (Properties) savedPropsField.get(null);
-        } catch (Exception e) {
-            throw new GraalError(e);
-        }
-    }
-
     @Override
     public HotSpotGraalCompiler createCompiler(JVMCIRuntime runtime) {
         HotSpotGraalCompiler compiler = createCompiler(runtime, CompilerConfigurationFactory.selectFactory(null));
diff --git a/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalJVMCIServiceLocator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalJVMCIServiceLocator.java
new file mode 100644
index 00000000000..7dbda3a164f
--- /dev/null
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalJVMCIServiceLocator.java
@@ -0,0 +1,75 @@
+/*
+ * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+package org.graalvm.compiler.hotspot;
+
+import org.graalvm.compiler.serviceprovider.ServiceProvider;
+
+import jdk.vm.ci.hotspot.HotSpotVMEventListener;
+import jdk.vm.ci.runtime.JVMCICompilerFactory;
+import jdk.vm.ci.services.JVMCIServiceLocator;
+
+@ServiceProvider(JVMCIServiceLocator.class)
+public final class HotSpotGraalJVMCIServiceLocator extends JVMCIServiceLocator {
+
+    /**
+     * Holds the state shared between all {@link HotSpotGraalJVMCIServiceLocator} instances. This is
+     * necessary as a service provider instance is created each time the service is loaded.
+     */
+    private static final class Shared {
+        static final Shared SINGLETON = new Shared();
+
+         T getProvider(Class service, HotSpotGraalJVMCIServiceLocator locator) {
+            if (service == JVMCICompilerFactory.class) {
+                return service.cast(new HotSpotGraalCompilerFactory(locator));
+            } else if (service == HotSpotVMEventListener.class) {
+                if (graalRuntime != null) {
+                    return service.cast(new HotSpotGraalVMEventListener(graalRuntime));
+                }
+            }
+            return null;
+        }
+
+        private HotSpotGraalRuntime graalRuntime;
+
+        /**
+         * Notifies this object of the compiler created via {@link HotSpotGraalJVMCIServiceLocator}.
+         */
+        void onCompilerCreation(HotSpotGraalCompiler compiler) {
+            assert this.graalRuntime == null : "only expect a single JVMCICompiler to be created";
+            this.graalRuntime = (HotSpotGraalRuntime) compiler.getGraalRuntime();
+        }
+    }
+
+    @Override
+    public  T getProvider(Class service) {
+        return Shared.SINGLETON.getProvider(service, this);
+    }
+
+    /**
+     * Notifies this object of the compiler created via {@link HotSpotGraalJVMCIServiceLocator}.
+     */
+    @SuppressWarnings("static-method")
+    void onCompilerCreation(HotSpotGraalCompiler compiler) {
+        Shared.SINGLETON.onCompilerCreation(compiler);
+    }
+}
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalRuntime.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalRuntime.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalRuntime.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalRuntime.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalRuntimeProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalRuntimeProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalRuntimeProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalRuntimeProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalVMEventListener.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalVMEventListener.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalVMEventListener.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalVMEventListener.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotHostBackend.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotHostBackend.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotHostBackend.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotHostBackend.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotInstructionProfiling.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotInstructionProfiling.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotInstructionProfiling.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotInstructionProfiling.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerationResult.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerationResult.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerationResult.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerationResult.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerator.java
similarity index 92%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerator.java
index d2c61d89a9d..f2f45e24fec 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerator.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLIRGenerator.java
@@ -22,6 +22,7 @@
  */
 package org.graalvm.compiler.hotspot;
 
+import org.graalvm.compiler.core.common.LIRKind;
 import org.graalvm.compiler.debug.GraalError;
 import org.graalvm.compiler.hotspot.meta.HotSpotConstantLoadAction;
 import org.graalvm.compiler.hotspot.meta.HotSpotProviders;
@@ -141,10 +142,10 @@ public interface HotSpotLIRGenerator extends LIRGeneratorTool {
     /**
      * Emits code for a {@link LoadConstantIndirectlyNode}.
      *
-     * @param constant
+     * @param constant original constant
+     * @param action action to perform on the metaspace object
      * @return Value of loaded address in register
      */
-    @SuppressWarnings("unused")
     default Value emitLoadMetaspaceAddress(Constant constant, HotSpotConstantLoadAction action) {
         throw GraalError.unimplemented();
     }
@@ -152,21 +153,23 @@ public interface HotSpotLIRGenerator extends LIRGeneratorTool {
     /**
      * Emits code for a {@link GraalHotSpotVMConfigNode}.
      *
-     * @param markId type of address to load
+     * @param markId id of the value to load
+     * @param kind type of the value to load
      * @return value of loaded global in register
      */
-    default Value emitLoadConfigValue(int markId) {
+    default Value emitLoadConfigValue(int markId, LIRKind kind) {
         throw GraalError.unimplemented();
     }
 
     /**
      * Emits code for a {@link ResolveConstantNode} to resolve a {@link HotSpotObjectConstant}.
      *
+     * @param constant original constant
      * @param constantDescription a description of the string that need to be materialized (and
      *            interned) as java.lang.String, generated with {@link EncodedSymbolConstant}
+     * @param frameState frame state for the runtime call
      * @return Returns the address of the requested constant.
      */
-    @SuppressWarnings("unused")
     default Value emitObjectConstantRetrieval(Constant constant, Value constantDescription, LIRFrameState frameState) {
         throw GraalError.unimplemented();
     }
@@ -174,11 +177,12 @@ public interface HotSpotLIRGenerator extends LIRGeneratorTool {
     /**
      * Emits code for a {@link ResolveConstantNode} to resolve a {@link HotSpotMetaspaceConstant}.
      *
+     * @param constant original constant
      * @param constantDescription a symbolic description of the {@link HotSpotMetaspaceConstant}
      *            generated by {@link EncodedSymbolConstant}
+     * @param frameState frame state for the runtime call
      * @return Returns the address of the requested constant.
      */
-    @SuppressWarnings("unused")
     default Value emitMetaspaceConstantRetrieval(Constant constant, Value constantDescription, LIRFrameState frameState) {
         throw GraalError.unimplemented();
     }
@@ -188,12 +192,13 @@ public interface HotSpotLIRGenerator extends LIRGeneratorTool {
      * {@link HotSpotMetaspaceConstant} that represents a {@link ResolvedJavaMethod} and return the
      * corresponding MethodCounters object.
      *
+     * @param method original constant
      * @param klassHint a klass in which the method is declared
      * @param methodDescription is symbolic description of the constant generated by
      *            {@link EncodedSymbolConstant}
+     * @param frameState frame state for the runtime call
      * @return Returns the address of the requested constant.
      */
-    @SuppressWarnings("unused")
     default Value emitResolveMethodAndLoadCounters(Constant method, Value klassHint, Value methodDescription, LIRFrameState frameState) {
         throw GraalError.unimplemented();
     }
@@ -202,11 +207,13 @@ public interface HotSpotLIRGenerator extends LIRGeneratorTool {
      * Emits code for a {@link ResolveConstantNode} to resolve a klass
      * {@link HotSpotMetaspaceConstant} and run static initializer.
      *
+     *
+     * @param constant original constant
      * @param constantDescription a symbolic description of the {@link HotSpotMetaspaceConstant}
      *            generated by {@link EncodedSymbolConstant}
+     * @param frameState frame state for the runtime call
      * @return Returns the address of the requested constant.
      */
-    @SuppressWarnings("unused")
     default Value emitKlassInitializationAndRetrieval(Constant constant, Value constantDescription, LIRFrameState frameState) {
         throw GraalError.unimplemented();
     }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLockStack.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLockStack.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLockStack.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotLockStack.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotNodeLIRBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotNodeLIRBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotNodeLIRBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotNodeLIRBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotReferenceMapBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotReferenceMapBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotReferenceMapBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotReferenceMapBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotReplacementsImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotReplacementsImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotReplacementsImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotReplacementsImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotTTYStreamProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotTTYStreamProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotTTYStreamProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotTTYStreamProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/JVMCIVersionCheck.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/JVMCIVersionCheck.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/JVMCIVersionCheck.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/JVMCIVersionCheck.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/PrintStreamOption.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/PrintStreamOption.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/PrintStreamOption.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/PrintStreamOption.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/debug/BenchmarkCounters.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/debug/BenchmarkCounters.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/debug/BenchmarkCounters.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/debug/BenchmarkCounters.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/lir/HotSpotZapRegistersPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/lir/HotSpotZapRegistersPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/lir/HotSpotZapRegistersPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/lir/HotSpotZapRegistersPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/DefaultHotSpotLoweringProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/DefaultHotSpotLoweringProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/DefaultHotSpotLoweringProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/DefaultHotSpotLoweringProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotAOTProfilingPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotAOTProfilingPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotAOTProfilingPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotAOTProfilingPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotClassInitializationPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotClassInitializationPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotClassInitializationPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotClassInitializationPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotConstantFieldProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotConstantFieldProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotConstantFieldProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotConstantFieldProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotConstantLoadAction.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotConstantLoadAction.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotConstantLoadAction.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotConstantLoadAction.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotDisassemblerProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotDisassemblerProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotDisassemblerProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotDisassemblerProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotForeignCallsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotForeignCallsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotForeignCallsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotForeignCallsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotForeignCallsProviderImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotForeignCallsProviderImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotForeignCallsProviderImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotForeignCallsProviderImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraalConstantFieldProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraalConstantFieldProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraalConstantFieldProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraalConstantFieldProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraphBuilderPlugins.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraphBuilderPlugins.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraphBuilderPlugins.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraphBuilderPlugins.java
index 0fc8323be99..3f50151d1a0 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraphBuilderPlugins.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotGraphBuilderPlugins.java
@@ -128,7 +128,7 @@ public class HotSpotGraphBuilderPlugins {
      */
     public static Plugins create(GraalHotSpotVMConfig config, HotSpotWordTypes wordTypes, MetaAccessProvider metaAccess, ConstantReflectionProvider constantReflection,
                     SnippetReflectionProvider snippetReflection, ForeignCallsProvider foreignCalls, StampProvider stampProvider, ReplacementsImpl replacements) {
-        InvocationPlugins invocationPlugins = new HotSpotInvocationPlugins(config, metaAccess);
+        InvocationPlugins invocationPlugins = new HotSpotInvocationPlugins(config);
 
         Plugins plugins = new Plugins(invocationPlugins);
         NodeIntrinsificationProvider nodeIntrinsificationProvider = new NodeIntrinsificationProvider(metaAccess, snippetReflection, foreignCalls, wordTypes);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotHostForeignCallsProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotHostForeignCallsProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotHostForeignCallsProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotHostForeignCallsProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotInvocationPlugins.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotInvocationPlugins.java
similarity index 96%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotInvocationPlugins.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotInvocationPlugins.java
index 6c7f0088cd5..244579972dd 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotInvocationPlugins.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotInvocationPlugins.java
@@ -38,7 +38,6 @@ import org.graalvm.compiler.nodes.type.StampTool;
 import org.graalvm.compiler.replacements.nodes.MacroNode;
 
 import jdk.vm.ci.meta.JavaKind;
-import jdk.vm.ci.meta.MetaAccessProvider;
 import jdk.vm.ci.meta.ResolvedJavaType;
 
 /**
@@ -47,8 +46,7 @@ import jdk.vm.ci.meta.ResolvedJavaType;
 final class HotSpotInvocationPlugins extends InvocationPlugins {
     final GraalHotSpotVMConfig config;
 
-    HotSpotInvocationPlugins(GraalHotSpotVMConfig config, MetaAccessProvider metaAccess) {
-        super(metaAccess);
+    HotSpotInvocationPlugins(GraalHotSpotVMConfig config) {
         this.config = config;
     }
 
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotLoweringProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotLoweringProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotLoweringProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotLoweringProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotNodePlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotNodePlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotNodePlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotNodePlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotProfilingPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotProfilingPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotProfilingPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotProfilingPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotProviders.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotProviders.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotProviders.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotProviders.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotRegisters.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotRegisters.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotRegisters.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotRegisters.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotRegistersProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotRegistersProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotRegistersProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotRegistersProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotSnippetReflectionProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotSnippetReflectionProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotSnippetReflectionProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotSnippetReflectionProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotStampProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotStampProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotStampProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotStampProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotSuitesProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotSuitesProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotSuitesProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotSuitesProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotWordOperationPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotWordOperationPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotWordOperationPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/meta/HotSpotWordOperationPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/AcquiredCASLockNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/AcquiredCASLockNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/AcquiredCASLockNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/AcquiredCASLockNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/AllocaNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/AllocaNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/AllocaNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/AllocaNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ArrayRangeWriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ArrayRangeWriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ArrayRangeWriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ArrayRangeWriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/BeginLockScopeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/BeginLockScopeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/BeginLockScopeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/BeginLockScopeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CompressionNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CompressionNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CompressionNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CompressionNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ComputeObjectAddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ComputeObjectAddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ComputeObjectAddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ComputeObjectAddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CurrentJavaThreadNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CurrentJavaThreadNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CurrentJavaThreadNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CurrentJavaThreadNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CurrentLockNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CurrentLockNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CurrentLockNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/CurrentLockNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizationFetchUnrollInfoCallNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizationFetchUnrollInfoCallNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizationFetchUnrollInfoCallNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizationFetchUnrollInfoCallNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizeCallerNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizeCallerNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizeCallerNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizeCallerNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizingStubCall.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizingStubCall.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizingStubCall.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DeoptimizingStubCall.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DimensionsNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DimensionsNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DimensionsNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DimensionsNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DirectCompareAndSwapNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DirectCompareAndSwapNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DirectCompareAndSwapNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/DirectCompareAndSwapNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/EndLockScopeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/EndLockScopeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/EndLockScopeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/EndLockScopeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/EnterUnpackFramesStackFrameNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/EnterUnpackFramesStackFrameNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/EnterUnpackFramesStackFrameNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/EnterUnpackFramesStackFrameNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/FastAcquireBiasedLockNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/FastAcquireBiasedLockNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/FastAcquireBiasedLockNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/FastAcquireBiasedLockNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ArrayRangePostWriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ArrayRangePostWriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ArrayRangePostWriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ArrayRangePostWriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ArrayRangePreWriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ArrayRangePreWriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ArrayRangePreWriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ArrayRangePreWriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1PostWriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1PostWriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1PostWriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1PostWriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1PreWriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1PreWriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1PreWriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1PreWriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ReferentFieldReadBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ReferentFieldReadBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ReferentFieldReadBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/G1ReferentFieldReadBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GetObjectAddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GetObjectAddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GetObjectAddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GetObjectAddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GraalHotSpotVMConfigNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GraalHotSpotVMConfigNode.java
similarity index 76%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GraalHotSpotVMConfigNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GraalHotSpotVMConfigNode.java
index cdb8160632e..8d0575fe6b5 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GraalHotSpotVMConfigNode.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/GraalHotSpotVMConfigNode.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -55,62 +55,86 @@ public class GraalHotSpotVMConfigNode extends FloatingNode implements LIRLowerab
     private final GraalHotSpotVMConfig config;
     protected final int markId;
 
+    /**
+     * Constructor for {@link #areConfigValuesConstant()}.
+     *
+     * @param config
+     */
+    public GraalHotSpotVMConfigNode(@InjectedNodeParameter GraalHotSpotVMConfig config) {
+        super(TYPE, StampFactory.forKind(JavaKind.Boolean));
+        this.config = config;
+        this.markId = 0;
+    }
+
+    /**
+     * Constructor for node intrinsics below.
+     *
+     * @param config
+     * @param markId id of the config value
+     */
+    public GraalHotSpotVMConfigNode(@InjectedNodeParameter GraalHotSpotVMConfig config, int markId) {
+        super(TYPE, StampFactory.forNodeIntrinsic());
+        this.config = config;
+        this.markId = markId;
+    }
+
+    /**
+     * Constructor with explicit type specification.
+     *
+     * @param config
+     * @param markId id of the config value
+     * @param kind explicit type of the node
+     */
     public GraalHotSpotVMConfigNode(@InjectedNodeParameter GraalHotSpotVMConfig config, int markId, JavaKind kind) {
         super(TYPE, StampFactory.forKind(kind));
         this.config = config;
         this.markId = markId;
     }
 
-    /**
-     * Constructor selected by {@link #loadConfigValue(int, JavaKind)}.
-     *
-     * @param config
-     * @param markId
-     */
-    public GraalHotSpotVMConfigNode(@InjectedNodeParameter GraalHotSpotVMConfig config, int markId) {
-        super(TYPE, StampFactory.forKind(JavaKind.Boolean));
-        this.config = config;
-        this.markId = 0;
-    }
-
     @Override
     public void generate(NodeLIRBuilderTool generator) {
-        Value res = ((HotSpotLIRGenerator) generator.getLIRGeneratorTool()).emitLoadConfigValue(markId);
+        Value res = ((HotSpotLIRGenerator) generator.getLIRGeneratorTool()).emitLoadConfigValue(markId, generator.getLIRGeneratorTool().getLIRKind(stamp));
         generator.setResult(this, res);
     }
 
     @NodeIntrinsic
-    private static native boolean isConfigValueConstant(@ConstantNodeParameter int markId);
+    private static native boolean areConfigValuesConstant();
 
-    @NodeIntrinsic
-    private static native long loadConfigValue(@ConstantNodeParameter int markId, @ConstantNodeParameter JavaKind kind);
+    @NodeIntrinsic(setStampFromReturnType = true)
+    private static native long loadLongConfigValue(@ConstantNodeParameter int markId);
+
+    @NodeIntrinsic(setStampFromReturnType = true)
+    private static native int loadIntConfigValue(@ConstantNodeParameter int markId);
+
+    @NodeIntrinsic(setStampFromReturnType = true)
+    private static native byte loadByteConfigValue(@ConstantNodeParameter int markId);
 
     public static long cardTableAddress() {
-        return loadConfigValue(cardTableAddressMark(INJECTED_VMCONFIG), JavaKind.Long);
+        return loadLongConfigValue(cardTableAddressMark(INJECTED_VMCONFIG));
     }
 
     public static boolean isCardTableAddressConstant() {
-        return isConfigValueConstant(cardTableAddressMark(INJECTED_VMCONFIG));
+        return areConfigValuesConstant();
     }
 
     public static long heapTopAddress() {
-        return loadConfigValue(heapTopAddressMark(INJECTED_VMCONFIG), JavaKind.Long);
+        return loadLongConfigValue(heapTopAddressMark(INJECTED_VMCONFIG));
     }
 
     public static long heapEndAddress() {
-        return loadConfigValue(heapEndAddressMark(INJECTED_VMCONFIG), JavaKind.Long);
+        return loadLongConfigValue(heapEndAddressMark(INJECTED_VMCONFIG));
     }
 
     public static long crcTableAddress() {
-        return loadConfigValue(crcTableAddressMark(INJECTED_VMCONFIG), JavaKind.Long);
+        return loadLongConfigValue(crcTableAddressMark(INJECTED_VMCONFIG));
     }
 
     public static int logOfHeapRegionGrainBytes() {
-        return (int) loadConfigValue(logOfHeapRegionGrainBytesMark(INJECTED_VMCONFIG), JavaKind.Byte);
+        return loadIntConfigValue(logOfHeapRegionGrainBytesMark(INJECTED_VMCONFIG));
     }
 
     public static boolean inlineContiguousAllocationSupported() {
-        return loadConfigValue(inlineContiguousAllocationSupportedMark(INJECTED_VMCONFIG), JavaKind.Byte) > 0;
+        return loadByteConfigValue(inlineContiguousAllocationSupportedMark(INJECTED_VMCONFIG)) != 0;
     }
 
     @Fold
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotDirectCallTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotDirectCallTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotDirectCallTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotDirectCallTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotIndirectCallTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotIndirectCallTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotIndirectCallTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotIndirectCallTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotNodeCostProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotNodeCostProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotNodeCostProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/HotSpotNodeCostProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/JumpToExceptionHandlerInCallerNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/JumpToExceptionHandlerInCallerNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/JumpToExceptionHandlerInCallerNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/JumpToExceptionHandlerInCallerNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/JumpToExceptionHandlerNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/JumpToExceptionHandlerNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/JumpToExceptionHandlerNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/JumpToExceptionHandlerNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveCurrentStackFrameNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveCurrentStackFrameNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveCurrentStackFrameNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveCurrentStackFrameNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveDeoptimizedStackFrameNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveDeoptimizedStackFrameNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveDeoptimizedStackFrameNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveDeoptimizedStackFrameNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveUnpackFramesStackFrameNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveUnpackFramesStackFrameNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveUnpackFramesStackFrameNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LeaveUnpackFramesStackFrameNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LoadIndexedPointerNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LoadIndexedPointerNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LoadIndexedPointerNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/LoadIndexedPointerNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/MonitorCounterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/MonitorCounterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/MonitorCounterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/MonitorCounterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ObjectWriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ObjectWriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ObjectWriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/ObjectWriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/PatchReturnAddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/PatchReturnAddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/PatchReturnAddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/PatchReturnAddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/PushInterpreterFrameNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/PushInterpreterFrameNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/PushInterpreterFrameNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/PushInterpreterFrameNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SaveAllRegistersNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SaveAllRegistersNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SaveAllRegistersNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SaveAllRegistersNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SerialArrayRangeWriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SerialArrayRangeWriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SerialArrayRangeWriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SerialArrayRangeWriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SerialWriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SerialWriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SerialWriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SerialWriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SnippetAnchorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SnippetAnchorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SnippetAnchorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SnippetAnchorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SnippetLocationProxyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SnippetLocationProxyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SnippetLocationProxyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/SnippetLocationProxyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/StubForeignCallNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/StubForeignCallNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/StubForeignCallNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/StubForeignCallNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/StubStartNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/StubStartNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/StubStartNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/StubStartNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/UncommonTrapCallNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/UncommonTrapCallNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/UncommonTrapCallNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/UncommonTrapCallNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/VMErrorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/VMErrorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/VMErrorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/VMErrorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/WriteBarrier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/WriteBarrier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/WriteBarrier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/WriteBarrier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/EncodedSymbolNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/EncodedSymbolNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/EncodedSymbolNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/EncodedSymbolNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/InitializeKlassNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/InitializeKlassNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/InitializeKlassNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/InitializeKlassNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/InitializeKlassStubCall.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/InitializeKlassStubCall.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/InitializeKlassStubCall.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/InitializeKlassStubCall.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadConstantIndirectlyFixedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadConstantIndirectlyFixedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadConstantIndirectlyFixedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadConstantIndirectlyFixedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadConstantIndirectlyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadConstantIndirectlyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadConstantIndirectlyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadConstantIndirectlyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadMethodCountersIndirectlyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadMethodCountersIndirectlyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadMethodCountersIndirectlyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadMethodCountersIndirectlyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadMethodCountersNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadMethodCountersNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadMethodCountersNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/LoadMethodCountersNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveConstantNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveConstantNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveConstantNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveConstantNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveConstantStubCall.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveConstantStubCall.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveConstantStubCall.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveConstantStubCall.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveMethodAndLoadCountersNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveMethodAndLoadCountersNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveMethodAndLoadCountersNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveMethodAndLoadCountersNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveMethodAndLoadCountersStubCall.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveMethodAndLoadCountersStubCall.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveMethodAndLoadCountersStubCall.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/aot/ResolveMethodAndLoadCountersStubCall.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileBranchNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileBranchNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileBranchNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileBranchNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileInvokeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileInvokeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileInvokeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileInvokeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileWithNotificationNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileWithNotificationNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileWithNotificationNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/ProfileWithNotificationNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/RandomSeedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/RandomSeedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/RandomSeedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/profiling/RandomSeedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/HotSpotLIRKindTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/HotSpotLIRKindTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/HotSpotLIRKindTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/HotSpotLIRKindTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/KlassPointerStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/KlassPointerStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/KlassPointerStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/KlassPointerStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MetaspacePointerStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MetaspacePointerStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MetaspacePointerStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MetaspacePointerStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MethodCountersPointerStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MethodCountersPointerStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MethodCountersPointerStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MethodCountersPointerStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MethodPointerStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MethodPointerStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MethodPointerStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/MethodPointerStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/NarrowOopStamp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/NarrowOopStamp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/NarrowOopStamp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/nodes/type/NarrowOopStamp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/package-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/package-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/package-info.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/AheadOfTimeVerificationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/AheadOfTimeVerificationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/AheadOfTimeVerificationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/AheadOfTimeVerificationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/LoadJavaMirrorWithKlassPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/LoadJavaMirrorWithKlassPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/LoadJavaMirrorWithKlassPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/LoadJavaMirrorWithKlassPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/OnStackReplacementPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/OnStackReplacementPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/OnStackReplacementPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/OnStackReplacementPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/WriteBarrierAdditionPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/WriteBarrierAdditionPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/WriteBarrierAdditionPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/WriteBarrierAdditionPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/WriteBarrierVerificationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/WriteBarrierVerificationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/WriteBarrierVerificationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/WriteBarrierVerificationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/AOTInliningPolicy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/AOTInliningPolicy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/AOTInliningPolicy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/AOTInliningPolicy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/EliminateRedundantInitializationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/EliminateRedundantInitializationPhase.java
similarity index 99%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/EliminateRedundantInitializationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/EliminateRedundantInitializationPhase.java
index 46d8be12171..caa04c2c979 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/EliminateRedundantInitializationPhase.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/EliminateRedundantInitializationPhase.java
@@ -28,9 +28,6 @@ import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.Map.Entry;
 
-import jdk.vm.ci.hotspot.HotSpotMetaspaceConstant;
-import jdk.vm.ci.meta.JavaConstant;
-
 import org.graalvm.compiler.graph.Node;
 import org.graalvm.compiler.graph.iterators.NodeIterable;
 import org.graalvm.compiler.hotspot.nodes.aot.InitializeKlassNode;
@@ -43,6 +40,9 @@ import org.graalvm.compiler.nodes.cfg.ControlFlowGraph;
 import org.graalvm.compiler.phases.BasePhase;
 import org.graalvm.compiler.phases.tiers.PhaseContext;
 
+import jdk.vm.ci.hotspot.HotSpotMetaspaceConstant;
+import jdk.vm.ci.meta.Constant;
+
 public class EliminateRedundantInitializationPhase extends BasePhase {
     /**
      * Find blocks with class initializing nodes for the class identified the by the constant node.
@@ -202,7 +202,7 @@ public class EliminateRedundantInitializationPhase extends BasePhase redundantInits = new ArrayList<>();
         for (ConstantNode node : getConstantNodes(graph)) {
-            JavaConstant constant = node.asJavaConstant();
+            Constant constant = node.asConstant();
             if (constant instanceof HotSpotMetaspaceConstant) {
                 redundantInits.addAll(processConstantNode(cfg, node));
             }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/ReplaceConstantNodesPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/ReplaceConstantNodesPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/ReplaceConstantNodesPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/aot/ReplaceConstantNodesPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/profiling/FinalizeProfileNodesPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/profiling/FinalizeProfileNodesPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/profiling/FinalizeProfileNodesPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/phases/profiling/FinalizeProfileNodesPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AESCryptSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AESCryptSubstitutions.java
similarity index 94%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AESCryptSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AESCryptSubstitutions.java
index 3dfb4210356..2240b335ed3 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AESCryptSubstitutions.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AESCryptSubstitutions.java
@@ -29,8 +29,6 @@ import static org.graalvm.compiler.nodes.extended.BranchProbabilityNode.VERY_SLO
 import static org.graalvm.compiler.nodes.extended.BranchProbabilityNode.probability;
 import static jdk.vm.ci.hotspot.HotSpotJVMCIRuntimeProvider.getArrayBaseOffset;
 
-import java.lang.reflect.Field;
-
 import org.graalvm.compiler.api.replacements.ClassSubstitution;
 import org.graalvm.compiler.api.replacements.MethodSubstitution;
 import org.graalvm.compiler.core.common.LocationIdentity;
@@ -61,7 +59,7 @@ public class AESCryptSubstitutions {
     static final long kOffset;
     static final long lastKeyOffset;
     static final Class AESCryptClass;
-    static final int AES_BLOCK_SIZE;
+    static final int AES_BLOCK_SIZE_IN_BYTES;
 
     static {
         try {
@@ -72,9 +70,9 @@ public class AESCryptSubstitutions {
             AESCryptClass = Class.forName("com.sun.crypto.provider.AESCrypt", true, cl);
             kOffset = UnsafeAccess.UNSAFE.objectFieldOffset(AESCryptClass.getDeclaredField("K"));
             lastKeyOffset = UnsafeAccess.UNSAFE.objectFieldOffset(AESCryptClass.getDeclaredField("lastKey"));
-            Field aesBlockSizeField = Class.forName("com.sun.crypto.provider.AESConstants", true, cl).getDeclaredField("AES_BLOCK_SIZE");
-            aesBlockSizeField.setAccessible(true);
-            AES_BLOCK_SIZE = aesBlockSizeField.getInt(null);
+            // Thankfully the AES block size is a constant (128 bits) and so we don't need to
+            // reflect on com.sun.crypto.provider.AESConstants.AES_BLOCK_SIZE.
+            AES_BLOCK_SIZE_IN_BYTES = 16;
         } catch (Exception ex) {
             throw new GraalError(ex);
         }
@@ -141,7 +139,7 @@ public class AESCryptSubstitutions {
      * Perform null and array bounds checks for arguments to a cipher operation.
      */
     static void checkArgs(byte[] in, int inOffset, byte[] out, int outOffset) {
-        if (probability(VERY_SLOW_PATH_PROBABILITY, inOffset < 0 || in.length - AES_BLOCK_SIZE < inOffset || outOffset < 0 || out.length - AES_BLOCK_SIZE < outOffset)) {
+        if (probability(VERY_SLOW_PATH_PROBABILITY, inOffset < 0 || in.length - AES_BLOCK_SIZE_IN_BYTES < inOffset || outOffset < 0 || out.length - AES_BLOCK_SIZE_IN_BYTES < outOffset)) {
             DeoptimizeNode.deopt(DeoptimizationAction.None, DeoptimizationReason.RuntimeConstraint);
         }
     }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AssertionSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AssertionSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AssertionSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/AssertionSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/BigIntegerSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/BigIntegerSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/BigIntegerSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/BigIntegerSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CRC32Substitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CRC32Substitutions.java
similarity index 97%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CRC32Substitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CRC32Substitutions.java
index 218b4f0508e..1c1447d913a 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CRC32Substitutions.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CRC32Substitutions.java
@@ -57,7 +57,7 @@ public class CRC32Substitutions {
         return config.crcTableAddress;
     }
 
-    @MethodSubstitution
+    @MethodSubstitution(optional = true)
     static int update(int crc, int b) {
         final long crcTableRawAddress = GraalHotSpotVMConfigNode.crcTableAddress();
 
@@ -69,7 +69,7 @@ public class CRC32Substitutions {
         return ~result;
     }
 
-    @MethodSubstitution
+    @MethodSubstitution(optional = true)
     static int updateBytes(int crc, byte[] buf, int off, int len) {
         Word bufAddr = Word.unsigned(ComputeObjectAddressNode.get(buf, arrayBaseOffset(JavaKind.Byte) + off));
         return updateBytesCRC32(UPDATE_BYTES_CRC32, crc, bufAddr, len);
@@ -84,7 +84,7 @@ public class CRC32Substitutions {
         return updateBytesCRC32(UPDATE_BYTES_CRC32, crc, bufAddr, len);
     }
 
-    @MethodSubstitution
+    @MethodSubstitution(optional = true)
     static int updateByteBuffer(int crc, long addr, int off, int len) {
         Word bufAddr = Word.unsigned(addr).add(off);
         return updateBytesCRC32(UPDATE_BYTES_CRC32, crc, bufAddr, len);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CallSiteTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CallSiteTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CallSiteTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CallSiteTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CipherBlockChainingSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CipherBlockChainingSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CipherBlockChainingSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/CipherBlockChainingSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ClassGetHubNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ClassGetHubNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ClassGetHubNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ClassGetHubNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/EncodedSymbolConstant.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/EncodedSymbolConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/EncodedSymbolConstant.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/EncodedSymbolConstant.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HashCodeSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HashCodeSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HashCodeSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HashCodeSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotSpotClassSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotSpotClassSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotSpotClassSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotSpotClassSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotSpotReplacementsUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotSpotReplacementsUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotSpotReplacementsUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotSpotReplacementsUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotspotSnippetsOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotspotSnippetsOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotspotSnippetsOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HotspotSnippetsOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HubGetClassNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HubGetClassNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HubGetClassNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/HubGetClassNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/IdentityHashCodeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/IdentityHashCodeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/IdentityHashCodeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/IdentityHashCodeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/InstanceOfSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/InstanceOfSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/InstanceOfSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/InstanceOfSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/KlassLayoutHelperNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/KlassLayoutHelperNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/KlassLayoutHelperNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/KlassLayoutHelperNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/LoadExceptionObjectSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/LoadExceptionObjectSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/LoadExceptionObjectSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/LoadExceptionObjectSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/MonitorSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/MonitorSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/MonitorSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/MonitorSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/NewObjectSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/NewObjectSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/NewObjectSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/NewObjectSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectCloneNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectCloneNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectCloneNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectCloneNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectCloneSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectCloneSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectCloneSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectCloneSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ObjectSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ReflectionGetCallerClassNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ReflectionGetCallerClassNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ReflectionGetCallerClassNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ReflectionGetCallerClassNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ReflectionSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ReflectionSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ReflectionSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ReflectionSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHA2Substitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHA2Substitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHA2Substitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHA2Substitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHA5Substitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHA5Substitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHA5Substitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHA5Substitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHASubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHASubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHASubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/SHASubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/StringToBytesSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/StringToBytesSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/StringToBytesSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/StringToBytesSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ThreadSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ThreadSubstitutions.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ThreadSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ThreadSubstitutions.java
index 99fb04dde2d..e80bb98c19d 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ThreadSubstitutions.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/ThreadSubstitutions.java
@@ -45,7 +45,7 @@ import org.graalvm.compiler.word.Word;
 @ClassSubstitution(Thread.class)
 public class ThreadSubstitutions {
 
-    @MethodSubstitution(isStatic = false)
+    @MethodSubstitution(isStatic = false, optional = true)
     public static boolean isInterrupted(final Thread thisObject, boolean clearInterrupted) {
         Word javaThread = CurrentJavaThreadNode.get();
         Object thread = javaThread.readObject(threadObjectOffset(INJECTED_VMCONFIG), JAVA_THREAD_THREAD_OBJECT_LOCATION);
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/TypeCheckSnippetUtils.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/TypeCheckSnippetUtils.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/TypeCheckSnippetUtils.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/TypeCheckSnippetUtils.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/UnsafeAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/UnsafeAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/UnsafeAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/UnsafeAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/UnsafeLoadSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/UnsafeLoadSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/UnsafeLoadSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/UnsafeLoadSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/WriteBarrierSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/WriteBarrierSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/WriteBarrierSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/WriteBarrierSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/aot/ResolveConstantSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/aot/ResolveConstantSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/aot/ResolveConstantSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/aot/ResolveConstantSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyCallNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyCallNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyCallNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyCallNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopySlowPathNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopySlowPathNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopySlowPathNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopySlowPathNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopySnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopySnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopySnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopySnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyUnrollNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyUnrollNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyUnrollNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/ArrayCopyUnrollNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/CheckcastArrayCopyCallNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/CheckcastArrayCopyCallNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/CheckcastArrayCopyCallNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/CheckcastArrayCopyCallNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/UnsafeArrayCopyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/UnsafeArrayCopyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/UnsafeArrayCopyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/UnsafeArrayCopyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/UnsafeArrayCopySnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/UnsafeArrayCopySnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/UnsafeArrayCopySnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/arraycopy/UnsafeArrayCopySnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/profiling/ProbabilisticProfileSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/profiling/ProbabilisticProfileSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/profiling/ProbabilisticProfileSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/profiling/ProbabilisticProfileSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/profiling/ProfileSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/profiling/ProfileSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/profiling/ProfileSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/replacements/profiling/ProfileSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ArrayStoreExceptionStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ArrayStoreExceptionStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ArrayStoreExceptionStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ArrayStoreExceptionStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ClassCastExceptionStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ClassCastExceptionStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ClassCastExceptionStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ClassCastExceptionStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/CreateExceptionStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/CreateExceptionStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/CreateExceptionStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/CreateExceptionStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/DeoptimizationStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/DeoptimizationStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/DeoptimizationStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/DeoptimizationStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ExceptionHandlerStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ExceptionHandlerStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ExceptionHandlerStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ExceptionHandlerStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ForeignCallStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ForeignCallStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ForeignCallStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/ForeignCallStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NewArrayStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NewArrayStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NewArrayStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NewArrayStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NewInstanceStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NewInstanceStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NewInstanceStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NewInstanceStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NullPointerExceptionStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NullPointerExceptionStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NullPointerExceptionStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/NullPointerExceptionStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/OutOfBoundsExceptionStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/OutOfBoundsExceptionStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/OutOfBoundsExceptionStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/OutOfBoundsExceptionStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/SnippetStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/SnippetStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/SnippetStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/SnippetStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/Stub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/Stub.java
similarity index 81%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/Stub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/Stub.java
index 5d2eb3ee74b..8857bd417a6 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/Stub.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/Stub.java
@@ -89,18 +89,11 @@ public abstract class Stub {
      */
     protected InstalledCode code;
 
-    /**
-     * Compilation result from which {@link #code} was created.
-     */
-    protected CompilationResult compResult;
-
     /**
      * The registers destroyed by this stub (from the caller's perspective).
      */
     private Set destroyedCallerRegisters;
 
-    private HotSpotCompiledCode compiledCode;
-
     public void initDestroyedCallerRegisters(Set registers) {
         assert registers != null;
         assert destroyedCallerRegisters == null || registers.equals(destroyedCallerRegisters) : "cannot redefine";
@@ -184,35 +177,13 @@ public abstract class Stub {
     public synchronized InstalledCode getCode(final Backend backend) {
         if (code == null) {
             try (Scope d = Debug.sandbox("CompilingStub", DebugScope.getConfig(), providers.getCodeCache(), debugScopeContext())) {
-                final StructuredGraph graph = getGraph(getStubCompilationId());
-
-                // Stubs cannot be recompiled so they cannot be compiled with assumptions
-                assert graph.getAssumptions() == null;
-
-                if (!(graph.start() instanceof StubStartNode)) {
-                    StubStartNode newStart = graph.add(new StubStartNode(Stub.this));
-                    newStart.setStateAfter(graph.start().stateAfter());
-                    graph.replaceFixed(graph.start(), newStart);
-                }
-
                 CodeCacheProvider codeCache = providers.getCodeCache();
-
-                compResult = new CompilationResult(toString(), GeneratePIC.getValue());
-                try (Scope s0 = Debug.scope("StubCompilation", graph, providers.getCodeCache())) {
-                    Suites suites = createSuites();
-                    emitFrontEnd(providers, backend, graph, providers.getSuites().getDefaultGraphBuilderSuite(), OptimisticOptimizations.ALL, DefaultProfilingInfo.get(TriState.UNKNOWN), suites);
-                    LIRSuites lirSuites = createLIRSuites();
-                    emitBackEnd(graph, Stub.this, getInstalledCodeOwner(), backend, compResult, CompilationResultBuilderFactory.Default, getRegisterConfig(), lirSuites);
-                    assert checkStubInvariants();
-                } catch (Throwable e) {
-                    throw Debug.handle(e);
-                }
-
-                assert destroyedCallerRegisters != null;
+                CompilationResult compResult = buildCompilationResult(backend);
                 try (Scope s = Debug.scope("CodeInstall", compResult)) {
+                    assert destroyedCallerRegisters != null;
                     // Add a GeneratePIC check here later, we don't want to install
                     // code if we don't have a corresponding VM global symbol.
-                    compiledCode = HotSpotCompiledCodeBuilder.createCompiledCode(null, null, compResult);
+                    HotSpotCompiledCode compiledCode = HotSpotCompiledCodeBuilder.createCompiledCode(null, null, compResult);
                     code = codeCache.installCode(null, compiledCode, null, null, false);
                 } catch (Throwable e) {
                     throw Debug.handle(e);
@@ -226,6 +197,44 @@ public abstract class Stub {
         return code;
     }
 
+    @SuppressWarnings("try")
+    private CompilationResult buildCompilationResult(final Backend backend) {
+        CompilationResult compResult = new CompilationResult(toString(), GeneratePIC.getValue());
+        final StructuredGraph graph = getGraph(getStubCompilationId());
+
+        // Stubs cannot be recompiled so they cannot be compiled with assumptions
+        assert graph.getAssumptions() == null;
+
+        if (!(graph.start() instanceof StubStartNode)) {
+            StubStartNode newStart = graph.add(new StubStartNode(Stub.this));
+            newStart.setStateAfter(graph.start().stateAfter());
+            graph.replaceFixed(graph.start(), newStart);
+        }
+
+        try (Scope s0 = Debug.scope("StubCompilation", graph, providers.getCodeCache())) {
+            Suites suites = createSuites();
+            emitFrontEnd(providers, backend, graph, providers.getSuites().getDefaultGraphBuilderSuite(), OptimisticOptimizations.ALL, DefaultProfilingInfo.get(TriState.UNKNOWN), suites);
+            LIRSuites lirSuites = createLIRSuites();
+            emitBackEnd(graph, Stub.this, getInstalledCodeOwner(), backend, compResult, CompilationResultBuilderFactory.Default, getRegisterConfig(), lirSuites);
+            assert checkStubInvariants(compResult);
+        } catch (Throwable e) {
+            throw Debug.handle(e);
+        }
+        return compResult;
+    }
+
+    /**
+     * Gets a {@link CompilationResult} that can be used for code generation. Required for AOT.
+     */
+    @SuppressWarnings("try")
+    public CompilationResult getCompilationResult(final Backend backend) {
+        try (Scope d = Debug.sandbox("CompilingStub", DebugScope.getConfig(), providers.getCodeCache(), debugScopeContext())) {
+            return buildCompilationResult(backend);
+        } catch (Throwable e) {
+            throw Debug.handle(e);
+        }
+    }
+
     public CompilationIdentifier getStubCompilationId() {
         return new StubCompilationIdentifier(this);
     }
@@ -233,7 +242,7 @@ public abstract class Stub {
     /**
      * Checks the conditions a compilation must satisfy to be installed as a RuntimeStub.
      */
-    private boolean checkStubInvariants() {
+    private boolean checkStubInvariants(CompilationResult compResult) {
         assert compResult.getExceptionHandlers().isEmpty() : this;
 
         // Stubs cannot be recompiled so they cannot be compiled with
@@ -278,24 +287,4 @@ public abstract class Stub {
         }
         return lirSuites;
     }
-
-    /**
-     * Gets the HotSpotCompiledCode that was created during installation.
-     */
-    public synchronized HotSpotCompiledCode getCompiledCode(final Backend backend) {
-        getCompilationResult(backend);
-        assert compiledCode != null;
-        return compiledCode;
-    }
-
-    /**
-     * Gets the compilation result for this stub, compiling it first if necessary, and installing it
-     * in code.
-     */
-    public synchronized CompilationResult getCompilationResult(final Backend backend) {
-        if (code == null) {
-            getCode(backend);
-        }
-        return compResult;
-    }
 }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubCompilationIdentifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubCompilationIdentifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubCompilationIdentifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubCompilationIdentifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/StubUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/UncommonTrapStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/UncommonTrapStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/UncommonTrapStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/UncommonTrapStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/UnwindExceptionToCallerStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/UnwindExceptionToCallerStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/UnwindExceptionToCallerStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/UnwindExceptionToCallerStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/VerifyOopStub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/VerifyOopStub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/VerifyOopStub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/stubs/VerifyOopStub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/HotSpotOperation.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/HotSpotOperation.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/HotSpotOperation.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/HotSpotOperation.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/HotSpotWordTypes.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/HotSpotWordTypes.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/HotSpotWordTypes.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/HotSpotWordTypes.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/KlassPointer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/KlassPointer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/KlassPointer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/KlassPointer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MetaspacePointer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MetaspacePointer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MetaspacePointer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MetaspacePointer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MethodCountersPointer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MethodCountersPointer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MethodCountersPointer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MethodCountersPointer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MethodPointer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MethodPointer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MethodPointer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/MethodPointer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/PointerCastNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/PointerCastNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/PointerCastNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/word/PointerCastNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BciBlockMapping.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BciBlockMapping.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BciBlockMapping.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BciBlockMapping.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BytecodeParser.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BytecodeParser.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BytecodeParser.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BytecodeParser.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BytecodeParserOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BytecodeParserOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BytecodeParserOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/BytecodeParserOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/ComputeLoopFrequenciesClosure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/ComputeLoopFrequenciesClosure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/ComputeLoopFrequenciesClosure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/ComputeLoopFrequenciesClosure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/DefaultSuitesProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/DefaultSuitesProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/DefaultSuitesProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/DefaultSuitesProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/FrameStateBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/FrameStateBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/FrameStateBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/FrameStateBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/GraphBuilderPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/GraphBuilderPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/GraphBuilderPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/GraphBuilderPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/JsrNotSupportedBailout.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/JsrNotSupportedBailout.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/JsrNotSupportedBailout.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/JsrNotSupportedBailout.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/JsrScope.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/JsrScope.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/JsrScope.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/JsrScope.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/LargeLocalLiveness.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/LargeLocalLiveness.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/LargeLocalLiveness.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/LargeLocalLiveness.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/LocalLiveness.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/LocalLiveness.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/LocalLiveness.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/LocalLiveness.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/SmallLocalLiveness.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/SmallLocalLiveness.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/SmallLocalLiveness.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/SmallLocalLiveness.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/SuitesProviderBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/SuitesProviderBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/SuitesProviderBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/SuitesProviderBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/JTTTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/JTTTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/JTTTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/JTTTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/ConstantPhiTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/ConstantPhiTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/ConstantPhiTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/ConstantPhiTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/EmptyMethodTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/EmptyMethodTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/EmptyMethodTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/EmptyMethodTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/LargeConstantSectionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/LargeConstantSectionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/LargeConstantSectionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/backend/LargeConstantSectionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aaload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aaload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aaload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aaload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aaload_1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aaload_1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aaload_1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aaload_1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_0.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_0.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_0.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_0.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_aload_3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_anewarray.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_anewarray.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_anewarray.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_anewarray.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_areturn.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_areturn.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_areturn.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_areturn.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_arraylength.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_arraylength.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_arraylength.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_arraylength.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_athrow.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_athrow.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_athrow.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_athrow.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_baload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_baload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_baload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_baload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_bastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_bastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_bastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_bastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_caload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_caload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_caload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_caload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_castore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_castore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_castore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_castore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_checkcast03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2f.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2f.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2f.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2f.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2i01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2i01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2i01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2i01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2i02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2i02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2i02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2i02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_d2l03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dadd.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dadd.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dadd.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dadd.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_daload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_daload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_daload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_daload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp07.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp07.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp07.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp07.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp08.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp08.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp08.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp08.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp09.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp09.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp09.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp09.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp10.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp10.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp10.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dcmp10.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ddiv.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ddiv.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ddiv.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ddiv.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dmul.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dmul.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dmul.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dmul.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dneg.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dneg.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dneg.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dneg.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dneg2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dneg2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dneg2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dneg2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_double_base.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_double_base.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_double_base.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_double_base.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_drem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_drem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_drem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_drem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dreturn.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dreturn.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dreturn.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dreturn.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dsub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dsub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dsub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dsub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dsub2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dsub2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dsub2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_dsub2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2d.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2d.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2d.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2d.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2i01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2i01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2i01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2i01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2i02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2i02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2i02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2i02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2l01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2l01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2l01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2l01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2l02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2l02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2l02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_f2l02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fadd.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fadd.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fadd.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fadd.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_faload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_faload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_faload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_faload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp07.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp07.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp07.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp07.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp08.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp08.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp08.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp08.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp09.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp09.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp09.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp09.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp10.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp10.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp10.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fcmp10.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fdiv.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fdiv.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fdiv.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fdiv.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fload_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fload_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fload_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fload_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_float_base.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_float_base.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_float_base.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_float_base.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fmul.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fmul.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fmul.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fmul.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fneg.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fneg.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fneg.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fneg.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_frem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_frem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_frem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_frem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_freturn.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_freturn.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_freturn.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_freturn.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fsub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fsub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fsub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_fsub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_b.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_b.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_b.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_b.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_c.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_c.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_c.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_c.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_d.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_d.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_d.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_d.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_f.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_f.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_f.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_f.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_i.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_i.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_i.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_i.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_l.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_l.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_l.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_l.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_o.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_o.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_o.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_o.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_s.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_s.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_s.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_s.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_z.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_z.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_z.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getfield_z.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_b.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_b.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_b.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_b.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_c.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_c.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_c.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_c.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_d.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_d.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_d.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_d.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_f.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_f.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_f.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_f.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_i.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_i.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_i.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_i.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_l.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_l.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_l.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_l.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_s.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_s.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_s.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_s.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_z.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_z.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_z.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_getstatic_z.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2b.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2b.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2b.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2b.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2c.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2c.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2c.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2c.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2d.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2d.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2d.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2d.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2f.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2f.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2f.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2f.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2l.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2l.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2l.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2l.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2s.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2s.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2s.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_i2s.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const0.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const0.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const0.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const0.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iadd_const3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iaload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iaload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iaload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iaload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iand.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iand.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iand.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iand.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iconst.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iconst.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iconst.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iconst.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_idiv.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_idiv.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_idiv.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_idiv.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_idiv2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_idiv2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_idiv2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_idiv2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq_3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq_3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq_3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifeq_3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge_3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge_3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge_3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifge_3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifgt.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifgt.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifgt.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifgt.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmplt1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmplt1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmplt1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmplt1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmplt2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmplt2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmplt2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmplt2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmpne1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmpne1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmpne1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmpne1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmpne2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmpne2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmpne2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ificmpne2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifle.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifle.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifle.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifle.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iflt.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iflt.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iflt.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iflt.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifne.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifne.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifne.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifne.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull_3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull_3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull_3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnonnull_3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull_3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull_3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull_3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ifnull_3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iinc_4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0_1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0_1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0_1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0_1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_0_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_1_1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_1_1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_1_1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_1_1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iload_3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_imul.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_imul.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_imul.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_imul.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ineg.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ineg.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ineg.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ineg.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_instanceof.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_instanceof.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_instanceof.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_instanceof.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_instanceof01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_instanceof01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_instanceof01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_instanceof01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokeinterface.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokeinterface.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokeinterface.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokeinterface.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokespecial.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokespecial.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokespecial.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokespecial.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokespecial2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokespecial2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokespecial2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokespecial2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokestatic.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokestatic.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokestatic.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokestatic.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokevirtual.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokevirtual.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokevirtual.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_invokevirtual.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ior.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ior.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ior.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ior.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_irem3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ireturn.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ireturn.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ireturn.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ireturn.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ishl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ishl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ishl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ishl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ishr.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ishr.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ishr.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ishr.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_isub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_isub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_isub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_isub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iushr.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iushr.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iushr.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_iushr.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ixor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ixor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ixor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ixor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2d.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2d.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2d.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2d.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2f.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2f.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2f.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2f.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2i.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2i.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2i.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2i.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2i_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2i_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2i_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_l2i_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ladd.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ladd.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ladd.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ladd.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ladd2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ladd2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ladd2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ladd2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_laload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_laload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_laload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_laload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_land.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_land.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_land.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_land.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lcmp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lcmp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lcmp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lcmp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldc_06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_ldiv3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_0.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_0.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_0.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_0.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lload_3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lmul.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lmul.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lmul.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lmul.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lneg.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lneg.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lneg.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lneg.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lookupswitch05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lrem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lrem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lrem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lrem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lrem2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lrem2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lrem2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lrem2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lreturn.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lreturn.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lreturn.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lreturn.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshr.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshr.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshr.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshr.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshr02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshr02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshr02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lshr02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lsub.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lsub.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lsub.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lsub.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lushr.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lushr.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lushr.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lushr.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lxor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lxor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lxor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_lxor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_monitorenter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_monitorenter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_monitorenter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_monitorenter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_monitorenter02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_monitorenter02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_monitorenter02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_monitorenter02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_multianewarray04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_new.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_new.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_new.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_new.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_newarray.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_newarray.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_newarray.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_newarray.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putfield_04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putstatic.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putstatic.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putstatic.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_putstatic.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_saload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_saload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_saload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_saload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_sastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_sastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_sastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_sastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_tableswitch4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_wide01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_wide01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_wide01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_wide01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_wide02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_wide02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_wide02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/bytecode/BC_wide02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aaload0.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aaload0.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aaload0.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aaload0.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aaload1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aaload1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aaload1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aaload1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aastore0.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aastore0.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aastore0.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aastore0.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aastore1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aastore1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aastore1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_aastore1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_anewarray.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_anewarray.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_anewarray.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_anewarray.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_arraylength.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_arraylength.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_arraylength.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_arraylength.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow0.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow0.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow0.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow0.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_athrow3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_baload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_baload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_baload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_baload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_bastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_bastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_bastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_bastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_caload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_caload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_caload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_caload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_castore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_castore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_castore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_castore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast3.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast3.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast3.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast3.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast5.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast5.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast5.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast5.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast6.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast6.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast6.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_checkcast6.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_daload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_daload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_daload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_daload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_dastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_dastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_dastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_dastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_faload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_faload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_faload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_faload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_fastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_fastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_fastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_fastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_getfield.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_getfield.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_getfield.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_getfield.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_getfield1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_getfield1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_getfield1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_getfield1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_iaload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_iaload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_iaload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_iaload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_iastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_iastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_iastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_iastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_idiv.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_idiv.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_idiv.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_idiv.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_idiv2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_idiv2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_idiv2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_idiv2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokespecial01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokespecial01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokespecial01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokespecial01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokevirtual01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokevirtual01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokevirtual01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokevirtual01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokevirtual02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokevirtual02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokevirtual02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_invokevirtual02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_irem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_irem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_irem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_irem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_laload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_laload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_laload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_laload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_lastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_lastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_lastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_lastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_ldiv.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_ldiv.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_ldiv.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_ldiv.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_ldiv2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_ldiv2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_ldiv2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_ldiv2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_lrem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_lrem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_lrem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_lrem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_monitorenter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_monitorenter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_monitorenter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_monitorenter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_multianewarray.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_multianewarray.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_multianewarray.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_multianewarray.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_newarray.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_newarray.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_newarray.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_newarray.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_putfield.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_putfield.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_putfield.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_putfield.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_saload.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_saload.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_saload.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_saload.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_sastore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_sastore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_sastore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/BC_sastore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Loop03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NASE_1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NASE_1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NASE_1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NASE_1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NASE_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NASE_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NASE_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NASE_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_00.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_00.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_00.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_00.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_07.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_07.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_07.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_07.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_08.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_08.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_08.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_08.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_09.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_09.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_09.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_09.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_10.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_10.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_10.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_10.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_11.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_11.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_11.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_NPE_11.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_StackOverflowError_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Two03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Catch_Unresolved03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Locals.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Locals.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Locals.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Locals.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Except_Synchronized05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Finally01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Finally01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Finally01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Finally01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Finally02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Finally02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Finally02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Finally02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_AIOOBE_00.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_AIOOBE_00.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_AIOOBE_00.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_AIOOBE_00.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_CCE_00.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_CCE_00.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_CCE_00.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_CCE_00.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_00.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_00.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_00.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_00.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/StackTrace_NPE_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InCatch03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InNested.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InNested.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InNested.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_InNested.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_NPE_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_NPE_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_NPE_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_NPE_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/Throw_Synchronized05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/UntrustedInterfaces.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/UntrustedInterfaces.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/UntrustedInterfaces.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/except/UntrustedInterfaces.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_allocate04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_array04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_control01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_control01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_control01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_control01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_control02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_control02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_control02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_control02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_convert01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_convert01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_convert01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_convert01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_count.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_count.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_count.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_count.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_dead01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_dead01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_dead01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_dead01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_demo01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_demo01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_demo01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_demo01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_field04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_idea.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_idea.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_idea.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_idea.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_inline01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_inline01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_inline01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_inline01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_inline02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_inline02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_inline02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_inline02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_invoke01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_invoke01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_invoke01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_invoke01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_life.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_life.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_life.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_life.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_nest01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_nest01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_nest01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_nest01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_nest02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_nest02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_nest02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_nest02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_scope01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_scope01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_scope01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_scope01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_scope02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_scope02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_scope02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_scope02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_series.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_series.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_series.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_series.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_trees01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_trees01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_trees01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotpath/HP_trees01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6186134.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6186134.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6186134.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6186134.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6196102.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6196102.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6196102.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6196102.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6753639.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6753639.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6753639.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6753639.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6823354.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6823354.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6823354.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6823354.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6850611.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6850611.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6850611.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6850611.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6959129.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6959129.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6959129.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test6959129.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test7005594.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test7005594.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test7005594.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/hotspot/Test7005594.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/CharacterBits.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/CharacterBits.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/CharacterBits.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/CharacterBits.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Class_getName.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Class_getName.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Class_getName.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Class_getName.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/DivideUnsigned.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/DivideUnsigned.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/DivideUnsigned.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/DivideUnsigned.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/EnumMap01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/EnumMap01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/EnumMap01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/EnumMap01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/EnumMap02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/EnumMap02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/EnumMap02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/EnumMap02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/IntegerBits.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/IntegerBits.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/IntegerBits.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/IntegerBits.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/LongBits.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/LongBits.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/LongBits.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/LongBits.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/ShortBits.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/ShortBits.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/ShortBits.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/ShortBits.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_currentTimeMillis01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_currentTimeMillis01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_currentTimeMillis01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_currentTimeMillis01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_currentTimeMillis02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_currentTimeMillis02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_currentTimeMillis02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_currentTimeMillis02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_nanoTime01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_nanoTime01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_nanoTime01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_nanoTime01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_nanoTime02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_nanoTime02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_nanoTime02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_nanoTime02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_setOut.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_setOut.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_setOut.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/System_setOut.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Thread_setName.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Thread_setName.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Thread_setName.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Thread_setName.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/UnsafeAccess01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/UnsafeAccess01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/UnsafeAccess01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/UnsafeAccess01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/UnsafeAllocateInstance01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/UnsafeAllocateInstance01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/UnsafeAllocateInstance01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/UnsafeAllocateInstance01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Unsafe_compareAndSwap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Unsafe_compareAndSwap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Unsafe_compareAndSwap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Unsafe_compareAndSwap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Unsafe_compareAndSwapNullCheck.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Unsafe_compareAndSwapNullCheck.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Unsafe_compareAndSwapNullCheck.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/jdk/Unsafe_compareAndSwapNullCheck.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Boxed_TYPE_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Boxed_TYPE_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Boxed_TYPE_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Boxed_TYPE_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Bridge_method01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Bridge_method01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Bridge_method01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Bridge_method01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/ClassLoader_loadClass01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/ClassLoader_loadClass01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/ClassLoader_loadClass01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/ClassLoader_loadClass01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_Literal01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_Literal01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_Literal01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_Literal01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_asSubclass01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_asSubclass01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_asSubclass01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_asSubclass01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_cast01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_cast01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_cast01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_cast01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_cast02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_cast02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_cast02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_cast02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_forName05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getComponentType01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getComponentType01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getComponentType01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getComponentType01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getInterfaces01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getInterfaces01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getInterfaces01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getInterfaces01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getModifiers01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getModifiers01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getModifiers01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getModifiers01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getModifiers02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getModifiers02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getModifiers02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getModifiers02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getName01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getName01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getName01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getName01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getName02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getName02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getName02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getName02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSimpleName01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSimpleName01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSimpleName01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSimpleName01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSimpleName02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSimpleName02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSimpleName02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSimpleName02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSuperClass01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSuperClass01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSuperClass01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_getSuperClass01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isArray01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isArray01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isArray01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isArray01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isAssignableFrom03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance07.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance07.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance07.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInstance07.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInterface01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInterface01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInterface01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isInterface01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isPrimitive01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isPrimitive01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isPrimitive01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Class_isPrimitive01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_conditional.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_conditional.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_conditional.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_conditional.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_toString.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_toString.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_toString.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Double_toString.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_conditional.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_conditional.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_conditional.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Float_conditional.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greater03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_greaterEqual03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_less03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Int_lessEqual03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/JDK_ClassLoaders01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/JDK_ClassLoaders01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/JDK_ClassLoaders01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/JDK_ClassLoaders01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/JDK_ClassLoaders02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/JDK_ClassLoaders02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/JDK_ClassLoaders02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/JDK_ClassLoaders02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/LambdaEagerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/LambdaEagerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/LambdaEagerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/LambdaEagerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greater03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_greaterEqual03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_less03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_lessEqual03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_reverseBytes01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_reverseBytes01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_reverseBytes01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_reverseBytes01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_reverseBytes02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_reverseBytes02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_reverseBytes02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Long_reverseBytes02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_abs.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_abs.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_abs.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_abs.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_cos.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_cos.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_cos.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_cos.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_exact.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_exact.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_exact.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_exact.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_exp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_exp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_exp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_exp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_log.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_log.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_log.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_log.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_log10.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_log10.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_log10.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_log10.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_pow.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_pow.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_pow.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_pow.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_round.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_round.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_round.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_round.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_sin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_sin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_sin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_sin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_sqrt.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_sqrt.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_sqrt.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_sqrt.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_tan.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_tan.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_tan.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Math_tan.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_clone01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_clone01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_clone01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_clone01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_clone02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_clone02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_clone02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_clone02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_equals01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_equals01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_equals01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_equals01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_getClass01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_getClass01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_getClass01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_getClass01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_hashCode01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_hashCode01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_hashCode01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_hashCode01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_hashCode02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_hashCode02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_hashCode02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_hashCode02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notify01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notify01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notify01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notify01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notify02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notify02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notify02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notify02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notifyAll01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notifyAll01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notifyAll01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notifyAll01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notifyAll02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notifyAll02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notifyAll02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_notifyAll02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_toString01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_toString01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_toString01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_toString01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_toString02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_toString02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_toString02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_toString02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/Object_wait03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/ProcessEnvironment_init.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/ProcessEnvironment_init.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/ProcessEnvironment_init.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/ProcessEnvironment_init.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/StringCoding_Scale.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/StringCoding_Scale.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/StringCoding_Scale.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/StringCoding_Scale.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_intern03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_valueOf01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_valueOf01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_valueOf01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/String_valueOf01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/System_identityHashCode01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/System_identityHashCode01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/System_identityHashCode01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/lang/System_identityHashCode01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/DegeneratedLoop.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/DegeneratedLoop.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/DegeneratedLoop.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/DegeneratedLoop.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop07.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop07.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop07.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop07.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop07_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop07_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop07_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop07_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop08.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop08.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop08.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop08.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop09.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop09.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop09.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop09.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop09_2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop09_2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop09_2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop09_2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop11.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop11.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop11.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop11.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop12.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop12.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop12.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop12.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop13.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop13.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop13.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop13.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop14.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop14.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop14.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop14.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop15.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop15.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop15.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop15.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop16.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop16.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop16.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop16.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop17.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop17.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop17.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/Loop17.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopEscape.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopEscape.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopEscape.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopEscape.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopInline.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopInline.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopInline.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopInline.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopLastIndexOf.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopLastIndexOf.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopLastIndexOf.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopLastIndexOf.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopNewInstance.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopNewInstance.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopNewInstance.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopNewInstance.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopParseLong.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopParseLong.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopParseLong.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopParseLong.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopPhi.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopPhi.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopPhi.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopPhi.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopPhiResolutionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopPhiResolutionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopPhiResolutionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopPhiResolutionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopSpilling.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopSpilling.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopSpilling.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopSpilling.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopSwitch01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopSwitch01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopSwitch01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopSwitch01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopUnroll.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopUnroll.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopUnroll.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/LoopUnroll.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/SpillLoopPhiVariableAtDefinition.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/SpillLoopPhiVariableAtDefinition.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/SpillLoopPhiVariableAtDefinition.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/loop/SpillLoopPhiVariableAtDefinition.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ArrayCompare01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ArrayCompare01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ArrayCompare01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ArrayCompare01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ArrayCompare02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ArrayCompare02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ArrayCompare02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ArrayCompare02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BC_invokevirtual2.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BC_invokevirtual2.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BC_invokevirtual2.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BC_invokevirtual2.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigByteParams01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigByteParams01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigByteParams01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigByteParams01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigDoubleParams02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigDoubleParams02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigDoubleParams02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigDoubleParams02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigFloatParams01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigFloatParams01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigFloatParams01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigFloatParams01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigFloatParams02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigFloatParams02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigFloatParams02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigFloatParams02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigIntParams01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigIntParams01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigIntParams01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigIntParams01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigIntParams02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigIntParams02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigIntParams02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigIntParams02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigInterfaceParams01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigInterfaceParams01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigInterfaceParams01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigInterfaceParams01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigLongParams02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigLongParams02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigLongParams02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigLongParams02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigMixedParams04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigObjectParams01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigObjectParams01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigObjectParams01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigObjectParams01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigObjectParams02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigObjectParams02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigObjectParams02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigObjectParams02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigParamsAlignment.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigParamsAlignment.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigParamsAlignment.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigParamsAlignment.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigShortParams01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigShortParams01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigShortParams01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigShortParams01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigVirtualParams01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigVirtualParams01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigVirtualParams01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/BigVirtualParams01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Bubblesort.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Bubblesort.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Bubblesort.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Bubblesort.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ConstantLoadTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ConstantLoadTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ConstantLoadTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ConstantLoadTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Fibonacci.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Fibonacci.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Fibonacci.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Fibonacci.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/FloatingReads.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/FloatingReads.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/FloatingReads.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/FloatingReads.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeInterface_04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeVirtual_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeVirtual_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeVirtual_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeVirtual_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeVirtual_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeVirtual_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeVirtual_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/InvokeVirtual_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Matrix01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Matrix01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Matrix01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/Matrix01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ReferenceMap01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ReferenceMap01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ReferenceMap01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/ReferenceMap01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/StrangeFrames.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/StrangeFrames.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/StrangeFrames.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/StrangeFrames.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/String_format01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/String_format01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/String_format01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/String_format01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/String_format02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/String_format02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/String_format02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/String_format02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_String01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_String01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_String01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_String01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_Unroll.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_Unroll.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_Unroll.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_Unroll.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_boolean01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_boolean01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_boolean01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_boolean01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_byte01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_byte01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_byte01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_byte01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_char01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_char01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_char01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_char01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_double01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_double01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_double01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_double01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_float01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_float01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_float01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_float01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_int01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_int01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_int01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_int01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_long01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_long01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_long01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_long01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_short01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_short01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_short01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/micro/VarArgs_short01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ABCE_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopy06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopyGeneric.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopyGeneric.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopyGeneric.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayCopyGeneric.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayLength01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayLength01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayLength01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ArrayLength01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_idiv_16.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_idiv_16.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_idiv_16.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_idiv_16.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_idiv_4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_idiv_4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_idiv_4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_idiv_4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_imul_16.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_imul_16.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_imul_16.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_imul_16.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_imul_4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_imul_4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_imul_4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_imul_4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_ldiv_16.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_ldiv_16.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_ldiv_16.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_ldiv_16.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_ldiv_4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_ldiv_4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_ldiv_4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_ldiv_4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lmul_16.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lmul_16.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lmul_16.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lmul_16.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lmul_4.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lmul_4.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lmul_4.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lmul_4.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C16.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C16.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C16.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C16.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C24.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C24.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C24.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C24.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C32.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C32.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C32.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BC_lshr_C32.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BlockSkip01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BlockSkip01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BlockSkip01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BlockSkip01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BoxingIdentity.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BoxingIdentity.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BoxingIdentity.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/BoxingIdentity.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Cmov01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Cmov01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Cmov01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Cmov01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Cmov02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Cmov02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Cmov02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Cmov02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Conditional01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Conditional01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Conditional01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Conditional01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConditionalElimination01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConditionalElimination01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConditionalElimination01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConditionalElimination01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConditionalElimination02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConditionalElimination02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConditionalElimination02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConditionalElimination02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConvertCompare.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConvertCompare.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConvertCompare.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ConvertCompare.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/DeadCode01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/DeadCode01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/DeadCode01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/DeadCode01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/DeadCode02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/DeadCode02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/DeadCode02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/DeadCode02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Cast01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Cast01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Cast01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Cast01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Convert04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Double03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Float01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Float01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Float01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Float01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Float02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Float02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Float02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Float02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_InstanceOf01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_InstanceOf01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_InstanceOf01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_InstanceOf01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Int01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Int01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Int01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Int01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Int02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Int02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Int02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Int02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Long01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Long01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Long01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Long01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Long02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Long02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Long02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Long02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Math01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Math01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Math01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Fold_Math01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/InferStamp01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/InferStamp01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/InferStamp01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/InferStamp01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Inline01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Inline01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Inline01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Inline01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Inline02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Inline02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Inline02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Inline02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/LLE_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/LLE_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/LLE_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/LLE_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/List_reorder_bug.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/List_reorder_bug.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/List_reorder_bug.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/List_reorder_bug.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Logic0.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Logic0.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Logic0.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Logic0.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/LongToSomethingArray01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/LongToSomethingArray01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/LongToSomethingArray01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/LongToSomethingArray01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NCE_FlowSensitive05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_byte03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_char03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Narrow_short03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NestedLoop_EA.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NestedLoop_EA.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NestedLoop_EA.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/NestedLoop_EA.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Phi03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ReassociateConstants.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ReassociateConstants.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ReassociateConstants.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/ReassociateConstants.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Convert01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Convert01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Convert01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Convert01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Double01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Double01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Double01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Double01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Float01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Float01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Float01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Float01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Int04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_IntShift01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_IntShift01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_IntShift01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_IntShift01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_IntShift02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_IntShift02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_IntShift02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_IntShift02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_Long04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_LongShift01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_LongShift01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_LongShift01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_LongShift01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_LongShift02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_LongShift02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_LongShift02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Reduce_LongShift02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/SchedulingBug_01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/SchedulingBug_01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/SchedulingBug_01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/SchedulingBug_01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/SignExtendShort.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/SignExtendShort.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/SignExtendShort.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/SignExtendShort.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Switch01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Switch01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Switch01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Switch01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Switch02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Switch02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Switch02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/Switch02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/TypeCastElem.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/TypeCastElem.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/TypeCastElem.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/TypeCastElem.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/UnsafeDeopt.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/UnsafeDeopt.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/UnsafeDeopt.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/UnsafeDeopt.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Cast01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Cast01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Cast01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Cast01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Cast02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Cast02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Cast02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Cast02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Convert01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Convert01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Convert01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Convert01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Convert02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Convert02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Convert02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Convert02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Double01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Double01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Double01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Double01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Double02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Double02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Double02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Double02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Field01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Field01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Field01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Field01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Field02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Field02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Field02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Field02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Float01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Float01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Float01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Float01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Float02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Float02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Float02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Float02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_InstanceOf03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Int03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Long03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Loop01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Loop01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Loop01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/optimize/VN_Loop01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_get03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getBoolean01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getBoolean01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getBoolean01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getBoolean01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getByte01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getByte01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getByte01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getByte01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getChar01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getChar01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getChar01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getChar01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getDouble01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getDouble01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getDouble01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getDouble01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getFloat01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getFloat01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getFloat01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getFloat01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getInt01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getInt01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getInt01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getInt01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getLength01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getLength01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getLength01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getLength01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getLong01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getLong01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getLong01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getLong01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getShort01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getShort01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getShort01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_getShort01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_newInstance06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_set03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setBoolean01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setBoolean01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setBoolean01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setBoolean01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setByte01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setByte01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setByte01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setByte01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setChar01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setChar01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setChar01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setChar01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setDouble01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setDouble01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setDouble01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setDouble01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setFloat01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setFloat01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setFloat01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setFloat01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setInt01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setInt01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setInt01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setInt01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setLong01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setLong01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setLong01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setLong01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setShort01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setShort01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setShort01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Array_setShort01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getDeclaredField01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getDeclaredField01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getDeclaredField01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getDeclaredField01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getDeclaredMethod01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getDeclaredMethod01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getDeclaredMethod01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getDeclaredMethod01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getField01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getField01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getField01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getField01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getField02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getField02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getField02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getField02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getMethod01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getMethod01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getMethod01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getMethod01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getMethod02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getMethod02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getMethod02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_getMethod02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance06.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance06.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance06.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance06.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance07.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance07.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance07.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Class_newInstance07.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_get04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_getType01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_getType01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_getType01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_getType01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Field_set03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_except01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_except01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_except01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_except01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_main03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_virtual01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_virtual01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_virtual01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Invoke_virtual01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Method_getParameterTypes01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Method_getParameterTypes01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Method_getParameterTypes01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Method_getParameterTypes01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Method_getReturnType01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Method_getReturnType01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Method_getReturnType01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/reflect/Method_getReturnType01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitor_contended01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitor_contended01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitor_contended01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitor_contended01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitor_notowner01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitor_notowner01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitor_notowner01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitor_notowner01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitorenter01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitorenter01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitorenter01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitorenter01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitorenter02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitorenter02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitorenter02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Monitorenter02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Object_wait04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/SynchronizedLoopExit01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/SynchronizedLoopExit01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/SynchronizedLoopExit01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/SynchronizedLoopExit01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/ThreadLocal03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_currentThread01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_currentThread01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_currentThread01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_currentThread01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_getState01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_getState01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_getState01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_getState01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_getState02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_getState02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_getState02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_getState02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_holdsLock01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_holdsLock01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_holdsLock01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_holdsLock01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isAlive01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isAlive01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isAlive01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isAlive01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted04.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted04.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted04.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted04.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted05.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted05.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted05.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_isInterrupted05.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join03.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join03.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join03.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_join03.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_new01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_new01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_new01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_new01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_new02.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_new02.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_new02.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_new02.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_setPriority01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_setPriority01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_setPriority01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_setPriority01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_sleep01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_sleep01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_sleep01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_sleep01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_yield01.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_yield01.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_yield01.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.jtt/src/org/graalvm/compiler/jtt/threads/Thread_yield01.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64AddressValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64AddressValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64AddressValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64AddressValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ArithmeticLIRGeneratorTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ArithmeticLIRGeneratorTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ArithmeticLIRGeneratorTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ArithmeticLIRGeneratorTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ArithmeticOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ArithmeticOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ArithmeticOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ArithmeticOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BitManipulationOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BitManipulationOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BitManipulationOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BitManipulationOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BlockEndOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BlockEndOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BlockEndOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BlockEndOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BreakpointOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BreakpointOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BreakpointOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64BreakpointOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Call.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Call.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Call.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Call.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Compare.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Compare.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Compare.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Compare.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ControlFlow.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ControlFlow.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ControlFlow.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ControlFlow.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64FrameMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64FrameMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64FrameMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64FrameMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64FrameMapBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64FrameMapBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64FrameMapBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64FrameMapBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64LIRInstruction.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64LIRInstruction.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64LIRInstruction.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64LIRInstruction.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Move.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Move.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Move.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64Move.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64PauseOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64PauseOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64PauseOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64PauseOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64PrefetchOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64PrefetchOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64PrefetchOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64PrefetchOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ReinterpretOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ReinterpretOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ReinterpretOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64ReinterpretOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64SignExtendOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64SignExtendOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64SignExtendOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.aarch64/src/org/graalvm/compiler/lir/aarch64/AArch64SignExtendOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64AddressValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64AddressValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64AddressValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64AddressValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Arithmetic.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Arithmetic.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Arithmetic.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Arithmetic.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ArithmeticLIRGeneratorTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ArithmeticLIRGeneratorTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ArithmeticLIRGeneratorTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ArithmeticLIRGeneratorTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ArrayEqualsOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ArrayEqualsOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ArrayEqualsOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ArrayEqualsOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Binary.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Binary.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Binary.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Binary.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BinaryConsumer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BinaryConsumer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BinaryConsumer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BinaryConsumer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BlockEndOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BlockEndOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BlockEndOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BlockEndOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BreakpointOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BreakpointOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BreakpointOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64BreakpointOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ByteSwapOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ByteSwapOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ByteSwapOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ByteSwapOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64CCall.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64CCall.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64CCall.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64CCall.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Call.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Call.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Call.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Call.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ClearRegisterOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ClearRegisterOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ClearRegisterOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ClearRegisterOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ControlFlow.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ControlFlow.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ControlFlow.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ControlFlow.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64FrameMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64FrameMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64FrameMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64FrameMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64FrameMapBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64FrameMapBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64FrameMapBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64FrameMapBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64LIRInstruction.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64LIRInstruction.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64LIRInstruction.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64LIRInstruction.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MathIntrinsicBinaryOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MathIntrinsicBinaryOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MathIntrinsicBinaryOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MathIntrinsicBinaryOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MathIntrinsicUnaryOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MathIntrinsicUnaryOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MathIntrinsicUnaryOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MathIntrinsicUnaryOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Move.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Move.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Move.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Move.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MulDivOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MulDivOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MulDivOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64MulDivOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64PauseOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64PauseOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64PauseOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64PauseOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64PrefetchOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64PrefetchOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64PrefetchOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64PrefetchOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ReadTimestampCounter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ReadTimestampCounter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ReadTimestampCounter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ReadTimestampCounter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64RestoreRegistersOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64RestoreRegistersOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64RestoreRegistersOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64RestoreRegistersOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64SaveRegistersOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64SaveRegistersOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64SaveRegistersOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64SaveRegistersOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ShiftOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ShiftOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ShiftOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ShiftOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64SignExtendOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64SignExtendOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64SignExtendOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64SignExtendOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Unary.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Unary.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Unary.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64Unary.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64VZeroUpper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64VZeroUpper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64VZeroUpper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64VZeroUpper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ZapRegistersOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ZapRegistersOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ZapRegistersOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ZapRegistersOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ZapStackOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ZapStackOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ZapStackOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/AMD64ZapStackOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/phases/StackMoveOptimizationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/phases/StackMoveOptimizationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/phases/StackMoveOptimizationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.amd64/src/org/graalvm/compiler/lir/amd64/phases/StackMoveOptimizationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/ConstantStackCastTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/ConstantStackCastTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/ConstantStackCastTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/ConstantStackCastTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTestSpecification.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTestSpecification.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTestSpecification.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTestSpecification.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTestTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTestTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTestTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/LIRTestTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/SPARCBranchBailoutTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/SPARCBranchBailoutTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/SPARCBranchBailoutTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/SPARCBranchBailoutTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/StackMoveTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/StackMoveTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/StackMoveTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.jtt/src/org/graalvm/compiler/lir/jtt/StackMoveTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCAddressValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCAddressValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCAddressValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCAddressValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCArithmetic.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCArithmetic.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCArithmetic.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCArithmetic.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCArrayEqualsOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCArrayEqualsOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCArrayEqualsOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCArrayEqualsOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBitManipulationOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBitManipulationOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBitManipulationOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBitManipulationOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBlockEndOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBlockEndOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBlockEndOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBlockEndOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBreakpointOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBreakpointOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBreakpointOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCBreakpointOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCByteSwapOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCByteSwapOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCByteSwapOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCByteSwapOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCCall.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCCall.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCCall.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCCall.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCControlFlow.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCControlFlow.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCControlFlow.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCControlFlow.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCDelayedControlTransfer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCDelayedControlTransfer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCDelayedControlTransfer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCDelayedControlTransfer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFloatCompareOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFloatCompareOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFloatCompareOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFloatCompareOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFrameMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFrameMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFrameMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFrameMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFrameMapBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFrameMapBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFrameMapBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCFrameMapBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCImmediateAddressValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCImmediateAddressValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCImmediateAddressValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCImmediateAddressValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCIndexedAddressValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCIndexedAddressValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCIndexedAddressValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCIndexedAddressValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCJumpOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCJumpOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCJumpOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCJumpOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLIRInstruction.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLIRInstruction.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLIRInstruction.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLIRInstruction.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLIRInstructionMixin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLIRInstructionMixin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLIRInstructionMixin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLIRInstructionMixin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLoadConstantTableBaseOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLoadConstantTableBaseOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLoadConstantTableBaseOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCLoadConstantTableBaseOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCMove.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCMove.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCMove.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCMove.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCOP3Op.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCOP3Op.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCOP3Op.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCOP3Op.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCOPFOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCOPFOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCOPFOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCOPFOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCPauseOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCPauseOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCPauseOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCPauseOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCPrefetchOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCPrefetchOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCPrefetchOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCPrefetchOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCSaveRegistersOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCSaveRegistersOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCSaveRegistersOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCSaveRegistersOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCTailDelayedLIRInstruction.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCTailDelayedLIRInstruction.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCTailDelayedLIRInstruction.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.sparc/src/org/graalvm/compiler/lir/sparc/SPARCTailDelayedLIRInstruction.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/CompositeValueReplacementTest1.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/CompositeValueReplacementTest1.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/CompositeValueReplacementTest1.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/CompositeValueReplacementTest1.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/GenericValueMapTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/GenericValueMapTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/GenericValueMapTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/GenericValueMapTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/alloc/trace/TraceGlobalMoveResolutionMappingTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/alloc/trace/TraceGlobalMoveResolutionMappingTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/alloc/trace/TraceGlobalMoveResolutionMappingTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir.test/src/org/graalvm/compiler/lir/test/alloc/trace/TraceGlobalMoveResolutionMappingTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/BailoutAndRestartBackendException.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/BailoutAndRestartBackendException.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/BailoutAndRestartBackendException.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/BailoutAndRestartBackendException.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/CompositeValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/CompositeValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/CompositeValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/CompositeValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/CompositeValueClass.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/CompositeValueClass.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/CompositeValueClass.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/CompositeValueClass.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ConstantValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ConstantValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ConstantValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ConstantValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ControlFlowOptimizer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ControlFlowOptimizer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ControlFlowOptimizer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ControlFlowOptimizer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/EdgeMoveOptimizer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/EdgeMoveOptimizer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/EdgeMoveOptimizer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/EdgeMoveOptimizer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/FullInfopointOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/FullInfopointOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/FullInfopointOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/FullInfopointOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionStateProcedure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionStateProcedure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionStateProcedure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionStateProcedure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionValueConsumer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionValueConsumer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionValueConsumer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionValueConsumer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionValueProcedure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionValueProcedure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionValueProcedure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/InstructionValueProcedure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIR.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIR.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIR.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIR.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRFrameState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRFrameState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRFrameState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRFrameState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInsertionBuffer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInsertionBuffer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInsertionBuffer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInsertionBuffer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInstruction.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInstruction.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInstruction.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInstruction.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInstructionClass.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInstructionClass.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInstructionClass.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRInstructionClass.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRIntrospection.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRIntrospection.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRIntrospection.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRIntrospection.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRValueUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRValueUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRValueUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRValueUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LIRVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LabelRef.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LabelRef.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LabelRef.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/LabelRef.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/NullCheckOptimizer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/NullCheckOptimizer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/NullCheckOptimizer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/NullCheckOptimizer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/Opcode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/Opcode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/Opcode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/Opcode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/RedundantMoveElimination.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/RedundantMoveElimination.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/RedundantMoveElimination.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/RedundantMoveElimination.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/StandardOp.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/StandardOp.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/StandardOp.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/StandardOp.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/StateProcedure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/StateProcedure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/StateProcedure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/StateProcedure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/SwitchStrategy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/SwitchStrategy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/SwitchStrategy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/SwitchStrategy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ValueConsumer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ValueConsumer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ValueConsumer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ValueConsumer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ValueProcedure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ValueProcedure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ValueProcedure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ValueProcedure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/Variable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/Variable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/Variable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/Variable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/VirtualStackSlot.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/VirtualStackSlot.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/VirtualStackSlot.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/VirtualStackSlot.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/AllocationStageVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/AllocationStageVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/AllocationStageVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/AllocationStageVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/OutOfRegistersException.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/OutOfRegistersException.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/OutOfRegistersException.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/OutOfRegistersException.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/SaveCalleeSaveRegisters.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/SaveCalleeSaveRegisters.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/SaveCalleeSaveRegisters.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/SaveCalleeSaveRegisters.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/Interval.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/Interval.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/Interval.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/Interval.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/IntervalWalker.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/IntervalWalker.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/IntervalWalker.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/IntervalWalker.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScan.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScan.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScan.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScan.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanAssignLocationsPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanAssignLocationsPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanAssignLocationsPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanAssignLocationsPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanEliminateSpillMovePhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanEliminateSpillMovePhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanEliminateSpillMovePhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanEliminateSpillMovePhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanIntervalDumper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanIntervalDumper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanIntervalDumper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanIntervalDumper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanLifetimeAnalysisPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanLifetimeAnalysisPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanLifetimeAnalysisPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanLifetimeAnalysisPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanOptimizeSpillPositionPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanOptimizeSpillPositionPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanOptimizeSpillPositionPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanOptimizeSpillPositionPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanRegisterAllocationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanRegisterAllocationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanRegisterAllocationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanRegisterAllocationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanResolveDataFlowPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanResolveDataFlowPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanResolveDataFlowPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanResolveDataFlowPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanWalker.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanWalker.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanWalker.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/LinearScanWalker.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/MoveResolver.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/MoveResolver.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/MoveResolver.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/MoveResolver.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/OptimizingLinearScanWalker.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/OptimizingLinearScanWalker.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/OptimizingLinearScanWalker.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/OptimizingLinearScanWalker.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/Range.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/Range.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/Range.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/Range.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/RegisterVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/RegisterVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/RegisterVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/RegisterVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScan.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScan.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScan.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScan.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanEliminateSpillMovePhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanEliminateSpillMovePhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanEliminateSpillMovePhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanEliminateSpillMovePhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanLifetimeAnalysisPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanLifetimeAnalysisPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanLifetimeAnalysisPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanLifetimeAnalysisPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanResolveDataFlowPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanResolveDataFlowPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanResolveDataFlowPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSALinearScanResolveDataFlowPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSAMoveResolver.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSAMoveResolver.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSAMoveResolver.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/lsra/ssa/SSAMoveResolver.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/DefaultTraceRegisterAllocationPolicy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/DefaultTraceRegisterAllocationPolicy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/DefaultTraceRegisterAllocationPolicy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/DefaultTraceRegisterAllocationPolicy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/ShadowedRegisterValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/ShadowedRegisterValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/ShadowedRegisterValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/ShadowedRegisterValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceAllocationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceAllocationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceAllocationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceAllocationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceBuilderPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceBuilderPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceBuilderPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceBuilderPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceGlobalMoveResolutionPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceGlobalMoveResolutionPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceGlobalMoveResolutionPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceGlobalMoveResolutionPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceGlobalMoveResolver.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceGlobalMoveResolver.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceGlobalMoveResolver.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceGlobalMoveResolver.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceRegisterAllocationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceRegisterAllocationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceRegisterAllocationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceRegisterAllocationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceRegisterAllocationPolicy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceRegisterAllocationPolicy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceRegisterAllocationPolicy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceRegisterAllocationPolicy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TraceUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TrivialTraceAllocator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TrivialTraceAllocator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TrivialTraceAllocator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/TrivialTraceAllocator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/bu/BottomUpAllocator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/bu/BottomUpAllocator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/bu/BottomUpAllocator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/bu/BottomUpAllocator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/FixedInterval.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/FixedInterval.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/FixedInterval.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/FixedInterval.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/FixedRange.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/FixedRange.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/FixedRange.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/FixedRange.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/IntervalHint.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/IntervalHint.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/IntervalHint.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/IntervalHint.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/RegisterVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/RegisterVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/RegisterVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/RegisterVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceInterval.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceInterval.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceInterval.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceInterval.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceIntervalWalker.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceIntervalWalker.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceIntervalWalker.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceIntervalWalker.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanAllocationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanAllocationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanAllocationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanAllocationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanAssignLocationsPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanAssignLocationsPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanAssignLocationsPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanAssignLocationsPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanEliminateSpillMovePhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanEliminateSpillMovePhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanEliminateSpillMovePhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanEliminateSpillMovePhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanLifetimeAnalysisPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanLifetimeAnalysisPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanLifetimeAnalysisPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanLifetimeAnalysisPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanRegisterAllocationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanRegisterAllocationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanRegisterAllocationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanRegisterAllocationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanResolveDataFlowPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanResolveDataFlowPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanResolveDataFlowPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanResolveDataFlowPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanWalker.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanWalker.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanWalker.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLinearScanWalker.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLocalMoveResolver.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLocalMoveResolver.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLocalMoveResolver.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/alloc/trace/lsra/TraceLocalMoveResolver.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/ArrayDataPointerConstant.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/ArrayDataPointerConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/ArrayDataPointerConstant.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/ArrayDataPointerConstant.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/CompilationResultBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/CompilationResultBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/CompilationResultBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/CompilationResultBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/CompilationResultBuilderFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/CompilationResultBuilderFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/CompilationResultBuilderFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/CompilationResultBuilderFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/DataBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/DataBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/DataBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/DataBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/FrameContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/FrameContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/FrameContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/asm/FrameContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantLoadOptimization.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantLoadOptimization.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantLoadOptimization.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantLoadOptimization.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTree.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTree.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTree.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTree.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTreeAnalyzer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTreeAnalyzer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTreeAnalyzer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTreeAnalyzer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/DefUseTree.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/DefUseTree.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/DefUseTree.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/DefUseTree.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/UseEntry.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/UseEntry.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/UseEntry.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/UseEntry.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/VariableMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/VariableMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/VariableMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/VariableMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/debug/IntervalDumper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/debug/IntervalDumper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/debug/IntervalDumper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/debug/IntervalDumper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/debug/LIRGenerationDebugContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/debug/LIRGenerationDebugContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/debug/LIRGenerationDebugContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/debug/LIRGenerationDebugContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/LocationMarker.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/LocationMarker.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/LocationMarker.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/LocationMarker.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/LocationMarkerPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/LocationMarkerPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/LocationMarkerPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/LocationMarkerPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/MarkBasePointersPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/MarkBasePointersPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/MarkBasePointersPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/MarkBasePointersPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/RegStackValueSet.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/RegStackValueSet.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/RegStackValueSet.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/RegStackValueSet.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/UniqueWorkList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/UniqueWorkList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/UniqueWorkList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/dfa/UniqueWorkList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilderImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilderImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilderImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilderImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilderTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilderTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilderTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/FrameMapBuilderTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/ReferenceMapBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/ReferenceMapBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/ReferenceMapBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/ReferenceMapBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/SimpleVirtualStackSlot.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/SimpleVirtualStackSlot.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/SimpleVirtualStackSlot.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/SimpleVirtualStackSlot.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/VirtualStackSlotRange.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/VirtualStackSlotRange.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/VirtualStackSlotRange.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/framemap/VirtualStackSlotRange.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/ArithmeticLIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/ArithmeticLIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/ArithmeticLIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/ArithmeticLIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/ArithmeticLIRGeneratorTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/ArithmeticLIRGeneratorTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/ArithmeticLIRGeneratorTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/ArithmeticLIRGeneratorTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/BlockValueMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/BlockValueMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/BlockValueMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/BlockValueMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/DiagnosticLIRGeneratorTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/DiagnosticLIRGeneratorTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/DiagnosticLIRGeneratorTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/DiagnosticLIRGeneratorTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGenerationResult.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGenerationResult.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGenerationResult.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGenerationResult.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGeneratorTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGeneratorTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGeneratorTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/LIRGeneratorTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/PhiResolver.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/PhiResolver.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/PhiResolver.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/PhiResolver.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/VerifyingMoveFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/VerifyingMoveFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/VerifyingMoveFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/gen/VerifyingMoveFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/AllocationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/AllocationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/AllocationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/AllocationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/AllocationStage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/AllocationStage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/AllocationStage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/AllocationStage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyAllocationStage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyAllocationStage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyAllocationStage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyAllocationStage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyPostAllocationOptimizationStage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyPostAllocationOptimizationStage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyPostAllocationOptimizationStage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyPostAllocationOptimizationStage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyPreAllocationOptimizationStage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyPreAllocationOptimizationStage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyPreAllocationOptimizationStage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/EconomyPreAllocationOptimizationStage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/GenericContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/GenericContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/GenericContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/GenericContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRPhaseSuite.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRPhaseSuite.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRPhaseSuite.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRPhaseSuite.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRSuites.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRSuites.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRSuites.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/LIRSuites.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PostAllocationOptimizationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PostAllocationOptimizationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PostAllocationOptimizationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PostAllocationOptimizationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PostAllocationOptimizationStage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PostAllocationOptimizationStage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PostAllocationOptimizationStage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PostAllocationOptimizationStage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PreAllocationOptimizationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PreAllocationOptimizationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PreAllocationOptimizationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PreAllocationOptimizationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PreAllocationOptimizationStage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PreAllocationOptimizationStage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PreAllocationOptimizationStage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/phases/PreAllocationOptimizationStage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MethodProfilingPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MethodProfilingPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MethodProfilingPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MethodProfilingPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveProfiler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveProfiler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveProfiler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveProfiler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveProfilingPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveProfilingPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveProfilingPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveProfilingPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveType.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveType.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveType.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/profiling/MoveType.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssa/SSAUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssa/SSAUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssa/SSAUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssa/SSAUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssa/SSAVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssa/SSAVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssa/SSAVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssa/SSAVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/FastSSIBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/FastSSIBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/FastSSIBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/FastSSIBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIBuilderBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIBuilderBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIBuilderBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIBuilderBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIConstructionPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIConstructionPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIConstructionPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIConstructionPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/ssi/SSIVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/FixPointIntervalBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/FixPointIntervalBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/FixPointIntervalBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/FixPointIntervalBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/LSStackSlotAllocator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/LSStackSlotAllocator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/LSStackSlotAllocator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/LSStackSlotAllocator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/SimpleStackSlotAllocator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/SimpleStackSlotAllocator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/SimpleStackSlotAllocator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/SimpleStackSlotAllocator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackInterval.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackInterval.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackInterval.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackInterval.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackIntervalDumper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackIntervalDumper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackIntervalDumper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackIntervalDumper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackSlotAllocatorUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackSlotAllocatorUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackSlotAllocatorUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/stackslotalloc/StackSlotAllocatorUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/GenericValueMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/GenericValueMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/GenericValueMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/GenericValueMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/IndexedValueMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/IndexedValueMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/IndexedValueMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/IndexedValueMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/RegisterMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/RegisterMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/RegisterMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/RegisterMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/ValueMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/ValueMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/ValueMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/ValueMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/ValueSet.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/ValueSet.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/ValueSet.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/ValueSet.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/VariableVirtualStackValueMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/VariableVirtualStackValueMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/VariableVirtualStackValueMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/util/VariableVirtualStackValueMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/ContextlessLoopPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/ContextlessLoopPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/ContextlessLoopPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/ContextlessLoopPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopFullUnrollPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopFullUnrollPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopFullUnrollPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopFullUnrollPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopPeelingPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopPeelingPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopPeelingPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopPeelingPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopSafepointEliminationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopSafepointEliminationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopSafepointEliminationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopSafepointEliminationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopTransformations.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopTransformations.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopTransformations.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopTransformations.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopUnswitchingPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopUnswitchingPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopUnswitchingPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/LoopUnswitchingPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/ReassociateInvariantPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/ReassociateInvariantPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/ReassociateInvariantPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop.phases/src/org/graalvm/compiler/loop/phases/ReassociateInvariantPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/BasicInductionVariable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/BasicInductionVariable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/BasicInductionVariable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/BasicInductionVariable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/CountedLoopInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/CountedLoopInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/CountedLoopInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/CountedLoopInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DefaultLoopPolicies.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DefaultLoopPolicies.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DefaultLoopPolicies.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DefaultLoopPolicies.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedConvertedInductionVariable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedConvertedInductionVariable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedConvertedInductionVariable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedConvertedInductionVariable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedInductionVariable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedInductionVariable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedInductionVariable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedInductionVariable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedOffsetInductionVariable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedOffsetInductionVariable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedOffsetInductionVariable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedOffsetInductionVariable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedScaledInductionVariable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedScaledInductionVariable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedScaledInductionVariable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/DerivedScaledInductionVariable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/InductionVariable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/InductionVariable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/InductionVariable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/InductionVariable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopEx.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopEx.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopEx.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopEx.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragment.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragment.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragment.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragment.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInside.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInside.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInside.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInside.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInsideBefore.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInsideBefore.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInsideBefore.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInsideBefore.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInsideFrom.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInsideFrom.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInsideFrom.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentInsideFrom.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentWhole.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentWhole.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentWhole.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopFragmentWhole.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopPolicies.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopPolicies.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopPolicies.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopPolicies.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopsData.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopsData.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopsData.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/LoopsData.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/MathUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/MathUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/MathUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.loop/src/org/graalvm/compiler/loop/MathUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/ArrayDuplicationBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/ArrayDuplicationBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/ArrayDuplicationBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/ArrayDuplicationBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/GuardedIntrinsicBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/GuardedIntrinsicBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/GuardedIntrinsicBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/GuardedIntrinsicBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/MathFunctionBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/MathFunctionBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/MathFunctionBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/MathFunctionBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/SimpleSyncBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/SimpleSyncBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/SimpleSyncBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/SimpleSyncBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/package-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/package-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/micro/benchmarks/package-info.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/ConditionalEliminationBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/ConditionalEliminationBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/ConditionalEliminationBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/ConditionalEliminationBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/FrameStateAssigmentPhaseBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/FrameStateAssigmentPhaseBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/FrameStateAssigmentPhaseBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/FrameStateAssigmentPhaseBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/GraalBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/GraalBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/GraalBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/GraalBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/GraphCopyBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/GraphCopyBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/GraphCopyBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/GraphCopyBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/NodeBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/NodeBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/NodeBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/NodeBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/SchedulePhaseBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/SchedulePhaseBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/SchedulePhaseBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/SchedulePhaseBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/TestJMH.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/TestJMH.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/TestJMH.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/TestJMH.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/FrameStateAssignmentState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/FrameStateAssignmentState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/FrameStateAssignmentState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/FrameStateAssignmentState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraalState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraalState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraalState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraalState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraalUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraalUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraalUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraalUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraphState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraphState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraphState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/GraphState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/MethodSpec.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/MethodSpec.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/MethodSpec.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/MethodSpec.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/NodesState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/NodesState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/NodesState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/NodesState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/ScheduleState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/ScheduleState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/ScheduleState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/graal/util/ScheduleState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/CompileTimeBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/CompileTimeBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/CompileTimeBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/CompileTimeBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/GraalCompilerState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/GraalCompilerState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/GraalCompilerState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/GraalCompilerState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/RegisterAllocationTimeBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/RegisterAllocationTimeBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/RegisterAllocationTimeBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/RegisterAllocationTimeBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/ControlFlowGraphState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/ControlFlowGraphState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/ControlFlowGraphState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/ControlFlowGraphState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/TraceBuilderBenchmark.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/TraceBuilderBenchmark.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/TraceBuilderBenchmark.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/TraceBuilderBenchmark.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/TraceLSRAIntervalBuildingBench.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/TraceLSRAIntervalBuildingBench.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/TraceLSRAIntervalBuildingBench.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.microbenchmarks/src/org/graalvm/compiler/microbenchmarks/lir/trace/TraceLSRAIntervalBuildingBench.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/META-INF/services/javax.annotation.processing.Processor b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/META-INF/services/javax.annotation.processing.Processor
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/META-INF/services/javax.annotation.processing.Processor
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/META-INF/services/javax.annotation.processing.Processor
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/ElementException.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/ElementException.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/ElementException.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/ElementException.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/GraphNodeProcessor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/GraphNodeProcessor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/GraphNodeProcessor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/GraphNodeProcessor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/GraphNodeVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/GraphNodeVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/GraphNodeVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo.processor/src/org/graalvm/compiler/nodeinfo/processor/GraphNodeVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/InputType.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/InputType.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/InputType.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/InputType.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeCycles.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeCycles.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeCycles.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeCycles.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeSize.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeSize.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeSize.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/NodeSize.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/StructuralInput.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/StructuralInput.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/StructuralInput.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/StructuralInput.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/Verbosity.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/Verbosity.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/Verbosity.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodeinfo/src/org/graalvm/compiler/nodeinfo/Verbosity.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/AbstractObjectStampTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/AbstractObjectStampTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/AbstractObjectStampTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/AbstractObjectStampTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/IfNodeCanonicalizationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/IfNodeCanonicalizationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/IfNodeCanonicalizationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/IfNodeCanonicalizationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/IntegerStampTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/IntegerStampTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/IntegerStampTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/IntegerStampTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/LoopLivenessTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/LoopLivenessTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/LoopLivenessTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/LoopLivenessTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/LoopPhiCanonicalizerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/LoopPhiCanonicalizerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/LoopPhiCanonicalizerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/LoopPhiCanonicalizerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/NegateNodeCanonicalizationTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/NegateNodeCanonicalizationTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/NegateNodeCanonicalizationTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/NegateNodeCanonicalizationTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampJoinTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampJoinTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampJoinTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampJoinTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampMeetTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampMeetTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampMeetTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampMeetTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ObjectStampTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampDoubleToLongTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampDoubleToLongTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampDoubleToLongTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampDoubleToLongTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampFloatToIntTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampFloatToIntTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampFloatToIntTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampFloatToIntTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampIntToFloatTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampIntToFloatTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampIntToFloatTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampIntToFloatTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampLongToDoubleTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampLongToDoubleTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampLongToDoubleTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampLongToDoubleTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ReinterpretStampTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ShortCircuitOrNodeTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ShortCircuitOrNodeTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ShortCircuitOrNodeTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes.test/src/org/graalvm/compiler/nodes/test/ShortCircuitOrNodeTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractBeginNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractBeginNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractBeginNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractBeginNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractDeoptimizeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractDeoptimizeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractDeoptimizeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractDeoptimizeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractEndNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractEndNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractEndNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractEndNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractFixedGuardNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractFixedGuardNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractFixedGuardNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractFixedGuardNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractLocalNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractLocalNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractLocalNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractLocalNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractMergeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractMergeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractMergeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractMergeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractStateSplit.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractStateSplit.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractStateSplit.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/AbstractStateSplit.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ArithmeticOperation.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ArithmeticOperation.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ArithmeticOperation.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ArithmeticOperation.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BeginNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BeginNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BeginNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BeginNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BeginStateSplitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BeginStateSplitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BeginStateSplitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BeginStateSplitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BinaryOpLogicNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BinaryOpLogicNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BinaryOpLogicNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BinaryOpLogicNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BreakpointNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BreakpointNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BreakpointNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/BreakpointNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CallTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CallTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CallTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CallTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CanonicalizableLocation.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CanonicalizableLocation.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CanonicalizableLocation.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/CanonicalizableLocation.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ConditionAnchorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ConditionAnchorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ConditionAnchorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ConditionAnchorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ConstantNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ConstantNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ConstantNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ConstantNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ControlSinkNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ControlSinkNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ControlSinkNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ControlSinkNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ControlSplitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ControlSplitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ControlSplitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ControlSplitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingFixedWithNextNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingFixedWithNextNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingFixedWithNextNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingFixedWithNextNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingGuard.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingGuard.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingGuard.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingGuard.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DeoptimizingNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DirectCallTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DirectCallTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DirectCallTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DirectCallTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DynamicDeoptimizeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DynamicDeoptimizeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DynamicDeoptimizeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DynamicDeoptimizeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DynamicPiNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DynamicPiNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DynamicPiNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/DynamicPiNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EncodedGraph.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EncodedGraph.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EncodedGraph.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EncodedGraph.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EndNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EndNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EndNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EndNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EntryMarkerNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EntryMarkerNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EntryMarkerNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EntryMarkerNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EntryProxyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EntryProxyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EntryProxyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/EntryProxyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FieldLocationIdentity.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FieldLocationIdentity.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FieldLocationIdentity.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FieldLocationIdentity.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedGuardNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedGuardNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedGuardNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedGuardNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedNodeInterface.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedNodeInterface.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedNodeInterface.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedNodeInterface.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedWithNextNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedWithNextNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedWithNextNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FixedWithNextNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FloatingAnchoredNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FloatingAnchoredNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FloatingAnchoredNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FloatingAnchoredNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FloatingGuardedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FloatingGuardedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FloatingGuardedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FloatingGuardedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FrameState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FrameState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FrameState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FrameState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FullInfopointNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FullInfopointNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FullInfopointNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/FullInfopointNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GraphDecoder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GraphDecoder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GraphDecoder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GraphDecoder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GraphEncoder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GraphEncoder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GraphEncoder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GraphEncoder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardPhiNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardPhiNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardPhiNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardPhiNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardProxyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardProxyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardProxyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardProxyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardedValueNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardedValueNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardedValueNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/GuardedValueNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/IfNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/IfNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/IfNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/IfNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/IndirectCallTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/IndirectCallTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/IndirectCallTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/IndirectCallTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/Invoke.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/Invoke.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/Invoke.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/Invoke.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/InvokeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/InvokeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/InvokeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/InvokeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/InvokeWithExceptionNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/InvokeWithExceptionNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/InvokeWithExceptionNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/InvokeWithExceptionNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/KillingBeginNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/KillingBeginNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/KillingBeginNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/KillingBeginNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicConstantNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicConstantNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicConstantNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicConstantNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicNegationNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicNegationNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicNegationNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicNegationNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LogicNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopBeginNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopBeginNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopBeginNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopBeginNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopEndNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopEndNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopEndNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopEndNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopExitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopExitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopExitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoopExitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoweredCallTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoweredCallTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoweredCallTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/LoweredCallTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/MergeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/MergeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/MergeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/MergeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/NamedLocationIdentity.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/NamedLocationIdentity.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/NamedLocationIdentity.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/NamedLocationIdentity.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ParameterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ParameterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ParameterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ParameterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PauseNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PauseNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PauseNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PauseNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PhiNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PhiNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PhiNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PhiNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PiArrayNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PiArrayNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PiArrayNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PiArrayNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PiNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PiNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PiNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PiNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PrefetchAllocateNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PrefetchAllocateNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PrefetchAllocateNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/PrefetchAllocateNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ProxyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ProxyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ProxyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ProxyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ReturnNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ReturnNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ReturnNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ReturnNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/SafepointNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/SafepointNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/SafepointNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/SafepointNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ShortCircuitOrNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ShortCircuitOrNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ShortCircuitOrNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ShortCircuitOrNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/SimplifyingGraphDecoder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/SimplifyingGraphDecoder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/SimplifyingGraphDecoder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/SimplifyingGraphDecoder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StartNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StartNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StartNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StartNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StateSplit.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StateSplit.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StateSplit.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StateSplit.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StructuredGraph.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StructuredGraph.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StructuredGraph.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/StructuredGraph.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/TypeCheckHints.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/TypeCheckHints.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/TypeCheckHints.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/TypeCheckHints.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/UnaryOpLogicNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/UnaryOpLogicNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/UnaryOpLogicNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/UnaryOpLogicNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/UnwindNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/UnwindNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/UnwindNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/UnwindNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNodeInterface.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNodeInterface.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNodeInterface.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNodeInterface.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNodeUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNodeUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNodeUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueNodeUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValuePhiNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValuePhiNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValuePhiNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValuePhiNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueProxyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueProxyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueProxyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/ValueProxyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/VirtualState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/VirtualState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/VirtualState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/VirtualState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AbsNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AbsNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AbsNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AbsNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AddNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AddNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AddNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AddNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AndNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AndNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AndNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/AndNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/BinaryArithmeticNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/BinaryArithmeticNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/BinaryArithmeticNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/BinaryArithmeticNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/BinaryNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/BinaryNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/BinaryNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/BinaryNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/CompareNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/CompareNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/CompareNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/CompareNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ConditionalNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ConditionalNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ConditionalNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ConditionalNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ConvertNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ConvertNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ConvertNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ConvertNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/DivNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/DivNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/DivNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/DivNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FixedBinaryNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FixedBinaryNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FixedBinaryNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FixedBinaryNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatConvertNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatConvertNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatConvertNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatConvertNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatEqualsNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatEqualsNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatEqualsNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatEqualsNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatLessThanNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatLessThanNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatLessThanNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatLessThanNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatingNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatingNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatingNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/FloatingNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerBelowNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerBelowNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerBelowNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerBelowNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerConvertNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerConvertNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerConvertNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerConvertNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerDivRemNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerDivRemNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerDivRemNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerDivRemNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerEqualsNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerEqualsNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerEqualsNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerEqualsNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerLessThanNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerLessThanNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerLessThanNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerLessThanNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerTestNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerTestNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerTestNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IntegerTestNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IsNullNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IsNullNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IsNullNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/IsNullNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/LeftShiftNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/LeftShiftNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/LeftShiftNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/LeftShiftNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/MulNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/MulNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/MulNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/MulNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NarrowNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NarrowNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NarrowNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NarrowNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NarrowableArithmeticNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NarrowableArithmeticNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NarrowableArithmeticNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NarrowableArithmeticNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NegateNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NegateNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NegateNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NegateNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NormalizeCompareNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NormalizeCompareNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NormalizeCompareNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NormalizeCompareNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NotNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NotNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NotNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/NotNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ObjectEqualsNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ObjectEqualsNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ObjectEqualsNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ObjectEqualsNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/OrNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/OrNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/OrNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/OrNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/PointerEqualsNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/PointerEqualsNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/PointerEqualsNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/PointerEqualsNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ReinterpretNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ReinterpretNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ReinterpretNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ReinterpretNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/RemNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/RemNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/RemNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/RemNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/RightShiftNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/RightShiftNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/RightShiftNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/RightShiftNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ShiftNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ShiftNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ShiftNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ShiftNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignExtendNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignExtendNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignExtendNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignExtendNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignedDivNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignedDivNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignedDivNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignedDivNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignedRemNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignedRemNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignedRemNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SignedRemNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SqrtNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SqrtNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SqrtNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SqrtNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SubNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SubNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SubNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/SubNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnaryArithmeticNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnaryArithmeticNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnaryArithmeticNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnaryArithmeticNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnaryNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnaryNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnaryNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnaryNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedDivNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedDivNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedDivNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedDivNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedRemNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedRemNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedRemNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedRemNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedRightShiftNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedRightShiftNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedRightShiftNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/UnsignedRightShiftNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/XorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/XorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/XorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/XorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ZeroExtendNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ZeroExtendNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ZeroExtendNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/calc/ZeroExtendNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/Block.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/Block.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/Block.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/Block.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/ControlFlowGraph.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/ControlFlowGraph.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/ControlFlowGraph.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/ControlFlowGraph.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/HIRLoop.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/HIRLoop.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/HIRLoop.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/HIRLoop.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/LocationSet.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/LocationSet.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/LocationSet.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/cfg/LocationSet.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/BindToRegisterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/BindToRegisterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/BindToRegisterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/BindToRegisterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/BlackholeNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/BlackholeNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/BlackholeNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/BlackholeNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/ControlFlowAnchorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/ControlFlowAnchorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/ControlFlowAnchorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/ControlFlowAnchorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/ControlFlowAnchored.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/ControlFlowAnchored.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/ControlFlowAnchored.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/ControlFlowAnchored.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/DynamicCounterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/DynamicCounterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/DynamicCounterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/DynamicCounterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/OpaqueNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/OpaqueNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/OpaqueNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/OpaqueNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/SpillRegistersNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/SpillRegistersNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/SpillRegistersNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/SpillRegistersNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/StringToBytesNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/StringToBytesNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/StringToBytesNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/StringToBytesNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/VerifyHeapNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/VerifyHeapNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/VerifyHeapNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/VerifyHeapNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/WeakCounterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/WeakCounterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/WeakCounterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/WeakCounterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationBeginNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationBeginNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationBeginNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationBeginNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationEndNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationEndNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationEndNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationEndNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationInliningCallback.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationInliningCallback.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationInliningCallback.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationInliningCallback.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/InstrumentationNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/IsMethodInlinedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/IsMethodInlinedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/IsMethodInlinedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/IsMethodInlinedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/MonitorProxyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/MonitorProxyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/MonitorProxyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/MonitorProxyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/RootNameNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/RootNameNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/RootNameNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/debug/instrumentation/RootNameNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/AnchoringNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/AnchoringNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/AnchoringNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/AnchoringNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ArrayRangeWriteNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ArrayRangeWriteNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ArrayRangeWriteNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ArrayRangeWriteNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BoxNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BoxNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BoxNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BoxNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BranchProbabilityNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BranchProbabilityNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BranchProbabilityNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BranchProbabilityNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BytecodeExceptionNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BytecodeExceptionNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BytecodeExceptionNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/BytecodeExceptionNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/FixedValueAnchorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/FixedValueAnchorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/FixedValueAnchorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/FixedValueAnchorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ForeignCallNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ForeignCallNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ForeignCallNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ForeignCallNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GetClassNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GetClassNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GetClassNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GetClassNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardedUnsafeLoadNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardedUnsafeLoadNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardedUnsafeLoadNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardedUnsafeLoadNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardingNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardingNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardingNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/GuardingNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/IntegerSwitchNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/IntegerSwitchNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/IntegerSwitchNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/IntegerSwitchNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/JavaReadNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/JavaReadNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/JavaReadNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/JavaReadNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/JavaWriteNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/JavaWriteNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/JavaWriteNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/JavaWriteNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/LoadHubNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/LoadHubNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/LoadHubNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/LoadHubNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/LoadMethodNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/LoadMethodNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/LoadMethodNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/LoadMethodNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MembarNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MembarNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MembarNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MembarNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MonitorEnter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MonitorEnter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MonitorEnter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MonitorEnter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MonitorExit.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MonitorExit.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MonitorExit.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/MonitorExit.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/NullCheckNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/NullCheckNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/NullCheckNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/NullCheckNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/OSRLocalNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/OSRLocalNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/OSRLocalNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/OSRLocalNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/OSRStartNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/OSRStartNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/OSRStartNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/OSRStartNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/StoreHubNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/StoreHubNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/StoreHubNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/StoreHubNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/SwitchNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/SwitchNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/SwitchNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/SwitchNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnboxNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnboxNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnboxNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnboxNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeAccessNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeAccessNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeAccessNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeAccessNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeCopyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeCopyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeCopyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeCopyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeLoadNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeLoadNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeLoadNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeLoadNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeMemoryLoadNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeMemoryLoadNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeMemoryLoadNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeMemoryLoadNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeMemoryStoreNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeMemoryStoreNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeMemoryStoreNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeMemoryStoreNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeStoreNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeStoreNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeStoreNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/UnsafeStoreNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ValueAnchorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ValueAnchorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ValueAnchorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/extended/ValueAnchorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ClassInitializationPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ClassInitializationPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ClassInitializationPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ClassInitializationPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ForeignCallPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ForeignCallPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ForeignCallPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ForeignCallPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GeneratedInvocationPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GeneratedInvocationPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GeneratedInvocationPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GeneratedInvocationPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderConfiguration.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderConfiguration.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderConfiguration.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderConfiguration.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/GraphBuilderTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InlineInvokePlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InlineInvokePlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InlineInvokePlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InlineInvokePlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/IntrinsicContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/IntrinsicContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/IntrinsicContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/IntrinsicContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugin.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugin.java
index b2f6910c404..dac1acd0c94 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugin.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugin.java
@@ -40,8 +40,7 @@ public interface InvocationPlugin extends GraphBuilderPlugin {
 
     /**
      * The receiver in a non-static method. The class literal for this interface must be used with
-     * {@link InvocationPlugins#put(InvocationPlugin, boolean, boolean, boolean, Class, String, Class...)}
-     * to denote the receiver argument for such a non-static method.
+     * {@link InvocationPlugins#put} to denote the receiver argument for such a non-static method.
      */
     public interface Receiver {
         /**
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugins.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugins.java
similarity index 52%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugins.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugins.java
index 74562c4a031..bc1686ae126 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugins.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/InvocationPlugins.java
@@ -23,8 +23,9 @@
 package org.graalvm.compiler.nodes.graphbuilderconf;
 
 import static java.lang.String.format;
+import static org.graalvm.compiler.nodes.graphbuilderconf.InvocationPlugins.LateClassPlugins.CLOSED_LATE_CLASS_PLUGIN;
 
-import java.lang.reflect.Executable;
+import java.lang.reflect.Constructor;
 import java.lang.reflect.Method;
 import java.lang.reflect.Modifier;
 import java.lang.reflect.Type;
@@ -32,10 +33,8 @@ import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.HashMap;
-import java.util.HashSet;
 import java.util.List;
 import java.util.Map;
-import java.util.Set;
 
 import org.graalvm.compiler.api.replacements.MethodSubstitution;
 import org.graalvm.compiler.api.replacements.MethodSubstitutionRegistry;
@@ -46,12 +45,24 @@ import org.graalvm.compiler.graph.iterators.NodeIterable;
 import org.graalvm.compiler.nodes.ValueNode;
 import org.graalvm.compiler.nodes.graphbuilderconf.InvocationPlugin.Receiver;
 
-import jdk.vm.ci.meta.MetaAccessProvider;
 import jdk.vm.ci.meta.MetaUtil;
 import jdk.vm.ci.meta.ResolvedJavaMethod;
+import jdk.vm.ci.meta.ResolvedJavaType;
+import jdk.vm.ci.meta.Signature;
 
 /**
  * Manages a set of {@link InvocationPlugin}s.
+ *
+ * Most plugins are registered during initialization (i.e., before
+ * {@link #lookupInvocation(ResolvedJavaMethod)} or {@link #getBindings} is called). These
+ * registrations can be made with {@link Registration},
+ * {@link #register(InvocationPlugin, String, String, Type...)},
+ * {@link #register(InvocationPlugin, Type, String, Type...)} or
+ * {@link #registerOptional(InvocationPlugin, Type, String, Type...)}. Initialization is not
+ * thread-safe and so must only be performed by a single thread.
+ *
+ * Plugins that are not guaranteed to be made during initialization must use
+ * {@link LateRegistration}.
  */
 public class InvocationPlugins {
 
@@ -259,6 +270,26 @@ public class InvocationPlugins {
             plugins.register(plugin, false, allowOverwrite, declaringType, name, arg1, arg2, arg3, arg4, arg5);
         }
 
+        /**
+         * Registers a plugin for a method with 6 arguments.
+         *
+         * @param name the name of the method
+         * @param plugin the plugin to be registered
+         */
+        public void register6(String name, Type arg1, Type arg2, Type arg3, Type arg4, Type arg5, Type arg6, InvocationPlugin plugin) {
+            plugins.register(plugin, false, allowOverwrite, declaringType, name, arg1, arg2, arg3, arg4, arg5, arg6);
+        }
+
+        /**
+         * Registers a plugin for a method with 7 arguments.
+         *
+         * @param name the name of the method
+         * @param plugin the plugin to be registered
+         */
+        public void register7(String name, Type arg1, Type arg2, Type arg3, Type arg4, Type arg5, Type arg6, Type arg7, InvocationPlugin plugin) {
+            plugins.register(plugin, false, allowOverwrite, declaringType, name, arg1, arg2, arg3, arg4, arg5, arg6, arg7);
+        }
+
         /**
          * Registers a plugin for an optional method with no arguments.
          *
@@ -337,168 +368,151 @@ public class InvocationPlugins {
          */
         @Override
         public void registerMethodSubstitution(Class substituteDeclaringClass, String name, String substituteName, Type... argumentTypes) {
-            assert methodSubstitutionBytecodeProvider != null : "Registration used for method substitutions requires a non-null methodSubstitutionBytecodeProvider";
-            MethodSubstitutionPlugin plugin = new MethodSubstitutionPlugin(methodSubstitutionBytecodeProvider, substituteDeclaringClass, substituteName, argumentTypes);
+            MethodSubstitutionPlugin plugin = createMethodSubstitution(substituteDeclaringClass, substituteName, argumentTypes);
             plugins.register(plugin, false, allowOverwrite, declaringType, name, argumentTypes);
         }
+
+        public MethodSubstitutionPlugin createMethodSubstitution(Class substituteDeclaringClass, String substituteName, Type... argumentTypes) {
+            assert methodSubstitutionBytecodeProvider != null : "Registration used for method substitutions requires a non-null methodSubstitutionBytecodeProvider";
+            MethodSubstitutionPlugin plugin = new MethodSubstitutionPlugin(methodSubstitutionBytecodeProvider, substituteDeclaringClass, substituteName, argumentTypes);
+            return plugin;
+        }
+
     }
 
     /**
-     * Key for a {@linkplain ClassPlugins#entries resolved} plugin registration. Due to the
-     * possibility of class redefinition, we cannot directly use {@link ResolvedJavaMethod}s as
-     * keys. A {@link ResolvedJavaMethod} implementation might implement {@code equals()} and
-     * {@code hashCode()} based on internal representation subject to change by class redefinition.
+     * Utility for registering plugins after Graal may have been initialized. Registrations made via
+     * this class are not finalized until {@link #close} is called.
      */
-    static final class ResolvedJavaMethodKey {
-        private final ResolvedJavaMethod method;
+    public static class LateRegistration implements AutoCloseable {
 
-        ResolvedJavaMethodKey(ResolvedJavaMethod method) {
-            this.method = method;
+        private InvocationPlugins plugins;
+        private final List bindings = new ArrayList<>();
+        private final Type declaringType;
+
+        /**
+         * Creates an object for registering {@link InvocationPlugin}s for methods declared by a
+         * given class.
+         *
+         * @param plugins where to register the plugins
+         * @param declaringType the class declaring the methods for which plugins will be registered
+         *            via this object
+         */
+        public LateRegistration(InvocationPlugins plugins, Type declaringType) {
+            this.plugins = plugins;
+            this.declaringType = declaringType;
         }
 
-        @Override
-        public boolean equals(Object obj) {
-            if (obj instanceof ResolvedJavaMethodKey) {
-                ResolvedJavaMethodKey that = (ResolvedJavaMethodKey) obj;
-                if (this.method.isStatic() == that.method.isStatic()) {
-                    if (this.method.getDeclaringClass().equals(that.method.getDeclaringClass())) {
-                        if (this.method.getName().equals(that.method.getName())) {
-                            if (this.method.getSignature().equals(that.method.getSignature())) {
-                                return true;
-                            }
-                        }
-                    }
-                }
+        /**
+         * Registers an invocation plugin for a given method. There must be no plugin currently
+         * registered for {@code method}.
+         *
+         * @param argumentTypes the argument types of the method. Element 0 of this array must be
+         *            the {@link Class} value for {@link InvocationPlugin.Receiver} iff the method
+         *            is non-static. Upon returning, element 0 will have been rewritten to
+         *            {@code declaringClass}
+         */
+        public void register(InvocationPlugin plugin, String name, Type... argumentTypes) {
+            boolean isStatic = argumentTypes.length == 0 || argumentTypes[0] != InvocationPlugin.Receiver.class;
+            if (!isStatic) {
+                argumentTypes[0] = declaringType;
             }
-            return false;
+
+            assert isStatic || argumentTypes[0] == declaringType;
+            Binding binding = new Binding(plugin, isStatic, name, argumentTypes);
+            bindings.add(binding);
+
+            assert Checks.check(this.plugins, declaringType, binding);
+            assert Checks.checkResolvable(false, declaringType, binding);
         }
 
         @Override
-        public int hashCode() {
-            return this.method.getName().hashCode();
-        }
-
-        @Override
-        public String toString() {
-            return "ResolvedJavaMethodKey<" + method + ">";
+        public void close() {
+            assert plugins != null : String.format("Late registrations of invocation plugins for %s is already closed", declaringType);
+            plugins.registerLate(declaringType, bindings);
+            plugins = null;
         }
     }
 
     /**
-     * Key for {@linkplain ClassPlugins#registrations registering} an {@link InvocationPlugin} for a
-     * specific method.
+     * Associates an {@link InvocationPlugin} with the details of a method it substitutes.
      */
-    static class MethodKey {
-        final boolean isStatic;
+    public static class Binding {
+        /**
+         * The plugin this binding is for.
+         */
+        public final InvocationPlugin plugin;
 
         /**
-         * This method is optional. This is used for new API methods not present in previous JDK
-         * versions.
+         * Specifies if the associated method is static.
          */
-        final boolean isOptional;
-
-        final String name;
-        final Type[] argumentTypes;
-        final InvocationPlugin value;
+        public final boolean isStatic;
 
         /**
-         * Used to lazily initialize {@link #resolved}.
+         * The name of the associated method.
          */
-        private final MetaAccessProvider metaAccess;
+        public final String name;
 
-        private volatile ResolvedJavaMethod resolved;
+        /**
+         * A partial
+         * method
+         * descriptor for the associated method. The descriptor includes enclosing {@code '('}
+         * and {@code ')'} characters but omits the return type suffix.
+         */
+        public final String argumentsDescriptor;
 
-        MethodKey(MetaAccessProvider metaAccess, InvocationPlugin data, boolean isStatic, boolean isOptional, String name, Type... argumentTypes) {
-            this.metaAccess = metaAccess;
-            this.value = data;
+        /**
+         * Link in a list of bindings.
+         */
+        private Binding next;
+
+        Binding(InvocationPlugin data, boolean isStatic, String name, Type... argumentTypes) {
+            this.plugin = data;
             this.isStatic = isStatic;
-            this.isOptional = isOptional;
             this.name = name;
-            this.argumentTypes = argumentTypes;
-        }
-
-        @Override
-        public boolean equals(Object obj) {
-            if (obj instanceof MethodKey) {
-                MethodKey that = (MethodKey) obj;
-                boolean res = this.name.equals(that.name) && areEqual(this.argumentTypes, that.argumentTypes);
-                assert !res || this.isStatic == that.isStatic;
-                return res;
+            StringBuilder buf = new StringBuilder();
+            buf.append('(');
+            for (int i = isStatic ? 0 : 1; i < argumentTypes.length; i++) {
+                buf.append(MetaUtil.toInternalName(argumentTypes[i].getTypeName()));
             }
-            return false;
+            buf.append(')');
+            this.argumentsDescriptor = buf.toString();
+            assert !name.equals("") || !isStatic : this;
         }
 
-        private static boolean areEqual(Type[] args1, Type[] args2) {
-            if (args1.length == args2.length) {
-                for (int i = 0; i < args1.length; i++) {
-                    if (!args1[i].getTypeName().equals(args2[i].getTypeName())) {
-                        return false;
-                    }
-                }
-                return true;
-            }
-            return false;
-        }
-
-        public int getDeclaredParameterCount() {
-            return isStatic ? argumentTypes.length : argumentTypes.length - 1;
-        }
-
-        @Override
-        public int hashCode() {
-            return name.hashCode();
-        }
-
-        private ResolvedJavaMethod resolve(Class declaringClass) {
-            if (resolved == null) {
-                Executable method = resolveJava(declaringClass);
-                if (method == null) {
-                    return null;
-                }
-                resolved = metaAccess.lookupJavaMethod(method);
-            }
-            return resolved;
-        }
-
-        private Executable resolveJava(Class declaringClass) {
-            try {
-                Executable res;
-                Class[] parameterTypes = resolveTypes(argumentTypes, isStatic ? 0 : 1, argumentTypes.length);
-                if (name.equals("")) {
-                    res = declaringClass.getDeclaredConstructor(parameterTypes);
-                } else {
-                    res = declaringClass.getDeclaredMethod(name, parameterTypes);
-                }
-                assert Modifier.isStatic(res.getModifiers()) == isStatic : res;
-                return res;
-            } catch (NoSuchMethodException | SecurityException e) {
-                if (isOptional) {
-                    return null;
-                }
-                throw new InternalError(e);
-            }
+        Binding(ResolvedJavaMethod resolved, InvocationPlugin data) {
+            this.plugin = data;
+            this.isStatic = resolved.isStatic();
+            this.name = resolved.getName();
+            Signature sig = resolved.getSignature();
+            String desc = sig.toMethodDescriptor();
+            assert desc.indexOf(')') != -1 : desc;
+            this.argumentsDescriptor = desc.substring(0, desc.indexOf(')') + 1);
+            assert !name.equals("") || !isStatic : this;
         }
 
         @Override
         public String toString() {
-            StringBuilder sb = new StringBuilder(name).append('(');
-            for (Type p : argumentTypes) {
-                if (sb.charAt(sb.length() - 1) != '(') {
-                    sb.append(", ");
-                }
-                sb.append(p.getTypeName());
-            }
-            return sb.append(')').toString();
+            return name + argumentsDescriptor;
         }
     }
 
-    private final MetaAccessProvider metaAccess;
-
-    private final Map registrations = new HashMap<>();
+    /**
+     * Plugin registrations for already resolved methods. If non-null, then {@link #registrations}
+     * is null and no further registrations can be made.
+     */
+    private final Map resolvedRegistrations;
 
     /**
-     * Deferred registrations as well as guard for initialization. The guard uses double-checked
-     * locking which is why this field is {@code volatile}.
+     * Map from class names in {@linkplain MetaUtil#toInternalName(String) internal} form to the
+     * invocation plugin bindings for the class. Tf non-null, then {@link #resolvedRegistrations}
+     * will be null.
+     */
+    private final Map registrations;
+
+    /**
+     * Deferred registrations as well as the guard for delimiting the initial registration phase.
+     * The guard uses double-checked locking which is why this field is {@code volatile}.
      */
     private volatile List deferredRegistrations = new ArrayList<>();
 
@@ -512,119 +526,159 @@ public class InvocationPlugins {
     }
 
     /**
-     * Per-class invocation plugins.
+     * Support for registering plugins once this object may be accessed by multiple threads.
      */
-    protected static class ClassPlugins {
-        private final Type declaringType;
+    private volatile LateClassPlugins lateRegistrations;
 
-        private final List registrations = new ArrayList<>();
-
-        public ClassPlugins(Type declaringClass) {
-            this.declaringType = declaringClass;
-        }
+    /**
+     * Per-class bindings.
+     */
+    static class ClassPlugins {
 
         /**
-         * Entry map that is initialized upon first call to {@link #get(ResolvedJavaMethod)}.
-         *
-         * Note: this must be volatile as threads may race to initialize it.
+         * Maps method names to binding lists.
          */
-        private volatile Map entries;
+        private final Map bindings = new HashMap<>();
 
-        void initializeMap() {
-            if (!isClosed()) {
-                if (registrations.isEmpty()) {
-                    entries = Collections.emptyMap();
-                } else {
-                    Class declaringClass = resolveType(declaringType, true);
-                    if (declaringClass == null) {
-                        // An optional type that could not be resolved
-                        entries = Collections.emptyMap();
-                    } else {
-                        Map newEntries = new HashMap<>();
-                        for (MethodKey methodKey : registrations) {
-                            ResolvedJavaMethod m = methodKey.resolve(declaringClass);
-                            if (m != null) {
-                                newEntries.put(new ResolvedJavaMethodKey(m), methodKey.value);
-                                if (entries != null) {
-                                    // Another thread finished initializing entries first
-                                    return;
-                                }
-                            }
-                        }
-                        entries = newEntries;
+        /**
+         * Gets the invocation plugin for a given method.
+         *
+         * @return the invocation plugin for {@code method} or {@code null}
+         */
+        InvocationPlugin get(ResolvedJavaMethod method) {
+            assert !method.isBridge();
+            Binding binding = bindings.get(method.getName());
+            while (binding != null) {
+                if (method.isStatic() == binding.isStatic) {
+                    if (method.getSignature().toMethodDescriptor().startsWith(binding.argumentsDescriptor)) {
+                        return binding.plugin;
                     }
                 }
+                binding = binding.next;
             }
+            return null;
         }
 
-        public InvocationPlugin get(ResolvedJavaMethod method) {
-            if (!isClosed()) {
-                initializeMap();
-            }
-            return entries.get(new ResolvedJavaMethodKey(method));
-        }
-
-        public void register(MethodKey methodKey, boolean allowOverwrite) {
-            assert !isClosed() : "registration is closed: " + methodKey + " " + Arrays.toString(entries.keySet().toArray());
+        public void register(Binding binding, boolean allowOverwrite) {
             if (allowOverwrite) {
-                int index = registrations.indexOf(methodKey);
-                if (index >= 0) {
-                    registrations.set(index, methodKey);
+                if (lookup(binding) != null) {
+                    register(binding);
                     return;
                 }
             } else {
-                assert !registrations.contains(methodKey) : "a value is already registered for " + declaringType + "." + methodKey;
+                assert lookup(binding) == null : "a value is already registered for " + binding;
             }
-            registrations.add(methodKey);
+            register(binding);
         }
 
-        public boolean isClosed() {
-            return entries != null;
+        InvocationPlugin lookup(Binding binding) {
+            Binding b = bindings.get(binding.name);
+            while (b != null) {
+                if (b.isStatic == binding.isStatic && b.argumentsDescriptor.equals(binding.argumentsDescriptor)) {
+                    return b.plugin;
+                }
+                b = b.next;
+            }
+            return null;
+        }
+
+        /**
+         * Registers {@code binding}.
+         */
+        void register(Binding binding) {
+            Binding head = bindings.get(binding.name);
+            assert binding.next == null;
+            binding.next = head;
+            bindings.put(binding.name, binding);
+        }
+    }
+
+    static class LateClassPlugins extends ClassPlugins {
+        static final String CLOSED_LATE_CLASS_PLUGIN = "-----";
+        private final String className;
+        private final LateClassPlugins next;
+
+        LateClassPlugins(LateClassPlugins next, String className) {
+            assert next == null || next.className != CLOSED_LATE_CLASS_PLUGIN : "Late registration of invocation plugins is closed";
+            this.next = next;
+            this.className = className;
         }
     }
 
     /**
-     * Adds an entry to this map for a specified method.
+     * Registers a binding of a method to an invocation plugin.
      *
-     * @param value value to be associated with the specified method
+     * @param plugin invocation plugin to be associated with the specified method
      * @param isStatic specifies if the method is static
-     * @param isOptional specifies if the method is optional
      * @param declaringClass the class declaring the method
      * @param name the name of the method
      * @param argumentTypes the argument types of the method. Element 0 of this array must be
      *            {@code declaringClass} iff the method is non-static.
      * @return an object representing the method
      */
-    MethodKey put(InvocationPlugin value, boolean isStatic, boolean isOptional, boolean allowOverwrite, Type declaringClass, String name, Type... argumentTypes) {
-        assert isStatic || argumentTypes[0] == declaringClass;
-
+    Binding put(InvocationPlugin plugin, boolean isStatic, boolean allowOverwrite, Type declaringClass, String name, Type... argumentTypes) {
+        assert resolvedRegistrations == null : "registration is closed";
         String internalName = MetaUtil.toInternalName(declaringClass.getTypeName());
+        assert isStatic || argumentTypes[0] == declaringClass;
+        assert deferredRegistrations != null : "initial registration is closed - use " + LateRegistration.class.getName() + " for late registrations";
+
         ClassPlugins classPlugins = registrations.get(internalName);
         if (classPlugins == null) {
-            classPlugins = new ClassPlugins(declaringClass);
+            classPlugins = new ClassPlugins();
             registrations.put(internalName, classPlugins);
         }
-        assert isStatic || argumentTypes[0] == declaringClass;
-        MethodKey methodKey = new MethodKey(metaAccess, value, isStatic, isOptional, name, argumentTypes);
-        classPlugins.register(methodKey, allowOverwrite);
-        return methodKey;
-    }
-
-    /**
-     * Determines if a method denoted by a given {@link MethodKey} is in this map.
-     */
-    boolean containsKey(Type declaringType, MethodKey key) {
-        String internalName = MetaUtil.toInternalName(declaringType.getTypeName());
-        ClassPlugins classPlugins = registrations.get(internalName);
-        return classPlugins != null && classPlugins.registrations.contains(key);
+        Binding binding = new Binding(plugin, isStatic, name, argumentTypes);
+        classPlugins.register(binding, allowOverwrite);
+        return binding;
     }
 
     InvocationPlugin get(ResolvedJavaMethod method) {
-        flushDeferrables();
-        String internalName = method.getDeclaringClass().getName();
-        ClassPlugins classPlugins = registrations.get(internalName);
-        if (classPlugins != null) {
-            return classPlugins.get(method);
+        if (resolvedRegistrations != null) {
+            return resolvedRegistrations.get(method);
+        } else {
+            if (!method.isBridge()) {
+                ResolvedJavaType declaringClass = method.getDeclaringClass();
+                flushDeferrables();
+                String internalName = declaringClass.getName();
+                ClassPlugins classPlugins = registrations.get(internalName);
+                InvocationPlugin res = null;
+                if (classPlugins != null) {
+                    res = classPlugins.get(method);
+                }
+                if (res == null) {
+                    LateClassPlugins lcp = findLateClassPlugins(internalName);
+                    if (lcp != null) {
+                        res = lcp.get(method);
+                    }
+                }
+                if (res != null) {
+                    if (canBeIntrinsified(declaringClass)) {
+                        return res;
+                    }
+                }
+            } else {
+                // Supporting plugins for bridge methods would require including
+                // the return type in the registered signature. Until needed,
+                // this extra complexity is best avoided.
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Determines if methods in a given class can have invocation plugins.
+     *
+     * @param declaringClass the class to test
+     */
+    protected boolean canBeIntrinsified(ResolvedJavaType declaringClass) {
+        return true;
+    }
+
+    LateClassPlugins findLateClassPlugins(String internalClassName) {
+        for (LateClassPlugins lcp = lateRegistrations; lcp != null; lcp = lcp.next) {
+            if (lcp.className.equals(internalClassName)) {
+                return lcp;
+            }
         }
         return null;
     }
@@ -639,25 +693,39 @@ public class InvocationPlugins {
                     deferredRegistrations = null;
                 }
             }
-            for (Map.Entry e : registrations.entrySet()) {
-                e.getValue().initializeMap();
-            }
         }
     }
 
+    synchronized void registerLate(Type declaringType, List bindings) {
+        String internalName = MetaUtil.toInternalName(declaringType.getTypeName());
+        assert findLateClassPlugins(internalName) == null : "Cannot have more than one late registration of invocation plugins for " + internalName;
+        LateClassPlugins lateClassPlugins = new LateClassPlugins(lateRegistrations, internalName);
+        for (Binding b : bindings) {
+            lateClassPlugins.register(b);
+        }
+        lateRegistrations = lateClassPlugins;
+    }
+
+    private synchronized boolean closeLateRegistrations() {
+        if (lateRegistrations == null || lateRegistrations.className != CLOSED_LATE_CLASS_PLUGIN) {
+            lateRegistrations = new LateClassPlugins(lateRegistrations, CLOSED_LATE_CLASS_PLUGIN);
+        }
+        return true;
+    }
+
     /**
-     * Disallows new registrations of new plugins, and creates the internal tables for method
-     * lookup.
+     * Processes deferred registrations and then closes this object for future registration.
      */
     public void closeRegistration() {
+        assert closeLateRegistrations();
         flushDeferrables();
-        for (Map.Entry e : registrations.entrySet()) {
-            e.getValue().initializeMap();
-        }
     }
 
-    public int size() {
-        return registrations.size();
+    public boolean isEmpty() {
+        if (resolvedRegistrations != null) {
+            return resolvedRegistrations.isEmpty();
+        }
+        return registrations.size() == 0 && lateRegistrations == null;
     }
 
     /**
@@ -666,47 +734,39 @@ public class InvocationPlugins {
      */
     protected final InvocationPlugins parent;
 
-    private InvocationPlugins(InvocationPlugins parent, MetaAccessProvider metaAccess) {
-        this.metaAccess = metaAccess;
-        InvocationPlugins p = parent;
-        this.parent = p;
+    /**
+     * Creates a set of invocation plugins with no parent.
+     */
+    public InvocationPlugins() {
+        this(null);
     }
 
     /**
-     * Creates a set of invocation plugins with a non-null {@linkplain #getParent() parent}.
+     * Creates a set of invocation plugins.
+     *
+     * @param parent if non-null, this object will be searched first when looking up plugins
      */
     public InvocationPlugins(InvocationPlugins parent) {
-        this(parent, parent.getMetaAccess());
+        InvocationPlugins p = parent;
+        this.parent = p;
+        this.registrations = new HashMap<>();
+        this.resolvedRegistrations = null;
     }
 
-    public InvocationPlugins(Map plugins, InvocationPlugins parent, MetaAccessProvider metaAccess) {
-        this.metaAccess = metaAccess;
+    /**
+     * Creates a closed set of invocation plugins for a set of resolved methods. Such an object
+     * cannot have further plugins registered.
+     */
+    public InvocationPlugins(Map plugins, InvocationPlugins parent) {
         this.parent = parent;
-
+        this.registrations = null;
         this.deferredRegistrations = null;
+        Map map = new HashMap<>(plugins.size());
 
         for (Map.Entry entry : plugins.entrySet()) {
-            ResolvedJavaMethod method = entry.getKey();
-            InvocationPlugin plugin = entry.getValue();
-
-            String internalName = method.getDeclaringClass().getName();
-            ClassPlugins classPlugins = registrations.get(internalName);
-            if (classPlugins == null) {
-                classPlugins = new ClassPlugins(null);
-                registrations.put(internalName, classPlugins);
-                classPlugins.entries = new HashMap<>();
-            }
-
-            classPlugins.entries.put(new ResolvedJavaMethodKey(method), plugin);
+            map.put(entry.getKey(), entry.getValue());
         }
-    }
-
-    public MetaAccessProvider getMetaAccess() {
-        return metaAccess;
-    }
-
-    public InvocationPlugins(MetaAccessProvider metaAccess) {
-        this(null, metaAccess);
+        this.resolvedRegistrations = map;
     }
 
     protected void register(InvocationPlugin plugin, boolean isOptional, boolean allowOverwrite, Type declaringClass, String name, Type... argumentTypes) {
@@ -714,8 +774,9 @@ public class InvocationPlugins {
         if (!isStatic) {
             argumentTypes[0] = declaringClass;
         }
-        MethodKey methodKey = put(plugin, isStatic, isOptional, allowOverwrite, declaringClass, name, argumentTypes);
-        assert Checker.check(this, declaringClass, methodKey, plugin);
+        Binding binding = put(plugin, isStatic, allowOverwrite, declaringClass, name, argumentTypes);
+        assert Checks.check(this, declaringClass, binding);
+        assert Checks.checkResolvable(isOptional, declaringClass, binding);
     }
 
     /**
@@ -765,23 +826,56 @@ public class InvocationPlugins {
     }
 
     /**
-     * Gets the set of methods for which invocation plugins have been registered. Once this method
-     * is called, no further registrations can be made.
+     * Gets the set of registered invocation plugins.
+     *
+     * @return a map from class names in {@linkplain MetaUtil#toInternalName(String) internal} form
+     *         to the invocation plugin bindings for methods in the class
      */
-    public Set getMethods() {
-        Set res = new HashSet<>();
-        if (parent != null) {
-            res.addAll(parent.getMethods());
+    public Map> getBindings(boolean includeParents) {
+        Map> res = new HashMap<>();
+        if (parent != null && includeParents) {
+            res.putAll(parent.getBindings(true));
         }
-        flushDeferrables();
-        for (ClassPlugins cp : registrations.values()) {
-            for (ResolvedJavaMethodKey key : cp.entries.keySet()) {
-                res.add(key.method);
+        if (resolvedRegistrations != null) {
+            for (Map.Entry e : resolvedRegistrations.entrySet()) {
+                ResolvedJavaMethod method = e.getKey();
+                InvocationPlugin plugin = e.getValue();
+                String type = method.getDeclaringClass().getName();
+                List bindings = res.get(type);
+                if (bindings == null) {
+                    bindings = new ArrayList<>();
+                    res.put(type, bindings);
+                }
+                bindings.add(new Binding(method, plugin));
+            }
+        } else {
+            flushDeferrables();
+            for (Map.Entry e : registrations.entrySet()) {
+                String type = e.getKey();
+                ClassPlugins cp = e.getValue();
+                collectBindingsTo(res, type, cp);
+            }
+            for (LateClassPlugins lcp = lateRegistrations; lcp != null; lcp = lcp.next) {
+                String type = lcp.className;
+                collectBindingsTo(res, type, lcp);
             }
         }
         return res;
     }
 
+    private static void collectBindingsTo(Map> res, String type, ClassPlugins cp) {
+        for (Map.Entry e : cp.bindings.entrySet()) {
+            List bindings = res.get(type);
+            if (bindings == null) {
+                bindings = new ArrayList<>();
+                res.put(type, bindings);
+            }
+            for (Binding b = e.getValue(); b != null; b = b.next) {
+                bindings.add(b);
+            }
+        }
+    }
+
     /**
      * Gets the invocation plugins {@linkplain #lookupInvocation(ResolvedJavaMethod) searched}
      * before searching in this object.
@@ -792,17 +886,36 @@ public class InvocationPlugins {
 
     @Override
     public String toString() {
-        StringBuilder buf = new StringBuilder();
-        registrations.forEach((name, cp) -> buf.append(name).append('.').append(cp).append(", "));
-        String s = buf.toString();
-        if (buf.length() != 0) {
-            s = s.substring(buf.length() - ", ".length());
+        List all = new ArrayList<>();
+        for (Map.Entry> e : getBindings(false).entrySet()) {
+            String c = MetaUtil.internalNameToJava(e.getKey(), true, false);
+            for (Binding b : e.getValue()) {
+                all.add(c + '.' + b);
+            }
         }
-        return s + " / parent: " + this.parent;
+        Collections.sort(all);
+        StringBuilder buf = new StringBuilder();
+        String nl = String.format("%n");
+        for (String s : all) {
+            if (buf.length() != 0) {
+                buf.append(nl);
+            }
+            buf.append(s);
+        }
+        if (parent != null) {
+            if (buf.length() != 0) {
+                buf.append(nl);
+            }
+            buf.append("// parent").append(nl).append(parent);
+        }
+        return buf.toString();
     }
 
-    private static class Checker {
-        private static final int MAX_ARITY = 5;
+    /**
+     * Code only used in assertions. Putting this in a separate class reduces class load time.
+     */
+    private static class Checks {
+        private static final int MAX_ARITY = 7;
         /**
          * The set of all {@link InvocationPlugin#apply} method signatures.
          */
@@ -828,10 +941,17 @@ public class InvocationPlugins {
             SIGS = sigs.toArray(new Class[sigs.size()][]);
         }
 
-        public static boolean check(InvocationPlugins plugins, Type declaringType, MethodKey method, InvocationPlugin plugin) {
+        static boolean containsBinding(InvocationPlugins p, Type declaringType, Binding key) {
+            String internalName = MetaUtil.toInternalName(declaringType.getTypeName());
+            ClassPlugins classPlugins = p.registrations.get(internalName);
+            return classPlugins != null && classPlugins.lookup(key) != null;
+        }
+
+        public static boolean check(InvocationPlugins plugins, Type declaringType, Binding binding) {
+            InvocationPlugin plugin = binding.plugin;
             InvocationPlugins p = plugins.parent;
             while (p != null) {
-                assert !p.containsKey(declaringType, method) : "a plugin is already registered for " + method;
+                assert !containsBinding(p, declaringType, binding) : "a plugin is already registered for " + binding;
                 p = p.parent;
             }
             if (plugin instanceof ForeignCallPlugin || plugin instanceof GeneratedInvocationPlugin) {
@@ -843,8 +963,8 @@ public class InvocationPlugins {
                 assert substitute.getAnnotation(MethodSubstitution.class) != null : format("Substitute method must be annotated with @%s: %s", MethodSubstitution.class.getSimpleName(), substitute);
                 return true;
             }
-            int arguments = method.getDeclaredParameterCount();
-            assert arguments < SIGS.length : format("need to extend %s to support method with %d arguments: %s", InvocationPlugin.class.getSimpleName(), arguments, method);
+            int arguments = parseParameters(binding.argumentsDescriptor).size();
+            assert arguments < SIGS.length : format("need to extend %s to support method with %d arguments: %s", InvocationPlugin.class.getSimpleName(), arguments, binding);
             for (Method m : plugin.getClass().getDeclaredMethods()) {
                 if (m.getName().equals("apply")) {
                     Class[] parameterTypes = m.getParameterTypes();
@@ -853,7 +973,24 @@ public class InvocationPlugins {
                     }
                 }
             }
-            throw new AssertionError(format("graph builder plugin for %s not found", method));
+            throw new AssertionError(format("graph builder plugin for %s not found", binding));
+        }
+
+        static boolean checkResolvable(boolean isOptional, Type declaringType, Binding binding) {
+            Class declaringClass = InvocationPlugins.resolveType(declaringType, isOptional);
+            if (declaringClass == null) {
+                return true;
+            }
+            if (binding.name.equals("")) {
+                if (resolveConstructor(declaringClass, binding) == null && !isOptional) {
+                    throw new AssertionError(String.format("Constructor not found: %s%s", declaringClass.getName(), binding.argumentsDescriptor));
+                }
+            } else {
+                if (resolveMethod(declaringClass, binding) == null && !isOptional) {
+                    throw new AssertionError(String.format("Method not found: %s.%s%s", declaringClass.getName(), binding.name, binding.argumentsDescriptor));
+                }
+            }
+            return true;
         }
     }
 
@@ -904,31 +1041,119 @@ public class InvocationPlugins {
         if (type instanceof Class) {
             return (Class) type;
         }
-        if (optional && type instanceof OptionalLazySymbol) {
+        if (type instanceof OptionalLazySymbol) {
             return ((OptionalLazySymbol) type).resolve();
         }
         return resolveClass(type.getTypeName(), optional);
     }
 
-    private static final Class[] NO_CLASSES = {};
+    private static List toInternalTypeNames(Class[] types) {
+        String[] res = new String[types.length];
+        for (int i = 0; i < types.length; i++) {
+            res[i] = MetaUtil.toInternalName(types[i].getTypeName());
+        }
+        return Arrays.asList(res);
+    }
 
     /**
-     * Resolves an array of {@link Type}s to an array of {@link Class}es.
+     * Resolves a given binding to a method in a given class. If more than one method with the
+     * parameter types matching {@code binding} is found and the return types of all the matching
+     * methods form an inheritance chain, the one with the most specific type is returned; otherwise
+     * {@link NoSuchMethodError} is thrown.
      *
-     * @param types the types to resolve
-     * @param from the initial index of the range to be resolved, inclusive
-     * @param to the final index of the range to be resolved, exclusive
-     * @return the resolved class or null if resolution fails and {@code optional} is true
+     * @param declaringClass the class to search for a method matching {@code binding}
+     * @return the method (if any) in {@code declaringClass} matching binding
      */
-    public static Class[] resolveTypes(Type[] types, int from, int to) {
-        int length = to - from;
-        if (length <= 0) {
-            return NO_CLASSES;
+    public static Method resolveMethod(Class declaringClass, Binding binding) {
+        if (binding.name.equals("")) {
+            return null;
         }
-        Class[] classes = new Class[length];
-        for (int i = 0; i < length; i++) {
-            classes[i] = resolveType(types[i + from], false);
+        Method[] methods = declaringClass.getDeclaredMethods();
+        List parameterTypeNames = parseParameters(binding.argumentsDescriptor);
+        for (int i = 0; i < methods.length; ++i) {
+            Method m = methods[i];
+            if (binding.isStatic == Modifier.isStatic(m.getModifiers()) && m.getName().equals(binding.name)) {
+                if (parameterTypeNames.equals(toInternalTypeNames(m.getParameterTypes()))) {
+                    for (int j = i + 1; j < methods.length; ++j) {
+                        Method other = methods[j];
+                        if (binding.isStatic == Modifier.isStatic(other.getModifiers()) && other.getName().equals(binding.name)) {
+                            if (parameterTypeNames.equals(toInternalTypeNames(other.getParameterTypes()))) {
+                                if (m.getReturnType().isAssignableFrom(other.getReturnType())) {
+                                    // `other` has a more specific return type - choose it
+                                    // (m is most likely a bridge method)
+                                    m = other;
+                                } else {
+                                    if (!other.getReturnType().isAssignableFrom(m.getReturnType())) {
+                                        throw new NoSuchMethodError(String.format(
+                                                        "Found 2 methods with same name and parameter types but unrelated return types:%n %s%n %s", m, other));
+                                    }
+                                }
+                            }
+                        }
+                    }
+                    return m;
+                }
+            }
         }
-        return classes;
+        return null;
+    }
+
+    /**
+     * Resolves a given binding to a constructor in a given class.
+     *
+     * @param declaringClass the class to search for a constructor matching {@code binding}
+     * @return the constructor (if any) in {@code declaringClass} matching binding
+     */
+    public static Constructor resolveConstructor(Class declaringClass, Binding binding) {
+        if (!binding.name.equals("")) {
+            return null;
+        }
+        Constructor[] constructors = declaringClass.getDeclaredConstructors();
+        List parameterTypeNames = parseParameters(binding.argumentsDescriptor);
+        for (int i = 0; i < constructors.length; ++i) {
+            Constructor c = constructors[i];
+            if (parameterTypeNames.equals(toInternalTypeNames(c.getParameterTypes()))) {
+                return c;
+            }
+        }
+        return null;
+    }
+
+    private static List parseParameters(String argumentsDescriptor) {
+        assert argumentsDescriptor.startsWith("(") && argumentsDescriptor.endsWith(")") : argumentsDescriptor;
+        List res = new ArrayList<>();
+        int cur = 1;
+        int end = argumentsDescriptor.length() - 1;
+        while (cur != end) {
+            char first;
+            int start = cur;
+            do {
+                first = argumentsDescriptor.charAt(cur++);
+            } while (first == '[');
+
+            switch (first) {
+                case 'L':
+                    int endObject = argumentsDescriptor.indexOf(';', cur);
+                    if (endObject == -1) {
+                        throw new GraalError("Invalid object type at index %d in signature: %s", cur, argumentsDescriptor);
+                    }
+                    cur = endObject + 1;
+                    break;
+                case 'V':
+                case 'I':
+                case 'B':
+                case 'C':
+                case 'D':
+                case 'F':
+                case 'J':
+                case 'S':
+                case 'Z':
+                    break;
+                default:
+                    throw new GraalError("Invalid character at index %d in signature: %s", cur, argumentsDescriptor);
+            }
+            res.add(argumentsDescriptor.substring(start, cur));
+        }
+        return res;
     }
 }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/LoopExplosionPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/LoopExplosionPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/LoopExplosionPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/LoopExplosionPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/MethodSubstitutionPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/MethodSubstitutionPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/MethodSubstitutionPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/MethodSubstitutionPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/NodeIntrinsicPluginFactory.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/NodeIntrinsicPluginFactory.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/NodeIntrinsicPluginFactory.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/NodeIntrinsicPluginFactory.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/NodePlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/NodePlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/NodePlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/NodePlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ParameterPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ParameterPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ParameterPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ParameterPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ProfilingPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ProfilingPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ProfilingPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/ProfilingPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/TypePlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/TypePlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/TypePlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/graphbuilderconf/TypePlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AbstractNewArrayNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AbstractNewArrayNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AbstractNewArrayNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AbstractNewArrayNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AbstractNewObjectNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AbstractNewObjectNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AbstractNewObjectNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AbstractNewObjectNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessArrayNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessArrayNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessArrayNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessArrayNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessFieldNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessFieldNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessFieldNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessFieldNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessIndexedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessIndexedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessIndexedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessIndexedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessMonitorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessMonitorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessMonitorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AccessMonitorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ArrayLengthNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ArrayLengthNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ArrayLengthNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ArrayLengthNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AtomicReadAndAddNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AtomicReadAndAddNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AtomicReadAndAddNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AtomicReadAndAddNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AtomicReadAndWriteNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AtomicReadAndWriteNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AtomicReadAndWriteNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/AtomicReadAndWriteNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ClassIsAssignableFromNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ClassIsAssignableFromNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ClassIsAssignableFromNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ClassIsAssignableFromNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/CompareAndSwapNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/CompareAndSwapNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/CompareAndSwapNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/CompareAndSwapNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/DynamicNewArrayNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/DynamicNewArrayNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/DynamicNewArrayNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/DynamicNewArrayNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/DynamicNewInstanceNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/DynamicNewInstanceNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/DynamicNewInstanceNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/DynamicNewInstanceNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ExceptionObjectNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ExceptionObjectNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ExceptionObjectNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ExceptionObjectNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/FinalFieldBarrierNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/FinalFieldBarrierNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/FinalFieldBarrierNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/FinalFieldBarrierNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ForeignCallDescriptors.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ForeignCallDescriptors.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ForeignCallDescriptors.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/ForeignCallDescriptors.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/InstanceOfDynamicNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/InstanceOfDynamicNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/InstanceOfDynamicNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/InstanceOfDynamicNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/InstanceOfNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/InstanceOfNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/InstanceOfNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/InstanceOfNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadExceptionObjectNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadExceptionObjectNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadExceptionObjectNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadExceptionObjectNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadFieldNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadFieldNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadFieldNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadFieldNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadIndexedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadIndexedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadIndexedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoadIndexedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoweredAtomicReadAndWriteNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoweredAtomicReadAndWriteNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoweredAtomicReadAndWriteNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoweredAtomicReadAndWriteNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoweredCompareAndSwapNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoweredCompareAndSwapNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoweredCompareAndSwapNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/LoweredCompareAndSwapNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MethodCallTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MethodCallTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MethodCallTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MethodCallTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorEnterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorEnterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorEnterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorEnterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorExitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorExitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorExitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorExitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorIdNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorIdNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorIdNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/MonitorIdNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewArrayNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewArrayNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewArrayNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewArrayNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewInstanceNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewInstanceNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewInstanceNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewInstanceNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewMultiArrayNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewMultiArrayNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewMultiArrayNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/NewMultiArrayNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/RawMonitorEnterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/RawMonitorEnterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/RawMonitorEnterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/RawMonitorEnterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/RegisterFinalizerNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/RegisterFinalizerNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/RegisterFinalizerNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/RegisterFinalizerNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/StoreFieldNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/StoreFieldNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/StoreFieldNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/StoreFieldNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/StoreIndexedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/StoreIndexedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/StoreIndexedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/StoreIndexedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/TypeSwitchNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/TypeSwitchNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/TypeSwitchNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/java/TypeSwitchNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/AbstractMemoryCheckpoint.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/AbstractMemoryCheckpoint.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/AbstractMemoryCheckpoint.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/AbstractMemoryCheckpoint.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/AbstractWriteNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/AbstractWriteNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/AbstractWriteNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/AbstractWriteNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/Access.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/Access.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/Access.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/Access.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FixedAccessNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FixedAccessNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FixedAccessNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FixedAccessNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatableAccessNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatableAccessNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatableAccessNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatableAccessNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatingAccessNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatingAccessNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatingAccessNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatingAccessNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatingReadNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatingReadNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatingReadNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/FloatingReadNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/HeapAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/HeapAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/HeapAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/HeapAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryAnchorNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryAnchorNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryAnchorNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryAnchorNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryCheckpoint.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryCheckpoint.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryCheckpoint.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryCheckpoint.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryMapNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryMapNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryMapNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryMapNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryPhiNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryPhiNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryPhiNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/MemoryPhiNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/ReadNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/ReadNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/ReadNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/ReadNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/WriteNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/WriteNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/WriteNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/WriteNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/AddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/AddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/AddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/AddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/OffsetAddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/OffsetAddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/OffsetAddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/OffsetAddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/RawAddressNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/RawAddressNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/RawAddressNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/memory/address/RawAddressNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ArithmeticLIRLowerable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ArithmeticLIRLowerable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ArithmeticLIRLowerable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ArithmeticLIRLowerable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ArrayLengthProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ArrayLengthProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ArrayLengthProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ArrayLengthProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/DefaultNodeCostProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/DefaultNodeCostProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/DefaultNodeCostProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/DefaultNodeCostProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LIRLowerable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LIRLowerable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LIRLowerable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LIRLowerable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LimitedValueProxy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LimitedValueProxy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LimitedValueProxy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LimitedValueProxy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Lowerable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Lowerable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Lowerable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Lowerable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LoweringProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LoweringProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LoweringProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LoweringProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LoweringTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LoweringTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LoweringTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/LoweringTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/MemoryProxy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/MemoryProxy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/MemoryProxy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/MemoryProxy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeCostProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeCostProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeCostProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeCostProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeLIRBuilderTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeLIRBuilderTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeLIRBuilderTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeLIRBuilderTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeValueMap.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeValueMap.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeValueMap.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeValueMap.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeWithState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeWithState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeWithState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/NodeWithState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/PiPushable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/PiPushable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/PiPushable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/PiPushable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Proxy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Proxy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Proxy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Proxy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Replacements.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Replacements.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Replacements.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Replacements.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/StampProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/StampProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/StampProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/StampProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/UncheckedInterfaceProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/UncheckedInterfaceProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/UncheckedInterfaceProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/UncheckedInterfaceProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ValueProxy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ValueProxy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ValueProxy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/ValueProxy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Virtualizable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Virtualizable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Virtualizable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/Virtualizable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/VirtualizableAllocation.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/VirtualizableAllocation.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/VirtualizableAllocation.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/VirtualizableAllocation.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/VirtualizerTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/VirtualizerTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/VirtualizerTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/spi/VirtualizerTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/type/StampTool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/type/StampTool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/type/StampTool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/type/StampTool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/util/ConstantFoldUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/util/ConstantFoldUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/util/ConstantFoldUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/util/ConstantFoldUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/util/GraphUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/util/GraphUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/util/GraphUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/util/GraphUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/AllocatedObjectNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/AllocatedObjectNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/AllocatedObjectNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/AllocatedObjectNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/CommitAllocationNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/CommitAllocationNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/CommitAllocationNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/CommitAllocationNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/EnsureVirtualizedNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/EnsureVirtualizedNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/EnsureVirtualizedNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/EnsureVirtualizedNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/EscapeObjectState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/EscapeObjectState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/EscapeObjectState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/EscapeObjectState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/LockState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/LockState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/LockState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/LockState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualArrayNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualArrayNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualArrayNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualArrayNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualBoxingNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualBoxingNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualBoxingNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualBoxingNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualInstanceNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualInstanceNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualInstanceNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualInstanceNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualObjectNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualObjectNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualObjectNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.nodes/src/org/graalvm/compiler/nodes/virtual/VirtualObjectNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options.processor/src/META-INF/services/javax.annotation.processing.Processor b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options.processor/src/META-INF/services/javax.annotation.processing.Processor
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options.processor/src/META-INF/services/javax.annotation.processing.Processor
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options.processor/src/META-INF/services/javax.annotation.processing.Processor
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options.processor/src/org/graalvm/compiler/options/processor/OptionProcessor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options.processor/src/org/graalvm/compiler/options/processor/OptionProcessor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options.processor/src/org/graalvm/compiler/options/processor/OptionProcessor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options.processor/src/org/graalvm/compiler/options/processor/OptionProcessor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options.test/src/org/graalvm/compiler/options/test/NestedBooleanOptionValueTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options.test/src/org/graalvm/compiler/options/test/NestedBooleanOptionValueTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options.test/src/org/graalvm/compiler/options/test/NestedBooleanOptionValueTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options.test/src/org/graalvm/compiler/options/test/NestedBooleanOptionValueTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options.test/src/org/graalvm/compiler/options/test/TestOptionValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options.test/src/org/graalvm/compiler/options/test/TestOptionValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options.test/src/org/graalvm/compiler/options/test/TestOptionValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options.test/src/org/graalvm/compiler/options/test/TestOptionValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/DerivedOptionValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/DerivedOptionValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/DerivedOptionValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/DerivedOptionValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/EnumOptionValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/EnumOptionValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/EnumOptionValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/EnumOptionValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/NestedBooleanOptionValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/NestedBooleanOptionValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/NestedBooleanOptionValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/NestedBooleanOptionValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/Option.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/Option.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/Option.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/Option.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionDescriptor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionDescriptor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionDescriptor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionDescriptor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionDescriptors.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionDescriptors.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionDescriptors.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionDescriptors.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionType.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionType.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionType.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionType.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionsParser.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionsParser.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionsParser.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/OptionsParser.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/StableOptionValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/StableOptionValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/StableOptionValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/StableOptionValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/UniquePathUtilities.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/UniquePathUtilities.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/UniquePathUtilities.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.options/src/org/graalvm/compiler/options/UniquePathUtilities.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common.test/src/org/graalvm/compiler/phases/common/test/StampFactoryTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common.test/src/org/graalvm/compiler/phases/common/test/StampFactoryTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common.test/src/org/graalvm/compiler/phases/common/test/StampFactoryTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common.test/src/org/graalvm/compiler/phases/common/test/StampFactoryTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/AbstractInliningPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/AbstractInliningPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/AbstractInliningPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/AbstractInliningPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/AddressLoweringPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/AddressLoweringPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/AddressLoweringPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/AddressLoweringPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/CanonicalizerPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/CanonicalizerPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/CanonicalizerPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/CanonicalizerPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ConvertDeoptimizeToGuardPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ConvertDeoptimizeToGuardPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ConvertDeoptimizeToGuardPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ConvertDeoptimizeToGuardPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DeadCodeEliminationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DeadCodeEliminationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DeadCodeEliminationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DeadCodeEliminationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DeoptimizationGroupingPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DeoptimizationGroupingPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DeoptimizationGroupingPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DeoptimizationGroupingPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DominatorConditionalEliminationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DominatorConditionalEliminationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DominatorConditionalEliminationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/DominatorConditionalEliminationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ExpandLogicPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ExpandLogicPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ExpandLogicPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ExpandLogicPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/FloatingReadPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/FloatingReadPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/FloatingReadPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/FloatingReadPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/FrameStateAssignmentPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/FrameStateAssignmentPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/FrameStateAssignmentPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/FrameStateAssignmentPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/GuardLoweringPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/GuardLoweringPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/GuardLoweringPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/GuardLoweringPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/IncrementalCanonicalizerPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/IncrementalCanonicalizerPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/IncrementalCanonicalizerPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/IncrementalCanonicalizerPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/IterativeConditionalEliminationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/IterativeConditionalEliminationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/IterativeConditionalEliminationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/IterativeConditionalEliminationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LazyValue.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LazyValue.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LazyValue.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LazyValue.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LockEliminationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LockEliminationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LockEliminationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LockEliminationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LoopSafepointInsertionPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LoopSafepointInsertionPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LoopSafepointInsertionPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LoopSafepointInsertionPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LoweringPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LoweringPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LoweringPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/LoweringPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/NonNullParametersPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/NonNullParametersPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/NonNullParametersPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/NonNullParametersPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/OptimizeGuardAnchorsPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/OptimizeGuardAnchorsPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/OptimizeGuardAnchorsPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/OptimizeGuardAnchorsPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ProfileCompiledMethodsPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ProfileCompiledMethodsPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ProfileCompiledMethodsPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ProfileCompiledMethodsPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/PushThroughPiPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/PushThroughPiPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/PushThroughPiPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/PushThroughPiPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/RemoveValueProxyPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/RemoveValueProxyPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/RemoveValueProxyPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/RemoveValueProxyPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/UseTrappingNullChecksPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/UseTrappingNullChecksPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/UseTrappingNullChecksPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/UseTrappingNullChecksPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ValueAnchorCleanupPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ValueAnchorCleanupPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ValueAnchorCleanupPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/ValueAnchorCleanupPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/VerifyHeapAtReturnPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/VerifyHeapAtReturnPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/VerifyHeapAtReturnPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/VerifyHeapAtReturnPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/InliningPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/InliningPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/InliningPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/InliningPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/InliningUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/InliningUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/InliningUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/InliningUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/AbstractInlineInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/AbstractInlineInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/AbstractInlineInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/AbstractInlineInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/AssumptionInlineInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/AssumptionInlineInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/AssumptionInlineInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/AssumptionInlineInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/ExactInlineInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/ExactInlineInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/ExactInlineInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/ExactInlineInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/InlineInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/InlineInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/InlineInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/InlineInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/MultiTypeGuardInlineInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/MultiTypeGuardInlineInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/MultiTypeGuardInlineInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/MultiTypeGuardInlineInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/TypeGuardInlineInfo.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/TypeGuardInlineInfo.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/TypeGuardInlineInfo.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/TypeGuardInlineInfo.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/elem/Inlineable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/elem/Inlineable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/elem/Inlineable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/elem/Inlineable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/elem/InlineableGraph.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/elem/InlineableGraph.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/elem/InlineableGraph.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/info/elem/InlineableGraph.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/AbstractInliningPolicy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/AbstractInliningPolicy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/AbstractInliningPolicy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/AbstractInliningPolicy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/GreedyInliningPolicy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/GreedyInliningPolicy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/GreedyInliningPolicy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/GreedyInliningPolicy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InlineEverythingPolicy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InlineEverythingPolicy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InlineEverythingPolicy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InlineEverythingPolicy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InlineMethodSubstitutionsPolicy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InlineMethodSubstitutionsPolicy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InlineMethodSubstitutionsPolicy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InlineMethodSubstitutionsPolicy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InliningPolicy.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InliningPolicy.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InliningPolicy.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/policy/InliningPolicy.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/CallsiteHolder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/CallsiteHolder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/CallsiteHolder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/CallsiteHolder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/CallsiteHolderExplorable.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/CallsiteHolderExplorable.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/CallsiteHolderExplorable.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/CallsiteHolderExplorable.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/ComputeInliningRelevance.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/ComputeInliningRelevance.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/ComputeInliningRelevance.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/ComputeInliningRelevance.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/InliningData.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/InliningData.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/InliningData.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/InliningData.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/InliningIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/InliningIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/InliningIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/InliningIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/MethodInvocation.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/MethodInvocation.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/MethodInvocation.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/inlining/walker/MethodInvocation.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/ExtractInstrumentationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/ExtractInstrumentationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/ExtractInstrumentationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/ExtractInstrumentationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/HighTierReconcileInstrumentationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/HighTierReconcileInstrumentationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/HighTierReconcileInstrumentationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/HighTierReconcileInstrumentationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/InlineInstrumentationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/InlineInstrumentationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/InlineInstrumentationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/InlineInstrumentationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/MidTierReconcileInstrumentationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/MidTierReconcileInstrumentationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/MidTierReconcileInstrumentationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/instrumentation/MidTierReconcileInstrumentationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/util/HashSetNodeEventListener.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/util/HashSetNodeEventListener.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/util/HashSetNodeEventListener.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases.common/src/org/graalvm/compiler/phases/common/util/HashSetNodeEventListener.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/BasePhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/BasePhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/BasePhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/BasePhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/LazyName.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/LazyName.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/LazyName.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/LazyName.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/OptimisticOptimizations.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/OptimisticOptimizations.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/OptimisticOptimizations.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/OptimisticOptimizations.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/Phase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/Phase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/Phase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/Phase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/PhaseSuite.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/PhaseSuite.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/PhaseSuite.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/PhaseSuite.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/VerifyPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/VerifyPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/VerifyPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/VerifyPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/contract/NodeCostUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/contract/NodeCostUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/contract/NodeCostUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/contract/NodeCostUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/contract/PhaseSizeContract.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/contract/PhaseSizeContract.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/contract/PhaseSizeContract.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/contract/PhaseSizeContract.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/FixedNodeProbabilityCache.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/FixedNodeProbabilityCache.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/FixedNodeProbabilityCache.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/FixedNodeProbabilityCache.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/InferStamps.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/InferStamps.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/InferStamps.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/InferStamps.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/MergeableState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/MergeableState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/MergeableState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/MergeableState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/PostOrderNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/PostOrderNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/PostOrderNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/PostOrderNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ReentrantBlockIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ReentrantBlockIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ReentrantBlockIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ReentrantBlockIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ReentrantNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ReentrantNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ReentrantNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ReentrantNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ScheduledNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ScheduledNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ScheduledNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ScheduledNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ScopedPostOrderNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ScopedPostOrderNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ScopedPostOrderNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/ScopedPostOrderNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/SinglePassNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/SinglePassNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/SinglePassNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/SinglePassNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/StatelessPostOrderNodeIterator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/StatelessPostOrderNodeIterator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/StatelessPostOrderNodeIterator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/StatelessPostOrderNodeIterator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/package-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/package-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/graph/package-info.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/package-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/package-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/package-info.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/BlockClosure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/BlockClosure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/BlockClosure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/BlockClosure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/MemoryScheduleVerification.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/MemoryScheduleVerification.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/MemoryScheduleVerification.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/MemoryScheduleVerification.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/SchedulePhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/SchedulePhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/SchedulePhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/schedule/SchedulePhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/CompilerConfiguration.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/CompilerConfiguration.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/CompilerConfiguration.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/CompilerConfiguration.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/HighTierContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/HighTierContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/HighTierContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/HighTierContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/LowTierContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/LowTierContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/LowTierContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/LowTierContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/MidTierContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/MidTierContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/MidTierContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/MidTierContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/PhaseContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/PhaseContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/PhaseContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/PhaseContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/Suites.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/Suites.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/Suites.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/Suites.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/SuitesCreator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/SuitesCreator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/SuitesCreator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/SuitesCreator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/SuitesProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/SuitesProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/SuitesProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/SuitesProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/TargetProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/TargetProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/TargetProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/tiers/TargetProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/BlockWorkList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/BlockWorkList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/BlockWorkList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/BlockWorkList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/GraphOrder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/GraphOrder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/GraphOrder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/GraphOrder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/MethodDebugValueName.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/MethodDebugValueName.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/MethodDebugValueName.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/MethodDebugValueName.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/Providers.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/Providers.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/Providers.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/util/Providers.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyBailoutUsage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyBailoutUsage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyBailoutUsage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyBailoutUsage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyCallerSensitiveMethods.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyCallerSensitiveMethods.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyCallerSensitiveMethods.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyCallerSensitiveMethods.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyDebugUsage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyDebugUsage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyDebugUsage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyDebugUsage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyUpdateUsages.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyUpdateUsages.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyUpdateUsages.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyUpdateUsages.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyUsageWithEquals.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyUsageWithEquals.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyUsageWithEquals.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyUsageWithEquals.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyVirtualizableUsage.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyVirtualizableUsage.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyVirtualizableUsage.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/verify/VerifyVirtualizableUsage.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/BasicIdealGraphPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/BasicIdealGraphPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/BasicIdealGraphPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/BasicIdealGraphPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/BinaryGraphPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/BinaryGraphPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/BinaryGraphPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/BinaryGraphPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CFGPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CFGPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CFGPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CFGPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CFGPrinterObserver.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CFGPrinterObserver.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CFGPrinterObserver.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CFGPrinterObserver.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CanonicalStringGraphPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CanonicalStringGraphPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CanonicalStringGraphPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CanonicalStringGraphPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CompilationPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CompilationPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CompilationPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/CompilationPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraalDebugConfigCustomizer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraalDebugConfigCustomizer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraalDebugConfigCustomizer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraalDebugConfigCustomizer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinter.java
similarity index 98%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinter.java
index 6ef7a6143a3..a88c564b7c2 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinter.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinter.java
@@ -69,8 +69,7 @@ interface GraphPrinter extends Closeable {
     void close();
 
     /**
-     * A JVMCI package {@linkplain Services#exportJVMCITo(Class) dynamically exported} to trusted
-     * modules.
+     * A JVMCI package dynamically exported to trusted modules.
      */
     String JVMCI_RUNTIME_PACKAGE = JVMCI.class.getPackage().getName();
 
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinterDumpHandler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinterDumpHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinterDumpHandler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/GraphPrinterDumpHandler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/IdealGraphPrinter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/IdealGraphPrinter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/IdealGraphPrinter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/IdealGraphPrinter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/NoDeadCodeVerifyHandler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/NoDeadCodeVerifyHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/NoDeadCodeVerifyHandler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.printer/src/org/graalvm/compiler/printer/NoDeadCodeVerifyHandler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64CountLeadingZerosNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64CountLeadingZerosNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64CountLeadingZerosNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64CountLeadingZerosNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64FloatArithmeticSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64FloatArithmeticSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64FloatArithmeticSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64FloatArithmeticSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64GraphBuilderPlugins.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64GraphBuilderPlugins.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64GraphBuilderPlugins.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64GraphBuilderPlugins.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64IntegerArithmeticSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64IntegerArithmeticSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64IntegerArithmeticSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64IntegerArithmeticSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64IntegerSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64IntegerSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64IntegerSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64IntegerSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64LongSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64LongSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64LongSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.aarch64/src/org/graalvm/compiler/replacements/aarch64/AArch64LongSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64ConvertSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64ConvertSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64ConvertSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64ConvertSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64CountLeadingZerosNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64CountLeadingZerosNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64CountLeadingZerosNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64CountLeadingZerosNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64CountTrailingZerosNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64CountTrailingZerosNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64CountTrailingZerosNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64CountTrailingZerosNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64FloatConvertNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64FloatConvertNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64FloatConvertNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64FloatConvertNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64GraphBuilderPlugins.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64GraphBuilderPlugins.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64GraphBuilderPlugins.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64GraphBuilderPlugins.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64MathSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64MathSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64MathSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64MathSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64RoundNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64RoundNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64RoundNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.amd64/src/org/graalvm/compiler/replacements/amd64/AMD64RoundNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.sparc/src/org/graalvm/compiler/replacements/sparc/SPARCGraphBuilderPlugins.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.sparc/src/org/graalvm/compiler/replacements/sparc/SPARCGraphBuilderPlugins.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.sparc/src/org/graalvm/compiler/replacements/sparc/SPARCGraphBuilderPlugins.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.sparc/src/org/graalvm/compiler/replacements/sparc/SPARCGraphBuilderPlugins.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ArrayStoreBytecodeExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ArrayStoreBytecodeExceptionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ArrayStoreBytecodeExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ArrayStoreBytecodeExceptionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ArraysSubstitutionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ArraysSubstitutionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ArraysSubstitutionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ArraysSubstitutionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/BitOpNodesTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/BitOpNodesTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/BitOpNodesTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/BitOpNodesTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/BytecodeExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/BytecodeExceptionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/BytecodeExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/BytecodeExceptionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ClassCastBytecodeExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ClassCastBytecodeExceptionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ClassCastBytecodeExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ClassCastBytecodeExceptionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/CompiledExceptionHandlerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/CompiledExceptionHandlerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/CompiledExceptionHandlerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/CompiledExceptionHandlerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/CompiledNullPointerExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/CompiledNullPointerExceptionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/CompiledNullPointerExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/CompiledNullPointerExceptionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DeoptimizeOnExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DeoptimizeOnExceptionTest.java
similarity index 96%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DeoptimizeOnExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DeoptimizeOnExceptionTest.java
index 783c276711c..29d9e330654 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DeoptimizeOnExceptionTest.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DeoptimizeOnExceptionTest.java
@@ -30,10 +30,10 @@ import org.graalvm.compiler.test.ExportingClassLoader;
 import org.junit.Assert;
 import org.junit.Test;
 
-import jdk.internal.org.objectweb.asm.ClassWriter;
-import jdk.internal.org.objectweb.asm.Label;
-import jdk.internal.org.objectweb.asm.MethodVisitor;
-import jdk.internal.org.objectweb.asm.Opcodes;
+import org.objectweb.asm.ClassWriter;
+import org.objectweb.asm.Label;
+import org.objectweb.asm.MethodVisitor;
+import org.objectweb.asm.Opcodes;
 import jdk.vm.ci.meta.ResolvedJavaMethod;
 
 /**
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DerivedOopTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DerivedOopTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DerivedOopTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DerivedOopTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DynamicNewArrayTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DynamicNewArrayTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DynamicNewArrayTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/DynamicNewArrayTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/EdgesTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/EdgesTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/EdgesTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/EdgesTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/FoldTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/FoldTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/FoldTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/FoldTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IndexOobBytecodeExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IndexOobBytecodeExceptionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IndexOobBytecodeExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IndexOobBytecodeExceptionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InstanceOfDynamicTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InstanceOfDynamicTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InstanceOfDynamicTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InstanceOfDynamicTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InstanceOfTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InstanceOfTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InstanceOfTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InstanceOfTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerMulExactFoldTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerMulExactFoldTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerMulExactFoldTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerMulExactFoldTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerSubOverflowsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerSubOverflowsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerSubOverflowsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/IntegerSubOverflowsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InvokeTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InvokeTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InvokeTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/InvokeTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/MethodSubstitutionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/MethodSubstitutionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/MethodSubstitutionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/MethodSubstitutionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/MonitorTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/MonitorTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/MonitorTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/MonitorTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewArrayTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewArrayTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewArrayTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewArrayTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewInstanceTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewInstanceTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewInstanceTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewInstanceTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewMultiArrayTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewMultiArrayTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewMultiArrayTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NewMultiArrayTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NullBytecodeExceptionTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NullBytecodeExceptionTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NullBytecodeExceptionTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/NullBytecodeExceptionTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ObjectAccessTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ObjectAccessTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ObjectAccessTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ObjectAccessTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PEGraphDecoderTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PEGraphDecoderTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PEGraphDecoderTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PEGraphDecoderTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PointerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PointerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PointerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PointerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PointerTrackingTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PointerTrackingTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PointerTrackingTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/PointerTrackingTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ReplacementsParseTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ReplacementsParseTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ReplacementsParseTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/ReplacementsParseTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StandardMethodSubstitutionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StandardMethodSubstitutionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StandardMethodSubstitutionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StandardMethodSubstitutionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringEqualsConstantTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringEqualsConstantTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringEqualsConstantTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringEqualsConstantTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringHashConstantTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringHashConstantTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringHashConstantTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringHashConstantTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringSubstitutionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringSubstitutionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringSubstitutionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/StringSubstitutionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/SubstitutionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/SubstitutionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/SubstitutionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/SubstitutionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/TypeCheckTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/TypeCheckTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/TypeCheckTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/TypeCheckTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsafeSubstitutionsTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsafeSubstitutionsTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsafeSubstitutionsTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsafeSubstitutionsTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsignedIntegerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsignedIntegerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsignedIntegerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsignedIntegerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsignedMathTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsignedMathTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsignedMathTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnsignedMathTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnwindExceptionToCallerTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnwindExceptionToCallerTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnwindExceptionToCallerTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/UnwindExceptionToCallerTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/WordTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/WordTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/WordTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/WordTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/classfile/ClassfileBytecodeProviderTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/classfile/ClassfileBytecodeProviderTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/classfile/ClassfileBytecodeProviderTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/classfile/ClassfileBytecodeProviderTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/classfile/RedefineIntrinsicTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/classfile/RedefineIntrinsicTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/classfile/RedefineIntrinsicTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.test/src/org/graalvm/compiler/replacements/test/classfile/RedefineIntrinsicTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/META-INF/services/javax.annotation.processing.Processor b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/META-INF/services/javax.annotation.processing.Processor
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/META-INF/services/javax.annotation.processing.Processor
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/META-INF/services/javax.annotation.processing.Processor
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/APHotSpotSignature.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/APHotSpotSignature.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/APHotSpotSignature.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/APHotSpotSignature.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/AbstractVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/AbstractVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/AbstractVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/AbstractVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/ClassSubstitutionVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/ClassSubstitutionVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/ClassSubstitutionVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/ClassSubstitutionVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/FoldVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/FoldVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/FoldVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/FoldVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedFoldPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedFoldPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedFoldPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedFoldPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedNodeIntrinsicPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedNodeIntrinsicPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedNodeIntrinsicPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedNodeIntrinsicPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/GeneratedPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/InjectedDependencies.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/InjectedDependencies.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/InjectedDependencies.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/InjectedDependencies.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/MethodSubstitutionVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/MethodSubstitutionVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/MethodSubstitutionVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/MethodSubstitutionVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/NodeIntrinsicVerifier.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/NodeIntrinsicVerifier.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/NodeIntrinsicVerifier.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/NodeIntrinsicVerifier.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/PluginGenerator.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/PluginGenerator.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/PluginGenerator.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/PluginGenerator.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/VerifierAnnotationProcessor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/VerifierAnnotationProcessor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/VerifierAnnotationProcessor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements.verifier/src/org/graalvm/compiler/replacements/verifier/VerifierAnnotationProcessor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ArraySubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ArraySubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ArraySubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ArraySubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ArraysSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ArraysSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ArraysSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ArraysSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/BoxingSnippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/BoxingSnippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/BoxingSnippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/BoxingSnippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/CachingPEGraphDecoder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/CachingPEGraphDecoder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/CachingPEGraphDecoder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/CachingPEGraphDecoder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ConstantBindingParameterPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ConstantBindingParameterPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ConstantBindingParameterPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ConstantBindingParameterPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/DefaultJavaLoweringProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/DefaultJavaLoweringProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/DefaultJavaLoweringProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/DefaultJavaLoweringProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/GraphKit.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/GraphKit.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/GraphKit.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/GraphKit.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InlineDuringParsingPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InlineDuringParsingPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InlineDuringParsingPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InlineDuringParsingPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InlineGraalDirectivesPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InlineGraalDirectivesPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InlineGraalDirectivesPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InlineGraalDirectivesPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InstanceOfSnippetsTemplates.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InstanceOfSnippetsTemplates.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InstanceOfSnippetsTemplates.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/InstanceOfSnippetsTemplates.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/IntegerSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/IntegerSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/IntegerSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/IntegerSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/IntrinsicGraphBuilder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/IntrinsicGraphBuilder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/IntrinsicGraphBuilder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/IntrinsicGraphBuilder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/JavacBug.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/JavacBug.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/JavacBug.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/JavacBug.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/Log.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/Log.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/Log.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/Log.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/LongSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/LongSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/LongSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/LongSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/MethodHandlePlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/MethodHandlePlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/MethodHandlePlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/MethodHandlePlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/NodeIntrinsificationProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/NodeIntrinsificationProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/NodeIntrinsificationProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/NodeIntrinsificationProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/PEGraphDecoder.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/PEGraphDecoder.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/PEGraphDecoder.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/PEGraphDecoder.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ReplacementsImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ReplacementsImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ReplacementsImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ReplacementsImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ReplacementsUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ReplacementsUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ReplacementsUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/ReplacementsUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetCounter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetCounter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetCounter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetCounter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetCounterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetCounterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetCounterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetCounterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetTemplate.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetTemplate.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetTemplate.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/SnippetTemplate.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/Snippets.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/Snippets.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/Snippets.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/Snippets.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StandardGraphBuilderPlugins.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StandardGraphBuilderPlugins.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StandardGraphBuilderPlugins.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StandardGraphBuilderPlugins.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StringSubstitutions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StringSubstitutions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StringSubstitutions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/StringSubstitutions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/WordOperationPlugin.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/WordOperationPlugin.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/WordOperationPlugin.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/WordOperationPlugin.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/Classfile.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/Classfile.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/Classfile.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/Classfile.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileBytecode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileBytecode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileBytecode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileBytecode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileBytecodeProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileBytecodeProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileBytecodeProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileBytecodeProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileConstant.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileConstant.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileConstant.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileConstantPool.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileConstantPool.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileConstantPool.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/classfile/ClassfileConstantPool.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ArrayEqualsNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ArrayEqualsNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ArrayEqualsNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ArrayEqualsNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/AssertionNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/AssertionNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/AssertionNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/AssertionNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BasicArrayCopyNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BasicArrayCopyNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BasicArrayCopyNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BasicArrayCopyNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BasicObjectCloneNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BasicObjectCloneNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BasicObjectCloneNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BasicObjectCloneNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BinaryMathIntrinsicNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BinaryMathIntrinsicNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BinaryMathIntrinsicNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BinaryMathIntrinsicNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitCountNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitCountNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitCountNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitCountNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitScanForwardNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitScanForwardNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitScanForwardNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitScanForwardNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitScanReverseNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitScanReverseNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitScanReverseNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/BitScanReverseNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/CStringConstant.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/CStringConstant.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/CStringConstant.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/CStringConstant.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/DirectObjectStoreNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/DirectObjectStoreNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/DirectObjectStoreNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/DirectObjectStoreNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/DirectStoreNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/DirectStoreNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/DirectStoreNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/DirectStoreNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ExplodeLoopNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ExplodeLoopNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ExplodeLoopNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ExplodeLoopNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/LoadSnippetVarargParameterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/LoadSnippetVarargParameterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/LoadSnippetVarargParameterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/LoadSnippetVarargParameterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MacroNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MacroNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MacroNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MacroNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MacroStateSplitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MacroStateSplitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MacroStateSplitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MacroStateSplitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MethodHandleNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MethodHandleNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MethodHandleNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/MethodHandleNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/PureFunctionMacroNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/PureFunctionMacroNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/PureFunctionMacroNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/PureFunctionMacroNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ReadRegisterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ReadRegisterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ReadRegisterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ReadRegisterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ResolvedMethodHandleCallTargetNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ResolvedMethodHandleCallTargetNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ResolvedMethodHandleCallTargetNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ResolvedMethodHandleCallTargetNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ReverseBytesNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ReverseBytesNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ReverseBytesNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/ReverseBytesNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/UnaryMathIntrinsicNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/UnaryMathIntrinsicNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/UnaryMathIntrinsicNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/UnaryMathIntrinsicNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/VirtualizableInvokeMacroNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/VirtualizableInvokeMacroNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/VirtualizableInvokeMacroNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/VirtualizableInvokeMacroNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/WriteRegisterNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/WriteRegisterNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/WriteRegisterNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/WriteRegisterNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerAddExactNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerAddExactNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerAddExactNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerAddExactNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerAddExactSplitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerAddExactSplitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerAddExactSplitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerAddExactSplitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerExactArithmeticNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerExactArithmeticNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerExactArithmeticNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerExactArithmeticNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerExactArithmeticSplitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerExactArithmeticSplitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerExactArithmeticSplitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerExactArithmeticSplitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulExactNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulExactNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulExactNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulExactNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulExactSplitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulExactSplitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulExactSplitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulExactSplitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulHighNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulHighNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulHighNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerMulHighNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerSubExactNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerSubExactNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerSubExactNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerSubExactNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerSubExactSplitNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerSubExactSplitNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerSubExactSplitNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/IntegerSubExactSplitNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/UnsignedMulHighNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/UnsignedMulHighNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/UnsignedMulHighNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.replacements/src/org/graalvm/compiler/replacements/nodes/arithmetic/UnsignedMulHighNode.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.runtime/src/org/graalvm/compiler/runtime/RuntimeProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.runtime/src/org/graalvm/compiler/runtime/RuntimeProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.runtime/src/org/graalvm/compiler/runtime/RuntimeProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.runtime/src/org/graalvm/compiler/runtime/RuntimeProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/Salver.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/Salver.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/Salver.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/Salver.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/SalverDebugConfigCustomizer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/SalverDebugConfigCustomizer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/SalverDebugConfigCustomizer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/SalverDebugConfigCustomizer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/SalverOptions.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/SalverOptions.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/SalverOptions.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/SalverOptions.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/data/DataDict.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/data/DataDict.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/data/DataDict.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/data/DataDict.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/data/DataList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/data/DataList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/data/DataList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/data/DataList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractGraalDumper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractGraalDumper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractGraalDumper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractGraalDumper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractMethodScopeDumper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractMethodScopeDumper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractMethodScopeDumper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractMethodScopeDumper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractSerializerDumper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractSerializerDumper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractSerializerDumper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/AbstractSerializerDumper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/Dumper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/Dumper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/Dumper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/Dumper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/GraphDumper.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/GraphDumper.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/GraphDumper.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/dumper/GraphDumper.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/AbstractDumpHandler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/AbstractDumpHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/AbstractDumpHandler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/AbstractDumpHandler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/AbstractGraalDumpHandler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/AbstractGraalDumpHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/AbstractGraalDumpHandler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/AbstractGraalDumpHandler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/DumpHandler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/DumpHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/DumpHandler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/DumpHandler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/GraphDumpHandler.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/GraphDumpHandler.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/GraphDumpHandler.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/handler/GraphDumpHandler.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/package-info.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/package-info.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/package-info.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/package-info.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/AbstractSerializer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/AbstractSerializer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/AbstractSerializer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/AbstractSerializer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/JSONSerializer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/JSONSerializer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/JSONSerializer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/JSONSerializer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/Serializer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/Serializer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/Serializer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/serialize/Serializer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/util/ECIDUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/util/ECIDUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/util/ECIDUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/util/ECIDUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/util/MethodContext.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/util/MethodContext.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/util/MethodContext.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/util/MethodContext.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/writer/ChannelDumpWriter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/writer/ChannelDumpWriter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/writer/ChannelDumpWriter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/writer/ChannelDumpWriter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/writer/DumpWriter.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/writer/DumpWriter.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/writer/DumpWriter.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.salver/src/org/graalvm/compiler/salver/writer/DumpWriter.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider.processor/src/META-INF/services/javax.annotation.processing.Processor b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider.processor/src/META-INF/services/javax.annotation.processing.Processor
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider.processor/src/META-INF/services/javax.annotation.processing.Processor
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider.processor/src/META-INF/services/javax.annotation.processing.Processor
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider.processor/src/org/graalvm/compiler/serviceprovider/processor/ServiceProviderProcessor.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider.processor/src/org/graalvm/compiler/serviceprovider/processor/ServiceProviderProcessor.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider.processor/src/org/graalvm/compiler/serviceprovider/processor/ServiceProviderProcessor.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider.processor/src/org/graalvm/compiler/serviceprovider/processor/ServiceProviderProcessor.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/GraalServices.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/GraalServices.java
similarity index 65%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/GraalServices.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/GraalServices.java
index 483cf774822..1f0a4483b4b 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/GraalServices.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/GraalServices.java
@@ -22,9 +22,17 @@
  */
 package org.graalvm.compiler.serviceprovider;
 
+import static org.graalvm.compiler.serviceprovider.JDK9Method.Java8OrEarlier;
+import static org.graalvm.compiler.serviceprovider.JDK9Method.addOpens;
+import static org.graalvm.compiler.serviceprovider.JDK9Method.getModule;
+import static org.graalvm.compiler.serviceprovider.JDK9Method.getPackages;
+import static org.graalvm.compiler.serviceprovider.JDK9Method.isOpenTo;
+
+import java.lang.reflect.Method;
 import java.util.Iterator;
 import java.util.ServiceConfigurationError;
 import java.util.ServiceLoader;
+import java.util.Set;
 
 import jdk.vm.ci.services.JVMCIPermission;
 import jdk.vm.ci.services.Services;
@@ -32,14 +40,32 @@ import jdk.vm.ci.services.Services;
 /**
  * A mechanism for accessing service providers that abstracts over whether Graal is running on
  * JVMCI-8 or JVMCI-9. In JVMCI-8, a JVMCI specific mechanism is used to lookup services via the
- * hidden JVMCI class loader. in JVMCI-9, the standard {@link ServiceLoader} mechanism is used.
+ * hidden JVMCI class loader. In JVMCI-9, the standard {@link ServiceLoader} mechanism is used.
  */
 public final class GraalServices {
 
     private GraalServices() {
     }
 
-    public static final boolean Java8OrEarlier = System.getProperty("java.specification.version").compareTo("1.9") < 0;
+    /**
+     * Opens all JVMCI packages to the module of a given class. This relies on JVMCI already having
+     * opened all its packages to the module defining {@link GraalServices}.
+     *
+     * @param other all JVMCI packages will be opened to the module defining this class
+     */
+    public static void openJVMCITo(Class other) {
+        Object jvmci = getModule.invoke(Services.class);
+        Object otherModule = getModule.invoke(other);
+        if (jvmci != otherModule) {
+            Set packages = getPackages.invoke(jvmci);
+            for (String pkg : packages) {
+                boolean opened = isOpenTo.invoke(jvmci, pkg, otherModule);
+                if (!opened) {
+                    addOpens.invoke(jvmci, pkg, otherModule);
+                }
+            }
+        }
+    }
 
     /**
      * Gets an {@link Iterable} of the providers available for a given service.
@@ -50,9 +76,9 @@ public final class GraalServices {
     public static  Iterable load(Class service) {
         assert !service.getName().startsWith("jdk.vm.ci") : "JVMCI services must be loaded via " + Services.class.getName();
         if (Java8OrEarlier) {
-            return Services.load(service);
+            return load8(service);
         }
-        ServiceLoader iterable = ServiceLoader.load(service);
+        Iterable iterable = ServiceLoader.load(service);
         return new Iterable() {
             @Override
             public Iterator iterator() {
@@ -66,8 +92,8 @@ public final class GraalServices {
                     @Override
                     public S next() {
                         S provider = iterator.next();
-                        // Allow Graal extensions to access JVMCI assuming they have JVMCIPermission
-                        Services.exportJVMCITo(provider.getClass());
+                        // Allow Graal extensions to access JVMCI
+                        openJVMCITo(provider.getClass());
                         return provider;
                     }
 
@@ -80,6 +106,23 @@ public final class GraalServices {
         };
     }
 
+    /**
+     * {@code Services.load(Class)} is only defined in JVMCI-8.
+     */
+    private static volatile Method loadMethod;
+
+    @SuppressWarnings("unchecked")
+    private static  Iterable load8(Class service) throws InternalError {
+        try {
+            if (loadMethod == null) {
+                loadMethod = Services.class.getMethod("load", Class.class);
+            }
+            return (Iterable) loadMethod.invoke(null, service);
+        } catch (Exception e) {
+            throw new InternalError(e);
+        }
+    }
+
     /**
      * Gets the provider for a given service for which at most one provider must be available.
      *
@@ -92,16 +135,14 @@ public final class GraalServices {
      */
     public static  S loadSingle(Class service, boolean required) {
         assert !service.getName().startsWith("jdk.vm.ci") : "JVMCI services must be loaded via " + Services.class.getName();
-        if (Java8OrEarlier) {
-            return Services.loadSingle(service, required);
-        }
-        Iterable providers = ServiceLoader.load(service);
+        Iterable providers = load(service);
         S singleProvider = null;
         try {
             for (Iterator it = providers.iterator(); it.hasNext();) {
                 singleProvider = it.next();
                 if (it.hasNext()) {
-                    throw new InternalError(String.format("Multiple %s providers found", service.getName()));
+                    S other = it.next();
+                    throw new InternalError(String.format("Multiple %s providers found: %s, %s", service.getName(), singleProvider.getClass().getName(), other.getClass().getName()));
                 }
             }
         } catch (ServiceConfigurationError e) {
@@ -111,9 +152,6 @@ public final class GraalServices {
             if (required) {
                 throw new InternalError(String.format("No provider for %s found", service.getName()));
             }
-        } else {
-            // Allow Graal extensions to access JVMCI assuming they have JVMCIPermission
-            Services.exportJVMCITo(singleProvider.getClass());
         }
         return singleProvider;
     }
diff --git a/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/JDK9Method.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/JDK9Method.java
new file mode 100644
index 00000000000..17c8ae0dbbb
--- /dev/null
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/JDK9Method.java
@@ -0,0 +1,148 @@
+/*
+ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+package org.graalvm.compiler.serviceprovider;
+
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.lang.reflect.Modifier;
+
+/**
+ * Reflection based access to API introduced by JDK 9. This allows the API to be used in code that
+ * must be compiled on a JDK prior to 9.
+ */
+public final class JDK9Method {
+
+    private static int getJavaSpecificationVersion() {
+        String value = System.getProperty("java.specification.version");
+        if (value.startsWith("1.")) {
+            value = value.substring(2);
+        }
+        return Integer.parseInt(value);
+    }
+
+    /**
+     * The integer value corresponding to the value of the {@code java.specification.version} system
+     * property after any leading {@code "1."} has been stripped.
+     */
+    public static final int JAVA_SPECIFICATION_VERSION = getJavaSpecificationVersion();
+
+    public JDK9Method(Class declaringClass, String name, Class... parameterTypes) {
+        try {
+            this.method = declaringClass.getMethod(name, parameterTypes);
+        } catch (Exception e) {
+            throw new InternalError(e);
+        }
+    }
+
+    /**
+     * Determines if the Java runtime is version 8 or earlier.
+     */
+    public static final boolean Java8OrEarlier = JAVA_SPECIFICATION_VERSION <= 8;
+
+    public final Method method;
+
+    public Class getReturnType() {
+        return method.getReturnType();
+    }
+
+    /**
+     * {@code Class.getModule()}.
+     */
+    public static final JDK9Method getModule;
+
+    /**
+     * {@code java.lang.Module.getPackages()}.
+     */
+    public static final JDK9Method getPackages;
+
+    /**
+     * {@code java.lang.Module.getResourceAsStream(String)}.
+     */
+    public static final JDK9Method getResourceAsStream;
+
+    /**
+     * {@code java.lang.Module.addOpens(String, Module)}.
+     */
+    public static final JDK9Method addOpens;
+
+    /**
+     * {@code java.lang.Module.isOpen(String, Module)}.
+     */
+    public static final JDK9Method isOpenTo;
+
+    /**
+     * Invokes the static Module API method represented by this object.
+     */
+    @SuppressWarnings("unchecked")
+    public  T invokeStatic(Object... args) {
+        checkAvailability();
+        assert Modifier.isStatic(method.getModifiers());
+        try {
+            return (T) method.invoke(null, args);
+        } catch (IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
+            throw new InternalError(e);
+        }
+    }
+
+    /**
+     * Invokes the non-static Module API method represented by this object.
+     */
+    @SuppressWarnings("unchecked")
+    public  T invoke(Object receiver, Object... args) {
+        checkAvailability();
+        assert !Modifier.isStatic(method.getModifiers());
+        try {
+            return (T) method.invoke(receiver, args);
+        } catch (IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
+            throw new InternalError(e);
+        }
+    }
+
+    private void checkAvailability() throws InternalError {
+        if (method == null) {
+            throw new InternalError("Cannot use Module API on JDK " + JAVA_SPECIFICATION_VERSION);
+        }
+    }
+
+    static {
+        if (JAVA_SPECIFICATION_VERSION >= 9) {
+            getModule = new JDK9Method(Class.class, "getModule");
+            Class moduleClass = getModule.getReturnType();
+            getPackages = new JDK9Method(moduleClass, "getPackages");
+            addOpens = new JDK9Method(moduleClass, "addOpens", String.class, moduleClass);
+            getResourceAsStream = new JDK9Method(moduleClass, "getResourceAsStream", String.class);
+            isOpenTo = new JDK9Method(moduleClass, "isOpen", String.class, moduleClass);
+        } else {
+            JDK9Method unavailable = new JDK9Method();
+            getModule = unavailable;
+            getPackages = unavailable;
+            addOpens = unavailable;
+            getResourceAsStream = unavailable;
+            isOpenTo = unavailable;
+        }
+    }
+
+    private JDK9Method() {
+        method = null;
+    }
+}
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/ServiceProvider.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/ServiceProvider.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/ServiceProvider.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.serviceprovider/src/org/graalvm/compiler/serviceprovider/ServiceProvider.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/ExportingClassLoader.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/ExportingClassLoader.java
similarity index 88%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/ExportingClassLoader.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/ExportingClassLoader.java
index e139b19c971..1c08964c696 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/ExportingClassLoader.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/ExportingClassLoader.java
@@ -29,14 +29,14 @@ package org.graalvm.compiler.test;
 public class ExportingClassLoader extends ClassLoader {
     public ExportingClassLoader() {
         if (!GraalTest.Java8OrEarlier) {
-            JLRModule.fromClass(getClass()).exportAllPackagesTo(JLRModule.getUnnamedModuleFor(this));
+            JLModule.fromClass(getClass()).exportAllPackagesTo(JLModule.getUnnamedModuleFor(this));
         }
     }
 
     public ExportingClassLoader(ClassLoader parent) {
         super(parent);
         if (!GraalTest.Java8OrEarlier) {
-            JLRModule.fromClass(getClass()).exportAllPackagesTo(JLRModule.getUnnamedModuleFor(this));
+            JLModule.fromClass(getClass()).exportAllPackagesTo(JLModule.getUnnamedModuleFor(this));
         }
     }
 }
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/GraalTest.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/GraalTest.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/GraalTest.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/GraalTest.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/JLRModule.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/JLModule.java
similarity index 79%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/JLRModule.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/JLModule.java
index caa32231bd6..9f8c6e2014c 100644
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/JLRModule.java
+++ b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/JLModule.java
@@ -23,22 +23,23 @@
 package org.graalvm.compiler.test;
 
 import java.lang.reflect.Method;
+import java.util.Set;
 
 /**
- * Facade for the {@code java.lang.reflect.Module} class introduced in JDK9 that allows tests to be
+ * Facade for the {@code java.lang.Module} class introduced in JDK9 that allows tests to be
  * developed against JDK8 but use module logic if deployed on JDK9.
  */
-public class JLRModule {
+public class JLModule {
 
     static {
         if (GraalTest.Java8OrEarlier) {
-            throw new AssertionError("Use of " + JLRModule.class + " only allowed if " + GraalTest.class.getName() + ".JDK8OrEarlier is false");
+            throw new AssertionError("Use of " + JLModule.class + " only allowed if " + GraalTest.class.getName() + ".JDK8OrEarlier is false");
         }
     }
 
     private final Object realModule;
 
-    public JLRModule(Object module) {
+    public JLModule(Object module) {
         this.realModule = module;
     }
 
@@ -51,7 +52,7 @@ public class JLRModule {
     private static final Method addExportsMethod;
     static {
         try {
-            moduleClass = Class.forName("java.lang.reflect.Module");
+            moduleClass = Class.forName("java.lang.Module");
             getModuleMethod = Class.class.getMethod("getModule");
             getUnnamedModuleMethod = ClassLoader.class.getMethod("getUnnamedModule");
             getPackagesMethod = moduleClass.getMethod("getPackages");
@@ -63,17 +64,17 @@ public class JLRModule {
         }
     }
 
-    public static JLRModule fromClass(Class cls) {
+    public static JLModule fromClass(Class cls) {
         try {
-            return new JLRModule(getModuleMethod.invoke(cls));
+            return new JLModule(getModuleMethod.invoke(cls));
         } catch (Exception e) {
             throw new AssertionError(e);
         }
     }
 
-    public static JLRModule getUnnamedModuleFor(ClassLoader cl) {
+    public static JLModule getUnnamedModuleFor(ClassLoader cl) {
         try {
-            return new JLRModule(getUnnamedModuleMethod.invoke(cl));
+            return new JLModule(getUnnamedModuleMethod.invoke(cl));
         } catch (Exception e) {
             throw new AssertionError(e);
         }
@@ -82,7 +83,7 @@ public class JLRModule {
     /**
      * Exports all packages in this module to a given module.
      */
-    public void exportAllPackagesTo(JLRModule module) {
+    public void exportAllPackagesTo(JLModule module) {
         if (this != module) {
             for (String pkg : getPackages()) {
                 // Export all JVMCI packages dynamically instead
@@ -95,9 +96,10 @@ public class JLRModule {
         }
     }
 
-    public String[] getPackages() {
+    @SuppressWarnings("unchecked")
+    public Set getPackages() {
         try {
-            return (String[]) getPackagesMethod.invoke(realModule);
+            return (Set) getPackagesMethod.invoke(realModule);
         } catch (Exception e) {
             throw new AssertionError(e);
         }
@@ -111,7 +113,7 @@ public class JLRModule {
         }
     }
 
-    public boolean isExported(String pn, JLRModule other) {
+    public boolean isExported(String pn, JLModule other) {
         try {
             return (Boolean) isExported2Method.invoke(realModule, pn, other.realModule);
         } catch (Exception e) {
@@ -119,7 +121,7 @@ public class JLRModule {
         }
     }
 
-    public void addExports(String pn, JLRModule other) {
+    public void addExports(String pn, JLModule other) {
         try {
             addExportsMethod.invoke(realModule, pn, other.realModule);
         } catch (Exception e) {
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/SubprocessUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/SubprocessUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/SubprocessUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.test/src/org/graalvm/compiler/test/SubprocessUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual.bench/.checkstyle.exclude b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual.bench/.checkstyle.exclude
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual.bench/.checkstyle.exclude
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual.bench/.checkstyle.exclude
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual.bench/src/org/graalvm/compiler/virtual/bench/PartialEscapeBench.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual.bench/src/org/graalvm/compiler/virtual/bench/PartialEscapeBench.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual.bench/src/org/graalvm/compiler/virtual/bench/PartialEscapeBench.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual.bench/src/org/graalvm/compiler/virtual/bench/PartialEscapeBench.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/nodes/MaterializedObjectState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/nodes/MaterializedObjectState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/nodes/MaterializedObjectState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/nodes/MaterializedObjectState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/nodes/VirtualObjectState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/nodes/VirtualObjectState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/nodes/VirtualObjectState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/nodes/VirtualObjectState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EarlyReadEliminationPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EarlyReadEliminationPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EarlyReadEliminationPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EarlyReadEliminationPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsBlockState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsBlockState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsBlockState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsBlockState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsClosure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsClosure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsClosure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsClosure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsPhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsPhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsPhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/EffectsPhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/GraphEffectList.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/GraphEffectList.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/GraphEffectList.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/GraphEffectList.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ObjectState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ObjectState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ObjectState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ObjectState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PEReadEliminationBlockState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PEReadEliminationBlockState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PEReadEliminationBlockState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PEReadEliminationBlockState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PEReadEliminationClosure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PEReadEliminationClosure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PEReadEliminationClosure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PEReadEliminationClosure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapeBlockState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapeBlockState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapeBlockState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapeBlockState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapeClosure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapeClosure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapeClosure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapeClosure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapePhase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapePhase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapePhase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/PartialEscapePhase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ReadEliminationBlockState.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ReadEliminationBlockState.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ReadEliminationBlockState.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ReadEliminationBlockState.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ReadEliminationClosure.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ReadEliminationClosure.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ReadEliminationClosure.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/ReadEliminationClosure.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/VirtualUtil.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/VirtualUtil.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/VirtualUtil.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/VirtualUtil.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/VirtualizerToolImpl.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/VirtualizerToolImpl.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/VirtualizerToolImpl.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.virtual/src/org/graalvm/compiler/virtual/phases/ea/VirtualizerToolImpl.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/AtomicUnsigned.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/AtomicUnsigned.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/AtomicUnsigned.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/AtomicUnsigned.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/AtomicWord.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/AtomicWord.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/AtomicWord.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/AtomicWord.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/BarrieredAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/BarrieredAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/BarrieredAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/BarrieredAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/ComparableWord.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/ComparableWord.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/ComparableWord.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/ComparableWord.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/ObjectAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/ObjectAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/ObjectAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/ObjectAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Pointer.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Pointer.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Pointer.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Pointer.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/PointerBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/PointerBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/PointerBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/PointerBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/PointerUtils.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/PointerUtils.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/PointerUtils.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/PointerUtils.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Signed.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Signed.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Signed.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Signed.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/UnsafeAccess.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/UnsafeAccess.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/UnsafeAccess.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/UnsafeAccess.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Unsigned.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Unsigned.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Unsigned.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Unsigned.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/UnsignedUtils.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/UnsignedUtils.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/UnsignedUtils.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/UnsignedUtils.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Word.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Word.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Word.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/Word.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/WordBase.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/WordBase.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/WordBase.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/WordBase.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/WordTypes.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/WordTypes.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/WordTypes.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/WordTypes.java
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/nodes/WordCastNode.java b/hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/nodes/WordCastNode.java
similarity index 100%
rename from hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/nodes/WordCastNode.java
rename to hotspot/src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.word/src/org/graalvm/compiler/word/nodes/WordCastNode.java
diff --git a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java b/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java
deleted file mode 100644
index dbeb7fbf6b0..00000000000
--- a/hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java
+++ /dev/null
@@ -1,187 +0,0 @@
-/*
- * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-package jdk.vm.ci.services;
-
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.Formatter;
-import java.util.Iterator;
-import java.util.ServiceConfigurationError;
-import java.util.ServiceLoader;
-
-/**
- * A mechanism for accessing service providers via JVMCI.
- */
-public final class Services {
-
-    private Services() {
-    }
-
-    private static int getJavaSpecificationVersion() {
-        String value = System.getProperty("java.specification.version");
-        if (value.startsWith("1.")) {
-            value = value.substring(2);
-        }
-        return Integer.parseInt(value);
-    }
-
-    /**
-     * The integer value corresponding to the value of the {@code java.specification.version} system
-     * property after any leading {@code "1."} has been stripped.
-     */
-    public static final int JAVA_SPECIFICATION_VERSION = getJavaSpecificationVersion();
-
-    // Use reflection so that this compiles on Java 8
-    private static final Method getModule;
-    private static final Method getPackages;
-    private static final Method addUses;
-    private static final Method isExported;
-    private static final Method addExports;
-
-    static {
-        if (JAVA_SPECIFICATION_VERSION >= 9) {
-            try {
-                getModule = Class.class.getMethod("getModule");
-                Class moduleClass = getModule.getReturnType();
-                getPackages = moduleClass.getMethod("getPackages");
-                addUses = moduleClass.getMethod("addUses", Class.class);
-                isExported = moduleClass.getMethod("isExported", String.class, moduleClass);
-                addExports = moduleClass.getMethod("addExports", String.class, moduleClass);
-            } catch (NoSuchMethodException | SecurityException e) {
-                throw new InternalError(e);
-            }
-        } else {
-            getModule = null;
-            getPackages = null;
-            addUses = null;
-            isExported = null;
-            addExports = null;
-        }
-    }
-
-    @SuppressWarnings("unchecked")
-    static  T invoke(Method method, Object receiver, Object... args) {
-        try {
-            return (T) method.invoke(receiver, args);
-        } catch (IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
-            throw new InternalError(e);
-        }
-    }
-
-    /**
-     * Performs any required security checks and dynamic reconfiguration to allow the module of a
-     * given class to access the classes in the JVMCI module.
-     *
-     * Note: This API uses {@link Class} instead of {@code Module} to provide backwards
-     * compatibility for JVMCI clients compiled against a JDK release earlier than 9.
-     *
-     * @param requestor a class requesting access to the JVMCI module for its module
-     * @throws SecurityException if a security manager is present and it denies
-     *             {@link JVMCIPermission}
-     */
-    public static void exportJVMCITo(Class requestor) {
-        SecurityManager sm = System.getSecurityManager();
-        if (sm != null) {
-            sm.checkPermission(new JVMCIPermission());
-        }
-        if (JAVA_SPECIFICATION_VERSION >= 9) {
-            Object jvmci = invoke(getModule, Services.class);
-            Object requestorModule = invoke(getModule, requestor);
-            if (jvmci != requestorModule) {
-                String[] packages = invoke(getPackages, jvmci);
-                for (String pkg : packages) {
-                    // Export all JVMCI packages dynamically instead
-                    // of requiring a long list of --add-exports
-                    // options on the JVM command line.
-                    boolean exported = invoke(isExported, jvmci, pkg, requestorModule);
-                    if (!exported) {
-                        invoke(addExports, jvmci, pkg, requestorModule);
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Gets an {@link Iterable} of the JVMCI providers available for a given service.
-     *
-     * @throws SecurityException if a security manager is present and it denies
-     *             {@link JVMCIPermission}
-     */
-    public static  Iterable load(Class service) {
-        SecurityManager sm = System.getSecurityManager();
-        if (sm != null) {
-            sm.checkPermission(new JVMCIPermission());
-        }
-        if (JAVA_SPECIFICATION_VERSION >= 9) {
-            Object jvmci = invoke(getModule, Services.class);
-            invoke(addUses, jvmci, service);
-        }
-
-        // Restrict JVMCI clients to be on the class path or module path
-        return ServiceLoader.load(service, ClassLoader.getSystemClassLoader());
-    }
-
-    /**
-     * Gets the JVMCI provider for a given service for which at most one provider must be available.
-     *
-     * @param service the service whose provider is being requested
-     * @param required specifies if an {@link InternalError} should be thrown if no provider of
-     *            {@code service} is available
-     * @throws SecurityException if a security manager is present and it denies
-     *             {@link JVMCIPermission}
-     */
-    public static  S loadSingle(Class service, boolean required) {
-        SecurityManager sm = System.getSecurityManager();
-        if (sm != null) {
-            sm.checkPermission(new JVMCIPermission());
-        }
-        if (JAVA_SPECIFICATION_VERSION >= 9) {
-            Object jvmci = invoke(getModule, Services.class);
-            invoke(addUses, jvmci, service);
-        }
-        // Restrict JVMCI clients to be on the class path or module path
-        Iterable providers = ServiceLoader.load(service, ClassLoader.getSystemClassLoader());
-        S singleProvider = null;
-        try {
-            for (Iterator it = providers.iterator(); it.hasNext();) {
-                singleProvider = it.next();
-                if (it.hasNext()) {
-                    throw new InternalError(String.format("Multiple %s providers found", service.getName()));
-                }
-            }
-        } catch (ServiceConfigurationError e) {
-            // If the service is required we will bail out below.
-        }
-        if (singleProvider == null && required) {
-            String javaHome = System.getProperty("java.home");
-            String vmName = System.getProperty("java.vm.name");
-            Formatter errorMessage = new Formatter();
-            errorMessage.format("The VM does not expose required service %s.%n", service.getName());
-            errorMessage.format("Currently used Java home directory is %s.%n", javaHome);
-            errorMessage.format("Currently used VM configuration is: %s", vmName);
-            throw new UnsupportedOperationException(errorMessage.toString());
-        }
-        return singleProvider;
-    }
-}
diff --git a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalJVMCIServiceLocator.java b/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalJVMCIServiceLocator.java
deleted file mode 100644
index b33b0cf437f..00000000000
--- a/hotspot/src/jdk.vm.compiler/share/classes/org.graalvm.compiler.hotspot/src/org/graalvm/compiler/hotspot/HotSpotGraalJVMCIServiceLocator.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-package org.graalvm.compiler.hotspot;
-
-import static org.graalvm.compiler.core.common.util.ModuleAPI.addExports;
-import static org.graalvm.compiler.core.common.util.ModuleAPI.getModule;
-import static org.graalvm.compiler.core.common.util.Util.JAVA_SPECIFICATION_VERSION;
-
-import org.graalvm.compiler.serviceprovider.ServiceProvider;
-
-import jdk.vm.ci.hotspot.HotSpotVMEventListener;
-import jdk.vm.ci.runtime.JVMCICompilerFactory;
-import jdk.vm.ci.services.JVMCIServiceLocator;
-
-@ServiceProvider(JVMCIServiceLocator.class)
-public final class HotSpotGraalJVMCIServiceLocator extends JVMCIServiceLocator {
-
-    private boolean exportsAdded;
-
-    /**
-     * Dynamically exports various internal JDK packages to the Graal module. This requires only
-     * {@code --add-exports=java.base/jdk.internal.module=org.graalvm.compiler.graal_core} on the VM
-     * command line instead of a {@code --add-exports} instance for each JDK internal package used
-     * by Graal.
-     */
-    private void addExports() {
-        if (JAVA_SPECIFICATION_VERSION >= 9 && !exportsAdded) {
-            Object javaBaseModule = getModule.invoke(String.class);
-            Object graalModule = getModule.invoke(getClass());
-            addExports.invokeStatic(javaBaseModule, "jdk.internal.misc", graalModule);
-            addExports.invokeStatic(javaBaseModule, "jdk.internal.jimage", graalModule);
-            addExports.invokeStatic(javaBaseModule, "com.sun.crypto.provider", graalModule);
-            exportsAdded = true;
-        }
-    }
-
-    private HotSpotGraalRuntime graalRuntime;
-
-    @Override
-    public  T getProvider(Class service) {
-        if (service == JVMCICompilerFactory.class) {
-            addExports();
-            return service.cast(new HotSpotGraalCompilerFactory(this));
-        } else if (service == HotSpotVMEventListener.class) {
-            if (graalRuntime != null) {
-                addExports();
-                return service.cast(new HotSpotGraalVMEventListener(graalRuntime));
-            }
-        }
-        return null;
-    }
-
-    public void onCompilerCreation(HotSpotGraalCompiler compiler) {
-        assert this.graalRuntime == null : "only expect a single JVMCICompiler to be created";
-        this.graalRuntime = (HotSpotGraalRuntime) compiler.getGraalRuntime();
-    }
-}
diff --git a/hotspot/src/os/solaris/vm/os_solaris.cpp b/hotspot/src/os/solaris/vm/os_solaris.cpp
index 527246dcc3d..adbec4e459e 100644
--- a/hotspot/src/os/solaris/vm/os_solaris.cpp
+++ b/hotspot/src/os/solaris/vm/os_solaris.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -3050,15 +3050,12 @@ void os::naked_yield() {
   thr_yield();
 }
 
-// Interface for setting lwp priorities.  If we are using T2 libthread,
-// which forces the use of BoundThreads or we manually set UseBoundThreads,
-// all of our threads will be assigned to real lwp's.  Using the thr_setprio
-// function is meaningless in this mode so we must adjust the real lwp's priority
+// Interface for setting lwp priorities.  We are using T2 libthread,
+// which forces the use of bound threads, so all of our threads will
+// be assigned to real lwp's.  Using the thr_setprio function is
+// meaningless in this mode so we must adjust the real lwp's priority.
 // The routines below implement the getting and setting of lwp priorities.
 //
-// Note: T2 is now the only supported libthread. UseBoundThreads flag is
-//       being deprecated and all threads are now BoundThreads
-//
 // Note: There are three priority scales used on Solaris.  Java priotities
 //       which range from 1 to 10, libthread "thr_setprio" scale which range
 //       from 0 to 127, and the current scheduling class of the process we
diff --git a/hotspot/src/share/vm/Xusage.txt b/hotspot/src/share/vm/Xusage.txt
index 3849f8f8e2c..8c8eba19ace 100644
--- a/hotspot/src/share/vm/Xusage.txt
+++ b/hotspot/src/share/vm/Xusage.txt
@@ -12,7 +12,7 @@
     -Xms        set initial Java heap size
     -Xmx        set maximum Java heap size
     -Xss        set java thread stack size
-    -Xprof            output cpu profiling data
+    -Xprof            output cpu profiling data (deprecated)
     -Xfuture          enable strictest checks, anticipating future default
     -Xrs              reduce use of OS signals by Java/VM (see documentation)
     -Xcheck:jni       perform additional checks for JNI functions
diff --git a/hotspot/src/share/vm/aot/aotCodeHeap.cpp b/hotspot/src/share/vm/aot/aotCodeHeap.cpp
index 52e2c8d55b1..87d41f80777 100644
--- a/hotspot/src/share/vm/aot/aotCodeHeap.cpp
+++ b/hotspot/src/share/vm/aot/aotCodeHeap.cpp
@@ -830,38 +830,19 @@ void AOTCodeHeap::oops_do(OopClosure* f) {
   }
 }
 
-// Yes, this is faster than going through the relocations,
-// but there are two problems:
-// 1) GOT slots are sometimes patched with non-Metadata values
-// 2) We don't want to scan metadata for dead methods
-// Unfortunately we don't know if the metadata belongs to
-// live aot methods or not, so process them all.  If this
-// is for mark_on_stack, some old methods may stick around
-// forever instead of getting cleaned up.
+// Scan only metaspace_got cells which should have only Klass*,
+// metadata_got cells are scanned only for alive AOT methods
+// by AOTCompiledMethod::metadata_do().
 void AOTCodeHeap::got_metadata_do(void f(Metadata*)) {
   for (int i = 1; i < _metaspace_got_size; i++) {
     Metadata** p = &_metaspace_got[i];
     Metadata* md = *p;
     if (md == NULL)  continue;  // skip non-oops
-    intptr_t meta = (intptr_t)md;
-    if (meta == -1)  continue;  // skip non-oops
     if (Metaspace::contains(md)) {
       f(md);
-    }
-  }
-  for (int i = 1; i < _metadata_got_size; i++) {
-    Metadata** p = &_metadata_got[i];
-    Metadata* md = *p;
-    intptr_t meta = (intptr_t)md;
-    if ((meta & 1) == 1) {
-      // already resolved
-      md = (Metadata*)(meta & ~1);
     } else {
-      continue;
-    }
-    if (md == NULL)  continue;  // skip non-oops
-    if (Metaspace::contains(md)) {
-      f(md);
+      intptr_t meta = (intptr_t)md;
+      fatal("Invalid value in _metaspace_got[%d] = " INTPTR_FORMAT, i, meta);
     }
   }
 }
@@ -910,8 +891,6 @@ void AOTCodeHeap::metadata_do(void f(Metadata*)) {
       aot->metadata_do(f);
     }
   }
-#if 0
-  // With the marking above, this call doesn't seem to be needed
+  // Scan metaspace_got cells.
   got_metadata_do(f);
-#endif
 }
diff --git a/hotspot/src/share/vm/aot/aotCodeHeap.hpp b/hotspot/src/share/vm/aot/aotCodeHeap.hpp
index 0e0d0038d10..5c803cc0903 100644
--- a/hotspot/src/share/vm/aot/aotCodeHeap.hpp
+++ b/hotspot/src/share/vm/aot/aotCodeHeap.hpp
@@ -240,6 +240,11 @@ public:
     assert(result == CodeHeap::contains(p), "");
     return result;
   }
+
+  bool contains_blob(const CodeBlob* blob) const {
+    return CodeHeap::contains(blob->code_begin());
+  }
+
   AOTCompiledMethod* find_aot(address p) const;
 
   virtual void* find_start(void* p)     const;
diff --git a/hotspot/src/share/vm/aot/aotCompiledMethod.cpp b/hotspot/src/share/vm/aot/aotCompiledMethod.cpp
index 1f40284da7e..c501ce12e69 100644
--- a/hotspot/src/share/vm/aot/aotCompiledMethod.cpp
+++ b/hotspot/src/share/vm/aot/aotCompiledMethod.cpp
@@ -71,15 +71,6 @@ static void metadata_oops_do(Metadata** metadata_begin, Metadata **metadata_end,
 }
 #endif
 
-void AOTCompiledMethod::oops_do(OopClosure* f) {
-  if (_oop != NULL) {
-    f->do_oop(&_oop);
-  }
-#if 0
-  metadata_oops_do(metadata_begin(), metadata_end(), f);
-#endif
-}
-
 bool AOTCompiledMethod::do_unloading_oops(address low_boundary, BoolObjectClosure* is_alive, bool unloading_occurred) {
   return false;
 }
@@ -161,9 +152,6 @@ Metadata* AOTCompiledMethod::metadata_at(int index) const {
       *entry = (Metadata*)meta; // Should be atomic on x64
       return (Metadata*)m;
     }
-    // need to resolve it here..., patching of GOT need to be CAS or atomic operation.
-    // FIXIT: need methods for debuginfo.
-    // return _method;
   }
   ShouldNotReachHere(); return NULL;
 }
@@ -288,11 +276,19 @@ void AOTCompiledMethod::metadata_do(void f(Metadata*)) {
           f(cichk->holder_method());
           f(cichk->holder_klass());
         } else {
+          // Get Klass* or NULL (if value is -1) from GOT cell of virtual call PLT stub.
           Metadata* ic_oop = ic->cached_metadata();
           if (ic_oop != NULL) {
             f(ic_oop);
           }
         }
+      } else if (iter.type() == relocInfo::static_call_type ||
+                 iter.type() == relocInfo::opt_virtual_call_type){
+        // Check Method* in AOT c2i stub for other calls.
+        Metadata* meta = (Metadata*)nativeLoadGot_at(nativePltCall_at(iter.addr())->plt_c2i_stub())->data();
+        if (meta != NULL) {
+          f(meta);
+        }
       }
     }
   }
@@ -332,7 +328,12 @@ void AOTCompiledMethod::print_on(outputStream* st, const char* msg) const {
     st->print("%4d ", _aot_id);    // print compilation number
     st->print("    aot[%2d]", _heap->dso_id());
     // Stubs have _method == NULL
-    st->print("   %s", (_method == NULL ? _name : _method->name_and_sig_as_C_string()));
+    if (_method == NULL) {
+      st->print("   %s", _name);
+    } else {
+      ResourceMark m;
+      st->print("   %s", _method->name_and_sig_as_C_string());
+    }
     if (Verbose) {
       st->print(" entry at " INTPTR_FORMAT, p2i(_code));
     }
diff --git a/hotspot/src/share/vm/aot/aotCompiledMethod.hpp b/hotspot/src/share/vm/aot/aotCompiledMethod.hpp
index 7fef6fdb433..723bbdb8d30 100644
--- a/hotspot/src/share/vm/aot/aotCompiledMethod.hpp
+++ b/hotspot/src/share/vm/aot/aotCompiledMethod.hpp
@@ -257,8 +257,6 @@ private:
     return (int) (*_state_adr);
   }
 
-  virtual void oops_do(OopClosure* f);
-
   // inlined and non-virtual for AOTCodeHeap::oops_do
   void do_oops(OopClosure* f) {
     assert(_is_alive(), "");
diff --git a/hotspot/src/share/vm/aot/aotLoader.cpp b/hotspot/src/share/vm/aot/aotLoader.cpp
index 0dbf9ff72e4..bd2cc8f58f0 100644
--- a/hotspot/src/share/vm/aot/aotLoader.cpp
+++ b/hotspot/src/share/vm/aot/aotLoader.cpp
@@ -113,8 +113,8 @@ static const char* modules[] = {
   "java.logging",
   "jdk.compiler",
   "jdk.scripting.nashorn",
-  "jdk.vm.ci",
-  "jdk.vm.compiler"
+  "jdk.internal.vm.ci",
+  "jdk.internal.vm.compiler"
 };
 
 void AOTLoader::initialize() {
diff --git a/hotspot/src/share/vm/c1/c1_Canonicalizer.cpp b/hotspot/src/share/vm/c1/c1_Canonicalizer.cpp
index e3a7af67742..095ac876292 100644
--- a/hotspot/src/share/vm/c1/c1_Canonicalizer.cpp
+++ b/hotspot/src/share/vm/c1/c1_Canonicalizer.cpp
@@ -248,7 +248,9 @@ void Canonicalizer::do_ArrayLength    (ArrayLength*     x) {
   } else if ((lf = x->array()->as_LoadField()) != NULL) {
     ciField* field = lf->field();
     if (field->is_static_constant()) {
-      assert(PatchALot || ScavengeRootsInCode < 2, "Constant field loads are folded during parsing");
+      // Constant field loads are usually folded during parsing.
+      // But it doesn't happen with PatchALot, ScavengeRootsInCode < 2, or when
+      // holder class is being initialized during parsing (for static fields).
       ciObject* c = field->constant_value().as_object();
       if (!c->is_null_object()) {
         set_constant(c->as_array()->length());
diff --git a/hotspot/src/share/vm/c1/c1_CodeStubs.hpp b/hotspot/src/share/vm/c1/c1_CodeStubs.hpp
index 457c9cc14eb..3f2dbde1939 100644
--- a/hotspot/src/share/vm/c1/c1_CodeStubs.hpp
+++ b/hotspot/src/share/vm/c1/c1_CodeStubs.hpp
@@ -58,6 +58,7 @@ class CodeStub: public CompilationResourceObj {
   virtual bool is_exception_throw_stub() const   { return false; }
   virtual bool is_range_check_stub() const       { return false; }
   virtual bool is_divbyzero_stub() const         { return false; }
+  virtual bool is_simple_exception_stub() const  { return false; }
 #ifndef PRODUCT
   virtual void print_name(outputStream* out) const = 0;
 #endif
@@ -483,6 +484,7 @@ class SimpleExceptionStub: public CodeStub {
   virtual void emit_code(LIR_Assembler* e);
   virtual CodeEmitInfo* info() const             { return _info; }
   virtual bool is_exception_throw_stub() const   { return true; }
+  virtual bool is_simple_exception_stub() const  { return true; }
   virtual void visit(LIR_OpVisitState* visitor) {
     if (_obj->is_valid()) visitor->do_input(_obj);
     visitor->do_slow_case(_info);
diff --git a/hotspot/src/share/vm/c1/c1_Compiler.cpp b/hotspot/src/share/vm/c1/c1_Compiler.cpp
index 731b9efc96c..416f0f38fc8 100644
--- a/hotspot/src/share/vm/c1/c1_Compiler.cpp
+++ b/hotspot/src/share/vm/c1/c1_Compiler.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -108,7 +108,7 @@ bool Compiler::is_intrinsic_supported(const methodHandle& method) {
   }
 
   switch (id) {
-  case vmIntrinsics::_compareAndSwapLong:
+  case vmIntrinsics::_compareAndSetLong:
     if (!VM_Version::supports_cx8()) return false;
     break;
   case vmIntrinsics::_getAndAddInt:
@@ -217,8 +217,8 @@ bool Compiler::is_intrinsic_supported(const methodHandle& method) {
   case vmIntrinsics::_updateDirectByteBufferCRC32C:
 #endif
   case vmIntrinsics::_vectorizedMismatch:
-  case vmIntrinsics::_compareAndSwapInt:
-  case vmIntrinsics::_compareAndSwapObject:
+  case vmIntrinsics::_compareAndSetInt:
+  case vmIntrinsics::_compareAndSetObject:
   case vmIntrinsics::_getCharStringU:
   case vmIntrinsics::_putCharStringU:
 #ifdef TRACE_HAVE_INTRINSICS
diff --git a/hotspot/src/share/vm/c1/c1_GraphBuilder.cpp b/hotspot/src/share/vm/c1/c1_GraphBuilder.cpp
index 1a0a5f63687..d4400483912 100644
--- a/hotspot/src/share/vm/c1/c1_GraphBuilder.cpp
+++ b/hotspot/src/share/vm/c1/c1_GraphBuilder.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -1540,7 +1540,7 @@ void GraphBuilder::method_return(Value x, bool ignore_return) {
         ciMethod* caller = state()->scope()->method();
         ciMethodData* md = caller->method_data_or_null();
         ciProfileData* data = md->bci_to_data(invoke_bci);
-        if (data->is_CallTypeData() || data->is_VirtualCallTypeData()) {
+        if (data != NULL && (data->is_CallTypeData() || data->is_VirtualCallTypeData())) {
           bool has_return = data->is_CallTypeData() ? ((ciCallTypeData*)data)->has_return() : ((ciVirtualCallTypeData*)data)->has_return();
           // May not be true in case of an inlined call through a method handle intrinsic.
           if (has_return) {
@@ -1758,7 +1758,7 @@ Values* GraphBuilder::args_list_for_profiling(ciMethod* target, int& start, bool
   start = has_receiver ? 1 : 0;
   if (profile_arguments()) {
     ciProfileData* data = method()->method_data()->bci_to_data(bci());
-    if (data->is_CallTypeData() || data->is_VirtualCallTypeData()) {
+    if (data != NULL && (data->is_CallTypeData() || data->is_VirtualCallTypeData())) {
       n = data->is_CallTypeData() ? data->as_CallTypeData()->number_of_arguments() : data->as_VirtualCallTypeData()->number_of_arguments();
     }
   }
@@ -1829,6 +1829,20 @@ void GraphBuilder::invoke(Bytecodes::Code code) {
                 log->identify(target),
                 Bytecodes::name(code));
 
+  // invoke-special-super
+  if (bc_raw == Bytecodes::_invokespecial && !target->is_object_initializer()) {
+    ciInstanceKlass* sender_klass =
+          calling_klass->is_anonymous() ? calling_klass->host_klass() :
+                                          calling_klass;
+    if (sender_klass->is_interface()) {
+      int index = state()->stack_size() - (target->arg_size_no_receiver() + 1);
+      Value receiver = state()->stack_at(index);
+      CheckCast* c = new CheckCast(sender_klass, receiver, copy_state_before());
+      c->set_invokespecial_receiver_check();
+      state()->stack_at_put(index, append_split(c));
+    }
+  }
+
   // Some methods are obviously bindable without any type checks so
   // convert them directly to an invokespecial or invokestatic.
   if (target->is_loaded() && !target->is_abstract() && target->can_be_statically_bound()) {
@@ -3486,9 +3500,9 @@ void GraphBuilder::build_graph_for_intrinsic(ciMethod* callee, bool ignore_retur
   case vmIntrinsics::_putLongVolatile    : append_unsafe_put_obj(callee, T_LONG,    true); return;
   case vmIntrinsics::_putFloatVolatile   : append_unsafe_put_obj(callee, T_FLOAT,   true); return;
   case vmIntrinsics::_putDoubleVolatile  : append_unsafe_put_obj(callee, T_DOUBLE,  true); return;
-  case vmIntrinsics::_compareAndSwapLong:
-  case vmIntrinsics::_compareAndSwapInt:
-  case vmIntrinsics::_compareAndSwapObject: append_unsafe_CAS(callee); return;
+  case vmIntrinsics::_compareAndSetLong:
+  case vmIntrinsics::_compareAndSetInt:
+  case vmIntrinsics::_compareAndSetObject: append_unsafe_CAS(callee); return;
   case vmIntrinsics::_getAndAddInt:
   case vmIntrinsics::_getAndAddLong      : append_unsafe_get_and_set_obj(callee, true); return;
   case vmIntrinsics::_getAndSetInt       :
@@ -3995,10 +4009,14 @@ bool GraphBuilder::try_method_handle_inline(ciMethod* callee, bool ignore_return
         ciMethod* target = type->as_ObjectType()->constant_value()->as_method_handle()->get_vmtarget();
         // We don't do CHA here so only inline static and statically bindable methods.
         if (target->is_static() || target->can_be_statically_bound()) {
-          Bytecodes::Code bc = target->is_static() ? Bytecodes::_invokestatic : Bytecodes::_invokevirtual;
-          ignore_return = ignore_return || (callee->return_type()->is_void() && !target->return_type()->is_void());
-          if (try_inline(target, /*holder_known*/ true, ignore_return, bc)) {
-            return true;
+          if (ciMethod::is_consistent_info(callee, target)) {
+            Bytecodes::Code bc = target->is_static() ? Bytecodes::_invokestatic : Bytecodes::_invokevirtual;
+            ignore_return = ignore_return || (callee->return_type()->is_void() && !target->return_type()->is_void());
+            if (try_inline(target, /*holder_known*/ true, ignore_return, bc)) {
+              return true;
+            }
+          } else {
+            print_inlining(target, "signatures mismatch", /*success*/ false);
           }
         } else {
           print_inlining(target, "not static or statically bindable", /*success*/ false);
@@ -4026,6 +4044,8 @@ bool GraphBuilder::try_method_handle_inline(ciMethod* callee, bool ignore_return
           if (try_method_handle_inline(target, ignore_return)) {
             return true;
           }
+        } else if (!ciMethod::is_consistent_info(callee, target)) {
+          print_inlining(target, "signatures mismatch", /*success*/ false);
         } else {
           ciSignature* signature = target->signature();
           const int receiver_skip = target->is_static() ? 0 : 1;
@@ -4343,7 +4363,7 @@ void GraphBuilder::profile_return_type(Value ret, ciMethod* callee, ciMethod* m,
   }
   ciMethodData* md = m->method_data_or_null();
   ciProfileData* data = md->bci_to_data(invoke_bci);
-  if (data->is_CallTypeData() || data->is_VirtualCallTypeData()) {
+  if (data != NULL && (data->is_CallTypeData() || data->is_VirtualCallTypeData())) {
     append(new ProfileReturnType(m , invoke_bci, callee, ret));
   }
 }
diff --git a/hotspot/src/share/vm/c1/c1_Instruction.hpp b/hotspot/src/share/vm/c1/c1_Instruction.hpp
index 4b01069498c..c71b5619147 100644
--- a/hotspot/src/share/vm/c1/c1_Instruction.hpp
+++ b/hotspot/src/share/vm/c1/c1_Instruction.hpp
@@ -372,6 +372,7 @@ class Instruction: public CompilationResourceObj {
     UnorderedIsTrueFlag,
     NeedsPatchingFlag,
     ThrowIncompatibleClassChangeErrorFlag,
+    InvokeSpecialReceiverCheckFlag,
     ProfileMDOFlag,
     IsLinkedInBlockFlag,
     NeedsRangeCheckFlag,
@@ -1454,6 +1455,16 @@ LEAF(CheckCast, TypeCheck)
   bool is_incompatible_class_change_check() const {
     return check_flag(ThrowIncompatibleClassChangeErrorFlag);
   }
+  void set_invokespecial_receiver_check() {
+    set_flag(InvokeSpecialReceiverCheckFlag, true);
+  }
+  bool is_invokespecial_receiver_check() const {
+    return check_flag(InvokeSpecialReceiverCheckFlag);
+  }
+
+  virtual bool needs_exception_state() const {
+    return !is_invokespecial_receiver_check();
+  }
 
   ciType* declared_type() const;
 };
diff --git a/hotspot/src/share/vm/c1/c1_LIR.cpp b/hotspot/src/share/vm/c1/c1_LIR.cpp
index 05f39476849..e6cdb5e7c03 100644
--- a/hotspot/src/share/vm/c1/c1_LIR.cpp
+++ b/hotspot/src/share/vm/c1/c1_LIR.cpp
@@ -1413,6 +1413,17 @@ void LIR_List::store_check(LIR_Opr object, LIR_Opr array, LIR_Opr tmp1, LIR_Opr
   append(c);
 }
 
+void LIR_List::null_check(LIR_Opr opr, CodeEmitInfo* info, bool deoptimize_on_null) {
+  if (deoptimize_on_null) {
+    // Emit an explicit null check and deoptimize if opr is null
+    CodeStub* deopt = new DeoptimizeStub(info, Deoptimization::Reason_null_check, Deoptimization::Action_none);
+    cmp(lir_cond_equal, opr, LIR_OprFact::oopConst(NULL));
+    branch(lir_cond_equal, T_OBJECT, deopt);
+  } else {
+    // Emit an implicit null check
+    append(new LIR_Op1(lir_null_check, opr, info));
+  }
+}
 
 void LIR_List::cas_long(LIR_Opr addr, LIR_Opr cmp_value, LIR_Opr new_value,
                         LIR_Opr t1, LIR_Opr t2, LIR_Opr result) {
diff --git a/hotspot/src/share/vm/c1/c1_LIR.hpp b/hotspot/src/share/vm/c1/c1_LIR.hpp
index 79d298d4cdf..a9c073d32b0 100644
--- a/hotspot/src/share/vm/c1/c1_LIR.hpp
+++ b/hotspot/src/share/vm/c1/c1_LIR.hpp
@@ -613,7 +613,7 @@ class LIR_OprFact: public AllStatic {
   // Platform dependant.
   static LIR_Opr double_fpu(int reg1, int reg2 = -1 /*fnoreg*/);
 
-#ifdef __SOFTFP__
+#ifdef ARM32
   static LIR_Opr single_softfp(int reg) {
     return (LIR_Opr)(intptr_t)((reg  << LIR_OprDesc::reg1_shift) |
                                LIR_OprDesc::float_type           |
@@ -627,7 +627,7 @@ class LIR_OprFact: public AllStatic {
                                LIR_OprDesc::cpu_register         |
                                LIR_OprDesc::double_size);
   }
-#endif // __SOFTFP__
+#endif // ARM32
 
 #if defined(X86)
   static LIR_Opr single_xmm(int reg) {
@@ -2113,7 +2113,7 @@ class LIR_List: public CompilationResourceObj {
   void   pack64(LIR_Opr src, LIR_Opr dst) { append(new LIR_Op1(lir_pack64,   src, dst, T_LONG, lir_patch_none, NULL)); }
   void unpack64(LIR_Opr src, LIR_Opr dst) { append(new LIR_Op1(lir_unpack64, src, dst, T_LONG, lir_patch_none, NULL)); }
 
-  void null_check(LIR_Opr opr, CodeEmitInfo* info)         { append(new LIR_Op1(lir_null_check, opr, info)); }
+  void null_check(LIR_Opr opr, CodeEmitInfo* info, bool deoptimize_on_null = false);
   void throw_exception(LIR_Opr exceptionPC, LIR_Opr exceptionOop, CodeEmitInfo* info) {
     append(new LIR_Op2(lir_throw, exceptionPC, exceptionOop, LIR_OprFact::illegalOpr, info));
   }
diff --git a/hotspot/src/share/vm/c1/c1_LIRGenerator.cpp b/hotspot/src/share/vm/c1/c1_LIRGenerator.cpp
index 0c10e864e3f..68c959280d7 100644
--- a/hotspot/src/share/vm/c1/c1_LIRGenerator.cpp
+++ b/hotspot/src/share/vm/c1/c1_LIRGenerator.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -1752,8 +1752,10 @@ void LIRGenerator::do_StoreField(StoreField* x) {
   if (x->needs_null_check() &&
       (needs_patching ||
        MacroAssembler::needs_explicit_null_check(x->offset()))) {
-    // emit an explicit null check because the offset is too large
-    __ null_check(object.result(), new CodeEmitInfo(info));
+    // Emit an explicit null check because the offset is too large.
+    // If the class is not loaded and the object is NULL, we need to deoptimize to throw a
+    // NoClassDefFoundError in the interpreter instead of an implicit NPE from compiled code.
+    __ null_check(object.result(), new CodeEmitInfo(info), /* deoptimize */ needs_patching);
   }
 
   LIR_Address* address;
@@ -1838,8 +1840,10 @@ void LIRGenerator::do_LoadField(LoadField* x) {
       obj = new_register(T_OBJECT);
       __ move(LIR_OprFact::oopConst(NULL), obj);
     }
-    // emit an explicit null check because the offset is too large
-    __ null_check(obj, new CodeEmitInfo(info));
+    // Emit an explicit null check because the offset is too large.
+    // If the class is not loaded and the object is NULL, we need to deoptimize to throw a
+    // NoClassDefFoundError in the interpreter instead of an implicit NPE from compiled code.
+    __ null_check(obj, new CodeEmitInfo(info), /* deoptimize */ needs_patching);
   }
 
   LIR_Opr reg = rlock_result(x, field_type);
@@ -3208,13 +3212,13 @@ void LIRGenerator::do_Intrinsic(Intrinsic* x) {
   // java.nio.Buffer.checkIndex
   case vmIntrinsics::_checkIndex:     do_NIOCheckIndex(x); break;
 
-  case vmIntrinsics::_compareAndSwapObject:
+  case vmIntrinsics::_compareAndSetObject:
     do_CompareAndSwap(x, objectType);
     break;
-  case vmIntrinsics::_compareAndSwapInt:
+  case vmIntrinsics::_compareAndSetInt:
     do_CompareAndSwap(x, intType);
     break;
-  case vmIntrinsics::_compareAndSwapLong:
+  case vmIntrinsics::_compareAndSetLong:
     do_CompareAndSwap(x, longType);
     break;
 
@@ -3258,50 +3262,52 @@ void LIRGenerator::profile_arguments(ProfileCall* x) {
     int bci = x->bci_of_invoke();
     ciMethodData* md = x->method()->method_data_or_null();
     ciProfileData* data = md->bci_to_data(bci);
-    if ((data->is_CallTypeData() && data->as_CallTypeData()->has_arguments()) ||
-        (data->is_VirtualCallTypeData() && data->as_VirtualCallTypeData()->has_arguments())) {
-      ByteSize extra = data->is_CallTypeData() ? CallTypeData::args_data_offset() : VirtualCallTypeData::args_data_offset();
-      int base_offset = md->byte_offset_of_slot(data, extra);
-      LIR_Opr mdp = LIR_OprFact::illegalOpr;
-      ciTypeStackSlotEntries* args = data->is_CallTypeData() ? ((ciCallTypeData*)data)->args() : ((ciVirtualCallTypeData*)data)->args();
+    if (data != NULL) {
+      if ((data->is_CallTypeData() && data->as_CallTypeData()->has_arguments()) ||
+          (data->is_VirtualCallTypeData() && data->as_VirtualCallTypeData()->has_arguments())) {
+        ByteSize extra = data->is_CallTypeData() ? CallTypeData::args_data_offset() : VirtualCallTypeData::args_data_offset();
+        int base_offset = md->byte_offset_of_slot(data, extra);
+        LIR_Opr mdp = LIR_OprFact::illegalOpr;
+        ciTypeStackSlotEntries* args = data->is_CallTypeData() ? ((ciCallTypeData*)data)->args() : ((ciVirtualCallTypeData*)data)->args();
 
-      Bytecodes::Code bc = x->method()->java_code_at_bci(bci);
-      int start = 0;
-      int stop = data->is_CallTypeData() ? ((ciCallTypeData*)data)->number_of_arguments() : ((ciVirtualCallTypeData*)data)->number_of_arguments();
-      if (x->callee()->is_loaded() && x->callee()->is_static() && Bytecodes::has_receiver(bc)) {
-        // first argument is not profiled at call (method handle invoke)
-        assert(x->method()->raw_code_at_bci(bci) == Bytecodes::_invokehandle, "invokehandle expected");
-        start = 1;
-      }
-      ciSignature* callee_signature = x->callee()->signature();
-      // method handle call to virtual method
-      bool has_receiver = x->callee()->is_loaded() && !x->callee()->is_static() && !Bytecodes::has_receiver(bc);
-      ciSignatureStream callee_signature_stream(callee_signature, has_receiver ? x->callee()->holder() : NULL);
-
-      bool ignored_will_link;
-      ciSignature* signature_at_call = NULL;
-      x->method()->get_method_at_bci(bci, ignored_will_link, &signature_at_call);
-      ciSignatureStream signature_at_call_stream(signature_at_call);
-
-      // if called through method handle invoke, some arguments may have been popped
-      for (int i = 0; i < stop && i+start < x->nb_profiled_args(); i++) {
-        int off = in_bytes(TypeEntriesAtCall::argument_type_offset(i)) - in_bytes(TypeEntriesAtCall::args_data_offset());
-        ciKlass* exact = profile_type(md, base_offset, off,
-                                      args->type(i), x->profiled_arg_at(i+start), mdp,
-                                      !x->arg_needs_null_check(i+start),
-                                      signature_at_call_stream.next_klass(), callee_signature_stream.next_klass());
-        if (exact != NULL) {
-          md->set_argument_type(bci, i, exact);
+        Bytecodes::Code bc = x->method()->java_code_at_bci(bci);
+        int start = 0;
+        int stop = data->is_CallTypeData() ? ((ciCallTypeData*)data)->number_of_arguments() : ((ciVirtualCallTypeData*)data)->number_of_arguments();
+        if (x->callee()->is_loaded() && x->callee()->is_static() && Bytecodes::has_receiver(bc)) {
+          // first argument is not profiled at call (method handle invoke)
+          assert(x->method()->raw_code_at_bci(bci) == Bytecodes::_invokehandle, "invokehandle expected");
+          start = 1;
         }
-      }
-    } else {
+        ciSignature* callee_signature = x->callee()->signature();
+        // method handle call to virtual method
+        bool has_receiver = x->callee()->is_loaded() && !x->callee()->is_static() && !Bytecodes::has_receiver(bc);
+        ciSignatureStream callee_signature_stream(callee_signature, has_receiver ? x->callee()->holder() : NULL);
+
+        bool ignored_will_link;
+        ciSignature* signature_at_call = NULL;
+        x->method()->get_method_at_bci(bci, ignored_will_link, &signature_at_call);
+        ciSignatureStream signature_at_call_stream(signature_at_call);
+
+        // if called through method handle invoke, some arguments may have been popped
+        for (int i = 0; i < stop && i+start < x->nb_profiled_args(); i++) {
+          int off = in_bytes(TypeEntriesAtCall::argument_type_offset(i)) - in_bytes(TypeEntriesAtCall::args_data_offset());
+          ciKlass* exact = profile_type(md, base_offset, off,
+              args->type(i), x->profiled_arg_at(i+start), mdp,
+              !x->arg_needs_null_check(i+start),
+              signature_at_call_stream.next_klass(), callee_signature_stream.next_klass());
+          if (exact != NULL) {
+            md->set_argument_type(bci, i, exact);
+          }
+        }
+      } else {
 #ifdef ASSERT
-      Bytecodes::Code code = x->method()->raw_code_at_bci(x->bci_of_invoke());
-      int n = x->nb_profiled_args();
-      assert(MethodData::profile_parameters() && (MethodData::profile_arguments_jsr292_only() ||
-                                                  (x->inlined() && ((code == Bytecodes::_invokedynamic && n <= 1) || (code == Bytecodes::_invokehandle && n <= 2)))),
-             "only at JSR292 bytecodes");
+        Bytecodes::Code code = x->method()->raw_code_at_bci(x->bci_of_invoke());
+        int n = x->nb_profiled_args();
+        assert(MethodData::profile_parameters() && (MethodData::profile_arguments_jsr292_only() ||
+            (x->inlined() && ((code == Bytecodes::_invokedynamic && n <= 1) || (code == Bytecodes::_invokehandle && n <= 2)))),
+            "only at JSR292 bytecodes");
 #endif
+      }
     }
   }
 }
@@ -3392,24 +3398,26 @@ void LIRGenerator::do_ProfileReturnType(ProfileReturnType* x) {
   int bci = x->bci_of_invoke();
   ciMethodData* md = x->method()->method_data_or_null();
   ciProfileData* data = md->bci_to_data(bci);
-  assert(data->is_CallTypeData() || data->is_VirtualCallTypeData(), "wrong profile data type");
-  ciReturnTypeEntry* ret = data->is_CallTypeData() ? ((ciCallTypeData*)data)->ret() : ((ciVirtualCallTypeData*)data)->ret();
-  LIR_Opr mdp = LIR_OprFact::illegalOpr;
+  if (data != NULL) {
+    assert(data->is_CallTypeData() || data->is_VirtualCallTypeData(), "wrong profile data type");
+    ciReturnTypeEntry* ret = data->is_CallTypeData() ? ((ciCallTypeData*)data)->ret() : ((ciVirtualCallTypeData*)data)->ret();
+    LIR_Opr mdp = LIR_OprFact::illegalOpr;
 
-  bool ignored_will_link;
-  ciSignature* signature_at_call = NULL;
-  x->method()->get_method_at_bci(bci, ignored_will_link, &signature_at_call);
+    bool ignored_will_link;
+    ciSignature* signature_at_call = NULL;
+    x->method()->get_method_at_bci(bci, ignored_will_link, &signature_at_call);
 
-  // The offset within the MDO of the entry to update may be too large
-  // to be used in load/store instructions on some platforms. So have
-  // profile_type() compute the address of the profile in a register.
-  ciKlass* exact = profile_type(md, md->byte_offset_of_slot(data, ret->type_offset()), 0,
-                                ret->type(), x->ret(), mdp,
-                                !x->needs_null_check(),
-                                signature_at_call->return_type()->as_klass(),
-                                x->callee()->signature()->return_type()->as_klass());
-  if (exact != NULL) {
-    md->set_return_type(bci, exact);
+    // The offset within the MDO of the entry to update may be too large
+    // to be used in load/store instructions on some platforms. So have
+    // profile_type() compute the address of the profile in a register.
+    ciKlass* exact = profile_type(md, md->byte_offset_of_slot(data, ret->type_offset()), 0,
+        ret->type(), x->ret(), mdp,
+        !x->needs_null_check(),
+        signature_at_call->return_type()->as_klass(),
+        x->callee()->signature()->return_type()->as_klass());
+    if (exact != NULL) {
+      md->set_return_type(bci, exact);
+    }
   }
 }
 
diff --git a/hotspot/src/share/vm/c1/c1_ValueMap.hpp b/hotspot/src/share/vm/c1/c1_ValueMap.hpp
index e2e1c1b15fe..5b1342ede66 100644
--- a/hotspot/src/share/vm/c1/c1_ValueMap.hpp
+++ b/hotspot/src/share/vm/c1/c1_ValueMap.hpp
@@ -157,6 +157,12 @@ class ValueNumberingVisitor: public InstructionVisitor {
   void do_UnsafePutRaw   (UnsafePutRaw*    x) { kill_memory(); }
   void do_UnsafePutObject(UnsafePutObject* x) { kill_memory(); }
   void do_UnsafeGetAndSetObject(UnsafeGetAndSetObject* x) { kill_memory(); }
+  void do_UnsafeGetRaw   (UnsafeGetRaw*    x) { /* nothing to do */ }
+  void do_UnsafeGetObject(UnsafeGetObject* x) {
+    if (x->is_volatile()) { // the JMM requires this
+      kill_memory();
+    }
+  }
   void do_Intrinsic      (Intrinsic*       x) { if (!x->preserves_state()) kill_memory(); }
 
   void do_Phi            (Phi*             x) { /* nothing to do */ }
@@ -197,8 +203,6 @@ class ValueNumberingVisitor: public InstructionVisitor {
   void do_OsrEntry       (OsrEntry*        x) { /* nothing to do */ }
   void do_ExceptionObject(ExceptionObject* x) { /* nothing to do */ }
   void do_RoundFP        (RoundFP*         x) { /* nothing to do */ }
-  void do_UnsafeGetRaw   (UnsafeGetRaw*    x) { /* nothing to do */ }
-  void do_UnsafeGetObject(UnsafeGetObject* x) { /* nothing to do */ }
   void do_ProfileCall    (ProfileCall*     x) { /* nothing to do */ }
   void do_ProfileReturnType (ProfileReturnType*  x) { /* nothing to do */ }
   void do_ProfileInvoke  (ProfileInvoke*   x) { /* nothing to do */ };
diff --git a/hotspot/src/share/vm/ci/ciEnv.cpp b/hotspot/src/share/vm/ci/ciEnv.cpp
index 024909b1cbc..c7801a12dc4 100644
--- a/hotspot/src/share/vm/ci/ciEnv.cpp
+++ b/hotspot/src/share/vm/ci/ciEnv.cpp
@@ -101,6 +101,7 @@ ciEnv::ciEnv(CompileTask* task, int system_dictionary_modification_counter)
   _debug_info = NULL;
   _dependencies = NULL;
   _failure_reason = NULL;
+  _inc_decompile_count_on_failure = true;
   _compilable = MethodCompilable;
   _break_at_compile = false;
   _compiler_data = NULL;
@@ -161,6 +162,7 @@ ciEnv::ciEnv(Arena* arena) : _ciEnv_arena(mtCompiler) {
   _debug_info = NULL;
   _dependencies = NULL;
   _failure_reason = NULL;
+  _inc_decompile_count_on_failure = true;
   _compilable = MethodCompilable_never;
   _break_at_compile = false;
   _compiler_data = NULL;
@@ -702,16 +704,17 @@ ciField* ciEnv::get_field_by_index(ciInstanceKlass* accessor,
 //
 // Perform an appropriate method lookup based on accessor, holder,
 // name, signature, and bytecode.
-Method* ciEnv::lookup_method(InstanceKlass*  accessor,
-                               InstanceKlass*  holder,
-                               Symbol*       name,
-                               Symbol*       sig,
-                               Bytecodes::Code bc,
-                               constantTag    tag) {
-  EXCEPTION_CONTEXT;
-  KlassHandle h_accessor(THREAD, accessor);
-  KlassHandle h_holder(THREAD, holder);
-  LinkResolver::check_klass_accessability(h_accessor, h_holder, KILL_COMPILE_ON_FATAL_(NULL));
+Method* ciEnv::lookup_method(ciInstanceKlass* accessor,
+                             ciKlass*         holder,
+                             Symbol*          name,
+                             Symbol*          sig,
+                             Bytecodes::Code  bc,
+                             constantTag      tag) {
+  // Accessibility checks are performed in ciEnv::get_method_by_index_impl.
+  assert(check_klass_accessibility(accessor, holder->get_Klass()), "holder not accessible");
+
+  KlassHandle h_accessor(accessor->get_instanceKlass());
+  KlassHandle h_holder(holder->get_Klass());
   methodHandle dest_method;
   LinkInfo link_info(h_holder, name, sig, h_accessor, LinkInfo::needs_access_check, tag);
   switch (bc) {
@@ -770,7 +773,6 @@ ciMethod* ciEnv::get_method_by_index_impl(const constantPoolHandle& cpool,
     const int holder_index = cpool->klass_ref_index_at(index);
     bool holder_is_accessible;
     ciKlass* holder = get_klass_by_index_impl(cpool, holder_index, holder_is_accessible, accessor);
-    ciInstanceKlass* declared_holder = get_instance_klass_for_declared_method_holder(holder);
 
     // Get the method's name and signature.
     Symbol* name_sym = cpool->name_ref_at(index);
@@ -798,10 +800,9 @@ ciMethod* ciEnv::get_method_by_index_impl(const constantPoolHandle& cpool,
     }
 
     if (holder_is_accessible) {  // Our declared holder is loaded.
-      InstanceKlass* lookup = declared_holder->get_instanceKlass();
       constantTag tag = cpool->tag_ref_at(index);
       assert(accessor->get_instanceKlass() == cpool->pool_holder(), "not the pool holder?");
-      Method* m = lookup_method(accessor->get_instanceKlass(), lookup, name_sym, sig_sym, bc, tag);
+      Method* m = lookup_method(accessor, holder, name_sym, sig_sym, bc, tag);
       if (m != NULL &&
           (bc == Bytecodes::_invokestatic
            ?  m->method_holder()->is_not_initialized()
@@ -824,7 +825,7 @@ ciMethod* ciEnv::get_method_by_index_impl(const constantPoolHandle& cpool,
     // lookup.
     ciSymbol* name      = get_symbol(name_sym);
     ciSymbol* signature = get_symbol(sig_sym);
-    return get_unloaded_method(declared_holder, name, signature, accessor);
+    return get_unloaded_method(holder, name, signature, accessor);
   }
 }
 
@@ -902,7 +903,12 @@ void ciEnv::validate_compile_task_dependencies(ciMethod* target) {
     if (deps.is_klass_type())  continue;  // skip klass dependencies
     Klass* witness = deps.check_dependency();
     if (witness != NULL) {
-      record_failure("invalid non-klass dependency");
+      if (deps.type() == Dependencies::call_site_target_value) {
+        _inc_decompile_count_on_failure = false;
+        record_failure("call site target change");
+      } else {
+        record_failure("invalid non-klass dependency");
+      }
       return;
     }
   }
@@ -1017,7 +1023,7 @@ void ciEnv::register_method(ciMethod* target,
     if (failing()) {
       // While not a true deoptimization, it is a preemptive decompile.
       MethodData* mdo = method()->method_data();
-      if (mdo != NULL) {
+      if (mdo != NULL && _inc_decompile_count_on_failure) {
         mdo->inc_decompile_count();
       }
 
diff --git a/hotspot/src/share/vm/ci/ciEnv.hpp b/hotspot/src/share/vm/ci/ciEnv.hpp
index e5a99e1a96a..a7fbe0bd843 100644
--- a/hotspot/src/share/vm/ci/ciEnv.hpp
+++ b/hotspot/src/share/vm/ci/ciEnv.hpp
@@ -55,6 +55,7 @@ private:
   DebugInformationRecorder* _debug_info;
   Dependencies*    _dependencies;
   const char*      _failure_reason;
+  bool             _inc_decompile_count_on_failure;
   int              _compilable;
   bool             _break_at_compile;
   int              _num_inlined_bytecodes;
@@ -152,12 +153,12 @@ private:
   // Helper methods
   bool       check_klass_accessibility(ciKlass* accessing_klass,
                                       Klass* resolved_klass);
-  Method*    lookup_method(InstanceKlass*  accessor,
-                           InstanceKlass*  holder,
-                           Symbol*         name,
-                           Symbol*         sig,
-                           Bytecodes::Code bc,
-                           constantTag     tag);
+  Method*    lookup_method(ciInstanceKlass* accessor,
+                           ciKlass*         holder,
+                           Symbol*          name,
+                           Symbol*          sig,
+                           Bytecodes::Code  bc,
+                           constantTag      tag);
 
   // Get a ciObject from the object factory.  Ensures uniqueness
   // of ciObjects.
@@ -226,11 +227,12 @@ private:
   // Get a ciMethod representing either an unfound method or
   // a method with an unloaded holder.  Ensures uniqueness of
   // the result.
-  ciMethod* get_unloaded_method(ciInstanceKlass* holder,
+  ciMethod* get_unloaded_method(ciKlass*         holder,
                                 ciSymbol*        name,
                                 ciSymbol*        signature,
                                 ciInstanceKlass* accessor) {
-    return _factory->get_unloaded_method(holder, name, signature, accessor);
+    ciInstanceKlass* declared_holder = get_instance_klass_for_declared_method_holder(holder);
+    return _factory->get_unloaded_method(declared_holder, name, signature, accessor);
   }
 
   // Get a ciKlass representing an unloaded klass.
diff --git a/hotspot/src/share/vm/ci/ciInstanceKlass.cpp b/hotspot/src/share/vm/ci/ciInstanceKlass.cpp
index b8133ab754e..9715b2987a1 100644
--- a/hotspot/src/share/vm/ci/ciInstanceKlass.cpp
+++ b/hotspot/src/share/vm/ci/ciInstanceKlass.cpp
@@ -595,6 +595,16 @@ ciInstanceKlass* ciInstanceKlass::implementor() {
   return impl;
 }
 
+ciInstanceKlass* ciInstanceKlass::host_klass() {
+  assert(is_loaded(), "must be loaded");
+  if (is_anonymous()) {
+    VM_ENTRY_MARK
+    Klass* host_klass = get_instanceKlass()->host_klass();
+    return CURRENT_ENV->get_instance_klass(host_klass);
+  }
+  return NULL;
+}
+
 // Utility class for printing of the contents of the static fields for
 // use by compilation replay.  It only prints out the information that
 // could be consumed by the compiler, so for primitive types it prints
diff --git a/hotspot/src/share/vm/ci/ciInstanceKlass.hpp b/hotspot/src/share/vm/ci/ciInstanceKlass.hpp
index 1215c089ff4..02bf4b4641b 100644
--- a/hotspot/src/share/vm/ci/ciInstanceKlass.hpp
+++ b/hotspot/src/share/vm/ci/ciInstanceKlass.hpp
@@ -260,6 +260,8 @@ public:
     return NULL;
   }
 
+  ciInstanceKlass* host_klass();
+
   bool can_be_instantiated() {
     assert(is_loaded(), "must be loaded");
     return !is_interface() && !is_abstract();
diff --git a/hotspot/src/share/vm/ci/ciMethod.cpp b/hotspot/src/share/vm/ci/ciMethod.cpp
index 4860427786f..4590061166b 100644
--- a/hotspot/src/share/vm/ci/ciMethod.cpp
+++ b/hotspot/src/share/vm/ci/ciMethod.cpp
@@ -951,6 +951,13 @@ bool ciMethod::is_compiled_lambda_form() const {
   return iid == vmIntrinsics::_compiledLambdaForm;
 }
 
+// ------------------------------------------------------------------
+// ciMethod::is_object_initializer
+//
+bool ciMethod::is_object_initializer() const {
+   return name() == ciSymbol::object_initializer_name();
+}
+
 // ------------------------------------------------------------------
 // ciMethod::has_member_arg
 //
@@ -1409,6 +1416,97 @@ void ciMethod::print_impl(outputStream* st) {
   }
 }
 
+// ------------------------------------------------------------------
+
+static BasicType erase_to_word_type(BasicType bt) {
+  if (is_subword_type(bt)) return T_INT;
+  if (bt == T_ARRAY)       return T_OBJECT;
+  return bt;
+}
+
+static bool basic_types_match(ciType* t1, ciType* t2) {
+  if (t1 == t2)  return true;
+  return erase_to_word_type(t1->basic_type()) == erase_to_word_type(t2->basic_type());
+}
+
+bool ciMethod::is_consistent_info(ciMethod* declared_method, ciMethod* resolved_method) {
+  bool invoke_through_mh_intrinsic = declared_method->is_method_handle_intrinsic() &&
+                                  !resolved_method->is_method_handle_intrinsic();
+
+  if (!invoke_through_mh_intrinsic) {
+    // Method name & descriptor should stay the same.
+    // Signatures may reference unloaded types and thus they may be not strictly equal.
+    ciSymbol* declared_signature = declared_method->signature()->as_symbol();
+    ciSymbol* resolved_signature = resolved_method->signature()->as_symbol();
+
+    return (declared_method->name()->equals(resolved_method->name())) &&
+           (declared_signature->equals(resolved_signature));
+  }
+
+  ciMethod* linker = declared_method;
+  ciMethod* target = resolved_method;
+  // Linkers have appendix argument which is not passed to callee.
+  int has_appendix = MethodHandles::has_member_arg(linker->intrinsic_id()) ? 1 : 0;
+  if (linker->arg_size() != (target->arg_size() + has_appendix)) {
+    return false; // argument slot count mismatch
+  }
+
+  ciSignature* linker_sig = linker->signature();
+  ciSignature* target_sig = target->signature();
+
+  if (linker_sig->count() + (linker->is_static() ? 0 : 1) !=
+      target_sig->count() + (target->is_static() ? 0 : 1) + has_appendix) {
+    return false; // argument count mismatch
+  }
+
+  int sbase = 0, rbase = 0;
+  switch (linker->intrinsic_id()) {
+    case vmIntrinsics::_linkToVirtual:
+    case vmIntrinsics::_linkToInterface:
+    case vmIntrinsics::_linkToSpecial: {
+      if (target->is_static()) {
+        return false;
+      }
+      if (linker_sig->type_at(0)->is_primitive_type()) {
+        return false;  // receiver should be an oop
+      }
+      sbase = 1; // skip receiver
+      break;
+    }
+    case vmIntrinsics::_linkToStatic: {
+      if (!target->is_static()) {
+        return false;
+      }
+      break;
+    }
+    case vmIntrinsics::_invokeBasic: {
+      if (target->is_static()) {
+        if (target_sig->type_at(0)->is_primitive_type()) {
+          return false; // receiver should be an oop
+        }
+        rbase = 1; // skip receiver
+      }
+      break;
+    }
+  }
+  assert(target_sig->count() - rbase == linker_sig->count() - sbase - has_appendix, "argument count mismatch");
+  int arg_count = target_sig->count() - rbase;
+  for (int i = 0; i < arg_count; i++) {
+    if (!basic_types_match(linker_sig->type_at(sbase + i), target_sig->type_at(rbase + i))) {
+      return false;
+    }
+  }
+  // Only check the return type if the symbolic info has non-void return type.
+  // I.e. the return value of the resolved method can be dropped.
+  if (!linker->return_type()->is_void() &&
+      !basic_types_match(linker->return_type(), target->return_type())) {
+    return false;
+  }
+  return true; // no mismatch found
+}
+
+// ------------------------------------------------------------------
+
 #if INCLUDE_TRACE
 TraceStructCalleeMethod ciMethod::to_trace_struct() const {
   TraceStructCalleeMethod result;
diff --git a/hotspot/src/share/vm/ci/ciMethod.hpp b/hotspot/src/share/vm/ci/ciMethod.hpp
index f16948e71d7..2b81e682544 100644
--- a/hotspot/src/share/vm/ci/ciMethod.hpp
+++ b/hotspot/src/share/vm/ci/ciMethod.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2016, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -337,6 +337,7 @@ class ciMethod : public ciMetadata {
   bool has_reserved_stack_access() const         { return _has_reserved_stack_access; }
   bool is_boxing_method() const;
   bool is_unboxing_method() const;
+  bool is_object_initializer() const;
 
   // Replay data methods
   void dump_name_as_ascii(outputStream* st);
@@ -353,6 +354,8 @@ class ciMethod : public ciMetadata {
   void print_name(outputStream* st = tty);
   void print_short_name(outputStream* st = tty);
 
+  static bool is_consistent_info(ciMethod* declared_method, ciMethod* resolved_method);
+
 #if INCLUDE_TRACE
   TraceStructCalleeMethod to_trace_struct() const;
 #endif
diff --git a/hotspot/src/share/vm/ci/ciMethodData.cpp b/hotspot/src/share/vm/ci/ciMethodData.cpp
index 0ede3dfc31e..1e773c93062 100644
--- a/hotspot/src/share/vm/ci/ciMethodData.cpp
+++ b/hotspot/src/share/vm/ci/ciMethodData.cpp
@@ -408,11 +408,13 @@ void ciMethodData::set_argument_type(int bci, int i, ciKlass* k) {
   MethodData* mdo = get_MethodData();
   if (mdo != NULL) {
     ProfileData* data = mdo->bci_to_data(bci);
-    if (data->is_CallTypeData()) {
-      data->as_CallTypeData()->set_argument_type(i, k->get_Klass());
-    } else {
-      assert(data->is_VirtualCallTypeData(), "no arguments!");
-      data->as_VirtualCallTypeData()->set_argument_type(i, k->get_Klass());
+    if (data != NULL) {
+      if (data->is_CallTypeData()) {
+        data->as_CallTypeData()->set_argument_type(i, k->get_Klass());
+      } else {
+        assert(data->is_VirtualCallTypeData(), "no arguments!");
+        data->as_VirtualCallTypeData()->set_argument_type(i, k->get_Klass());
+      }
     }
   }
 }
@@ -430,11 +432,13 @@ void ciMethodData::set_return_type(int bci, ciKlass* k) {
   MethodData* mdo = get_MethodData();
   if (mdo != NULL) {
     ProfileData* data = mdo->bci_to_data(bci);
-    if (data->is_CallTypeData()) {
-      data->as_CallTypeData()->set_return_type(k->get_Klass());
-    } else {
-      assert(data->is_VirtualCallTypeData(), "no arguments!");
-      data->as_VirtualCallTypeData()->set_return_type(k->get_Klass());
+    if (data != NULL) {
+      if (data->is_CallTypeData()) {
+        data->as_CallTypeData()->set_return_type(k->get_Klass());
+      } else {
+        assert(data->is_VirtualCallTypeData(), "no arguments!");
+        data->as_VirtualCallTypeData()->set_return_type(k->get_Klass());
+      }
     }
   }
 }
diff --git a/hotspot/src/share/vm/classfile/classFileParser.cpp b/hotspot/src/share/vm/classfile/classFileParser.cpp
index 96ffac10af0..db813adf834 100644
--- a/hotspot/src/share/vm/classfile/classFileParser.cpp
+++ b/hotspot/src/share/vm/classfile/classFileParser.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -105,6 +105,12 @@
 
 #define JAVA_9_VERSION                    53
 
+void ClassFileParser::set_class_bad_constant_seen(short bad_constant) {
+  assert((bad_constant == 19 || bad_constant == 20) && _major_version >= JAVA_9_VERSION,
+         "Unexpected bad constant pool entry");
+  if (_bad_constant_seen == 0) _bad_constant_seen = bad_constant;
+}
+
 void ClassFileParser::parse_constant_pool_entries(const ClassFileStream* const stream,
                                                   ConstantPool* cp,
                                                   const int length,
@@ -302,6 +308,18 @@ void ClassFileParser::parse_constant_pool_entries(const ClassFileStream* const s
         }
         break;
       }
+      case 19:
+      case 20: {
+        // Record that an error occurred in these two cases but keep parsing so
+        // that ACC_Module can be checked for in the access_flags.  Need to
+        // throw NoClassDefFoundError in that case.
+        if (_major_version >= JAVA_9_VERSION) {
+          cfs->guarantee_more(3, CHECK);
+          cfs->get_u2_fast();
+          set_class_bad_constant_seen(tag);
+          break;
+        }
+      }
       default: {
         classfile_parse_error("Unknown constant tag %u in class file %s",
                               tag,
@@ -359,14 +377,18 @@ PRAGMA_DIAG_POP
 #endif
 
 void ClassFileParser::parse_constant_pool(const ClassFileStream* const stream,
-                                          ConstantPool* const cp,
-                                          const int length,
-                                          TRAPS) {
+                                         ConstantPool* const cp,
+                                         const int length,
+                                         TRAPS) {
   assert(cp != NULL, "invariant");
   assert(stream != NULL, "invariant");
 
   // parsing constant pool entries
   parse_constant_pool_entries(stream, cp, length, CHECK);
+  if (class_bad_constant_seen() != 0) {
+    // a bad CP entry has been detected previously so stop parsing and just return.
+    return;
+  }
 
   int index = 1;  // declared outside of loops for portability
 
@@ -1244,6 +1266,10 @@ void ClassFileParser::parse_field_attributes(const ClassFileStream* const cfs,
       }
     } else if (_major_version >= JAVA_1_5_VERSION) {
       if (attribute_name == vmSymbols::tag_signature()) {
+        if (generic_signature_index != 0) {
+          classfile_parse_error(
+            "Multiple Signature attributes for field in class file %s", CHECK);
+        }
         if (attribute_length != 2) {
           classfile_parse_error(
             "Wrong size %u for field's Signature attribute in class file %s",
@@ -2565,6 +2591,11 @@ Method* ClassFileParser::parse_method(const ClassFileStream* const cfs,
       }
     } else if (_major_version >= JAVA_1_5_VERSION) {
       if (method_attribute_name == vmSymbols::tag_signature()) {
+        if (generic_signature_index != 0) {
+          classfile_parse_error(
+            "Multiple Signature attributes for method in class file %s",
+            CHECK_NULL);
+        }
         if (method_attribute_length != 2) {
           classfile_parse_error(
             "Invalid Signature attribute length %u in class file %s",
@@ -3052,7 +3083,13 @@ u2 ClassFileParser::parse_classfile_inner_classes_attribute(const ClassFileStrea
                          "Class is both outer and inner class in class file %s", CHECK_0);
     }
     // Access flags
-    jint flags = cfs->get_u2_fast() & RECOGNIZED_INNER_CLASS_MODIFIERS;
+    jint flags;
+    // JVM_ACC_MODULE is defined in JDK-9 and later.
+    if (_major_version >= JAVA_9_VERSION) {
+      flags = cfs->get_u2_fast() & (RECOGNIZED_INNER_CLASS_MODIFIERS | JVM_ACC_MODULE);
+    } else {
+      flags = cfs->get_u2_fast() & RECOGNIZED_INNER_CLASS_MODIFIERS;
+    }
     if ((flags & JVM_ACC_INTERFACE) && _major_version < JAVA_6_VERSION) {
       // Set abstract bit for old class files for backward compatibility
       flags |= JVM_ACC_ABSTRACT;
@@ -3278,6 +3315,10 @@ void ClassFileParser::parse_classfile_attributes(const ClassFileStream* const cf
       }
     } else if (_major_version >= JAVA_1_5_VERSION) {
       if (tag == vmSymbols::tag_signature()) {
+        if (_generic_signature_index != 0) {
+          classfile_parse_error(
+            "Multiple Signature attributes in class file %s", CHECK);
+        }
         if (attribute_length != 2) {
           classfile_parse_error(
             "Wrong Signature attribute length %u in class file %s",
@@ -4524,6 +4565,18 @@ static void check_illegal_static_method(const InstanceKlass* this_klass, TRAPS)
 // utility methods for format checking
 
 void ClassFileParser::verify_legal_class_modifiers(jint flags, TRAPS) const {
+  const bool is_module = (flags & JVM_ACC_MODULE) != 0;
+  assert(_major_version >= JAVA_9_VERSION || !is_module, "JVM_ACC_MODULE should not be set");
+  if (is_module) {
+    ResourceMark rm(THREAD);
+    Exceptions::fthrow(
+      THREAD_AND_LOCATION,
+      vmSymbols::java_lang_NoClassDefFoundError(),
+      "%s is not a class because access_flag ACC_MODULE is set",
+      _class_name->as_C_string());
+    return;
+  }
+
   if (!_need_verify) { return; }
 
   const bool is_interface  = (flags & JVM_ACC_INTERFACE)  != 0;
@@ -4532,14 +4585,12 @@ void ClassFileParser::verify_legal_class_modifiers(jint flags, TRAPS) const {
   const bool is_super      = (flags & JVM_ACC_SUPER)      != 0;
   const bool is_enum       = (flags & JVM_ACC_ENUM)       != 0;
   const bool is_annotation = (flags & JVM_ACC_ANNOTATION) != 0;
-  const bool is_module_info= (flags & JVM_ACC_MODULE)     != 0;
   const bool major_gte_15  = _major_version >= JAVA_1_5_VERSION;
 
   if ((is_abstract && is_final) ||
       (is_interface && !is_abstract) ||
       (is_interface && major_gte_15 && (is_super || is_enum)) ||
-      (!is_interface && major_gte_15 && is_annotation) ||
-      is_module_info) {
+      (!is_interface && major_gte_15 && is_annotation)) {
     ResourceMark rm(THREAD);
     Exceptions::fthrow(
       THREAD_AND_LOCATION,
@@ -5355,7 +5406,7 @@ void ClassFileParser::fill_instance_klass(InstanceKlass* ik, bool changed_by_loa
   ModuleEntry* module_entry = ik->module();
   assert(module_entry != NULL, "module_entry should always be set");
 
-  // Obtain java.lang.reflect.Module
+  // Obtain java.lang.Module
   Handle module_handle(THREAD, JNIHandles::resolve(module_entry->module()));
 
   // Allocate mirror and initialize static fields
@@ -5542,6 +5593,7 @@ ClassFileParser::ClassFileParser(ClassFileStream* stream,
   _protection_domain(protection_domain),
   _access_flags(),
   _pub_level(pub_level),
+  _bad_constant_seen(0),
   _synthetic_flag(false),
   _sde_length(false),
   _sde_buffer(NULL),
@@ -5734,16 +5786,29 @@ void ClassFileParser::parse_stream(const ClassFileStream* const stream,
   stream->guarantee_more(8, CHECK);  // flags, this_class, super_class, infs_len
 
   // Access flags
-  jint flags = stream->get_u2_fast() & JVM_RECOGNIZED_CLASS_MODIFIERS;
+  jint flags;
+  // JVM_ACC_MODULE is defined in JDK-9 and later.
+  if (_major_version >= JAVA_9_VERSION) {
+    flags = stream->get_u2_fast() & (JVM_RECOGNIZED_CLASS_MODIFIERS | JVM_ACC_MODULE);
+  } else {
+    flags = stream->get_u2_fast() & JVM_RECOGNIZED_CLASS_MODIFIERS;
+  }
 
   if ((flags & JVM_ACC_INTERFACE) && _major_version < JAVA_6_VERSION) {
     // Set abstract bit for old class files for backward compatibility
     flags |= JVM_ACC_ABSTRACT;
   }
 
-  _access_flags.set_flags(flags);
+  verify_legal_class_modifiers(flags, CHECK);
 
-  verify_legal_class_modifiers((jint)_access_flags.as_int(), CHECK);
+  short bad_constant = class_bad_constant_seen();
+  if (bad_constant != 0) {
+    // Do not throw CFE until after the access_flags are checked because if
+    // ACC_MODULE is set in the access flags, then NCDFE must be thrown, not CFE.
+    classfile_parse_error("Unknown constant tag %u in class file %s", bad_constant, CHECK);
+  }
+
+  _access_flags.set_flags(flags);
 
   // This class and superclass
   _this_class_index = stream->get_u2_fast();
diff --git a/hotspot/src/share/vm/classfile/classFileParser.hpp b/hotspot/src/share/vm/classfile/classFileParser.hpp
index df9ff6848ab..031a7142375 100644
--- a/hotspot/src/share/vm/classfile/classFileParser.hpp
+++ b/hotspot/src/share/vm/classfile/classFileParser.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -122,6 +122,15 @@ class ClassFileParser VALUE_OBJ_CLASS_SPEC {
   // for tracing and notifications
   Publicity _pub_level;
 
+  // Used to keep track of whether a constant pool item 19 or 20 is found.  These
+  // correspond to CONSTANT_Module and CONSTANT_Package tags and are not allowed
+  // in regular class files.  For class file version >= 53, a CFE cannot be thrown
+  // immediately when these are seen because a NCDFE must be thrown if the class's
+  // access_flags have ACC_MODULE set.  But, the access_flags haven't been looked
+  // at yet.  So, the bad constant pool item is cached here.  A value of zero
+  // means that no constant pool item 19 or 20 was found.
+  short _bad_constant_seen;
+
   // class attributes parsed before the instance klass is created:
   bool _synthetic_flag;
   int _sde_length;
@@ -161,6 +170,8 @@ class ClassFileParser VALUE_OBJ_CLASS_SPEC {
   void fill_instance_klass(InstanceKlass* ik, bool cf_changed_in_CFLH, TRAPS);
   void set_klass(InstanceKlass* instance);
 
+  void set_class_bad_constant_seen(short bad_constant);
+  short class_bad_constant_seen() { return  _bad_constant_seen; }
   void set_class_synthetic_flag(bool x)        { _synthetic_flag = x; }
   void set_class_sourcefile_index(u2 x)        { _sourcefile_index = x; }
   void set_class_generic_signature_index(u2 x) { _generic_signature_index = x; }
diff --git a/hotspot/src/share/vm/classfile/classLoaderData.cpp b/hotspot/src/share/vm/classfile/classLoaderData.cpp
index d1e37d82761..c7b26613d07 100644
--- a/hotspot/src/share/vm/classfile/classLoaderData.cpp
+++ b/hotspot/src/share/vm/classfile/classLoaderData.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -93,7 +93,7 @@ ClassLoaderData::ClassLoaderData(Handle h_class_loader, bool is_anonymous, Depen
   _keep_alive((is_anonymous || h_class_loader.is_null()) ? 1 : 0),
   _metaspace(NULL), _unloading(false), _klasses(NULL),
   _modules(NULL), _packages(NULL),
-  _claimed(0), _jmethod_ids(NULL), _handles(NULL), _deallocate_list(NULL),
+  _claimed(0), _jmethod_ids(NULL), _handles(), _deallocate_list(NULL),
   _next(NULL), _dependencies(dependencies),
   _metaspace_lock(new Mutex(Monitor::leaf+1, "Metaspace allocation lock", true,
                             Monitor::_safepoint_check_never)) {
@@ -112,6 +112,76 @@ void ClassLoaderData::Dependencies::init(TRAPS) {
   _list_head = oopFactory::new_objectArray(2, CHECK);
 }
 
+ClassLoaderData::ChunkedHandleList::~ChunkedHandleList() {
+  Chunk* c = _head;
+  while (c != NULL) {
+    Chunk* next = c->_next;
+    delete c;
+    c = next;
+  }
+}
+
+oop* ClassLoaderData::ChunkedHandleList::add(oop o) {
+  if (_head == NULL || _head->_size == Chunk::CAPACITY) {
+    Chunk* next = new Chunk(_head);
+    OrderAccess::release_store_ptr(&_head, next);
+  }
+  oop* handle = &_head->_data[_head->_size];
+  *handle = o;
+  OrderAccess::release_store(&_head->_size, _head->_size + 1);
+  return handle;
+}
+
+inline void ClassLoaderData::ChunkedHandleList::oops_do_chunk(OopClosure* f, Chunk* c, const juint size) {
+  for (juint i = 0; i < size; i++) {
+    if (c->_data[i] != NULL) {
+      f->do_oop(&c->_data[i]);
+    }
+  }
+}
+
+void ClassLoaderData::ChunkedHandleList::oops_do(OopClosure* f) {
+  Chunk* head = (Chunk*) OrderAccess::load_ptr_acquire(&_head);
+  if (head != NULL) {
+    // Must be careful when reading size of head
+    oops_do_chunk(f, head, OrderAccess::load_acquire(&head->_size));
+    for (Chunk* c = head->_next; c != NULL; c = c->_next) {
+      oops_do_chunk(f, c, c->_size);
+    }
+  }
+}
+
+#ifdef ASSERT
+class VerifyContainsOopClosure : public OopClosure {
+  oop* _target;
+  bool _found;
+
+ public:
+  VerifyContainsOopClosure(oop* target) : _target(target), _found(false) {}
+
+  void do_oop(oop* p) {
+    if (p == _target) {
+      _found = true;
+    }
+  }
+
+  void do_oop(narrowOop* p) {
+    // The ChunkedHandleList should not contain any narrowOop
+    ShouldNotReachHere();
+  }
+
+  bool found() const {
+    return _found;
+  }
+};
+
+bool ClassLoaderData::ChunkedHandleList::contains(oop* p) {
+  VerifyContainsOopClosure cl(p);
+  oops_do(&cl);
+  return cl.found();
+}
+#endif
+
 bool ClassLoaderData::claim() {
   if (_claimed == 1) {
     return false;
@@ -146,9 +216,9 @@ void ClassLoaderData::oops_do(OopClosure* f, KlassClosure* klass_closure, bool m
 
   f->do_oop(&_class_loader);
   _dependencies.oops_do(f);
-  if (_handles != NULL) {
-    _handles->oops_do(f);
-  }
+
+  _handles.oops_do(f);
+
   if (klass_closure != NULL) {
     classes_do(klass_closure);
   }
@@ -484,12 +554,6 @@ ClassLoaderData::~ClassLoaderData() {
     _metaspace = NULL;
     delete m;
   }
-  // release the handles
-  if (_handles != NULL) {
-    JNIHandleBlock::release_block(_handles);
-    _handles = NULL;
-  }
-
   // Clear all the JNI handles for methods
   // These aren't deallocated and are going to look like a leak, but that's
   // needed because we can't really get rid of jmethodIDs because we don't
@@ -563,19 +627,14 @@ Metaspace* ClassLoaderData::metaspace_non_null() {
   return metaspace;
 }
 
-JNIHandleBlock* ClassLoaderData::handles() const           { return _handles; }
-void ClassLoaderData::set_handles(JNIHandleBlock* handles) { _handles = handles; }
-
 jobject ClassLoaderData::add_handle(Handle h) {
   MutexLockerEx ml(metaspace_lock(),  Mutex::_no_safepoint_check_flag);
-  if (handles() == NULL) {
-    set_handles(JNIHandleBlock::allocate_block());
-  }
-  return handles()->allocate_handle(h());
+  return (jobject) _handles.add(h());
 }
 
-void ClassLoaderData::remove_handle(jobject h) {
-  _handles->release_handle(h);
+void ClassLoaderData::remove_handle_unsafe(jobject h) {
+  assert(_handles.contains((oop*) h), "Got unexpected handle " PTR_FORMAT, p2i((oop*) h));
+  *((oop*) h) = NULL;
 }
 
 // Add this metadata pointer to be freed when it's safe.  This is only during
@@ -645,7 +704,6 @@ void ClassLoaderData::dump(outputStream * const out) {
       p2i(class_loader() != NULL ? class_loader()->klass() : NULL), loader_name());
   if (claimed()) out->print(" claimed ");
   if (is_unloading()) out->print(" unloading ");
-  out->print(" handles " INTPTR_FORMAT, p2i(handles()));
   out->cr();
   if (metaspace_or_null() != NULL) {
     out->print_cr("metaspace: " INTPTR_FORMAT, p2i(metaspace_or_null()));
diff --git a/hotspot/src/share/vm/classfile/classLoaderData.hpp b/hotspot/src/share/vm/classfile/classLoaderData.hpp
index 8c8df5187a7..3c0aba64992 100644
--- a/hotspot/src/share/vm/classfile/classLoaderData.hpp
+++ b/hotspot/src/share/vm/classfile/classLoaderData.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -52,7 +52,6 @@
 
 class ClassLoaderData;
 class JNIMethodBlock;
-class JNIHandleBlock;
 class Metadebug;
 class ModuleEntry;
 class PackageEntry;
@@ -160,6 +159,34 @@ class ClassLoaderData : public CHeapObj {
     void oops_do(OopClosure* f);
   };
 
+  class ChunkedHandleList VALUE_OBJ_CLASS_SPEC {
+    struct Chunk : public CHeapObj {
+      static const size_t CAPACITY = 32;
+
+      oop _data[CAPACITY];
+      volatile juint _size;
+      Chunk* _next;
+
+      Chunk(Chunk* c) : _next(c), _size(0) { }
+    };
+
+    Chunk* _head;
+
+    void oops_do_chunk(OopClosure* f, Chunk* c, const juint size);
+
+   public:
+    ChunkedHandleList() : _head(NULL) {}
+    ~ChunkedHandleList();
+
+    // Only one thread at a time can add, guarded by ClassLoaderData::metaspace_lock().
+    // However, multiple threads can execute oops_do concurrently with add.
+    oop* add(oop o);
+#ifdef ASSERT
+    bool contains(oop* p);
+#endif
+    void oops_do(OopClosure* f);
+  };
+
   friend class ClassLoaderDataGraph;
   friend class ClassLoaderDataGraphKlassIteratorAtomic;
   friend class ClassLoaderDataGraphMetaspaceIterator;
@@ -185,8 +212,8 @@ class ClassLoaderData : public CHeapObj {
   volatile int _claimed;   // true if claimed, for example during GC traces.
                            // To avoid applying oop closure more than once.
                            // Has to be an int because we cas it.
-  JNIHandleBlock* _handles; // Handles to constant pool arrays, Modules, etc, which
-                            // have the same life cycle of the corresponding ClassLoader.
+  ChunkedHandleList _handles; // Handles to constant pool arrays, Modules, etc, which
+                              // have the same life cycle of the corresponding ClassLoader.
 
   Klass* volatile _klasses;              // The classes defined by the class loader.
   PackageEntryTable* volatile _packages; // The packages defined by the class loader.
@@ -217,9 +244,6 @@ class ClassLoaderData : public CHeapObj {
   ClassLoaderData(Handle h_class_loader, bool is_anonymous, Dependencies dependencies);
   ~ClassLoaderData();
 
-  JNIHandleBlock* handles() const;
-  void set_handles(JNIHandleBlock* handles);
-
   // GC interface.
   void clear_claimed()          { _claimed = 0; }
   bool claimed() const          { return _claimed == 1; }
@@ -312,7 +336,7 @@ class ClassLoaderData : public CHeapObj {
   const char* loader_name();
 
   jobject add_handle(Handle h);
-  void remove_handle(jobject h);
+  void remove_handle_unsafe(jobject h);
   void add_class(Klass* k, bool publicize = true);
   void remove_class(Klass* k);
   bool contains_klass(Klass* k);
diff --git a/hotspot/src/share/vm/classfile/javaClasses.cpp b/hotspot/src/share/vm/classfile/javaClasses.cpp
index b7fe590eee1..22c1e6cc34e 100644
--- a/hotspot/src/share/vm/classfile/javaClasses.cpp
+++ b/hotspot/src/share/vm/classfile/javaClasses.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -773,13 +773,13 @@ void java_lang_Class::initialize_mirror_fields(KlassHandle k,
   InstanceKlass::cast(k())->do_local_static_fields(&initialize_static_field, mirror, CHECK);
 }
 
-// Set the java.lang.reflect.Module module field in the java_lang_Class mirror
+// Set the java.lang.Module module field in the java_lang_Class mirror
 void java_lang_Class::set_mirror_module_field(KlassHandle k, Handle mirror, Handle module, TRAPS) {
   if (module.is_null()) {
     // During startup, the module may be NULL only if java.base has not been defined yet.
-    // Put the class on the fixup_module_list to patch later when the java.lang.reflect.Module
+    // Put the class on the fixup_module_list to patch later when the java.lang.Module
     // for java.base is known.
-    assert(!Universe::is_module_initialized(), "Incorrect java.lang.reflect.Module pre module system initialization");
+    assert(!Universe::is_module_initialized(), "Incorrect java.lang.Module pre module system initialization");
 
     bool javabase_was_defined = false;
     {
@@ -810,7 +810,7 @@ void java_lang_Class::set_mirror_module_field(KlassHandle k, Handle mirror, Hand
     assert(Universe::is_module_initialized() ||
            (ModuleEntryTable::javabase_defined() &&
             (module() == JNIHandles::resolve(ModuleEntryTable::javabase_moduleEntry()->module()))),
-           "Incorrect java.lang.reflect.Module specification while creating mirror");
+           "Incorrect java.lang.Module specification while creating mirror");
     set_module(mirror(), module());
   }
 }
@@ -2269,6 +2269,7 @@ void java_lang_LiveStackFrameInfo::compute_offsets() {
   compute_offset(_monitors_offset,   k, vmSymbols::monitors_name(),    vmSymbols::object_array_signature());
   compute_offset(_locals_offset,     k, vmSymbols::locals_name(),      vmSymbols::object_array_signature());
   compute_offset(_operands_offset,   k, vmSymbols::operands_name(),    vmSymbols::object_array_signature());
+  compute_offset(_mode_offset,       k, vmSymbols::mode_name(),        vmSymbols::int_signature());
 }
 
 void java_lang_reflect_AccessibleObject::compute_offsets() {
@@ -2803,28 +2804,28 @@ void java_lang_reflect_Parameter::set_executable(oop param, oop value) {
 }
 
 
-int java_lang_reflect_Module::loader_offset;
-int java_lang_reflect_Module::name_offset;
-int java_lang_reflect_Module::_module_entry_offset = -1;
+int java_lang_Module::loader_offset;
+int java_lang_Module::name_offset;
+int java_lang_Module::_module_entry_offset = -1;
 
-Handle java_lang_reflect_Module::create(Handle loader, Handle module_name, TRAPS) {
+Handle java_lang_Module::create(Handle loader, Handle module_name, TRAPS) {
   assert(Universe::is_fully_initialized(), "Need to find another solution to the reflection problem");
 
-  Symbol* name = vmSymbols::java_lang_reflect_Module();
+  Symbol* name = vmSymbols::java_lang_Module();
   Klass* k = SystemDictionary::resolve_or_fail(name, true, CHECK_NH);
   instanceKlassHandle klass (THREAD, k);
 
-  Handle jlrmh = klass->allocate_instance_handle(CHECK_NH);
+  Handle jlmh = klass->allocate_instance_handle(CHECK_NH);
   JavaValue result(T_VOID);
-  JavaCalls::call_special(&result, jlrmh, KlassHandle(THREAD, klass()),
+  JavaCalls::call_special(&result, jlmh, KlassHandle(THREAD, klass()),
                           vmSymbols::object_initializer_name(),
-                          vmSymbols::java_lang_reflect_module_init_signature(),
+                          vmSymbols::java_lang_module_init_signature(),
                           loader, module_name, CHECK_NH);
-  return jlrmh;
+  return jlmh;
 }
 
-void java_lang_reflect_Module::compute_offsets() {
-  Klass* k = SystemDictionary::reflect_Module_klass();
+void java_lang_Module::compute_offsets() {
+  Klass* k = SystemDictionary::Module_klass();
   if(NULL != k) {
     compute_offset(loader_offset,  k, vmSymbols::loader_name(),  vmSymbols::classloader_signature());
     compute_offset(name_offset,    k, vmSymbols::name_name(),    vmSymbols::string_signature());
@@ -2833,27 +2834,27 @@ void java_lang_reflect_Module::compute_offsets() {
 }
 
 
-oop java_lang_reflect_Module::loader(oop module) {
+oop java_lang_Module::loader(oop module) {
   assert(Universe::is_fully_initialized(), "Need to find another solution to the reflection problem");
   return module->obj_field(loader_offset);
 }
 
-void java_lang_reflect_Module::set_loader(oop module, oop value) {
+void java_lang_Module::set_loader(oop module, oop value) {
   assert(Universe::is_fully_initialized(), "Need to find another solution to the reflection problem");
   module->obj_field_put(loader_offset, value);
 }
 
-oop java_lang_reflect_Module::name(oop module) {
+oop java_lang_Module::name(oop module) {
   assert(Universe::is_fully_initialized(), "Need to find another solution to the reflection problem");
   return module->obj_field(name_offset);
 }
 
-void java_lang_reflect_Module::set_name(oop module, oop value) {
+void java_lang_Module::set_name(oop module, oop value) {
   assert(Universe::is_fully_initialized(), "Need to find another solution to the reflection problem");
   module->obj_field_put(name_offset, value);
 }
 
-ModuleEntry* java_lang_reflect_Module::module_entry(oop module, TRAPS) {
+ModuleEntry* java_lang_Module::module_entry(oop module, TRAPS) {
   assert(_module_entry_offset != -1, "Uninitialized module_entry_offset");
   assert(module != NULL, "module can't be null");
   assert(module->is_oop(), "module must be oop");
@@ -2862,7 +2863,7 @@ ModuleEntry* java_lang_reflect_Module::module_entry(oop module, TRAPS) {
   if (module_entry == NULL) {
     // If the inject field containing the ModuleEntry* is null then return the
     // class loader's unnamed module.
-    oop loader = java_lang_reflect_Module::loader(module);
+    oop loader = java_lang_Module::loader(module);
     Handle h_loader = Handle(THREAD, loader);
     ClassLoaderData* loader_cld = SystemDictionary::register_loader(h_loader, CHECK_NULL);
     return loader_cld->modules()->unnamed_module();
@@ -2870,7 +2871,7 @@ ModuleEntry* java_lang_reflect_Module::module_entry(oop module, TRAPS) {
   return module_entry;
 }
 
-void java_lang_reflect_Module::set_module_entry(oop module, ModuleEntry* module_entry) {
+void java_lang_Module::set_module_entry(oop module, ModuleEntry* module_entry) {
   assert(_module_entry_offset != -1, "Uninitialized module_entry_offset");
   assert(module != NULL, "module can't be null");
   assert(module->is_oop(), "module must be oop");
@@ -3246,6 +3247,15 @@ void java_lang_invoke_MemberName::set_vmindex(oop mname, intptr_t index) {
   mname->address_field_put(_vmindex_offset, (address) index);
 }
 
+bool java_lang_invoke_MemberName::equals(oop mn1, oop mn2) {
+  if (mn1 == mn2) {
+     return true;
+  }
+  return (vmtarget(mn1) == vmtarget(mn2) && flags(mn1) == flags(mn2) &&
+          vmindex(mn1) == vmindex(mn2) &&
+          clazz(mn1) == clazz(mn2));
+}
+
 oop java_lang_invoke_LambdaForm::vmentry(oop lform) {
   assert(is_instance(lform), "wrong type");
   return lform->obj_field(_vmentry_offset);
@@ -3658,6 +3668,7 @@ int java_lang_StackFrameInfo::_version_offset;
 int java_lang_LiveStackFrameInfo::_monitors_offset;
 int java_lang_LiveStackFrameInfo::_locals_offset;
 int java_lang_LiveStackFrameInfo::_operands_offset;
+int java_lang_LiveStackFrameInfo::_mode_offset;
 int java_lang_AssertionStatusDirectives::classes_offset;
 int java_lang_AssertionStatusDirectives::classEnabled_offset;
 int java_lang_AssertionStatusDirectives::packages_offset;
@@ -3728,6 +3739,10 @@ void java_lang_LiveStackFrameInfo::set_operands(oop element, oop value) {
   element->obj_field_put(_operands_offset, value);
 }
 
+void java_lang_LiveStackFrameInfo::set_mode(oop element, int value) {
+  element->int_field_put(_mode_offset, value);
+}
+
 // Support for java Assertions - java_lang_AssertionStatusDirectives.
 
 void java_lang_AssertionStatusDirectives::set_classes(oop o, oop val) {
@@ -3862,7 +3877,7 @@ void JavaClasses::compute_offsets() {
   reflect_ConstantPool::compute_offsets();
   reflect_UnsafeStaticFieldAccessorImpl::compute_offsets();
   java_lang_reflect_Parameter::compute_offsets();
-  java_lang_reflect_Module::compute_offsets();
+  java_lang_Module::compute_offsets();
   java_lang_StackFrameInfo::compute_offsets();
   java_lang_LiveStackFrameInfo::compute_offsets();
 
diff --git a/hotspot/src/share/vm/classfile/javaClasses.hpp b/hotspot/src/share/vm/classfile/javaClasses.hpp
index f05db4c79b7..da5d4a67f2c 100644
--- a/hotspot/src/share/vm/classfile/javaClasses.hpp
+++ b/hotspot/src/share/vm/classfile/javaClasses.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -755,9 +755,9 @@ class java_lang_reflect_Parameter {
 };
 
 #define MODULE_INJECTED_FIELDS(macro)                            \
-  macro(java_lang_reflect_Module, module_entry, intptr_signature, false)
+  macro(java_lang_Module, module_entry, intptr_signature, false)
 
-class java_lang_reflect_Module {
+class java_lang_Module {
   private:
     static int loader_offset;
     static int name_offset;
@@ -1086,6 +1086,8 @@ class java_lang_invoke_MemberName: AllStatic {
   static int flags_offset_in_bytes()            { return _flags_offset; }
   static int vmtarget_offset_in_bytes()         { return _vmtarget_offset; }
   static int vmindex_offset_in_bytes()          { return _vmindex_offset; }
+
+  static bool equals(oop mt1, oop mt2);
 };
 
 
@@ -1380,11 +1382,13 @@ class java_lang_LiveStackFrameInfo: AllStatic {
   static int _monitors_offset;
   static int _locals_offset;
   static int _operands_offset;
+  static int _mode_offset;
 
  public:
   static void set_monitors(oop info, oop value);
   static void set_locals(oop info, oop value);
   static void set_operands(oop info, oop value);
+  static void set_mode(oop info, int value);
 
   static void compute_offsets();
 
diff --git a/hotspot/src/share/vm/classfile/javaClasses.inline.hpp b/hotspot/src/share/vm/classfile/javaClasses.inline.hpp
index b388bb157d3..a50113d1c61 100644
--- a/hotspot/src/share/vm/classfile/javaClasses.inline.hpp
+++ b/hotspot/src/share/vm/classfile/javaClasses.inline.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -162,8 +162,8 @@ inline bool java_lang_invoke_DirectMethodHandle::is_instance(oop obj) {
   return obj != NULL && is_subclass(obj->klass());
 }
 
-inline bool java_lang_reflect_Module::is_instance(oop obj) {
-  return obj != NULL && obj->klass() == SystemDictionary::reflect_Module_klass();
+inline bool java_lang_Module::is_instance(oop obj) {
+  return obj != NULL && obj->klass() == SystemDictionary::Module_klass();
 }
 
 inline int Backtrace::merge_bci_and_version(int bci, int version) {
diff --git a/hotspot/src/share/vm/classfile/moduleEntry.cpp b/hotspot/src/share/vm/classfile/moduleEntry.cpp
index 9402f5d91e1..f9941c014e2 100644
--- a/hotspot/src/share/vm/classfile/moduleEntry.cpp
+++ b/hotspot/src/share/vm/classfile/moduleEntry.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -87,11 +87,11 @@ Handle ModuleEntry::shared_protection_domain() {
 // Set the shared ProtectionDomain atomically
 void ModuleEntry::set_shared_protection_domain(ClassLoaderData *loader_data,
                                                Handle pd_h) {
-  // Create a JNI handle for the shared ProtectionDomain and save it atomically.
-  // If someone beats us setting the _pd cache, the created JNI handle is destroyed.
+  // Create a handle for the shared ProtectionDomain and save it atomically.
+  // If someone beats us setting the _pd cache, the created handle is destroyed.
   jobject obj = loader_data->add_handle(pd_h);
   if (Atomic::cmpxchg_ptr(obj, &_pd, NULL) != NULL) {
-    loader_data->remove_handle(obj);
+    loader_data->remove_handle_unsafe(obj);
   }
 }
 
@@ -158,10 +158,10 @@ void ModuleEntry::set_read_walk_required(ClassLoaderData* m_loader_data) {
       loader_data() != m_loader_data &&
       !m_loader_data->is_builtin_class_loader_data()) {
     _must_walk_reads = true;
-    if (log_is_enabled(Trace, modules)) {
+    if (log_is_enabled(Trace, module)) {
       ResourceMark rm;
-      log_trace(modules)("ModuleEntry::set_read_walk_required(): module %s reads list must be walked",
-                         (name() != NULL) ? name()->as_C_string() : UNNAMED_MODULE);
+      log_trace(module)("ModuleEntry::set_read_walk_required(): module %s reads list must be walked",
+                        (name() != NULL) ? name()->as_C_string() : UNNAMED_MODULE);
     }
   }
 }
@@ -180,10 +180,10 @@ void ModuleEntry::purge_reads() {
     // on the remaining live modules on the reads list.
     _must_walk_reads = false;
 
-    if (log_is_enabled(Trace, modules)) {
+    if (log_is_enabled(Trace, module)) {
       ResourceMark rm;
-      log_trace(modules)("ModuleEntry::purge_reads(): module %s reads list being walked",
-                         (name() != NULL) ? name()->as_C_string() : UNNAMED_MODULE);
+      log_trace(module)("ModuleEntry::purge_reads(): module %s reads list being walked",
+                        (name() != NULL) ? name()->as_C_string() : UNNAMED_MODULE);
     }
 
     // Go backwards because this removes entries that are dead.
@@ -236,8 +236,11 @@ ModuleEntryTable::~ModuleEntryTable() {
       m = m->next();
 
       ResourceMark rm;
-      log_debug(modules)("ModuleEntryTable: deleting module: %s", to_remove->name() != NULL ?
-                         to_remove->name()->as_C_string() : UNNAMED_MODULE);
+      if (to_remove->name() != NULL) {
+        log_info(module, unload)("unloading module %s", to_remove->name()->as_C_string());
+      }
+      log_debug(module)("ModuleEntryTable: deleting module: %s", to_remove->name() != NULL ?
+                        to_remove->name()->as_C_string() : UNNAMED_MODULE);
 
       // Clean out the C heap allocated reads list first before freeing the entry
       to_remove->delete_reads();
@@ -266,19 +269,19 @@ void ModuleEntryTable::create_unnamed_module(ClassLoaderData* loader_data) {
 
   // Each ModuleEntryTable has exactly one unnamed module
   if (loader_data->is_the_null_class_loader_data()) {
-    // For the boot loader, the java.lang.reflect.Module for the unnamed module
+    // For the boot loader, the java.lang.Module for the unnamed module
     // is not known until a call to JVM_SetBootLoaderUnnamedModule is made. At
     // this point initially create the ModuleEntry for the unnamed module.
     _unnamed_module = new_entry(0, Handle(NULL), NULL, NULL, NULL, loader_data);
   } else {
-    // For all other class loaders the java.lang.reflect.Module for their
+    // For all other class loaders the java.lang.Module for their
     // corresponding unnamed module can be found in the java.lang.ClassLoader object.
     oop module = java_lang_ClassLoader::unnamedModule(loader_data->class_loader());
     _unnamed_module = new_entry(0, Handle(module), NULL, NULL, NULL, loader_data);
 
-    // Store pointer to the ModuleEntry in the unnamed module's java.lang.reflect.Module
+    // Store pointer to the ModuleEntry in the unnamed module's java.lang.Module
     // object.
-    java_lang_reflect_Module::set_module_entry(module, _unnamed_module);
+    java_lang_Module::set_module_entry(module, _unnamed_module);
   }
 
   // Add to bucket 0, no name to hash on
@@ -315,9 +318,9 @@ ModuleEntry* ModuleEntryTable::new_entry(unsigned int hash, Handle module_handle
 
   if (ClassLoader::is_in_patch_mod_entries(name)) {
     entry->set_is_patched();
-    if (log_is_enabled(Trace, modules, patch)) {
+    if (log_is_enabled(Trace, module, patch)) {
       ResourceMark rm;
-      log_trace(modules, patch)("Marked module %s as patched from --patch-module", name->as_C_string());
+      log_trace(module, patch)("Marked module %s as patched from --patch-module", name->as_C_string());
     }
   }
 
@@ -388,27 +391,27 @@ void ModuleEntryTable::finalize_javabase(Handle module_handle, Symbol* version,
     fatal("Unable to finalize module definition for " JAVA_BASE_NAME);
   }
 
-  // Set java.lang.reflect.Module, version and location for java.base
+  // Set java.lang.Module, version and location for java.base
   ModuleEntry* jb_module = javabase_moduleEntry();
   assert(jb_module != NULL, JAVA_BASE_NAME " ModuleEntry not defined");
   jb_module->set_version(version);
   jb_module->set_location(location);
   // Once java.base's ModuleEntry _module field is set with the known
-  // java.lang.reflect.Module, java.base is considered "defined" to the VM.
+  // java.lang.Module, java.base is considered "defined" to the VM.
   jb_module->set_module(boot_loader_data->add_handle(module_handle));
 
-  // Store pointer to the ModuleEntry for java.base in the java.lang.reflect.Module object.
-  java_lang_reflect_Module::set_module_entry(module_handle(), jb_module);
+  // Store pointer to the ModuleEntry for java.base in the java.lang.Module object.
+  java_lang_Module::set_module_entry(module_handle(), jb_module);
 }
 
-// Within java.lang.Class instances there is a java.lang.reflect.Module field
-// that must be set with the defining module.  During startup, prior to java.base's
-// definition, classes needing their module field set are added to the fixup_module_list.
-// Their module field is set once java.base's java.lang.reflect.Module is known to the VM.
+// Within java.lang.Class instances there is a java.lang.Module field that must
+// be set with the defining module.  During startup, prior to java.base's definition,
+// classes needing their module field set are added to the fixup_module_list.
+// Their module field is set once java.base's java.lang.Module is known to the VM.
 void ModuleEntryTable::patch_javabase_entries(Handle module_handle) {
   if (module_handle.is_null()) {
     fatal("Unable to patch the module field of classes loaded prior to "
-          JAVA_BASE_NAME "'s definition, invalid java.lang.reflect.Module");
+          JAVA_BASE_NAME "'s definition, invalid java.lang.Module");
   }
 
   // Do the fixups for the basic primitive types
diff --git a/hotspot/src/share/vm/classfile/moduleEntry.hpp b/hotspot/src/share/vm/classfile/moduleEntry.hpp
index 85e898ea861..c50441a1739 100644
--- a/hotspot/src/share/vm/classfile/moduleEntry.hpp
+++ b/hotspot/src/share/vm/classfile/moduleEntry.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -36,8 +36,8 @@
 #include "utilities/ostream.hpp"
 
 #define UNNAMED_MODULE "Unnamed Module"
-#define JAVAPKG "java/"
-#define JAVAPKG_LEN 5
+#define JAVAPKG "java"
+#define JAVAPKG_LEN 4
 #define JAVA_BASE_NAME "java.base"
 
 class ModuleClosure;
@@ -45,7 +45,7 @@ class ModuleClosure;
 // A ModuleEntry describes a module that has been defined by a call to JVM_DefineModule.
 // It contains:
 //   - Symbol* containing the module's name.
-//   - pointer to the java.lang.reflect.Module for this module.
+//   - pointer to the java.lang.Module for this module.
 //   - pointer to the java.security.ProtectionDomain shared by classes defined to this module.
 //   - ClassLoaderData*, class loader of this module.
 //   - a growable array containg other module entries that this module can read.
@@ -55,7 +55,7 @@ class ModuleClosure;
 // data structure.
 class ModuleEntry : public HashtableEntry {
 private:
-  jobject _module;                     // java.lang.reflect.Module
+  jobject _module;                     // java.lang.Module
   jobject _pd;                         // java.security.ProtectionDomain, cached
                                        // for shared classes from this module
   ClassLoaderData* _loader_data;
diff --git a/hotspot/src/share/vm/classfile/modules.cpp b/hotspot/src/share/vm/classfile/modules.cpp
index afa3553af1c..7328aec06fb 100644
--- a/hotspot/src/share/vm/classfile/modules.cpp
+++ b/hotspot/src/share/vm/classfile/modules.cpp
@@ -62,7 +62,7 @@ bool Modules::verify_package_name(const char* package_name) {
 }
 
 static char* get_module_name(oop module, TRAPS) {
-  oop name_oop = java_lang_reflect_Module::name(module);
+  oop name_oop = java_lang_Module::name(module);
   if (name_oop == NULL) {
     THROW_MSG_NULL(vmSymbols::java_lang_NullPointerException(), "Null module name");
   }
@@ -98,11 +98,11 @@ static PackageEntryTable* get_package_entry_table(Handle h_loader, TRAPS) {
 
 static ModuleEntry* get_module_entry(jobject module, TRAPS) {
   Handle module_h(THREAD, JNIHandles::resolve(module));
-  if (!java_lang_reflect_Module::is_instance(module_h())) {
+  if (!java_lang_Module::is_instance(module_h())) {
     THROW_MSG_NULL(vmSymbols::java_lang_IllegalArgumentException(),
-                   "module is not an instance of type java.lang.reflect.Module");
+                   "module is not an instance of type java.lang.Module");
   }
-  return java_lang_reflect_Module::module_entry(module_h(), CHECK_NULL);
+  return java_lang_Module::module_entry(module_h(), CHECK_NULL);
 }
 
 static PackageEntry* get_package_entry(ModuleEntry* module_entry, const char* package_name, TRAPS) {
@@ -181,7 +181,7 @@ static void define_javabase_module(jobject module, jstring version,
   }
 
   // Validate java_base's loader is the boot loader.
-  oop loader = java_lang_reflect_Module::loader(module_handle());
+  oop loader = java_lang_Module::loader(module_handle());
   if (loader != NULL) {
     THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(),
               "Class loader must be the boot class loader");
@@ -234,19 +234,21 @@ static void define_javabase_module(jobject module, jstring version,
   // Only the thread that actually defined the base module will get here,
   // so no locking is needed.
 
-  // Patch any previously loaded class's module field with java.base's java.lang.reflect.Module.
+  // Patch any previously loaded class's module field with java.base's java.lang.Module.
   ModuleEntryTable::patch_javabase_entries(module_handle);
 
-  log_debug(modules)("define_javabase_module(): Definition of module: "
-                     JAVA_BASE_NAME ", version: %s, location: %s, package #: %d",
-                     module_version != NULL ? module_version : "NULL",
-                     module_location != NULL ? module_location : "NULL",
-                     pkg_list->length());
+  log_info(module, load)(JAVA_BASE_NAME " location: %s",
+                         module_location != NULL ? module_location : "NULL");
+  log_debug(module)("define_javabase_module(): Definition of module: "
+                    JAVA_BASE_NAME ", version: %s, location: %s, package #: %d",
+                    module_version != NULL ? module_version : "NULL",
+                    module_location != NULL ? module_location : "NULL",
+                    pkg_list->length());
 
   // packages defined to java.base
   for (int x = 0; x < pkg_list->length(); x++) {
-    log_trace(modules)("define_javabase_module(): creation of package %s for module " JAVA_BASE_NAME,
-                       (pkg_list->at(x))->as_C_string());
+    log_trace(module)("define_javabase_module(): creation of package %s for module " JAVA_BASE_NAME,
+                      (pkg_list->at(x))->as_C_string());
   }
 }
 
@@ -284,9 +286,9 @@ void Modules::define_module(jobject module, jstring version,
   }
 
   Handle module_handle(THREAD, JNIHandles::resolve(module));
-  if (!java_lang_reflect_Module::is_instance(module_handle())) {
+  if (!java_lang_Module::is_instance(module_handle())) {
     THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(),
-              "module is not an instance of type java.lang.reflect.Module");
+              "module is not an instance of type java.lang.Module");
   }
 
   char* module_name = get_module_name(module_handle(), CHECK);
@@ -303,7 +305,7 @@ void Modules::define_module(jobject module, jstring version,
 
   const char* module_version = get_module_version(version);
 
-  oop loader = java_lang_reflect_Module::loader(module_handle());
+  oop loader = java_lang_Module::loader(module_handle());
   // Make sure loader is not the jdk.internal.reflect.DelegatingClassLoader.
   if (loader != java_lang_ClassLoader::non_reflection_class_loader(loader)) {
     THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(),
@@ -325,7 +327,8 @@ void Modules::define_module(jobject module, jstring version,
     // Only modules defined to either the boot or platform class loader, can define a "java/" package.
     if (!h_loader.is_null() &&
         !SystemDictionary::is_platform_class_loader(h_loader) &&
-        strncmp(package_name, JAVAPKG, JAVAPKG_LEN) == 0) {
+        (strncmp(package_name, JAVAPKG, JAVAPKG_LEN) == 0 &&
+          (package_name[JAVAPKG_LEN] == '/' || package_name[JAVAPKG_LEN] == '\0'))) {
       const char* class_loader_name = SystemDictionary::loader_name(h_loader());
       size_t pkg_len = strlen(package_name);
       char* pkg_name = NEW_RESOURCE_ARRAY_IN_THREAD(THREAD, char, pkg_len);
@@ -423,8 +426,8 @@ void Modules::define_module(jobject module, jstring version,
           pkg_list->at(y)->decrement_refcount();
         }
 
-        // Store pointer to ModuleEntry record in java.lang.reflect.Module object.
-        java_lang_reflect_Module::set_module_entry(module_handle(), module_entry);
+        // Store pointer to ModuleEntry record in java.lang.Module object.
+        java_lang_Module::set_module_entry(module_handle(), module_entry);
       }
     }
   }  // Release the lock
@@ -437,23 +440,24 @@ void Modules::define_module(jobject module, jstring version,
       throw_dup_pkg_exception(module_name, existing_pkg, CHECK);
   }
 
-  if (log_is_enabled(Debug, modules)) {
-    outputStream* logst = Log(modules)::debug_stream();
+  log_info(module, load)("%s location: %s", module_name,
+                         module_location != NULL ? module_location : "NULL");
+  if (log_is_enabled(Debug, module)) {
+    outputStream* logst = Log(module)::debug_stream();
     logst->print("define_module(): creation of module: %s, version: %s, location: %s, ",
                  module_name, module_version != NULL ? module_version : "NULL",
                  module_location != NULL ? module_location : "NULL");
     loader_data->print_value_on(logst);
     logst->print_cr(", package #: %d", pkg_list->length());
     for (int y = 0; y < pkg_list->length(); y++) {
-      log_trace(modules)("define_module(): creation of package %s for module %s",
-                         (pkg_list->at(y))->as_C_string(), module_name);
+      log_trace(module)("define_module(): creation of package %s for module %s",
+                        (pkg_list->at(y))->as_C_string(), module_name);
     }
   }
 
   // If the module is defined to the boot loader and an exploded build is being
   // used, prepend /modules/modules_name, if it exists, to the system boot class path.
   if (loader == NULL &&
-      !Universe::is_module_initialized() &&
       !ClassLoader::has_jrt_entry()) {
     ClassLoader::add_to_exploded_build_list(module_symbol, CHECK);
   }
@@ -466,37 +470,37 @@ void Modules::set_bootloader_unnamed_module(jobject module, TRAPS) {
     THROW_MSG(vmSymbols::java_lang_NullPointerException(), "Null module object");
   }
   Handle module_handle(THREAD, JNIHandles::resolve(module));
-  if (!java_lang_reflect_Module::is_instance(module_handle())) {
+  if (!java_lang_Module::is_instance(module_handle())) {
     THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(),
-              "module is not an instance of type java.lang.reflect.Module");
+              "module is not an instance of type java.lang.Module");
   }
 
   // Ensure that this is an unnamed module
-  oop name = java_lang_reflect_Module::name(module_handle());
+  oop name = java_lang_Module::name(module_handle());
   if (name != NULL) {
     THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(),
-              "boot loader's unnamed module's java.lang.reflect.Module has a name");
+              "boot loader's unnamed module's java.lang.Module has a name");
   }
 
   // Validate java_base's loader is the boot loader.
-  oop loader = java_lang_reflect_Module::loader(module_handle());
+  oop loader = java_lang_Module::loader(module_handle());
   if (loader != NULL) {
     THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(),
               "Class loader must be the boot class loader");
   }
   Handle h_loader = Handle(THREAD, loader);
 
-  log_debug(modules)("set_bootloader_unnamed_module(): recording unnamed module for boot loader");
+  log_debug(module)("set_bootloader_unnamed_module(): recording unnamed module for boot loader");
 
   // Ensure the boot loader's PackageEntryTable has been created
   ModuleEntryTable* module_table = get_module_entry_table(h_loader, CHECK);
 
-  // Set java.lang.reflect.Module for the boot loader's unnamed module
+  // Set java.lang.Module for the boot loader's unnamed module
   ModuleEntry* unnamed_module = module_table->unnamed_module();
   assert(unnamed_module != NULL, "boot loader's unnamed ModuleEntry not defined");
   unnamed_module->set_module(ClassLoaderData::the_null_class_loader_data()->add_handle(module_handle));
-  // Store pointer to the ModuleEntry in the unnamed module's java.lang.reflect.Module object.
-  java_lang_reflect_Module::set_module_entry(module_handle(), unnamed_module);
+  // Store pointer to the ModuleEntry in the unnamed module's java.lang.Module object.
+  java_lang_Module::set_module_entry(module_handle(), unnamed_module);
 }
 
 void Modules::add_module_exports(jobject from_module, const char* package_name, jobject to_module, TRAPS) {
@@ -544,10 +548,10 @@ void Modules::add_module_exports(jobject from_module, const char* package_name,
                       from_module_entry->name()->as_C_string()));
   }
 
-  log_debug(modules)("add_module_exports(): package %s in module %s is exported to module %s",
-                     package_entry->name()->as_C_string(),
-                     from_module_entry->name()->as_C_string(),
-                     to_module_entry == NULL ? "NULL" :
+  log_debug(module)("add_module_exports(): package %s in module %s is exported to module %s",
+                    package_entry->name()->as_C_string(),
+                    from_module_entry->name()->as_C_string(),
+                    to_module_entry == NULL ? "NULL" :
                       to_module_entry->is_named() ?
                         to_module_entry->name()->as_C_string() : UNNAMED_MODULE);
 
@@ -591,12 +595,12 @@ void Modules::add_reads_module(jobject from_module, jobject to_module, TRAPS) {
   }
 
   ResourceMark rm(THREAD);
-  log_debug(modules)("add_reads_module(): Adding read from module %s to module %s",
-                     from_module_entry->is_named() ?
-                     from_module_entry->name()->as_C_string() : UNNAMED_MODULE,
-                     to_module_entry == NULL ? "all unnamed" :
-                       (to_module_entry->is_named() ?
-                        to_module_entry->name()->as_C_string() : UNNAMED_MODULE));
+  log_debug(module)("add_reads_module(): Adding read from module %s to module %s",
+                    from_module_entry->is_named() ?
+                    from_module_entry->name()->as_C_string() : UNNAMED_MODULE,
+                    to_module_entry == NULL ? "all unnamed" :
+                      (to_module_entry->is_named() ?
+                       to_module_entry->name()->as_C_string() : UNNAMED_MODULE));
 
   // if modules are the same or if from_module is unnamed then no need to add the read.
   if (from_module_entry != to_module_entry && from_module_entry->is_named()) {
@@ -615,7 +619,7 @@ jobject Modules::get_module(jclass clazz, TRAPS) {
   }
   oop mirror = JNIHandles::resolve_non_null(clazz);
   if (mirror == NULL) {
-    log_debug(modules)("get_module(): no mirror, returning NULL");
+    log_debug(module)("get_module(): no mirror, returning NULL");
     return NULL;
   }
   if (!java_lang_Class::is_instance(mirror)) {
@@ -626,13 +630,13 @@ jobject Modules::get_module(jclass clazz, TRAPS) {
   oop module = java_lang_Class::module(mirror);
 
   assert(module != NULL, "java.lang.Class module field not set");
-  assert(java_lang_reflect_Module::is_instance(module), "module is not an instance of type java.lang.reflect.Module");
+  assert(java_lang_Module::is_instance(module), "module is not an instance of type java.lang.Module");
 
-  if (log_is_enabled(Debug, modules)) {
+  if (log_is_enabled(Debug, module)) {
     ResourceMark rm(THREAD);
-    outputStream* logst = Log(modules)::debug_stream();
+    outputStream* logst = Log(module)::debug_stream();
     Klass* klass = java_lang_Class::as_Klass(mirror);
-    oop module_name = java_lang_reflect_Module::name(module);
+    oop module_name = java_lang_Module::name(module);
     if (module_name != NULL) {
       logst->print("get_module(): module ");
       java_lang_String::print(module_name, tty);
@@ -748,7 +752,8 @@ void Modules::add_module_package(jobject module, const char* package_name, TRAPS
   // Only modules defined to either the boot or platform class loader, can define a "java/" package.
   if (!loader_data->is_the_null_class_loader_data() &&
       !loader_data->is_platform_class_loader_data() &&
-      strncmp(package_name, JAVAPKG, JAVAPKG_LEN) == 0) {
+      (strncmp(package_name, JAVAPKG, JAVAPKG_LEN) == 0 &&
+        (package_name[JAVAPKG_LEN] == '/' || package_name[JAVAPKG_LEN] == '\0'))) {
     const char* class_loader_name = SystemDictionary::loader_name(loader_data);
     size_t pkg_len = strlen(package_name);
     char* pkg_name = NEW_RESOURCE_ARRAY_IN_THREAD(THREAD, char, pkg_len);
@@ -762,8 +767,8 @@ void Modules::add_module_package(jobject module, const char* package_name, TRAPS
     THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(), message);
   }
 
-  log_debug(modules)("add_module_package(): Adding package %s to module %s",
-                     package_name, module_entry->name()->as_C_string());
+  log_debug(module)("add_module_package(): Adding package %s to module %s",
+                    package_name, module_entry->name()->as_C_string());
 
   TempNewSymbol pkg_symbol = SymbolTable::new_symbol(package_name, CHECK);
   PackageEntryTable* package_table = loader_data->packages();
@@ -818,8 +823,8 @@ void Modules::add_module_exports_to_all_unnamed(jobject module, const char* pack
                         module_entry->name()->as_C_string()));
     }
 
-    log_debug(modules)("add_module_exports_to_all_unnamed(): package %s in module"
-                       " %s is exported to all unnamed modules",
+    log_debug(module)("add_module_exports_to_all_unnamed(): package %s in module"
+                      " %s is exported to all unnamed modules",
                        package_entry->name()->as_C_string(),
                        module_entry->name()->as_C_string());
 
diff --git a/hotspot/src/share/vm/classfile/modules.hpp b/hotspot/src/share/vm/classfile/modules.hpp
index 4f5e089a065..4dc752c95a4 100644
--- a/hotspot/src/share/vm/classfile/modules.hpp
+++ b/hotspot/src/share/vm/classfile/modules.hpp
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+* Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 *
 * This code is free software; you can redistribute it and/or modify it
@@ -55,12 +55,12 @@ public:
                             jstring location, const char* const* packages,
                             jsize num_packages, TRAPS);
 
-  // Provides the java.lang.reflect.Module for the unnamed module defined
+  // Provides the java.lang.Module for the unnamed module defined
   // to the boot loader.
   //
   //  IllegalArgumentExceptions are thrown for the following :
   //  * Module has a name
-  //  * Module is not a subclass of java.lang.reflect.Module
+  //  * Module is not a subclass of java.lang.Module
   //  * Module's class loader is not the boot loader
   //  NullPointerExceptions are thrown if module is null.
   static void set_bootloader_unnamed_module(jobject module, TRAPS);
@@ -96,10 +96,10 @@ public:
   // module does not exist.
   static void add_reads_module(jobject from_module, jobject to_module, TRAPS);
 
-  // Return the java.lang.reflect.Module object for this class object.
+  // Return the java.lang.Module object for this class object.
   static jobject get_module(jclass clazz, TRAPS);
 
-  // Return the java.lang.reflect.Module object for this class loader and package.
+  // Return the java.lang.Module object for this class loader and package.
   // Returns NULL if the class loader has not loaded any classes in the package.
   // The package should contain /'s, not .'s, as in java/lang, not java.lang.
   // NullPointerException is thrown if package is null.
@@ -109,7 +109,7 @@ public:
   static jobject get_named_module(Handle h_loader, const char* package, TRAPS);
 
   // If package is defined by loader, return the
-  // java.lang.reflect.Module object for the module in which the package is defined.
+  // java.lang.Module object for the module in which the package is defined.
   // Returns NULL if package is invalid or not defined by loader.
   static jobject get_module(Symbol* package_name, Handle h_loader, TRAPS);
 
diff --git a/hotspot/src/share/vm/classfile/packageEntry.cpp b/hotspot/src/share/vm/classfile/packageEntry.cpp
index ab80fcb732b..aec61c0c75a 100644
--- a/hotspot/src/share/vm/classfile/packageEntry.cpp
+++ b/hotspot/src/share/vm/classfile/packageEntry.cpp
@@ -77,13 +77,13 @@ void PackageEntry::set_export_walk_required(ClassLoaderData* m_loader_data) {
       (this_pkg_mod == NULL || this_pkg_mod->loader_data() != m_loader_data) &&
       !m_loader_data->is_builtin_class_loader_data()) {
     _must_walk_exports = true;
-    if (log_is_enabled(Trace, modules)) {
+    if (log_is_enabled(Trace, module)) {
       ResourceMark rm;
       assert(name() != NULL, "PackageEntry without a valid name");
-      log_trace(modules)("PackageEntry::set_export_walk_required(): package %s defined in module %s, exports list must be walked",
-                         name()->as_C_string(),
-                         (this_pkg_mod == NULL || this_pkg_mod->name() == NULL) ?
-                           UNNAMED_MODULE : this_pkg_mod->name()->as_C_string());
+      log_trace(module)("PackageEntry::set_export_walk_required(): package %s defined in module %s, exports list must be walked",
+                        name()->as_C_string(),
+                        (this_pkg_mod == NULL || this_pkg_mod->name() == NULL) ?
+                          UNNAMED_MODULE : this_pkg_mod->name()->as_C_string());
     }
   }
 }
@@ -132,13 +132,13 @@ void PackageEntry::purge_qualified_exports() {
     // on the remaining live modules on the exports list.
     _must_walk_exports = false;
 
-    if (log_is_enabled(Trace, modules)) {
+    if (log_is_enabled(Trace, module)) {
       ResourceMark rm;
       assert(name() != NULL, "PackageEntry without a valid name");
       ModuleEntry* pkg_mod = module();
-      log_trace(modules)("PackageEntry::purge_qualified_exports(): package %s defined in module %s, exports list being walked",
-                         name()->as_C_string(),
-                         (pkg_mod == NULL || pkg_mod->name() == NULL) ? UNNAMED_MODULE : pkg_mod->name()->as_C_string());
+      log_trace(module)("PackageEntry::purge_qualified_exports(): package %s defined in module %s, exports list being walked",
+                        name()->as_C_string(),
+                        (pkg_mod == NULL || pkg_mod->name() == NULL) ? UNNAMED_MODULE : pkg_mod->name()->as_C_string());
     }
 
     // Go backwards because this removes entries that are dead.
diff --git a/hotspot/src/share/vm/classfile/stringTable.cpp b/hotspot/src/share/vm/classfile/stringTable.cpp
index 24c72b7ccf1..731cba8a8a6 100644
--- a/hotspot/src/share/vm/classfile/stringTable.cpp
+++ b/hotspot/src/share/vm/classfile/stringTable.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -96,10 +96,14 @@ CompactHashtable StringTable::_shared_table;
 
 // Pick hashing algorithm
 unsigned int StringTable::hash_string(const jchar* s, int len) {
-  return use_alternate_hashcode() ? AltHashing::murmur3_32(seed(), s, len) :
+  return use_alternate_hashcode() ? alt_hash_string(s, len) :
                                     java_lang_String::hash_code(s, len);
 }
 
+unsigned int StringTable::alt_hash_string(const jchar* s, int len) {
+  return AltHashing::murmur3_32(seed(), s, len);
+}
+
 unsigned int StringTable::hash_string(oop string) {
   EXCEPTION_MARK;
   if (string == NULL) {
@@ -117,11 +121,10 @@ unsigned int StringTable::hash_string(oop string) {
   }
 }
 
-oop StringTable::lookup_shared(jchar* name, int len) {
-  // java_lang_String::hash_code() was used to compute hash values in the shared table. Don't
-  // use the hash value from StringTable::hash_string() as it might use alternate hashcode.
-  return _shared_table.lookup((const char*)name,
-                              java_lang_String::hash_code(name, len), len);
+oop StringTable::lookup_shared(jchar* name, int len, unsigned int hash) {
+  assert(hash == java_lang_String::hash_code(name, len),
+         "hash must be computed using java_lang_String::hash_code");
+  return _shared_table.lookup((const char*)name, hash, len);
 }
 
 oop StringTable::lookup_in_main_table(int index, jchar* name,
@@ -156,7 +159,7 @@ oop StringTable::basic_add(int index_arg, Handle string, jchar* name,
   unsigned int hashValue;
   int index;
   if (use_alternate_hashcode()) {
-    hashValue = hash_string(name, len);
+    hashValue = alt_hash_string(name, len);
     index = hash_to_index(hashValue);
   } else {
     hashValue = hashValue_arg;
@@ -199,12 +202,15 @@ static void ensure_string_alive(oop string) {
 }
 
 oop StringTable::lookup(jchar* name, int len) {
-  oop string = lookup_shared(name, len);
+  // shared table always uses java_lang_String::hash_code
+  unsigned int hash = java_lang_String::hash_code(name, len);
+  oop string = lookup_shared(name, len, hash);
   if (string != NULL) {
     return string;
   }
-
-  unsigned int hash = hash_string(name, len);
+  if (use_alternate_hashcode()) {
+    hash = alt_hash_string(name, len);
+  }
   int index = the_table()->hash_to_index(hash);
   string = the_table()->lookup_in_main_table(index, name, len, hash);
 
@@ -215,12 +221,15 @@ oop StringTable::lookup(jchar* name, int len) {
 
 oop StringTable::intern(Handle string_or_null, jchar* name,
                         int len, TRAPS) {
-  oop found_string = lookup_shared(name, len);
+  // shared table always uses java_lang_String::hash_code
+  unsigned int hashValue = java_lang_String::hash_code(name, len);
+  oop found_string = lookup_shared(name, len, hashValue);
   if (found_string != NULL) {
     return found_string;
   }
-
-  unsigned int hashValue = hash_string(name, len);
+  if (use_alternate_hashcode()) {
+    hashValue = alt_hash_string(name, len);
+  }
   int index = the_table()->hash_to_index(hashValue);
   found_string = the_table()->lookup_in_main_table(index, name, len, hashValue);
 
@@ -305,7 +314,11 @@ oop StringTable::intern(const char* utf8_string, TRAPS) {
 }
 
 void StringTable::unlink_or_oops_do(BoolObjectClosure* is_alive, OopClosure* f, int* processed, int* removed) {
-  buckets_unlink_or_oops_do(is_alive, f, 0, the_table()->table_size(), processed, removed);
+  BucketUnlinkContext context;
+  buckets_unlink_or_oops_do(is_alive, f, 0, the_table()->table_size(), &context);
+  _the_table->bulk_free_entries(&context);
+  *processed = context._num_processed;
+  *removed = context._num_removed;
 }
 
 void StringTable::possibly_parallel_unlink_or_oops_do(BoolObjectClosure* is_alive, OopClosure* f, int* processed, int* removed) {
@@ -314,6 +327,7 @@ void StringTable::possibly_parallel_unlink_or_oops_do(BoolObjectClosure* is_aliv
   assert(SafepointSynchronize::is_at_safepoint(), "must be at safepoint");
   const int limit = the_table()->table_size();
 
+  BucketUnlinkContext context;
   for (;;) {
     // Grab next set of buckets to scan
     int start_idx = Atomic::add(ClaimChunkSize, &_parallel_claimed_idx) - ClaimChunkSize;
@@ -323,8 +337,11 @@ void StringTable::possibly_parallel_unlink_or_oops_do(BoolObjectClosure* is_aliv
     }
 
     int end_idx = MIN2(limit, start_idx + ClaimChunkSize);
-    buckets_unlink_or_oops_do(is_alive, f, start_idx, end_idx, processed, removed);
+    buckets_unlink_or_oops_do(is_alive, f, start_idx, end_idx, &context);
   }
+  _the_table->bulk_free_entries(&context);
+  *processed = context._num_processed;
+  *removed = context._num_removed;
 }
 
 void StringTable::buckets_oops_do(OopClosure* f, int start_idx, int end_idx) {
@@ -350,7 +367,7 @@ void StringTable::buckets_oops_do(OopClosure* f, int start_idx, int end_idx) {
   }
 }
 
-void StringTable::buckets_unlink_or_oops_do(BoolObjectClosure* is_alive, OopClosure* f, int start_idx, int end_idx, int* processed, int* removed) {
+void StringTable::buckets_unlink_or_oops_do(BoolObjectClosure* is_alive, OopClosure* f, int start_idx, int end_idx, BucketUnlinkContext* context) {
   const int limit = the_table()->table_size();
 
   assert(0 <= start_idx && start_idx <= limit,
@@ -374,10 +391,9 @@ void StringTable::buckets_unlink_or_oops_do(BoolObjectClosure* is_alive, OopClos
         p = entry->next_addr();
       } else {
         *p = entry->next();
-        the_table()->free_entry(entry);
-        (*removed)++;
+        context->free_entry(entry);
       }
-      (*processed)++;
+      context->_num_processed++;
       entry = *p;
     }
   }
diff --git a/hotspot/src/share/vm/classfile/stringTable.hpp b/hotspot/src/share/vm/classfile/stringTable.hpp
index 397cbbd6f9e..0ef225f1c54 100644
--- a/hotspot/src/share/vm/classfile/stringTable.hpp
+++ b/hotspot/src/share/vm/classfile/stringTable.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -56,14 +56,25 @@ private:
                 unsigned int hashValue, TRAPS);
 
   oop lookup_in_main_table(int index, jchar* chars, int length, unsigned int hashValue);
-  static oop lookup_shared(jchar* name, int len);
+  static oop lookup_shared(jchar* name, int len, unsigned int hash);
 
   // Apply the give oop closure to the entries to the buckets
   // in the range [start_idx, end_idx).
   static void buckets_oops_do(OopClosure* f, int start_idx, int end_idx);
+
+  typedef StringTable::BucketUnlinkContext BucketUnlinkContext;
   // Unlink or apply the give oop closure to the entries to the buckets
-  // in the range [start_idx, end_idx).
-  static void buckets_unlink_or_oops_do(BoolObjectClosure* is_alive, OopClosure* f, int start_idx, int end_idx, int* processed, int* removed);
+  // in the range [start_idx, end_idx). Unlinked bucket entries are collected in the given
+  // context to be freed later.
+  // This allows multiple threads to work on the table at once.
+  static void buckets_unlink_or_oops_do(BoolObjectClosure* is_alive, OopClosure* f, int start_idx, int end_idx, BucketUnlinkContext* context);
+
+  // Hashing algorithm, used as the hash value used by the
+  //     StringTable for bucket selection and comparison (stored in the
+  //     HashtableEntry structures).  This is used in the String.intern() method.
+  static unsigned int hash_string(const jchar* s, int len);
+  static unsigned int hash_string(oop string);
+  static unsigned int alt_hash_string(const jchar* s, int len);
 
   StringTable() : RehashableHashtable((int)StringTableSize,
                               sizeof (HashtableEntry)) {}
@@ -109,12 +120,6 @@ public:
   }
   static void possibly_parallel_oops_do(OopClosure* f);
 
-  // Hashing algorithm, used as the hash value used by the
-  //     StringTable for bucket selection and comparison (stored in the
-  //     HashtableEntry structures).  This is used in the String.intern() method.
-  static unsigned int hash_string(const jchar* s, int len);
-  static unsigned int hash_string(oop string);
-
   // Internal test.
   static void test_alt_hash() PRODUCT_RETURN;
 
diff --git a/hotspot/src/share/vm/classfile/symbolTable.cpp b/hotspot/src/share/vm/classfile/symbolTable.cpp
index 5121fdbcd64..548be92bcad 100644
--- a/hotspot/src/share/vm/classfile/symbolTable.cpp
+++ b/hotspot/src/share/vm/classfile/symbolTable.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -98,7 +98,7 @@ int SymbolTable::_symbols_removed = 0;
 int SymbolTable::_symbols_counted = 0;
 volatile int SymbolTable::_parallel_claimed_idx = 0;
 
-void SymbolTable::buckets_unlink(int start_idx, int end_idx, int* processed, int* removed) {
+void SymbolTable::buckets_unlink(int start_idx, int end_idx, BucketUnlinkContext* context) {
   for (int i = start_idx; i < end_idx; ++i) {
     HashtableEntry** p = the_table()->bucket_addr(i);
     HashtableEntry* entry = the_table()->bucket(i);
@@ -111,15 +111,14 @@ void SymbolTable::buckets_unlink(int start_idx, int end_idx, int* processed, int
         break;
       }
       Symbol* s = entry->literal();
-      (*processed)++;
+      context->_num_processed++;
       assert(s != NULL, "just checking");
       // If reference count is zero, remove.
       if (s->refcount() == 0) {
         assert(!entry->is_shared(), "shared entries should be kept live");
         delete s;
-        (*removed)++;
         *p = entry->next();
-        the_table()->free_entry(entry);
+        context->free_entry(entry);
       } else {
         p = entry->next_addr();
       }
@@ -132,17 +131,20 @@ void SymbolTable::buckets_unlink(int start_idx, int end_idx, int* processed, int
 // Remove unreferenced symbols from the symbol table
 // This is done late during GC.
 void SymbolTable::unlink(int* processed, int* removed) {
-  size_t memory_total = 0;
-  buckets_unlink(0, the_table()->table_size(), processed, removed);
-  _symbols_removed += *removed;
-  _symbols_counted += *processed;
+  BucketUnlinkContext context;
+  buckets_unlink(0, the_table()->table_size(), &context);
+  _the_table->bulk_free_entries(&context);
+  *processed = context._num_processed;
+  *removed = context._num_removed;
+
+  _symbols_removed = context._num_removed;
+  _symbols_counted = context._num_processed;
 }
 
 void SymbolTable::possibly_parallel_unlink(int* processed, int* removed) {
   const int limit = the_table()->table_size();
 
-  size_t memory_total = 0;
-
+  BucketUnlinkContext context;
   for (;;) {
     // Grab next set of buckets to scan
     int start_idx = Atomic::add(ClaimChunkSize, &_parallel_claimed_idx) - ClaimChunkSize;
@@ -152,10 +154,15 @@ void SymbolTable::possibly_parallel_unlink(int* processed, int* removed) {
     }
 
     int end_idx = MIN2(limit, start_idx + ClaimChunkSize);
-    buckets_unlink(start_idx, end_idx, processed, removed);
+    buckets_unlink(start_idx, end_idx, &context);
   }
-  Atomic::add(*processed, &_symbols_counted);
-  Atomic::add(*removed, &_symbols_removed);
+
+  _the_table->bulk_free_entries(&context);
+  *processed = context._num_processed;
+  *removed = context._num_removed;
+
+  Atomic::add(context._num_processed, &_symbols_counted);
+  Atomic::add(context._num_removed, &_symbols_removed);
 }
 
 // Create a new table and using alternate hash code, populate the new table
diff --git a/hotspot/src/share/vm/classfile/symbolTable.hpp b/hotspot/src/share/vm/classfile/symbolTable.hpp
index e45ec753ef1..8e7b1362fff 100644
--- a/hotspot/src/share/vm/classfile/symbolTable.hpp
+++ b/hotspot/src/share/vm/classfile/symbolTable.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -154,8 +154,11 @@ private:
 
   static volatile int _parallel_claimed_idx;
 
-  // Release any dead symbols
-  static void buckets_unlink(int start_idx, int end_idx, int* processed, int* removed);
+  typedef SymbolTable::BucketUnlinkContext BucketUnlinkContext;
+  // Release any dead symbols. Unlinked bucket entries are collected in the given
+  // context to be freed later.
+  // This allows multiple threads to work on the table at once.
+  static void buckets_unlink(int start_idx, int end_idx, BucketUnlinkContext* context);
 public:
   enum {
     symbol_alloc_batch_size = 8,
diff --git a/hotspot/src/share/vm/classfile/systemDictionary.cpp b/hotspot/src/share/vm/classfile/systemDictionary.cpp
index e29fd131432..fd410851d33 100644
--- a/hotspot/src/share/vm/classfile/systemDictionary.cpp
+++ b/hotspot/src/share/vm/classfile/systemDictionary.cpp
@@ -1152,21 +1152,26 @@ Klass* SystemDictionary::resolve_from_stream(Symbol* class_name,
   Symbol* h_name = k->name();
   assert(class_name == NULL || class_name == h_name, "name mismatch");
 
-  bool define_succeeded = false;
   // Add class just loaded
   // If a class loader supports parallel classloading handle parallel define requests
   // find_or_define_instance_class may return a different InstanceKlass
   if (is_parallelCapable(class_loader)) {
-    instanceKlassHandle defined_k = find_or_define_instance_class(h_name, class_loader, k, CHECK_NULL);
-    if (k() == defined_k()) {
-      // we have won over other concurrent threads (if any) that are
-      // competing to define the same class.
-      define_succeeded = true;
+    instanceKlassHandle defined_k = find_or_define_instance_class(h_name, class_loader, k, THREAD);
+    if (!HAS_PENDING_EXCEPTION && defined_k() != k()) {
+      // If a parallel capable class loader already defined this class, register 'k' for cleanup.
+      assert(defined_k.not_null(), "Should have a klass if there's no exception");
+      loader_data->add_to_deallocate_list(k());
+      k = defined_k;
     }
-    k = defined_k;
   } else {
-    define_instance_class(k, CHECK_NULL);
-    define_succeeded = true;
+    define_instance_class(k, THREAD);
+  }
+
+  // If defining the class throws an exception register 'k' for cleanup.
+  if (HAS_PENDING_EXCEPTION) {
+    assert(k.not_null(), "Must have an instance klass here!");
+    loader_data->add_to_deallocate_list(k());
+    return NULL;
   }
 
   // Make sure we have an entry in the SystemDictionary on success
@@ -1518,8 +1523,16 @@ instanceKlassHandle SystemDictionary::load_instance_class(Symbol* class_name, Ha
     // find_or_define_instance_class may return a different InstanceKlass
     if (!k.is_null()) {
       instanceKlassHandle defined_k =
-        find_or_define_instance_class(class_name, class_loader, k, CHECK_(nh));
-      k = defined_k;
+        find_or_define_instance_class(class_name, class_loader, k, THREAD);
+      if (!HAS_PENDING_EXCEPTION && defined_k() != k()) {
+        // If a parallel capable class loader already defined this class, register 'k' for cleanup.
+        assert(defined_k.not_null(), "Should have a klass if there's no exception");
+        loader_data->add_to_deallocate_list(k());
+        k = defined_k;
+      } else if (HAS_PENDING_EXCEPTION) {
+        loader_data->add_to_deallocate_list(k());
+        return nh;
+      }
     }
     return k;
   } else {
diff --git a/hotspot/src/share/vm/classfile/systemDictionary.hpp b/hotspot/src/share/vm/classfile/systemDictionary.hpp
index 4cd5e40ffa8..f6ad7a4b347 100644
--- a/hotspot/src/share/vm/classfile/systemDictionary.hpp
+++ b/hotspot/src/share/vm/classfile/systemDictionary.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -133,9 +133,9 @@ class SymbolPropertyTable;
   do_klass(Thread_klass,                                java_lang_Thread,                          Pre                 ) \
   do_klass(ThreadGroup_klass,                           java_lang_ThreadGroup,                     Pre                 ) \
   do_klass(Properties_klass,                            java_util_Properties,                      Pre                 ) \
+  do_klass(Module_klass,                                java_lang_Module,                          Pre                 ) \
   do_klass(reflect_AccessibleObject_klass,              java_lang_reflect_AccessibleObject,        Pre                 ) \
   do_klass(reflect_Field_klass,                         java_lang_reflect_Field,                   Pre                 ) \
-  do_klass(reflect_Module_klass,                        java_lang_reflect_Module,                  Pre                 ) \
   do_klass(reflect_Parameter_klass,                     java_lang_reflect_Parameter,               Opt                 ) \
   do_klass(reflect_Method_klass,                        java_lang_reflect_Method,                  Pre                 ) \
   do_klass(reflect_Constructor_klass,                   java_lang_reflect_Constructor,             Pre                 ) \
diff --git a/hotspot/src/share/vm/classfile/vmSymbols.cpp b/hotspot/src/share/vm/classfile/vmSymbols.cpp
index ad17837fb0d..e56b4e95d6c 100644
--- a/hotspot/src/share/vm/classfile/vmSymbols.cpp
+++ b/hotspot/src/share/vm/classfile/vmSymbols.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -632,25 +632,28 @@ bool vmIntrinsics::is_disabled_by_flags(vmIntrinsics::ID id) {
   case vmIntrinsics::_loadFence:
   case vmIntrinsics::_storeFence:
   case vmIntrinsics::_fullFence:
-  case vmIntrinsics::_compareAndSwapLong:
-  case vmIntrinsics::_weakCompareAndSwapLong:
-  case vmIntrinsics::_weakCompareAndSwapLongAcquire:
-  case vmIntrinsics::_weakCompareAndSwapLongRelease:
-  case vmIntrinsics::_compareAndSwapInt:
-  case vmIntrinsics::_weakCompareAndSwapInt:
-  case vmIntrinsics::_weakCompareAndSwapIntAcquire:
-  case vmIntrinsics::_weakCompareAndSwapIntRelease:
-  case vmIntrinsics::_compareAndSwapObject:
-  case vmIntrinsics::_weakCompareAndSwapObject:
-  case vmIntrinsics::_weakCompareAndSwapObjectAcquire:
-  case vmIntrinsics::_weakCompareAndSwapObjectRelease:
-  case vmIntrinsics::_compareAndExchangeIntVolatile:
+  case vmIntrinsics::_compareAndSetLong:
+  case vmIntrinsics::_weakCompareAndSetLong:
+  case vmIntrinsics::_weakCompareAndSetLongPlain:
+  case vmIntrinsics::_weakCompareAndSetLongAcquire:
+  case vmIntrinsics::_weakCompareAndSetLongRelease:
+  case vmIntrinsics::_compareAndSetInt:
+  case vmIntrinsics::_weakCompareAndSetInt:
+  case vmIntrinsics::_weakCompareAndSetIntPlain:
+  case vmIntrinsics::_weakCompareAndSetIntAcquire:
+  case vmIntrinsics::_weakCompareAndSetIntRelease:
+  case vmIntrinsics::_compareAndSetObject:
+  case vmIntrinsics::_weakCompareAndSetObject:
+  case vmIntrinsics::_weakCompareAndSetObjectPlain:
+  case vmIntrinsics::_weakCompareAndSetObjectAcquire:
+  case vmIntrinsics::_weakCompareAndSetObjectRelease:
+  case vmIntrinsics::_compareAndExchangeInt:
   case vmIntrinsics::_compareAndExchangeIntAcquire:
   case vmIntrinsics::_compareAndExchangeIntRelease:
-  case vmIntrinsics::_compareAndExchangeLongVolatile:
+  case vmIntrinsics::_compareAndExchangeLong:
   case vmIntrinsics::_compareAndExchangeLongAcquire:
   case vmIntrinsics::_compareAndExchangeLongRelease:
-  case vmIntrinsics::_compareAndExchangeObjectVolatile:
+  case vmIntrinsics::_compareAndExchangeObject:
   case vmIntrinsics::_compareAndExchangeObjectAcquire:
   case vmIntrinsics::_compareAndExchangeObjectRelease:
     if (!InlineUnsafeOps) return true;
diff --git a/hotspot/src/share/vm/classfile/vmSymbols.hpp b/hotspot/src/share/vm/classfile/vmSymbols.hpp
index 0ef86447c4e..15aa3613422 100644
--- a/hotspot/src/share/vm/classfile/vmSymbols.hpp
+++ b/hotspot/src/share/vm/classfile/vmSymbols.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -56,6 +56,7 @@
   template(java_lang_Object,                          "java/lang/Object")                         \
   template(java_lang_Class,                           "java/lang/Class")                          \
   template(java_lang_Package,                         "java/lang/Package")                        \
+  template(java_lang_Module,                          "java/lang/Module")                         \
   template(java_lang_String,                          "java/lang/String")                         \
   template(java_lang_StringLatin1,                    "java/lang/StringLatin1")                   \
   template(java_lang_StringUTF16,                     "java/lang/StringUTF16")                    \
@@ -90,7 +91,6 @@
   template(java_lang_reflect_Method,                  "java/lang/reflect/Method")                 \
   template(java_lang_reflect_Constructor,             "java/lang/reflect/Constructor")            \
   template(java_lang_reflect_Field,                   "java/lang/reflect/Field")                  \
-  template(java_lang_reflect_Module,                  "java/lang/reflect/Module")                 \
   template(java_lang_reflect_Parameter,               "java/lang/reflect/Parameter")              \
   template(java_lang_reflect_Array,                   "java/lang/reflect/Array")                  \
   template(java_lang_StringBuffer,                    "java/lang/StringBuffer")                   \
@@ -136,7 +136,7 @@
   template(initPhase1_name,                           "initPhase1")                               \
   template(initPhase2_name,                           "initPhase2")                               \
   template(initPhase3_name,                           "initPhase3")                               \
-  template(java_lang_reflect_module_init_signature,   "(Ljava/lang/ClassLoader;Ljava/lang/String;)V") \
+  template(java_lang_module_init_signature,           "(Ljava/lang/ClassLoader;Ljava/lang/String;)V") \
                                                                                                   \
   /* class file format tags */                                                                    \
   template(tag_source_file,                           "SourceFile")                               \
@@ -325,14 +325,8 @@
   template(java_lang_StackStreamFactory_AbstractStackWalker, "java/lang/StackStreamFactory$AbstractStackWalker") \
   template(doStackWalk_signature,                     "(JIIII)Ljava/lang/Object;")                \
   template(asPrimitive_name,                          "asPrimitive")                              \
-  template(asPrimitive_int_signature,                 "(I)Ljava/lang/LiveStackFrame$PrimitiveValue;") \
-  template(asPrimitive_long_signature,                "(J)Ljava/lang/LiveStackFrame$PrimitiveValue;") \
-  template(asPrimitive_short_signature,               "(S)Ljava/lang/LiveStackFrame$PrimitiveValue;") \
-  template(asPrimitive_byte_signature,                "(B)Ljava/lang/LiveStackFrame$PrimitiveValue;") \
-  template(asPrimitive_char_signature,                "(C)Ljava/lang/LiveStackFrame$PrimitiveValue;") \
-  template(asPrimitive_float_signature,               "(F)Ljava/lang/LiveStackFrame$PrimitiveValue;") \
-  template(asPrimitive_double_signature,              "(D)Ljava/lang/LiveStackFrame$PrimitiveValue;") \
-  template(asPrimitive_boolean_signature,             "(Z)Ljava/lang/LiveStackFrame$PrimitiveValue;") \
+  template(asPrimitive_int_signature,                 "(I)Ljava/lang/LiveStackFrame$PrimitiveSlot;") \
+  template(asPrimitive_long_signature,                "(J)Ljava/lang/LiveStackFrame$PrimitiveSlot;") \
                                                                                                   \
   /* common method and field names */                                                             \
   template(object_initializer_name,                   "")                                   \
@@ -444,6 +438,7 @@
   template(monitors_name,                             "monitors")                                 \
   template(locals_name,                               "locals")                                   \
   template(operands_name,                             "operands")                                 \
+  template(mode_name,                                 "mode")                                     \
   template(oop_size_name,                             "oop_size")                                 \
   template(static_oop_field_count_name,               "static_oop_field_count")                   \
   template(protection_domain_name,                    "protection_domain")                        \
@@ -455,7 +450,7 @@
   template(getModule_name,                            "getModule")                                \
   template(input_stream_void_signature,               "(Ljava/io/InputStream;)V")                 \
   template(definePackage_name,                        "definePackage")                            \
-  template(definePackage_signature,                   "(Ljava/lang/String;Ljava/lang/reflect/Module;)Ljava/lang/Package;") \
+  template(definePackage_signature,                   "(Ljava/lang/String;Ljava/lang/Module;)Ljava/lang/Package;") \
   template(defineOrCheckPackage_name,                 "defineOrCheckPackage")                     \
   template(defineOrCheckPackage_signature,            "(Ljava/lang/String;Ljava/util/jar/Manifest;Ljava/net/URL;)Ljava/lang/Package;") \
   template(fileToEncodedURL_name,                     "fileToEncodedURL")                         \
@@ -537,7 +532,7 @@
   template(void_class_signature,                      "()Ljava/lang/Class;")                                      \
   template(void_class_array_signature,                "()[Ljava/lang/Class;")                                     \
   template(void_string_signature,                     "()Ljava/lang/String;")                                     \
-  template(void_module_signature,                     "()Ljava/lang/reflect/Module;")                             \
+  template(void_module_signature,                     "()Ljava/lang/Module;")                                     \
   template(object_array_object_signature,             "([Ljava/lang/Object;)Ljava/lang/Object;")                  \
   template(object_object_array_object_signature,      "(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;")\
   template(exception_void_signature,                  "(Ljava/lang/Exception;)V")                                 \
@@ -557,7 +552,7 @@
   template(reference_signature,                       "Ljava/lang/ref/Reference;")                                \
   template(sun_misc_Cleaner_signature,                "Lsun/misc/Cleaner;")                                       \
   template(executable_signature,                      "Ljava/lang/reflect/Executable;")                           \
-  template(module_signature,                          "Ljava/lang/reflect/Module;")                               \
+  template(module_signature,                          "Ljava/lang/Module;")                                       \
   template(concurrenthashmap_signature,               "Ljava/util/concurrent/ConcurrentHashMap;")                 \
   template(String_StringBuilder_signature,            "(Ljava/lang/String;)Ljava/lang/StringBuilder;")            \
   template(int_StringBuilder_signature,               "(I)Ljava/lang/StringBuilder;")                             \
@@ -566,6 +561,7 @@
   template(int_StringBuffer_signature,                "(I)Ljava/lang/StringBuffer;")                              \
   template(char_StringBuffer_signature,               "(C)Ljava/lang/StringBuffer;")                              \
   template(int_String_signature,                      "(I)Ljava/lang/String;")                                    \
+  template(boolean_boolean_int_signature,             "(ZZ)I")                                                    \
   template(codesource_permissioncollection_signature, "(Ljava/security/CodeSource;Ljava/security/PermissionCollection;)V") \
   /* signature symbols needed by intrinsics */                                                                    \
   VM_INTRINSICS_DO(VM_INTRINSIC_IGNORE, VM_SYMBOL_IGNORE, VM_SYMBOL_IGNORE, template, VM_ALIAS_IGNORE)            \
@@ -646,16 +642,18 @@
   template(jdk_internal_module_Modules,                "jdk/internal/module/Modules")                             \
   template(jdk_internal_vm_VMSupport,                  "jdk/internal/vm/VMSupport")                               \
   template(addReads_name,                              "addReads")                                                \
-  template(addReads_signature,                         "(Ljava/lang/reflect/Module;Ljava/lang/reflect/Module;)V") \
+  template(addReads_signature,                         "(Ljava/lang/Module;Ljava/lang/Module;)V")                 \
   template(addExports_name,                            "addExports")                                              \
   template(addOpens_name,                              "addOpens")                                                \
-  template(addExports_signature,                       "(Ljava/lang/reflect/Module;Ljava/lang/String;Ljava/lang/reflect/Module;)V") \
+  template(addExports_signature,                       "(Ljava/lang/Module;Ljava/lang/String;Ljava/lang/Module;)V") \
   template(addUses_name,                               "addUses")                                                 \
-  template(addUses_signature,                          "(Ljava/lang/reflect/Module;Ljava/lang/Class;)V")          \
+  template(addUses_signature,                          "(Ljava/lang/Module;Ljava/lang/Class;)V")                  \
   template(addProvides_name,                           "addProvides")                                             \
-  template(addProvides_signature,                      "(Ljava/lang/reflect/Module;Ljava/lang/Class;Ljava/lang/Class;)V") \
+  template(addProvides_signature,                      "(Ljava/lang/Module;Ljava/lang/Class;Ljava/lang/Class;)V") \
+  template(loadModule_name,                            "loadModule")                                              \
+  template(loadModule_signature,                       "(Ljava/lang/String;)Ljava/lang/Module;")                  \
   template(transformedByAgent_name,                    "transformedByAgent")                                      \
-  template(transformedByAgent_signature,               "(Ljava/lang/reflect/Module;)V")                           \
+  template(transformedByAgent_signature,               "(Ljava/lang/Module;)V")                                   \
   template(appendToClassPathForInstrumentation_name,   "appendToClassPathForInstrumentation")                     \
   do_alias(appendToClassPathForInstrumentation_signature, string_void_signature)                                  \
   template(serializePropertiesToByteArray_name,        "serializePropertiesToByteArray")                          \
@@ -1246,100 +1244,100 @@
   do_intrinsic(_putIntUnaligned,           jdk_internal_misc_Unsafe,    putIntUnaligned_name, putInt_signature,         F_R)  \
   do_intrinsic(_putLongUnaligned,          jdk_internal_misc_Unsafe,    putLongUnaligned_name, putLong_signature,       F_R)  \
                                                                                                                         \
-  do_signature(compareAndSwapObject_signature,     "(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z")        \
+  do_signature(compareAndSetObject_signature,      "(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z")        \
   do_signature(compareAndExchangeObject_signature, "(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;") \
-  do_signature(compareAndSwapLong_signature,       "(Ljava/lang/Object;JJJ)Z")                                          \
+  do_signature(compareAndSetLong_signature,        "(Ljava/lang/Object;JJJ)Z")                                          \
   do_signature(compareAndExchangeLong_signature,   "(Ljava/lang/Object;JJJ)J")                                          \
-  do_signature(compareAndSwapInt_signature,        "(Ljava/lang/Object;JII)Z")                                          \
+  do_signature(compareAndSetInt_signature,         "(Ljava/lang/Object;JII)Z")                                          \
   do_signature(compareAndExchangeInt_signature,    "(Ljava/lang/Object;JII)I")                                          \
-  do_signature(compareAndSwapByte_signature,       "(Ljava/lang/Object;JBB)Z")                                          \
+  do_signature(compareAndSetByte_signature,        "(Ljava/lang/Object;JBB)Z")                                          \
   do_signature(compareAndExchangeByte_signature,   "(Ljava/lang/Object;JBB)B")                                          \
-  do_signature(compareAndSwapShort_signature,      "(Ljava/lang/Object;JSS)Z")                                          \
+  do_signature(compareAndSetShort_signature,       "(Ljava/lang/Object;JSS)Z")                                          \
   do_signature(compareAndExchangeShort_signature,  "(Ljava/lang/Object;JSS)S")                                          \
                                                                                                                         \
-  do_name(compareAndSwapObject_name,             "compareAndSwapObject")                                                \
-  do_name(compareAndExchangeObjectVolatile_name, "compareAndExchangeObjectVolatile")                                    \
+  do_name(compareAndSetObject_name,              "compareAndSetObject")                                                 \
+  do_name(compareAndExchangeObject_name,         "compareAndExchangeObject")                                            \
   do_name(compareAndExchangeObjectAcquire_name,  "compareAndExchangeObjectAcquire")                                     \
   do_name(compareAndExchangeObjectRelease_name,  "compareAndExchangeObjectRelease")                                     \
-  do_name(compareAndSwapLong_name,               "compareAndSwapLong")                                                  \
-  do_name(compareAndExchangeLongVolatile_name,   "compareAndExchangeLongVolatile")                                      \
+  do_name(compareAndSetLong_name,                "compareAndSetLong")                                                   \
+  do_name(compareAndExchangeLong_name,           "compareAndExchangeLong")                                              \
   do_name(compareAndExchangeLongAcquire_name,    "compareAndExchangeLongAcquire")                                       \
   do_name(compareAndExchangeLongRelease_name,    "compareAndExchangeLongRelease")                                       \
-  do_name(compareAndSwapInt_name,                "compareAndSwapInt")                                                   \
-  do_name(compareAndExchangeIntVolatile_name,    "compareAndExchangeIntVolatile")                                       \
+  do_name(compareAndSetInt_name,                 "compareAndSetInt")                                                    \
+  do_name(compareAndExchangeInt_name,            "compareAndExchangeInt")                                               \
   do_name(compareAndExchangeIntAcquire_name,     "compareAndExchangeIntAcquire")                                        \
   do_name(compareAndExchangeIntRelease_name,     "compareAndExchangeIntRelease")                                        \
-  do_name(compareAndSwapByte_name,               "compareAndSwapByte")                                                  \
-  do_name(compareAndExchangeByteVolatile_name,   "compareAndExchangeByteVolatile")                                      \
+  do_name(compareAndSetByte_name,                "compareAndSetByte")                                                   \
+  do_name(compareAndExchangeByte_name,           "compareAndExchangeByte")                                              \
   do_name(compareAndExchangeByteAcquire_name,    "compareAndExchangeByteAcquire")                                       \
   do_name(compareAndExchangeByteRelease_name,    "compareAndExchangeByteRelease")                                       \
-  do_name(compareAndSwapShort_name,              "compareAndSwapShort")                                                 \
-  do_name(compareAndExchangeShortVolatile_name,  "compareAndExchangeShortVolatile")                                     \
+  do_name(compareAndSetShort_name,               "compareAndSetShort")                                                  \
+  do_name(compareAndExchangeShort_name,          "compareAndExchangeShort")                                             \
   do_name(compareAndExchangeShortAcquire_name,   "compareAndExchangeShortAcquire")                                      \
   do_name(compareAndExchangeShortRelease_name,   "compareAndExchangeShortRelease")                                      \
                                                                                                                         \
-  do_name(weakCompareAndSwapObject_name,         "weakCompareAndSwapObject")                                            \
-  do_name(weakCompareAndSwapObjectAcquire_name,  "weakCompareAndSwapObjectAcquire")                                     \
-  do_name(weakCompareAndSwapObjectRelease_name,  "weakCompareAndSwapObjectRelease")                                     \
-  do_name(weakCompareAndSwapObjectVolatile_name, "weakCompareAndSwapObjectVolatile")                                    \
-  do_name(weakCompareAndSwapLong_name,           "weakCompareAndSwapLong")                                              \
-  do_name(weakCompareAndSwapLongAcquire_name,    "weakCompareAndSwapLongAcquire")                                       \
-  do_name(weakCompareAndSwapLongRelease_name,    "weakCompareAndSwapLongRelease")                                       \
-  do_name(weakCompareAndSwapLongVolatile_name,   "weakCompareAndSwapLongVolatile")                                      \
-  do_name(weakCompareAndSwapInt_name,            "weakCompareAndSwapInt")                                               \
-  do_name(weakCompareAndSwapIntAcquire_name,     "weakCompareAndSwapIntAcquire")                                        \
-  do_name(weakCompareAndSwapIntRelease_name,     "weakCompareAndSwapIntRelease")                                        \
-  do_name(weakCompareAndSwapIntVolatile_name,    "weakCompareAndSwapIntVolatile")                                       \
-  do_name(weakCompareAndSwapByte_name,           "weakCompareAndSwapByte")                                              \
-  do_name(weakCompareAndSwapByteAcquire_name,    "weakCompareAndSwapByteAcquire")                                       \
-  do_name(weakCompareAndSwapByteRelease_name,    "weakCompareAndSwapByteRelease")                                       \
-  do_name(weakCompareAndSwapByteVolatile_name,   "weakCompareAndSwapByteVolatile")                                      \
-  do_name(weakCompareAndSwapShort_name,          "weakCompareAndSwapShort")                                             \
-  do_name(weakCompareAndSwapShortAcquire_name,   "weakCompareAndSwapShortAcquire")                                      \
-  do_name(weakCompareAndSwapShortRelease_name,   "weakCompareAndSwapShortRelease")                                      \
-  do_name(weakCompareAndSwapShortVolatile_name,  "weakCompareAndSwapShortVolatile")                                     \
+  do_name(weakCompareAndSetObjectPlain_name,     "weakCompareAndSetObjectPlain")                                        \
+  do_name(weakCompareAndSetObjectAcquire_name,   "weakCompareAndSetObjectAcquire")                                      \
+  do_name(weakCompareAndSetObjectRelease_name,   "weakCompareAndSetObjectRelease")                                      \
+  do_name(weakCompareAndSetObject_name,          "weakCompareAndSetObject")                                             \
+  do_name(weakCompareAndSetLongPlain_name,       "weakCompareAndSetLongPlain")                                          \
+  do_name(weakCompareAndSetLongAcquire_name,     "weakCompareAndSetLongAcquire")                                        \
+  do_name(weakCompareAndSetLongRelease_name,     "weakCompareAndSetLongRelease")                                        \
+  do_name(weakCompareAndSetLong_name,            "weakCompareAndSetLong")                                               \
+  do_name(weakCompareAndSetIntPlain_name,        "weakCompareAndSetIntPlain")                                           \
+  do_name(weakCompareAndSetIntAcquire_name,      "weakCompareAndSetIntAcquire")                                         \
+  do_name(weakCompareAndSetIntRelease_name,      "weakCompareAndSetIntRelease")                                         \
+  do_name(weakCompareAndSetInt_name,             "weakCompareAndSetInt")                                                \
+  do_name(weakCompareAndSetBytePlain_name,       "weakCompareAndSetBytePlain")                                          \
+  do_name(weakCompareAndSetByteAcquire_name,     "weakCompareAndSetByteAcquire")                                        \
+  do_name(weakCompareAndSetByteRelease_name,     "weakCompareAndSetByteRelease")                                        \
+  do_name(weakCompareAndSetByte_name,            "weakCompareAndSetByte")                                               \
+  do_name(weakCompareAndSetShortPlain_name,      "weakCompareAndSetShortPlain")                                         \
+  do_name(weakCompareAndSetShortAcquire_name,    "weakCompareAndSetShortAcquire")                                       \
+  do_name(weakCompareAndSetShortRelease_name,    "weakCompareAndSetShortRelease")                                       \
+  do_name(weakCompareAndSetShort_name,           "weakCompareAndSetShort")                                              \
                                                                                                                         \
-  do_intrinsic(_compareAndSwapObject,             jdk_internal_misc_Unsafe,  compareAndSwapObject_name,             compareAndSwapObject_signature,     F_RN) \
-  do_intrinsic(_compareAndExchangeObjectVolatile, jdk_internal_misc_Unsafe,  compareAndExchangeObjectVolatile_name, compareAndExchangeObject_signature, F_RN) \
+  do_intrinsic(_compareAndSetObject,              jdk_internal_misc_Unsafe,  compareAndSetObject_name,              compareAndSetObject_signature,      F_RN) \
+  do_intrinsic(_compareAndExchangeObject,         jdk_internal_misc_Unsafe,  compareAndExchangeObject_name,         compareAndExchangeObject_signature, F_RN) \
   do_intrinsic(_compareAndExchangeObjectAcquire,  jdk_internal_misc_Unsafe,  compareAndExchangeObjectAcquire_name,  compareAndExchangeObject_signature, F_R)  \
   do_intrinsic(_compareAndExchangeObjectRelease,  jdk_internal_misc_Unsafe,  compareAndExchangeObjectRelease_name,  compareAndExchangeObject_signature, F_R)  \
-  do_intrinsic(_compareAndSwapLong,               jdk_internal_misc_Unsafe,  compareAndSwapLong_name,               compareAndSwapLong_signature,       F_RN) \
-  do_intrinsic(_compareAndExchangeLongVolatile,   jdk_internal_misc_Unsafe,  compareAndExchangeLongVolatile_name,   compareAndExchangeLong_signature,   F_RN) \
+  do_intrinsic(_compareAndSetLong,                jdk_internal_misc_Unsafe,  compareAndSetLong_name,                compareAndSetLong_signature,        F_RN) \
+  do_intrinsic(_compareAndExchangeLong,           jdk_internal_misc_Unsafe,  compareAndExchangeLong_name,           compareAndExchangeLong_signature,   F_RN) \
   do_intrinsic(_compareAndExchangeLongAcquire,    jdk_internal_misc_Unsafe,  compareAndExchangeLongAcquire_name,    compareAndExchangeLong_signature,   F_R)  \
   do_intrinsic(_compareAndExchangeLongRelease,    jdk_internal_misc_Unsafe,  compareAndExchangeLongRelease_name,    compareAndExchangeLong_signature,   F_R)  \
-  do_intrinsic(_compareAndSwapInt,                jdk_internal_misc_Unsafe,  compareAndSwapInt_name,                compareAndSwapInt_signature,        F_RN) \
-  do_intrinsic(_compareAndExchangeIntVolatile,    jdk_internal_misc_Unsafe,  compareAndExchangeIntVolatile_name,    compareAndExchangeInt_signature,    F_RN) \
+  do_intrinsic(_compareAndSetInt,                 jdk_internal_misc_Unsafe,  compareAndSetInt_name,                 compareAndSetInt_signature,         F_RN) \
+  do_intrinsic(_compareAndExchangeInt,            jdk_internal_misc_Unsafe,  compareAndExchangeInt_name,            compareAndExchangeInt_signature,    F_RN) \
   do_intrinsic(_compareAndExchangeIntAcquire,     jdk_internal_misc_Unsafe,  compareAndExchangeIntAcquire_name,     compareAndExchangeInt_signature,    F_R)  \
   do_intrinsic(_compareAndExchangeIntRelease,     jdk_internal_misc_Unsafe,  compareAndExchangeIntRelease_name,     compareAndExchangeInt_signature,    F_R)  \
-  do_intrinsic(_compareAndSwapByte,               jdk_internal_misc_Unsafe,  compareAndSwapByte_name,               compareAndSwapByte_signature,       F_R)  \
-  do_intrinsic(_compareAndExchangeByteVolatile,   jdk_internal_misc_Unsafe,  compareAndExchangeByteVolatile_name,   compareAndExchangeByte_signature,   F_R)  \
+  do_intrinsic(_compareAndSetByte,                jdk_internal_misc_Unsafe,  compareAndSetByte_name,                compareAndSetByte_signature,        F_R)  \
+  do_intrinsic(_compareAndExchangeByte,           jdk_internal_misc_Unsafe,  compareAndExchangeByte_name,           compareAndExchangeByte_signature,   F_R)  \
   do_intrinsic(_compareAndExchangeByteAcquire,    jdk_internal_misc_Unsafe,  compareAndExchangeByteAcquire_name,    compareAndExchangeByte_signature,   F_R)  \
   do_intrinsic(_compareAndExchangeByteRelease,    jdk_internal_misc_Unsafe,  compareAndExchangeByteRelease_name,    compareAndExchangeByte_signature,   F_R)  \
-  do_intrinsic(_compareAndSwapShort,              jdk_internal_misc_Unsafe,  compareAndSwapShort_name,              compareAndSwapShort_signature,      F_R)  \
-  do_intrinsic(_compareAndExchangeShortVolatile,  jdk_internal_misc_Unsafe,  compareAndExchangeShortVolatile_name,  compareAndExchangeShort_signature,  F_R)  \
+  do_intrinsic(_compareAndSetShort,               jdk_internal_misc_Unsafe,  compareAndSetShort_name,               compareAndSetShort_signature,       F_R)  \
+  do_intrinsic(_compareAndExchangeShort,          jdk_internal_misc_Unsafe,  compareAndExchangeShort_name,          compareAndExchangeShort_signature,  F_R)  \
   do_intrinsic(_compareAndExchangeShortAcquire,   jdk_internal_misc_Unsafe,  compareAndExchangeShortAcquire_name,   compareAndExchangeShort_signature,  F_R)  \
   do_intrinsic(_compareAndExchangeShortRelease,   jdk_internal_misc_Unsafe,  compareAndExchangeShortRelease_name,   compareAndExchangeShort_signature,  F_R)  \
                                                                                                                                                              \
-  do_intrinsic(_weakCompareAndSwapObject,         jdk_internal_misc_Unsafe,  weakCompareAndSwapObject_name,         compareAndSwapObject_signature,     F_R) \
-  do_intrinsic(_weakCompareAndSwapObjectAcquire,  jdk_internal_misc_Unsafe,  weakCompareAndSwapObjectAcquire_name,  compareAndSwapObject_signature,     F_R) \
-  do_intrinsic(_weakCompareAndSwapObjectRelease,  jdk_internal_misc_Unsafe,  weakCompareAndSwapObjectRelease_name,  compareAndSwapObject_signature,     F_R) \
-  do_intrinsic(_weakCompareAndSwapObjectVolatile, jdk_internal_misc_Unsafe,  weakCompareAndSwapObjectVolatile_name, compareAndSwapObject_signature,     F_R) \
-  do_intrinsic(_weakCompareAndSwapLong,           jdk_internal_misc_Unsafe,  weakCompareAndSwapLong_name,           compareAndSwapLong_signature,       F_R) \
-  do_intrinsic(_weakCompareAndSwapLongAcquire,    jdk_internal_misc_Unsafe,  weakCompareAndSwapLongAcquire_name,    compareAndSwapLong_signature,       F_R) \
-  do_intrinsic(_weakCompareAndSwapLongRelease,    jdk_internal_misc_Unsafe,  weakCompareAndSwapLongRelease_name,    compareAndSwapLong_signature,       F_R) \
-  do_intrinsic(_weakCompareAndSwapLongVolatile,   jdk_internal_misc_Unsafe,  weakCompareAndSwapLongVolatile_name,   compareAndSwapLong_signature,       F_R) \
-  do_intrinsic(_weakCompareAndSwapInt,            jdk_internal_misc_Unsafe,  weakCompareAndSwapInt_name,            compareAndSwapInt_signature,        F_R) \
-  do_intrinsic(_weakCompareAndSwapIntAcquire,     jdk_internal_misc_Unsafe,  weakCompareAndSwapIntAcquire_name,     compareAndSwapInt_signature,        F_R) \
-  do_intrinsic(_weakCompareAndSwapIntRelease,     jdk_internal_misc_Unsafe,  weakCompareAndSwapIntRelease_name,     compareAndSwapInt_signature,        F_R) \
-  do_intrinsic(_weakCompareAndSwapIntVolatile,    jdk_internal_misc_Unsafe,  weakCompareAndSwapIntVolatile_name,    compareAndSwapInt_signature,        F_R) \
-  do_intrinsic(_weakCompareAndSwapByte,           jdk_internal_misc_Unsafe,  weakCompareAndSwapByte_name,           compareAndSwapByte_signature,       F_R) \
-  do_intrinsic(_weakCompareAndSwapByteAcquire,    jdk_internal_misc_Unsafe,  weakCompareAndSwapByteAcquire_name,    compareAndSwapByte_signature,       F_R) \
-  do_intrinsic(_weakCompareAndSwapByteRelease,    jdk_internal_misc_Unsafe,  weakCompareAndSwapByteRelease_name,    compareAndSwapByte_signature,       F_R) \
-  do_intrinsic(_weakCompareAndSwapByteVolatile,   jdk_internal_misc_Unsafe,  weakCompareAndSwapByteVolatile_name,   compareAndSwapByte_signature,       F_R) \
-  do_intrinsic(_weakCompareAndSwapShort,          jdk_internal_misc_Unsafe,  weakCompareAndSwapShort_name,          compareAndSwapShort_signature,      F_R) \
-  do_intrinsic(_weakCompareAndSwapShortAcquire,   jdk_internal_misc_Unsafe,  weakCompareAndSwapShortAcquire_name,   compareAndSwapShort_signature,      F_R) \
-  do_intrinsic(_weakCompareAndSwapShortRelease,   jdk_internal_misc_Unsafe,  weakCompareAndSwapShortRelease_name,   compareAndSwapShort_signature,      F_R) \
-  do_intrinsic(_weakCompareAndSwapShortVolatile,  jdk_internal_misc_Unsafe,  weakCompareAndSwapShortVolatile_name,  compareAndSwapShort_signature,      F_R) \
+  do_intrinsic(_weakCompareAndSetObjectPlain,     jdk_internal_misc_Unsafe,  weakCompareAndSetObjectPlain_name,     compareAndSetObject_signature,      F_R) \
+  do_intrinsic(_weakCompareAndSetObjectAcquire,   jdk_internal_misc_Unsafe,  weakCompareAndSetObjectAcquire_name,   compareAndSetObject_signature,      F_R) \
+  do_intrinsic(_weakCompareAndSetObjectRelease,   jdk_internal_misc_Unsafe,  weakCompareAndSetObjectRelease_name,   compareAndSetObject_signature,      F_R) \
+  do_intrinsic(_weakCompareAndSetObject,          jdk_internal_misc_Unsafe,  weakCompareAndSetObject_name,          compareAndSetObject_signature,      F_R) \
+  do_intrinsic(_weakCompareAndSetLongPlain,       jdk_internal_misc_Unsafe,  weakCompareAndSetLongPlain_name,       compareAndSetLong_signature,        F_R) \
+  do_intrinsic(_weakCompareAndSetLongAcquire,     jdk_internal_misc_Unsafe,  weakCompareAndSetLongAcquire_name,     compareAndSetLong_signature,        F_R) \
+  do_intrinsic(_weakCompareAndSetLongRelease,     jdk_internal_misc_Unsafe,  weakCompareAndSetLongRelease_name,     compareAndSetLong_signature,        F_R) \
+  do_intrinsic(_weakCompareAndSetLong,            jdk_internal_misc_Unsafe,  weakCompareAndSetLong_name,            compareAndSetLong_signature,        F_R) \
+  do_intrinsic(_weakCompareAndSetIntPlain,        jdk_internal_misc_Unsafe,  weakCompareAndSetIntPlain_name,        compareAndSetInt_signature,         F_R) \
+  do_intrinsic(_weakCompareAndSetIntAcquire,      jdk_internal_misc_Unsafe,  weakCompareAndSetIntAcquire_name,      compareAndSetInt_signature,         F_R) \
+  do_intrinsic(_weakCompareAndSetIntRelease,      jdk_internal_misc_Unsafe,  weakCompareAndSetIntRelease_name,      compareAndSetInt_signature,         F_R) \
+  do_intrinsic(_weakCompareAndSetInt,             jdk_internal_misc_Unsafe,  weakCompareAndSetInt_name,             compareAndSetInt_signature,         F_R) \
+  do_intrinsic(_weakCompareAndSetBytePlain,       jdk_internal_misc_Unsafe,  weakCompareAndSetBytePlain_name,       compareAndSetByte_signature,        F_R) \
+  do_intrinsic(_weakCompareAndSetByteAcquire,     jdk_internal_misc_Unsafe,  weakCompareAndSetByteAcquire_name,     compareAndSetByte_signature,        F_R) \
+  do_intrinsic(_weakCompareAndSetByteRelease,     jdk_internal_misc_Unsafe,  weakCompareAndSetByteRelease_name,     compareAndSetByte_signature,        F_R) \
+  do_intrinsic(_weakCompareAndSetByte,            jdk_internal_misc_Unsafe,  weakCompareAndSetByte_name,            compareAndSetByte_signature,        F_R) \
+  do_intrinsic(_weakCompareAndSetShortPlain,      jdk_internal_misc_Unsafe,  weakCompareAndSetShortPlain_name,      compareAndSetShort_signature,       F_R) \
+  do_intrinsic(_weakCompareAndSetShortAcquire,    jdk_internal_misc_Unsafe,  weakCompareAndSetShortAcquire_name,    compareAndSetShort_signature,       F_R) \
+  do_intrinsic(_weakCompareAndSetShortRelease,    jdk_internal_misc_Unsafe,  weakCompareAndSetShortRelease_name,    compareAndSetShort_signature,       F_R) \
+  do_intrinsic(_weakCompareAndSetShort,           jdk_internal_misc_Unsafe,  weakCompareAndSetShort_name,           compareAndSetShort_signature,       F_R) \
                            \
   do_intrinsic(_getAndAddInt,             jdk_internal_misc_Unsafe,     getAndAddInt_name, getAndAddInt_signature, F_R)       \
    do_name(     getAndAddInt_name,                                      "getAndAddInt")                                       \
diff --git a/hotspot/src/share/vm/code/codeCache.cpp b/hotspot/src/share/vm/code/codeCache.cpp
index bfe643ab683..549535b7aa0 100644
--- a/hotspot/src/share/vm/code/codeCache.cpp
+++ b/hotspot/src/share/vm/code/codeCache.cpp
@@ -417,7 +417,7 @@ void CodeCache::add_heap(ReservedSpace rs, const char* name, int code_blob_type)
 CodeHeap* CodeCache::get_code_heap(const CodeBlob* cb) {
   assert(cb != NULL, "CodeBlob is null");
   FOR_ALL_HEAPS(heap) {
-    if ((*heap)->contains(cb->code_begin())) {
+    if ((*heap)->contains_blob(cb)) {
       return *heap;
     }
   }
@@ -1211,7 +1211,7 @@ void CodeCache::make_marked_nmethods_not_entrant() {
   CompiledMethodIterator iter;
   while(iter.next_alive()) {
     CompiledMethod* nm = iter.method();
-    if (nm->is_marked_for_deoptimization()) {
+    if (nm->is_marked_for_deoptimization() && !nm->is_not_entrant()) {
       nm->make_not_entrant();
     }
   }
diff --git a/hotspot/src/share/vm/code/codeCache.hpp b/hotspot/src/share/vm/code/codeCache.hpp
index 99209dc3c66..469ac0af329 100644
--- a/hotspot/src/share/vm/code/codeCache.hpp
+++ b/hotspot/src/share/vm/code/codeCache.hpp
@@ -304,11 +304,10 @@ template  class CodeBlobIterator : public StackObj {
     // If set to NULL, initialized by first call to next()
     _code_blob = (CodeBlob*)nm;
     if (nm != NULL) {
-      address start = nm->code_begin();
-      while(!(*_heap)->contains(start)) {
+      while(!(*_heap)->contains_blob(_code_blob)) {
         ++_heap;
       }
-      assert((*_heap)->contains(start), "match not found");
+      assert((*_heap)->contains_blob(_code_blob), "match not found");
     }
   }
 
diff --git a/hotspot/src/share/vm/code/nmethod.cpp b/hotspot/src/share/vm/code/nmethod.cpp
index 71420040970..f82872baf1c 100644
--- a/hotspot/src/share/vm/code/nmethod.cpp
+++ b/hotspot/src/share/vm/code/nmethod.cpp
@@ -1146,6 +1146,14 @@ bool nmethod::make_not_entrant_or_zombie(unsigned int state) {
   assert(state == zombie || state == not_entrant, "must be zombie or not_entrant");
   assert(!is_zombie(), "should not already be a zombie");
 
+  if (_state == state) {
+    // Avoid taking the lock if already in required state.
+    // This is safe from races because the state is an end-state,
+    // which the nmethod cannot back out of once entered.
+    // No need for fencing either.
+    return false;
+  }
+
   // Make sure neither the nmethod nor the method is flushed in case of a safepoint in code below.
   nmethodLocker nml(this);
   methodHandle the_method(method());
diff --git a/hotspot/src/share/vm/code/relocInfo.cpp b/hotspot/src/share/vm/code/relocInfo.cpp
index d9c095e4413..03c706b9ac4 100644
--- a/hotspot/src/share/vm/code/relocInfo.cpp
+++ b/hotspot/src/share/vm/code/relocInfo.cpp
@@ -129,9 +129,9 @@ void RelocIterator::initialize(CompiledMethod* nm, address begin, address limit)
   if (nm == NULL && begin != NULL) {
     // allow nmethod to be deduced from beginning address
     CodeBlob* cb = CodeCache::find_blob(begin);
-    nm = cb->as_compiled_method_or_null();
+    nm = (cb != NULL) ? cb->as_compiled_method_or_null() : NULL;
   }
-  assert(nm != NULL, "must be able to deduce nmethod from other arguments");
+  guarantee(nm != NULL, "must be able to deduce nmethod from other arguments");
 
   _code    = nm;
   _current = nm->relocation_begin() - 1;
diff --git a/hotspot/src/share/vm/compiler/compilerDefinitions.cpp b/hotspot/src/share/vm/compiler/compilerDefinitions.cpp
index 00c2e64f851..bcec3ffa20d 100644
--- a/hotspot/src/share/vm/compiler/compilerDefinitions.cpp
+++ b/hotspot/src/share/vm/compiler/compilerDefinitions.cpp
@@ -100,7 +100,9 @@ void set_client_compilation_mode() {
     FLAG_SET_ERGO(size_t, MetaspaceSize, 12*M);
   }
   if (FLAG_IS_DEFAULT(MaxRAM)) {
-    FLAG_SET_ERGO(uint64_t, MaxRAM, 1ULL*G);
+    // Do not use FLAG_SET_ERGO to update MaxRAM, as this will impact
+    // heap setting done based on available phys_mem (see Arguments::set_heap_size).
+    FLAG_SET_DEFAULT(MaxRAM, 1ULL*G);
   }
   if (FLAG_IS_DEFAULT(CompileThreshold)) {
     FLAG_SET_ERGO(intx, CompileThreshold, 1500);
diff --git a/hotspot/src/share/vm/compiler/oopMap.cpp b/hotspot/src/share/vm/compiler/oopMap.cpp
index 378198ecb9b..fd94440d3f2 100644
--- a/hotspot/src/share/vm/compiler/oopMap.cpp
+++ b/hotspot/src/share/vm/compiler/oopMap.cpp
@@ -350,16 +350,14 @@ void OopMapSet::all_do(const frame *fr, const RegisterMap *reg_map,
         omv = oms.current();
         oop* loc = fr->oopmapreg_to_location(omv.reg(),reg_map);
         guarantee(loc != NULL, "missing saved register");
-        oop *base_loc    = fr->oopmapreg_to_location(omv.content_reg(), reg_map);
         oop *derived_loc = loc;
-        oop val = *base_loc;
-        if (val == (oop)NULL || Universe::is_narrow_oop_base(val)) {
-          // Ignore NULL oops and decoded NULL narrow oops which
-          // equal to Universe::narrow_oop_base when a narrow oop
-          // implicit null check is used in compiled code.
-          // The narrow_oop_base could be NULL or be the address
-          // of the page below heap depending on compressed oops mode.
-        } else {
+        oop *base_loc    = fr->oopmapreg_to_location(omv.content_reg(), reg_map);
+        // Ignore NULL oops and decoded NULL narrow oops which
+        // equal to Universe::narrow_oop_base when a narrow oop
+        // implicit null check is used in compiled code.
+        // The narrow_oop_base could be NULL or be the address
+        // of the page below heap depending on compressed oops mode.
+        if (base_loc != NULL && *base_loc != (oop)NULL && !Universe::is_narrow_oop_base(*base_loc)) {
           derived_oop_fn(base_loc, derived_loc);
         }
         oms.next();
diff --git a/hotspot/src/share/vm/gc/cms/concurrentMarkSweepGeneration.cpp b/hotspot/src/share/vm/gc/cms/concurrentMarkSweepGeneration.cpp
index 1cc6a5ea1e9..4effbf42d11 100644
--- a/hotspot/src/share/vm/gc/cms/concurrentMarkSweepGeneration.cpp
+++ b/hotspot/src/share/vm/gc/cms/concurrentMarkSweepGeneration.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -488,9 +488,6 @@ CMSCollector::CMSCollector(ConcurrentMarkSweepGeneration* cmsGen,
   _gc_timer_cm(new (ResourceObj::C_HEAP, mtGC) ConcurrentGCTimer()),
   _cms_start_registered(false)
 {
-  if (ExplicitGCInvokesConcurrentAndUnloadsClasses) {
-    ExplicitGCInvokesConcurrent = true;
-  }
   // Now expand the span and allocate the collection support structures
   // (MUT, marking bit map etc.) to cover both generations subject to
   // collection.
@@ -2559,10 +2556,8 @@ void CMSCollector::verify_overflow_empty() const {
 // Decide if we want to enable class unloading as part of the
 // ensuing concurrent GC cycle. We will collect and
 // unload classes if it's the case that:
-// (1) an explicit gc request has been made and the flag
-//     ExplicitGCInvokesConcurrentAndUnloadsClasses is set, OR
-// (2) (a) class unloading is enabled at the command line, and
-//     (b) old gen is getting really full
+//  (a) class unloading is enabled at the command line, and
+//  (b) old gen is getting really full
 // NOTE: Provided there is no change in the state of the heap between
 // calls to this method, it should have idempotent results. Moreover,
 // its results should be monotonically increasing (i.e. going from 0 to 1,
@@ -2575,11 +2570,7 @@ void CMSCollector::verify_overflow_empty() const {
 // below.
 void CMSCollector::update_should_unload_classes() {
   _should_unload_classes = false;
-  // Condition 1 above
-  if (_full_gc_requested && ExplicitGCInvokesConcurrentAndUnloadsClasses) {
-    _should_unload_classes = true;
-  } else if (CMSClassUnloadingEnabled) { // Condition 2.a above
-    // Disjuncts 2.b.(i,ii,iii) above
+  if (CMSClassUnloadingEnabled) {
     _should_unload_classes = (concurrent_cycles_since_last_unload() >=
                               CMSClassUnloadingMaxInterval)
                            || _cmsGen->is_too_full();
diff --git a/hotspot/src/share/vm/gc/g1/heapRegionRemSet.cpp b/hotspot/src/share/vm/gc/g1/heapRegionRemSet.cpp
index 7967d6cf001..6015b16c3e2 100644
--- a/hotspot/src/share/vm/gc/g1/heapRegionRemSet.cpp
+++ b/hotspot/src/share/vm/gc/g1/heapRegionRemSet.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -711,29 +711,6 @@ void HeapRegionRemSet::setup_remset_size() {
   guarantee(G1RSetSparseRegionEntries > 0 && G1RSetRegionEntries > 0 , "Sanity");
 }
 
-#ifndef PRODUCT
-void HeapRegionRemSet::print() {
-  HeapRegionRemSetIterator iter(this);
-  size_t card_index;
-  while (iter.has_next(card_index)) {
-    HeapWord* card_start = _bot->address_for_index(card_index);
-    tty->print_cr("  Card " PTR_FORMAT, p2i(card_start));
-  }
-  if (iter.n_yielded() != occupied()) {
-    tty->print_cr("Yielded disagrees with occupied:");
-    tty->print_cr("  " SIZE_FORMAT_W(6) " yielded (" SIZE_FORMAT_W(6)
-                  " coarse, " SIZE_FORMAT_W(6) " fine).",
-                  iter.n_yielded(),
-                  iter.n_yielded_coarse(), iter.n_yielded_fine());
-    tty->print_cr("  " SIZE_FORMAT_W(6) " occ     (" SIZE_FORMAT_W(6)
-                           " coarse, " SIZE_FORMAT_W(6) " fine).",
-                  occupied(), occ_coarse(), occ_fine());
-  }
-  guarantee(iter.n_yielded() == occupied(),
-            "We should have yielded all the represented cards.");
-}
-#endif
-
 void HeapRegionRemSet::cleanup() {
   SparsePRT::cleanup_all();
 }
@@ -917,10 +894,6 @@ bool HeapRegionRemSetIterator::has_next(size_t& card_index) {
     // Otherwise...
     break;
   }
-  assert(ParallelGCThreads > 1 ||
-         n_yielded() == _hrrs->occupied(),
-         "Should have yielded all the cards in the rem set "
-         "(in the non-par case).");
   return false;
 }
 
diff --git a/hotspot/src/share/vm/gc/g1/heapRegionRemSet.hpp b/hotspot/src/share/vm/gc/g1/heapRegionRemSet.hpp
index 7f740b692c8..97c7e0643ea 100644
--- a/hotspot/src/share/vm/gc/g1/heapRegionRemSet.hpp
+++ b/hotspot/src/share/vm/gc/g1/heapRegionRemSet.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -290,8 +290,6 @@ public:
   // consumed by the strong code roots.
   size_t strong_code_roots_mem_size();
 
-  void print() PRODUCT_RETURN;
-
   // Called during a stop-world phase to perform any deferred cleanups.
   static void cleanup();
 
diff --git a/hotspot/src/share/vm/gc/parallel/gcTaskThread.cpp b/hotspot/src/share/vm/gc/parallel/gcTaskThread.cpp
index 48eb3c4163d..e300f8c2309 100644
--- a/hotspot/src/share/vm/gc/parallel/gcTaskThread.cpp
+++ b/hotspot/src/share/vm/gc/parallel/gcTaskThread.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -54,8 +54,26 @@ GCTaskThread::~GCTaskThread() {
   }
 }
 
+void GCTaskThread::add_task_timestamp(const char* name, jlong t_entry, jlong t_exit) {
+  if (_time_stamp_index < GCTaskTimeStampEntries) {
+    GCTaskTimeStamp* time_stamp = time_stamp_at(_time_stamp_index);
+    time_stamp->set_name(name);
+    time_stamp->set_entry_time(t_entry);
+    time_stamp->set_exit_time(t_exit);
+  } else {
+    if (_time_stamp_index ==  GCTaskTimeStampEntries) {
+      log_warning(gc, task, time)("GC-thread %u: Too many timestamps, ignoring future ones. "
+                                  "Increase GCTaskTimeStampEntries to get more info.",
+                                  id());
+    }
+    // Let _time_stamp_index keep counting to give the user an idea about how many
+    // are needed.
+  }
+  _time_stamp_index++;
+}
+
 GCTaskTimeStamp* GCTaskThread::time_stamp_at(uint index) {
-  guarantee(index < GCTaskTimeStampEntries, "increase GCTaskTimeStampEntries");
+  assert(index < GCTaskTimeStampEntries, "Precondition");
   if (_time_stamps == NULL) {
     // We allocate the _time_stamps array lazily since logging can be enabled dynamically
     GCTaskTimeStamp* time_stamps = NEW_C_HEAP_ARRAY(GCTaskTimeStamp, GCTaskTimeStampEntries, mtGC);
@@ -65,7 +83,6 @@ GCTaskTimeStamp* GCTaskThread::time_stamp_at(uint index) {
       FREE_C_HEAP_ARRAY(GCTaskTimeStamp, time_stamps);
     }
   }
-
   return &(_time_stamps[index]);
 }
 
@@ -75,8 +92,11 @@ void GCTaskThread::print_task_time_stamps() {
   // Since _time_stamps is now lazily allocated we need to check that it
   // has in fact been allocated when calling this function.
   if (_time_stamps != NULL) {
-    log_debug(gc, task, time)("GC-Thread %u entries: %d", id(), _time_stamp_index);
-    for(uint i=0; i<_time_stamp_index; i++) {
+    log_debug(gc, task, time)("GC-Thread %u entries: %d%s", id(),
+                              _time_stamp_index,
+                              _time_stamp_index >= GCTaskTimeStampEntries ? " (overflow)" : "");
+    const uint max_index = MIN2(_time_stamp_index, GCTaskTimeStampEntries);
+    for (uint i = 0; i < max_index; i++) {
       GCTaskTimeStamp* time_stamp = time_stamp_at(i);
       log_debug(gc, task, time)("\t[ %s " JLONG_FORMAT " " JLONG_FORMAT " ]",
                                 time_stamp->name(),
@@ -144,16 +164,7 @@ void GCTaskThread::run() {
 
         if (log_is_enabled(Debug, gc, task, time)) {
           timer.update();
-
-          GCTaskTimeStamp* time_stamp = time_stamp_at(_time_stamp_index);
-
-          time_stamp->set_name(name);
-          time_stamp->set_entry_time(entry_time);
-          time_stamp->set_exit_time(timer.ticks());
-
-          // Update the index after we have set up the entry correctly since
-          // GCTaskThread::print_task_time_stamps() may read this value concurrently.
-          _time_stamp_index++;
+          add_task_timestamp(name, entry_time, timer.ticks());
         }
       } else {
         // idle tasks complete outside the normal accounting
diff --git a/hotspot/src/share/vm/gc/parallel/gcTaskThread.hpp b/hotspot/src/share/vm/gc/parallel/gcTaskThread.hpp
index 59e6286f26e..d4fbe4b96b7 100644
--- a/hotspot/src/share/vm/gc/parallel/gcTaskThread.hpp
+++ b/hotspot/src/share/vm/gc/parallel/gcTaskThread.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -45,6 +45,7 @@ private:
   uint _time_stamp_index;
 
   GCTaskTimeStamp* time_stamp_at(uint index);
+  void add_task_timestamp(const char* name, jlong t_entry, jlong t_exit);
 
   bool _is_working;                     // True if participating in GC tasks
 
@@ -92,16 +93,16 @@ class GCTaskTimeStamp : public CHeapObj
  private:
   jlong  _entry_time;
   jlong  _exit_time;
-  char*  _name;
+  const char*  _name;
 
  public:
   jlong entry_time()              { return _entry_time; }
   jlong exit_time()               { return _exit_time; }
-  const char* name() const        { return (const char*)_name; }
+  const char* name() const        { return _name; }
 
   void set_entry_time(jlong time) { _entry_time = time; }
   void set_exit_time(jlong time)  { _exit_time = time; }
-  void set_name(char* name)       { _name = name; }
+  void set_name(const char* name) { _name = name; }
 };
 
 #endif // SHARE_VM_GC_PARALLEL_GCTASKTHREAD_HPP
diff --git a/hotspot/src/share/vm/interpreter/interpreterRuntime.cpp b/hotspot/src/share/vm/interpreter/interpreterRuntime.cpp
index 573529f8cec..d053786f031 100644
--- a/hotspot/src/share/vm/interpreter/interpreterRuntime.cpp
+++ b/hotspot/src/share/vm/interpreter/interpreterRuntime.cpp
@@ -720,7 +720,8 @@ void InterpreterRuntime::resolve_invoke(JavaThread* thread, Bytecodes::Code byte
   Thread* THREAD = thread;
   // extract receiver from the outgoing argument list if necessary
   Handle receiver(thread, NULL);
-  if (bytecode == Bytecodes::_invokevirtual || bytecode == Bytecodes::_invokeinterface) {
+  if (bytecode == Bytecodes::_invokevirtual || bytecode == Bytecodes::_invokeinterface ||
+      bytecode == Bytecodes::_invokespecial) {
     ResourceMark rm(thread);
     methodHandle m (thread, method(thread));
     Bytecode_invoke call(m, bci(thread));
@@ -783,16 +784,25 @@ void InterpreterRuntime::resolve_invoke(JavaThread* thread, Bytecodes::Code byte
       int index = info.resolved_method()->itable_index();
       assert(info.itable_index() == index, "");
     }
+  } else if (bytecode == Bytecodes::_invokespecial) {
+    assert(info.call_kind() == CallInfo::direct_call, "must be direct call");
   } else {
     assert(info.call_kind() == CallInfo::direct_call ||
            info.call_kind() == CallInfo::vtable_call, "");
   }
 #endif
+  // Get sender or sender's host_klass, and only set cpCache entry to resolved if
+  // it is not an interface.  The receiver for invokespecial calls within interface
+  // methods must be checked for every call.
+  InstanceKlass* sender = pool->pool_holder();
+  sender = sender->is_anonymous() ? sender->host_klass() : sender;
+
   switch (info.call_kind()) {
   case CallInfo::direct_call:
     cp_cache_entry->set_direct_call(
       bytecode,
-      info.resolved_method());
+      info.resolved_method(),
+      sender->is_interface());
     break;
   case CallInfo::vtable_call:
     cp_cache_entry->set_vtable_call(
diff --git a/hotspot/src/share/vm/interpreter/linkResolver.cpp b/hotspot/src/share/vm/interpreter/linkResolver.cpp
index b062f2cc4bd..d7ae64effe6 100644
--- a/hotspot/src/share/vm/interpreter/linkResolver.cpp
+++ b/hotspot/src/share/vm/interpreter/linkResolver.cpp
@@ -1057,12 +1057,14 @@ methodHandle LinkResolver::linktime_resolve_static_method(const LinkInfo& link_i
 
 
 void LinkResolver::resolve_special_call(CallInfo& result,
+                                        Handle recv,
                                         const LinkInfo& link_info,
                                         TRAPS) {
   methodHandle resolved_method = linktime_resolve_special_method(link_info, CHECK);
   runtime_resolve_special_method(result, resolved_method,
                                  link_info.resolved_klass(),
                                  link_info.current_klass(),
+                                 recv,
                                  link_info.check_access(), CHECK);
 }
 
@@ -1149,6 +1151,7 @@ void LinkResolver::runtime_resolve_special_method(CallInfo& result,
                                                   const methodHandle& resolved_method,
                                                   KlassHandle resolved_klass,
                                                   KlassHandle current_klass,
+                                                  Handle recv,
                                                   bool check_access, TRAPS) {
 
   // resolved method is selected method unless we have an old-style lookup
@@ -1157,21 +1160,19 @@ void LinkResolver::runtime_resolve_special_method(CallInfo& result,
   // no checks for shadowing
   methodHandle sel_method(THREAD, resolved_method());
 
-  // check if this is an old-style super call and do a new lookup if so
-  { KlassHandle method_klass  = KlassHandle(THREAD,
-                                            resolved_method->method_holder());
+  if (check_access &&
+      // check if the method is not 
+      resolved_method->name() != vmSymbols::object_initializer_name()) {
 
-    if (check_access &&
+  // check if this is an old-style super call and do a new lookup if so
         // a) check if ACC_SUPER flag is set for the current class
-        (current_klass->is_super() || !AllowNonVirtualCalls) &&
+    if ((current_klass->is_super() || !AllowNonVirtualCalls) &&
         // b) check if the class of the resolved_klass is a superclass
         // (not supertype in order to exclude interface classes) of the current class.
         // This check is not performed for super.invoke for interface methods
         // in super interfaces.
         current_klass->is_subclass_of(resolved_klass()) &&
-        current_klass() != resolved_klass() &&
-        // c) check if the method is not 
-        resolved_method->name() != vmSymbols::object_initializer_name()) {
+        current_klass() != resolved_klass()) {
       // Lookup super method
       KlassHandle super_klass(THREAD, current_klass->super());
       sel_method = lookup_instance_method_in_klasses(super_klass,
@@ -1186,6 +1187,27 @@ void LinkResolver::runtime_resolve_special_method(CallInfo& result,
                                             resolved_method->signature()));
       }
     }
+
+    // Check that the class of objectref (the receiver) is the current class or interface,
+    // or a subtype of the current class or interface (the sender), otherwise invokespecial
+    // throws IllegalAccessError.
+    // The verifier checks that the sender is a subtype of the class in the I/MR operand.
+    // The verifier also checks that the receiver is a subtype of the sender, if the sender is
+    // a class.  If the sender is an interface, the check has to be performed at runtime.
+    InstanceKlass* sender = InstanceKlass::cast(current_klass());
+    sender = sender->is_anonymous() ? sender->host_klass() : sender;
+    if (sender->is_interface() && recv.not_null()) {
+      Klass* receiver_klass = recv->klass();
+      if (!receiver_klass->is_subtype_of(sender)) {
+        ResourceMark rm(THREAD);
+        char buf[500];
+        jio_snprintf(buf, sizeof(buf),
+                     "Receiver class %s must be the current class or a subtype of interface %s",
+                     receiver_klass->name()->as_C_string(),
+                     sender->name()->as_C_string());
+        THROW_MSG(vmSymbols::java_lang_IllegalAccessError(), buf);
+      }
+    }
   }
 
   // check if not static
@@ -1518,7 +1540,7 @@ methodHandle LinkResolver::resolve_static_call_or_null(const LinkInfo& link_info
 methodHandle LinkResolver::resolve_special_call_or_null(const LinkInfo& link_info) {
   EXCEPTION_MARK;
   CallInfo info;
-  resolve_special_call(info, link_info, THREAD);
+  resolve_special_call(info, Handle(), link_info, THREAD);
   if (HAS_PENDING_EXCEPTION) {
     CLEAR_PENDING_EXCEPTION;
     return methodHandle();
@@ -1534,7 +1556,7 @@ methodHandle LinkResolver::resolve_special_call_or_null(const LinkInfo& link_inf
 void LinkResolver::resolve_invoke(CallInfo& result, Handle recv, const constantPoolHandle& pool, int index, Bytecodes::Code byte, TRAPS) {
   switch (byte) {
     case Bytecodes::_invokestatic   : resolve_invokestatic   (result,       pool, index, CHECK); break;
-    case Bytecodes::_invokespecial  : resolve_invokespecial  (result,       pool, index, CHECK); break;
+    case Bytecodes::_invokespecial  : resolve_invokespecial  (result, recv, pool, index, CHECK); break;
     case Bytecodes::_invokevirtual  : resolve_invokevirtual  (result, recv, pool, index, CHECK); break;
     case Bytecodes::_invokehandle   : resolve_invokehandle   (result,       pool, index, CHECK); break;
     case Bytecodes::_invokedynamic  : resolve_invokedynamic  (result,       pool, index, CHECK); break;
@@ -1563,7 +1585,7 @@ void LinkResolver::resolve_invoke(CallInfo& result, Handle& recv,
       resolve_static_call(result, link_info, /*initialize_class=*/false, CHECK);
       break;
     case Bytecodes::_invokespecial:
-      resolve_special_call(result, link_info, CHECK);
+      resolve_special_call(result, recv, link_info, CHECK);
       break;
     default:
       fatal("bad call: %s", Bytecodes::name(byte));
@@ -1576,9 +1598,10 @@ void LinkResolver::resolve_invokestatic(CallInfo& result, const constantPoolHand
 }
 
 
-void LinkResolver::resolve_invokespecial(CallInfo& result, const constantPoolHandle& pool, int index, TRAPS) {
+void LinkResolver::resolve_invokespecial(CallInfo& result, Handle recv,
+                                         const constantPoolHandle& pool, int index, TRAPS) {
   LinkInfo link_info(pool, index, CHECK);
-  resolve_special_call(result, link_info, CHECK);
+  resolve_special_call(result, recv, link_info, CHECK);
 }
 
 
diff --git a/hotspot/src/share/vm/interpreter/linkResolver.hpp b/hotspot/src/share/vm/interpreter/linkResolver.hpp
index 1c02898b42d..2f14496bb01 100644
--- a/hotspot/src/share/vm/interpreter/linkResolver.hpp
+++ b/hotspot/src/share/vm/interpreter/linkResolver.hpp
@@ -230,6 +230,7 @@ class LinkResolver: AllStatic {
                                                  const methodHandle& resolved_method,
                                                  KlassHandle resolved_klass,
                                                  KlassHandle current_klass,
+                                                 Handle recv,
                                                  bool check_access, TRAPS);
   static void runtime_resolve_virtual_method    (CallInfo& result,
                                                  const methodHandle& resolved_method,
@@ -256,7 +257,7 @@ class LinkResolver: AllStatic {
   // runtime resolving from constant pool
   static void resolve_invokestatic   (CallInfo& result,
                                       const constantPoolHandle& pool, int index, TRAPS);
-  static void resolve_invokespecial  (CallInfo& result,
+  static void resolve_invokespecial  (CallInfo& result, Handle recv,
                                       const constantPoolHandle& pool, int index, TRAPS);
   static void resolve_invokevirtual  (CallInfo& result, Handle recv,
                                       const constantPoolHandle& pool, int index, TRAPS);
@@ -289,6 +290,7 @@ class LinkResolver: AllStatic {
                                      const LinkInfo& link_info,
                                      bool initialize_klass, TRAPS);
   static void resolve_special_call  (CallInfo& result,
+                                     Handle recv,
                                      const LinkInfo& link_info,
                                      TRAPS);
   static void resolve_virtual_call  (CallInfo& result, Handle recv, KlassHandle recv_klass,
diff --git a/hotspot/src/share/vm/jvmci/jvmciCompilerToVM.cpp b/hotspot/src/share/vm/jvmci/jvmciCompilerToVM.cpp
index 2fe6b45b79e..6f02a6ce79e 100644
--- a/hotspot/src/share/vm/jvmci/jvmciCompilerToVM.cpp
+++ b/hotspot/src/share/vm/jvmci/jvmciCompilerToVM.cpp
@@ -53,8 +53,34 @@
 #include "runtime/vframe.hpp"
 #include "runtime/vframe_hp.hpp"
 #include "runtime/vmStructs.hpp"
+#include "utilities/resourceHash.hpp"
 
 
+void JNIHandleMark::push_jni_handle_block() {
+  JavaThread* thread = JavaThread::current();
+  if (thread != NULL) {
+    // Allocate a new block for JNI handles.
+    // Inlined code from jni_PushLocalFrame()
+    JNIHandleBlock* java_handles = ((JavaThread*)thread)->active_handles();
+    JNIHandleBlock* compile_handles = JNIHandleBlock::allocate_block(thread);
+    assert(compile_handles != NULL && java_handles != NULL, "should not be NULL");
+    compile_handles->set_pop_frame_link(java_handles);
+    thread->set_active_handles(compile_handles);
+  }
+}
+
+void JNIHandleMark::pop_jni_handle_block() {
+  JavaThread* thread = JavaThread::current();
+  if (thread != NULL) {
+    // Release our JNI handle block
+    JNIHandleBlock* compile_handles = thread->active_handles();
+    JNIHandleBlock* java_handles = compile_handles->pop_frame_link();
+    thread->set_active_handles(java_handles);
+    compile_handles->set_pop_frame_link(NULL);
+    JNIHandleBlock::release_block(compile_handles, thread); // may block
+  }
+}
+
 // Entry to native method implementation that transitions current thread to '_thread_in_vm'.
 #define C2V_VMENTRY(result_type, name, signature) \
   JNIEXPORT result_type JNICALL c2v_ ## name signature { \
@@ -88,6 +114,7 @@ oop CompilerToVM::get_jvmci_type(KlassHandle klass, TRAPS) {
   return NULL;
 }
 
+
 int CompilerToVM::Data::Klass_vtable_start_offset;
 int CompilerToVM::Data::Klass_vtable_length_offset;
 
@@ -120,6 +147,15 @@ int CompilerToVM::Data::cardtable_shift;
 
 int CompilerToVM::Data::vm_page_size;
 
+int CompilerToVM::Data::sizeof_vtableEntry = sizeof(vtableEntry);
+int CompilerToVM::Data::sizeof_ExceptionTableElement = sizeof(ExceptionTableElement);
+int CompilerToVM::Data::sizeof_LocalVariableTableElement = sizeof(LocalVariableTableElement);
+int CompilerToVM::Data::sizeof_ConstantPool = sizeof(ConstantPool);
+int CompilerToVM::Data::sizeof_SymbolPointer = sizeof(Symbol*);
+int CompilerToVM::Data::sizeof_narrowKlass = sizeof(narrowKlass);
+int CompilerToVM::Data::sizeof_arrayOopDesc = sizeof(arrayOopDesc);
+int CompilerToVM::Data::sizeof_BasicLock = sizeof(BasicLock);
+
 address CompilerToVM::Data::dsin;
 address CompilerToVM::Data::dcos;
 address CompilerToVM::Data::dtan;
@@ -128,7 +164,10 @@ address CompilerToVM::Data::dlog;
 address CompilerToVM::Data::dlog10;
 address CompilerToVM::Data::dpow;
 
-void CompilerToVM::Data::initialize() {
+address CompilerToVM::Data::symbol_init;
+address CompilerToVM::Data::symbol_clinit;
+
+void CompilerToVM::Data::initialize(TRAPS) {
   Klass_vtable_start_offset = in_bytes(Klass::vtable_start_offset());
   Klass_vtable_length_offset = in_bytes(Klass::vtable_length_offset());
 
@@ -160,6 +199,9 @@ void CompilerToVM::Data::initialize() {
   assert(OopMapValue::legal_vm_reg_name(VMRegImpl::stack2reg(max_oop_map_stack_index)), "should be valid");
   assert(!OopMapValue::legal_vm_reg_name(VMRegImpl::stack2reg(max_oop_map_stack_index + 1)), "should be invalid");
 
+  symbol_init = (address) vmSymbols::object_initializer_name();
+  symbol_clinit = (address) vmSymbols::class_initializer_name();
+
   BarrierSet* bs = Universe::heap()->barrier_set();
   switch (bs->kind()) {
   case BarrierSet::CardTableModRef:
@@ -179,7 +221,7 @@ void CompilerToVM::Data::initialize() {
     // No post barriers
     break;
   default:
-    ShouldNotReachHere();
+    JVMCI_ERROR("Unsupported BarrierSet kind %d", bs->kind());
     break;
   }
 
@@ -237,13 +279,114 @@ objArrayHandle CompilerToVM::initialize_intrinsics(TRAPS) {
   return vmIntrinsics;
 }
 
-C2V_VMENTRY(jobjectArray, readConfiguration, (JNIEnv *env))
-#define BOXED_LONG(name, value) oop name; do { jvalue p; p.j = (jlong) (value); name = java_lang_boxing_object::create(T_LONG, &p, CHECK_NULL);} while(0)
+/**
+ * The set of VM flags known to be used.
+ */
+#define PREDEFINED_CONFIG_FLAGS(do_bool_flag, do_intx_flag, do_uintx_flag) \
+  do_intx_flag(AllocateInstancePrefetchLines)                              \
+  do_intx_flag(AllocatePrefetchDistance)                                   \
+  do_intx_flag(AllocatePrefetchInstr)                                      \
+  do_intx_flag(AllocatePrefetchLines)                                      \
+  do_intx_flag(AllocatePrefetchStepSize)                                   \
+  do_intx_flag(AllocatePrefetchStyle)                                      \
+  do_intx_flag(BciProfileWidth)                                            \
+  do_bool_flag(BootstrapJVMCI)                                             \
+  do_bool_flag(CITime)                                                     \
+  do_bool_flag(CITimeEach)                                                 \
+  do_uintx_flag(CodeCacheSegmentSize)                                      \
+  do_intx_flag(CodeEntryAlignment)                                         \
+  do_bool_flag(CompactFields)                                              \
+  NOT_PRODUCT(do_intx_flag(CompileTheWorldStartAt))                        \
+  NOT_PRODUCT(do_intx_flag(CompileTheWorldStopAt))                         \
+  do_intx_flag(ContendedPaddingWidth)                                      \
+  do_bool_flag(DontCompileHugeMethods)                                     \
+  do_bool_flag(EnableContended)                                            \
+  do_intx_flag(FieldsAllocationStyle)                                      \
+  do_bool_flag(FoldStableValues)                                           \
+  do_bool_flag(ForceUnreachable)                                           \
+  do_intx_flag(HugeMethodLimit)                                            \
+  do_bool_flag(Inline)                                                     \
+  do_intx_flag(JVMCICounterSize)                                           \
+  do_bool_flag(JVMCIPrintProperties)                                       \
+  do_bool_flag(JVMCIUseFastLocking)                                        \
+  do_intx_flag(MethodProfileWidth)                                         \
+  do_intx_flag(ObjectAlignmentInBytes)                                     \
+  do_bool_flag(PrintInlining)                                              \
+  do_bool_flag(ReduceInitialCardMarks)                                     \
+  do_bool_flag(RestrictContended)                                          \
+  do_intx_flag(StackReservedPages)                                         \
+  do_intx_flag(StackShadowPages)                                           \
+  do_bool_flag(TLABStats)                                                  \
+  do_uintx_flag(TLABWasteIncrement)                                        \
+  do_intx_flag(TypeProfileWidth)                                           \
+  do_bool_flag(UseAESIntrinsics)                                           \
+  X86_ONLY(do_intx_flag(UseAVX))                                           \
+  do_bool_flag(UseBiasedLocking)                                           \
+  do_bool_flag(UseCRC32Intrinsics)                                         \
+  do_bool_flag(UseCompressedClassPointers)                                 \
+  do_bool_flag(UseCompressedOops)                                          \
+  do_bool_flag(UseConcMarkSweepGC)                                         \
+  X86_ONLY(do_bool_flag(UseCountLeadingZerosInstruction))                  \
+  X86_ONLY(do_bool_flag(UseCountTrailingZerosInstruction))                 \
+  do_bool_flag(UseG1GC)                                                    \
+  COMPILER2_PRESENT(do_bool_flag(UseMontgomeryMultiplyIntrinsic))          \
+  COMPILER2_PRESENT(do_bool_flag(UseMontgomerySquareIntrinsic))            \
+  COMPILER2_PRESENT(do_bool_flag(UseMulAddIntrinsic))                      \
+  COMPILER2_PRESENT(do_bool_flag(UseMultiplyToLenIntrinsic))               \
+  do_bool_flag(UsePopCountInstruction)                                     \
+  do_bool_flag(UseSHA1Intrinsics)                                          \
+  do_bool_flag(UseSHA256Intrinsics)                                        \
+  do_bool_flag(UseSHA512Intrinsics)                                        \
+  do_intx_flag(UseSSE)                                                     \
+  COMPILER2_PRESENT(do_bool_flag(UseSquareToLenIntrinsic))                 \
+  do_bool_flag(UseStackBanging)                                            \
+  do_bool_flag(UseTLAB)                                                    \
+  do_bool_flag(VerifyOops)                                                 \
+
+#define BOXED_BOOLEAN(name, value) oop name = ((jboolean)(value) ? boxedTrue() : boxedFalse())
 #define BOXED_DOUBLE(name, value) oop name; do { jvalue p; p.d = (jdouble) (value); name = java_lang_boxing_object::create(T_DOUBLE, &p, CHECK_NULL);} while(0)
+#define BOXED_LONG(name, value) \
+  oop name; \
+  do { \
+    jvalue p; p.j = (jlong) (value); \
+    Handle* e = longs.get(p.j); \
+    if (e == NULL) { \
+      Handle h = java_lang_boxing_object::create(T_LONG, &p, CHECK_NULL); \
+      longs.put(p.j, h); \
+      name = h(); \
+    } else { \
+      name = (*e)(); \
+    } \
+  } while (0)
+
+#define CSTRING_TO_JSTRING(name, value) \
+  Handle name; \
+  do { \
+    if (value != NULL) { \
+      Handle* e = strings.get(value); \
+      if (e == NULL) { \
+        Handle h = java_lang_String::create_from_str(value, CHECK_NULL); \
+        strings.put(value, h); \
+        name = h(); \
+      } else { \
+        name = (*e)(); \
+      } \
+    } \
+  } while (0)
+
+C2V_VMENTRY(jobjectArray, readConfiguration, (JNIEnv *env))
   ResourceMark rm;
   HandleMark hm;
 
-  CompilerToVM::Data::initialize();
+  // Used to canonicalize Long and String values.
+  ResourceHashtable longs;
+  ResourceHashtable strings;
+
+  jvalue prim;
+  prim.z = true;  Handle boxedTrue =  java_lang_boxing_object::create(T_BOOLEAN, &prim, CHECK_NULL);
+  prim.z = false; Handle boxedFalse = java_lang_boxing_object::create(T_BOOLEAN, &prim, CHECK_NULL);
+
+  CompilerToVM::Data::initialize(CHECK_NULL);
 
   VMField::klass()->initialize(CHECK_NULL);
   VMFlag::klass()->initialize(CHECK_NULL);
@@ -257,31 +400,31 @@ C2V_VMENTRY(jobjectArray, readConfiguration, (JNIEnv *env))
     size_t name_buf_len = strlen(vmField.typeName) + strlen(vmField.fieldName) + 2 /* "::" */;
     char* name_buf = NEW_RESOURCE_ARRAY_IN_THREAD(THREAD, char, name_buf_len + 1);
     sprintf(name_buf, "%s::%s", vmField.typeName, vmField.fieldName);
-    Handle name = java_lang_String::create_from_str(name_buf, CHECK_NULL);
-    Handle type = java_lang_String::create_from_str(vmField.typeString, CHECK_NULL);
+    CSTRING_TO_JSTRING(name, name_buf);
+    CSTRING_TO_JSTRING(type, vmField.typeString);
     VMField::set_name(vmFieldObj, name());
     VMField::set_type(vmFieldObj, type());
     VMField::set_offset(vmFieldObj, vmField.offset);
     VMField::set_address(vmFieldObj, (jlong) vmField.address);
-    if (vmField.isStatic) {
+    if (vmField.isStatic && vmField.typeString != NULL) {
       if (strcmp(vmField.typeString, "bool") == 0) {
-        BOXED_LONG(value, *(jbyte*) vmField.address);
-        VMField::set_value(vmFieldObj, value);
+        BOXED_BOOLEAN(box, *(jbyte*) vmField.address);
+        VMField::set_value(vmFieldObj, box);
       } else if (strcmp(vmField.typeString, "int") == 0 ||
                  strcmp(vmField.typeString, "jint") == 0) {
-        BOXED_LONG(value, *(jint*) vmField.address);
-        VMField::set_value(vmFieldObj, value);
+        BOXED_LONG(box, *(jint*) vmField.address);
+        VMField::set_value(vmFieldObj, box);
       } else if (strcmp(vmField.typeString, "uint64_t") == 0) {
-        BOXED_LONG(value, *(uint64_t*) vmField.address);
-        VMField::set_value(vmFieldObj, value);
+        BOXED_LONG(box, *(uint64_t*) vmField.address);
+        VMField::set_value(vmFieldObj, box);
       } else if (strcmp(vmField.typeString, "address") == 0 ||
                  strcmp(vmField.typeString, "intptr_t") == 0 ||
                  strcmp(vmField.typeString, "uintptr_t") == 0 ||
                  strcmp(vmField.typeString, "size_t") == 0 ||
                  // All foo* types are addresses.
                  vmField.typeString[strlen(vmField.typeString) - 1] == '*') {
-        BOXED_LONG(value, *((address*) vmField.address));
-        VMField::set_value(vmFieldObj, value);
+        BOXED_LONG(box, *((address*) vmField.address));
+        VMField::set_value(vmFieldObj, box);
       } else {
         JVMCI_ERROR_NULL("VM field %s has unsupported type %s", name_buf, vmField.typeString);
       }
@@ -289,16 +432,6 @@ C2V_VMENTRY(jobjectArray, readConfiguration, (JNIEnv *env))
     vmFields->obj_at_put(i, vmFieldObj());
   }
 
-  len = JVMCIVMStructs::localHotSpotVMTypes_count();
-  objArrayHandle vmTypes = oopFactory::new_objArray(SystemDictionary::Object_klass(), len * 2, CHECK_NULL);
-  for (int i = 0; i < len ; i++) {
-    VMTypeEntry vmType = JVMCIVMStructs::localHotSpotVMTypes[i];
-    Handle name = java_lang_String::create_from_str(vmType.typeName, CHECK_NULL);
-    BOXED_LONG(size, vmType.size);
-    vmTypes->obj_at_put(i * 2, name());
-    vmTypes->obj_at_put(i * 2 + 1, size);
-  }
-
   int ints_len = JVMCIVMStructs::localHotSpotVMIntConstants_count();
   int longs_len = JVMCIVMStructs::localHotSpotVMLongConstants_count();
   len = ints_len + longs_len;
@@ -306,14 +439,14 @@ C2V_VMENTRY(jobjectArray, readConfiguration, (JNIEnv *env))
   int insert = 0;
   for (int i = 0; i < ints_len ; i++) {
     VMIntConstantEntry c = JVMCIVMStructs::localHotSpotVMIntConstants[i];
-    Handle name = java_lang_String::create_from_str(c.name, CHECK_NULL);
+    CSTRING_TO_JSTRING(name, c.name);
     BOXED_LONG(value, c.value);
     vmConstants->obj_at_put(insert++, name());
     vmConstants->obj_at_put(insert++, value);
   }
   for (int i = 0; i < longs_len ; i++) {
     VMLongConstantEntry c = JVMCIVMStructs::localHotSpotVMLongConstants[i];
-    Handle name = java_lang_String::create_from_str(c.name, CHECK_NULL);
+    CSTRING_TO_JSTRING(name, c.name);
     BOXED_LONG(value, c.value);
     vmConstants->obj_at_put(insert++, name());
     vmConstants->obj_at_put(insert++, value);
@@ -324,69 +457,104 @@ C2V_VMENTRY(jobjectArray, readConfiguration, (JNIEnv *env))
   objArrayHandle vmAddresses = oopFactory::new_objArray(SystemDictionary::Object_klass(), len * 2, CHECK_NULL);
   for (int i = 0; i < len ; i++) {
     VMAddressEntry a = JVMCIVMStructs::localHotSpotVMAddresses[i];
-    Handle name = java_lang_String::create_from_str(a.name, CHECK_NULL);
+    CSTRING_TO_JSTRING(name, a.name);
     BOXED_LONG(value, a.value);
     vmAddresses->obj_at_put(i * 2, name());
     vmAddresses->obj_at_put(i * 2 + 1, value);
   }
 
-  // The last entry is the null entry.
-  len = (int) Flag::numFlags - 1;
+#define COUNT_FLAG(ignore) +1
+#ifdef ASSERT
+#define CHECK_FLAG(type, name) { \
+  Flag* flag = Flag::find_flag(#name, strlen(#name), /*allow_locked*/ true, /* return_flag */ true); \
+  assert(flag != NULL, "No such flag named " #name); \
+  assert(flag->is_##type(), "Flag " #name " is not of type " #type); \
+}
+#else
+#define CHECK_FLAG(type, name)
+#endif
+
+#define ADD_FLAG(type, name, convert) { \
+  CHECK_FLAG(type, name) \
+  instanceHandle vmFlagObj = InstanceKlass::cast(VMFlag::klass())->allocate_instance_handle(CHECK_NULL); \
+  CSTRING_TO_JSTRING(fname, #name); \
+  CSTRING_TO_JSTRING(ftype, #type); \
+  VMFlag::set_name(vmFlagObj, fname()); \
+  VMFlag::set_type(vmFlagObj, ftype()); \
+  convert(value, name); \
+  VMFlag::set_value(vmFlagObj, value); \
+  vmFlags->obj_at_put(i++, vmFlagObj()); \
+}
+#define ADD_BOOL_FLAG(name)  ADD_FLAG(bool, name, BOXED_BOOLEAN)
+#define ADD_INTX_FLAG(name)  ADD_FLAG(intx, name, BOXED_LONG)
+#define ADD_UINTX_FLAG(name) ADD_FLAG(uintx, name, BOXED_LONG)
+
+  len = 0 + PREDEFINED_CONFIG_FLAGS(COUNT_FLAG, COUNT_FLAG, COUNT_FLAG);
   objArrayHandle vmFlags = oopFactory::new_objArray(VMFlag::klass(), len, CHECK_NULL);
-  for (int i = 0; i < len; i++) {
-    Flag* flag = &Flag::flags[i];
-    instanceHandle vmFlagObj = InstanceKlass::cast(VMFlag::klass())->allocate_instance_handle(CHECK_NULL);
-    Handle name = java_lang_String::create_from_str(flag->_name, CHECK_NULL);
-    Handle type = java_lang_String::create_from_str(flag->_type, CHECK_NULL);
-    VMFlag::set_name(vmFlagObj, name());
-    VMFlag::set_type(vmFlagObj, type());
-    if (flag->is_bool()) {
-      BOXED_LONG(value, flag->get_bool());
-      VMFlag::set_value(vmFlagObj, value);
-    } else if (flag->is_ccstr()) {
-      Handle value = java_lang_String::create_from_str(flag->get_ccstr(), CHECK_NULL);
-      VMFlag::set_value(vmFlagObj, value());
-    } else if (flag->is_int()) {
-      BOXED_LONG(value, flag->get_int());
-      VMFlag::set_value(vmFlagObj, value);
-    } else if (flag->is_intx()) {
-      BOXED_LONG(value, flag->get_intx());
-      VMFlag::set_value(vmFlagObj, value);
-    } else if (flag->is_uint()) {
-      BOXED_LONG(value, flag->get_uint());
-      VMFlag::set_value(vmFlagObj, value);
-    } else if (flag->is_uint64_t()) {
-      BOXED_LONG(value, flag->get_uint64_t());
-      VMFlag::set_value(vmFlagObj, value);
-    } else if (flag->is_uintx()) {
-      BOXED_LONG(value, flag->get_uintx());
-      VMFlag::set_value(vmFlagObj, value);
-    } else if (flag->is_double()) {
-      BOXED_DOUBLE(value, flag->get_double());
-      VMFlag::set_value(vmFlagObj, value);
-    } else if (flag->is_size_t()) {
-      BOXED_LONG(value, flag->get_size_t());
-      VMFlag::set_value(vmFlagObj, value);
-    } else {
-      JVMCI_ERROR_NULL("VM flag %s has unsupported type %s", flag->_name, flag->_type);
-    }
-    vmFlags->obj_at_put(i, vmFlagObj());
-  }
+  int i = 0;
+  PREDEFINED_CONFIG_FLAGS(ADD_BOOL_FLAG, ADD_INTX_FLAG, ADD_UINTX_FLAG)
 
   objArrayHandle vmIntrinsics = CompilerToVM::initialize_intrinsics(CHECK_NULL);
 
-  objArrayOop data = oopFactory::new_objArray(SystemDictionary::Object_klass(), 6, CHECK_NULL);
+  objArrayOop data = oopFactory::new_objArray(SystemDictionary::Object_klass(), 5, CHECK_NULL);
   data->obj_at_put(0, vmFields());
-  data->obj_at_put(1, vmTypes());
-  data->obj_at_put(2, vmConstants());
-  data->obj_at_put(3, vmAddresses());
-  data->obj_at_put(4, vmFlags());
-  data->obj_at_put(5, vmIntrinsics());
+  data->obj_at_put(1, vmConstants());
+  data->obj_at_put(2, vmAddresses());
+  data->obj_at_put(3, vmFlags());
+  data->obj_at_put(4, vmIntrinsics());
 
   return (jobjectArray) JNIHandles::make_local(THREAD, data);
+#undef COUNT_FLAG
+#undef ADD_FLAG
+#undef ADD_BOOL_FLAG
+#undef ADD_INTX_FLAG
+#undef ADD_UINTX_FLAG
+#undef CHECK_FLAG
+C2V_END
+
+C2V_VMENTRY(jobject, getFlagValue, (JNIEnv *, jobject c2vm, jobject name_handle))
+#define RETURN_BOXED_LONG(value) oop box; jvalue p; p.j = (jlong) (value); box = java_lang_boxing_object::create(T_LONG, &p, CHECK_NULL); return JNIHandles::make_local(THREAD, box);
+#define RETURN_BOXED_DOUBLE(value) oop box; jvalue p; p.d = (jdouble) (value); box = java_lang_boxing_object::create(T_DOUBLE, &p, CHECK_NULL); return JNIHandles::make_local(THREAD, box);
+  Handle name = JNIHandles::resolve(name_handle);
+  if (name.is_null()) {
+    THROW_0(vmSymbols::java_lang_NullPointerException());
+  }
+  ResourceMark rm;
+  const char* cstring = java_lang_String::as_utf8_string(name());
+  Flag* flag = Flag::find_flag(cstring, strlen(cstring), /* allow_locked */ true, /* return_flag */ true);
+  if (flag == NULL) {
+    return c2vm;
+  }
+  if (flag->is_bool()) {
+    jvalue prim;
+    prim.z = flag->get_bool();
+    oop box = java_lang_boxing_object::create(T_BOOLEAN, &prim, CHECK_NULL);
+    return JNIHandles::make_local(THREAD, box);
+  } else if (flag->is_ccstr()) {
+    Handle value = java_lang_String::create_from_str(flag->get_ccstr(), CHECK_NULL);
+    return JNIHandles::make_local(THREAD, value());
+  } else if (flag->is_intx()) {
+    RETURN_BOXED_LONG(flag->get_intx());
+  } else if (flag->is_int()) {
+    RETURN_BOXED_LONG(flag->get_int());
+  } else if (flag->is_uint()) {
+    RETURN_BOXED_LONG(flag->get_uint());
+  } else if (flag->is_uint64_t()) {
+    RETURN_BOXED_LONG(flag->get_uint64_t());
+  } else if (flag->is_size_t()) {
+    RETURN_BOXED_LONG(flag->get_size_t());
+  } else if (flag->is_uintx()) {
+    RETURN_BOXED_LONG(flag->get_uintx());
+  } else if (flag->is_double()) {
+    RETURN_BOXED_DOUBLE(flag->get_double());
+  } else {
+    JVMCI_ERROR_NULL("VM flag %s has unsupported type %s", flag->_name, flag->_type);
+  }
+C2V_END
+
 #undef BOXED_LONG
 #undef BOXED_DOUBLE
-C2V_END
+#undef CSTRING_TO_JSTRING
 
 C2V_VMENTRY(jbyteArray, getBytecode, (JNIEnv *, jobject, jobject jvmci_method))
   methodHandle method = CompilerToVM::asMethod(jvmci_method);
@@ -593,9 +761,7 @@ C2V_END
 
 C2V_VMENTRY(jboolean, isCompilable,(JNIEnv *, jobject, jobject jvmci_method))
   methodHandle method = CompilerToVM::asMethod(jvmci_method);
-  // Ignore the not_compilable flags in hosted mode since they are never set by
-  // the JVMCI compiler.
-  return UseJVMCICompiler || !method->is_not_compilable(CompLevel_full_optimization);
+  return !method->is_not_compilable(CompLevel_full_optimization);
 C2V_END
 
 C2V_VMENTRY(jboolean, hasNeverInlineDirective,(JNIEnv *, jobject, jobject jvmci_method))
@@ -743,7 +909,7 @@ C2V_VMENTRY(jint, constantPoolRemapInstructionOperandFromCache, (JNIEnv*, jobjec
   return cp->remap_instruction_operand_from_cache(index);
 C2V_END
 
-C2V_VMENTRY(jobject, resolveFieldInPool, (JNIEnv*, jobject, jobject jvmci_constant_pool, jint index, jobject jvmci_method, jbyte opcode, jlongArray info_handle))
+C2V_VMENTRY(jobject, resolveFieldInPool, (JNIEnv*, jobject, jobject jvmci_constant_pool, jint index, jobject jvmci_method, jbyte opcode, jintArray info_handle))
   ResourceMark rm;
   constantPoolHandle cp = CompilerToVM::asConstantPool(jvmci_constant_pool);
   Bytecodes::Code code = (Bytecodes::Code)(((int) opcode) & 0xFF);
@@ -751,9 +917,12 @@ C2V_VMENTRY(jobject, resolveFieldInPool, (JNIEnv*, jobject, jobject jvmci_consta
   LinkInfo link_info(cp, index, (jvmci_method != NULL) ? CompilerToVM::asMethod(jvmci_method) : NULL, CHECK_0);
   LinkResolver::resolve_field(fd, link_info, Bytecodes::java_code(code), false, CHECK_0);
   typeArrayOop info = (typeArrayOop) JNIHandles::resolve(info_handle);
-  assert(info != NULL && info->length() == 2, "must be");
-  info->long_at_put(0, (jlong) fd.access_flags().as_int());
-  info->long_at_put(1, (jlong) fd.offset());
+  if (info == NULL || info->length() != 3) {
+    JVMCI_ERROR_NULL("info must not be null and have a length of 3");
+  }
+  info->int_at_put(0, fd.access_flags().as_int());
+  info->int_at_put(1, fd.offset());
+  info->int_at_put(2, fd.index());
   oop field_holder = CompilerToVM::get_jvmci_type(fd.field_holder(), CHECK_NULL);
   return JNIHandles::make_local(THREAD, field_holder);
 C2V_END
@@ -842,6 +1011,8 @@ C2V_END
 C2V_VMENTRY(jint, installCode, (JNIEnv *jniEnv, jobject, jobject target, jobject compiled_code, jobject installed_code, jobject speculation_log))
   ResourceMark rm;
   HandleMark hm;
+  JNIHandleMark jni_hm;
+
   Handle target_handle = JNIHandles::resolve(target);
   Handle compiled_code_handle = JNIHandles::resolve(compiled_code);
   CodeBlob* cb = NULL;
@@ -1610,7 +1781,7 @@ JNINativeMethod CompilerToVM::methods[] = {
   {CC "resolveConstantInPool",                        CC "(" HS_CONSTANT_POOL "I)" OBJECT,                                                  FN_PTR(resolveConstantInPool)},
   {CC "resolvePossiblyCachedConstantInPool",          CC "(" HS_CONSTANT_POOL "I)" OBJECT,                                                  FN_PTR(resolvePossiblyCachedConstantInPool)},
   {CC "resolveTypeInPool",                            CC "(" HS_CONSTANT_POOL "I)" HS_RESOLVED_KLASS,                                       FN_PTR(resolveTypeInPool)},
-  {CC "resolveFieldInPool",                           CC "(" HS_CONSTANT_POOL "I" HS_RESOLVED_METHOD "B[J)" HS_RESOLVED_KLASS,              FN_PTR(resolveFieldInPool)},
+  {CC "resolveFieldInPool",                           CC "(" HS_CONSTANT_POOL "I" HS_RESOLVED_METHOD "B[I)" HS_RESOLVED_KLASS,              FN_PTR(resolveFieldInPool)},
   {CC "resolveInvokeDynamicInPool",                   CC "(" HS_CONSTANT_POOL "I)V",                                                        FN_PTR(resolveInvokeDynamicInPool)},
   {CC "resolveInvokeHandleInPool",                    CC "(" HS_CONSTANT_POOL "I)V",                                                        FN_PTR(resolveInvokeHandleInPool)},
   {CC "resolveMethod",                                CC "(" HS_RESOLVED_KLASS HS_RESOLVED_METHOD HS_RESOLVED_KLASS ")" HS_RESOLVED_METHOD, FN_PTR(resolveMethod)},
@@ -1648,6 +1819,7 @@ JNINativeMethod CompilerToVM::methods[] = {
   {CC "getFingerprint",                               CC "(J)J",                                                                            FN_PTR(getFingerprint)},
   {CC "interpreterFrameSize",                         CC "(" BYTECODE_FRAME ")I",                                                           FN_PTR(interpreterFrameSize)},
   {CC "compileToBytecode",                            CC "(" OBJECT ")V",                                                                   FN_PTR(compileToBytecode)},
+  {CC "getFlagValue",                                 CC "(" STRING ")" OBJECT,                                                             FN_PTR(getFlagValue)},
 };
 
 int CompilerToVM::methods_count() {
diff --git a/hotspot/src/share/vm/jvmci/jvmciCompilerToVM.hpp b/hotspot/src/share/vm/jvmci/jvmciCompilerToVM.hpp
index c0f21e2b8c2..036ffdd3249 100644
--- a/hotspot/src/share/vm/jvmci/jvmciCompilerToVM.hpp
+++ b/hotspot/src/share/vm/jvmci/jvmciCompilerToVM.hpp
@@ -66,6 +66,15 @@ class CompilerToVM {
 
     static int vm_page_size;
 
+    static int sizeof_vtableEntry;
+    static int sizeof_ExceptionTableElement;
+    static int sizeof_LocalVariableTableElement;
+    static int sizeof_ConstantPool;
+    static int sizeof_SymbolPointer;
+    static int sizeof_narrowKlass;
+    static int sizeof_arrayOopDesc;
+    static int sizeof_BasicLock;
+
     static address dsin;
     static address dcos;
     static address dtan;
@@ -74,8 +83,11 @@ class CompilerToVM {
     static address dlog10;
     static address dpow;
 
+    static address symbol_init;
+    static address symbol_clinit;
+
    public:
-    static void initialize();
+    static void initialize(TRAPS);
 
     static int max_oop_map_stack_offset() {
       assert(_max_oop_map_stack_offset > 0, "must be initialized");
@@ -83,6 +95,20 @@ class CompilerToVM {
     }
   };
 
+  static bool cstring_equals(const char* const& s0, const char* const& s1) {
+    return strcmp(s0, s1) == 0;
+  }
+
+  static unsigned cstring_hash(const char* const& s) {
+    int h = 0;
+    const char* p = s;
+    while (*p != '\0') {
+      h = 31 * h + *p;
+      p++;
+    }
+    return h;
+  }
+
   static JNINativeMethod methods[];
 
   static objArrayHandle initialize_intrinsics(TRAPS);
@@ -180,4 +206,14 @@ class JavaArgumentUnboxer : public SignatureIterator {
   inline void do_void()                     { }
 };
 
+class JNIHandleMark : public StackObj {
+  public:
+    JNIHandleMark() { push_jni_handle_block(); }
+    ~JNIHandleMark() { pop_jni_handle_block(); }
+
+  private:
+    static void push_jni_handle_block();
+    static void pop_jni_handle_block();
+};
+
 #endif // SHARE_VM_JVMCI_JVMCI_COMPILER_TO_VM_HPP
diff --git a/hotspot/src/share/vm/jvmci/jvmciEnv.cpp b/hotspot/src/share/vm/jvmci/jvmciEnv.cpp
index 9c5d98361e0..8fb1e8cbdbf 100644
--- a/hotspot/src/share/vm/jvmci/jvmciEnv.cpp
+++ b/hotspot/src/share/vm/jvmci/jvmciEnv.cpp
@@ -283,13 +283,14 @@ void JVMCIEnv::get_field_by_index(instanceKlassHandle accessor, fieldDescriptor&
 // Perform an appropriate method lookup based on accessor, holder,
 // name, signature, and bytecode.
 methodHandle JVMCIEnv::lookup_method(instanceKlassHandle h_accessor,
-                               instanceKlassHandle h_holder,
+                               KlassHandle   h_holder,
                                Symbol*       name,
                                Symbol*       sig,
                                Bytecodes::Code bc,
                                constantTag   tag) {
-  JVMCI_EXCEPTION_CONTEXT;
-  LinkResolver::check_klass_accessability(h_accessor, h_holder, KILL_COMPILE_ON_FATAL_(NULL));
+  // Accessibility checks are performed in JVMCIEnv::get_method_by_index_impl().
+  assert(check_klass_accessibility(h_accessor, h_holder), "holder not accessible");
+
   methodHandle dest_method;
   LinkInfo link_info(h_holder, name, sig, h_accessor, LinkInfo::needs_access_check, tag);
   switch (bc) {
@@ -363,9 +364,8 @@ methodHandle JVMCIEnv::get_method_by_index_impl(const constantPoolHandle& cpool,
   }
 
   if (holder_is_accessible) { // Our declared holder is loaded.
-    instanceKlassHandle lookup = get_instance_klass_for_declared_method_holder(holder);
     constantTag tag = cpool->tag_ref_at(index);
-    methodHandle m = lookup_method(accessor, lookup, name_sym, sig_sym, bc, tag);
+    methodHandle m = lookup_method(accessor, holder, name_sym, sig_sym, bc, tag);
     if (!m.is_null() &&
         (bc == Bytecodes::_invokestatic
          ?  InstanceKlass::cast(m->method_holder())->is_not_initialized()
diff --git a/hotspot/src/share/vm/jvmci/jvmciEnv.hpp b/hotspot/src/share/vm/jvmci/jvmciEnv.hpp
index 2c884494db8..1154a95d567 100644
--- a/hotspot/src/share/vm/jvmci/jvmciEnv.hpp
+++ b/hotspot/src/share/vm/jvmci/jvmciEnv.hpp
@@ -127,7 +127,7 @@ private:
   // Helper methods
   static bool       check_klass_accessibility(KlassHandle accessing_klass, KlassHandle resolved_klass);
   static methodHandle  lookup_method(instanceKlassHandle  accessor,
-                           instanceKlassHandle  holder,
+                           KlassHandle     holder,
                            Symbol*         name,
                            Symbol*         sig,
                            Bytecodes::Code bc,
diff --git a/hotspot/src/share/vm/jvmci/jvmciJavaClasses.hpp b/hotspot/src/share/vm/jvmci/jvmciJavaClasses.hpp
index d6039fca4a3..58764147efa 100644
--- a/hotspot/src/share/vm/jvmci/jvmciJavaClasses.hpp
+++ b/hotspot/src/share/vm/jvmci/jvmciJavaClasses.hpp
@@ -117,7 +117,7 @@ class JVMCIJavaClasses : AllStatic {
     oop_field(VMField, type, "Ljava/lang/String;")                                                                                                             \
     long_field(VMField, offset)                                                                                                                                \
     long_field(VMField, address)                                                                                                                               \
-    oop_field(VMField, value, "Ljava/lang/Long;")                                                                                                              \
+    oop_field(VMField, value, "Ljava/lang/Object;")                                                                                                            \
   end_class                                                                                                                                                    \
   start_class(VMFlag)                                                                                                                                          \
     oop_field(VMFlag, name, "Ljava/lang/String;")                                                                                                              \
diff --git a/hotspot/src/share/vm/jvmci/vmStructs_jvmci.cpp b/hotspot/src/share/vm/jvmci/vmStructs_jvmci.cpp
index a01651f55aa..0ce9816890a 100644
--- a/hotspot/src/share/vm/jvmci/vmStructs_jvmci.cpp
+++ b/hotspot/src/share/vm/jvmci/vmStructs_jvmci.cpp
@@ -78,6 +78,15 @@
                                                                                                                                      \
   static_field(CompilerToVM::Data,             vm_page_size,                           int)                                          \
                                                                                                                                      \
+  static_field(CompilerToVM::Data,             sizeof_vtableEntry,                     int)                                          \
+  static_field(CompilerToVM::Data,             sizeof_ExceptionTableElement,           int)                                          \
+  static_field(CompilerToVM::Data,             sizeof_LocalVariableTableElement,       int)                                          \
+  static_field(CompilerToVM::Data,             sizeof_ConstantPool,                    int)                                          \
+  static_field(CompilerToVM::Data,             sizeof_SymbolPointer,                   int)                                          \
+  static_field(CompilerToVM::Data,             sizeof_narrowKlass,                     int)                                          \
+  static_field(CompilerToVM::Data,             sizeof_arrayOopDesc,                    int)                                          \
+  static_field(CompilerToVM::Data,             sizeof_BasicLock,                       int)                                          \
+                                                                                                                                     \
   static_field(CompilerToVM::Data,             dsin,                                   address)                                      \
   static_field(CompilerToVM::Data,             dcos,                                   address)                                      \
   static_field(CompilerToVM::Data,             dtan,                                   address)                                      \
@@ -86,6 +95,9 @@
   static_field(CompilerToVM::Data,             dlog10,                                 address)                                      \
   static_field(CompilerToVM::Data,             dpow,                                   address)                                      \
                                                                                                                                      \
+  static_field(CompilerToVM::Data,             symbol_init,                            address)                                      \
+  static_field(CompilerToVM::Data,             symbol_clinit,                          address)                                      \
+                                                                                                                                     \
   static_field(Abstract_VM_Version,            _features,                              uint64_t)                                     \
                                                                                                                                      \
   nonstatic_field(Array,                  _length,                                int)                                          \
diff --git a/hotspot/src/share/vm/logging/logTag.hpp b/hotspot/src/share/vm/logging/logTag.hpp
index e262d074cfa..322e9030112 100644
--- a/hotspot/src/share/vm/logging/logTag.hpp
+++ b/hotspot/src/share/vm/logging/logTag.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -82,7 +82,7 @@
   LOG_TAG(metadata) \
   LOG_TAG(metaspace) \
   LOG_TAG(mmu) \
-  LOG_TAG(modules) \
+  LOG_TAG(module) \
   LOG_TAG(monitorinflation) \
   LOG_TAG(monitormismatch) \
   LOG_TAG(nmethod) \
diff --git a/hotspot/src/share/vm/memory/heap.cpp b/hotspot/src/share/vm/memory/heap.cpp
index 9d2179d5cf7..8db869ca8ce 100644
--- a/hotspot/src/share/vm/memory/heap.cpp
+++ b/hotspot/src/share/vm/memory/heap.cpp
@@ -190,6 +190,10 @@ void* CodeHeap::allocate(size_t instance_size) {
   if (block != NULL) {
     assert(block->length() >= number_of_segments && block->length() < number_of_segments + CodeCacheMinBlockLength, "sanity check");
     assert(!block->free(), "must be marked free");
+    guarantee((char*) block >= _memory.low_boundary() && (char*) block < _memory.high(),
+              "The newly allocated block " INTPTR_FORMAT " is not within the heap "
+              "starting with "  INTPTR_FORMAT " and ending with "  INTPTR_FORMAT,
+              p2i(block), p2i(_memory.low_boundary()), p2i(_memory.high()));
     DEBUG_ONLY(memset((void*)block->allocated_space(), badCodeHeapNewVal, instance_size));
     _max_allocated_capacity = MAX2(_max_allocated_capacity, allocated_capacity());
     _blob_count++;
@@ -204,6 +208,10 @@ void* CodeHeap::allocate(size_t instance_size) {
     HeapBlock* b =  block_at(_next_segment);
     b->initialize(number_of_segments);
     _next_segment += number_of_segments;
+    guarantee((char*) b >= _memory.low_boundary() && (char*) block < _memory.high(),
+              "The newly allocated block " INTPTR_FORMAT " is not within the heap "
+              "starting with "  INTPTR_FORMAT " and ending with " INTPTR_FORMAT,
+              p2i(b), p2i(_memory.low_boundary()), p2i(_memory.high()));
     DEBUG_ONLY(memset((void *)b->allocated_space(), badCodeHeapNewVal, instance_size));
     _max_allocated_capacity = MAX2(_max_allocated_capacity, allocated_capacity());
     _blob_count++;
@@ -219,6 +227,10 @@ void CodeHeap::deallocate(void* p) {
   // Find start of HeapBlock
   HeapBlock* b = (((HeapBlock *)p) - 1);
   assert(b->allocated_space() == p, "sanity check");
+  guarantee((char*) b >= _memory.low_boundary() && (char*) b < _memory.high(),
+            "The block to be deallocated " INTPTR_FORMAT " is not within the heap "
+            "starting with "  INTPTR_FORMAT " and ending with " INTPTR_FORMAT,
+            p2i(b), p2i(_memory.low_boundary()), p2i(_memory.high()));
   DEBUG_ONLY(memset((void *)b->allocated_space(), badCodeHeapFreeVal,
              segments_to_size(b->length()) - sizeof(HeapBlock)));
   add_to_freelist(b);
diff --git a/hotspot/src/share/vm/memory/heap.hpp b/hotspot/src/share/vm/memory/heap.hpp
index d75559695e1..6fe3391d6f0 100644
--- a/hotspot/src/share/vm/memory/heap.hpp
+++ b/hotspot/src/share/vm/memory/heap.hpp
@@ -153,7 +153,9 @@ class CodeHeap : public CHeapObj {
   char* high() const                             { return _memory.high(); }
   char* high_boundary() const                    { return _memory.high_boundary(); }
 
-  virtual bool  contains(const void* p) const    { return low_boundary() <= p && p < high(); }
+  virtual bool contains(const void* p) const     { return low_boundary() <= p && p < high(); }
+  virtual bool contains_blob(const CodeBlob* blob) const { return low_boundary() <= (char*) blob && (char*) blob < high(); }
+
   virtual void* find_start(void* p)     const;   // returns the block containing p or NULL
   virtual CodeBlob* find_blob_unsafe(void* start) const;
   size_t alignment_unit()       const;           // alignment of any block
diff --git a/hotspot/src/share/vm/oops/constMethod.cpp b/hotspot/src/share/vm/oops/constMethod.cpp
index 34fe9f9e8be..c26fe2d0904 100644
--- a/hotspot/src/share/vm/oops/constMethod.cpp
+++ b/hotspot/src/share/vm/oops/constMethod.cpp
@@ -407,8 +407,12 @@ void ConstMethod::print_on(outputStream* st) const {
   ResourceMark rm;
   assert(is_constMethod(), "must be constMethod");
   st->print_cr("%s", internal_name());
-  st->print(" - method:       " INTPTR_FORMAT " ", p2i((address)method()));
-  method()->print_value_on(st); st->cr();
+  Method* m = method();
+  st->print(" - method:       " INTPTR_FORMAT " ", p2i((address)m));
+  if (m != NULL) {
+    m->print_value_on(st);
+  }
+  st->cr();
   if (has_stackmap_table()) {
     st->print(" - stackmap data:       ");
     stackmap_data()->print_value_on(st);
@@ -421,7 +425,12 @@ void ConstMethod::print_on(outputStream* st) const {
 void ConstMethod::print_value_on(outputStream* st) const {
   assert(is_constMethod(), "must be constMethod");
   st->print(" const part of method " );
-  method()->print_value_on(st);
+  Method* m = method();
+  if (m != NULL) {
+    m->print_value_on(st);
+  } else {
+    st->print("NULL");
+  }
 }
 
 #if INCLUDE_SERVICES
@@ -461,7 +470,7 @@ void ConstMethod::verify_on(outputStream* st) {
 
   // Verification can occur during oop construction before the method or
   // other fields have been initialized.
-  guarantee(method()->is_method(), "should be method");
+  guarantee(method() != NULL && method()->is_method(), "should be method");
 
   address m_end = (address)((intptr_t) this + size());
   address compressed_table_start = code_end();
diff --git a/hotspot/src/share/vm/oops/constMethod.hpp b/hotspot/src/share/vm/oops/constMethod.hpp
index 45246ba209b..7453ecbf689 100644
--- a/hotspot/src/share/vm/oops/constMethod.hpp
+++ b/hotspot/src/share/vm/oops/constMethod.hpp
@@ -359,7 +359,9 @@ public:
   }
 
   // Sizing
-  static int header_size() { return sizeof(ConstMethod)/wordSize; }
+  static int header_size() {
+    return align_size_up(sizeof(ConstMethod), wordSize) / wordSize;
+  }
 
   // Size needed
   static int size(int code_size, InlineTableSizes* sizes);
diff --git a/hotspot/src/share/vm/oops/constantPool.hpp b/hotspot/src/share/vm/oops/constantPool.hpp
index 38a71f525d2..86cfa192171 100644
--- a/hotspot/src/share/vm/oops/constantPool.hpp
+++ b/hotspot/src/share/vm/oops/constantPool.hpp
@@ -705,7 +705,9 @@ class ConstantPool : public Metadata {
   }
 
   // Sizing (in words)
-  static int header_size()             { return sizeof(ConstantPool)/wordSize; }
+  static int header_size()             {
+    return align_size_up(sizeof(ConstantPool), wordSize) / wordSize;
+  }
   static int size(int length)          { return align_metadata_size(header_size() + length); }
   int size() const                     { return size(length()); }
 #if INCLUDE_SERVICES
diff --git a/hotspot/src/share/vm/oops/cpCache.cpp b/hotspot/src/share/vm/oops/cpCache.cpp
index a30d19dd685..b7522433bbf 100644
--- a/hotspot/src/share/vm/oops/cpCache.cpp
+++ b/hotspot/src/share/vm/oops/cpCache.cpp
@@ -140,7 +140,8 @@ void ConstantPoolCacheEntry::set_parameter_size(int value) {
 
 void ConstantPoolCacheEntry::set_direct_or_vtable_call(Bytecodes::Code invoke_code,
                                                        methodHandle method,
-                                                       int vtable_index) {
+                                                       int vtable_index,
+                                                       bool sender_is_interface) {
   bool is_vtable_call = (vtable_index >= 0);  // FIXME: split this method on this boolean
   assert(method->interpreter_entry() != NULL, "should have been set at this point");
   assert(!method->is_obsolete(),  "attempt to write obsolete method to cpCache");
@@ -204,7 +205,13 @@ void ConstantPoolCacheEntry::set_direct_or_vtable_call(Bytecodes::Code invoke_co
   if (byte_no == 1) {
     assert(invoke_code != Bytecodes::_invokevirtual &&
            invoke_code != Bytecodes::_invokeinterface, "");
+    // Don't mark invokespecial to method as resolved if sender is an interface.  The receiver
+    // has to be checked that it is a subclass of the current class every time this bytecode
+    // is executed.
+    if (invoke_code != Bytecodes::_invokespecial || !sender_is_interface ||
+        method->name() == vmSymbols::object_initializer_name()) {
     set_bytecode_1(invoke_code);
+    }
   } else if (byte_no == 2)  {
     if (change_to_virtual) {
       assert(invoke_code == Bytecodes::_invokeinterface, "");
@@ -234,17 +241,18 @@ void ConstantPoolCacheEntry::set_direct_or_vtable_call(Bytecodes::Code invoke_co
   NOT_PRODUCT(verify(tty));
 }
 
-void ConstantPoolCacheEntry::set_direct_call(Bytecodes::Code invoke_code, methodHandle method) {
+void ConstantPoolCacheEntry::set_direct_call(Bytecodes::Code invoke_code, methodHandle method,
+                                             bool sender_is_interface) {
   int index = Method::nonvirtual_vtable_index;
   // index < 0; FIXME: inline and customize set_direct_or_vtable_call
-  set_direct_or_vtable_call(invoke_code, method, index);
+  set_direct_or_vtable_call(invoke_code, method, index, sender_is_interface);
 }
 
 void ConstantPoolCacheEntry::set_vtable_call(Bytecodes::Code invoke_code, methodHandle method, int index) {
   // either the method is a miranda or its holder should accept the given index
   assert(method->method_holder()->is_interface() || method->method_holder()->verify_vtable_index(index), "");
   // index >= 0; FIXME: inline and customize set_direct_or_vtable_call
-  set_direct_or_vtable_call(invoke_code, method, index);
+  set_direct_or_vtable_call(invoke_code, method, index, false);
 }
 
 void ConstantPoolCacheEntry::set_itable_call(Bytecodes::Code invoke_code, const methodHandle& method, int index) {
diff --git a/hotspot/src/share/vm/oops/cpCache.hpp b/hotspot/src/share/vm/oops/cpCache.hpp
index e58d7c16ceb..9db57ffa033 100644
--- a/hotspot/src/share/vm/oops/cpCache.hpp
+++ b/hotspot/src/share/vm/oops/cpCache.hpp
@@ -230,13 +230,15 @@ class ConstantPoolCacheEntry VALUE_OBJ_CLASS_SPEC {
   void set_direct_or_vtable_call(
     Bytecodes::Code invoke_code,                 // the bytecode used for invoking the method
     methodHandle    method,                      // the method/prototype if any (NULL, otherwise)
-    int             vtable_index                 // the vtable index if any, else negative
+    int             vtable_index,                // the vtable index if any, else negative
+    bool            sender_is_interface
   );
 
  public:
   void set_direct_call(                          // sets entry to exact concrete method entry
     Bytecodes::Code invoke_code,                 // the bytecode used for invoking the method
-    methodHandle    method                       // the method to call
+    methodHandle    method,                      // the method to call
+    bool            sender_is_interface
   );
 
   void set_vtable_call(                          // sets entry to vtable index
@@ -359,7 +361,9 @@ class ConstantPoolCacheEntry VALUE_OBJ_CLASS_SPEC {
                                                    return (TosState)((_flags >> tos_state_shift) & tos_state_mask); }
 
   // Code generation support
-  static WordSize size()                         { return in_WordSize(sizeof(ConstantPoolCacheEntry) / wordSize); }
+  static WordSize size()                         {
+    return in_WordSize(align_size_up(sizeof(ConstantPoolCacheEntry), wordSize) / wordSize);
+  }
   static ByteSize size_in_bytes()                { return in_ByteSize(sizeof(ConstantPoolCacheEntry)); }
   static ByteSize indices_offset()               { return byte_offset_of(ConstantPoolCacheEntry, _indices); }
   static ByteSize f1_offset()                    { return byte_offset_of(ConstantPoolCacheEntry, _f1); }
diff --git a/hotspot/src/share/vm/oops/instanceKlass.cpp b/hotspot/src/share/vm/oops/instanceKlass.cpp
index 41f5fd143a8..044d26e5219 100644
--- a/hotspot/src/share/vm/oops/instanceKlass.cpp
+++ b/hotspot/src/share/vm/oops/instanceKlass.cpp
@@ -2331,21 +2331,21 @@ void InstanceKlass::set_package(ClassLoaderData* loader_data, TRAPS) {
              name()->as_C_string(), loader_data->loader_name());
     }
 
-    if (log_is_enabled(Debug, modules)) {
+    if (log_is_enabled(Debug, module)) {
       ResourceMark rm;
       ModuleEntry* m = _package_entry->module();
-      log_trace(modules)("Setting package: class: %s, package: %s, loader: %s, module: %s",
-                         external_name(),
-                         pkg_name->as_C_string(),
-                         loader_data->loader_name(),
-                         (m->is_named() ? m->name()->as_C_string() : UNNAMED_MODULE));
+      log_trace(module)("Setting package: class: %s, package: %s, loader: %s, module: %s",
+                        external_name(),
+                        pkg_name->as_C_string(),
+                        loader_data->loader_name(),
+                        (m->is_named() ? m->name()->as_C_string() : UNNAMED_MODULE));
     }
   } else {
     ResourceMark rm;
-    log_trace(modules)("Setting package: class: %s, package: unnamed, loader: %s, module: %s",
-                       external_name(),
-                       (loader_data != NULL) ? loader_data->loader_name() : "NULL",
-                       UNNAMED_MODULE);
+    log_trace(module)("Setting package: class: %s, package: unnamed, loader: %s, module: %s",
+                      external_name(),
+                      (loader_data != NULL) ? loader_data->loader_name() : "NULL",
+                      UNNAMED_MODULE);
   }
 }
 
@@ -2456,22 +2456,24 @@ Klass* InstanceKlass::compute_enclosing_class_impl(instanceKlassHandle self,
 void InstanceKlass::check_prohibited_package(Symbol* class_name,
                                              Handle class_loader,
                                              TRAPS) {
-  ResourceMark rm(THREAD);
   if (!class_loader.is_null() &&
       !SystemDictionary::is_platform_class_loader(class_loader) &&
-      class_name != NULL &&
-      strncmp(class_name->as_C_string(), JAVAPKG, JAVAPKG_LEN) == 0) {
-    TempNewSymbol pkg_name = InstanceKlass::package_from_name(class_name, CHECK);
-    assert(pkg_name != NULL, "Error in parsing package name starting with 'java/'");
-    char* name = pkg_name->as_C_string();
-    const char* class_loader_name = SystemDictionary::loader_name(class_loader());
-    StringUtils::replace_no_expand(name, "/", ".");
-    const char* msg_text1 = "Class loader (instance of): ";
-    const char* msg_text2 = " tried to load prohibited package name: ";
-    size_t len = strlen(msg_text1) + strlen(class_loader_name) + strlen(msg_text2) + strlen(name) + 1;
-    char* message = NEW_RESOURCE_ARRAY_IN_THREAD(THREAD, char, len);
-    jio_snprintf(message, len, "%s%s%s%s", msg_text1, class_loader_name, msg_text2, name);
-    THROW_MSG(vmSymbols::java_lang_SecurityException(), message);
+      class_name != NULL) {
+    ResourceMark rm(THREAD);
+    char* name = class_name->as_C_string();
+    if (strncmp(name, JAVAPKG, JAVAPKG_LEN) == 0 && name[JAVAPKG_LEN] == '/') {
+      TempNewSymbol pkg_name = InstanceKlass::package_from_name(class_name, CHECK);
+      assert(pkg_name != NULL, "Error in parsing package name starting with 'java/'");
+      name = pkg_name->as_C_string();
+      const char* class_loader_name = SystemDictionary::loader_name(class_loader());
+      StringUtils::replace_no_expand(name, "/", ".");
+      const char* msg_text1 = "Class loader (instance of): ";
+      const char* msg_text2 = " tried to load prohibited package name: ";
+      size_t len = strlen(msg_text1) + strlen(class_loader_name) + strlen(msg_text2) + strlen(name) + 1;
+      char* message = NEW_RESOURCE_ARRAY_IN_THREAD(THREAD, char, len);
+      jio_snprintf(message, len, "%s%s%s%s", msg_text1, class_loader_name, msg_text2, name);
+      THROW_MSG(vmSymbols::java_lang_SecurityException(), message);
+    }
   }
   return;
 }
@@ -2806,7 +2808,7 @@ nmethod* InstanceKlass::lookup_osr_nmethod(const Method* m, int bci, int comp_le
   return NULL;
 }
 
-bool InstanceKlass::add_member_name(Handle mem_name) {
+oop InstanceKlass::add_member_name(Handle mem_name, bool intern) {
   jweak mem_name_wref = JNIHandles::make_weak_global(mem_name);
   MutexLocker ml(MemberNameTable_lock);
   DEBUG_ONLY(NoSafepointVerifier nsv);
@@ -2816,7 +2818,7 @@ bool InstanceKlass::add_member_name(Handle mem_name) {
   // is called!
   Method* method = (Method*)java_lang_invoke_MemberName::vmtarget(mem_name());
   if (method->is_obsolete()) {
-    return false;
+    return NULL;
   } else if (method->is_old()) {
     // Replace method with redefined version
     java_lang_invoke_MemberName::set_vmtarget(mem_name(), method_with_idnum(method->method_idnum()));
@@ -2825,8 +2827,11 @@ bool InstanceKlass::add_member_name(Handle mem_name) {
   if (_member_names == NULL) {
     _member_names = new (ResourceObj::C_HEAP, mtClass) MemberNameTable(idnum_allocated_count());
   }
-  _member_names->add_member_name(mem_name_wref);
-  return true;
+  if (intern) {
+    return _member_names->find_or_add_member_name(mem_name_wref);
+  } else {
+    return _member_names->add_member_name(mem_name_wref);
+  }
 }
 
 // -----------------------------------------------------------------------------------------------------
diff --git a/hotspot/src/share/vm/oops/instanceKlass.hpp b/hotspot/src/share/vm/oops/instanceKlass.hpp
index 015a86c7e9c..1756b9fc86d 100644
--- a/hotspot/src/share/vm/oops/instanceKlass.hpp
+++ b/hotspot/src/share/vm/oops/instanceKlass.hpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -1359,7 +1359,7 @@ public:
   // JSR-292 support
   MemberNameTable* member_names() { return _member_names; }
   void set_member_names(MemberNameTable* member_names) { _member_names = member_names; }
-  bool add_member_name(Handle member_name);
+  oop add_member_name(Handle member_name, bool intern);
 
 public:
   // JVMTI support
diff --git a/hotspot/src/share/vm/oops/klass.cpp b/hotspot/src/share/vm/oops/klass.cpp
index ebc59953842..d8ec1ba8875 100644
--- a/hotspot/src/share/vm/oops/klass.cpp
+++ b/hotspot/src/share/vm/oops/klass.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -532,7 +532,7 @@ void Klass::restore_unshareable_info(ClassLoaderData* loader_data, Handle protec
     } else {
       module_entry = ModuleEntryTable::javabase_moduleEntry();
     }
-    // Obtain java.lang.reflect.Module, if available
+    // Obtain java.lang.Module, if available
     Handle module_handle(THREAD, ((module_entry != NULL) ? JNIHandles::resolve(module_entry->module()) : (oop)NULL));
     java_lang_Class::create_mirror(this, loader, module_handle, protection_domain, CHECK);
   }
diff --git a/hotspot/src/share/vm/oops/metadata.hpp b/hotspot/src/share/vm/oops/metadata.hpp
index c42997292e2..b6d60e6a6ef 100644
--- a/hotspot/src/share/vm/oops/metadata.hpp
+++ b/hotspot/src/share/vm/oops/metadata.hpp
@@ -47,6 +47,7 @@ class Metadata : public MetaspaceObj {
   virtual bool is_method()             const volatile { return false; }
   virtual bool is_methodData()         const volatile { return false; }
   virtual bool is_constantPool()       const volatile { return false; }
+  virtual bool is_methodCounters()     const volatile { return false; }
 
   virtual const char* internal_name()  const = 0;
 
diff --git a/hotspot/src/share/vm/oops/method.cpp b/hotspot/src/share/vm/oops/method.cpp
index f37278edd13..beed68bed8e 100644
--- a/hotspot/src/share/vm/oops/method.cpp
+++ b/hotspot/src/share/vm/oops/method.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -2199,7 +2199,6 @@ void Method::print_on(outputStream* st) const {
   ResourceMark rm;
   assert(is_method(), "must be method");
   st->print_cr("%s", internal_name());
-  // get the effect of PrintOopAddress, always, for methods:
   st->print_cr(" - this oop:          " INTPTR_FORMAT, p2i(this));
   st->print   (" - method holder:     "); method_holder()->print_value_on(st); st->cr();
   st->print   (" - constants:         " INTPTR_FORMAT " ", p2i(constants()));
diff --git a/hotspot/src/share/vm/oops/method.hpp b/hotspot/src/share/vm/oops/method.hpp
index ebd5f0feef2..6675410db81 100644
--- a/hotspot/src/share/vm/oops/method.hpp
+++ b/hotspot/src/share/vm/oops/method.hpp
@@ -671,7 +671,9 @@ class Method : public Metadata {
 #endif
 
   // sizing
-  static int header_size()                       { return sizeof(Method)/wordSize; }
+  static int header_size()                       {
+    return align_size_up(sizeof(Method), wordSize) / wordSize;
+  }
   static int size(bool is_native);
   int size() const                               { return method_size(); }
 #if INCLUDE_SERVICES
diff --git a/hotspot/src/share/vm/oops/methodCounters.cpp b/hotspot/src/share/vm/oops/methodCounters.cpp
index b78b6e8046b..225573e5220 100644
--- a/hotspot/src/share/vm/oops/methodCounters.cpp
+++ b/hotspot/src/share/vm/oops/methodCounters.cpp
@@ -73,3 +73,11 @@ void MethodCounters::set_highest_osr_comp_level(int level) {
 #endif
 }
 
+
+void MethodCounters::print_value_on(outputStream* st) const {
+  assert(is_methodCounters(), "must be methodCounters");
+  st->print("method counters");
+  print_address_on(st);
+}
+
+
diff --git a/hotspot/src/share/vm/oops/methodCounters.hpp b/hotspot/src/share/vm/oops/methodCounters.hpp
index df96b638735..97ddc4b5406 100644
--- a/hotspot/src/share/vm/oops/methodCounters.hpp
+++ b/hotspot/src/share/vm/oops/methodCounters.hpp
@@ -30,7 +30,7 @@
 #include "interpreter/invocationCounter.hpp"
 #include "runtime/arguments.hpp"
 
-class MethodCounters: public MetaspaceObj {
+class MethodCounters : public Metadata {
  friend class VMStructs;
  friend class JVMCIVMStructs;
  private:
@@ -109,16 +109,17 @@ class MethodCounters: public MetaspaceObj {
   }
 
  public:
+  virtual bool is_methodCounters() const volatile { return true; }
+
   static MethodCounters* allocate(methodHandle mh, TRAPS);
 
   void deallocate_contents(ClassLoaderData* loader_data) {}
-  DEBUG_ONLY(bool on_stack() { return false; })  // for template
 
   AOT_ONLY(Method* method() const { return _method; })
 
-  static int size() { return sizeof(MethodCounters) / wordSize; }
-
-  bool is_klass() const { return false; }
+  static int size() {
+    return align_size_up(sizeof(MethodCounters), wordSize) / wordSize;
+  }
 
   void clear_counters();
 
@@ -251,5 +252,9 @@ class MethodCounters: public MetaspaceObj {
   static ByteSize backedge_mask_offset() {
     return byte_offset_of(MethodCounters, _backedge_mask);
   }
+
+  virtual const char* internal_name() const { return "{method counters}"; }
+  virtual void print_value_on(outputStream* st) const;
+
 };
 #endif //SHARE_VM_OOPS_METHODCOUNTERS_HPP
diff --git a/hotspot/src/share/vm/opto/arraycopynode.cpp b/hotspot/src/share/vm/opto/arraycopynode.cpp
index a81d7a96b8a..01fe12c8173 100644
--- a/hotspot/src/share/vm/opto/arraycopynode.cpp
+++ b/hotspot/src/share/vm/opto/arraycopynode.cpp
@@ -25,6 +25,7 @@
 #include "precompiled.hpp"
 #include "opto/arraycopynode.hpp"
 #include "opto/graphKit.hpp"
+#include "runtime/sharedRuntime.hpp"
 
 ArrayCopyNode::ArrayCopyNode(Compile* C, bool alloc_tightly_coupled, bool has_negative_length_guard)
   : CallNode(arraycopy_type(), NULL, TypeRawPtr::BOTTOM),
@@ -225,7 +226,6 @@ bool ArrayCopyNode::prepare_array_copy(PhaseGVN *phase, bool can_reshape,
   Node* dest = in(ArrayCopyNode::Dest);
   const Type* src_type = phase->type(src);
   const TypeAryPtr* ary_src = src_type->isa_aryptr();
-  assert(ary_src != NULL, "should be an array copy/clone");
 
   if (is_arraycopy() || is_copyofrange() || is_copyof()) {
     const Type* dest_type = phase->type(dest);
@@ -286,7 +286,8 @@ bool ArrayCopyNode::prepare_array_copy(PhaseGVN *phase, bool can_reshape,
 
     copy_type = dest_elem;
   } else {
-    assert (is_clonebasic(), "should be");
+    assert(ary_src != NULL, "should be a clone");
+    assert(is_clonebasic(), "should be");
 
     disjoint_bases = true;
     assert(src->is_AddP(), "should be base + off");
@@ -631,42 +632,76 @@ bool ArrayCopyNode::may_modify(const TypeOopPtr *t_oop, PhaseTransform *phase) {
   return CallNode::may_modify_arraycopy_helper(dest_t, t_oop, phase);
 }
 
-bool ArrayCopyNode::may_modify_helper(const TypeOopPtr *t_oop, Node* n, PhaseTransform *phase, ArrayCopyNode*& ac) {
-  if (n->Opcode() == Op_StoreCM ||
-      n->Opcode() == Op_StoreB) {
-    // Ignore card mark stores
-    n = n->in(MemNode::Memory);
-  }
-
-  if (n->is_Proj()) {
-    n = n->in(0);
-    if (n->is_Call() && n->as_Call()->may_modify(t_oop, phase)) {
-      if (n->isa_ArrayCopy() != NULL) {
-        ac = n->as_ArrayCopy();
-      }
-      return true;
-    }
+bool ArrayCopyNode::may_modify_helper(const TypeOopPtr *t_oop, Node* n, PhaseTransform *phase, CallNode*& call) {
+  if (n != NULL &&
+      n->is_Call() &&
+      n->as_Call()->may_modify(t_oop, phase) &&
+      (n->as_Call()->is_ArrayCopy() || n->as_Call()->is_call_to_arraycopystub())) {
+    call = n->as_Call();
+    return true;
   }
   return false;
 }
 
-bool ArrayCopyNode::may_modify(const TypeOopPtr *t_oop, MemBarNode* mb, PhaseTransform *phase, ArrayCopyNode*& ac) {
-  Node* mem = mb->in(TypeFunc::Memory);
-
-  if (mem->is_MergeMem()) {
-    Node* n = mem->as_MergeMem()->memory_at(Compile::AliasIdxRaw);
-    if (may_modify_helper(t_oop, n, phase, ac)) {
-      return true;
-    } else if (n->is_Phi()) {
-      for (uint i = 1; i < n->req(); i++) {
-        if (n->in(i) != NULL) {
-          if (may_modify_helper(t_oop, n->in(i), phase, ac)) {
-            return true;
+static Node* step_over_gc_barrier(Node* c) {
+  if (UseG1GC && !GraphKit::use_ReduceInitialCardMarks() &&
+      c != NULL && c->is_Region() && c->req() == 3) {
+    for (uint i = 1; i < c->req(); i++) {
+      if (c->in(i) != NULL && c->in(i)->is_Region() &&
+          c->in(i)->req() == 3) {
+        Node* r = c->in(i);
+        for (uint j = 1; j < r->req(); j++) {
+          if (r->in(j) != NULL && r->in(j)->is_Proj() &&
+              r->in(j)->in(0) != NULL &&
+              r->in(j)->in(0)->Opcode() == Op_CallLeaf &&
+              r->in(j)->in(0)->as_Call()->entry_point() == CAST_FROM_FN_PTR(address, SharedRuntime::g1_wb_post)) {
+            Node* call = r->in(j)->in(0);
+            c = c->in(i == 1 ? 2 : 1);
+            if (c != NULL) {
+              c = c->in(0);
+              if (c != NULL) {
+                c = c->in(0);
+                assert(call->in(0) == NULL ||
+                       call->in(0)->in(0) == NULL ||
+                       call->in(0)->in(0)->in(0) == NULL ||
+                       call->in(0)->in(0)->in(0)->in(0) == NULL ||
+                       call->in(0)->in(0)->in(0)->in(0)->in(0) == NULL ||
+                       c == call->in(0)->in(0)->in(0)->in(0)->in(0), "bad barrier shape");
+                return c;
+              }
+            }
           }
         }
       }
     }
   }
+  return c;
+}
+
+bool ArrayCopyNode::may_modify(const TypeOopPtr *t_oop, MemBarNode* mb, PhaseTransform *phase, ArrayCopyNode*& ac) {
+
+  Node* c = mb->in(0);
+
+  // step over g1 gc barrier if we're at a clone with ReduceInitialCardMarks off
+  c = step_over_gc_barrier(c);
+
+  CallNode* call = NULL;
+  if (c != NULL && c->is_Region()) {
+    for (uint i = 1; i < c->req(); i++) {
+      if (c->in(i) != NULL) {
+        Node* n = c->in(i)->in(0);
+        if (may_modify_helper(t_oop, n, phase, call)) {
+          ac = call->isa_ArrayCopy();
+          assert(c == mb->in(0), "only for clone");
+          return true;
+        }
+      }
+    }
+  } else if (may_modify_helper(t_oop, c->in(0), phase, call)) {
+    ac = call->isa_ArrayCopy();
+    assert(c == mb->in(0) || (ac != NULL && ac->is_clonebasic() && !GraphKit::use_ReduceInitialCardMarks()), "only for clone");
+    return true;
+  }
 
   return false;
 }
@@ -677,37 +712,77 @@ bool ArrayCopyNode::may_modify(const TypeOopPtr *t_oop, MemBarNode* mb, PhaseTra
 // between offset_lo and offset_hi
 // if must_modify is true, return true if the copy is guaranteed to
 // write between offset_lo and offset_hi
-bool ArrayCopyNode::modifies(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase, bool must_modify) {
+bool ArrayCopyNode::modifies(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase, bool must_modify) const {
   assert(_kind == ArrayCopy || _kind == CopyOf || _kind == CopyOfRange, "only for real array copies");
 
-  Node* dest = in(ArrayCopyNode::Dest);
-  Node* src_pos = in(ArrayCopyNode::SrcPos);
-  Node* dest_pos = in(ArrayCopyNode::DestPos);
-  Node* len = in(ArrayCopyNode::Length);
+  Node* dest = in(Dest);
+  Node* dest_pos = in(DestPos);
+  Node* len = in(Length);
 
   const TypeInt *dest_pos_t = phase->type(dest_pos)->isa_int();
   const TypeInt *len_t = phase->type(len)->isa_int();
   const TypeAryPtr* ary_t = phase->type(dest)->isa_aryptr();
 
-  if (dest_pos_t != NULL && len_t != NULL && ary_t != NULL) {
-    BasicType ary_elem = ary_t->klass()->as_array_klass()->element_type()->basic_type();
-    uint header = arrayOopDesc::base_offset_in_bytes(ary_elem);
-    uint elemsize = type2aelembytes(ary_elem);
+  if (dest_pos_t == NULL || len_t == NULL || ary_t == NULL) {
+    return !must_modify;
+  }
 
-    jlong dest_pos_plus_len_lo = (((jlong)dest_pos_t->_lo) + len_t->_lo) * elemsize + header;
-    jlong dest_pos_plus_len_hi = (((jlong)dest_pos_t->_hi) + len_t->_hi) * elemsize + header;
-    jlong dest_pos_lo = ((jlong)dest_pos_t->_lo) * elemsize + header;
-    jlong dest_pos_hi = ((jlong)dest_pos_t->_hi) * elemsize + header;
+  BasicType ary_elem = ary_t->klass()->as_array_klass()->element_type()->basic_type();
+  uint header = arrayOopDesc::base_offset_in_bytes(ary_elem);
+  uint elemsize = type2aelembytes(ary_elem);
 
-    if (must_modify) {
-      if (offset_lo >= dest_pos_hi && offset_hi < dest_pos_plus_len_lo) {
-        return true;
-      }
-    } else {
-      if (offset_hi >= dest_pos_lo && offset_lo < dest_pos_plus_len_hi) {
-        return true;
-      }
+  jlong dest_pos_plus_len_lo = (((jlong)dest_pos_t->_lo) + len_t->_lo) * elemsize + header;
+  jlong dest_pos_plus_len_hi = (((jlong)dest_pos_t->_hi) + len_t->_hi) * elemsize + header;
+  jlong dest_pos_lo = ((jlong)dest_pos_t->_lo) * elemsize + header;
+  jlong dest_pos_hi = ((jlong)dest_pos_t->_hi) * elemsize + header;
+
+  if (must_modify) {
+    if (offset_lo >= dest_pos_hi && offset_hi < dest_pos_plus_len_lo) {
+      return true;
+    }
+  } else {
+    if (offset_hi >= dest_pos_lo && offset_lo < dest_pos_plus_len_hi) {
+      return true;
     }
   }
   return false;
 }
+
+// We try to replace a load from the destination of an arraycopy with
+// a load from the source so the arraycopy has a chance to be
+// eliminated. It's only valid if the arraycopy doesn't change the
+// element that would be loaded from the source array.
+bool ArrayCopyNode::can_replace_dest_load_with_src_load(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase) const {
+  assert(_kind == ArrayCopy || _kind == CopyOf || _kind == CopyOfRange, "only for real array copies");
+
+  Node* src = in(Src);
+  Node* dest = in(Dest);
+
+  // Check whether, assuming source and destination are the same
+  // array, the arraycopy modifies the element from the source we
+  // would load.
+  if ((src != dest && in(SrcPos) == in(DestPos)) || !modifies(offset_lo, offset_hi, phase, false)) {
+    // if not the transformation is legal
+    return true;
+  }
+
+  AllocateNode* src_alloc = AllocateNode::Ideal_allocation(src, phase);
+  AllocateNode* dest_alloc = AllocateNode::Ideal_allocation(dest, phase);
+
+  // Check whether source and destination can be proved to be
+  // different arrays
+  const TypeOopPtr* t_src = phase->type(src)->isa_oopptr();
+  const TypeOopPtr* t_dest = phase->type(dest)->isa_oopptr();
+
+  if (t_src != NULL && t_dest != NULL &&
+      (t_src->is_known_instance() || t_dest->is_known_instance()) &&
+      t_src->instance_id() != t_dest->instance_id()) {
+    return true;
+  }
+
+  if (MemNode::detect_ptr_independence(src->uncast(), src_alloc, dest->uncast(), dest_alloc, phase)) {
+    return true;
+  }
+
+  return false;
+}
diff --git a/hotspot/src/share/vm/opto/arraycopynode.hpp b/hotspot/src/share/vm/opto/arraycopynode.hpp
index 58d641727d8..46e57003168 100644
--- a/hotspot/src/share/vm/opto/arraycopynode.hpp
+++ b/hotspot/src/share/vm/opto/arraycopynode.hpp
@@ -108,7 +108,7 @@ private:
                             BasicType copy_type, const Type* value_type, int count);
   bool finish_transform(PhaseGVN *phase, bool can_reshape,
                         Node* ctl, Node *mem);
-  static bool may_modify_helper(const TypeOopPtr *t_oop, Node* n, PhaseTransform *phase, ArrayCopyNode*& ac);
+  static bool may_modify_helper(const TypeOopPtr *t_oop, Node* n, PhaseTransform *phase, CallNode*& call);
 
 public:
 
@@ -167,7 +167,8 @@ public:
   bool has_negative_length_guard() const { return _has_negative_length_guard; }
 
   static bool may_modify(const TypeOopPtr *t_oop, MemBarNode* mb, PhaseTransform *phase, ArrayCopyNode*& ac);
-  bool modifies(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase, bool must_modify);
+  bool modifies(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase, bool must_modify) const;
+  bool can_replace_dest_load_with_src_load(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase) const;
 
 #ifndef PRODUCT
   virtual void dump_spec(outputStream *st) const;
diff --git a/hotspot/src/share/vm/opto/c2compiler.cpp b/hotspot/src/share/vm/opto/c2compiler.cpp
index ec7e03c5ff0..69106bbeaa2 100644
--- a/hotspot/src/share/vm/opto/c2compiler.cpp
+++ b/hotspot/src/share/vm/opto/c2compiler.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -244,8 +244,8 @@ bool C2Compiler::is_intrinsic_supported(const methodHandle& method, bool is_virt
     if (!Matcher::match_rule_supported(Op_ReverseBytesL)) return false;
     break;
 
-  /* CompareAndSwap, Object: */
-  case vmIntrinsics::_compareAndSwapObject:
+  /* CompareAndSet, Object: */
+  case vmIntrinsics::_compareAndSetObject:
 #ifdef _LP64
     if ( UseCompressedOops && !Matcher::match_rule_supported(Op_CompareAndSwapN)) return false;
     if (!UseCompressedOops && !Matcher::match_rule_supported(Op_CompareAndSwapP)) return false;
@@ -253,10 +253,10 @@ bool C2Compiler::is_intrinsic_supported(const methodHandle& method, bool is_virt
     if (!Matcher::match_rule_supported(Op_CompareAndSwapP)) return false;
 #endif
     break;
-  case vmIntrinsics::_weakCompareAndSwapObject:
-  case vmIntrinsics::_weakCompareAndSwapObjectAcquire:
-  case vmIntrinsics::_weakCompareAndSwapObjectRelease:
-  case vmIntrinsics::_weakCompareAndSwapObjectVolatile:
+  case vmIntrinsics::_weakCompareAndSetObjectPlain:
+  case vmIntrinsics::_weakCompareAndSetObjectAcquire:
+  case vmIntrinsics::_weakCompareAndSetObjectRelease:
+  case vmIntrinsics::_weakCompareAndSetObject:
 #ifdef _LP64
     if ( UseCompressedOops && !Matcher::match_rule_supported(Op_WeakCompareAndSwapN)) return false;
     if (!UseCompressedOops && !Matcher::match_rule_supported(Op_WeakCompareAndSwapP)) return false;
@@ -264,52 +264,52 @@ bool C2Compiler::is_intrinsic_supported(const methodHandle& method, bool is_virt
     if (!Matcher::match_rule_supported(Op_WeakCompareAndSwapP)) return false;
 #endif
     break;
-  /* CompareAndSwap, Long: */
-  case vmIntrinsics::_compareAndSwapLong:
+  /* CompareAndSet, Long: */
+  case vmIntrinsics::_compareAndSetLong:
     if (!Matcher::match_rule_supported(Op_CompareAndSwapL)) return false;
     break;
-  case vmIntrinsics::_weakCompareAndSwapLong:
-  case vmIntrinsics::_weakCompareAndSwapLongAcquire:
-  case vmIntrinsics::_weakCompareAndSwapLongRelease:
-  case vmIntrinsics::_weakCompareAndSwapLongVolatile:
+  case vmIntrinsics::_weakCompareAndSetLongPlain:
+  case vmIntrinsics::_weakCompareAndSetLongAcquire:
+  case vmIntrinsics::_weakCompareAndSetLongRelease:
+  case vmIntrinsics::_weakCompareAndSetLong:
     if (!Matcher::match_rule_supported(Op_WeakCompareAndSwapL)) return false;
     break;
 
-  /* CompareAndSwap, Int: */
-  case vmIntrinsics::_compareAndSwapInt:
+  /* CompareAndSet, Int: */
+  case vmIntrinsics::_compareAndSetInt:
     if (!Matcher::match_rule_supported(Op_CompareAndSwapI)) return false;
     break;
-  case vmIntrinsics::_weakCompareAndSwapInt:
-  case vmIntrinsics::_weakCompareAndSwapIntAcquire:
-  case vmIntrinsics::_weakCompareAndSwapIntRelease:
-  case vmIntrinsics::_weakCompareAndSwapIntVolatile:
+  case vmIntrinsics::_weakCompareAndSetIntPlain:
+  case vmIntrinsics::_weakCompareAndSetIntAcquire:
+  case vmIntrinsics::_weakCompareAndSetIntRelease:
+  case vmIntrinsics::_weakCompareAndSetInt:
     if (!Matcher::match_rule_supported(Op_WeakCompareAndSwapL)) return false;
     break;
 
-  /* CompareAndSwap, Byte: */
-  case vmIntrinsics::_compareAndSwapByte:
+  /* CompareAndSet, Byte: */
+  case vmIntrinsics::_compareAndSetByte:
     if (!Matcher::match_rule_supported(Op_CompareAndSwapB)) return false;
     break;
-  case vmIntrinsics::_weakCompareAndSwapByte:
-  case vmIntrinsics::_weakCompareAndSwapByteAcquire:
-  case vmIntrinsics::_weakCompareAndSwapByteRelease:
-  case vmIntrinsics::_weakCompareAndSwapByteVolatile:
+  case vmIntrinsics::_weakCompareAndSetBytePlain:
+  case vmIntrinsics::_weakCompareAndSetByteAcquire:
+  case vmIntrinsics::_weakCompareAndSetByteRelease:
+  case vmIntrinsics::_weakCompareAndSetByte:
     if (!Matcher::match_rule_supported(Op_WeakCompareAndSwapB)) return false;
     break;
 
-  /* CompareAndSwap, Short: */
-  case vmIntrinsics::_compareAndSwapShort:
+  /* CompareAndSet, Short: */
+  case vmIntrinsics::_compareAndSetShort:
     if (!Matcher::match_rule_supported(Op_CompareAndSwapS)) return false;
     break;
-  case vmIntrinsics::_weakCompareAndSwapShort:
-  case vmIntrinsics::_weakCompareAndSwapShortAcquire:
-  case vmIntrinsics::_weakCompareAndSwapShortRelease:
-  case vmIntrinsics::_weakCompareAndSwapShortVolatile:
+  case vmIntrinsics::_weakCompareAndSetShortPlain:
+  case vmIntrinsics::_weakCompareAndSetShortAcquire:
+  case vmIntrinsics::_weakCompareAndSetShortRelease:
+  case vmIntrinsics::_weakCompareAndSetShort:
     if (!Matcher::match_rule_supported(Op_WeakCompareAndSwapS)) return false;
     break;
 
   /* CompareAndExchange, Object: */
-  case vmIntrinsics::_compareAndExchangeObjectVolatile:
+  case vmIntrinsics::_compareAndExchangeObject:
   case vmIntrinsics::_compareAndExchangeObjectAcquire:
   case vmIntrinsics::_compareAndExchangeObjectRelease:
 #ifdef _LP64
@@ -321,28 +321,28 @@ bool C2Compiler::is_intrinsic_supported(const methodHandle& method, bool is_virt
     break;
 
   /* CompareAndExchange, Long: */
-  case vmIntrinsics::_compareAndExchangeLongVolatile:
+  case vmIntrinsics::_compareAndExchangeLong:
   case vmIntrinsics::_compareAndExchangeLongAcquire:
   case vmIntrinsics::_compareAndExchangeLongRelease:
     if (!Matcher::match_rule_supported(Op_CompareAndExchangeL)) return false;
     break;
 
   /* CompareAndExchange, Int: */
-  case vmIntrinsics::_compareAndExchangeIntVolatile:
+  case vmIntrinsics::_compareAndExchangeInt:
   case vmIntrinsics::_compareAndExchangeIntAcquire:
   case vmIntrinsics::_compareAndExchangeIntRelease:
     if (!Matcher::match_rule_supported(Op_CompareAndExchangeI)) return false;
     break;
 
   /* CompareAndExchange, Byte: */
-  case vmIntrinsics::_compareAndExchangeByteVolatile:
+  case vmIntrinsics::_compareAndExchangeByte:
   case vmIntrinsics::_compareAndExchangeByteAcquire:
   case vmIntrinsics::_compareAndExchangeByteRelease:
     if (!Matcher::match_rule_supported(Op_CompareAndExchangeB)) return false;
     break;
 
   /* CompareAndExchange, Short: */
-  case vmIntrinsics::_compareAndExchangeShortVolatile:
+  case vmIntrinsics::_compareAndExchangeShort:
   case vmIntrinsics::_compareAndExchangeShortAcquire:
   case vmIntrinsics::_compareAndExchangeShortRelease:
     if (!Matcher::match_rule_supported(Op_CompareAndExchangeS)) return false;
diff --git a/hotspot/src/share/vm/opto/callGenerator.cpp b/hotspot/src/share/vm/opto/callGenerator.cpp
index de9f44c359d..a5aaa552fee 100644
--- a/hotspot/src/share/vm/opto/callGenerator.cpp
+++ b/hotspot/src/share/vm/opto/callGenerator.cpp
@@ -46,7 +46,7 @@ const TypeFunc* CallGenerator::tf() const {
   return TypeFunc::make(method());
 }
 
-bool CallGenerator::is_inlined_mh_linker(JVMState* jvms, ciMethod* callee) {
+bool CallGenerator::is_inlined_method_handle_intrinsic(JVMState* jvms, ciMethod* callee) {
   ciMethod* symbolic_info = jvms->method()->get_method_at_bci(jvms->bci());
   return symbolic_info->is_method_handle_intrinsic() && !callee->is_method_handle_intrinsic();
 }
@@ -142,7 +142,7 @@ JVMState* DirectCallGenerator::generate(JVMState* jvms) {
   }
 
   CallStaticJavaNode *call = new CallStaticJavaNode(kit.C, tf(), target, method(), kit.bci());
-  if (is_inlined_mh_linker(jvms, method())) {
+  if (is_inlined_method_handle_intrinsic(jvms, method())) {
     // To be able to issue a direct call and skip a call to MH.linkTo*/invokeBasic adapter,
     // additional information about the method being invoked should be attached
     // to the call site to make resolution logic work
@@ -241,7 +241,7 @@ JVMState* VirtualCallGenerator::generate(JVMState* jvms) {
   address target = SharedRuntime::get_resolve_virtual_call_stub();
   // Normal inline cache used for call
   CallDynamicJavaNode *call = new CallDynamicJavaNode(tf(), target, method(), _vtable_index, kit.bci());
-  if (is_inlined_mh_linker(jvms, method())) {
+  if (is_inlined_method_handle_intrinsic(jvms, method())) {
     // To be able to issue a direct call (optimized virtual or virtual)
     // and skip a call to MH.linkTo*/invokeBasic adapter, additional information
     // about the method being invoked should be attached to the call site to
@@ -785,8 +785,7 @@ JVMState* PredictedCallGenerator::generate(JVMState* jvms) {
 
 
 CallGenerator* CallGenerator::for_method_handle_call(JVMState* jvms, ciMethod* caller, ciMethod* callee, bool delayed_forbidden) {
-  assert(callee->is_method_handle_intrinsic() ||
-         callee->is_compiled_lambda_form(), "for_method_handle_call mismatch");
+  assert(callee->is_method_handle_intrinsic(), "for_method_handle_call mismatch");
   bool input_not_const;
   CallGenerator* cg = CallGenerator::for_method_handle_inline(jvms, caller, callee, input_not_const);
   Compile* C = Compile::current();
@@ -826,6 +825,13 @@ CallGenerator* CallGenerator::for_method_handle_inline(JVMState* jvms, ciMethod*
         const TypeOopPtr* oop_ptr = receiver->bottom_type()->is_oopptr();
         ciMethod* target = oop_ptr->const_oop()->as_method_handle()->get_vmtarget();
         const int vtable_index = Method::invalid_vtable_index;
+
+        if (!ciMethod::is_consistent_info(callee, target)) {
+          print_inlining_failure(C, callee, jvms->depth() - 1, jvms->bci(),
+                                 "signatures mismatch");
+          return NULL;
+        }
+
         CallGenerator* cg = C->call_generator(target, vtable_index,
                                               false /* call_does_dispatch */,
                                               jvms,
@@ -833,9 +839,8 @@ CallGenerator* CallGenerator::for_method_handle_inline(JVMState* jvms, ciMethod*
                                               PROB_ALWAYS);
         return cg;
       } else {
-        const char* msg = "receiver not constant";
-        if (PrintInlining)  C->print_inlining(callee, jvms->depth() - 1, jvms->bci(), msg);
-        C->log_inline_failure(msg);
+        print_inlining_failure(C, callee, jvms->depth() - 1, jvms->bci(),
+                               "receiver not constant");
       }
     }
     break;
@@ -852,6 +857,12 @@ CallGenerator* CallGenerator::for_method_handle_inline(JVMState* jvms, ciMethod*
         const TypeOopPtr* oop_ptr = member_name->bottom_type()->is_oopptr();
         ciMethod* target = oop_ptr->const_oop()->as_member_name()->get_vmtarget();
 
+        if (!ciMethod::is_consistent_info(callee, target)) {
+          print_inlining_failure(C, callee, jvms->depth() - 1, jvms->bci(),
+                                 "signatures mismatch");
+          return NULL;
+        }
+
         // In lambda forms we erase signature types to avoid resolving issues
         // involving class loaders.  When we optimize a method handle invoke
         // to a direct call we must cast the receiver and arguments to its
@@ -912,9 +923,8 @@ CallGenerator* CallGenerator::for_method_handle_inline(JVMState* jvms, ciMethod*
                                               speculative_receiver_type);
         return cg;
       } else {
-        const char* msg = "member_name not constant";
-        if (PrintInlining)  C->print_inlining(callee, jvms->depth() - 1, jvms->bci(), msg);
-        C->log_inline_failure(msg);
+        print_inlining_failure(C, callee, jvms->depth() - 1, jvms->bci(),
+                               "member_name not constant");
       }
     }
     break;
diff --git a/hotspot/src/share/vm/opto/callGenerator.hpp b/hotspot/src/share/vm/opto/callGenerator.hpp
index 58e8fe9c614..8b7ee546571 100644
--- a/hotspot/src/share/vm/opto/callGenerator.hpp
+++ b/hotspot/src/share/vm/opto/callGenerator.hpp
@@ -170,7 +170,12 @@ class CallGenerator : public ResourceObj {
     }
   }
 
-  static bool is_inlined_mh_linker(JVMState* jvms, ciMethod* m);
+  static void print_inlining_failure(Compile* C, ciMethod* callee, int inline_level, int bci, const char* msg) {
+    print_inlining(C, callee, inline_level, bci, msg);
+    C->log_inline_failure(msg);
+  }
+
+  static bool is_inlined_method_handle_intrinsic(JVMState* jvms, ciMethod* m);
 };
 
 
diff --git a/hotspot/src/share/vm/opto/callnode.cpp b/hotspot/src/share/vm/opto/callnode.cpp
index 66b2d086bbd..7def4ee721e 100644
--- a/hotspot/src/share/vm/opto/callnode.cpp
+++ b/hotspot/src/share/vm/opto/callnode.cpp
@@ -784,8 +784,8 @@ bool CallNode::may_modify(const TypeOopPtr *t_oop, PhaseTransform *phase) {
       }
       // May modify (by reflection) if an boxing object is passed
       // as argument or returned.
-      if (returns_pointer() && (proj_out(TypeFunc::Parms) != NULL)) {
-        Node* proj = proj_out(TypeFunc::Parms);
+      Node* proj = returns_pointer() ? proj_out(TypeFunc::Parms) : NULL;
+      if (proj != NULL) {
         const TypeInstPtr* inst_t = phase->type(proj)->isa_instptr();
         if ((inst_t != NULL) && (!inst_t->klass_is_exact() ||
                                  (inst_t->klass() == boxing_klass))) {
diff --git a/hotspot/src/share/vm/opto/callnode.hpp b/hotspot/src/share/vm/opto/callnode.hpp
index 00979ae0d53..f5cc9bcf237 100644
--- a/hotspot/src/share/vm/opto/callnode.hpp
+++ b/hotspot/src/share/vm/opto/callnode.hpp
@@ -452,8 +452,8 @@ public:
   void delete_replaced_nodes() {
     _replaced_nodes.reset();
   }
-  void apply_replaced_nodes() {
-    _replaced_nodes.apply(this);
+  void apply_replaced_nodes(uint idx) {
+    _replaced_nodes.apply(this, idx);
   }
   void merge_replaced_nodes_with(SafePointNode* sfpt) {
     _replaced_nodes.merge_with(sfpt->_replaced_nodes);
diff --git a/hotspot/src/share/vm/opto/castnode.cpp b/hotspot/src/share/vm/opto/castnode.cpp
index 1184728add5..9f829a40008 100644
--- a/hotspot/src/share/vm/opto/castnode.cpp
+++ b/hotspot/src/share/vm/opto/castnode.cpp
@@ -225,7 +225,10 @@ Node *CastIINode::Ideal(PhaseGVN *phase, bool can_reshape) {
   }
 
   // Similar to ConvI2LNode::Ideal() for the same reasons
-  if (can_reshape && !phase->C->major_progress()) {
+  // Do not narrow the type of range check dependent CastIINodes to
+  // avoid corruption of the graph if a CastII is replaced by TOP but
+  // the corresponding range check is not removed.
+  if (can_reshape && !_range_check_dependency && !phase->C->major_progress()) {
     const TypeInt* this_type = this->type()->is_int();
     const TypeInt* in_type = phase->type(in(1))->isa_int();
     if (in_type != NULL && this_type != NULL &&
diff --git a/hotspot/src/share/vm/opto/cfgnode.cpp b/hotspot/src/share/vm/opto/cfgnode.cpp
index de85b1cb155..69e7659a877 100644
--- a/hotspot/src/share/vm/opto/cfgnode.cpp
+++ b/hotspot/src/share/vm/opto/cfgnode.cpp
@@ -1889,6 +1889,12 @@ Node *PhiNode::Ideal(PhaseGVN *phase, bool can_reshape) {
     bool saw_self = false;
     for( uint i=1; iis_MergeMem()) {
         MergeMemNode* n = ii->as_MergeMem();
         merge_width = MAX2(merge_width, n->req());
diff --git a/hotspot/src/share/vm/opto/convertnode.cpp b/hotspot/src/share/vm/opto/convertnode.cpp
index bc111ccae7a..5d97a7330f2 100644
--- a/hotspot/src/share/vm/opto/convertnode.cpp
+++ b/hotspot/src/share/vm/opto/convertnode.cpp
@@ -294,8 +294,7 @@ Node *ConvI2LNode::Ideal(PhaseGVN *phase, bool can_reshape) {
   }
 
 #ifdef _LP64
-  // Convert ConvI2L(AddI(x, y)) to AddL(ConvI2L(x), ConvI2L(y)) or
-  // ConvI2L(CastII(AddI(x, y))) to AddL(ConvI2L(CastII(x)), ConvI2L(CastII(y))),
+  // Convert ConvI2L(AddI(x, y)) to AddL(ConvI2L(x), ConvI2L(y))
   // but only if x and y have subranges that cannot cause 32-bit overflow,
   // under the assumption that x+y is in my own subrange this->type().
 
@@ -319,13 +318,6 @@ Node *ConvI2LNode::Ideal(PhaseGVN *phase, bool can_reshape) {
 
   Node* z = in(1);
   int op = z->Opcode();
-  Node* ctrl = NULL;
-  if (op == Op_CastII && z->as_CastII()->has_range_check()) {
-    // Skip CastII node but save control dependency
-    ctrl = z->in(0);
-    z = z->in(1);
-    op = z->Opcode();
-  }
   if (op == Op_AddI || op == Op_SubI) {
     Node* x = z->in(1);
     Node* y = z->in(2);
@@ -385,8 +377,8 @@ Node *ConvI2LNode::Ideal(PhaseGVN *phase, bool can_reshape) {
     }
     assert(rxlo == (int)rxlo && rxhi == (int)rxhi, "x should not overflow");
     assert(rylo == (int)rylo && ryhi == (int)ryhi, "y should not overflow");
-    Node* cx = phase->C->constrained_convI2L(phase, x, TypeInt::make(rxlo, rxhi, widen), ctrl);
-    Node* cy = phase->C->constrained_convI2L(phase, y, TypeInt::make(rylo, ryhi, widen), ctrl);
+    Node* cx = phase->C->constrained_convI2L(phase, x, TypeInt::make(rxlo, rxhi, widen), NULL);
+    Node* cy = phase->C->constrained_convI2L(phase, y, TypeInt::make(rylo, ryhi, widen), NULL);
     switch (op) {
       case Op_AddI:  return new AddLNode(cx, cy);
       case Op_SubI:  return new SubLNode(cx, cy);
diff --git a/hotspot/src/share/vm/opto/doCall.cpp b/hotspot/src/share/vm/opto/doCall.cpp
index 97af80e61b0..3e9bdd53d07 100644
--- a/hotspot/src/share/vm/opto/doCall.cpp
+++ b/hotspot/src/share/vm/opto/doCall.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1998, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -400,92 +400,10 @@ bool Parse::can_not_compile_call_site(ciMethod *dest_method, ciInstanceKlass* kl
 }
 
 #ifdef ASSERT
-static bool check_type(ciType* t1, ciType* t2) {
-  // Either oop-oop or prim-prim pair.
-  if (t1->is_primitive_type() && t2->is_primitive_type()) {
-    return t1->size() == t2->size(); // argument sizes should match
-  } else {
-    return !t1->is_primitive_type() && !t2->is_primitive_type(); // oop-oop
-  }
-}
-
-static bool check_inlined_mh_linker_info(ciMethod* symbolic_info, ciMethod* resolved_method) {
-  assert(symbolic_info->is_method_handle_intrinsic(), "sanity");
-  assert(!resolved_method->is_method_handle_intrinsic(), "sanity");
-
-  if (!symbolic_info->is_loaded() || !resolved_method->is_loaded()) {
-    return true; // Don't compare unloaded methods.
-  }
-  // Linkers have appendix argument which is not passed to callee.
-  int has_appendix = MethodHandles::has_member_arg(symbolic_info->intrinsic_id()) ? 1 : 0;
-  if (symbolic_info->arg_size() != (resolved_method->arg_size() + has_appendix)) {
-    return false; // Total size of arguments on stack mismatch.
-  }
-  if (!symbolic_info->return_type()->is_void()) {
-    // Only check the return type if the symbolic method is not void
-    // i.e. the return value of the resolved method can be dropped
-    if (!check_type(symbolic_info->return_type(), resolved_method->return_type())) {
-      return false; // Return value size or type mismatch encountered.
-    }
-  }
-
-  switch (symbolic_info->intrinsic_id()) {
-    case vmIntrinsics::_linkToVirtual:
-    case vmIntrinsics::_linkToInterface:
-    case vmIntrinsics::_linkToSpecial: {
-      if (resolved_method->is_static())  return false;
-      break;
-    }
-    case vmIntrinsics::_linkToStatic: {
-      if (!resolved_method->is_static())  return false;
-      break;
-    }
-  }
-
-  ciSignature* symbolic_sig = symbolic_info->signature();
-  ciSignature* resolved_sig = resolved_method->signature();
-
-  if (symbolic_sig->count() + (symbolic_info->is_static() ? 0 : 1) !=
-      resolved_sig->count() + (resolved_method->is_static() ? 0 : 1) + has_appendix) {
-    return false; // Argument count mismatch
-  }
-
-  int sbase = 0, rbase = 0;
-  int arg_count = MIN2(symbolic_sig->count() - has_appendix, resolved_sig->count());
-  ciType* recv_type = NULL;
-  if (symbolic_info->is_static() && !resolved_method->is_static()) {
-    recv_type = symbolic_sig->type_at(0);
-    sbase = 1;
-  } else if (!symbolic_info->is_static() && resolved_method->is_static()) {
-    recv_type = resolved_sig->type_at(0);
-    rbase = 1;
-  }
-  if (recv_type != NULL && recv_type->is_primitive_type()) {
-    return false; // Receiver should be an oop.
-  }
-  for (int i = 0; i < arg_count; i++) {
-    if (!check_type(symbolic_sig->type_at(sbase + i), resolved_sig->type_at(rbase + i))) {
-      return false; // Argument size or type mismatch encountered.
-    }
-  }
-  return true;
-}
-
-static bool is_call_consistent_with_jvms(JVMState* jvms, CallGenerator* cg) {
+static bool check_call_consistency(JVMState* jvms, CallGenerator* cg) {
   ciMethod* symbolic_info = jvms->method()->get_method_at_bci(jvms->bci());
   ciMethod* resolved_method = cg->method();
-
-  if (CallGenerator::is_inlined_mh_linker(jvms, resolved_method)) {
-    return check_inlined_mh_linker_info(symbolic_info, resolved_method);
-  } else {
-    // Method name & descriptor should stay the same.
-    return (symbolic_info->get_Method()->name() == resolved_method->get_Method()->name()) &&
-           (symbolic_info->get_Method()->signature() == resolved_method->get_Method()->signature());
-  }
-}
-
-static bool check_call_consistency(JVMState* jvms, CallGenerator* cg) {
-  if (!is_call_consistent_with_jvms(jvms, cg)) {
+  if (!ciMethod::is_consistent_info(symbolic_info, resolved_method)) {
     tty->print_cr("JVMS:");
     jvms->dump();
     tty->print_cr("Bytecode info:");
@@ -587,6 +505,30 @@ void Parse::do_call() {
     speculative_receiver_type = receiver_type != NULL ? receiver_type->speculative_type() : NULL;
   }
 
+  // invoke-super-special
+  if (iter().cur_bc_raw() == Bytecodes::_invokespecial && !orig_callee->is_object_initializer()) {
+    ciInstanceKlass* calling_klass = method()->holder();
+    ciInstanceKlass* sender_klass =
+        calling_klass->is_anonymous() ? calling_klass->host_klass() :
+                                        calling_klass;
+    if (sender_klass->is_interface()) {
+      Node* receiver_node = stack(sp() - nargs);
+      Node* cls_node = makecon(TypeKlassPtr::make(sender_klass));
+      Node* bad_type_ctrl = NULL;
+      Node* casted_receiver = gen_checkcast(receiver_node, cls_node, &bad_type_ctrl);
+      if (bad_type_ctrl != NULL) {
+        PreserveJVMState pjvms(this);
+        set_control(bad_type_ctrl);
+        uncommon_trap(Deoptimization::Reason_class_check,
+                      Deoptimization::Action_none);
+      }
+      if (stopped()) {
+        return; // MUST uncommon-trap?
+      }
+      set_stack(sp() - nargs, casted_receiver);
+    }
+  }
+
   // Note:  It's OK to try to inline a virtual call.
   // The call generator will not attempt to inline a polymorphic call
   // unless it knows how to optimize the receiver dispatch.
diff --git a/hotspot/src/share/vm/opto/ifnode.cpp b/hotspot/src/share/vm/opto/ifnode.cpp
index 169146a607e..1f13554db40 100644
--- a/hotspot/src/share/vm/opto/ifnode.cpp
+++ b/hotspot/src/share/vm/opto/ifnode.cpp
@@ -249,6 +249,13 @@ static Node* split_if(IfNode *iff, PhaseIterGVN *igvn) {
       predicate_proj = proj;
     }
   }
+
+  // If all the defs of the phi are the same constant, we already have the desired end state.
+  // Skip the split that would create empty phi and region nodes.
+  if((r->req() - req_c) == 1) {
+    return NULL;
+  }
+
   if (nb_predicate_proj > 1) {
     // Can happen in case of loop unswitching and when the loop is
     // optimized out: it's not a loop anymore so we don't care about
@@ -1458,8 +1465,9 @@ Node* IfNode::dominated_by(Node* prev_dom, PhaseIterGVN *igvn) {
   // be skipped. For example, range check predicate has two checks
   // for lower and upper bounds.
   ProjNode* unc_proj = proj_out(1 - prev_dom->as_Proj()->_con)->as_Proj();
-  if (unc_proj->is_uncommon_trap_proj(Deoptimization::Reason_predicate) != NULL)
-   prev_dom = idom;
+  if ((unc_proj != NULL) && (unc_proj->is_uncommon_trap_proj(Deoptimization::Reason_predicate) != NULL)) {
+    prev_dom = idom;
+  }
 
   // Now walk the current IfNode's projections.
   // Loop ends when 'this' has no more uses.
diff --git a/hotspot/src/share/vm/opto/lcm.cpp b/hotspot/src/share/vm/opto/lcm.cpp
index 87d6d92d5f6..0cad4dce650 100644
--- a/hotspot/src/share/vm/opto/lcm.cpp
+++ b/hotspot/src/share/vm/opto/lcm.cpp
@@ -254,10 +254,12 @@ void PhaseCFG::implicit_null_check(Block* block, Node *proj, Node *val, int allo
       const TypePtr *adr_type = NULL;  // Do not need this return value here
       const Node* base = mach->get_base_and_disp(offset, adr_type);
       if (base == NULL || base == NodeSentinel) {
-        // Narrow oop address doesn't have base, only index
-        if( val->bottom_type()->isa_narrowoop() &&
-            MacroAssembler::needs_explicit_null_check(offset) )
-          continue;             // Give up if offset is beyond page size
+        // Narrow oop address doesn't have base, only index.
+        // Give up if offset is beyond page size or if heap base is not protected.
+        if (val->bottom_type()->isa_narrowoop() &&
+            (MacroAssembler::needs_explicit_null_check(offset) ||
+             !Universe::narrow_oop_use_implicit_null_checks()))
+          continue;
         // cannot reason about it; is probably not implicit null exception
       } else {
         const TypePtr* tptr;
@@ -269,12 +271,17 @@ void PhaseCFG::implicit_null_check(Block* block, Node *proj, Node *val, int allo
           // only regular oops are expected here
           tptr = base->bottom_type()->is_ptr();
         }
-        // Give up if offset is not a compile-time constant
-        if( offset == Type::OffsetBot || tptr->_offset == Type::OffsetBot )
+        // Give up if offset is not a compile-time constant.
+        if (offset == Type::OffsetBot || tptr->_offset == Type::OffsetBot)
           continue;
         offset += tptr->_offset; // correct if base is offseted
-        if( MacroAssembler::needs_explicit_null_check(offset) )
-          continue;             // Give up is reference is beyond 4K page size
+        // Give up if reference is beyond page size.
+        if (MacroAssembler::needs_explicit_null_check(offset))
+          continue;
+        // Give up if base is a decode node and the heap base is not protected.
+        if (base->is_Mach() && base->as_Mach()->ideal_Opcode() == Op_DecodeN &&
+            !Universe::narrow_oop_use_implicit_null_checks())
+          continue;
       }
     }
 
diff --git a/hotspot/src/share/vm/opto/library_call.cpp b/hotspot/src/share/vm/opto/library_call.cpp
index 5d837d6ecb0..4e5051ee01c 100644
--- a/hotspot/src/share/vm/opto/library_call.cpp
+++ b/hotspot/src/share/vm/opto/library_call.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -277,7 +277,8 @@ class LibraryCallKit : public GraphKit {
   AllocateArrayNode* tightly_coupled_allocation(Node* ptr,
                                                 RegionNode* slow_region);
   JVMState* arraycopy_restore_alloc_state(AllocateArrayNode* alloc, int& saved_reexecute_sp);
-  void arraycopy_move_allocation_here(AllocateArrayNode* alloc, Node* dest, JVMState* saved_jvms, int saved_reexecute_sp);
+  void arraycopy_move_allocation_here(AllocateArrayNode* alloc, Node* dest, JVMState* saved_jvms, int saved_reexecute_sp,
+                                      uint new_idx);
 
   typedef enum { LS_get_add, LS_get_set, LS_cmp_swap, LS_cmp_swap_weak, LS_cmp_exchange } LoadStoreKind;
   MemNode::MemOrd access_kind_to_memord_LS(AccessKind access_kind, bool is_store);
@@ -648,46 +649,46 @@ bool LibraryCallKit::try_to_inline(int predicate) {
   case vmIntrinsics::_putFloatOpaque:           return inline_unsafe_access( is_store, T_FLOAT,    Opaque, false);
   case vmIntrinsics::_putDoubleOpaque:          return inline_unsafe_access( is_store, T_DOUBLE,   Opaque, false);
 
-  case vmIntrinsics::_compareAndSwapObject:             return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap,      Volatile);
-  case vmIntrinsics::_compareAndSwapByte:               return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap,      Volatile);
-  case vmIntrinsics::_compareAndSwapShort:              return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap,      Volatile);
-  case vmIntrinsics::_compareAndSwapInt:                return inline_unsafe_load_store(T_INT,    LS_cmp_swap,      Volatile);
-  case vmIntrinsics::_compareAndSwapLong:               return inline_unsafe_load_store(T_LONG,   LS_cmp_swap,      Volatile);
+  case vmIntrinsics::_compareAndSetObject:              return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap,      Volatile);
+  case vmIntrinsics::_compareAndSetByte:                return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap,      Volatile);
+  case vmIntrinsics::_compareAndSetShort:               return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap,      Volatile);
+  case vmIntrinsics::_compareAndSetInt:                 return inline_unsafe_load_store(T_INT,    LS_cmp_swap,      Volatile);
+  case vmIntrinsics::_compareAndSetLong:                return inline_unsafe_load_store(T_LONG,   LS_cmp_swap,      Volatile);
 
-  case vmIntrinsics::_weakCompareAndSwapObject:         return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap_weak, Relaxed);
-  case vmIntrinsics::_weakCompareAndSwapObjectAcquire:  return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap_weak, Acquire);
-  case vmIntrinsics::_weakCompareAndSwapObjectRelease:  return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap_weak, Release);
-  case vmIntrinsics::_weakCompareAndSwapObjectVolatile: return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap_weak, Volatile);
-  case vmIntrinsics::_weakCompareAndSwapByte:           return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap_weak, Relaxed);
-  case vmIntrinsics::_weakCompareAndSwapByteAcquire:    return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap_weak, Acquire);
-  case vmIntrinsics::_weakCompareAndSwapByteRelease:    return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap_weak, Release);
-  case vmIntrinsics::_weakCompareAndSwapByteVolatile:   return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap_weak, Volatile);
-  case vmIntrinsics::_weakCompareAndSwapShort:          return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap_weak, Relaxed);
-  case vmIntrinsics::_weakCompareAndSwapShortAcquire:   return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap_weak, Acquire);
-  case vmIntrinsics::_weakCompareAndSwapShortRelease:   return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap_weak, Release);
-  case vmIntrinsics::_weakCompareAndSwapShortVolatile:  return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap_weak, Volatile);
-  case vmIntrinsics::_weakCompareAndSwapInt:            return inline_unsafe_load_store(T_INT,    LS_cmp_swap_weak, Relaxed);
-  case vmIntrinsics::_weakCompareAndSwapIntAcquire:     return inline_unsafe_load_store(T_INT,    LS_cmp_swap_weak, Acquire);
-  case vmIntrinsics::_weakCompareAndSwapIntRelease:     return inline_unsafe_load_store(T_INT,    LS_cmp_swap_weak, Release);
-  case vmIntrinsics::_weakCompareAndSwapIntVolatile:    return inline_unsafe_load_store(T_INT,    LS_cmp_swap_weak, Volatile);
-  case vmIntrinsics::_weakCompareAndSwapLong:           return inline_unsafe_load_store(T_LONG,   LS_cmp_swap_weak, Relaxed);
-  case vmIntrinsics::_weakCompareAndSwapLongAcquire:    return inline_unsafe_load_store(T_LONG,   LS_cmp_swap_weak, Acquire);
-  case vmIntrinsics::_weakCompareAndSwapLongRelease:    return inline_unsafe_load_store(T_LONG,   LS_cmp_swap_weak, Release);
-  case vmIntrinsics::_weakCompareAndSwapLongVolatile:   return inline_unsafe_load_store(T_LONG,   LS_cmp_swap_weak, Volatile);
+  case vmIntrinsics::_weakCompareAndSetObjectPlain:     return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap_weak, Relaxed);
+  case vmIntrinsics::_weakCompareAndSetObjectAcquire:   return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap_weak, Acquire);
+  case vmIntrinsics::_weakCompareAndSetObjectRelease:   return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap_weak, Release);
+  case vmIntrinsics::_weakCompareAndSetObject:          return inline_unsafe_load_store(T_OBJECT, LS_cmp_swap_weak, Volatile);
+  case vmIntrinsics::_weakCompareAndSetBytePlain:       return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap_weak, Relaxed);
+  case vmIntrinsics::_weakCompareAndSetByteAcquire:     return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap_weak, Acquire);
+  case vmIntrinsics::_weakCompareAndSetByteRelease:     return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap_weak, Release);
+  case vmIntrinsics::_weakCompareAndSetByte:            return inline_unsafe_load_store(T_BYTE,   LS_cmp_swap_weak, Volatile);
+  case vmIntrinsics::_weakCompareAndSetShortPlain:      return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap_weak, Relaxed);
+  case vmIntrinsics::_weakCompareAndSetShortAcquire:    return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap_weak, Acquire);
+  case vmIntrinsics::_weakCompareAndSetShortRelease:    return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap_weak, Release);
+  case vmIntrinsics::_weakCompareAndSetShort:           return inline_unsafe_load_store(T_SHORT,  LS_cmp_swap_weak, Volatile);
+  case vmIntrinsics::_weakCompareAndSetIntPlain:        return inline_unsafe_load_store(T_INT,    LS_cmp_swap_weak, Relaxed);
+  case vmIntrinsics::_weakCompareAndSetIntAcquire:      return inline_unsafe_load_store(T_INT,    LS_cmp_swap_weak, Acquire);
+  case vmIntrinsics::_weakCompareAndSetIntRelease:      return inline_unsafe_load_store(T_INT,    LS_cmp_swap_weak, Release);
+  case vmIntrinsics::_weakCompareAndSetInt:             return inline_unsafe_load_store(T_INT,    LS_cmp_swap_weak, Volatile);
+  case vmIntrinsics::_weakCompareAndSetLongPlain:       return inline_unsafe_load_store(T_LONG,   LS_cmp_swap_weak, Relaxed);
+  case vmIntrinsics::_weakCompareAndSetLongAcquire:     return inline_unsafe_load_store(T_LONG,   LS_cmp_swap_weak, Acquire);
+  case vmIntrinsics::_weakCompareAndSetLongRelease:     return inline_unsafe_load_store(T_LONG,   LS_cmp_swap_weak, Release);
+  case vmIntrinsics::_weakCompareAndSetLong:            return inline_unsafe_load_store(T_LONG,   LS_cmp_swap_weak, Volatile);
 
-  case vmIntrinsics::_compareAndExchangeObjectVolatile: return inline_unsafe_load_store(T_OBJECT, LS_cmp_exchange,  Volatile);
+  case vmIntrinsics::_compareAndExchangeObject:         return inline_unsafe_load_store(T_OBJECT, LS_cmp_exchange,  Volatile);
   case vmIntrinsics::_compareAndExchangeObjectAcquire:  return inline_unsafe_load_store(T_OBJECT, LS_cmp_exchange,  Acquire);
   case vmIntrinsics::_compareAndExchangeObjectRelease:  return inline_unsafe_load_store(T_OBJECT, LS_cmp_exchange,  Release);
-  case vmIntrinsics::_compareAndExchangeByteVolatile:   return inline_unsafe_load_store(T_BYTE,   LS_cmp_exchange,  Volatile);
+  case vmIntrinsics::_compareAndExchangeByte:           return inline_unsafe_load_store(T_BYTE,   LS_cmp_exchange,  Volatile);
   case vmIntrinsics::_compareAndExchangeByteAcquire:    return inline_unsafe_load_store(T_BYTE,   LS_cmp_exchange,  Acquire);
   case vmIntrinsics::_compareAndExchangeByteRelease:    return inline_unsafe_load_store(T_BYTE,   LS_cmp_exchange,  Release);
-  case vmIntrinsics::_compareAndExchangeShortVolatile:  return inline_unsafe_load_store(T_SHORT,  LS_cmp_exchange,  Volatile);
+  case vmIntrinsics::_compareAndExchangeShort:          return inline_unsafe_load_store(T_SHORT,  LS_cmp_exchange,  Volatile);
   case vmIntrinsics::_compareAndExchangeShortAcquire:   return inline_unsafe_load_store(T_SHORT,  LS_cmp_exchange,  Acquire);
   case vmIntrinsics::_compareAndExchangeShortRelease:   return inline_unsafe_load_store(T_SHORT,  LS_cmp_exchange,  Release);
-  case vmIntrinsics::_compareAndExchangeIntVolatile:    return inline_unsafe_load_store(T_INT,    LS_cmp_exchange,  Volatile);
+  case vmIntrinsics::_compareAndExchangeInt:            return inline_unsafe_load_store(T_INT,    LS_cmp_exchange,  Volatile);
   case vmIntrinsics::_compareAndExchangeIntAcquire:     return inline_unsafe_load_store(T_INT,    LS_cmp_exchange,  Acquire);
   case vmIntrinsics::_compareAndExchangeIntRelease:     return inline_unsafe_load_store(T_INT,    LS_cmp_exchange,  Release);
-  case vmIntrinsics::_compareAndExchangeLongVolatile:   return inline_unsafe_load_store(T_LONG,   LS_cmp_exchange,  Volatile);
+  case vmIntrinsics::_compareAndExchangeLong:           return inline_unsafe_load_store(T_LONG,   LS_cmp_exchange,  Volatile);
   case vmIntrinsics::_compareAndExchangeLongAcquire:    return inline_unsafe_load_store(T_LONG,   LS_cmp_exchange,  Acquire);
   case vmIntrinsics::_compareAndExchangeLongRelease:    return inline_unsafe_load_store(T_LONG,   LS_cmp_exchange,  Release);
 
@@ -1667,6 +1668,9 @@ bool LibraryCallKit::inline_string_char_access(bool is_store) {
   }
 
   Node* adr = array_element_address(value, index, T_CHAR);
+  if (adr->is_top()) {
+    return false;
+  }
   if (is_store) {
     (void) store_to_memory(control(), adr, ch, T_CHAR, TypeAryPtr::BYTES, MemNode::unordered,
                            false, false, true /* mismatched */);
@@ -2371,10 +2375,10 @@ bool LibraryCallKit::inline_unsafe_access(bool is_store, const BasicType type, c
   // the barriers get omitted and the unsafe reference begins to "pollute"
   // the alias analysis of the rest of the graph, either Compile::can_alias
   // or Compile::must_alias will throw a diagnostic assert.)
-  bool need_mem_bar;
+  bool need_mem_bar = false;
   switch (kind) {
       case Relaxed:
-          need_mem_bar = mismatched || can_access_non_heap;
+          need_mem_bar = mismatched && !adr_type->isa_aryptr();
           break;
       case Opaque:
           // Opaque uses CPUOrder membars for protection against code movement.
@@ -2583,23 +2587,26 @@ bool LibraryCallKit::inline_unsafe_access(bool is_store, const BasicType type, c
 //
 // LS_cmp_swap:
 //
-//   boolean compareAndSwapObject(Object o, long offset, Object expected, Object x);
-//   boolean compareAndSwapInt(   Object o, long offset, int    expected, int    x);
-//   boolean compareAndSwapLong(  Object o, long offset, long   expected, long   x);
+//   boolean compareAndSetObject(Object o, long offset, Object expected, Object x);
+//   boolean compareAndSetInt(   Object o, long offset, int    expected, int    x);
+//   boolean compareAndSetLong(  Object o, long offset, long   expected, long   x);
 //
 // LS_cmp_swap_weak:
 //
-//   boolean weakCompareAndSwapObject(       Object o, long offset, Object expected, Object x);
-//   boolean weakCompareAndSwapObjectAcquire(Object o, long offset, Object expected, Object x);
-//   boolean weakCompareAndSwapObjectRelease(Object o, long offset, Object expected, Object x);
+//   boolean weakCompareAndSetObject(       Object o, long offset, Object expected, Object x);
+//   boolean weakCompareAndSetObjectPlain(  Object o, long offset, Object expected, Object x);
+//   boolean weakCompareAndSetObjectAcquire(Object o, long offset, Object expected, Object x);
+//   boolean weakCompareAndSetObjectRelease(Object o, long offset, Object expected, Object x);
 //
-//   boolean weakCompareAndSwapInt(          Object o, long offset, int    expected, int    x);
-//   boolean weakCompareAndSwapIntAcquire(   Object o, long offset, int    expected, int    x);
-//   boolean weakCompareAndSwapIntRelease(   Object o, long offset, int    expected, int    x);
+//   boolean weakCompareAndSetInt(          Object o, long offset, int    expected, int    x);
+//   boolean weakCompareAndSetIntPlain(     Object o, long offset, int    expected, int    x);
+//   boolean weakCompareAndSetIntAcquire(   Object o, long offset, int    expected, int    x);
+//   boolean weakCompareAndSetIntRelease(   Object o, long offset, int    expected, int    x);
 //
-//   boolean weakCompareAndSwapLong(         Object o, long offset, long   expected, long   x);
-//   boolean weakCompareAndSwapLongAcquire(  Object o, long offset, long   expected, long   x);
-//   boolean weakCompareAndSwapLongRelease(  Object o, long offset, long   expected, long   x);
+//   boolean weakCompareAndSetLong(         Object o, long offset, long   expected, long   x);
+//   boolean weakCompareAndSetLongPlain(    Object o, long offset, long   expected, long   x);
+//   boolean weakCompareAndSetLongAcquire(  Object o, long offset, long   expected, long   x);
+//   boolean weakCompareAndSetLongRelease(  Object o, long offset, long   expected, long   x);
 //
 // LS_cmp_exchange:
 //
@@ -3017,7 +3024,7 @@ bool LibraryCallKit::inline_unsafe_load_store(const BasicType type, const LoadSt
       load_store = _gvn.transform(new DecodeNNode(load_store, load_store->get_ptr_type()));
     }
 #endif
-    if (can_move_pre_barrier()) {
+    if (can_move_pre_barrier() && kind == LS_get_set) {
       // Don't need to load pre_val. The old value is returned by load_store.
       // The pre_barrier can execute after the xchg as long as no safepoint
       // gets inserted between them.
@@ -4882,7 +4889,8 @@ JVMState* LibraryCallKit::arraycopy_restore_alloc_state(AllocateArrayNode* alloc
 // deoptimize. This is possible because tightly_coupled_allocation()
 // guarantees there's no observer of the allocated array at this point
 // and the control flow is simple enough.
-void LibraryCallKit::arraycopy_move_allocation_here(AllocateArrayNode* alloc, Node* dest, JVMState* saved_jvms, int saved_reexecute_sp) {
+void LibraryCallKit::arraycopy_move_allocation_here(AllocateArrayNode* alloc, Node* dest, JVMState* saved_jvms,
+                                                    int saved_reexecute_sp, uint new_idx) {
   if (saved_jvms != NULL && !stopped()) {
     assert(alloc != NULL, "only with a tightly coupled allocation");
     // restore JVM state to the state at the arraycopy
@@ -4891,7 +4899,7 @@ void LibraryCallKit::arraycopy_move_allocation_here(AllocateArrayNode* alloc, No
     assert(saved_jvms->map()->i_o() == map()->i_o(), "IO state changed?");
     // If we've improved the types of some nodes (null check) while
     // emitting the guards, propagate them to the current state
-    map()->replaced_nodes().apply(saved_jvms->map());
+    map()->replaced_nodes().apply(saved_jvms->map(), new_idx);
     set_jvms(saved_jvms);
     _reexecute_sp = saved_reexecute_sp;
 
@@ -4949,6 +4957,7 @@ bool LibraryCallKit::inline_arraycopy() {
   Node* dest_offset = argument(3);  // type: int
   Node* length      = argument(4);  // type: int
 
+  uint new_idx = C->unique();
 
   // Check for allocation before we add nodes that would confuse
   // tightly_coupled_allocation()
@@ -4959,7 +4968,7 @@ bool LibraryCallKit::inline_arraycopy() {
   // See arraycopy_restore_alloc_state() comment
   // if alloc == NULL we don't have to worry about a tightly coupled allocation so we can emit all needed guards
   // if saved_jvms != NULL (then alloc != NULL) then we can handle guards and a tightly coupled allocation
-  // if saved_jvms == NULL and alloc != NULL, we can’t emit any guards
+  // if saved_jvms == NULL and alloc != NULL, we can't emit any guards
   bool can_emit_guards = (alloc == NULL || saved_jvms != NULL);
 
   // The following tests must be performed
@@ -5164,7 +5173,7 @@ bool LibraryCallKit::inline_arraycopy() {
     }
   }
 
-  arraycopy_move_allocation_here(alloc, dest, saved_jvms, saved_reexecute_sp);
+  arraycopy_move_allocation_here(alloc, dest, saved_jvms, saved_reexecute_sp, new_idx);
 
   if (stopped()) {
     return true;
diff --git a/hotspot/src/share/vm/opto/loopTransform.cpp b/hotspot/src/share/vm/opto/loopTransform.cpp
index d35d71aebd4..7590ba66b5a 100644
--- a/hotspot/src/share/vm/opto/loopTransform.cpp
+++ b/hotspot/src/share/vm/opto/loopTransform.cpp
@@ -3174,6 +3174,11 @@ bool PhaseIdealLoop::intrinsify_fill(IdealLoopTree* lpt) {
     return false;
   }
 
+  Node* exit = head->loopexit()->proj_out(0);
+  if (exit == NULL) {
+    return false;
+  }
+
 #ifndef PRODUCT
   if (TraceLoopOpts) {
     tty->print("ArrayFill    ");
@@ -3281,7 +3286,6 @@ bool PhaseIdealLoop::intrinsify_fill(IdealLoopTree* lpt) {
 */
 
   // Redirect the old control and memory edges that are outside the loop.
-  Node* exit = head->loopexit()->proj_out(0);
   // Sometimes the memory phi of the head is used as the outgoing
   // state of the loop.  It's safe in this case to replace it with the
   // result_mem.
diff --git a/hotspot/src/share/vm/opto/loopnode.cpp b/hotspot/src/share/vm/opto/loopnode.cpp
index 7909014b53e..f605e204668 100644
--- a/hotspot/src/share/vm/opto/loopnode.cpp
+++ b/hotspot/src/share/vm/opto/loopnode.cpp
@@ -1860,6 +1860,9 @@ void IdealLoopTree::dump_head( ) const {
   if (_required_safept != NULL && _required_safept->size() > 0) {
     tty->print(" req={"); _required_safept->dump_simple(); tty->print(" }");
   }
+  if (Verbose) {
+    tty->print(" body={"); _body.dump_simple(); tty->print(" }");
+  }
   tty->cr();
 }
 
diff --git a/hotspot/src/share/vm/opto/loopopts.cpp b/hotspot/src/share/vm/opto/loopopts.cpp
index bd00791aee0..6de29ab35af 100644
--- a/hotspot/src/share/vm/opto/loopopts.cpp
+++ b/hotspot/src/share/vm/opto/loopopts.cpp
@@ -913,7 +913,11 @@ Node *PhaseIdealLoop::split_if_with_blocks_pre( Node *n ) {
 
   if (n->is_ConstraintCast()) {
     Node* dom_cast = n->as_ConstraintCast()->dominating_cast(this);
-    if (dom_cast != NULL) {
+    // ConstraintCastNode::dominating_cast() uses node control input to determine domination.
+    // Node control inputs don't necessarily agree with loop control info (due to
+    // transformations happened in between), thus additional dominance check is needed
+    // to keep loop info valid.
+    if (dom_cast != NULL && is_dominator(get_ctrl(dom_cast), get_ctrl(n))) {
       _igvn.replace_node(n, dom_cast);
       return dom_cast;
     }
diff --git a/hotspot/src/share/vm/opto/macro.cpp b/hotspot/src/share/vm/opto/macro.cpp
index bd0a1b75c9a..ed3ef88aa65 100644
--- a/hotspot/src/share/vm/opto/macro.cpp
+++ b/hotspot/src/share/vm/opto/macro.cpp
@@ -1047,7 +1047,9 @@ void PhaseMacroExpand::process_users_of_allocation(CallNode *alloc) {
         // opportunities for allocation elimination
         Node* src = ac->in(ArrayCopyNode::Src);
         ac->replace_edge(src, top());
-        if (src->outcnt() == 0) {
+        // src can be top at this point if src and dest of the
+        // arraycopy were the same
+        if (src->outcnt() == 0 && !src->is_top()) {
           _igvn.remove_dead_node(src);
         }
 
diff --git a/hotspot/src/share/vm/opto/macroArrayCopy.cpp b/hotspot/src/share/vm/opto/macroArrayCopy.cpp
index fb55efedb95..cd6983f97a7 100644
--- a/hotspot/src/share/vm/opto/macroArrayCopy.cpp
+++ b/hotspot/src/share/vm/opto/macroArrayCopy.cpp
@@ -718,6 +718,15 @@ Node* PhaseMacroExpand::generate_arraycopy(ArrayCopyNode *ac, AllocateArrayNode*
   _igvn.replace_node(_ioproj_fallthrough, *io);
   _igvn.replace_node(_fallthroughcatchproj, *ctrl);
 
+#ifdef ASSERT
+  const TypeOopPtr* dest_t = _igvn.type(dest)->is_oopptr();
+  if (dest_t->is_known_instance()) {
+    ArrayCopyNode* ac = NULL;
+    assert(ArrayCopyNode::may_modify(dest_t, (*ctrl)->in(0)->as_MemBar(), &_igvn, ac), "dependency on arraycopy lost");
+    assert(ac == NULL, "no arraycopy anymore");
+  }
+#endif
+
   return out_mem;
 }
 
@@ -1139,8 +1148,25 @@ void PhaseMacroExpand::expand_arraycopy_node(ArrayCopyNode *ac) {
   const TypeAryPtr* top_src = src_type->isa_aryptr();
   const TypeAryPtr* top_dest = dest_type->isa_aryptr();
 
-  if (top_src  == NULL || top_src->klass()  == NULL ||
-      top_dest == NULL || top_dest->klass() == NULL) {
+  BasicType src_elem = T_CONFLICT;
+  BasicType dest_elem = T_CONFLICT;
+
+  if (top_dest != NULL && top_dest->klass() != NULL) {
+    dest_elem = top_dest->klass()->as_array_klass()->element_type()->basic_type();
+  }
+  if (top_src != NULL && top_src->klass() != NULL) {
+    src_elem = top_src->klass()->as_array_klass()->element_type()->basic_type();
+  }
+  if (src_elem  == T_ARRAY)  src_elem  = T_OBJECT;
+  if (dest_elem == T_ARRAY)  dest_elem = T_OBJECT;
+
+  if (ac->is_arraycopy_validated() &&
+      dest_elem != T_CONFLICT &&
+      src_elem == T_CONFLICT) {
+    src_elem = dest_elem;
+  }
+
+  if (src_elem == T_CONFLICT || dest_elem == T_CONFLICT) {
     // Conservatively insert a memory barrier on all memory slices.
     // Do not let writes into the source float below the arraycopy.
     {
@@ -1169,13 +1195,11 @@ void PhaseMacroExpand::expand_arraycopy_node(ArrayCopyNode *ac) {
     }
     return;
   }
+
+  assert(!ac->is_arraycopy_validated() || (src_elem == dest_elem && dest_elem != T_VOID), "validated but different basic types");
+
   // (2) src and dest arrays must have elements of the same BasicType
   // Figure out the size and type of the elements we will be copying.
-  BasicType src_elem  = top_src->klass()->as_array_klass()->element_type()->basic_type();
-  BasicType dest_elem = top_dest->klass()->as_array_klass()->element_type()->basic_type();
-  if (src_elem  == T_ARRAY)  src_elem  = T_OBJECT;
-  if (dest_elem == T_ARRAY)  dest_elem = T_OBJECT;
-
   if (src_elem != dest_elem || dest_elem == T_VOID) {
     // The component types are not the same or are not recognized.  Punt.
     // (But, avoid the native method wrapper to JVM_ArrayCopy.)
diff --git a/hotspot/src/share/vm/opto/matcher.cpp b/hotspot/src/share/vm/opto/matcher.cpp
index 698b0bae068..f58bc97cfc9 100644
--- a/hotspot/src/share/vm/opto/matcher.cpp
+++ b/hotspot/src/share/vm/opto/matcher.cpp
@@ -1000,7 +1000,7 @@ Node *Matcher::xform( Node *n, int max_stack ) {
             if (C->failing())  return NULL;
             if (m == NULL) { Matcher::soft_match_failure(); return NULL; }
           } else {                  // Nothing the matcher cares about
-            if( n->is_Proj() && n->in(0)->is_Multi()) {       // Projections?
+            if (n->is_Proj() && n->in(0) != NULL && n->in(0)->is_Multi()) {       // Projections?
               // Convert to machine-dependent projection
               m = n->in(0)->as_Multi()->match( n->as_Proj(), this );
 #ifdef ASSERT
@@ -1645,6 +1645,7 @@ MachNode *Matcher::ReduceInst( State *s, int rule, Node *&mem ) {
 
   // Build the object to represent this state & prepare for recursive calls
   MachNode *mach = s->MachNodeGenerator(rule);
+  guarantee(mach != NULL, "Missing MachNode");
   mach->_opnds[0] = s->MachOperGenerator(_reduceOp[rule]);
   assert( mach->_opnds[0] != NULL, "Missing result operand" );
   Node *leaf = s->_leaf;
diff --git a/hotspot/src/share/vm/opto/memnode.cpp b/hotspot/src/share/vm/opto/memnode.cpp
index 445192c1da4..3fd63287071 100644
--- a/hotspot/src/share/vm/opto/memnode.cpp
+++ b/hotspot/src/share/vm/opto/memnode.cpp
@@ -61,6 +61,15 @@ const TypePtr *MemNode::adr_type() const {
   return calculate_adr_type(adr->bottom_type(), cross_check);
 }
 
+bool MemNode::check_if_adr_maybe_raw(Node* adr) {
+  if (adr != NULL) {
+    if (adr->bottom_type()->base() == Type::RawPtr || adr->bottom_type()->base() == Type::AnyPtr) {
+      return true;
+    }
+  }
+  return false;
+}
+
 #ifndef PRODUCT
 void MemNode::dump_spec(outputStream *st) const {
   if (in(Address) == NULL)  return; // node is dead
@@ -560,6 +569,7 @@ Node* MemNode::find_previous_store(PhaseTransform* phase) {
   if (offset == Type::OffsetBot)
     return NULL;            // cannot unalias unless there are precise offsets
 
+  const bool adr_maybe_raw = check_if_adr_maybe_raw(adr);
   const TypeOopPtr *addr_t = adr->bottom_type()->isa_oopptr();
 
   intptr_t size_in_bytes = memory_size();
@@ -577,6 +587,13 @@ Node* MemNode::find_previous_store(PhaseTransform* phase) {
       Node* st_base = AddPNode::Ideal_base_and_offset(st_adr, phase, st_offset);
       if (st_base == NULL)
         break;              // inscrutable pointer
+
+      // For raw accesses it's not enough to prove that constant offsets don't intersect.
+      // We need the bases to be the equal in order for the offset check to make sense.
+      if ((adr_maybe_raw || check_if_adr_maybe_raw(st_adr)) && st_base != base) {
+        break;
+      }
+
       if (st_offset != offset && st_offset != Type::OffsetBot) {
         const int MAX_STORE = BytesPerLong;
         if (st_offset >= offset + size_in_bytes ||
@@ -891,10 +908,11 @@ Node* LoadNode::can_see_arraycopy_value(Node* st, PhaseTransform* phase) const {
         ld->set_req(0, ld_alloc->in(0));
       }
     } else {
+      Node* src = ac->in(ArrayCopyNode::Src);
       Node* addp = in(MemNode::Address)->clone();
       assert(addp->in(AddPNode::Base) == addp->in(AddPNode::Address), "should be");
-      addp->set_req(AddPNode::Base, ac->in(ArrayCopyNode::Src));
-      addp->set_req(AddPNode::Address, ac->in(ArrayCopyNode::Src));
+      addp->set_req(AddPNode::Base, src);
+      addp->set_req(AddPNode::Address, src);
 
       const TypeAryPtr* ary_t = phase->type(in(MemNode::Address))->isa_aryptr();
       BasicType ary_elem  = ary_t->klass()->as_array_klass()->element_type()->basic_type();
@@ -911,6 +929,12 @@ Node* LoadNode::can_see_arraycopy_value(Node* st, PhaseTransform* phase) const {
       addp->set_req(AddPNode::Offset, offset);
       ld->set_req(MemNode::Address, phase->transform(addp));
 
+      const TypeX *ld_offs_t = phase->type(offset)->isa_intptr_t();
+
+      if (!ac->as_ArrayCopy()->can_replace_dest_load_with_src_load(ld_offs_t->_lo, ld_offs_t->_hi, phase)) {
+        return NULL;
+      }
+
       if (in(0) != NULL) {
         assert(ac->in(0) != NULL, "alloc must have control");
         ld->set_req(0, ac->in(0));
@@ -1106,6 +1130,9 @@ Node* LoadNode::Identity(PhaseGVN* phase) {
       // Use _idx of address base (could be Phi node) for boxed values.
       intptr_t   ignore = 0;
       Node*      base = AddPNode::Ideal_base_and_offset(in(Address), phase, ignore);
+      if (base == NULL) {
+        return this;
+      }
       this_iid = base->_idx;
     }
     const Type* this_type = bottom_type();
@@ -3930,9 +3957,10 @@ Node* InitializeNode::complete_stores(Node* rawctl, Node* rawmem, Node* rawptr,
     // if it is the last unused 4 bytes of an instance, forget about it
     intptr_t size_limit = phase->find_intptr_t_con(size_in_bytes, max_jint);
     if (zeroes_done + BytesPerLong >= size_limit) {
-      assert(allocation() != NULL, "");
-      if (allocation()->Opcode() == Op_Allocate) {
-        Node* klass_node = allocation()->in(AllocateNode::KlassNode);
+      AllocateNode* alloc = allocation();
+      assert(alloc != NULL, "must be present");
+      if (alloc != NULL && alloc->Opcode() == Op_Allocate) {
+        Node* klass_node = alloc->in(AllocateNode::KlassNode);
         ciKlass* k = phase->type(klass_node)->is_klassptr()->klass();
         if (zeroes_done == k->layout_helper())
           zeroes_done = size_limit;
diff --git a/hotspot/src/share/vm/opto/memnode.hpp b/hotspot/src/share/vm/opto/memnode.hpp
index f0608bc752d..3409446861a 100644
--- a/hotspot/src/share/vm/opto/memnode.hpp
+++ b/hotspot/src/share/vm/opto/memnode.hpp
@@ -78,6 +78,7 @@ protected:
   }
 
   virtual Node* find_previous_arraycopy(PhaseTransform* phase, Node* ld_alloc, Node*& mem, bool can_see_stored_value) const { return NULL; }
+  static bool check_if_adr_maybe_raw(Node* adr);
 
 public:
   // Helpers for the optimizer.  Documented in memnode.cpp.
diff --git a/hotspot/src/share/vm/opto/parse1.cpp b/hotspot/src/share/vm/opto/parse1.cpp
index be1d82d7554..35d099bdeda 100644
--- a/hotspot/src/share/vm/opto/parse1.cpp
+++ b/hotspot/src/share/vm/opto/parse1.cpp
@@ -1086,7 +1086,7 @@ void Parse::do_exits() {
         kit.make_dtrace_method_exit(method());
       }
       if (_replaced_nodes_for_exceptions) {
-        kit.map()->apply_replaced_nodes();
+        kit.map()->apply_replaced_nodes(_new_idx);
       }
       // Done with exception-path processing.
       ex_map = kit.make_exception_state(ex_oop);
@@ -1107,7 +1107,7 @@ void Parse::do_exits() {
       _exits.add_exception_state(ex_map);
     }
   }
-  _exits.map()->apply_replaced_nodes();
+  _exits.map()->apply_replaced_nodes(_new_idx);
 }
 
 //-----------------------------create_entry_map-------------------------------
diff --git a/hotspot/src/share/vm/opto/parse2.cpp b/hotspot/src/share/vm/opto/parse2.cpp
index c8553ce798b..51538767fde 100644
--- a/hotspot/src/share/vm/opto/parse2.cpp
+++ b/hotspot/src/share/vm/opto/parse2.cpp
@@ -826,6 +826,9 @@ float Parse::dynamic_branch_prediction(float &cnt, BoolTest::mask btest, Node* t
     ciMethodData* methodData = method()->method_data();
     if (!methodData->is_mature())  return PROB_UNKNOWN;
     ciProfileData* data = methodData->bci_to_data(bci());
+    if (data == NULL) {
+      return PROB_UNKNOWN;
+    }
     if (!data->is_JumpData())  return PROB_UNKNOWN;
 
     // get taken and not taken values
@@ -917,8 +920,8 @@ float Parse::branch_prediction(float& cnt,
         // of the OSR-ed method, and we want to deopt to gather more stats.
         // If you have ANY counts, then this loop is simply 'cold' relative
         // to the OSR loop.
-        if (data->as_BranchData()->taken() +
-            data->as_BranchData()->not_taken() == 0 ) {
+        if (data == NULL ||
+            (data->as_BranchData()->taken() +  data->as_BranchData()->not_taken() == 0)) {
           // This is the only way to return PROB_UNKNOWN:
           return PROB_UNKNOWN;
         }
diff --git a/hotspot/src/share/vm/opto/parse3.cpp b/hotspot/src/share/vm/opto/parse3.cpp
index ca571af0dd2..ee0997e6913 100644
--- a/hotspot/src/share/vm/opto/parse3.cpp
+++ b/hotspot/src/share/vm/opto/parse3.cpp
@@ -146,8 +146,16 @@ void Parse::do_field_access(bool is_get, bool is_field) {
 
 
 void Parse::do_get_xxx(Node* obj, ciField* field, bool is_field) {
+  BasicType bt = field->layout_type();
+
   // Does this field have a constant value?  If so, just push the value.
-  if (field->is_constant()) {
+  if (field->is_constant() &&
+      // Keep consistent with types found by ciTypeFlow: for an
+      // unloaded field type, ciTypeFlow::StateVector::do_getstatic()
+      // speculates the field is null. The code in the rest of this
+      // method does the same. We must not bypass it and use a non
+      // null constant here.
+      (bt != T_OBJECT || field->type()->is_loaded())) {
     // final or stable field
     Node* con = make_constant_from_field(field, obj);
     if (con != NULL) {
@@ -163,7 +171,6 @@ void Parse::do_get_xxx(Node* obj, ciField* field, bool is_field) {
   int offset = field->offset_in_bytes();
   const TypePtr* adr_type = C->alias_type(field)->adr_type();
   Node *adr = basic_plus_adr(obj, obj, offset);
-  BasicType bt = field->layout_type();
 
   // Build the resultant type of the load
   const Type *type;
diff --git a/hotspot/src/share/vm/opto/replacednodes.cpp b/hotspot/src/share/vm/opto/replacednodes.cpp
index e3f3c113572..68928fc1601 100644
--- a/hotspot/src/share/vm/opto/replacednodes.cpp
+++ b/hotspot/src/share/vm/opto/replacednodes.cpp
@@ -92,13 +92,17 @@ void ReplacedNodes::reset() {
 }
 
 // Perfom node replacement (used when returning to caller)
-void ReplacedNodes::apply(Node* n) {
+void ReplacedNodes::apply(Node* n, uint idx) {
   if (is_empty()) {
     return;
   }
   for (int i = 0; i < _replaced_nodes->length(); i++) {
     ReplacedNode replaced = _replaced_nodes->at(i);
-    n->replace_edge(replaced.initial(), replaced.improved());
+    // Only apply if improved node was created in a callee to avoid
+    // issues with irreducible loops in the caller
+    if (replaced.improved()->_idx >= idx) {
+      n->replace_edge(replaced.initial(), replaced.improved());
+    }
   }
 }
 
diff --git a/hotspot/src/share/vm/opto/replacednodes.hpp b/hotspot/src/share/vm/opto/replacednodes.hpp
index 0f68fe986d5..3c31d0de903 100644
--- a/hotspot/src/share/vm/opto/replacednodes.hpp
+++ b/hotspot/src/share/vm/opto/replacednodes.hpp
@@ -71,7 +71,7 @@ class ReplacedNodes VALUE_OBJ_CLASS_SPEC {
   void record(Node* initial, Node* improved);
   void transfer_from(const ReplacedNodes& other, uint idx);
   void reset();
-  void apply(Node* n);
+  void apply(Node* n, uint idx);
   void merge_with(const ReplacedNodes& other);
   bool is_empty() const;
   void dump(outputStream *st) const;
diff --git a/hotspot/src/share/vm/opto/stringopts.cpp b/hotspot/src/share/vm/opto/stringopts.cpp
index 85151b0b99e..889353dabfe 100644
--- a/hotspot/src/share/vm/opto/stringopts.cpp
+++ b/hotspot/src/share/vm/opto/stringopts.cpp
@@ -891,8 +891,9 @@ bool StringConcat::validate_control_flow() {
       ctrl_path.push(cn);
       ctrl_path.push(cn->proj_out(0));
       ctrl_path.push(cn->proj_out(0)->unique_out());
-      if (cn->proj_out(0)->unique_out()->as_Catch()->proj_out(0) != NULL) {
-        ctrl_path.push(cn->proj_out(0)->unique_out()->as_Catch()->proj_out(0));
+      Node* catchproj = cn->proj_out(0)->unique_out()->as_Catch()->proj_out(0);
+      if (catchproj != NULL) {
+        ctrl_path.push(catchproj);
       }
     } else {
       ShouldNotReachHere();
diff --git a/hotspot/src/share/vm/opto/type.cpp b/hotspot/src/share/vm/opto/type.cpp
index a8c68006020..6411307c517 100644
--- a/hotspot/src/share/vm/opto/type.cpp
+++ b/hotspot/src/share/vm/opto/type.cpp
@@ -373,7 +373,7 @@ const Type* Type::make_constant_from_field(ciField* field, ciInstance* holder,
   if (con_type != NULL && field->is_call_site_target()) {
     ciCallSite* call_site = holder->as_call_site();
     if (!call_site->is_constant_call_site()) {
-      ciMethodHandle* target = call_site->get_target();
+      ciMethodHandle* target = con.as_object()->as_method_handle();
       Compile::current()->dependencies()->assert_call_site_target_value(call_site, target);
     }
   }
diff --git a/hotspot/src/share/vm/prims/jni.cpp b/hotspot/src/share/vm/prims/jni.cpp
index f519e5e2788..acda443267a 100644
--- a/hotspot/src/share/vm/prims/jni.cpp
+++ b/hotspot/src/share/vm/prims/jni.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * Copyright (c) 2012 Red Hat, Inc.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
@@ -935,8 +935,7 @@ class JNI_ArgumentPusherVaArg : public JNI_ArgumentPusher {
   inline void get_long()   { _arguments->push_long(va_arg(_ap, jlong)); }
   inline void get_float()  { _arguments->push_float((jfloat)va_arg(_ap, jdouble)); } // float is coerced to double w/ va_arg
   inline void get_double() { _arguments->push_double(va_arg(_ap, jdouble)); }
-  inline void get_object() { jobject l = va_arg(_ap, jobject);
-                             _arguments->push_oop(Handle((oop *)l, false)); }
+  inline void get_object() { _arguments->push_jobject(va_arg(_ap, jobject)); }
 
   inline void set_ap(va_list rap) {
     va_copy(_ap, rap);
@@ -1025,7 +1024,7 @@ class JNI_ArgumentPusherArray : public JNI_ArgumentPusher {
   inline void get_long()   { _arguments->push_long((_ap++)->j);  }
   inline void get_float()  { _arguments->push_float((_ap++)->f); }
   inline void get_double() { _arguments->push_double((_ap++)->d);}
-  inline void get_object() { _arguments->push_oop(Handle((oop *)(_ap++)->l, false)); }
+  inline void get_object() { _arguments->push_jobject((_ap++)->l); }
 
   inline void set_ap(const jvalue *rap) { _ap = rap; }
 
diff --git a/hotspot/src/share/vm/prims/jvm.cpp b/hotspot/src/share/vm/prims/jvm.cpp
index 2955463852e..59704b2ced7 100644
--- a/hotspot/src/share/vm/prims/jvm.cpp
+++ b/hotspot/src/share/vm/prims/jvm.cpp
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -684,7 +684,7 @@ JVM_ENTRY(jobject, JVM_Clone(JNIEnv* env, jobject handle))
       // This can safepoint and redefine method, so need both new_obj and method
       // in a handle, for two different reasons.  new_obj can move, method can be
       // deleted if nothing is using it on the stack.
-      m->method_holder()->add_member_name(new_obj());
+      m->method_holder()->add_member_name(new_obj(), false);
     }
   }
 
@@ -2967,14 +2967,7 @@ JVM_ENTRY(void, JVM_Yield(JNIEnv *env, jclass threadClass))
   JVMWrapper("JVM_Yield");
   if (os::dont_yield()) return;
   HOTSPOT_THREAD_YIELD();
-
-  // When ConvertYieldToSleep is off (default), this matches the classic VM use of yield.
-  // Critical for similar threading behaviour
-  if (ConvertYieldToSleep) {
-    os::sleep(thread, MinSleepInterval, false);
-  } else {
-    os::naked_yield();
-  }
+  os::naked_yield();
 JVM_END
 
 
@@ -2998,18 +2991,7 @@ JVM_ENTRY(void, JVM_Sleep(JNIEnv* env, jclass threadClass, jlong millis))
   EventThreadSleep event;
 
   if (millis == 0) {
-    // When ConvertSleepToYield is on, this matches the classic VM implementation of
-    // JVM_Sleep. Critical for similar threading behaviour (Win32)
-    // It appears that in certain GUI contexts, it may be beneficial to do a short sleep
-    // for SOLARIS
-    if (ConvertSleepToYield) {
-      os::naked_yield();
-    } else {
-      ThreadState old_state = thread->osthread()->get_state();
-      thread->osthread()->set_state(SLEEPING);
-      os::sleep(thread, MinSleepInterval, false);
-      thread->osthread()->set_state(old_state);
-    }
+    os::naked_yield();
   } else {
     ThreadState old_state = thread->osthread()->get_state();
     thread->osthread()->set_state(SLEEPING);
diff --git a/hotspot/src/share/vm/prims/jvmti.xml b/hotspot/src/share/vm/prims/jvmti.xml
index 7a0515c2bc4..571d8dd13b4 100644
--- a/hotspot/src/share/vm/prims/jvmti.xml
+++ b/hotspot/src/share/vm/prims/jvmti.xml
@@ -24,11 +24,11 @@
 -->
 
 
-   
 
    
@@ -41,13 +41,13 @@
    
    
 
-   
    
 
    
    
 
    
    
 
@@ -107,7 +107,7 @@
 
    
    
 
@@ -292,16 +292,16 @@
    
 
    
-   
+
    
-   
+
    
-   
+
    
 
    
    
-   
+
    
    
     JVM Tool Interface
   
-  
+
   
-    The JVM Tool Interface () 
-    is a programming interface used by development and monitoring tools. 
-    It provides both a way to inspect the state and 
+    The JVM Tool Interface ()
+    is a programming interface used by development and monitoring tools.
+    It provides both a way to inspect the state and
     to control the execution of applications running in the
     Java virtual machine (VM).
     

@@ -376,21 +376,21 @@ may not be available in all implementations of the Java virtual machine.

- is a two-way interface. + is a two-way interface. A client of , hereafter called an agent, can be notified of - interesting occurrences through events. + interesting occurrences through events. - can query and control the application through many - functions, - either in response to events or + can query and control the application through many + functions, + either in response to events or independent of them.

- Agents run in the same process with and communicate directly with + Agents run in the same process with and communicate directly with the virtual machine executing the application being examined. This communication is through a native interface (). The native in-process interface allows - maximal control with minimal intrusion on the part of a tool. + maximal control with minimal intrusion on the part of a tool. Typically, agents are relatively compact. They can be controlled by a separate process which implements the bulk of a tool's function without interfering with the target application's normal execution. @@ -400,12 +400,12 @@ Tools can be written directly to or indirectly through higher level interfaces. The Java Platform Debugger Architecture includes , but also - contains higher-level, out-of-process debugger interfaces. The higher-level - interfaces are more appropriate than for many tools. - For more information on the Java Platform Debugger Architecture, - see the - Java - Platform Debugger Architecture website. + contains higher-level, out-of-process debugger interfaces. The higher-level + interfaces are more appropriate than for many tools. + For more information on the Java Platform Debugger Architecture, + see the + Java + Platform Debugger Architecture website. @@ -424,16 +424,16 @@ - An agent is deployed in a platform specific manner but is typically the - platform equivalent of a dynamic library. On the Windows operating - system, for example, an agent library is a "Dynamic Linked Library" (DLL). + An agent is deployed in a platform specific manner but is typically the + platform equivalent of a dynamic library. On the Windows operating + system, for example, an agent library is a "Dynamic Linked Library" (DLL). On the Solaris Operating Environment, an agent library is a shared object (.so file).

An agent may be started at VM startup by specifying the agent library name using a command line option. - Some implementations may support a mechanism to + Some implementations may support a mechanism to start agents in the live phase. The details of how this is initiated are implementation specific. @@ -460,7 +460,7 @@ a function is exported, at the same point during VM execution as it would have called the dynamic entry point Agent_OnUnLoad. A statically loaded agent cannot be unloaded. The Agent_OnUnload_L function will still be - called to do any other agent shutdown related tasks. + called to do any other agent shutdown related tasks. If a statically linked agent L exports a function called Agent_OnUnLoad_L and a function called Agent_OnUnLoad, the Agent_OnUnLoad function will be ignored. @@ -472,19 +472,19 @@ Agent_OnAttach_L and a function called Agent_OnAttach, the Agent_OnAttach function will be ignored. - + The term "command-line option" is used below to mean options supplied in the JavaVMInitArgs argument to the JNI_CreateJavaVM function of the JNI Invocation API.

- One of the two following - command-line options is used on VM startup to + One of the two following + command-line options is used on VM startup to properly load and run agents. - These arguments identify the library containing + These arguments identify the library containing the agent as well as an options - string to be passed in at startup. + string to be passed in at startup.

-agentlib:<agent-lib-name>=<options>
@@ -494,10 +494,10 @@ Typically, the <agent-lib-name> is expanded to an operating system specific file name. The <options> will be passed to the agent on start-up. - For example, if the option - -agentlib:foo=opt1,opt2 is specified, the VM will attempt to + For example, if the option + -agentlib:foo=opt1,opt2 is specified, the VM will attempt to load the shared library foo.dll from the system PATH - under Windows or libfoo.so from the + under Windows or libfoo.so from the LD_LIBRARY_PATH under the Solaris operating environment. If the agent library is statically linked into the executable @@ -510,8 +510,8 @@ to load the library. No library name expansion will occur. The <options> will be passed to the agent on start-up. - For example, if the option - -agentpath:c:\myLibs\foo.dll=opt1,opt2 is specified, the VM will attempt to + For example, if the option + -agentpath:c:\myLibs\foo.dll=opt1,opt2 is specified, the VM will attempt to load the shared library c:\myLibs\foo.dll. If the agent library is statically linked into the executable then no actual loading takes place. @@ -523,13 +523,13 @@ in the library will be invoked. If the agent library is statically linked into the executable then the system will attempt to invoke the Agent_OnLoad_<agent-lib-name> entry point where - <agent-lib-name> is the basename of the + <agent-lib-name> is the basename of the agent. In the above example -agentpath:c:\myLibs\foo.dll=opt1,opt2, the system will attempt to find and call the Agent_OnLoad_foo start-up routine.

Libraries loaded with -agentlib: or -agentpath: will be searched for JNI native method implementations to facilitate the - use of Java programming language code in tools, as is needed for + use of Java programming language code in tools, as is needed for bytecode instrumentation.

The agent libraries will be searched after all other libraries have been @@ -537,11 +537,11 @@ implementations of non-agent methods can use the NativeMethodBind event).

- These switches do the above and nothing more - they do not change the - state of the VM or . No command line options are needed - to enable + These switches do the above and nothing more - they do not change the + state of the VM or . No command line options are needed + to enable or aspects of , this is handled programmatically - by the use of + by the use of capabilities. @@ -557,29 +557,29 @@ Agent_OnAttach or Agent_OnAttach_L for statically linked agents will be invoked. - Exactly one call to a start-up function is made per agent. + Exactly one call to a start-up function is made per agent. If an agent is started during the OnLoad phase then its agent library must export a start-up function with the following prototype: -JNIEXPORT jint JNICALL +JNIEXPORT jint JNICALL Agent_OnLoad(JavaVM *vm, char *options, void *reserved) Or for a statically linked agent named 'L': -JNIEXPORT jint JNICALL +JNIEXPORT jint JNICALL Agent_OnLoad_L(JavaVM *vm, char *options, void *reserved) - The VM will start the agent by calling this function. + The VM will start the agent by calling this function. It will be called early enough in VM initialization that:

  • system properties may be set before they have been used in the start-up of the VM
  • -
  • the full set of +
  • the full set of capabilities is still available (note that capabilities that configure the VM - may only be available at this time--see the + may only be available at this time--see the Capability function section)
  • no bytecodes have executed
  • no classes have been loaded
  • @@ -588,13 +588,13 @@ Agent_OnLoad_L(JavaVM *vm, char *options, void *reserved)

    The VM will call the Agent_OnLoad or Agent_OnLoad_<agent-lib-name> function with - <options> as the second argument - + <options> as the second argument - that is, using the command-line option examples, - "opt1,opt2" will be passed to the char *options + "opt1,opt2" will be passed to the char *options argument of Agent_OnLoad. The options argument is encoded as a modified UTF-8 string. - If =<options> is not specified, + If =<options> is not specified, a zero length string is passed to options. The lifespan of the options string is the Agent_OnLoad or Agent_OnLoad_<agent-lib-name> @@ -602,26 +602,26 @@ Agent_OnLoad_L(JavaVM *vm, char *options, void *reserved) be copied. The period between when Agent_OnLoad is called and when it returns is called the OnLoad phase. - Since the VM is not initialized during the OnLoad + Since the VM is not initialized during the OnLoad phase, - the set of allowed operations + the set of allowed operations inside Agent_OnLoad is restricted (see the function descriptions for the - functionality available at this time). - The agent can safely process the options and set - event callbacks with . Once - the VM initialization event is received - (that is, the VMInit + functionality available at this time). + The agent can safely process the options and set + event callbacks with . Once + the VM initialization event is received + (that is, the VMInit callback is invoked), the agent can complete its initialization. Early startup is required so that agents can set the desired capabilities, many of which must be set before the VM is initialized. - In JVMDI, the -Xdebug command-line option provided - very coarse-grain control of capabilities. + In JVMDI, the -Xdebug command-line option provided + very coarse-grain control of capabilities. JVMPI implementations use various tricks to provide a single "JVMPI on" switch. - No reasonable command-line + No reasonable command-line option could provide the fine-grain of control required to balance needed capabilities vs - performance impact. + performance impact. Early startup is also needed so that agents can control the execution environment - modifying the file system and system properties to install their functionality. @@ -631,75 +631,75 @@ Agent_OnLoad_L(JavaVM *vm, char *options, void *reserved) Agent_OnLoad_<agent-lib-name> is used to indicate an error. Any value other than zero indicates an error and causes termination of the VM. - + - A VM may support a mechanism that allows agents to be started in the VM during the live + A VM may support a mechanism that allows agents to be started in the VM during the live phase. The details of how this is supported, - are implementation specific. For example, a tool may use some platform specific mechanism, + are implementation specific. For example, a tool may use some platform specific mechanism, or implementation specific API, to attach to the running VM, and request it start a given agent.

    If an agent is started during the live phase then its agent library - must export a start-up function + must export a start-up function with the following prototype: -JNIEXPORT jint JNICALL +JNIEXPORT jint JNICALL Agent_OnAttach(JavaVM* vm, char *options, void *reserved) Or for a statically linked agent named 'L': -JNIEXPORT jint JNICALL +JNIEXPORT jint JNICALL Agent_OnAttach_L(JavaVM* vm, char *options, void *reserved) -

    - The VM will start the agent by calling this function. +

    + The VM will start the agent by calling this function. It will be called in the context of a thread that is attached to the VM. The first argument <vm> is the Java VM. The <options> argument is the startup options provided to the agent. <options> is encoded as a modified UTF-8 string. - If startup options were not provided, a zero length string is passed to - options. The lifespan of the options string is the + If startup options were not provided, a zero length string is passed to + options. The lifespan of the options string is the Agent_OnAttach or Agent_OnAttach_<agent-lib-name> call. If needed beyond this time the string or parts of the string must be copied.

    - Note that some capabilities + Note that some capabilities may not be available in the live phase.

    The Agent_OnAttach or Agent_OnAttach_<agent-lib-name > function initializes the agent and returns a value - to the VM to indicate if an error occurred. Any value other than zero indicates an error. - An error does not cause the VM to terminate. Instead the VM ignores the error, or takes - some implementation specific action -- for example it might print an error to standard error, + to the VM to indicate if an error occurred. Any value other than zero indicates an error. + An error does not cause the VM to terminate. Instead the VM ignores the error, or takes + some implementation specific action -- for example it might print an error to standard error, or record the error in a system log. - The library may optionally export a + The library may optionally export a shutdown function with the following prototype: -JNIEXPORT void JNICALL +JNIEXPORT void JNICALL Agent_OnUnload(JavaVM *vm) Or for a statically linked agent named 'L': -JNIEXPORT void JNICALL +JNIEXPORT void JNICALL Agent_OnUnload_L(JavaVM *vm) This function will be called by the VM when the library is about to be unloaded. The library will be unloaded (unless it is statically linked into the - executable) and this function will be called if some platform specific + executable) and this function will be called if some platform specific mechanism causes the unload (an unload mechanism is not specified in this document) - or the library is (in effect) unloaded by the termination of the VM whether through + or the library is (in effect) unloaded by the termination of the VM whether through normal termination or VM failure, including start-up failure. Uncontrolled shutdown is, of couse, an exception to this rule. - Note the distinction between this function and the + Note the distinction between this function and the VM Death event: for the VM Death event - to be sent, the VM must have run at least to the point of initialization and a valid + to be sent, the VM must have run at least to the point of initialization and a valid environment must exist which has set a callback for VMDeath and enabled the event. None of these are required for Agent_OnUnload or Agent_OnUnload_<agent-lib-name> and this function is also called if the library is unloaded for other reasons. - In the case that a VM Death event is sent, it will be sent before this + In the case that a VM Death event is sent, it will be sent before this function is called (assuming this function is called due to VM termination). This function can be used to clean-up resources allocated by the agent. @@ -709,17 +709,17 @@ Agent_OnUnload_L(JavaVM *vm) or simply VMs launched deep within scripts, a JAVA_TOOL_OPTIONS variable is provided so that agents may be launched in these cases.

    - Platforms which support environment variables or other named strings, may support the - JAVA_TOOL_OPTIONS variable. This variable will be broken into options at white-space - boundaries. White-space characters include space, tab, carriage-return, new-line, - vertical-tab, and form-feed. Sequences of white-space characters are considered - equivalent to a single white-space character. No white-space is included in the options + Platforms which support environment variables or other named strings, may support the + JAVA_TOOL_OPTIONS variable. This variable will be broken into options at white-space + boundaries. White-space characters include space, tab, carriage-return, new-line, + vertical-tab, and form-feed. Sequences of white-space characters are considered + equivalent to a single white-space character. No white-space is included in the options unless quoted. Quoting is as follows:

      -
    • All characters enclosed between a pair of single quote marks (''), except a single +
    • All characters enclosed between a pair of single quote marks (''), except a single quote, are quoted.
    • Double quote characters have no special meaning inside a pair of single quote marks.
    • -
    • All characters enclosed between a pair of double quote marks (""), except a double +
    • All characters enclosed between a pair of double quote marks (""), except a double quote, are quoted.
    • Single quote characters have no special meaning inside a pair of double quote marks.
    • A quoted part can start or end anywhere in the variable.
    • @@ -727,24 +727,24 @@ Agent_OnUnload_L(JavaVM *vm) the option like any other character and do not mark white-space boundaries.
    • The pair of quote marks is not included in the option.
    - JNI_CreateJavaVM (in the JNI Invocation API) will prepend these options to the options supplied - in its JavaVMInitArgs argument. Platforms may disable this feature in cases where security is - a concern; for example, the Reference Implementation disables this feature on Unix systems when - the effective user or group ID differs from the real ID. - This feature is intended to support the initialization of tools -- specifically including the - launching of native or Java programming language agents. Multiple tools may wish to use this - feature, so the variable should not be overwritten, instead, options should be appended to - the variable. Note that since the variable is processed at the time of the JNI Invocation + JNI_CreateJavaVM (in the JNI Invocation API) will prepend these options to the options supplied + in its JavaVMInitArgs argument. Platforms may disable this feature in cases where security is + a concern; for example, the Reference Implementation disables this feature on Unix systems when + the effective user or group ID differs from the real ID. + This feature is intended to support the initialization of tools -- specifically including the + launching of native or Java programming language agents. Multiple tools may wish to use this + feature, so the variable should not be overwritten, instead, options should be appended to + the variable. Note that since the variable is processed at the time of the JNI Invocation API create VM call, options processed by a launcher (e.g., VM selection options) will not be handled. The specification supports the use of multiple simultaneous agents. - Each agent has its own environment. + Each agent has its own environment. That is, the state is separate for each agent - changes to one environment do not affect the - others. The state of a + others. The state of a environment includes:
    • the event callbacks
    • @@ -752,7 +752,7 @@ Agent_OnUnload_L(JavaVM *vm)
    • the capabilities
    • the memory allocation/deallocation hooks
    - Although their state + Although their state is separate, agents inspect and modify the shared state of the VM, they also share the native environment in which they execute. As such, an agent can perturb the results of other agents or cause them @@ -761,30 +761,30 @@ Agent_OnUnload_L(JavaVM *vm) of preventing destructive interactions between agents. Techniques to reduce the likelihood of these occurrences are beyond the scope of this document.

    - An agent creates a environment - by passing a version - as the interface ID to the JNI Invocation API function - + An agent creates a environment + by passing a version + as the interface ID to the JNI Invocation API function + GetEnv. See Accessing Functions - for more details on the creation and use of + for more details on the creation and use of environments. - Typically, environments are created by calling GetEnv from + Typically, environments are created by calling GetEnv from Agent_OnLoad. This interface does not include some events that one might expect in an interface with profiling support. Some examples include object allocation events and full speed - method enter and exit events. The interface instead provides support for + method enter and exit events. The interface instead provides support for bytecode instrumentation, the ability to alter the Java virtual machine bytecode instructions which comprise the target program. Typically, these alterations are to add "events" to the code of a method - for example, to add, at the beginning of a method, - a call to MyProfiler.methodEntered(). + a call to MyProfiler.methodEntered(). Since the changes are purely additive, they do not modify application state or behavior. Because the inserted agent code is standard bytecodes, the VM can run at full speed, - optimizing not only the target program but also the instrumentation. If the + optimizing not only the target program but also the instrumentation. If the instrumentation does not involve switching from bytecode execution, no expensive state transitions are needed. The result is high performance events. This approach also provides complete control to the agent: instrumentation can be @@ -792,14 +792,14 @@ Agent_OnUnload_L(JavaVM *vm) can be conditional. Instrumentation can run entirely in Java programming language code or can call into the native agent. Instrumentation can simply maintain counters or can statistically sample events. -

    +

    Instrumentation can be inserted in one of three ways:

    • Static Instrumentation: The class file is instrumented before it is loaded into the VM - for example, by creating a duplicate directory of *.class files which have been modified to add the instrumentation. - This method is extremely awkward and, in general, an agent cannot know + This method is extremely awkward and, in general, an agent cannot know the origin of the class files which will be loaded.
    • @@ -817,21 +817,21 @@ Agent_OnUnload_L(JavaVM *vm) function. Classes can be modified multiple times and can be returned to their original state. - The mechanism allows instrumentation which changes during the + The mechanism allows instrumentation which changes during the course of execution.
    -

    +

    The class modification functionality provided in this interface is intended to provide a mechanism for instrumentation (the event and the function) and, during development, for fix-and-continue debugging (the function). -

    - Care must be taken to avoid perturbing dependencies, especially when +

    + Care must be taken to avoid perturbing dependencies, especially when instrumenting core classes. For example, an approach to getting notification - of every object allocation is to instrument the constructor on + of every object allocation is to instrument the constructor on Object. Assuming that the constructor is initially empty, the constructor could be changed to: @@ -839,15 +839,15 @@ Agent_OnUnload_L(JavaVM *vm) MyProfiler.allocationTracker(this); } - However, if this change was made using the + However, if this change was made using the - event then this might impact a typical VM as follows: + event then this might impact a typical VM as follows: the first created object will call the constructor causing a class load of MyProfiler; which will then cause object creation, and since MyProfiler isn't loaded yet, infinite recursion; resulting in a stack overflow. A refinement of this would be to delay invoking the tracking method until a safe time. For - example, trackAllocations could be set in the + example, trackAllocations could be set in the handler for the VMInit event. static boolean trackAllocations = false; @@ -881,17 +881,17 @@ Agent_OnUnload_L(JavaVM *vm) uses modified UTF-8 to encode character strings. This is the same encoding used by JNI. - Modified UTF-8 differs - from standard UTF-8 in the representation of supplementary characters + Modified UTF-8 differs + from standard UTF-8 in the representation of supplementary characters and of the null character. See the - + Modified UTF-8 Strings section of the JNI specification for details. Since this interface provides access to the state of applications running in the - Java virtual machine; + Java virtual machine; terminology refers to the Java platform and not the native platform (unless stated otherwise). For example:

      @@ -903,20 +903,20 @@ Agent_OnUnload_L(JavaVM *vm)

    Sun, Sun Microsystems, the Sun logo, Java, and JVM - are trademarks or registered trademarks of Oracle + are trademarks or registered trademarks of Oracle and/or its affiliates, in the U.S. and other countries. - Native code accesses features - by calling functions. + Native code accesses features + by calling functions. Access to functions is by use of an interface pointer - in the same manner as - Java + in the same manner as + Java Native Interface (JNI) functions are accessed. - The interface pointer is called the + The interface pointer is called the environment pointer.

    An environment pointer is a pointer to an environment and has @@ -924,8 +924,8 @@ Agent_OnUnload_L(JavaVM *vm) An environment has information about its connection. The first value in the environment is a pointer to the function table. The function table is an array of pointers to functions. - Every function pointer is at a predefined offset inside the - array. + Every function pointer is at a predefined offset inside the + array.

    When used from the C language: double indirection is used to access the functions; @@ -945,7 +945,7 @@ jvmtiEnv *jvmti; ... jvmtiError err = jvmti->GetLoadedClasses(&class_count, &classes); - Unless otherwise stated, all examples and declarations in this + Unless otherwise stated, all examples and declarations in this specification use the C language.

    A environment can be obtained through the JNI Invocation API @@ -955,24 +955,24 @@ jvmtiEnv *jvmti; ... (*jvm)->GetEnv(jvm, &jvmti, JVMTI_VERSION_1_0); - Each call to GetEnv + Each call to GetEnv creates a new connection and thus - a new environment. + a new environment. The version argument of GetEnv must be a version. The returned environment may have a different version than the requested version but the returned environment must be compatible. - GetEnv will return JNI_EVERSION if a + GetEnv will return JNI_EVERSION if a compatible version is not available, if is not supported or is not supported in the current VM configuration. Other interfaces may be added for creating environments in specific contexts. Each environment has its own state (for example, - desired events, - event handling functions, and - capabilities). - An environment is released with - . + desired events, + event handling functions, and + capabilities). + An environment is released with + . Thus, unlike JNI which has one environment per thread, environments work across threads and are created dynamically. @@ -980,12 +980,12 @@ jvmtiEnv *jvmti; functions always return an error code via the - function return value. + function return value. Some functions can return additional - values through pointers provided by the calling function. + values through pointers provided by the calling function. In some cases, functions allocate memory that your program must explicitly deallocate. This is indicated in the individual - function descriptions. Empty lists, arrays, sequences, etc are + function descriptions. Empty lists, arrays, sequences, etc are returned as NULL.

    In the event that the function encounters @@ -996,26 +996,26 @@ jvmtiEnv *jvmti; - functions identify objects with JNI references + functions identify objects with JNI references ( and ) and their derivatives ( and ). - References passed to - functions can be either global or local, but they must be - strong references. All references returned by functions are - local references--these local references are created + References passed to + functions can be either global or local, but they must be + strong references. All references returned by functions are + local references--these local references are created during the call. - Local references are a resource that must be managed (see the - - JNI Documentation). + Local references are a resource that must be managed (see the + + JNI Documentation). When threads return from native code all local references are freed. Note that some threads, including typical agent threads, will never return from native code. - A thread is ensured the ability to create sixteen local + A thread is ensured the ability to create sixteen local references without the need for any explicit management. For threads executing a limited number of calls before returning from native code - (for example, threads processing events), + (for example, threads processing events), it may be determined that no explicit management is needed. However, long running agent threads will need explicit @@ -1023,7 +1023,7 @@ jvmtiEnv *jvmti; PushLocalFrame and PopLocalFrame. Conversely, to preserve references beyond the return from native code, they must be converted to global references. - These rules do not apply to and + These rules do not apply to and as they are not s. @@ -1035,21 +1035,21 @@ jvmtiEnv *jvmti; - functions never throw exceptions; error conditions are - communicated via the + functions never throw exceptions; error conditions are + communicated via the function return value. - Any existing exception state is preserved across a call to a + Any existing exception state is preserved across a call to a function. See the - Java Exceptions section of the JNI specification for information on handling exceptions. - These functions provide for the allocation and deallocation of + These functions provide for the allocation and deallocation of memory used by functionality and can be used to provide working memory for agents. Memory managed by is not compatible with other memory @@ -1059,7 +1059,7 @@ jvmtiEnv *jvmti; Allocate - Allocate an area of memory through the allocator. + Allocate an area of memory through the allocator. The allocated memory should be freed with . @@ -1097,9 +1097,9 @@ jvmtiEnv *jvmti; Deallocate - Deallocate mem using the allocator. + Deallocate mem using the allocator. This function should - be used to deallocate any memory allocated and returned + be used to deallocate any memory allocated and returned by a function (including memory allocated with ). All allocated memory must be deallocated @@ -1143,60 +1143,60 @@ jvmtiEnv *jvmti;

  • Why not alive?
    • New.
    • -
    • Terminated (Terminated (JVMTI_THREAD_STATE_TERMINATED)
-
  • Alive (Alive (JVMTI_THREAD_STATE_ALIVE)
    • Suspended?
        -
      • Suspended (Suspended (JVMTI_THREAD_STATE_SUSPENDED)
      • Not suspended
    • Interrupted?
        -
      • Interrupted (Interrupted (JVMTI_THREAD_STATE_INTERRUPTED)
      • Not interrupted.
    • In native?
        -
      • In native code (In native code (JVMTI_THREAD_STATE_IN_NATIVE)
      • In Java programming language code
    • What alive state?
        -
      • Runnable (Runnable (JVMTI_THREAD_STATE_RUNNABLE)
      • -
      • Blocked (Blocked (JVMTI_THREAD_STATE_BLOCKED_ON_MONITOR_ENTER)
      • -
      • Waiting (Waiting (JVMTI_THREAD_STATE_WAITING)
        • Timed wait?
            -
          • Indefinite (Indefinite (JVMTI_THREAD_STATE_WAITING_INDEFINITELY
          • -
          • Timed (Timed (JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT)
        • Why waiting?
            -
          • Object.wait (Object.wait (JVMTI_THREAD_STATE_IN_OBJECT_WAIT)
          • -
          • LockSupport.park (LockSupport.park (JVMTI_THREAD_STATE_PARKED)
          • -
          • Sleeping (Sleeping (JVMTI_THREAD_STATE_SLEEPING)
        • @@ -1210,7 +1210,7 @@ jvmtiEnv *jvmti;

        - The answers are represented by the following bit vector. + The answers are represented by the following bit vector. Thread is alive. Zero if thread is new (not started) or terminated. @@ -1223,7 +1223,7 @@ jvmtiEnv *jvmti; Thread is waiting to enter a synchronization block/method or, - after an Object.wait(), waiting to re-enter a + after an Object.wait(), waiting to re-enter a synchronization block/method. @@ -1250,8 +1250,8 @@ jvmtiEnv *jvmti; Thread suspended. java.lang.Thread.suspend() - or a suspend function - (such as ) + or a suspend function + (such as ) has been called on the thread. If this bit is set, the other bits refer to the thread state before suspension. @@ -1313,7 +1313,7 @@ jvmtiEnv *jvmti; Rules

        There can be no more than one answer to a question, although there can be no - answer (because the answer is unknown, does not apply, or none of the answers is + answer (because the answer is unknown, does not apply, or none of the answers is correct). An answer is set only when the enclosing answers match. That is, no more than one of

          @@ -1322,32 +1322,32 @@ jvmtiEnv *jvmti;
        • JVMTI_THREAD_STATE_WAITING
        can be set (a J2SE compliant implementation will always set - one of these if JVMTI_THREAD_STATE_ALIVE is set). - And if any of these are set, the enclosing answer - JVMTI_THREAD_STATE_ALIVE is set. + one of these if JVMTI_THREAD_STATE_ALIVE is set). + And if any of these are set, the enclosing answer + JVMTI_THREAD_STATE_ALIVE is set. No more than one of
        • JVMTI_THREAD_STATE_WAITING_INDEFINITELY
        • JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT
        can be set (a J2SE compliant implementation will always set - one of these if JVMTI_THREAD_STATE_WAITING is set). - And if either is set, the enclosing answers - JVMTI_THREAD_STATE_ALIVE and - JVMTI_THREAD_STATE_WAITING are set. + one of these if JVMTI_THREAD_STATE_WAITING is set). + And if either is set, the enclosing answers + JVMTI_THREAD_STATE_ALIVE and + JVMTI_THREAD_STATE_WAITING are set. No more than one of
        • JVMTI_THREAD_STATE_IN_OBJECT_WAIT
        • JVMTI_THREAD_STATE_PARKED
        • JVMTI_THREAD_STATE_SLEEPING
        - can be set. And if any of these is set, the enclosing answers - JVMTI_THREAD_STATE_ALIVE and - JVMTI_THREAD_STATE_WAITING are set. + can be set. And if any of these is set, the enclosing answers + JVMTI_THREAD_STATE_ALIVE and + JVMTI_THREAD_STATE_WAITING are set. Also, if JVMTI_THREAD_STATE_SLEEPING is set, then JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT is set. - If a state A is implemented using the mechanism of - state B then it is state A which + If a state A is implemented using the mechanism of + state B then it is state A which is returned by this function. For example, if Thread.sleep(long) is implemented using Object.wait(long) @@ -1364,16 +1364,16 @@ jvmtiEnv *jvmti;

        And finally, JVMTI_THREAD_STATE_TERMINATED cannot be set unless - JVMTI_THREAD_STATE_ALIVE is not set. + JVMTI_THREAD_STATE_ALIVE is not set.

        The thread state representation is designed for extension in future versions of the specification; thread state values should be used accordingly, that is - they should not be used as ordinals. + they should not be used as ordinals. Most queries can be made by testing a single bit, if use in a switch statement is desired, the state bits should be masked with the interesting bits. - All bits not defined above are reserved for future use. + All bits not defined above are reserved for future use. A VM, compliant to the current specification, must set reserved bits to zero. - An agent should ignore reserved bits -- + An agent should ignore reserved bits -- they should not be assumed to be zero and thus should not be included in comparisons.

        Examples @@ -1390,8 +1390,8 @@ jvmtiEnv *jvmti; The state of a thread at a Object.wait(3000) would be: - JVMTI_THREAD_STATE_ALIVE + JVMTI_THREAD_STATE_WAITING + - JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT + + JVMTI_THREAD_STATE_ALIVE + JVMTI_THREAD_STATE_WAITING + + JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT + JVMTI_THREAD_STATE_MONITOR_WAITING The state of a thread suspended while runnable would be: @@ -1423,7 +1423,7 @@ jvmtiEnv *jvmti; To distinguish timed from untimed Object.wait: - if (state & JVMTI_THREAD_STATE_IN_OBJECT_WAIT) { + if (state & JVMTI_THREAD_STATE_IN_OBJECT_WAIT) { if (state & JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT) { printf("in Object.wait(long timeout)\n"); } else { @@ -1436,7 +1436,7 @@ jvmtiEnv *jvmti;

        The thread state represented by java.lang.Thread.State returned from java.lang.Thread.getState() is a subset of the - information returned from this function. + information returned from this function. The corresponding java.lang.Thread.State can be determined by using the provided conversion masks. For example, this returns the name of the java.lang.Thread.State thread state: @@ -1466,7 +1466,7 @@ jvmtiEnv *jvmti; - The thread to query. + The thread to query. @@ -1484,11 +1484,15 @@ jvmtiEnv *jvmti; Get Current Thread - Get the current thread. + Get the current thread. The current thread is the Java programming language thread which has called the function. + The function may return NULL in the start phase if the + + can_generate_early_vmstart capability is enabled + and the java.lang.Thread class has not been initialized yet.

        - Note that most functions that take a thread - as an argument will accept NULL to mean + Note that most functions that take a thread + as an argument will accept NULL to mean the current thread. new @@ -1498,7 +1502,7 @@ jvmtiEnv *jvmti; - On return, points to the current thread. + On return, points to the current thread, or NULL. @@ -1512,12 +1516,12 @@ jvmtiEnv *jvmti; Get all live threads. The threads are Java programming language threads; that is, threads that are attached to the VM. - A thread is live if java.lang.Thread.isAlive() + A thread is live if java.lang.Thread.isAlive() would return true, that is, the thread has been started and has not yet died. The universe of threads is determined by the context of the environment, which typically is all threads attached to the VM. - Note that this includes agent threads + Note that this includes agent threads (see ). jvmdi @@ -1545,8 +1549,8 @@ jvmtiEnv *jvmti; Suspend Thread - Suspend the specified thread. If the calling thread is specified, - this function will not return until some other thread calls + Suspend the specified thread. If the calling thread is specified, + this function will not return until some other thread calls . If the thread is currently suspended, this function does nothing and returns an error. @@ -1559,7 +1563,7 @@ jvmtiEnv *jvmti; - The thread to suspend. + The thread to suspend. @@ -1588,22 +1592,22 @@ jvmtiEnv *jvmti; The threads are Java programming language threads; native threads which are not attached to the VM are not Java programming language threads. - A thread is live if java.lang.Thread.isAlive() + A thread is live if java.lang.Thread.isAlive() would return true, that is, the thread has been started and has not yet died. - The universe of threads is determined + The universe of threads is determined by the context of the environment, which, typically, is all threads attached to the VM, - except critical VM internal threads and agent threads + except critical VM internal threads and agent threads (see ).

        - If the calling thread is specified, + If the calling thread is specified, all other threads are suspended first then the caller thread is suspended - - this function will not return until some other thread calls + this function will not return until some other thread calls .

        The list of actually - suspended threads is returned in + suspended threads is returned in . Suspension is as defined in . @@ -1658,13 +1662,13 @@ jvmtiEnv *jvmti; Suspend Thread List - Suspend the - threads specified in the - array. + Suspend the + threads specified in the + array. Threads may be resumed with or . - If the calling thread is specified in the + If the calling thread is specified in the array, this function will not return until some other thread resumes it. Errors encountered in the suspension of a thread @@ -1692,11 +1696,11 @@ jvmtiEnv *jvmti; jvmtiError - An agent supplied array of + An agent supplied array of elements. On return, filled with the error code for the suspend of the corresponding thread. - The error code will be + The error code will be if the thread was suspended by this call. Possible error codes are those specified @@ -1711,12 +1715,12 @@ jvmtiEnv *jvmti; Resume Thread - Resume a suspended thread. + Resume a suspended thread. Any threads currently suspended through a suspend function (eg. - ) + ) or java.lang.Thread.suspend() - will resume execution; + will resume execution; all other threads are unaffected. jvmdi @@ -1736,7 +1740,7 @@ jvmtiEnv *jvmti; Thread was not suspended. - The state of the thread has been modified, and is now inconsistent. + The state of the thread has been modified, and is now inconsistent. @@ -1744,12 +1748,12 @@ jvmtiEnv *jvmti; Resume Thread List - Resume the - threads specified in the - array. + Resume the + threads specified in the + array. Any thread suspended through a suspend function (eg. - ) + ) or java.lang.Thread.suspend() will resume execution. @@ -1773,11 +1777,11 @@ jvmtiEnv *jvmti; jvmtiError - An agent supplied array of + An agent supplied array of elements. On return, filled with the error code for the resume of the corresponding thread. - The error code will be + The error code will be if the thread was suspended by this call. Possible error codes are those specified @@ -1792,9 +1796,9 @@ jvmtiEnv *jvmti; Stop Thread - Send the specified asynchronous exception to the specified thread + Send the specified asynchronous exception to the specified thread (similar to java.lang.Thread.stop). - Normally, this function is used to kill the specified thread with an + Normally, this function is used to kill the specified thread with an instance of the exception ThreadDeath. jvmdi @@ -1879,7 +1883,7 @@ jvmtiEnv *jvmti; - Get thread information. The fields of the structure + Get thread information. The fields of the structure are filled in with details of the specified thread. jvmdi @@ -1906,8 +1910,8 @@ jvmtiEnv *jvmti; Get Owned Monitor Info - Get information about the monitors owned by the - specified thread. + Get information about the monitors owned by the + specified thread. jvmdiClone @@ -1939,7 +1943,7 @@ jvmtiEnv *jvmti; Get Owned Monitor Stack Depth Info - @@ -1950,18 +1954,18 @@ jvmtiEnv *jvmti; - The stack depth. Corresponds to the stack depth used in the + The stack depth. Corresponds to the stack depth used in the Stack Frame functions. That is, zero is the current frame, one is the frame which - called the current frame. And it is negative one if the - implementation cannot determine the stack depth (e.g., for + called the current frame. And it is negative one if the + implementation cannot determine the stack depth (e.g., for monitors acquired by JNI MonitorEnter). - Get information about the monitors owned by the - specified thread and the depth of the stack frame which locked them. + Get information about the monitors owned by the + specified thread and the depth of the stack frame which locked them. new @@ -1996,7 +2000,7 @@ jvmtiEnv *jvmti; Get Current Contended Monitor - Get the object, if any, whose monitor the specified thread is waiting to + Get the object, if any, whose monitor the specified thread is waiting to enter or waiting to regain through java.lang.Object.wait. jvmdi @@ -2053,7 +2057,7 @@ jvmtiEnv *jvmti; - The arg parameter passed to + The arg parameter passed to . @@ -2067,13 +2071,13 @@ jvmtiEnv *jvmti; The parameter is forwarded on to the start function (specified with ) as its single argument. - This function allows the creation of agent threads - for handling communication with another process or for handling events - without the need to load a special subclass of java.lang.Thread or - implementer of java.lang.Runnable. + This function allows the creation of agent threads + for handling communication with another process or for handling events + without the need to load a special subclass of java.lang.Thread or + implementer of java.lang.Runnable. Instead, the created thread can run entirely in native code. However, the created thread does require a newly created instance - of java.lang.Thread (referenced by the argument thread) to + of java.lang.Thread (referenced by the argument thread) to which it will be associated. The thread object can be created with JNI calls.

        @@ -2101,14 +2105,14 @@ jvmtiEnv *jvmti; added to the thread group and the thread is not seen on queries of the thread group at either the Java programming language or levels.

        - The thread is not visible to Java programming language queries but is - included in queries (for example, + The thread is not visible to Java programming language queries but is + included in queries (for example, and ).

        Upon execution of proc, the new thread will be attached to the - VM -- see the JNI documentation on - Attaching to the VM. jvmdiClone @@ -2148,8 +2152,8 @@ jvmtiEnv *jvmti; - - is less than + + is less than or greater than @@ -2165,7 +2169,7 @@ jvmtiEnv *jvmti; This value is NULL unless set with this function. Agents can allocate memory in which they store thread specific information. By setting thread-local storage it can then be - accessed with + accessed with .

        This function is called by the agent to set the value of the @@ -2184,10 +2188,10 @@ jvmtiEnv *jvmti; - - - value is set to NULL - + + + value is set to NULL + The value to be entered into the thread-local storage. @@ -2201,7 +2205,7 @@ jvmtiEnv *jvmti; Get Thread Local Storage Called by the agent to get the value of the thread-local - storage. + storage. jvmpi @@ -2216,10 +2220,10 @@ jvmtiEnv *jvmti; - Pointer through which the value of the thread local + Pointer through which the value of the thread local storage is returned. If thread-local storage has not been set with - the returned + the returned pointer is NULL. @@ -2290,8 +2294,8 @@ jvmtiEnv *jvmti; - Get information about the thread group. The fields of the - structure + Get information about the thread group. The fields of the + structure are filled in with details of the specified thread group. jvmdi @@ -2308,7 +2312,7 @@ jvmtiEnv *jvmti; jvmtiThreadGroupInfo On return, filled with information describing the specified - thread group. + thread group. @@ -2369,15 +2373,15 @@ jvmtiEnv *jvmti;

        Stack frames are as described in , - That is, they correspond to method - invocations (including native methods) but do not correspond to platform native or + That is, they correspond to method + invocations (including native methods) but do not correspond to platform native or VM internal frames.

        A implementation may use method invocations to launch a thread and the corresponding frames may be included in the stack as presented by these functions -- that is, there may be frames shown deeper than main() and run(). - However this presentation must be consistent across all functionality which + However this presentation must be consistent across all functionality which uses stack frames or stack depth. @@ -2421,16 +2425,16 @@ jvmtiEnv *jvmti; jvmtiFrameInfo - On return, this agent allocated buffer is filled - with stack frame information. + On return, this agent allocated buffer is filled + with stack frame information. - On return, the number of records filled into + On return, the number of records filled into frame_buffer. - This will be + This will be min(max_frame_count, stackDepth). @@ -2441,7 +2445,7 @@ jvmtiEnv *jvmti; Get information about the stack of a thread. If is less than the depth of the stack, - the topmost frames are returned, + the topmost frames are returned, otherwise the entire stack is returned. The topmost frames, those most recently invoked, are at the beginning of the returned buffer.

        @@ -2453,23 +2457,23 @@ jvmtiFrameInfo frames[5]; jint count; jvmtiError err; -err = (*jvmti)->GetStackTrace(jvmti, aThread, 0, 5, +err = (*jvmti)->GetStackTrace(jvmti, aThread, 0, 5, frames, &count); if (err == JVMTI_ERROR_NONE && count >= 1) { char *methodName; - err = (*jvmti)->GetMethodName(jvmti, frames[0].method, + err = (*jvmti)->GetMethodName(jvmti, frames[0].method, &methodName, NULL, NULL); if (err == JVMTI_ERROR_NONE) { printf("Executing method: %s", methodName); } } - + check example code.

        The need not be suspended - to call this function. + to call this function.

        The function can be used to map locations to line numbers. Note that @@ -2488,15 +2492,15 @@ if (err == JVMTI_ERROR_NONE && count >= 1) { - Begin retrieving frames at this depth. - If non-negative, count from the current frame, - the first frame retrieved is at depth start_depth. + Begin retrieving frames at this depth. + If non-negative, count from the current frame, + the first frame retrieved is at depth start_depth. For example, if zero, start from the current frame; if one, start from the caller of the current frame; if two, start from the caller of the caller of the current frame; and so on. If negative, count from below the oldest frame, - the first frame retrieved is at depth stackDepth + start_depth, - where stackDepth is the count of frames on the stack. + the first frame retrieved is at depth stackDepth + start_depth, + where stackDepth is the count of frames on the stack. For example, if negative one, only the oldest frame is retrieved; if negative two, start from the frame called by the oldest frame. @@ -2512,17 +2516,17 @@ if (err == JVMTI_ERROR_NONE && count >= 1) { jvmtiFrameInfo - On return, this agent allocated buffer is filled - with stack frame information. + On return, this agent allocated buffer is filled + with stack frame information. On return, points to the number of records filled in. - For non-negative start_depth, this will be + For non-negative start_depth, this will be min(max_frame_count, stackDepth - start_depth). - For negative start_depth, this will be + For negative start_depth, this will be min(max_frame_count, -start_depth). @@ -2542,23 +2546,23 @@ if (err == JVMTI_ERROR_NONE && count >= 1) { Get information about the stacks of all live threads (including agent threads). If is less than the depth of a stack, - the topmost frames are returned for that thread, + the topmost frames are returned for that thread, otherwise the entire stack is returned. The topmost frames, those most recently invoked, are at the beginning of the returned buffer.

        - All stacks are collected simultaneously, that is, no changes will occur to the + All stacks are collected simultaneously, that is, no changes will occur to the thread state or stacks between the sampling of one thread and the next. The threads need not be suspended. - + jvmtiStackInfo *stack_info; jint thread_count; int ti; jvmtiError err; -err = (*jvmti)->GetAllStackTraces(jvmti, MAX_FRAMES, &stack_info, &thread_count); +err = (*jvmti)->GetAllStackTraces(jvmti, MAX_FRAMES, &stack_info, &thread_count); if (err != JVMTI_ERROR_NONE) { - ... + ... } for (ti = 0; ti < thread_count; ++ti) { jvmtiStackInfo *infop = &stack_info[ti]; @@ -2573,9 +2577,9 @@ for (ti = 0; ti < thread_count; ++ti) { } } /* this one Deallocate call frees all data allocated by GetAllStackTraces */ -err = (*jvmti)->Deallocate(jvmti, stack_info); +err = (*jvmti)->Deallocate(jvmti, stack_info); - + check example code. @@ -2595,12 +2599,12 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); jvmtiStackInfo - On return, this buffer is filled - with stack information for each thread. - The number of records is determined + On return, this buffer is filled + with stack information for each thread. + The number of records is determined by .

        - Note that this buffer is allocated to include the + Note that this buffer is allocated to include the buffers pointed to by . These buffers must not be separately deallocated. @@ -2621,11 +2625,11 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Get information about the stacks of the supplied threads. If is less than the depth of a stack, - the topmost frames are returned for that thread, + the topmost frames are returned for that thread, otherwise the entire stack is returned. The topmost frames, those most recently invoked, are at the beginning of the returned buffer.

        - All stacks are collected simultaneously, that is, no changes will occur to the + All stacks are collected simultaneously, that is, no changes will occur to the thread state or stacks between the sampling one thread and the next. The threads need not be suspended.

        @@ -2663,12 +2667,12 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); jvmtiStackInfo - On return, this buffer is filled - with stack information for each thread. - The number of records is determined + On return, this buffer is filled + with stack information for each thread. + The number of records is determined by .

        - Note that this buffer is allocated to include the + Note that this buffer is allocated to include the buffers pointed to by . These buffers must not be separately deallocated. @@ -2699,8 +2703,8 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); - If false, - + If false, + must be false. @@ -2709,7 +2713,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Return the stack showing - model of the stack; + model of the stack; otherwise, show the internal representation of the stack with inlined and optimized methods missing. If the virtual machine is using the Java Virtual Machine Specification stack model @@ -2730,9 +2734,9 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); The agent passes in a buffer - large enough to hold max_count records of + large enough to hold max_count records of . This buffer must be - pre-allocated by the agent. + pre-allocated by the agent. @@ -2784,27 +2788,27 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Pop Frame Pop the current frame of thread's stack. - Popping a frame takes you to the previous frame. - When the thread is resumed, the execution + Popping a frame takes you to the previous frame. + When the thread is resumed, the execution state of the thread is reset to the state immediately before the called method was invoked. That is (using terminology):

        • the current frame is discarded as the previous frame becomes the current one
        • the operand stack is restored--the argument values are added back - and if the invoke was not invokestatic, + and if the invoke was not invokestatic, objectref is added back as well
        • the Java virtual machine PC is restored to the opcode of the invoke instruction
        Note however, that any changes to the arguments, which - occurred in the called method, remain; - when execution continues, the first instruction to - execute will be the invoke. + occurred in the called method, remain; + when execution continues, the first instruction to + execute will be the invoke.

        - Between calling PopFrame and resuming the - thread the state of the stack is undefined. - To pop frames beyond the first, + Between calling PopFrame and resuming the + thread the state of the stack is undefined. + To pop frames beyond the first, these three steps must be repeated:

        • suspend the thread via an event (step, breakpoint, ...)
        • @@ -2812,11 +2816,11 @@ err = (*jvmti)->Deallocate(jvmti, stack_info);
        • resume the thread

        - A lock acquired by calling the called method - (if it is a synchronized method) + A lock acquired by calling the called method + (if it is a synchronized method) and locks acquired by entering synchronized - blocks within the called method are released. - Note: this does not apply to native locks or + blocks within the called method are released. + Note: this does not apply to native locks or java.util.concurrent.locks locks.

        Finally blocks are not executed. @@ -2825,7 +2829,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info);

        The specified thread must be suspended (which implies it cannot be the current thread).

        - Both the called method and calling method must be non-native Java programming + Both the called method and calling method must be non-native Java programming language methods.

        No events are generated by this function. @@ -2888,7 +2892,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); - On return, points to the index of the currently + On return, points to the index of the currently executing instruction. Is set to -1 if the frame is executing a native method. @@ -2902,11 +2906,11 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Notify Frame Pop - When the frame that is currently at + When the frame that is currently at is popped from the stack, generate a - event. See the + event. See the event for details. - Only frames corresponding to non-native Java programming language + Only frames corresponding to non-native Java programming language methods can receive notification.

        The specified thread must either be the current thread @@ -2918,7 +2922,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); - + The thread of the frame for which the frame pop event will be generated. @@ -2931,7 +2935,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); - + The frame at depth is executing a native method. @@ -2950,7 +2954,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); The method which will return early is referred to as the called method. The called method is the current method (as defined by - ) + ) for the specified thread at the time the function is called.

        @@ -2958,17 +2962,17 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); The return occurs when execution of Java programming language code is resumed on this thread. Between calling one of these functions and resumption - of thread execution, the state of the stack is undefined. + of thread execution, the state of the stack is undefined.

        - No further instructions are executed in the called method. + No further instructions are executed in the called method. Specifically, finally blocks are not executed. Note: this can cause inconsistent states in the application.

        - A lock acquired by calling the called method - (if it is a synchronized method) + A lock acquired by calling the called method + (if it is a synchronized method) and locks acquired by entering synchronized - blocks within the called method are released. - Note: this does not apply to native locks or + blocks within the called method are released. + Note: this does not apply to native locks or java.util.concurrent.locks locks.

        Events, such as , @@ -2985,7 +2989,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); This function can be used to return from a method whose result type is Object - or a subclass of Object. + or a subclass of Object. new @@ -3001,7 +3005,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); - The return value for the called frame. + The return value for the called frame. An object or NULL. @@ -3013,12 +3017,12 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Or the implementation is unable to provide this functionality on this frame. - - The result type of the called method is not + + The result type of the called method is not Object or a subclass of Object. - - The supplied is not compatible with the + + The supplied is not compatible with the result type of the called method. @@ -3035,8 +3039,8 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); This function can be used to return from a method whose result type is int, short, - char, byte, or - boolean. + char, byte, or + boolean. new @@ -3063,10 +3067,10 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Or the implementation is unable to provide this functionality on this frame. - - The result type of the called method is not + + The result type of the called method is not int, short, - char, byte, or + char, byte, or boolean. @@ -3109,7 +3113,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Or the implementation is unable to provide this functionality on this frame. - + The result type of the called method is not long. @@ -3152,7 +3156,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Or the implementation is unable to provide this functionality on this frame. - + The result type of the called method is not float. @@ -3193,7 +3197,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Attempted to return early from a frame corresponding to a native method. Or the implementation is unable to provide this functionality on this frame. - + The result type of the called method is not double. @@ -3230,8 +3234,8 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Or the implementation is unable to provide this functionality on this frame. - - The called method has a result type. + + The called method has a result type. Thread was not the current thread and was not suspended. @@ -3250,12 +3254,12 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Functionality includes the ability to view the objects in the heap and to tag these objects. - + A tag is a value associated with an object. Tags are explicitly set by the agent using the function or by - callback functions such as . + callback functions such as .

        Tags are local to the environment; that is, the tags of one environment are not visible in another. @@ -3263,10 +3267,10 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Tags are jlong values which can be used simply to mark an object or to store a pointer to more detailed information. Objects which have not been tagged have a - tag of zero. + tag of zero. Setting a tag to zero makes the object untagged. - + Heap functions which iterate through the heap and recursively follow object references use agent supplied callback functions @@ -3274,7 +3278,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info);

        These heap callback functions must adhere to the following restrictions -- These callbacks must not use JNI functions. - These callbacks must not use functions except + These callbacks must not use functions except callback safe functions which specifically allow such use (see the raw monitor, memory management, and environment local storage functions). @@ -3285,7 +3289,7 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); be invoked at a time.

        The Heap Filter Flags can be used to prevent reporting - based on the tag status of an object or its class. + based on the tag status of an object or its class. If no flags are set (the jint is zero), objects will not be filtered out. @@ -3306,43 +3310,43 @@ err = (*jvmti)->Deallocate(jvmti, stack_info);

        The Heap Visit Control Flags are returned by the heap callbacks - and can be used to abort the iteration. For the - Heap - Reference Callback, it can also be used + and can be used to abort the iteration. For the + Heap + Reference Callback, it can also be used to prune the graph of traversed references (JVMTI_VISIT_OBJECTS is not set). - If we are visiting an object and if this callback - was initiated by , + was initiated by , traverse the references of this object. Otherwise ignored. - + Abort the iteration. Ignore all other bits.

        - The Heap Reference Enumeration is provided by the - Heap - Reference Callback and - Primitive Field - Callback to + The Heap Reference Enumeration is provided by the + Heap + Reference Callback and + Primitive Field + Callback to describe the kind of reference being reported. - Reference from an object to its class. - + Reference from an object to the value of one of its instance fields. @@ -3357,11 +3361,11 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Reference from a class to its protection domain. - + - Reference from a class to one of its interfaces. + Reference from a class to one of its interfaces. Note: interfaces are defined via a constant pool reference, - so the referenced interfaces may also be reported with a + so the referenced interfaces may also be reported with a JVMTI_HEAP_REFERENCE_CONSTANT_POOL reference kind. @@ -3371,10 +3375,10 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Reference from a class to a resolved entry in the constant pool. - Reference from a class to its superclass. + Reference from a class to its superclass. A callback is not sent if the superclass is java.lang.Object. Note: loaded classes define superclasses via a constant pool - reference, so the referenced superclass may also be reported with + reference, so the referenced superclass may also be reported with a JVMTI_HEAP_REFERENCE_CONSTANT_POOL reference kind. @@ -3404,88 +3408,88 @@ err = (*jvmti)->Deallocate(jvmti, stack_info); Definitions for the single character type descriptors of primitive types. - 'Z' - Java programming language boolean - JNI jboolean - + 'B' - Java programming language byte - JNI jbyte - + 'C' - Java programming language char - JNI jchar - + 'S' - Java programming language short - JNI jshort - + 'I' - Java programming language int - JNI jint - + 'J' - Java programming language long - JNI jlong - + 'F' - Java programming language float - JNI jfloat - + 'D' - Java programming language double - JNI jdouble - + - - Reference information returned for - and + Reference information returned for + and references. - - For , the - referrer object is not a class or an inteface. - In this case, index is the index of the field - in the class of the referrer object. + + For , the + referrer object is not a class or an inteface. + In this case, index is the index of the field + in the class of the referrer object. This class is referred to below as C.

        For , the referrer object is a class (referred to below as C) or an interface (referred to below as I). - In this case, index is the index of the field in + In this case, index is the index of the field in that class or interface.

        - If the referrer object is not an interface, then the field - indices are determined as follows: + If the referrer object is not an interface, then the field + indices are determined as follows:

        • make a list of all the fields in C and its - superclasses, starting with all the fields in + superclasses, starting with all the fields in java.lang.Object and ending with all the fields in C.
        • -
        • Within this list, put +
        • Within this list, put the fields for a given class in the order returned by .
        • -
        • Assign the fields in this list indices - n, n+1, ..., in order, where n +
        • Assign the fields in this list indices + n, n+1, ..., in order, where n is the count of the fields in all the interfaces - implemented by C. - Note that C implements all interfaces + implemented by C. + Note that C implements all interfaces directly implemented by its superclasses; as well as all superinterfaces of these interfaces.
        - If the referrer object is an interface, then the field + If the referrer object is an interface, then the field indices are determined as follows:
          -
        • make a list of the fields directly declared in +
        • make a list of the fields directly declared in I.
        • -
        • Within this list, put +
        • Within this list, put the fields in the order returned by .
        • -
        • Assign the fields in this list indices - n, n+1, ..., in order, where n +
        • Assign the fields in this list indices + n, n+1, ..., in order, where n is the count of the fields in all the superinterfaces of I.
        @@ -3518,7 +3522,7 @@ class C2 extends C1 implements I2 { Assume that called on C1 returns the fields of C1 in the - order: a, b; and that the fields of C2 are + order: a, b; and that the fields of C2 are returned in the order: q, r. An instance of class C1 will have the following field indices: @@ -3565,7 +3569,7 @@ class C2 extends C1 implements I2 { The count of the fields in the interfaces implemented by C2 is three (n=3): p of I0, - x of I1 and y of I2 + x of I1 and y of I2 (an interface of C2). Note that the field p of I0 is only included once. @@ -3607,7 +3611,7 @@ class C2 extends C1 implements I2 { The class C2 will have the same field indices. Note that a field may have a different index depending on the object that is viewing it -- for example field "a" above. - Note also: not all field indices may be visible from the + Note also: not all field indices may be visible from the callbacks, but all indices are shown for illustrative purposes.

        The interface I1 will have the @@ -3627,46 +3631,46 @@ class C2 extends C1 implements I2 {

  • - + - - Reference information returned for + Reference information returned for references. - + The array index. - - Reference information returned for + Reference information returned for references. - - The index into the constant pool of the class. See the description in + + The index into the constant pool of the class. See the description in . - - Reference information returned for + Reference information returned for references. @@ -3684,7 +3688,7 @@ class C2 extends C1 implements I2 { - The depth of the frame. + The depth of the frame. @@ -3707,11 +3711,11 @@ class C2 extends C1 implements I2 { - - Reference information returned for + Reference information returned for references. @@ -3729,7 +3733,7 @@ class C2 extends C1 implements I2 { - The depth of the frame. + The depth of the frame. @@ -3740,8 +3744,8 @@ class C2 extends C1 implements I2 { - Reference information returned for other references. @@ -3796,8 +3800,8 @@ class C2 extends C1 implements I2 { - The information returned about referrers. @@ -3805,50 +3809,50 @@ class C2 extends C1 implements I2 { jvmtiHeapReferenceInfoField - - The referrer information for - + + The referrer information for + and references. jvmtiHeapReferenceInfoArray - - The referrer information for + + The referrer information for For references. jvmtiHeapReferenceInfoConstantPool - - The referrer information for + + The referrer information for For references. jvmtiHeapReferenceInfoStackLocal - - The referrer information for + + The referrer information for For references. jvmtiHeapReferenceInfoJniLocal - - The referrer information for + + The referrer information for For references. jvmtiHeapReferenceInfoReserved - + reserved for future use. - @@ -3856,22 +3860,22 @@ class C2 extends C1 implements I2 { The callback to be called to describe an - object in the heap. Used by the + object in the heap. Used by the function, ignored by the function. - + jvmtiHeapReferenceCallback The callback to be called to describe an - object reference. Used by the + object reference. Used by the function, ignored by the function. - + jvmtiPrimitiveFieldCallback @@ -3880,7 +3884,7 @@ class C2 extends C1 implements I2 { The callback to be called to describe a primitive field. - + jvmtiArrayPrimitiveValueCallback @@ -3889,7 +3893,7 @@ class C2 extends C1 implements I2 { The callback to be called to describe an array of primitive values. - + jvmtiStringPrimitiveValueCallback @@ -3897,7 +3901,7 @@ class C2 extends C1 implements I2 { The callback to be called to describe a String value. - + jvmtiReservedCallback @@ -3905,7 +3909,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3913,7 +3917,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3921,7 +3925,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3929,7 +3933,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3937,7 +3941,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3945,7 +3949,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3953,7 +3957,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3961,7 +3965,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3969,7 +3973,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3977,7 +3981,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + jvmtiReservedCallback @@ -3985,7 +3989,7 @@ class C2 extends C1 implements I2 { Reserved for future use.. - + @@ -4029,10 +4033,10 @@ class C2 extends C1 implements I2 { - The tag of the class of object (zero if the class is not tagged). - If the object represents a runtime class, - the class_tag is the tag - associated with java.lang.Class + The tag of the class of object (zero if the class is not tagged). + If the object represents a runtime class, + the class_tag is the tag + associated with java.lang.Class (zero if java.lang.Class is not tagged). @@ -4047,7 +4051,7 @@ class C2 extends C1 implements I2 { The object tag value, or zero if the object is not tagged. To set the tag value to be associated with the object - the agent sets the jlong pointed to by the parameter. + the agent sets the jlong pointed to by the parameter. @@ -4059,17 +4063,17 @@ class C2 extends C1 implements I2 { - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. - + Heap Reference Callback - Agent supplied callback function. + Agent supplied callback function. Describes a reference from an object or the VM (the referrer) to another object (the referree) or a heap root to a referree.

    @@ -4093,12 +4097,12 @@ class C2 extends C1 implements I2 { jvmtiHeapReferenceInfo - Details about the reference. + Details about the reference. Set when the reference_kind is , , , - , + , , or . Otherwise NULL. @@ -4107,9 +4111,9 @@ class C2 extends C1 implements I2 { - The tag of the class of referree object (zero if the class is not tagged). - If the referree object represents a runtime class, - the class_tag is the tag + The tag of the class of referree object (zero if the class is not tagged). + If the referree object represents a runtime class, + the class_tag is the tag associated with java.lang.Class (zero if java.lang.Class is not tagged). @@ -4127,14 +4131,14 @@ class C2 extends C1 implements I2 { - Size of the referree object (in bytes). + Size of the referree object (in bytes). See . - Points to the referree object tag value, or zero if the object is not + Points to the referree object tag value, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -4143,14 +4147,14 @@ class C2 extends C1 implements I2 { - Points to the tag of the referrer object, or + Points to the tag of the referrer object, or points to the zero if the referrer - object is not tagged. + object is not tagged. NULL if the referrer in not an object (that is, this callback is reporting a heap root). To set the tag value to be associated with the referrer object the agent sets the jlong pointed to by the parameter. - If this callback is reporting a reference from an object to itself, + If this callback is reporting a reference from an object to itself, referrer_tag_ptr == tag_ptr. @@ -4163,7 +4167,7 @@ class C2 extends C1 implements I2 { - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -4173,7 +4177,7 @@ class C2 extends C1 implements I2 { Primitive Field Callback - Agent supplied callback function which + Agent supplied callback function which describes a primitive field of an object (the object). A primitive field is a field whose type is a primitive type. This callback will describe a static field if the object is a class, @@ -4191,7 +4195,7 @@ class C2 extends C1 implements I2 { jvmtiHeapReferenceKind - The kind of field -- instance or static ( or + The kind of field -- instance or static ( or ). @@ -4206,17 +4210,17 @@ class C2 extends C1 implements I2 { - The tag of the class of the object (zero if the class is not tagged). - If the object represents a runtime class, the - object_class_tag is the tag - associated with java.lang.Class + The tag of the class of the object (zero if the class is not tagged). + If the object represents a runtime class, the + object_class_tag is the tag + associated with java.lang.Class (zero if java.lang.Class is not tagged). - Points to the tag of the object, or zero if the object is not + Points to the tag of the object, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -4237,7 +4241,7 @@ class C2 extends C1 implements I2 { - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -4247,7 +4251,7 @@ class C2 extends C1 implements I2 { Array Primitive Value Callback - Agent supplied callback function. + Agent supplied callback function. Describes the values in an array of a primitive type.

    This function should return a bit vector of the desired @@ -4262,20 +4266,20 @@ class C2 extends C1 implements I2 { - The tag of the class of the array object (zero if the class is not tagged). + The tag of the class of the array object (zero if the class is not tagged). - Size of the array (in bytes). + Size of the array (in bytes). See . - Points to the tag of the array object, or zero if the object is not + Points to the tag of the array object, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -4303,7 +4307,7 @@ class C2 extends C1 implements I2 { - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -4313,7 +4317,7 @@ class C2 extends C1 implements I2 { String Primitive Value Callback - Agent supplied callback function. + Agent supplied callback function. Describes the value of a java.lang.String.

    This function should return a bit vector of the desired @@ -4328,21 +4332,21 @@ class C2 extends C1 implements I2 { - The tag of the class of the String class (zero if the class is not tagged). + The tag of the class of the String class (zero if the class is not tagged). Is this needed? - Size of the string (in bytes). + Size of the string (in bytes). See . - Points to the tag of the String object, or zero if the object is not + Points to the tag of the String object, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -4357,15 +4361,15 @@ class C2 extends C1 implements I2 { - The length of the string. - The length is equal to the number of 16-bit Unicode + The length of the string. + The length is equal to the number of 16-bit Unicode characters in the string. - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -4384,27 +4388,27 @@ class C2 extends C1 implements I2 { Follow References - - This function initiates a traversal over the objects that are + + This function initiates a traversal over the objects that are directly and indirectly reachable from the specified object or, - if initial_object is not specified, all objects + if initial_object is not specified, all objects reachable from the heap roots. - The heap root are the set of system classes, - JNI globals, references from thread stacks, and other objects used as roots - for the purposes of garbage collection. + The heap root are the set of system classes, + JNI globals, references from thread stacks, and other objects used as roots + for the purposes of garbage collection.

    This function operates by traversing the reference graph. Let A, B, ... represent objects. When a reference from A to B is traversed, - when a reference from a heap root to B is traversed, - or when B is specified as the , + when a reference from a heap root to B is traversed, + or when B is specified as the , then B is said to be visited. - A reference from A to B is not traversed until A + A reference from A to B is not traversed until A is visited. References are reported in the same order that the references are traversed. - Object references are reported by invoking the agent supplied + Object references are reported by invoking the agent supplied callback function . - In a reference from A to B, A is known + In a reference from A to B, A is known as the referrer and B as the referree. The callback is invoked exactly once for each reference from a referrer; this is true even if there are reference cycles or multiple paths to @@ -4412,10 +4416,10 @@ class C2 extends C1 implements I2 { There may be more than one reference between a referrer and a referree, each reference is reported. These references may be distinguished by examining the - reference_kind and - reference_info parameters of the callback.

    @@ -4452,10 +4456,10 @@ class C2 extends C1 implements I2 { whether the callback will be invoked, it does not influence which objects are visited nor does it influence whether other callbacks will be invoked. - However, the + However, the visit control flags returned by - do determine if the objects referenced by the + do determine if the objects referenced by the current object as visited. The heap filter flags and provided as parameters to this function @@ -4464,7 +4468,7 @@ class C2 extends C1 implements I2 { For example, if the only callback that was set is and klass is set to the array of bytes class, then only arrays of byte will be - reported. + reported. The table below summarizes this:

    @@ -4543,22 +4547,22 @@ class C2 extends C1 implements I2 {

    During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new - + - This bit vector of + This bit vector of heap filter flags. restricts the objects for which the callback function is called. This applies to both the object and primitive callbacks. @@ -4571,7 +4575,7 @@ class C2 extends C1 implements I2 { class - Callbacks are only reported when the object is an instance of + Callbacks are only reported when the object is an instance of this class. Objects which are instances of a subclass of klass are not reported. @@ -4595,14 +4599,14 @@ class C2 extends C1 implements I2 { Structure defining the set of callback functions. - + NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -4619,12 +4623,12 @@ class C2 extends C1 implements I2 { Iterate Through Heap - - Initiate an iteration over all objects in the heap. - This includes both reachable and + + Initiate an iteration over all objects in the heap. + This includes both reachable and unreachable objects. Objects are visited in no particular order.

    - Heap objects are reported by invoking the agent supplied + Heap objects are reported by invoking the agent supplied callback function . References between objects are not reported. If only reachable objects are desired, or if object reference information @@ -4638,7 +4642,7 @@ class C2 extends C1 implements I2 { . A primitive field is reported after the object with that field is visited; - it is reported by invoking the agent supplied + it is reported by invoking the agent supplied callback function .

    @@ -4656,7 +4660,7 @@ class C2 extends C1 implements I2 { For example, if the only callback that was set is and klass is set to the array of bytes class, then only arrays of byte will be - reported. The table below summarizes this (contrast this with + reported. The table below summarizes this (contrast this with ):

    @@ -4735,11 +4739,11 @@ class C2 extends C1 implements I2 {

    During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new @@ -4750,7 +4754,7 @@ class C2 extends C1 implements I2 { - This bit vector of + This bit vector of heap filter flags. restricts the objects for which the callback function is called. This applies to both the object and primitive callbacks. @@ -4762,7 +4766,7 @@ class C2 extends C1 implements I2 { callbacks are not limited to instances of a particular class - Callbacks are only reported when the object is an instance of + Callbacks are only reported when the object is an instance of this class. Objects which are instances of a subclass of klass are not reported. @@ -4777,14 +4781,14 @@ class C2 extends C1 implements I2 { Structure defining the set callback functions. - + NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -4799,7 +4803,7 @@ class C2 extends C1 implements I2 { Get Tag Retrieve the tag associated with an object. - The tag is a long value typically used to store a + The tag is a long value typically used to store a unique identifier or pointer to object information. The tag is set with . @@ -4820,7 +4824,7 @@ class C2 extends C1 implements I2 { - On return, the referenced long is set to the value + On return, the referenced long is set to the value of the tag. @@ -4833,7 +4837,7 @@ class C2 extends C1 implements I2 { Set Tag Set the tag associated with an object. - The tag is a long value typically used to store a + The tag is a long value typically used to store a unique identifier or pointer to object information. The tag is visible with . @@ -4891,7 +4895,7 @@ class C2 extends C1 implements I2 { - Return the number of objects with any of the tags + Return the number of objects with any of the tags in . @@ -4901,7 +4905,7 @@ class C2 extends C1 implements I2 { this information is not returned - Returns the array of objects with any of the tags + Returns the array of objects with any of the tags in . @@ -4932,13 +4936,13 @@ class C2 extends C1 implements I2 { This function does not return until the garbage collection is finished.

    - Although garbage collection is as complete - as possible there is no guarantee that all + Although garbage collection is as complete + as possible there is no guarantee that all - events will have been - sent by the time that this function - returns. In particular, an object may be - prevented from being freed because it + events will have been + sent by the time that this function + returns. In particular, an object may be + prevented from being freed because it is awaiting finalization. new @@ -4956,7 +4960,7 @@ class C2 extends C1 implements I2 { - These functions and data types were introduced in the original + These functions and data types were introduced in the original version 1.0 and have been superseded by more powerful and flexible versions @@ -4966,7 +4970,7 @@ class C2 extends C1 implements I2 {

    • - Allow access to primitive values (the value of Strings, arrays, + Allow access to primitive values (the value of Strings, arrays, and primitive fields)
    • @@ -5030,13 +5034,13 @@ class C2 extends C1 implements I2 { Reference from an object to its class. - + Reference from an object to the value of one of its instance fields. For references of this kind the referrer_index parameter to the jvmtiObjectReferenceCallback is the index of the - the instance field. The index is based on the order of all the + the instance field. The index is based on the order of all the object's fields. This includes all fields of the directly declared static and instance fields in the class, and includes all fields (both public and private) fields declared in superclasses and superinterfaces. @@ -5059,7 +5063,7 @@ class C2 extends C1 implements I2 { Reference from a class to its protection domain. - + Reference from a class to one of its interfaces. @@ -5068,7 +5072,7 @@ class C2 extends C1 implements I2 { For references of this kind the referrer_index parameter to the jvmtiObjectReferenceCallback is the index of the - the static field. The index is based on the order of all the + the static field. The index is based on the order of all the object's fields. This includes all fields of the directly declared static and instance fields in the class, and includes all fields (both public and private) fields declared in superclasses and superinterfaces. @@ -5091,11 +5095,11 @@ class C2 extends C1 implements I2 { - Continue the iteration. + Continue the iteration. If this is a reference iteration, follow the references of this object. - + - Continue the iteration. + Continue the iteration. If this is a reference iteration, ignore the references of this object. @@ -5121,9 +5125,9 @@ class C2 extends C1 implements I2 { - The tag of the class of object (zero if the class is not tagged). - If the object represents a runtime class, - the class_tag is the tag + The tag of the class of object (zero if the class is not tagged). + If the object represents a runtime class, + the class_tag is the tag associated with java.lang.Class (zero if java.lang.Class is not tagged). @@ -5134,60 +5138,6 @@ class C2 extends C1 implements I2 { Size of the object (in bytes). See . - - - - The object tag value, or zero if the object is not tagged. - To set the tag value to be associated with the object - the agent sets the jlong pointed to by the parameter. - - - - - - The user supplied data that was passed into the iteration function. - - - - - - - jvmtiIterationControl - Heap Root Object Callback - - Agent supplied callback function. - Describes (but does not pass in) an object that is a root for the purposes - of garbage collection. -

      - Return value should be JVMTI_ITERATION_CONTINUE to continue iteration, - JVMTI_ITERATION_IGNORE to continue iteration without pursuing - references from referree object or JVMTI_ITERATION_ABORT to stop iteration. -

      - See the heap callback - function restrictions. - - - - jvmtiHeapRootKind - - The kind of heap root. - - - - - - The tag of the class of object (zero if the class is not tagged). - If the object represents a runtime class, the class_tag is the tag - associated with java.lang.Class - (zero if java.lang.Class is not tagged). - - - - - - Size of the object (in bytes). See . - - @@ -5199,22 +5149,76 @@ class C2 extends C1 implements I2 { - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. - + + + + jvmtiIterationControl + Heap Root Object Callback + + Agent supplied callback function. + Describes (but does not pass in) an object that is a root for the purposes + of garbage collection. +

      + Return value should be JVMTI_ITERATION_CONTINUE to continue iteration, + JVMTI_ITERATION_IGNORE to continue iteration without pursuing + references from referree object or JVMTI_ITERATION_ABORT to stop iteration. +

      + See the heap callback + function restrictions. + + + + jvmtiHeapRootKind + + The kind of heap root. + + + + + + The tag of the class of object (zero if the class is not tagged). + If the object represents a runtime class, the class_tag is the tag + associated with java.lang.Class + (zero if java.lang.Class is not tagged). + + + + + + Size of the object (in bytes). See . + + + + + + The object tag value, or zero if the object is not tagged. + To set the tag value to be associated with the object + the agent sets the jlong pointed to by the parameter. + + + + + + The user supplied data that was passed into the iteration function. + + + + jvmtiIterationControl Stack Reference Object Callback Agent supplied callback function. - Describes (but does not pass in) an object on the stack that is a root for + Describes (but does not pass in) an object on the stack that is a root for the purposes of garbage collection.

      Return value should be JVMTI_ITERATION_CONTINUE to continue iteration, - JVMTI_ITERATION_IGNORE to continue iteration without pursuing + JVMTI_ITERATION_IGNORE to continue iteration without pursuing references from referree object or JVMTI_ITERATION_ABORT to stop iteration.

      See the heap callback @@ -5231,9 +5235,9 @@ class C2 extends C1 implements I2 { - The tag of the class of object (zero if the class is not tagged). - If the object represents a runtime class, the class_tag is the tag - associated with java.lang.Class + The tag of the class of object (zero if the class is not tagged). + If the object represents a runtime class, the class_tag is the tag + associated with java.lang.Class (zero if java.lang.Class is not tagged). @@ -5260,7 +5264,7 @@ class C2 extends C1 implements I2 { - The depth of the frame. + The depth of the frame. @@ -5278,7 +5282,7 @@ class C2 extends C1 implements I2 { - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -5288,12 +5292,12 @@ class C2 extends C1 implements I2 { jvmtiIterationControl Object Reference Callback - Agent supplied callback function. + Agent supplied callback function. Describes a reference from an object (the referrer) to another object (the referree).

      Return value should be JVMTI_ITERATION_CONTINUE to continue iteration, - JVMTI_ITERATION_IGNORE to continue iteration without pursuing + JVMTI_ITERATION_IGNORE to continue iteration without pursuing references from referree object or JVMTI_ITERATION_ABORT to stop iteration.

      See the heap callback @@ -5309,24 +5313,24 @@ class C2 extends C1 implements I2 { - The tag of the class of referree object (zero if the class is not tagged). + The tag of the class of referree object (zero if the class is not tagged). If the referree object represents a runtime class, - the class_tag is the tag - associated with java.lang.Class + the class_tag is the tag + associated with java.lang.Class (zero if java.lang.Class is not tagged). - Size of the referree object (in bytes). + Size of the referree object (in bytes). See . - The referree object tag value, or zero if the object is not + The referree object tag value, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -5341,11 +5345,11 @@ class C2 extends C1 implements I2 { - + For references of type JVMTI_REFERENCE_FIELD or JVMTI_REFERENCE_STATIC_FIELD the index - of the field in the referrer object. The index is based on the - order of all the object's fields - see JVMTI_REFERENCE_FIELD or JVMTI_REFERENCE_STATIC_FIELD @@ -5358,7 +5362,7 @@ class C2 extends C1 implements I2 { For references of type JVMTI_REFERENCE_CONSTANT_POOL the index into the constant pool of the class - see - JVMTI_REFERENCE_CONSTANT_POOL for further + JVMTI_REFERENCE_CONSTANT_POOL for further description.

      For references of other kinds the referrer_index is @@ -5368,7 +5372,7 @@ class C2 extends C1 implements I2 { - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -5376,17 +5380,17 @@ class C2 extends C1 implements I2 { Iterate Over Objects Reachable From Object - + This function iterates over all objects that are directly and indirectly reachable from the specified object. For each object A (known - as the referrer) with a reference to object B the specified + as the referrer) with a reference to object B the specified callback function is called to describe the object reference. The callback is called exactly once for each reference from a referrer; this is true even if there are reference cycles or multiple paths to the referrer. There may be more than one reference between a referrer and a referree, - These may be distinguished by the + These may be distinguished by the and . The callback for an object will always occur after the callback for @@ -5397,18 +5401,18 @@ class C2 extends C1 implements I2 {

      During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new - + @@ -5423,14 +5427,14 @@ class C2 extends C1 implements I2 { The callback to be called to describe each object reference. - + NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -5443,9 +5447,9 @@ class C2 extends C1 implements I2 { This function iterates over the root objects and all objects that are directly and indirectly reachable from the root objects. - The root objects comprise the set of system classes, - JNI globals, references from thread stacks, and other objects used as roots - for the purposes of garbage collection. + The root objects comprise the set of system classes, + JNI globals, references from thread stacks, and other objects used as roots + for the purposes of garbage collection.

      For each root the or callback is called. @@ -5458,7 +5462,7 @@ class C2 extends C1 implements I2 { this is true even if there are reference cycles or multiple paths to the referrer. There may be more than one reference between a referrer and a referree, - These may be distinguished by the + These may be distinguished by the and . The callback for an object will always occur after the callback for @@ -5468,26 +5472,26 @@ class C2 extends C1 implements I2 { references which are reported.

      Roots are always reported to the profiler before any object references - are reported. In other words, the + are reported. In other words, the callback will not be called until the appropriate callback has been called - for all roots. If the callback is + for all roots. If the callback is specified as NULL then this function returns after reporting the root objects to the profiler.

      During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new - + jvmtiHeapRootCallback @@ -5498,7 +5502,7 @@ class C2 extends C1 implements I2 { JVMTI_HEAP_ROOT_JNI_GLOBAL, JVMTI_HEAP_ROOT_SYSTEM_CLASS, JVMTI_HEAP_ROOT_MONITOR, - JVMTI_HEAP_ROOT_THREAD, or + JVMTI_HEAP_ROOT_THREAD, or JVMTI_HEAP_ROOT_OTHER. @@ -5528,7 +5532,7 @@ class C2 extends C1 implements I2 { NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -5538,14 +5542,14 @@ class C2 extends C1 implements I2 { Iterate Over Heap - - Iterate over all objects in the heap. This includes both reachable and + + Iterate over all objects in the heap. This includes both reachable and unreachable objects.

      The parameter indicates the objects for which the callback function is called. If this parameter - is JVMTI_HEAP_OBJECT_TAGGED then the callback will only be - called for every object that is tagged. If the parameter is + is JVMTI_HEAP_OBJECT_TAGGED then the callback will only be + called for every object that is tagged. If the parameter is JVMTI_HEAP_OBJECT_UNTAGGED then the callback will only be for objects that are not tagged. If the parameter is JVMTI_HEAP_OBJECT_EITHER then the callback will be @@ -5554,11 +5558,11 @@ class C2 extends C1 implements I2 {

      During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new @@ -5587,7 +5591,7 @@ class C2 extends C1 implements I2 { NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -5598,15 +5602,15 @@ class C2 extends C1 implements I2 { Iterate Over Instances Of Class - Iterate over all objects in the heap that are instances of the specified class. - This includes direct instances of the specified class and + Iterate over all objects in the heap that are instances of the specified class. + This includes direct instances of the specified class and instances of all subclasses of the specified class. This includes both reachable and unreachable objects.

      The parameter indicates the objects for which the callback function is called. If this parameter - is JVMTI_HEAP_OBJECT_TAGGED then the callback will only be - called for every object that is tagged. If the parameter is + is JVMTI_HEAP_OBJECT_TAGGED then the callback will only be + called for every object that is tagged. If the parameter is JVMTI_HEAP_OBJECT_UNTAGGED then the callback will only be called for objects that are not tagged. If the parameter is JVMTI_HEAP_OBJECT_EITHER then the callback will be @@ -5615,11 +5619,11 @@ class C2 extends C1 implements I2 {

      During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new @@ -5645,7 +5649,7 @@ class C2 extends C1 implements I2 { The iterator function to be called for each - instance matching + instance matching the . @@ -5655,7 +5659,7 @@ class C2 extends C1 implements I2 { NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -5668,19 +5672,19 @@ class C2 extends C1 implements I2 { - These functions are used to retrieve or set the value of a local variable. + These functions are used to retrieve or set the value of a local variable. The variable is identified by the depth of the frame containing its - value and the variable's slot number within that frame. - The mapping of variables to - slot numbers can be obtained with the function + value and the variable's slot number within that frame. + The mapping of variables to + slot numbers can be obtained with the function . Get Local Variable - Object - This function can be used to retrieve the value of a local - variable whose type is Object or a subclass of Object. + This function can be used to retrieve the value of a local + variable whose type is Object or a subclass of Object. jvmdi @@ -5708,7 +5712,7 @@ class C2 extends C1 implements I2 { - On return, points to the variable's value. + On return, points to the variable's value. @@ -5716,11 +5720,11 @@ class C2 extends C1 implements I2 { Invalid slot. - + The variable type is not Object or a subclass of Object. - + Not a visible frame @@ -5732,7 +5736,7 @@ class C2 extends C1 implements I2 { This function can be used to retrieve the value of the local object variable at slot 0 (the "this" object) from non-static frames. This function can retrieve the "this" object from - native method frames, whereas GetLocalObject() would + native method frames, whereas GetLocalObject() would return JVMTI_ERROR_OPAQUE_FRAME in those cases. new @@ -5755,7 +5759,7 @@ class C2 extends C1 implements I2 { - On return, points to the variable's value. + On return, points to the variable's value. @@ -5768,10 +5772,10 @@ class C2 extends C1 implements I2 { Get Local Variable - Int - This function can be used to retrieve the value of a local + This function can be used to retrieve the value of a local variable whose type is int, - short, char, byte, or - boolean. + short, char, byte, or + boolean. jvmdi @@ -5799,7 +5803,7 @@ class C2 extends C1 implements I2 { - On return, points to the variable's value. + On return, points to the variable's value. @@ -5807,13 +5811,13 @@ class C2 extends C1 implements I2 { Invalid slot. - - The variable type is not + + The variable type is not int, short, - char, byte, or + char, byte, or boolean. - + Not a visible frame @@ -5822,8 +5826,8 @@ class C2 extends C1 implements I2 { Get Local Variable - Long - This function can be used to retrieve the value of a local - variable whose type is long. + This function can be used to retrieve the value of a local + variable whose type is long. jvmdi @@ -5851,7 +5855,7 @@ class C2 extends C1 implements I2 { - On return, points to the variable's value. + On return, points to the variable's value. @@ -5859,10 +5863,10 @@ class C2 extends C1 implements I2 { Invalid slot. - + The variable type is not long. - + Not a visible frame @@ -5871,8 +5875,8 @@ class C2 extends C1 implements I2 { Get Local Variable - Float - This function can be used to retrieve the value of a local - variable whose type is float. + This function can be used to retrieve the value of a local + variable whose type is float. jvmdi @@ -5900,7 +5904,7 @@ class C2 extends C1 implements I2 { - On return, points to the variable's value. + On return, points to the variable's value. @@ -5908,10 +5912,10 @@ class C2 extends C1 implements I2 { Invalid slot. - + The variable type is not float. - + Not a visible frame @@ -5920,8 +5924,8 @@ class C2 extends C1 implements I2 { Get Local Variable - Double - This function can be used to retrieve the value of a local - variable whose type is long. + This function can be used to retrieve the value of a local + variable whose type is long. jvmdi @@ -5949,7 +5953,7 @@ class C2 extends C1 implements I2 { - On return, points to the variable's value. + On return, points to the variable's value. @@ -5957,10 +5961,10 @@ class C2 extends C1 implements I2 { Invalid slot. - + The variable type is not double. - + Not a visible frame @@ -5969,8 +5973,8 @@ class C2 extends C1 implements I2 { Set Local Variable - Object - This function can be used to set the value of a local - variable whose type is Object or a subclass of Object. + This function can be used to set the value of a local + variable whose type is Object or a subclass of Object. jvmdi @@ -6011,7 +6015,7 @@ class C2 extends C1 implements I2 { Object or a subclass of Object. - The supplied is not compatible + The supplied is not compatible with the variable type. @@ -6023,10 +6027,10 @@ class C2 extends C1 implements I2 { Set Local Variable - Int - This function can be used to set the value of a local + This function can be used to set the value of a local variable whose type is int, - short, char, byte, or - boolean. + short, char, byte, or + boolean. jvmdi @@ -6062,10 +6066,10 @@ class C2 extends C1 implements I2 { Invalid slot. - - The variable type is not + + The variable type is not int, short, - char, byte, or + char, byte, or boolean. @@ -6077,8 +6081,8 @@ class C2 extends C1 implements I2 { Set Local Variable - Long - This function can be used to set the value of a local - variable whose type is long. + This function can be used to set the value of a local + variable whose type is long. jvmdi @@ -6114,7 +6118,7 @@ class C2 extends C1 implements I2 { Invalid slot. - + The variable type is not long. @@ -6126,8 +6130,8 @@ class C2 extends C1 implements I2 { Set Local Variable - Float - This function can be used to set the value of a local - variable whose type is float. + This function can be used to set the value of a local + variable whose type is float. jvmdi @@ -6163,7 +6167,7 @@ class C2 extends C1 implements I2 { Invalid slot. - + The variable type is not float. @@ -6175,8 +6179,8 @@ class C2 extends C1 implements I2 { Set Local Variable - Double - This function can be used to set the value of a local - variable whose type is double. + This function can be used to set the value of a local + variable whose type is double. jvmdi @@ -6212,7 +6216,7 @@ class C2 extends C1 implements I2 { Invalid slot. - + The variable type is not double. @@ -6263,7 +6267,7 @@ class C2 extends C1 implements I2 { - + The designated bytecode already has a breakpoint. @@ -6300,7 +6304,7 @@ class C2 extends C1 implements I2 { - + There's no breakpoint at the designated bytecode. @@ -6321,14 +6325,14 @@ class C2 extends C1 implements I2 { by klass and field is about to be accessed. An event will be generated for each access of the field - until it is canceled with + until it is canceled with . Field accesses from Java programming language code or from JNI code are watched, fields modified by other means are not watched. Note that users should be aware that their own field accesses will trigger the watch. A field can only have one field access watch set. - Modification of a field is not considered an access--use + Modification of a field is not considered an access--use to monitor modifications. @@ -6352,7 +6356,7 @@ class C2 extends C1 implements I2 { - + The designated field is already being watched for accesses. @@ -6361,8 +6365,8 @@ class C2 extends C1 implements I2 { Clear Field Access Watch - Cancel a field access watch previously set by - , on the + Cancel a field access watch previously set by + , on the field specified by klass and field. @@ -6387,7 +6391,7 @@ class C2 extends C1 implements I2 { - + The designated field is not being watched for accesses. @@ -6401,7 +6405,7 @@ class C2 extends C1 implements I2 { by klass and field is about to be modified. An event will be generated for each modification of the field - until it is canceled with + until it is canceled with . Field modifications from Java programming language code or from JNI code are watched, fields modified by other means are not watched. @@ -6429,7 +6433,7 @@ class C2 extends C1 implements I2 { - + The designated field is already being watched for modifications. @@ -6439,8 +6443,8 @@ class C2 extends C1 implements I2 { Clear Field Modification Watch - Cancel a field modification watch previously set by - , on the + Cancel a field modification watch previously set by + , on the field specified by klass and field. @@ -6465,7 +6469,7 @@ class C2 extends C1 implements I2 { - + The designated field is not being watched for modifications. @@ -6512,7 +6516,7 @@ class C2 extends C1 implements I2 { Get Named Module - Return the java.lang.reflect.Module object for a named + Return the java.lang.Module object for a named module defined to a class loader that contains a given package. The module is returned via module_ptr.

      @@ -6550,7 +6554,7 @@ class C2 extends C1 implements I2 { - On return, points to a java.lang.reflect.Module object + On return, points to a java.lang.Module object or points to NULL. @@ -6595,6 +6599,10 @@ class C2 extends C1 implements I2 { If is not a module object. + + if the module cannot be modified. + See . + @@ -6629,7 +6637,7 @@ class C2 extends C1 implements I2 { The module the package is exported to. If the to_module is not a subclass of - java.lang.reflect.Module this function returns + java.lang.Module this function returns . @@ -6645,6 +6653,10 @@ class C2 extends C1 implements I2 { If the package does not belong to the module. + + if the module cannot be modified. + See . + @@ -6680,7 +6692,7 @@ class C2 extends C1 implements I2 { The module with the package to open. If the to_module is not a subclass of - java.lang.reflect.Module this function returns + java.lang.Module this function returns . @@ -6696,6 +6708,10 @@ class C2 extends C1 implements I2 { If the package does not belong to the module. + + if the module cannot be modified. + See . + @@ -6733,6 +6749,10 @@ class C2 extends C1 implements I2 { If is not a class object. + + if the module cannot be modified. + See . + @@ -6779,6 +6799,46 @@ class C2 extends C1 implements I2 { If is not a class object. + + if the module cannot be modified. + See . + + + + + + Is Modifiable Module + + Determines whether a module is modifiable. + If a module is modifiable then this module can be updated with + , , + , , + and . If a module is not modifiable + then the module can not be updated with these functions. The result of + this function is always JNI_TRUE when called to determine + if an unnamed module is modifiable. + + new + + + + + + + The module to query. + + + + + + On return, points to the boolean result of this function. + + + + + + If is not a module object. + @@ -6797,9 +6857,9 @@ class C2 extends C1 implements I2 { class_count_ptr, and the array itself via classes_ptr.

      - Array classes of all types (including arrays of primitive types) are - included in the returned list. Primitive classes (for example, - java.lang.Integer.TYPE) are not included in this list. + Array classes of all types (including arrays of primitive types) are + included in the returned list. Primitive classes (for example, + java.lang.Integer.TYPE) are not included in this list. jvmdi @@ -6827,8 +6887,8 @@ class C2 extends C1 implements I2 { Get Classloader Classes Returns an array of those classes for which this class loader has - been recorded as an initiating loader. Each - class in the returned array was created by this class loader, + been recorded as an initiating loader. Each + class in the returned array was created by this class loader, either by defining it directly or by delegation to another class loader. See .

      @@ -6870,14 +6930,14 @@ class C2 extends C1 implements I2 { Get Class Signature - For the class indicated by klass, return the - JNI - type signature + For the class indicated by klass, return the + JNI + type signature and the generic signature of the class. For example, java.util.List is "Ljava/util/List;" and int[] is "[I" The returned name for primitive classes - is the type signature character of the corresponding primitive type. + is the type signature character of the corresponding primitive type. For example, java.lang.Integer.TYPE is "I". jvmdiClone @@ -6892,7 +6952,7 @@ class C2 extends C1 implements I2 { - + the signature is not returned @@ -6902,14 +6962,14 @@ class C2 extends C1 implements I2 { - + the generic signature is not returned On return, points to the generic signature of the class, encoded as a modified UTF-8 string. If there is no generic signature attribute for the class, then, - on return, points to NULL. + on return, points to NULL. @@ -6920,7 +6980,7 @@ class C2 extends C1 implements I2 { Get Class Status - Get the status of the class. Zero or more of the following bits can be + Get the status of the class. Zero or more of the following bits can be set. @@ -6939,7 +6999,7 @@ class C2 extends C1 implements I2 { Class is an array. If set, all other bits are zero. - Class is a primitive class (for example, java.lang.Integer.TYPE). + Class is a primitive class (for example, java.lang.Integer.TYPE). If set, all other bits are zero. @@ -6957,7 +7017,7 @@ class C2 extends C1 implements I2 { - On return, points to the current state of this class as one or + On return, points to the current state of this class as one or more of the class status flags. @@ -6970,11 +7030,11 @@ class C2 extends C1 implements I2 { Get Source File Name For the class indicated by klass, return the source file - name via source_name_ptr. The returned string - is a file name only and never contains a directory name. + name via source_name_ptr. The returned string + is a file name only and never contains a directory name.

      - For primitive classes (for example, java.lang.Integer.TYPE) - and for arrays this function returns + For primitive classes (for example, java.lang.Integer.TYPE) + and for arrays this function returns . jvmdi @@ -6997,7 +7057,7 @@ class C2 extends C1 implements I2 { - + Class information does not include a source file name. This includes cases where the class is an array class or primitive class. @@ -7012,17 +7072,17 @@ class C2 extends C1 implements I2 { via modifiers_ptr. Access flags are defined in .

      - If the class is an array class, then its public, private, and protected - modifiers are the same as those of its component type. For arrays of - primitives, this component type is represented by one of the primitive - classes (for example, java.lang.Integer.TYPE). + If the class is an array class, then its public, private, and protected + modifiers are the same as those of its component type. For arrays of + primitives, this component type is represented by one of the primitive + classes (for example, java.lang.Integer.TYPE).

      - If the class is a primitive class, its public modifier is always true, - and its protected and private modifiers are always false. + If the class is a primitive class, its public modifier is always true, + and its protected and private modifiers are always false.

      - If the class is an array class or a primitive class then its final - modifier is always true and its interface modifier is always false. - The values of its other modifiers are not determined by this specification. + If the class is an array class or a primitive class then its final + modifier is always true and its interface modifier is always false. + The values of its other modifiers are not determined by this specification. jvmdi @@ -7052,7 +7112,7 @@ class C2 extends C1 implements I2 { For the class indicated by klass, return a count of methods via method_count_ptr and a list of - method IDs via methods_ptr. The method list contains + method IDs via methods_ptr. The method list contains constructors and static initializers as well as true methods. Only directly declared methods are returned (not inherited methods). An empty method list is returned for array classes and primitive classes @@ -7125,7 +7185,7 @@ class C2 extends C1 implements I2 { - + is not prepared. @@ -7134,7 +7194,7 @@ class C2 extends C1 implements I2 { Get Implemented Interfaces - Return the direct super-interfaces of this class. For a class, this + Return the direct super-interfaces of this class. For a class, this function returns the interfaces declared in its implements clause. For an interface, this function returns the interfaces declared in its extends clause. @@ -7165,7 +7225,7 @@ class C2 extends C1 implements I2 { - + is not prepared. @@ -7174,10 +7234,10 @@ class C2 extends C1 implements I2 { Get Class Version Numbers - For the class indicated by klass, + For the class indicated by klass, return the minor and major version numbers, as defined in - . + . new @@ -7193,7 +7253,7 @@ class C2 extends C1 implements I2 { On return, points to the value of the - minor_version item of the + minor_version item of the Class File Format. Note: to be consistent with the Class File Format, the minor version number is the first parameter. @@ -7203,13 +7263,13 @@ class C2 extends C1 implements I2 { On return, points to the value of the - major_version item of the + major_version item of the Class File Format. - + The class is a primitive or array class. @@ -7218,13 +7278,13 @@ class C2 extends C1 implements I2 { Get Constant Pool - For the class indicated by klass, + For the class indicated by klass, return the raw bytes of the constant pool in the format of the - constant_pool item of + constant_pool item of . The format of the constant pool may differ between versions - of the Class File Format, so, the - minor and major + of the Class File Format, so, the + minor and major class version numbers should be checked for compatibility.

      @@ -7234,17 +7294,17 @@ class C2 extends C1 implements I2 { more or fewer entries than the defining constant pool. Entries may be in a different order. The constant pool returned by GetConstantPool() will match the - constant pool used by + constant pool used by GetBytecodes(). That is, the bytecodes returned by GetBytecodes() will have constant pool indices which refer to constant pool entries returned by GetConstantPool(). - Note that since - and can change + Note that since + and can change the constant pool, the constant pool returned by this function - can change accordingly. Thus, the correspondence between + can change accordingly. Thus, the correspondence between GetConstantPool() and GetBytecodes() does not hold if there - is an intervening class retransformation or redefinition. + is an intervening class retransformation or redefinition. The value of a constant pool entry used by a given bytecode will match that of the defining class file (even if the indices don't match). Constant pool entries which are not used directly or indirectly by @@ -7282,13 +7342,13 @@ class C2 extends C1 implements I2 { On return, points to the raw constant pool, that is the bytes - defined by the constant_pool item of the + defined by the constant_pool item of the Class File Format - + The class is a primitive or array class. @@ -7300,7 +7360,7 @@ class C2 extends C1 implements I2 { Determines whether a class object reference represents an interface. The jboolean result is JNI_TRUE if the "class" is actually an interface, - JNI_FALSE otherwise. + JNI_FALSE otherwise. jvmdi @@ -7330,7 +7390,7 @@ class C2 extends C1 implements I2 { Determines whether a class object reference represents an array. The jboolean result is JNI_TRUE if the class is an array, - JNI_FALSE otherwise. + JNI_FALSE otherwise. jvmdi @@ -7360,11 +7420,11 @@ class C2 extends C1 implements I2 { Determines whether a class is modifiable. If a class is modifiable ( returns JNI_TRUE) the class can be - redefined with (assuming + redefined with (assuming the agent possesses the capability) or - retransformed with (assuming + retransformed with (assuming the agent possesses the capability). @@ -7373,7 +7433,7 @@ class C2 extends C1 implements I2 { redefined nor retransformed.

      Primitive classes (for example, java.lang.Integer.TYPE), - array classes, and some implementation defined classes are never modifiable. + array classes, and some implementation defined classes are never modifiable.

      new @@ -7451,11 +7511,11 @@ class C2 extends C1 implements I2 { Get Source Debug Extension - For the class indicated by klass, return the debug + For the class indicated by klass, return the debug extension via source_debug_extension_ptr. - The returned string + The returned string contains exactly the debug extension information present in the - class file of klass. + class file of klass. jvmdi @@ -7477,7 +7537,7 @@ class C2 extends C1 implements I2 { - + Class information does not include a debug extension. @@ -7486,15 +7546,15 @@ class C2 extends C1 implements I2 { Retransform Classes - This function facilitates the + This function facilitates the bytecode instrumentation of already loaded classes. To replace the class definition without reference to the existing - bytecodes, as one might do when recompiling from source for + bytecodes, as one might do when recompiling from source for fix-and-continue debugging, function should be used instead.

      - When classes are initially loaded or when they are + When classes are initially loaded or when they are redefined, the initial class file bytes can be transformed with the event. @@ -7502,16 +7562,16 @@ class C2 extends C1 implements I2 { (whether or not a transformation has previously occurred). This retransformation follows these steps:

        -
      • starting from the initial class file bytes +
      • starting from the initial class file bytes
      • for each retransformation incapable agent which received a ClassFileLoadHook event during the previous - load or redefine, the bytes it returned + load or redefine, the bytes it returned (via the new_class_data parameter) - are reused as the output of the transformation; + are reused as the output of the transformation; note that this is equivalent to reapplying the previous transformation, unaltered. except that the ClassFileLoadHook event @@ -7529,7 +7589,7 @@ class C2 extends C1 implements I2 {
      See the event for more details.

      - The initial class file bytes represent the bytes passed to + The initial class file bytes represent the bytes passed to ClassLoader.defineClass or RedefineClasses (before any transformations were applied), however they may not exactly match them. @@ -7541,13 +7601,13 @@ class C2 extends C1 implements I2 { order may not be preserved.

      Retransformation can cause new versions of methods to be installed. - Old method versions may become + Old method versions may become obsolete - The new method version will be used on new invokes. + The new method version will be used on new invokes. If a method has active stack frames, those active frames continue to - run the bytecodes of the original method version. + run the bytecodes of the original method version.

      - This function does not cause any initialization except that which + This function does not cause any initialization except that which would occur under the customary JVM semantics. In other words, retransforming a class does not cause its initializers to be run. The values of static fields will remain as they were @@ -7560,7 +7620,7 @@ class C2 extends C1 implements I2 { All attributes are updated.

      Instances of the retransformed class are not affected -- fields retain their - previous values. + previous values. Tags on the instances are also unaffected.

      @@ -7569,8 +7629,8 @@ class C2 extends C1 implements I2 { will be sent.

      The retransformation may change method bodies, the constant pool and attributes. - The retransformation must not add, remove or rename fields or methods, change the - signatures of methods, change modifiers, or change inheritance. + The retransformation must not add, remove or rename fields or methods, change the + signatures of methods, change modifiers, or change inheritance. These restrictions may be lifted in future versions. See the error return description below for information on error codes returned if an unsupported retransformation is attempted. @@ -7580,7 +7640,7 @@ class C2 extends C1 implements I2 { If any error code is returned other than JVMTI_ERROR_NONE, none of the classes to be retransformed will have a new definition installed. When this function returns (with the error code of JVMTI_ERROR_NONE) - all of the classes to be retransformed will have their new definitions installed. + all of the classes to be retransformed will have their new definitions installed. new @@ -7603,7 +7663,7 @@ class C2 extends C1 implements I2 { - One of the cannot be modified. + One of the cannot be modified. See . @@ -7616,7 +7676,7 @@ class C2 extends C1 implements I2 { A retransformed class file is malformed (The VM would return a ClassFormatError). - The retransformed class file definitions would lead to a circular definition + The retransformed class file definitions would lead to a circular definition (the VM would return a ClassCircularityError). @@ -7679,22 +7739,22 @@ class C2 extends C1 implements I2 { This function is used to replace the definition of a class with a new definition, as might be needed in fix-and-continue debugging. - Where the existing class file bytes are to be transformed, for + Where the existing class file bytes are to be transformed, for example in bytecode instrumentation, should be used.

      Redefinition can cause new versions of methods to be installed. - Old method versions may become + Old method versions may become obsolete - The new method version will be used on new invokes. + The new method version will be used on new invokes. If a method has active stack frames, those active frames continue to - run the bytecodes of the original method version. - If resetting of stack frames is desired, use + run the bytecodes of the original method version. + If resetting of stack frames is desired, use to pop frames with obsolete method versions.

      - This function does not cause any initialization except that which + This function does not cause any initialization except that which would occur under the customary JVM semantics. In other words, redefining a class does not cause its initializers to be run. The values of static fields will remain as they were @@ -7707,7 +7767,7 @@ class C2 extends C1 implements I2 { All attributes are updated.

      Instances of the redefined class are not affected -- fields retain their - previous values. + previous values. Tags on the instances are also unaffected.

      @@ -7716,8 +7776,8 @@ class C2 extends C1 implements I2 { will be sent (if enabled), but no other events will be sent.

      The redefinition may change method bodies, the constant pool and attributes. - The redefinition must not add, remove or rename fields or methods, change the - signatures of methods, change modifiers, or change inheritance. + The redefinition must not add, remove or rename fields or methods, change the + signatures of methods, change modifiers, or change inheritance. These restrictions may be lifted in future versions. See the error return description below for information on error codes returned if an unsupported redefinition is attempted. @@ -7728,7 +7788,7 @@ class C2 extends C1 implements I2 { If any error code is returned other than JVMTI_ERROR_NONE, none of the classes to be redefined will have a new definition installed. When this function returns (with the error code of JVMTI_ERROR_NONE) - all of the classes to be redefined will have their new definitions installed. + all of the classes to be redefined will have their new definitions installed. jvmdi @@ -7767,7 +7827,7 @@ class C2 extends C1 implements I2 { A new class file is malformed (The VM would return a ClassFormatError). - The new class file definitions would lead to a circular definition + The new class file definitions would lead to a circular definition (the VM would return a ClassCircularityError). @@ -7799,6 +7859,10 @@ class C2 extends C1 implements I2 { A method in the new class version has different modifiers than its counterpart in the old class version. + + A module cannot be modified. + See . + @@ -7812,7 +7876,7 @@ class C2 extends C1 implements I2 { For the object indicated by object, return via size_ptr the size of the object. This size is an implementation-specific approximation of - the amount of storage consumed by this object. + the amount of storage consumed by this object. It may include some or all of the object's overhead, and thus is useful for comparison within an implementation but not between implementations. @@ -7845,11 +7909,11 @@ class C2 extends C1 implements I2 { For the object indicated by object, return via hash_code_ptr a hash code. This hash code could be used to maintain a hash table of object references, - however, on some implementations this can cause significant performance - impacts--in most cases - tags + however, on some implementations this can cause significant performance + impacts--in most cases + tags will be a more efficient means of associating information with objects. - This function guarantees + This function guarantees the same hash code value for a particular object throughout its life jvmdi @@ -7915,7 +7979,7 @@ class C2 extends C1 implements I2 { Get information about the object's monitor. - The fields of the structure + The fields of the structure are filled in with information about usage of the monitor. Decide and then clarify suspend requirements. @@ -7935,7 +7999,7 @@ class C2 extends C1 implements I2 { jvmtiMonitorUsage - On return, filled with monitor information for the + On return, filled with monitor information for the specified object. @@ -7950,7 +8014,7 @@ class C2 extends C1 implements I2 { Return the list of object monitors.

      - Note: details about each monitor can be examined with + Note: details about each monitor can be examined with . new @@ -7961,7 +8025,7 @@ class C2 extends C1 implements I2 { - On return, pointer to the number + On return, pointer to the number of monitors returned in monitors_ptr. @@ -7992,7 +8056,7 @@ class C2 extends C1 implements I2 { .

      Field signatures are defined in the - JNI Specification + JNI Specification and are referred to as field descriptors in . @@ -8034,14 +8098,14 @@ class C2 extends C1 implements I2 { - + the generic signature is not returned On return, points to the generic signature of the field, encoded as a modified UTF-8 string. If there is no generic signature attribute for the field, then, - on return, points to NULL. + on return, points to NULL. @@ -8123,7 +8187,7 @@ class C2 extends C1 implements I2 { For the field indicated by klass and field, return a value indicating whether the field is synthetic via is_synthetic_ptr. - Synthetic fields are generated by the compiler but not present in the + Synthetic fields are generated by the compiler but not present in the original source code. jvmdi @@ -8177,7 +8241,7 @@ class C2 extends C1 implements I2 { An original method version which is not equivalent to the new method version is called obsolete and is assigned a new method ID; the original method ID now refers to the new method version. - A method ID can be tested for obsolescence with + A method ID can be tested for obsolescence with . @@ -8189,8 +8253,8 @@ class C2 extends C1 implements I2 { signature_ptr.

      Method signatures are defined in the - JNI Specification - and are referred to as method descriptors in + JNI Specification + and are referred to as method descriptors in . Note this is different than method signatures as defined in the Java Language Specification. @@ -8227,14 +8291,14 @@ class C2 extends C1 implements I2 { - + the generic signature is not returned On return, points to the generic signature of the method, encoded as a modified UTF-8 string. If there is no generic signature attribute for the method, then, - on return, points to NULL. + on return, points to NULL. @@ -8315,7 +8379,7 @@ class C2 extends C1 implements I2 { For the method indicated by method, return the number of local variable slots used by the method, including the local variables used to pass parameters to the - method on its invocation. + method on its invocation.

      See max_locals in . @@ -8401,7 +8465,7 @@ class C2 extends C1 implements I2 { For the method indicated by method, return a table of source line number entries. The size of the table is returned via entry_count_ptr and the table itself is - returned via table_ptr. + returned via table_ptr. jvmdi @@ -8434,7 +8498,7 @@ class C2 extends C1 implements I2 { - + Class information does not include line numbers. @@ -8446,10 +8510,10 @@ class C2 extends C1 implements I2 { For the method indicated by method, return the beginning and ending addresses through start_location_ptr and end_location_ptr. In a - conventional byte code indexing scheme, + conventional byte code indexing scheme, start_location_ptr will always point to zero - and end_location_ptr - will always point to the byte code count minus one. + and end_location_ptr + will always point to the byte code count minus one. jvmdi @@ -8470,9 +8534,9 @@ class C2 extends C1 implements I2 { - On return, points to the first location, or + On return, points to the first location, or -1 if location information is not available. - If the information is available and + If the information is available and returns then this will always be zero. @@ -8487,7 +8551,7 @@ class C2 extends C1 implements I2 { - + Class information does not include method sizes. @@ -8507,7 +8571,7 @@ class C2 extends C1 implements I2 { The length of the valid section for this local variable. - The last code array index where the local variable is valid + The last code array index where the local variable is valid is start_location + length. @@ -8532,7 +8596,7 @@ class C2 extends C1 implements I2 { The local variable's generic signature, encoded as a modified UTF-8 string. - The value of this field will be NULL for any local + The value of this field will be NULL for any local variable which does not have a generic type. @@ -8658,7 +8722,7 @@ class C2 extends C1 implements I2 { For the method indicated by method, return a value indicating whether the method is synthetic via is_synthetic_ptr. - Synthetic methods are generated by the compiler but not present in the + Synthetic methods are generated by the compiler but not present in the original source code. jvmdi @@ -8729,7 +8793,7 @@ class C2 extends C1 implements I2 { This function modifies the failure handling of native method resolution by allowing retry with a prefix applied to the name. - When used with the + When used with the ClassFileLoadHook event, it enables native methods to be instrumented. @@ -8741,7 +8805,7 @@ class C2 extends C1 implements I2 { native boolean foo(int x);

      - We could transform the class file (with the + We could transform the class file (with the ClassFileLoadHook event) so that this becomes: boolean foo(int x) { @@ -8759,28 +8823,28 @@ native boolean wrapped_foo(int x); better but would make these examples less readable.

      The wrapper will allow data to be collected on the native - method call, but now the problem becomes linking up the - wrapped method with the native implementation. - That is, the method wrapped_foo needs to be + method call, but now the problem becomes linking up the + wrapped method with the native implementation. + That is, the method wrapped_foo needs to be resolved to the native implementation of foo, which might be: Java_somePackage_someClass_foo(JNIEnv* env, jint x)

      This function allows the prefix to be specified and the - proper resolution to occur. + proper resolution to occur. Specifically, when the standard resolution fails, the resolution is retried taking the prefix into consideration. There are two ways that resolution occurs, explicit resolution with the JNI function RegisterNatives - and the normal automatic resolution. For - RegisterNatives, the VM will attempt this + and the normal automatic resolution. For + RegisterNatives, the VM will attempt this association: method(foo) -> nativeImplementation(foo)

      When this fails, the resolution will be retried with - the specified prefix prepended to the method name, + the specified prefix prepended to the method name, yielding the correct resolution: method(wrapped_foo) -> nativeImplementation(foo) @@ -8790,7 +8854,7 @@ method(wrapped_foo) -> nativeImplementation(foo) method(wrapped_foo) -> nativeImplementation(wrapped_foo)

      When this fails, the resolution will be retried with - the specified prefix deleted from the implementation name, + the specified prefix deleted from the implementation name, yielding the correct resolution: method(wrapped_foo) -> nativeImplementation(foo) @@ -8799,7 +8863,7 @@ method(wrapped_foo) -> nativeImplementation(foo) resolution fails, native methods can be wrapped selectively.

      Since each environment is independent and - can do its own transformation of the bytecodes, more + can do its own transformation of the bytecodes, more than one layer of wrappers may be applied. Thus each environment needs its own prefix. Since transformations are applied in order, the prefixes, if applied, will @@ -8807,21 +8871,21 @@ method(wrapped_foo) -> nativeImplementation(foo) The order of transformation application is described in the event. Thus if three environments applied - wrappers, foo might become + wrappers, foo might become $env3_$env2_$env1_foo. But if, say, the second environment did not apply a wrapper to - foo it would be just - $env3_$env1_foo. To be able to + foo it would be just + $env3_$env1_foo. To be able to efficiently determine the sequence of prefixes, an intermediate prefix is only applied if its non-native - wrapper exists. Thus, in the last example, even though + wrapper exists. Thus, in the last example, even though $env1_foo is not a native method, the - $env1_ prefix is applied since + $env1_ prefix is applied since $env1_foo exists.

      Since the prefixes are used at resolution time and since resolution may be arbitrarily delayed, a - native method prefix must remain set as long as there + native method prefix must remain set as long as there are corresponding prefixed native methods. new @@ -8854,7 +8918,7 @@ method(wrapped_foo) -> nativeImplementation(foo) For a meta-agent that performs multiple independent class file transformations (for example as a proxy for another layer of agents) this function allows each transformation - to have its own prefix. + to have its own prefix. The prefixes are applied in the order supplied and are processed in the same manor as described for the application of prefixes from multiple environments @@ -8865,13 +8929,13 @@ method(wrapped_foo) -> nativeImplementation(foo) disables prefixing in this environment.

      and this function - are the two ways to set the prefixes. - Calling SetNativeMethodPrefix with - a prefix is the same as calling this function with - of 1. - Calling SetNativeMethodPrefix with - NULL is the same as calling this function with - of 0. + are the two ways to set the prefixes. + Calling SetNativeMethodPrefix with + a prefix is the same as calling this function with + of 1. + Calling SetNativeMethodPrefix with + NULL is the same as calling this function with + of 0. new @@ -8950,16 +9014,16 @@ method(wrapped_foo) -> nativeImplementation(foo) - + Not monitor owner - + Raw Monitor Enter - Gain exclusive ownership of a raw monitor. + Gain exclusive ownership of a raw monitor. The same thread may enter a monitor more then once. The thread must exit @@ -9000,7 +9064,7 @@ method(wrapped_foo) -> nativeImplementation(foo) - + Not monitor owner @@ -9011,9 +9075,9 @@ method(wrapped_foo) -> nativeImplementation(foo) Wait for notification of the raw monitor.

      - Causes the current thread to wait until either another thread calls - or - + Causes the current thread to wait until either another thread calls + or + for the specified raw monitor, or the specified timeout has elapsed. @@ -9038,10 +9102,10 @@ method(wrapped_foo) -> nativeImplementation(foo) - + Not monitor owner - + Wait was interrupted, try again @@ -9087,7 +9151,7 @@ method(wrapped_foo) -> nativeImplementation(foo) - + Not monitor owner @@ -9097,7 +9161,7 @@ method(wrapped_foo) -> nativeImplementation(foo) Get Raw Monitor Use - The fields of the structure + The fields of the structure are filled in with information about usage of the raw monitor. new @@ -9114,7 +9178,7 @@ method(wrapped_foo) -> nativeImplementation(foo) jvmtiMonitorUsage - On return, filled with monitor information for the + On return, filled with monitor information for the specified raw monitor. @@ -9128,7 +9192,7 @@ method(wrapped_foo) -> nativeImplementation(foo) Return the list of raw monitors.

      - Note: details about each monitor can be examined with + Note: details about each monitor can be examined with . new @@ -9139,7 +9203,7 @@ method(wrapped_foo) -> nativeImplementation(foo) - On return, pointer to the number + On return, pointer to the number of monitors returned in monitors_ptr. @@ -9159,13 +9223,13 @@ method(wrapped_foo) -> nativeImplementation(foo) - Provides the ability to intercept and resend + Provides the ability to intercept and resend Java Native Interface (JNI) function calls by manipulating the JNI function table. - See JNI + See JNI Functions in the Java Native Interface Specification.

      - The following example illustrates intercepting the + The following example illustrates intercepting the NewGlobalRef JNI call in order to count reference creation. @@ -9210,19 +9274,19 @@ myInit() { check that the example compiles and executes. - + Set JNI Function Table - Set the JNI function table + Set the JNI function table in all current and future JNI environments. As a result, all future JNI calls are directed to the specified functions. Use to get the function table to pass to this function. - For this function to take effect the the updated table entries must be + For this function to take effect the the updated table entries must be used by the JNI clients. Since the table is defined const some compilers may optimize - away the access to the table, thus preventing this function from taking + away the access to the table, thus preventing this function from taking effect. The table is copied--changes to the local copy of the table have no effect. @@ -9246,16 +9310,16 @@ myInit() { - + Get JNI Function Table Get the JNI function table. The JNI function table is copied into allocated memory. - If + If has been called, the modified (not the original) function table is returned. - Only the function table is copied, no other aspects of the environment + Only the function table is copied, no other aspects of the environment are copied. See the examples above. @@ -9268,7 +9332,7 @@ myInit() { jniNativeInterface - On return, *function_table + On return, *function_table points a newly allocated copy of the JNI function table. @@ -9290,13 +9354,13 @@ myInit() { table have no effect. This is an atomic action, all callbacks are set at once. No events are sent before this function is called. - When an entry is NULL or when the event is beyond + When an entry is NULL or when the event is beyond no event is sent. - Details on events are + Details on events are described later in this document. An event must be enabled and have a callback in order to be - sent--the order in which this function and - + sent--the order in which this function and + are called does not affect the result. new @@ -9327,28 +9391,28 @@ myInit() { Set Event Notification Mode - Control the generation of events. + Control the generation of events. - If is JVMTI_ENABLE, + If is JVMTI_ENABLE, the event will be enabled - If is JVMTI_DISABLE, + If is JVMTI_DISABLE, the event will be disabled If thread is NULL, - the event is enabled or disabled globally; otherwise, it is - enabled or disabled for a particular thread. - An event is generated for + the event is enabled or disabled globally; otherwise, it is + enabled or disabled for a particular thread. + An event is generated for a particular thread if it is enabled either at the thread or global - levels. + levels.

      See below for information on specific events.

      The following events cannot be controlled at the thread - level through this function. + level through this function.

      • @@ -9360,13 +9424,13 @@ myInit() {

      - Initially, no events are enabled at either the thread level + Initially, no events are enabled at either the thread level or the global level.

      Any needed capabilities (see Event Enabling Capabilities below) must be possessed before calling this function.

      - Details on events are + Details on events are described below. jvmdiClone @@ -9408,10 +9472,10 @@ myInit() { is non-NULL and is not live (has not been started or is now dead). - thread level control was attempted on events which do not + thread level control was attempted on events which do not permit thread level control. - + The Required Event Enabling Capability is not possessed. @@ -9420,14 +9484,14 @@ myInit() { Generate Events - Generate events to represent the current state of the VM. - For example, if is + Generate events to represent the current state of the VM. + For example, if is JVMTI_EVENT_COMPILED_METHOD_LOAD, a event will be sent for each currently compiled method. Methods that were loaded and now have been unloaded are not sent. - The history of what events have previously been sent does not - effect what events are sent by this function--for example, + The history of what events have previously been sent does not + effect what events are sent by this function--for example, all currently compiled methods will be sent each time this function is called.

      @@ -9438,14 +9502,14 @@ myInit() { Attempts to execute Java programming language code or JNI functions may be paused until this function returns - so neither should be called from the thread sending the event. - This function returns only after the missed events have been + This function returns only after the missed events have been sent, processed and have returned. The event may be sent on a different thread than the thread on which the event occurred. - The callback for the event must be set with - + The callback for the event must be set with + and the event must be enabled with - + or the events will not occur. If the VM no longer has the information to generate some or all of the requested events, the events are simply not sent - @@ -9474,13 +9538,13 @@ myInit() { - - is + + is JVMTI_EVENT_COMPILED_METHOD_LOAD and is false. - + is other than JVMTI_EVENT_COMPILED_METHOD_LOAD or JVMTI_EVENT_DYNAMIC_CODE_GENERATED. @@ -9502,63 +9566,63 @@ myInit() { - Java programming language primitive type - byte. + Java programming language primitive type - byte. JNI type jbyte. - Java programming language primitive type - char. + Java programming language primitive type - char. JNI type jchar. - Java programming language primitive type - short. + Java programming language primitive type - short. JNI type jshort. - Java programming language primitive type - int. + Java programming language primitive type - int. JNI type . - Java programming language primitive type - long. + Java programming language primitive type - long. JNI type . - Java programming language primitive type - float. + Java programming language primitive type - float. JNI type . - Java programming language primitive type - double. + Java programming language primitive type - double. JNI type . - Java programming language primitive type - boolean. + Java programming language primitive type - boolean. JNI type . - Java programming language object type - java.lang.Object. + Java programming language object type - java.lang.Object. JNI type . Returned values are JNI local references and must be managed. - Java programming language object type - java.lang.Thread. + Java programming language object type - java.lang.Thread. type . Returned values are JNI local references and must be managed. - Java programming language object type - java.lang.Class. + Java programming language object type - java.lang.Class. JNI type . Returned values are JNI local references and must be managed. - Union of all Java programming language primitive and object types - + Union of all Java programming language primitive and object types - JNI type . Returned values which represent object types are JNI local references and must be managed. - Java programming language field identifier - + Java programming language field identifier - JNI type . - Java programming language method identifier - + Java programming language method identifier - JNI type . @@ -9693,7 +9757,7 @@ myInit() { jvmtiParamInfo - Array of + Array of parameters (jvmtiEnv *jvmti_env excluded) @@ -9776,7 +9840,7 @@ myInit() { jvmtiParamInfo - Array of + Array of parameters (jvmtiEnv *jvmti_env excluded) @@ -9812,7 +9876,7 @@ myInit() { Extension Event This is the implementation-specific event. - The event handler is set with + The event handler is set with .

      Event handlers for extension events must be declared varargs to match this definition. @@ -9863,9 +9927,9 @@ myInit() { Identifies which callback to set. - This index is the + This index is the - field of + field of . @@ -9875,18 +9939,18 @@ myInit() { disable the event - If callback is non-NULL, + If callback is non-NULL, set callback to be the event callback function and enable the event. - + is not an - - returned by + returned by @@ -9898,30 +9962,30 @@ myInit() { The capabilities functions allow you to change the - functionality available to --that is, - which + functionality available to --that is, + which functions can be called, what events can be generated, and what functionality these events and functions can provide.

      - The "Capabilities" section of each function and event describe which + The "Capabilities" section of each function and event describe which capabilities, if any, they are associated with. "Required Functionality" means it is available for use and no capabilities must be added to use it. "Optional Functionality" means the agent must possess the capability - before it can be used. + before it can be used. To possess a capability, the agent must add the capability. "Optional Features" describe capabilities which, if added, extend the feature set.

      - The potentially available capabilities of each implementation are different. + The potentially available capabilities of each implementation are different. Depending on the implementation, a capability:

      • may never be added
      • may be added in either the OnLoad or live phase in any environment
      • may be added only during the OnLoad phase
      • may be possessed by only one environment at a time
      • -
      • may be possessed by only one environment at a time, +
      • may be possessed by only one environment at a time, and only during the OnLoad phase
      • and so on ...
      @@ -9929,24 +9993,24 @@ myInit() { time, and/or memory footprint. Note that the overhead of using a capability is completely different than the overhead of possessing a capability. Take single stepping as an example. When single stepping is on (that - is, when the event is enabled and thus actively sending events) - the overhead of sending and processing an event - on each instruction is huge in any implementation. - However, the overhead of possessing the capability may be small or large, + is, when the event is enabled and thus actively sending events) + the overhead of sending and processing an event + on each instruction is huge in any implementation. + However, the overhead of possessing the capability may be small or large, depending on the implementation. Also, when and if a capability is potentially available depends on the implementation. Some examples:
        -
      • One VM might perform all execution by compiling bytecodes into +
      • One VM might perform all execution by compiling bytecodes into native code and be unable to generate single step instructions. In this implementation the capability can not be added.
      • Another VM may be able to switch execution to a single stepping - interpreter at any time. In this implementation, having the capability has no + interpreter at any time. In this implementation, having the capability has no overhead and could be added at any time.
      • Yet another VM might be able to choose a bytecode compiling or single stepping capable interpreted execution engine at start up, but be unable to switch between them. - In this implementation the capability would need to be added + In this implementation the capability would need to be added during the OnLoad phase (before bytecode - execution begins) and would have a large impact on execution speed + execution begins) and would have a large impact on execution speed even if single stepping was never used.
      • Still another VM might be able to add an "is single stepping on" check into compiled bytecodes or a generated interpreter. Again in this implementation @@ -9955,30 +10019,30 @@ myInit() {

      Each environment - has its own set of capabilities. + has its own set of capabilities. Initially, that set is empty. Any desired capability must be added. - If possible, capabilities should be added during the OnLoad phase. For most - virtual machines certain capabilities require special set up for + If possible, capabilities should be added during the OnLoad phase. For most + virtual machines certain capabilities require special set up for the virtual machine and this set up must happen - during the OnLoad phase, before the virtual machine begins execution. + during the OnLoad phase, before the virtual machine begins execution. Once a capability is added, it can only be removed if explicitly relinquished by the environment.

      - The agent can, + The agent can, determine what capabilities this VM can potentially provide, add the capabilities to be used, release capabilities which are no longer needed, and - examine the currently available + examine the currently available capabilities. For example, a freshly started agent (in the OnLoad function) - wants to enable all possible capabilities. + wants to enable all possible capabilities. Note that, in general, this is not advisable as the agent may suffer a performance penalty for functionality it is not using. The code might look like this in C: @@ -9991,9 +10055,9 @@ myInit() { err = (*jvmti)->AddCapabilities(jvmti, &capa); For example, if an agent wants to check if it can get - the bytecodes of a method (that is, it wants to check - if it previously added this capability and has not - relinquished it), the code might + the bytecodes of a method (that is, it wants to check + if it previously added this capability and has not + relinquished it), the code might look like this in C: jvmtiCapabilities capa; @@ -10001,13 +10065,13 @@ myInit() { err = (*jvmti)->GetCapabilities(jvmti, &capa); if (err == JVMTI_ERROR_NONE) { - if (capa.can_get_bytecodes) { ... } } + if (capa.can_get_bytecodes) { ... } } - The functions in this category use this capabilities structure + The functions in this category use this capabilities structure which contains boolean flags corresponding to each capability: @@ -10035,14 +10099,14 @@ myInit() { - Can test if a field or method is synthetic - + Can test if a field or method is synthetic - and - Can get information about ownership of monitors - + Can get information about ownership of monitors - @@ -10103,19 +10167,19 @@ myInit() { - Can get exception thrown and + Can get exception thrown and exception catch events - Can set and thus get + Can set and thus get events - Can set and thus get + Can set and thus get events @@ -10142,65 +10206,65 @@ myInit() { thread CPU time - Can generate method entry events on entering a method - Can generate method exit events on leaving a method - Can generate ClassFileLoadHook events for every loaded class. - Can generate events when a method is compiled or unloaded - Can generate events on monitor activity - Can generate events on VM allocation of an object - Can generate events when a native method is bound to its implementation - Can generate events when garbage collection begins or ends - Can generate events when the garbage collector frees an object @@ -10234,16 +10298,16 @@ myInit() { Can retransform classes with . - In addition to the restrictions imposed by the specific + In addition to the restrictions imposed by the specific implementation on this capability (see the Capability section), - this capability must be set before the + this capability must be set before the event is enabled for the first time in this environment. - An environment that possesses this capability at the time that + An environment that possesses this capability at the time that ClassFileLoadHook is enabled for the first time is said to be retransformation capable. - An environment that does not possess this capability at the time that + An environment that does not possess this capability at the time that ClassFileLoadHook is enabled for the first time is said to be retransformation incapable. @@ -10258,7 +10322,7 @@ myInit() { - Can generate events when the VM is unable to allocate memory from + Can generate events when the VM is unable to allocate memory from the Java platform heap. See . @@ -10291,11 +10355,11 @@ myInit() { Get Potential Capabilities - Returns via the + Returns via the features that can potentially be possessed by this environment at this time. The returned capabilities differ from the complete set of capabilities - implemented by the VM in two cases: another environment possesses + implemented by the VM in two cases: another environment possesses capabilities that can only be possessed by one environment, or the current phase is live, and certain capabilities can only be added during the OnLoad phase. @@ -10338,7 +10402,7 @@ myInit() { conditional implementations would be used or are even a good idea. The thought is that release documentation for the implementation would be the best means of exposing this information. - Unless new arguments are presented, I intend to remove this + Unless new arguments are presented, I intend to remove this function in the next revision.

      @@ -10348,15 +10412,15 @@ myInit() { . The returned estimates are in percentage of additional overhead, thus a time impact of 100 mean the application might run - at half the speed. + at half the speed. The estimates are very rough approximations and are not guaranteed. Note also, that the estimates are of the impact of having the capability available--when and if it is used the impact may be much greater. - Estimates can be for a single capability or for a set of + Estimates can be for a single capability or for a set of capabilities. Note that the costs are not necessarily additive, - adding support for one capability might make another available - for free or conversely having two capabilities at once may + adding support for one capability might make another available + for free or conversely having two capabilities at once may have multiplicative impact. Estimates are relative to the current set of capabilities - that is, how much more impact given the currently possessed capabilities. @@ -10396,7 +10460,7 @@ myInit() { - + The desired capabilities are not even potentially available. @@ -10406,7 +10470,7 @@ myInit() { Add Capabilities - Set new capabilities by adding the capabilities + Set new capabilities by adding the capabilities whose values are set to one (1) in *. All previous capabilities are retained. @@ -10429,7 +10493,7 @@ myInit() { - + The desired capabilities are not even potentially available. @@ -10483,7 +10547,7 @@ myInit() { Get Capabilities - Returns via the optional + Returns via the optional features which this environment currently possesses. Each possessed capability is indicated by a one (1) in the corresponding field of the capabilities @@ -10514,16 +10578,16 @@ myInit() { - - + + These functions provide timing information. - The resolution at which the time is updated is not specified. - They provides nanosecond precision, but not necessarily nanosecond accuracy. + The resolution at which the time is updated is not specified. + They provides nanosecond precision, but not necessarily nanosecond accuracy. Details about the timers, such as their maximum values, can be accessed with - the timer information functions. + the timer information functions. @@ -10557,7 +10621,7 @@ myInit() { jvmtiTimerKind The kind of timer. - On a platform that does not distinguish between user and system time, JVMTI_TIMER_TOTAL_CPU is returned. @@ -10595,12 +10659,12 @@ myInit() { Get Current Thread CPU Timer Information - Get information about the - timer. - The fields of the structure + Get information about the + timer. + The fields of the structure are filled in with details about the timer. This information is specific to the platform and the implementation of - and thus + and thus does not vary by thread nor does it vary during a particular invocation of the VM.

      @@ -10632,15 +10696,15 @@ myInit() { Get Current Thread CPU Time - Return the CPU time utilized by the current thread. + Return the CPU time utilized by the current thread.

      Note that the function provides CPU time for any thread, including - the current thread. GetCurrentThreadCpuTime + the current thread. GetCurrentThreadCpuTime exists to support platforms which cannot - supply CPU time for threads other than the current + supply CPU time for threads other than the current thread or which have more accurate information for - the current thread (see + the current thread (see vs ). On many platforms this call will be equivalent to: @@ -10653,13 +10717,13 @@ myInit() { Can get current thread CPU time.

      - If this capability is enabled after threads have started, + If this capability is enabled after threads have started, the implementation may choose any time up - to and including the time that the capability is enabled + to and including the time that the capability is enabled as the point where CPU time collection starts.

      - This capability must be potentially available on any - platform where + This capability must be potentially available on any + platform where can_get_thread_cpu_time is potentially available. @@ -10669,7 +10733,7 @@ myInit() { On return, points to the CPU time used by this thread - in nanoseconds. + in nanoseconds. This is an unsigned value. If tested or printed as a jlong (signed value) it may appear to be a negative number. @@ -10682,12 +10746,12 @@ myInit() { Get Thread CPU Timer Information - Get information about the - timer. - The fields of the structure + Get information about the + timer. + The fields of the structure are filled in with details about the timer. This information is specific to the platform and the implementation of - and thus + and thus does not vary by thread nor does it vary during a particular invocation of the VM.

      @@ -10719,19 +10783,19 @@ myInit() { Get Thread CPU Time - Return the CPU time utilized by the specified thread. + Return the CPU time utilized by the specified thread.

      Get information about this timer with - . + . new Can get thread CPU time.

      - If this capability is enabled after threads have started, + If this capability is enabled after threads have started, the implementation may choose any time up - to and including the time that the capability is enabled + to and including the time that the capability is enabled as the point where CPU time collection starts. @@ -10746,7 +10810,7 @@ myInit() { On return, points to the CPU time used by the specified thread - in nanoseconds. + in nanoseconds. This is an unsigned value. If tested or printed as a jlong (signed value) it may appear to be a negative number. @@ -10759,9 +10823,9 @@ myInit() { Get Timer Information - Get information about the - timer. - The fields of the structure + Get information about the + timer. + The fields of the structure are filled in with details about the timer. This information will not change during a particular invocation of the VM. @@ -10784,7 +10848,7 @@ myInit() { Get Time - Return the current value of the system timer, in nanoseconds. + Return the current value of the system timer, in nanoseconds.

      The value returned represents nanoseconds since some fixed but arbitrary time (perhaps in the future, so values may be @@ -10793,7 +10857,7 @@ myInit() { how frequently values change.

      Get information about this timer with - . + . new @@ -10802,7 +10866,7 @@ myInit() { - On return, points to the time in nanoseconds. + On return, points to the time in nanoseconds. This is an unsigned value. If tested or printed as a jlong (signed value) it may appear to be a negative number. @@ -10817,7 +10881,7 @@ myInit() { Returns the number of processors available to the Java virtual machine.

      - This value may change during a particular invocation of the virtual machine. + This value may change during a particular invocation of the virtual machine. Applications that are sensitive to the number of available processors should therefore occasionally poll this property. @@ -10829,7 +10893,7 @@ myInit() { On return, points to the maximum number of processors available to the - virtual machine; never smaller than one. + virtual machine; never smaller than one. @@ -10850,18 +10914,18 @@ myInit() { Add To Bootstrap Class Loader Search - This function can be used to cause instrumentation classes to be defined by the + This function can be used to cause instrumentation classes to be defined by the bootstrap class loader. See . After the bootstrap - class loader unsuccessfully searches for a class, the specified platform-dependent - search path will be searched as well. Only one segment may be specified in - the . This function may be called multiple times to add multiple segments, + class loader unsuccessfully searches for a class, the specified platform-dependent + search path will be searched as well. Only one segment may be specified in + the . This function may be called multiple times to add multiple segments, the segments will be searched in the order that this function was called.

      - In the OnLoad phase the function may be used to specify any platform-dependent + In the OnLoad phase the function may be used to specify any platform-dependent search path segment to be searched after the bootstrap class loader unsuccessfully searches for a class. The segment is typically a directory or JAR file. -

      +

      In the live phase the may be used to specify any platform-dependent path to a JAR file. The agent should take care that the JAR file does not @@ -10889,7 +10953,7 @@ myInit() { - + is an invalid path. In the live phase, anything other than an existing JAR file is an invalid path. @@ -10901,15 +10965,15 @@ myInit() { This function can be used to cause instrumentation classes to be defined by the system class loader. See . - After the class loader unsuccessfully searches for a class, the specified platform-dependent search - path will be searched as well. Only one segment may be specified in the - . This function may be called multiple times to add multiple segments, the + After the class loader unsuccessfully searches for a class, the specified platform-dependent search + path will be searched as well. Only one segment may be specified in the + . This function may be called multiple times to add multiple segments, the segments will be searched in the order that this function was called.

      - In the OnLoad phase the function may be used to specify any platform-dependent + In the OnLoad phase the function may be used to specify any platform-dependent search path segment to be searched after the system class loader unsuccessfully searches for a class. The segment is typically a directory or JAR file. -

      +

      In the live phase the is a platform-dependent path to a JAR file to be searched after the system class loader unsuccessfully searches for a class. The agent should @@ -10917,9 +10981,9 @@ myInit() { defined by the system class loader for the purposes of instrumentation.

      In the live phase the system class loader supports adding a JAR file to be searched if - the system class loader implements a method name appendToClassPathForInstrumentation - which takes a single parameter of type java.lang.String. The method is not required - to have public access. + the system class loader implements a method name appendToClassPathForInstrumentation + which takes a single parameter of type java.lang.String. The method is not required + to have public access.

      specifies that a subsequent attempt to resolve a symbolic reference that the Java virtual machine has previously unsuccessfully attempted @@ -10948,7 +11012,7 @@ myInit() { Operation not supported by the system class loader. - + @@ -10964,7 +11028,7 @@ myInit() { Get System Properties - The list of VM system property keys which may be used with + The list of VM system property keys which may be used with is returned. It is strongly recommended that virtual machines provide the following property keys: @@ -10979,15 +11043,15 @@ myInit() { Provides access to system properties defined by and used by the VM. Properties set on the command-line are included. - This allows getting and setting of these properties + This allows getting and setting of these properties before the VM even begins executing bytecodes. - Since this is a VM view of system properties, the set of available + Since this is a VM view of system properties, the set of available properties will usually be different than that in java.lang.System.getProperties. - JNI method invocation may be used to access + JNI method invocation may be used to access java.lang.System.getProperties.

      - The set of properties may grow during execution. + The set of properties may grow during execution. new @@ -11002,7 +11066,7 @@ myInit() { - On return, points to an array of property keys, encoded as + On return, points to an array of property keys, encoded as modified UTF-8 strings. @@ -11014,25 +11078,25 @@ myInit() { Get System Property - Return a VM system property value given the property key. + Return a VM system property value given the property key.

      The function returns the set of property keys which may be used. The properties which can be retrieved may grow during execution.

      - Since this is a VM view of system properties, the values - of properties may differ from that returned by + Since this is a VM view of system properties, the values + of properties may differ from that returned by java.lang.System.getProperty(String). - A typical VM might copy the values of the VM system + A typical VM might copy the values of the VM system properties into the Properties held by java.lang.System during the initialization of that class. Thereafter any changes to the VM system - properties (with ) + properties (with ) or the java.lang.System system properties (with java.lang.System.setProperty(String,String)) would cause the values to diverge. - JNI method invocation may be used to access + JNI method invocation may be used to access java.lang.System.getProperty(String). new @@ -11055,7 +11119,7 @@ myInit() { - + This property is not available. Use to find available properties. @@ -11065,7 +11129,7 @@ myInit() { Set System Property - Set a VM system property value. + Set a VM system property value.

      The function returns the set of property keys, some of these may be settable. @@ -11097,7 +11161,7 @@ myInit() { - + This property is not available or is not writeable. @@ -11113,7 +11177,7 @@ myInit() { Get Phase - Return the current phase of VM execution. + Return the current phase of VM execution. The phases proceed in sequence: @@ -11129,7 +11193,7 @@ myInit() { VMStart event. - Start phase: when the VMStart event + Start phase: when the VMStart event is sent and until the VMInit event is sent. @@ -11158,8 +11222,8 @@ myInit() {

      Most events are sent only in the live phase. The following events operate in others phases: - - + + new @@ -11181,7 +11245,7 @@ myInit() { Shutdown a connection created with JNI GetEnv (see Environments). - Dispose of any resources held by the environment. + Dispose of any resources held by the environment. What resources are reclaimed? What is undone? Breakpoints,watchpoints removed? @@ -11191,7 +11255,7 @@ myInit() { Memory allocated by this environment via calls to functions is not released, this can be done explicitly by the agent by calling . - Raw monitors created by this environment are not destroyed, + Raw monitors created by this environment are not destroyed, this can be done explicitly by the agent by calling . The state of threads waiting on raw monitors created by this environment @@ -11230,7 +11294,7 @@ myInit() { This value is NULL unless set with this function. Agents can allocate memory in which they store environment specific information. By setting environment-local storage it can then be - accessed with + accessed with .

      Called by the agent to set the value of the @@ -11243,10 +11307,10 @@ myInit() { - - - value is set to NULL - + + + value is set to NULL + The value to be entered into the environment-local storage. @@ -11260,7 +11324,7 @@ myInit() { Get Environment Local Storage Called by the agent to get the value of the environment-local - storage. + storage. new @@ -11269,10 +11333,10 @@ myInit() { - Pointer through which the value of the environment local + Pointer through which the value of the environment local storage is returned. If environment-local storage has not been set with - returned + returned pointer is NULL. @@ -11285,7 +11349,7 @@ myInit() { Get Version Number Return the version via version_ptr. - The return value is the version identifier. + The return value is the version identifier. The version identifier includes major, minor and micro version as well as the interface type. @@ -11298,10 +11362,10 @@ myInit() { - Mask to extract interface type. + Mask to extract interface type. The value of the version returned by this function masked with JVMTI_VERSION_MASK_INTERFACE_TYPE is always - JVMTI_VERSION_INTERFACE_JVMTI + JVMTI_VERSION_INTERFACE_JVMTI since this is a function. @@ -11345,11 +11409,11 @@ myInit() { Get Error Name - Return the symbolic name for an - error code. + Return the symbolic name for an + error code.

      - For example - GetErrorName(env, JVMTI_ERROR_NONE, &err_name) + For example + GetErrorName(env, JVMTI_ERROR_NONE, &err_name) would return in err_name the string "JVMTI_ERROR_NONE". @@ -11395,7 +11459,7 @@ myInit() { Control verbose output. - This is the output which typically is sent to stderr. + This is the output which typically is sent to stderr. new @@ -11424,18 +11488,18 @@ myInit() { Although the greatest functionality is achieved with location information referencing the virtual machine bytecode index, the definition of - jlocation has intentionally been left unconstrained to allow VM + jlocation has intentionally been left unconstrained to allow VM implementations that do not have this information.

      This function describes the representation of jlocation used in this VM. - If the returned format is , + If the returned format is , jlocations can be used as in indices into the array returned by - . + . - jlocation values represent virtual machine - bytecode indices--that is, offsets into the + jlocation values represent virtual machine + bytecode indices--that is, offsets into the virtual machine code for a method. @@ -11470,16 +11534,16 @@ myInit() { Every function returns a jvmtiError error code.

      - It is the responsibility of the agent to call functions with + It is the responsibility of the agent to call functions with valid parameters and in the proper context (calling thread is attached, - phase is correct, etc.). - Detecting some error conditions may be difficult, inefficient, or + phase is correct, etc.). + Detecting some error conditions may be difficult, inefficient, or impossible for an implementation. - The errors listed in + The errors listed in Function Specific Required Errors must be detected by the implementation. All other errors represent the recommended response to the error - condition. + condition. @@ -11495,7 +11559,7 @@ myInit() { Pointer is unexpectedly NULL. - The function attempted to allocate memory and no more memory was + The function attempted to allocate memory and no more memory was available for allocation. @@ -11563,6 +11627,9 @@ myInit() { The class cannot be modified. + + The module cannot be modified. + The functionality is not available in this virtual machine. @@ -11584,7 +11651,7 @@ myInit() { The following errors are returned by some functions. They are returned in the event of invalid parameters passed by the - agent or usage in an invalid context. + agent or usage in an invalid context. An implementation is not required to detect these errors. @@ -11659,7 +11726,7 @@ myInit() { declared in the old class version. - The class name defined in the new class file is + The class name defined in the new class file is different from the name in the old class object. @@ -11678,33 +11745,33 @@ myInit() { programs.

      To handle events, designate a set of callback functions with - . - For each event the corresponding callback function will be + . + For each event the corresponding callback function will be called. Arguments to the callback function provide additional - information about the event. + information about the event.

      - The callback function is usually called from within an application - thread. The implementation does not + The callback function is usually called from within an application + thread. The implementation does not queue events in any way. This means - that event callback functions must be written - carefully. Here are some general guidelines. See + that event callback functions must be written + carefully. Here are some general guidelines. See the individual event descriptions for further suggestions.

        -
      • Any exception thrown during the execution of an event callback can +
      • Any exception thrown during the execution of an event callback can overwrite any current pending exception in the current application thread. Care must be taken to preserve a pending exception when an event callback makes a JNI call that might generate an exception.
      • Event callback functions must be re-entrant. The implementation does - not queue events. If an agent needs to process events one at a time, it - can use a raw monitor inside the + not queue events. If an agent needs to process events one at a time, it + can use a raw monitor inside the event callback functions to serialize event processing.
      • Event callback functions that execute JNI's FindClass function to load - classes need to note that FindClass locates the class loader associated + classes need to note that FindClass locates the class loader associated with the current native method. For the purposes of class loading, an event callback that includes a JNI environment as a parameter to the callback will treated as if it is a native call, where the native method @@ -11712,8 +11779,8 @@ myInit() {

      - Some events identify objects with JNI references. - All references + Some events identify objects with JNI references. + All references in events are JNI local references and will become invalid after the event callback returns. Unless stated otherwise, memory referenced by pointers sent in event @@ -11724,13 +11791,13 @@ myInit() { Events are sent at the time they occur. The specification for each event includes the set of phases in which it can be sent; - if an event triggering activity occurs during another phase, no event - is sent. + if an event triggering activity occurs during another phase, no event + is sent.

      A thread that generates an event does not change its execution status (for example, the event does not cause the thread to be suspended). If an agent wishes the event to result in suspension, then the agent - is responsible for explicitly suspending the thread with + is responsible for explicitly suspending the thread with .

      If an event is enabled in multiple environments, the event will be sent @@ -11743,26 +11810,26 @@ myInit() {

      • If the event requires a capability, that capability must - be added with + be added with .
      • - A callback for the event must be set with + A callback for the event must be set with .
      • The event must be enabled with - . + .
      - In many situations it is possible for multiple events to occur - at the same location in one thread. When this happens, all the events + In many situations it is possible for multiple events to occur + at the same location in one thread. When this happens, all the events are reported through the event callbacks in the order specified in this section.

      - If the current location is at the entry point of a method, the + If the current location is at the entry point of a method, the event is reported before any other event at the current location in the same thread.

      @@ -11772,39 +11839,39 @@ myInit() { exceptionCatch event is reported before any other event at the current location in the same thread.

      - If a singleStep event or - breakpoint event is triggered at the - current location, the event is defined to occur - immediately before the code at the current location is executed. - These events are reported before any events which are triggered - by the execution of code at the current location in the same - thread (specifically: + If a singleStep event or + breakpoint event is triggered at the + current location, the event is defined to occur + immediately before the code at the current location is executed. + These events are reported before any events which are triggered + by the execution of code at the current location in the same + thread (specifically: exception, fieldAccess, and fieldModification). - If both a step and breakpoint event are triggered for the same thread and + If both a step and breakpoint event are triggered for the same thread and location, the step event is reported before the breakpoint event.

      If the current location is the exit point of a method (that is, the last - location before returning to the caller), the - event and + location before returning to the caller), the + event and the event (if requested) are reported after all other events at the current location in the same - thread. There is no specified ordering of these two events + thread. There is no specified ordering of these two events with respect to each other.

      Co-located events can be triggered during the processing of some other event by the agent at the same location in the same thread. - If such an event, of type y, is triggered during the processing of - an event of type x, and if x - precedes y in the ordering specified above, the co-located event + If such an event, of type y, is triggered during the processing of + an event of type x, and if x + precedes y in the ordering specified above, the co-located event y is reported for the current thread and location. If x does not precede y, y is not reported for the current thread and location. - For example, if a breakpoint is set at the current location + For example, if a breakpoint is set at the current location during the processing of , - that breakpoint will be reported before the thread moves off the current + that breakpoint will be reported before the thread moves off the current location. -

      The following events are never considered to be co-located with +

      The following events are never considered to be co-located with other events.

      • @@ -11820,7 +11887,7 @@ myInit() { The event callback structure below is used to specify the handler function for events. It is set with the - function. + function. Single step events allow the agent to trace thread execution at the finest granularity allowed by the VM. A single step event is - generated whenever a thread reaches a new location. - Typically, single step events represent the completion of one VM - instruction as defined in . However, some implementations - may define locations differently. In any case the + generated whenever a thread reaches a new location. + Typically, single step events represent the completion of one VM + instruction as defined in . However, some implementations + may define locations differently. In any case the method and location parameters uniquely identify the current location and allow - the mapping to source file and line number when that information is + the mapping to source file and line number when that information is available.

        No single step events are generated from within native methods. @@ -11843,7 +11910,7 @@ myInit() { - + JNIEnv @@ -11886,14 +11953,14 @@ myInit() { designated as a breakpoint with . The method and location parameters uniquely identify the current location and allow - the mapping to source file and line number when that information is + the mapping to source file and line number when that information is available. jvmdi - + JNIEnv @@ -11933,18 +12000,18 @@ myInit() { id="FieldAccess" const="JVMTI_EVENT_FIELD_ACCESS" filtered="thread" num="63"> Field access events are generated whenever a thread accesses - a field that was designated as a watchpoint + a field that was designated as a watchpoint with . - The method and location + The method and location parameters uniquely identify the current location and allow - the mapping to source file and line number when that information is - available. + the mapping to source file and line number when that information is + available. jvmdi - + JNIEnv @@ -12003,18 +12070,18 @@ myInit() { id="FieldModification" const="JVMTI_EVENT_FIELD_MODIFICATION" filtered="thread" num="64"> Field modification events are generated whenever a thread modifies - a field that was designated as a watchpoint + a field that was designated as a watchpoint with . - The method and location + The method and location parameters uniquely identify the current location and allow - the mapping to source file and line number when that information is - available. + the mapping to source file and line number when that information is + available. jvmdi - + JNIEnv @@ -12084,25 +12151,25 @@ myInit() { - Frame pop events are generated upon exit from a single method + Frame pop events are generated upon exit from a single method in a single frame as specified in a call to . This is true whether termination is caused by executing its return instruction - or by throwing an exception to its caller + or by throwing an exception to its caller (see ). - However, frame pops caused by the + However, frame pops caused by the function are not reported.

        The location reported by - identifies the executable location in the returning method, - immediately prior to the return. + identifies the executable location in the returning method, + immediately prior to the return. jvmdi - + JNIEnv @@ -12142,24 +12209,24 @@ myInit() { - Method entry events are generated upon entry of Java + Method entry events are generated upon entry of Java programming language methods (including native methods).

        The location reported by identifies the initial executable location in - the method. + the method.

        Enabling method entry or exit events will significantly degrade performance on many platforms and is thus not advised for performance critical usage (such as profiling). - Bytecode instrumentation should be + Bytecode instrumentation should be used in these cases. jvmdi - + JNIEnv @@ -12192,25 +12259,25 @@ myInit() { - Method exit events are generated upon exit from Java + Method exit events are generated upon exit from Java programming language methods (including native methods). This is true whether termination is caused by executing its return instruction - or by throwing an exception to its caller + or by throwing an exception to its caller (see ).

        The method field uniquely identifies the - method being entered or exited. The frame field provides + method being entered or exited. The frame field provides access to the stack frame for the method.

        The location reported by - identifies the executable location in the returning method - immediately prior to the return. + identifies the executable location in the returning method + immediately prior to the return.

        Enabling method entry or exit events will significantly degrade performance on many platforms and is thus not advised for performance critical usage (such as profiling). - Bytecode instrumentation should be + Bytecode instrumentation should be used in these cases. jvmdi @@ -12255,7 +12322,7 @@ myInit() { The return value of the method being exited. - Undefined and should not be used if + Undefined and should not be used if is true. @@ -12266,18 +12333,18 @@ myInit() { - A Native Method Bind event is sent when a VM binds a + A Native Method Bind event is sent when a VM binds a Java programming language native method - to the address of a function that implements the native method. + to the address of a function that implements the native method. This will occur when the native method is called for the first time and also occurs when the JNI function RegisterNatives is called. This event allows the bind to be redirected to an agent-specified - proxy function. + proxy function. This event is not sent when the native method is unbound. - Typically, this proxy function will need to be specific to a + Typically, this proxy function will need to be specific to a particular method or, to handle the general case, automatically - generated assembly code, since after instrumentation code is - executed the function at the original binding + generated assembly code, since after instrumentation code is + executed the function at the original binding address will usually be invoked. The original binding can be restored or the redirection changed by use of the JNI function RegisterNatives. @@ -12296,7 +12363,7 @@ myInit() { The JNI environment of the event (current) thread - Will be NULL if sent during the primordial + Will be NULL if sent during the primordial phase. @@ -12340,7 +12407,7 @@ myInit() { id="Exception" const="JVMTI_EVENT_EXCEPTION" filtered="thread" num="58"> Exception events are generated whenever an exception is first detected - in a Java programming language method. + in a Java programming language method. Where "exception" means any java.lang.Throwable. The exception may have been thrown by a Java programming language or native method, but in the case of native methods, the event is not generated @@ -12349,20 +12416,20 @@ myInit() { no exception event is generated.

        The method and location - parameters uniquely identify the current location + parameters uniquely identify the current location (where the exception was detected) and allow - the mapping to source file and line number when that information is + the mapping to source file and line number when that information is available. The exception field identifies the thrown exception object. The catch_method and catch_location identify the location of the catch clause, if any, that handles the thrown exception. If there is no such catch clause, each field is set to 0. There is no guarantee that the thread will ever reach this catch clause. If there are native methods on the call stack - between the throw location and the catch clause, the exception may + between the throw location and the catch clause, the exception may be reset by one of those native methods. Similarly, exceptions that are reported as uncaught (catch_klass et al. set to 0) may in fact be caught by native code. - Agents can check for these occurrences by monitoring + Agents can check for these occurrences by monitoring events. Note that finally clauses are implemented as catch and re-throw. Therefore they will be reported in the catch location. @@ -12371,7 +12438,7 @@ myInit() { - + JNIEnv @@ -12438,18 +12505,18 @@ myInit() { Where "exception" means any java.lang.Throwable. If the exception is caught in a Java programming language method, the event is generated when the catch clause is reached. If the exception is caught in a native - method, the event is generated as soon as control is returned to a Java programming language + method, the event is generated as soon as control is returned to a Java programming language method. Exception catch events are generated for any exception for which a throw was detected in a Java programming language method. Note that finally clauses are implemented as catch and re-throw. Therefore they will generate exception catch events.

        The method and location - parameters uniquely identify the current location - and allow the mapping to source file and line number when that information is - available. For exceptions caught in a Java programming language method, the + parameters uniquely identify the current location + and allow the mapping to source file and line number when that information is + available. For exceptions caught in a Java programming language method, the exception object identifies the exception object. Exceptions - caught in native methods are not necessarily available by the time the + caught in native methods are not necessarily available by the time the exception catch is reported, so the exception field is set to NULL. @@ -12457,7 +12524,7 @@ myInit() { - + JNIEnv @@ -12503,11 +12570,11 @@ myInit() { id="ThreadStart" const="JVMTI_EVENT_THREAD_START" num="52" phase="start"> Thread start events are generated by a new thread before its initial - method executes. + method executes.

        A thread may be listed in the array returned by - before its thread start event is generated. + before its thread start event is generated. It is possible for other events to be generated on a thread before its thread start event.

        @@ -12516,7 +12583,7 @@ myInit() { jvmdi - + JNIEnv @@ -12535,14 +12602,14 @@ myInit() { + id="ThreadEnd" const="JVMTI_EVENT_THREAD_END" filtered="thread" num="53" phase="start"> Thread end events are generated by a terminating thread - after its initial method has finished execution. + after its initial method has finished execution.

        A thread may be listed in the array returned by - after its thread end event is generated. + after its thread end event is generated. No events are generated on a thread after its thread end event.

        @@ -12551,7 +12618,7 @@ myInit() { jvmdi - + JNIEnv @@ -12574,15 +12641,15 @@ myInit() { A class load event is generated when a class is first loaded. The order of class load events generated by a particular thread are guaranteed - to match the order of class loading within that thread. + to match the order of class loading within that thread. Array class creation does not generate a class load event. - The creation of a primitive class (for example, java.lang.Integer.TYPE) + The creation of a primitive class (for example, java.lang.Integer.TYPE) does not generate a class load event.

        This event is sent at an early stage in loading the class. As a result the class should be used carefully. Note, for example, that methods and fields are not yet loaded, so queries for methods, - fields, subclasses, and so on will not give correct results. + fields, subclasses, and so on will not give correct results. See "Loading of Classes and Interfaces" in the Java Language Specification. For most purposes the event will @@ -12591,7 +12658,7 @@ myInit() { jvmdi - + JNIEnv @@ -12620,7 +12687,7 @@ myInit() { id="ClassUnload" const="JVMTI_EVENT_CLASS_UNLOAD" num="57"> A class unload event is generated when the class is about to be unloaded. - Class unload events take place during garbage collection and must be + Class unload events take place during garbage collection and must be handled extremely carefully. The garbage collector holds many locks and has suspended all other threads, so the event handler cannot depend on the ability to acquire any locks. The class unload event handler should @@ -12637,7 +12704,7 @@ myInit() { jvmdi - + JNIEnv @@ -12666,16 +12733,16 @@ myInit() { id="ClassPrepare" const="JVMTI_EVENT_CLASS_PREPARE" filtered="thread" phase="start" num="56"> A class prepare event is generated when class preparation is complete. - At this point, class fields, methods, and implemented interfaces are - available, and no code from the class has been executed. Since array - classes never have fields or methods, class prepare events are not - generated for them. Class prepare events are not generated for - primitive classes (for example, java.lang.Integer.TYPE). + At this point, class fields, methods, and implemented interfaces are + available, and no code from the class has been executed. Since array + classes never have fields or methods, class prepare events are not + generated for them. Class prepare events are not generated for + primitive classes (for example, java.lang.Integer.TYPE). jvmdi - + JNIEnv @@ -12704,14 +12771,14 @@ myInit() { This event is sent when the VM obtains class file data, but before it constructs - the in-memory representation for that class. - This event is also sent when the class is being modified by the + the in-memory representation for that class. + This event is also sent when the class is being modified by the function or the function, called in any environment. The agent can instrument the existing class file data sent by the VM to include profiling/debugging hooks. - See the description of + See the description of bytecode instrumentation for usage information.

        @@ -12721,28 +12788,28 @@ myInit() { can_generate_all_class_hook_events are enabled then this event may be sent in the primordial phase. - Otherwise, this event may be sent before the VM is initialized (the start + Otherwise, this event may be sent before the VM is initialized (the start phase). Some classes might not be compatible with the function (eg. ROMized classes or implementation defined classes) and this event will not be generated for these classes.

        - The agent must allocate the space for the modified + The agent must allocate the space for the modified class file data buffer - using the memory allocation function + using the memory allocation function because the VM is responsible for freeing the new class file data buffer using .

        - If the agent wishes to modify the class file, it must set + If the agent wishes to modify the class file, it must set new_class_data to point to the newly instrumented class file data buffer and set - new_class_data_len to the length of that + new_class_data_len to the length of that buffer before returning from this call. If no modification is desired, the agent simply does not set new_class_data. If multiple agents have enabled this event the results are chained. That is, if - new_class_data has been set, it becomes the + new_class_data has been set, it becomes the class_data for the next agent.

        When handling a class load in the live phase, then the @@ -12760,13 +12827,13 @@ myInit() {

      • retransformation incapable - environments, in the + environments, in the order in which they were created
      • retransformation capable - environments, in the + environments, in the order in which they were created
      @@ -12802,7 +12869,7 @@ myInit() { - The class loader loading the class. + The class loader loading the class. NULL if the bootstrap class loader. @@ -12905,7 +12972,7 @@ myInit() { with other events, but the preceding events should be handled carefully, if at all, because the VM has not completed its initialization. The thread start event for the - main application thread is guaranteed not to occur until after the + main application thread is guaranteed not to occur until after the handler for the VM initialization event returns.

      In the case of VM start-up failure, this event will not be sent. @@ -12934,7 +13001,7 @@ myInit() { - The VM death event notifies the agent of the termination of the VM. + The VM death event notifies the agent of the termination of the VM. No events will occur after the VMDeath event.

      In the case of VM start-up failure, this event will not be sent. @@ -12965,7 +13032,7 @@ myInit() { followed by a new CompiledMethodLoad event. Note that a single method may have multiple compiled forms, and that this event will be sent for each form. - Note also that several methods may be inlined into a single + Note also that several methods may be inlined into a single address range, and that this event will be sent for each method.

      These events can be sent after their initial occurrence with @@ -12982,7 +13049,7 @@ myInit() { - Corresponding location. See + Corresponding location. See for the meaning of location. @@ -13028,7 +13095,7 @@ myInit() { jvmtiAddrLocationMap Map from native addresses to location. - The native address range of each entry is from + The native address range of each entry is from to start_address-1 of the next entry. NULL if mapping information cannot be supplied. @@ -13037,10 +13104,10 @@ myInit() { - VM-specific compilation information. + VM-specific compilation information. The referenced compile information is managed by the VM and must not depend on the agent for collection. - A VM implementation defines the content and lifetime + A VM implementation defines the content and lifetime of the information. @@ -13052,9 +13119,9 @@ myInit() { Sent when a compiled method is unloaded from memory. This event might not be sent on the thread which performed the unload. - This event may be sent sometime after the unload occurs, but + This event may be sent sometime after the unload occurs, but will be sent before the memory is reused - by a newly generated compiled method. This event may be sent after + by a newly generated compiled method. This event may be sent after the class is unloaded. jvmpi @@ -13072,7 +13139,7 @@ myInit() { Compiled method being unloaded. - For identification of the compiled method only -- the class + For identification of the compiled method only -- the class may be unloaded and therefore the method should not be used as an argument to further JNI or functions. @@ -13081,7 +13148,7 @@ myInit() { Address where compiled method code was loaded. - For identification of the compiled method only -- + For identification of the compiled method only -- the space may have been reclaimed. @@ -13169,7 +13236,7 @@ myInit() { - JNI local reference to the thread + JNI local reference to the thread attempting to enter the monitor @@ -13300,28 +13367,28 @@ myInit() { since="1.1"> Sent when a VM resource needed by a running application has been exhausted. - Except as required by the optional capabilities, the set of resources + Except as required by the optional capabilities, the set of resources which report exhaustion is implementation dependent.

      The following bit flags define the properties of the resource exhaustion: - After this event returns, the VM will throw a java.lang.OutOfMemoryError. - + - The VM was unable to allocate memory from the Java + The VM was unable to allocate memory from the Java platform heap. The heap is the runtime data area from which memory for all class instances and arrays are allocated. - + The VM was unable to create a thread. - + new @@ -13331,7 +13398,7 @@ myInit() { heap. - Can generate events when the VM is unable to + Can generate events when the VM is unable to create a thread. @@ -13349,8 +13416,8 @@ myInit() { Flags defining the properties of the of resource exhaustion - as specified by the - Resource + as specified by the + Resource Exhaustion Flags. @@ -13373,16 +13440,16 @@ myInit() { - Sent when a method causes the virtual machine to allocate an + Sent when a method causes the virtual machine to allocate an Object visible to Java programming language code and the allocation is not detectable by other intrumentation mechanisms. Generally object allocation should be detected by instrumenting the bytecodes of allocating methods. Object allocation generated in native code by JNI function - calls should be detected using + calls should be detected using JNI function interception. - Some methods might not have associated bytecodes and are not - native methods, they instead are executed directly by the + Some methods might not have associated bytecodes and are not + native methods, they instead are executed directly by the VM. These methods should send this event. Virtual machines which are incapable of bytecode instrumentation for some or all of their methods can send this event. @@ -13472,7 +13539,7 @@ myInit() { - A Garbage Collection Start event is sent when a + A Garbage Collection Start event is sent when a garbage collection pause begins. Only stop-the-world collections are reported--that is, collections during which all threads cease to modify the state of the Java virtual machine. @@ -13483,8 +13550,8 @@ myInit() { specifically allow such use (see the raw monitor, memory management, and environment local storage functions).

      - This event is always sent as a matched pair with - + This event is always sent as a matched pair with + (assuming both events are enabled) and no garbage collection events will occur between them. @@ -13513,11 +13580,11 @@ myInit() { and the handler for the Garbage Collection Finish event simply notifies the raw monitor

      - This event is always sent as a matched pair with + This event is always sent as a matched pair with (assuming both events are enabled). The most important use of this event is to provide timing information, - and thus additional information is not required. However, + and thus additional information is not required. However, information about the collection which is "free" should be included - what that information is needs to be determined. @@ -13546,7 +13613,7 @@ myInit() {

    - Though this seemed trivial to implement. + Though this seemed trivial to implement. In the RI it appears this will be quite complex. @@ -13592,54 +13659,54 @@ myInit() { - Holds a Java programming language int. + Holds a Java programming language int. Signed 32 bits. - Holds a Java programming language long. + Holds a Java programming language long. Signed 64 bits. - Holds a Java programming language float. + Holds a Java programming language float. 32 bits. - Holds a Java programming language double. + Holds a Java programming language double. 64 bits. - Holds a Java programming language object. + Holds a Java programming language object. - Holds a Java programming language class. + Holds a Java programming language class. - Is a union of all primitive types and jobject. Thus, holds any Java - programming language value. + Is a union of all primitive types and jobject. Thus, holds any Java + programming language value. - Identifies a Java programming language field. + Identifies a Java programming language field. jfieldIDs returned by functions and events may be safely stored. - Identifies a Java programming language method, initializer, or constructor. + Identifies a Java programming language method, initializer, or constructor. jmethodIDs returned by functions and events may be safely stored. However, if the class is unloaded, they become invalid and must not be used. @@ -13648,7 +13715,7 @@ myInit() { Pointer to the JNI function table. Pointer to this (JNIEnv *) - is a JNI environment. + is a JNI environment. @@ -13656,9 +13723,9 @@ myInit() { - The environment pointer. + The environment pointer. See the Function Section. - jvmtiEnv points to the + jvmtiEnv points to the function table pointer. @@ -13677,8 +13744,8 @@ myInit() { typedef jlong jlocation; - A 64 bit value, representing a monotonically increasing - executable position within a method. + A 64 bit value, representing a monotonically increasing + executable position within a method. -1 indicates a native method. See for the format on a given VM. @@ -13696,10 +13763,10 @@ typedef struct _jrawMonitorID *jrawMonitorID; Holds an error return code. See the Error section for possible values. -typedef enum { - JVMTI_ERROR_NONE = 0, +typedef enum { + JVMTI_ERROR_NONE = 0, JVMTI_ERROR_INVALID_THREAD = 10, - ... + ... } jvmtiError; @@ -13708,13 +13775,13 @@ typedef enum { An identifier for an event type. See the Event section for possible values. - It is guaranteed that future versions of this specification will + It is guaranteed that future versions of this specification will never assign zero as an event type identifier. -typedef enum { - JVMTI_EVENT_SINGLE_STEP = 1, - JVMTI_EVENT_BREAKPOINT = 2, - ... +typedef enum { + JVMTI_EVENT_SINGLE_STEP = 1, + JVMTI_EVENT_BREAKPOINT = 2, + ... } jvmtiEvent; @@ -13726,16 +13793,16 @@ typedef enum { typedef struct { jvmtiEventVMInit VMInit; jvmtiEventVMDeath VMDeath; - ... + ... } jvmtiEventCallbacks; - See event callbacks + See event callbacks for the complete structure.

    Where, for example, the VM initialization callback is defined: typedef void (JNICALL *jvmtiEventVMInit) - (jvmtiEnv *jvmti_env, + (jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread); @@ -13746,8 +13813,8 @@ typedef void (JNICALL *jvmtiEventVMInit) typedef struct JNINativeInterface_ jniNativeInterface; Typedef for the JNI function table JNINativeInterface - defined in the - + defined in the + JNI Specification. The JNI reference implementation defines this with an underscore. @@ -13759,13 +13826,13 @@ typedef void (JNICALL *jvmtiEventVMInit) JVMDI requires that the agent suspend threads before calling - certain sensitive functions. JVMPI requires garbage collection to be - disabled before calling certain sensitive functions. + certain sensitive functions. JVMPI requires garbage collection to be + disabled before calling certain sensitive functions. It was suggested that rather than have this requirement, that VM place itself in a suitable state before performing an operation. This makes considerable sense since each VM knows its requirements and can most easily arrange a - safe state. + safe state.

    The ability to externally suspend/resume threads will, of course, remain. The ability to enable/disable garbage collection will not. @@ -13773,19 +13840,19 @@ typedef void (JNICALL *jvmtiEventVMInit) This issue is resolved--suspend will not be required. The spec has been updated to reflect this. - + There are a variety of approaches to sampling call stacks. The biggest bifurcation is between VM controlled and agent - controlled. + controlled.

    This issue is resolved--agent controlled sampling will be the approach. - + JVMDI represents threads as jthread. JVMPI primarily - uses JNIEnv* to represent threads. + uses JNIEnv* to represent threads.

    The Expert Group has chosen jthread as the representation for threads in . @@ -13796,26 +13863,26 @@ typedef void (JNICALL *jvmtiEventVMInit) The JNI spec allows an implementation to depend on jclass/jmethodID - pairs, rather than simply a jmethodID, to reference a method. - JVMDI, for consistency, choose the same representation. + pairs, rather than simply a jmethodID, to reference a method. + JVMDI, for consistency, choose the same representation. JVMPI, however, specifies that a jmethodID alone maps to a method. Both of the Sun J2SE virtual machines (Classic and HotSpot) store pointers in jmethodIDs, and as a result, a jmethodID is sufficient. In fact, any JVM implementation that supports JVMPI must have - such a representation. + such a representation. will use jmethodID as a unique representation of a method (no jclass is used). - There should be efficiency gains, particularly in + There should be efficiency gains, particularly in functionality like stack dumping, to this representation.

    Note that fields were not used in JVMPI and that the access profile - of fields differs from methods--for implementation efficiency - reasons, a jclass/jfieldID pair will still be needed for field + of fields differs from methods--for implementation efficiency + reasons, a jclass/jfieldID pair will still be needed for field reference. - Functions return local references. + Functions return local references. @@ -13833,37 +13900,37 @@ typedef void (JNICALL *jvmtiEventVMInit) - A hint of the percentage of objects that will be tagged would + A hint of the percentage of objects that will be tagged would help the VM pick a good implementation. - How difficult or easy would be to extend the monitor_info category to include + How difficult or easy would be to extend the monitor_info category to include

    -  - current number of monitors 
    -  - enumeration of monitors 
    -  - enumeration of threads waiting on a given monitor 
    +  - current number of monitors
    +  - enumeration of monitors
    +  - enumeration of threads waiting on a given monitor
         
    - The reason for my question is the fact that current get_monitor_info support - requires the agent to specify a given thread to get the info which is probably - OK in the profiling/debugging space, while in the monitoring space the agent - could be watching the monitor list and then decide which thread to ask for - the info. You might ask why is this important for monitoring .... I think it + The reason for my question is the fact that current get_monitor_info support + requires the agent to specify a given thread to get the info which is probably + OK in the profiling/debugging space, while in the monitoring space the agent + could be watching the monitor list and then decide which thread to ask for + the info. You might ask why is this important for monitoring .... I think it can aid in the detection/prediction of application contention caused by hot-locks. - The specification is an evolving document with major, minor, + The specification is an evolving document with major, minor, and micro version numbers. A released version of the specification is uniquely identified by its major and minor version. - The functions, events, and capabilities in this specification + The functions, events, and capabilities in this specification indicate a "Since" value which is the major and minor version in which it was introduced. - The version of the specification implemented by the VM can - be retrieved at runtime with the + The version of the specification implemented by the VM can + be retrieved at runtime with the function. @@ -13957,9 +14024,9 @@ typedef void (JNICALL *jvmtiEventVMInit) get/set annotation, iterate live objects/heap. Add heap profiling functions place holder added: heap roots. - Heap profiling event added: object free. - Heap profiling event redesigned: vm object allocation. - Heap profiling event placeholders added: garbage collection start/finish. + Heap profiling event added: object free. + Heap profiling event redesigned: vm object allocation. + Heap profiling event placeholders added: garbage collection start/finish. Native method bind event added. @@ -14091,7 +14158,7 @@ typedef void (JNICALL *jvmtiEventVMInit) One character XML fix. - Change function parameter names to be consistent with + Change function parameter names to be consistent with event parameters (fooBarBaz becomes foo_bar_baz). @@ -14148,8 +14215,8 @@ typedef void (JNICALL *jvmtiEventVMInit) Define the data type jvmtiEventCallbacks. - Zero length allocations return NULL. - Keep SetAllocationHooks in JVMDI, but remove from . + Zero length allocations return NULL. + Keep SetAllocationHooks in JVMDI, but remove from . Add JVMTI_THREAD_STATUS_FLAG_INTERRUPTED. @@ -14167,7 +14234,7 @@ typedef void (JNICALL *jvmtiEventVMInit) Changes per June 11th Expert Group meeting -- - Overhaul Heap functionality: single callback, + Overhaul Heap functionality: single callback, remove GetHeapRoots, add reachable iterators, and rename "annotation" to "tag". NULL thread parameter on most functions is current @@ -14183,8 +14250,8 @@ typedef void (JNICALL *jvmtiEventVMInit) Clean up issues sections. Rename GetClassName back to GetClassSignature and fix description. - Add generic signature to GetClassSignature, - GetFieldSignature, GetMethodSignature, and + Add generic signature to GetClassSignature, + GetFieldSignature, GetMethodSignature, and GetLocalVariableTable. Elide EstimateCostOfCapabilities. Clarify that the system property functions operate @@ -14271,7 +14338,7 @@ typedef void (JNICALL *jvmtiEventVMInit) Split can_get_source_info into can_get_source_file_name, can_get_line_numbers, and can_get_source_debug_extension. PopFrame cannot have a native calling method. - Removed incorrect statement in GetClassloaderClasses + Removed incorrect statement in GetClassloaderClasses (see ). @@ -14303,7 +14370,7 @@ typedef void (JNICALL *jvmtiEventVMInit) Rename JVMTI_REFERENCE_ARRAY to JVMTI_REFERENCE_ARRAY_ELEMENT. - Steal java.lang.Runtime.availableProcessors() wording for + Steal java.lang.Runtime.availableProcessors() wording for AvailableProcessors(). Guarantee that zero will never be an event ID. Remove some issues which are no longer issues. @@ -14328,7 +14395,7 @@ typedef void (JNICALL *jvmtiEventVMInit) Remove the ClassUnload event. - Heap reference iterator callbacks return an enum that + Heap reference iterator callbacks return an enum that allows outgoing object references to be ignored. Allow JNIEnv as a param type to extension events/functions. @@ -14336,23 +14403,23 @@ typedef void (JNICALL *jvmtiEventVMInit) Fix a typo. - Remove all metadata functions: GetClassMetadata, + Remove all metadata functions: GetClassMetadata, GetFieldMetadata, and GetMethodMetadata. - Mark the functions Allocate. Deallocate, RawMonitor*, - SetEnvironmentLocalStorage, and GetEnvironmentLocalStorage + Mark the functions Allocate. Deallocate, RawMonitor*, + SetEnvironmentLocalStorage, and GetEnvironmentLocalStorage as safe for use in heap callbacks and GC events. - Add pass through opaque user data pointer to heap iterate + Add pass through opaque user data pointer to heap iterate functions and callbacks. In the CompiledMethodUnload event, send the code address. Add GarbageCollectionOccurred event. Add constant pool reference kind. Mark the functions CreateRawMonitor and DestroyRawMonitor as safe for use in heap callbacks and GC events. - Clarify: VMDeath, GetCurrentThreadCpuTimerInfo, + Clarify: VMDeath, GetCurrentThreadCpuTimerInfo, GetThreadCpuTimerInfo, IterateOverReachableObjects, IterateOverObjectsReachableFromObject, GetTime and JVMTI_ERROR_NULL_POINTER. @@ -14367,8 +14434,8 @@ typedef void (JNICALL *jvmtiEventVMInit) SetEventNotificationMode, add: error attempted inappropriate thread level control. Remove jvmtiExceptionHandlerEntry. - Fix handling of native methods on the stack -- - location_ptr param of GetFrameLocation, remove + Fix handling of native methods on the stack -- + location_ptr param of GetFrameLocation, remove JVMTI_ERROR_OPAQUE_FRAME from GetFrameLocation, jvmtiFrameInfo.location, and jlocation. Remove typo (from JVMPI) implying that the MonitorWaited @@ -14389,7 +14456,7 @@ typedef void (JNICALL *jvmtiEventVMInit) Remove MonitorContendedExit. Added JNIEnv parameter to VMObjectAlloc. - Clarified definition of class_tag and referrer_index + Clarified definition of class_tag and referrer_index parameters to heap callbacks. @@ -14416,13 +14483,13 @@ typedef void (JNICALL *jvmtiEventVMInit) Require NotifyFramePop to act on suspended threads. - Add capabilities + Add capabilities (can_redefine_any_class - and + and can_generate_all_class_hook_events) - and an error () + >can_generate_all_class_hook_events) + and an error () which allow some classes to be unmodifiable. @@ -14506,11 +14573,11 @@ typedef void (JNICALL *jvmtiEventVMInit) Bump major.minor version numbers to "1.0". - Clarify interaction between ForceGarbageCollection + Clarify interaction between ForceGarbageCollection and ObjectFree. - Restrict AddToBootstrapClassLoaderSearch and + Restrict AddToBootstrapClassLoaderSearch and SetSystemProperty to the OnLoad phase only. @@ -14537,8 +14604,8 @@ typedef void (JNICALL *jvmtiEventVMInit) Add "since" version marker. Add AddToSystemClassLoaderSearch. Allow AddToBootstrapClassLoaderSearch be used in live phase. - Fix historic rubbish in the descriptions of the heap_object_callback - parameter of IterateOverHeap and IterateOverInstancesOfClass functions; + Fix historic rubbish in the descriptions of the heap_object_callback + parameter of IterateOverHeap and IterateOverInstancesOfClass functions; disallow NULL for this parameter. Clarify, correct and make consistent: wording about current thread, opaque frames and insufficient number of frames in PopFrame. @@ -14562,19 +14629,19 @@ typedef void (JNICALL *jvmtiEventVMInit) Allow agents be started in the live phase. - Added paragraph about deploying agents. + Added paragraph about deploying agents. Add specification description to SetNativeMethodPrefix(es). - Better define the conditions on GetConstantPool. + Better define the conditions on GetConstantPool. Break out the GetClassVersionNumber function from GetConstantPool. - Clean-up the references to the VM Spec. + Clean-up the references to the VM Spec. Allow SetNativeMethodPrefix(es) in any phase. - Add clarifications about the impact of redefinition on GetConstantPool. + Add clarifications about the impact of redefinition on GetConstantPool. Various clarifications to SetNativeMethodPrefix(es). @@ -14588,7 +14655,7 @@ typedef void (JNICALL *jvmtiEventVMInit) Add . Revamp the bytecode instrumentation documentation. - Change to no longer + Change to no longer require the can_redefine_classes capability. @@ -14601,7 +14668,7 @@ typedef void (JNICALL *jvmtiEventVMInit) Add new heap functionity which supports reporting primitive values, allows setting the referrer tag, and has more powerful filtering: - FollowReferences, IterateThroughHeap, and their associated + FollowReferences, IterateThroughHeap, and their associated callbacks, structs, enums, and constants. @@ -14670,10 +14737,10 @@ typedef void (JNICALL *jvmtiEventVMInit) Better phrasing. - Match the referrer_index for static fields in Object Reference Callback + Match the referrer_index for static fields in Object Reference Callback with the Reference Implementation (and all other known implementations); that is, make it match the definition for instance fields. - In GetThreadListStackTraces, add JVMTI_ERROR_INVALID_THREAD to cover + In GetThreadListStackTraces, add JVMTI_ERROR_INVALID_THREAD to cover an invalid thread in the list; and specify that not started threads return empty stacks. @@ -14689,10 +14756,10 @@ typedef void (JNICALL *jvmtiEventVMInit) Changed spec to return -1 for monitor stack depth for the - implementation which can not determine stack depth. + implementation which can not determine stack depth. - Corrections for readability and accuracy courtesy of Alan Pratt of IBM. + Corrections for readability and accuracy courtesy of Alan Pratt of IBM. List the object relationships reported in FollowReferences. @@ -14732,9 +14799,15 @@ typedef void (JNICALL *jvmtiEventVMInit) - Add new functions: - GetAllModules - AddModuleReads, AddModuleExports, AddModuleOpens, AddModuleUses, AddModuleProvides + - IsModifiableModule Clarified can_redefine_any_classes, can_retransform_any_classes and IsModifiableClass API to disallow some implementation defined classes. + + Minor update for GetCurrentThread function: + - The function may return NULL in the start phase if the + can_generate_early_vmstart capability is enabled. + diff --git a/hotspot/src/share/vm/prims/jvmtiEnv.cpp b/hotspot/src/share/vm/prims/jvmtiEnv.cpp index f9dc315a552..491eeddd1d5 100644 --- a/hotspot/src/share/vm/prims/jvmtiEnv.cpp +++ b/hotspot/src/share/vm/prims/jvmtiEnv.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -235,12 +235,12 @@ JvmtiEnv::AddModuleReads(jobject module, jobject to_module) { // check module Handle h_module(THREAD, JNIHandles::resolve(module)); - if (!java_lang_reflect_Module::is_instance(h_module())) { + if (!java_lang_Module::is_instance(h_module())) { return JVMTI_ERROR_INVALID_MODULE; } // check to_module Handle h_to_module(THREAD, JNIHandles::resolve(to_module)); - if (!java_lang_reflect_Module::is_instance(h_to_module())) { + if (!java_lang_Module::is_instance(h_to_module())) { return JVMTI_ERROR_INVALID_MODULE; } return JvmtiExport::add_module_reads(h_module, h_to_module, THREAD); @@ -257,12 +257,12 @@ JvmtiEnv::AddModuleExports(jobject module, const char* pkg_name, jobject to_modu // check module Handle h_module(THREAD, JNIHandles::resolve(module)); - if (!java_lang_reflect_Module::is_instance(h_module())) { + if (!java_lang_Module::is_instance(h_module())) { return JVMTI_ERROR_INVALID_MODULE; } // check to_module Handle h_to_module(THREAD, JNIHandles::resolve(to_module)); - if (!java_lang_reflect_Module::is_instance(h_to_module())) { + if (!java_lang_Module::is_instance(h_to_module())) { return JVMTI_ERROR_INVALID_MODULE; } return JvmtiExport::add_module_exports(h_module, h_pkg, h_to_module, THREAD); @@ -279,12 +279,12 @@ JvmtiEnv::AddModuleOpens(jobject module, const char* pkg_name, jobject to_module // check module Handle h_module(THREAD, JNIHandles::resolve(module)); - if (!java_lang_reflect_Module::is_instance(h_module())) { + if (!java_lang_Module::is_instance(h_module())) { return JVMTI_ERROR_INVALID_MODULE; } // check to_module Handle h_to_module(THREAD, JNIHandles::resolve(to_module)); - if (!java_lang_reflect_Module::is_instance(h_to_module())) { + if (!java_lang_Module::is_instance(h_to_module())) { return JVMTI_ERROR_INVALID_MODULE; } return JvmtiExport::add_module_opens(h_module, h_pkg, h_to_module, THREAD); @@ -299,7 +299,7 @@ JvmtiEnv::AddModuleUses(jobject module, jclass service) { // check module Handle h_module(THREAD, JNIHandles::resolve(module)); - if (!java_lang_reflect_Module::is_instance(h_module())) { + if (!java_lang_Module::is_instance(h_module())) { return JVMTI_ERROR_INVALID_MODULE; } // check service @@ -321,7 +321,7 @@ JvmtiEnv::AddModuleProvides(jobject module, jclass service, jclass impl_class) { // check module Handle h_module(THREAD, JNIHandles::resolve(module)); - if (!java_lang_reflect_Module::is_instance(h_module())) { + if (!java_lang_Module::is_instance(h_module())) { return JVMTI_ERROR_INVALID_MODULE; } // check service @@ -339,6 +339,22 @@ JvmtiEnv::AddModuleProvides(jobject module, jclass service, jclass impl_class) { return JvmtiExport::add_module_provides(h_module, h_service, h_impl_class, THREAD); } /* end AddModuleProvides */ +// module - pre-checked for NULL +// is_modifiable_class_ptr - pre-checked for NULL +jvmtiError +JvmtiEnv::IsModifiableModule(jobject module, jboolean* is_modifiable_module_ptr) { + JavaThread* THREAD = JavaThread::current(); + + // check module + Handle h_module(THREAD, JNIHandles::resolve(module)); + if (!java_lang_Module::is_instance(h_module())) { + return JVMTI_ERROR_INVALID_MODULE; + } + + *is_modifiable_module_ptr = JNI_TRUE; + return JVMTI_ERROR_NONE; +} /* end IsModifiableModule */ + // // Class functions @@ -1796,6 +1812,13 @@ JvmtiEnv::FollowReferences(jint heap_filter, jclass klass, jobject initial_objec } } + if (initial_object != NULL) { + oop init_obj = JNIHandles::resolve_external_guard(initial_object); + if (init_obj == NULL) { + return JVMTI_ERROR_INVALID_OBJECT; + } + } + Thread *thread = Thread::current(); HandleMark hm(thread); KlassHandle kh (thread, k_oop); diff --git a/hotspot/src/share/vm/prims/jvmtiExport.cpp b/hotspot/src/share/vm/prims/jvmtiExport.cpp index 52350da0cde..8ac9e1bc822 100644 --- a/hotspot/src/share/vm/prims/jvmtiExport.cpp +++ b/hotspot/src/share/vm/prims/jvmtiExport.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -54,7 +54,6 @@ #include "runtime/os.inline.hpp" #include "runtime/thread.inline.hpp" #include "runtime/vframe.hpp" -#include "services/attachListener.hpp" #include "services/serviceUtil.hpp" #include "utilities/macros.hpp" #if INCLUDE_ALL_GCS @@ -1230,8 +1229,12 @@ void JvmtiExport::post_class_unload(Klass* klass) { assert(thread->is_VM_thread(), "wrong thread"); // get JavaThread for whom we are proxy - JavaThread *real_thread = - (JavaThread *)((VMThread *)thread)->vm_operation()->calling_thread(); + Thread *calling_thread = ((VMThread *)thread)->vm_operation()->calling_thread(); + if (!calling_thread->is_Java_thread()) { + // cannot post an event to a non-JavaThread + return; + } + JavaThread *real_thread = (JavaThread *)calling_thread; JvmtiEnvIterator it; for (JvmtiEnv* env = it.first(); env != NULL; env = it.next(env)) { @@ -2475,15 +2478,6 @@ extern "C" { typedef jint (JNICALL *OnAttachEntry_t)(JavaVM*, char *, void *); } -jint JvmtiExport::load_agent_library(AttachOperation* op, outputStream* st) { - // get agent name and options - const char* agent = op->arg(0); - const char* absParam = op->arg(1); - const char* options = op->arg(2); - - return load_agent_library(agent, absParam, options, st); -} - jint JvmtiExport::load_agent_library(const char *agent, const char *absParam, const char *options, outputStream* st) { char ebuf[1024]; diff --git a/hotspot/src/share/vm/prims/jvmtiExport.hpp b/hotspot/src/share/vm/prims/jvmtiExport.hpp index 8599656ab7d..666ab62709b 100644 --- a/hotspot/src/share/vm/prims/jvmtiExport.hpp +++ b/hotspot/src/share/vm/prims/jvmtiExport.hpp @@ -45,7 +45,6 @@ class JvmtiEventControllerPrivate; class JvmtiManageCapabilities; class JvmtiEnv; class JvmtiThreadState; -class AttachOperation; #define JVMTI_SUPPORT_FLAG(key) \ private: \ @@ -396,7 +395,6 @@ class JvmtiExport : public AllStatic { #if INCLUDE_SERVICES // attach support static jint load_agent_library(const char *agent, const char *absParam, const char *options, outputStream* out) NOT_JVMTI_RETURN_(JNI_ERR); - static jint load_agent_library(AttachOperation* op, outputStream* out) NOT_JVMTI_RETURN_(JNI_ERR); #endif // SetNativeMethodPrefix support diff --git a/hotspot/src/share/vm/prims/jvmtiTagMap.cpp b/hotspot/src/share/vm/prims/jvmtiTagMap.cpp index b2cf5660865..e90420d03b8 100644 --- a/hotspot/src/share/vm/prims/jvmtiTagMap.cpp +++ b/hotspot/src/share/vm/prims/jvmtiTagMap.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -51,6 +51,7 @@ #include "services/serviceUtil.hpp" #include "utilities/macros.hpp" #if INCLUDE_ALL_GCS +#include "gc/g1/g1SATBCardTableModRefBS.hpp" #include "gc/parallel/parallelScavengeHeap.hpp" #endif // INCLUDE_ALL_GCS @@ -1534,6 +1535,14 @@ class TagObjectCollector : public JvmtiTagHashmapEntryClosure { if (_tags[i] == entry->tag()) { oop o = entry->object(); assert(o != NULL && Universe::heap()->is_in_reserved(o), "sanity check"); +#if INCLUDE_ALL_GCS + if (UseG1GC) { + // The reference in this tag map could be the only (implicitly weak) + // reference to that object. If we hand it out, we need to keep it live wrt + // SATB marking similar to other j.l.ref.Reference referents. + G1SATBCardTableModRefBS::enqueue(o); + } +#endif jobject ref = JNIHandles::make_local(JavaThread::current(), o); _object_results->append(ref); _tag_results->append((uint64_t)entry->tag()); diff --git a/hotspot/src/share/vm/prims/methodHandles.cpp b/hotspot/src/share/vm/prims/methodHandles.cpp index 717c1fe00ad..1ddc306d4a0 100644 --- a/hotspot/src/share/vm/prims/methodHandles.cpp +++ b/hotspot/src/share/vm/prims/methodHandles.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -176,7 +176,7 @@ oop MethodHandles::init_MemberName(Handle mname, Handle target) { return NULL; } -oop MethodHandles::init_method_MemberName(Handle mname, CallInfo& info) { +oop MethodHandles::init_method_MemberName(Handle mname, CallInfo& info, bool intern) { assert(info.resolved_appendix().is_null(), "only normal methods here"); methodHandle m = info.resolved_method(); assert(m.not_null(), "null method handle"); @@ -277,13 +277,7 @@ oop MethodHandles::init_method_MemberName(Handle mname, CallInfo& info) { // If relevant, the vtable or itable value is stored as vmindex. // This is done eagerly, since it is readily available without // constructing any new objects. - // TO DO: maybe intern mname_oop - if (m->method_holder()->add_member_name(mname)) { - return mname(); - } else { - // Redefinition caused this to fail. Return NULL (and an exception?) - return NULL; - } + return m->method_holder()->add_member_name(mname, intern); } oop MethodHandles::init_field_MemberName(Handle mname, fieldDescriptor& fd, bool is_setter) { @@ -733,7 +727,7 @@ Handle MethodHandles::resolve_MemberName(Handle mname, KlassHandle caller, TRAPS assert(!is_signature_polymorphic_static(mh_invoke_id), ""); LinkResolver::resolve_handle_call(result, link_info, THREAD); } else if (ref_kind == JVM_REF_invokeSpecial) { - LinkResolver::resolve_special_call(result, + LinkResolver::resolve_special_call(result, Handle(), link_info, THREAD); } else if (ref_kind == JVM_REF_invokeVirtual) { LinkResolver::resolve_virtual_call(result, Handle(), defc, @@ -761,7 +755,7 @@ Handle MethodHandles::resolve_MemberName(Handle mname, KlassHandle caller, TRAPS { assert(!HAS_PENDING_EXCEPTION, ""); if (name == vmSymbols::object_initializer_name()) { - LinkResolver::resolve_special_call(result, link_info, THREAD); + LinkResolver::resolve_special_call(result, Handle(), link_info, THREAD); } else { break; // will throw after end of switch } @@ -973,7 +967,9 @@ int MethodHandles::find_MemberNames(KlassHandle k, if (!java_lang_invoke_MemberName::is_instance(result())) return -99; // caller bug! CallInfo info(m); - oop saved = MethodHandles::init_method_MemberName(result, info); + // Since this is going through the methods to create MemberNames, don't search + // for matching methods already in the table + oop saved = MethodHandles::init_method_MemberName(result, info, /*intern*/false); if (saved != result()) results->obj_at_put(rfill-1, saved); // show saved instance to user } else if (++overflow >= overflow_limit) { @@ -1054,9 +1050,34 @@ MemberNameTable::~MemberNameTable() { } } -void MemberNameTable::add_member_name(jweak mem_name_wref) { +oop MemberNameTable::add_member_name(jweak mem_name_wref) { assert_locked_or_safepoint(MemberNameTable_lock); this->push(mem_name_wref); + return JNIHandles::resolve(mem_name_wref); +} + +oop MemberNameTable::find_or_add_member_name(jweak mem_name_wref) { + assert_locked_or_safepoint(MemberNameTable_lock); + oop new_mem_name = JNIHandles::resolve(mem_name_wref); + + // Find matching member name in the list. + // This is linear because these are short lists. + int len = this->length(); + int new_index = len; + for (int idx = 0; idx < len; idx++) { + oop mname = JNIHandles::resolve(this->at(idx)); + if (mname == NULL) { + new_index = idx; + continue; + } + if (java_lang_invoke_MemberName::equals(new_mem_name, mname)) { + JNIHandles::destroy_weak_global(mem_name_wref); + return mname; + } + } + // Not found, push the new one, or reuse empty slot + this->at_put_grow(new_index, mem_name_wref); + return new_mem_name; } #if INCLUDE_JVMTI @@ -1208,9 +1229,10 @@ JVM_ENTRY(jobject, MHN_resolve_Mem(JNIEnv *env, jobject igcls, jobject mname_jh, if (reference_klass != NULL && reference_klass->is_instance_klass()) { // Emulate LinkResolver::check_klass_accessability. Klass* caller = java_lang_Class::as_Klass(JNIHandles::resolve_non_null(caller_jh)); - if (Reflection::verify_class_access(caller, - reference_klass, - true) != Reflection::ACCESS_OK) { + if (caller != SystemDictionary::Object_klass() + && Reflection::verify_class_access(caller, + reference_klass, + true) != Reflection::ACCESS_OK) { THROW_MSG_NULL(vmSymbols::java_lang_InternalError(), reference_klass->external_name()); } } diff --git a/hotspot/src/share/vm/prims/methodHandles.hpp b/hotspot/src/share/vm/prims/methodHandles.hpp index 4a825464fb8..3a5e90305fe 100644 --- a/hotspot/src/share/vm/prims/methodHandles.hpp +++ b/hotspot/src/share/vm/prims/methodHandles.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -66,7 +66,7 @@ class MethodHandles: AllStatic { static Handle new_MemberName(TRAPS); // must be followed by init_MemberName static oop init_MemberName(Handle mname_h, Handle target_h); // compute vmtarget/vmindex from target static oop init_field_MemberName(Handle mname_h, fieldDescriptor& fd, bool is_setter = false); - static oop init_method_MemberName(Handle mname_h, CallInfo& info); + static oop init_method_MemberName(Handle mname_h, CallInfo& info, bool intern = true); static int method_ref_kind(Method* m, bool do_dispatch_if_possible = true); static int find_MemberNames(KlassHandle k, Symbol* name, Symbol* sig, int mflags, KlassHandle caller, @@ -235,7 +235,8 @@ class MemberNameTable : public GrowableArray { public: MemberNameTable(int methods_cnt); ~MemberNameTable(); - void add_member_name(jweak mem_name_ref); + oop add_member_name(jweak mem_name_ref); + oop find_or_add_member_name(jweak mem_name_ref); #if INCLUDE_JVMTI // RedefineClasses() API support: diff --git a/hotspot/src/share/vm/prims/stackwalk.cpp b/hotspot/src/share/vm/prims/stackwalk.cpp index e130127318a..9e3fc9a8464 100644 --- a/hotspot/src/share/vm/prims/stackwalk.cpp +++ b/hotspot/src/share/vm/prims/stackwalk.cpp @@ -173,7 +173,11 @@ void JavaFrameStream::fill_frame(int index, objArrayHandle frames_array, } } -oop LiveFrameStream::create_primitive_value_instance(StackValueCollection* values, int i, TRAPS) { +// Create and return a LiveStackFrame.PrimitiveSlot (if needed) for the +// StackValue at the given index. 'type' is expected to be T_INT, T_LONG, +// T_OBJECT, or T_CONFLICT. +oop LiveFrameStream::create_primitive_slot_instance(StackValueCollection* values, + int i, BasicType type, TRAPS) { Klass* k = SystemDictionary::resolve_or_null(vmSymbols::java_lang_LiveStackFrameInfo(), CHECK_NULL); instanceKlassHandle ik (THREAD, k); @@ -182,8 +186,8 @@ oop LiveFrameStream::create_primitive_value_instance(StackValueCollection* value Symbol* signature = NULL; // ## TODO: type is only available in LocalVariable table, if present. - // ## StackValue type is T_INT or T_OBJECT. - switch (values->at(i)->type()) { + // ## StackValue type is T_INT or T_OBJECT (or converted to T_LONG on 64-bit) + switch (type) { case T_INT: args.push_int(values->int_at(i)); signature = vmSymbols::asPrimitive_int_signature(); @@ -195,42 +199,26 @@ oop LiveFrameStream::create_primitive_value_instance(StackValueCollection* value break; case T_FLOAT: - args.push_float(values->float_at(i)); - signature = vmSymbols::asPrimitive_float_signature(); - break; - case T_DOUBLE: - args.push_double(values->double_at(i)); - signature = vmSymbols::asPrimitive_double_signature(); - break; - case T_BYTE: - args.push_int(values->int_at(i)); - signature = vmSymbols::asPrimitive_byte_signature(); - break; - case T_SHORT: - args.push_int(values->int_at(i)); - signature = vmSymbols::asPrimitive_short_signature(); - break; - case T_CHAR: - args.push_int(values->int_at(i)); - signature = vmSymbols::asPrimitive_char_signature(); - break; - case T_BOOLEAN: - args.push_int(values->int_at(i)); - signature = vmSymbols::asPrimitive_boolean_signature(); - break; + THROW_MSG_(vmSymbols::java_lang_InternalError(), "Unexpected StackValue type", NULL); case T_OBJECT: return values->obj_at(i)(); case T_CONFLICT: // put a non-null slot - args.push_int(0); - signature = vmSymbols::asPrimitive_int_signature(); + #ifdef _LP64 + args.push_long(0); + signature = vmSymbols::asPrimitive_long_signature(); + #else + args.push_int(0); + signature = vmSymbols::asPrimitive_int_signature(); + #endif + break; default: ShouldNotReachHere(); @@ -252,9 +240,19 @@ objArrayHandle LiveFrameStream::values_to_object_array(StackValueCollection* val objArrayHandle array_h(THREAD, array_oop); for (int i = 0; i < values->size(); i++) { StackValue* st = values->at(i); - oop obj = create_primitive_value_instance(values, i, CHECK_(empty)); - if (obj != NULL) + BasicType type = st->type(); + int index = i; +#ifdef _LP64 + if (type != T_OBJECT && type != T_CONFLICT) { + intptr_t ret = st->get_int(); // read full 64-bit slot + type = T_LONG; // treat as long + index--; // undo +1 in StackValueCollection::long_at + } +#endif + oop obj = create_primitive_slot_instance(values, index, type, CHECK_(empty)); + if (obj != NULL) { array_h->obj_at_put(i, obj); + } } return array_h; } @@ -286,6 +284,13 @@ void LiveFrameStream::fill_live_stackframe(Handle stackFrame, StackValueCollection* expressions = _jvf->expressions(); GrowableArray* monitors = _jvf->monitors(); + int mode = 0; + if (_jvf->is_interpreted_frame()) { + mode = MODE_INTERPRETED; + } else if (_jvf->is_compiled_frame()) { + mode = MODE_COMPILED; + } + if (!locals->is_empty()) { objArrayHandle locals_h = values_to_object_array(locals, CHECK); java_lang_LiveStackFrameInfo::set_locals(stackFrame(), locals_h()); @@ -298,6 +303,7 @@ void LiveFrameStream::fill_live_stackframe(Handle stackFrame, objArrayHandle monitors_h = monitors_to_object_array(monitors, CHECK); java_lang_LiveStackFrameInfo::set_monitors(stackFrame(), monitors_h()); } + java_lang_LiveStackFrameInfo::set_mode(stackFrame(), mode); } } diff --git a/hotspot/src/share/vm/prims/stackwalk.hpp b/hotspot/src/share/vm/prims/stackwalk.hpp index 161a74599c3..a0c4bede64a 100644 --- a/hotspot/src/share/vm/prims/stackwalk.hpp +++ b/hotspot/src/share/vm/prims/stackwalk.hpp @@ -92,11 +92,16 @@ public: class LiveFrameStream : public BaseFrameStream { private: + enum { + MODE_INTERPRETED = 0x01, + MODE_COMPILED = 0x02 + }; + javaVFrame* _jvf; void fill_live_stackframe(Handle stackFrame, const methodHandle& method, TRAPS); - static oop create_primitive_value_instance(StackValueCollection* values, - int i, TRAPS); + static oop create_primitive_slot_instance(StackValueCollection* values, + int i, BasicType type, TRAPS); static objArrayHandle monitors_to_object_array(GrowableArray* monitors, TRAPS); static objArrayHandle values_to_object_array(StackValueCollection* values, TRAPS); diff --git a/hotspot/src/share/vm/prims/unsafe.cpp b/hotspot/src/share/vm/prims/unsafe.cpp index 1c98add775b..2f096378201 100644 --- a/hotspot/src/share/vm/prims/unsafe.cpp +++ b/hotspot/src/share/vm/prims/unsafe.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -378,7 +378,7 @@ UNSAFE_ENTRY(jobject, Unsafe_GetUncompressedObject(JNIEnv *env, jobject unsafe, // On platforms which do not support atomic compare-and-swap of jlong (8 byte) // values we have to use a lock-based scheme to enforce atomicity. This has to be // applied to all Unsafe operations that set the value of a jlong field. Even so -// the compareAndSwapLong operation will not be atomic with respect to direct stores +// the compareAndSetLong operation will not be atomic with respect to direct stores // to the field from Java code. It is important therefore that any Java code that // utilizes these Unsafe jlong operations does not perform direct stores. To permit // direct loads of the field from Java code we must also use Atomic::store within the @@ -1013,7 +1013,7 @@ UNSAFE_ENTRY(jlong, Unsafe_CompareAndExchangeLong(JNIEnv *env, jobject unsafe, j #endif } UNSAFE_END -UNSAFE_ENTRY(jboolean, Unsafe_CompareAndSwapObject(JNIEnv *env, jobject unsafe, jobject obj, jlong offset, jobject e_h, jobject x_h)) { +UNSAFE_ENTRY(jboolean, Unsafe_CompareAndSetObject(JNIEnv *env, jobject unsafe, jobject obj, jlong offset, jobject e_h, jobject x_h)) { oop x = JNIHandles::resolve(x_h); oop e = JNIHandles::resolve(e_h); oop p = JNIHandles::resolve(obj); @@ -1028,14 +1028,14 @@ UNSAFE_ENTRY(jboolean, Unsafe_CompareAndSwapObject(JNIEnv *env, jobject unsafe, return true; } UNSAFE_END -UNSAFE_ENTRY(jboolean, Unsafe_CompareAndSwapInt(JNIEnv *env, jobject unsafe, jobject obj, jlong offset, jint e, jint x)) { +UNSAFE_ENTRY(jboolean, Unsafe_CompareAndSetInt(JNIEnv *env, jobject unsafe, jobject obj, jlong offset, jint e, jint x)) { oop p = JNIHandles::resolve(obj); jint* addr = (jint *)index_oop_from_field_offset_long(p, offset); return (jint)(Atomic::cmpxchg(x, addr, e)) == e; } UNSAFE_END -UNSAFE_ENTRY(jboolean, Unsafe_CompareAndSwapLong(JNIEnv *env, jobject unsafe, jobject obj, jlong offset, jlong e, jlong x)) { +UNSAFE_ENTRY(jboolean, Unsafe_CompareAndSetLong(JNIEnv *env, jobject unsafe, jobject obj, jlong offset, jlong e, jlong x)) { Handle p(THREAD, JNIHandles::resolve(obj)); jlong* addr = (jlong*)index_oop_from_field_offset_long(p(), offset); @@ -1194,12 +1194,12 @@ static JNINativeMethod jdk_internal_misc_Unsafe_methods[] = { {CC "defineClass0", CC "(" DC_Args ")" CLS, FN_PTR(Unsafe_DefineClass0)}, {CC "allocateInstance", CC "(" CLS ")" OBJ, FN_PTR(Unsafe_AllocateInstance)}, {CC "throwException", CC "(" THR ")V", FN_PTR(Unsafe_ThrowException)}, - {CC "compareAndSwapObject", CC "(" OBJ "J" OBJ "" OBJ ")Z", FN_PTR(Unsafe_CompareAndSwapObject)}, - {CC "compareAndSwapInt", CC "(" OBJ "J""I""I"")Z", FN_PTR(Unsafe_CompareAndSwapInt)}, - {CC "compareAndSwapLong", CC "(" OBJ "J""J""J"")Z", FN_PTR(Unsafe_CompareAndSwapLong)}, - {CC "compareAndExchangeObjectVolatile", CC "(" OBJ "J" OBJ "" OBJ ")" OBJ, FN_PTR(Unsafe_CompareAndExchangeObject)}, - {CC "compareAndExchangeIntVolatile", CC "(" OBJ "J""I""I"")I", FN_PTR(Unsafe_CompareAndExchangeInt)}, - {CC "compareAndExchangeLongVolatile", CC "(" OBJ "J""J""J"")J", FN_PTR(Unsafe_CompareAndExchangeLong)}, + {CC "compareAndSetObject",CC "(" OBJ "J" OBJ "" OBJ ")Z", FN_PTR(Unsafe_CompareAndSetObject)}, + {CC "compareAndSetInt", CC "(" OBJ "J""I""I"")Z", FN_PTR(Unsafe_CompareAndSetInt)}, + {CC "compareAndSetLong", CC "(" OBJ "J""J""J"")Z", FN_PTR(Unsafe_CompareAndSetLong)}, + {CC "compareAndExchangeObject", CC "(" OBJ "J" OBJ "" OBJ ")" OBJ, FN_PTR(Unsafe_CompareAndExchangeObject)}, + {CC "compareAndExchangeInt", CC "(" OBJ "J""I""I"")I", FN_PTR(Unsafe_CompareAndExchangeInt)}, + {CC "compareAndExchangeLong", CC "(" OBJ "J""J""J"")J", FN_PTR(Unsafe_CompareAndExchangeLong)}, {CC "park", CC "(ZJ)V", FN_PTR(Unsafe_Park)}, {CC "unpark", CC "(" OBJ ")V", FN_PTR(Unsafe_Unpark)}, diff --git a/hotspot/src/share/vm/runtime/arguments.cpp b/hotspot/src/share/vm/runtime/arguments.cpp index b57cb96839f..7149c1a6094 100644 --- a/hotspot/src/share/vm/runtime/arguments.cpp +++ b/hotspot/src/share/vm/runtime/arguments.cpp @@ -375,53 +375,18 @@ static SpecialFlag const special_jvm_flags[] = { // -------------- Deprecated Flags -------------- // --- Non-alias flags - sorted by obsolete_in then expired_in: { "MaxGCMinorPauseMillis", JDK_Version::jdk(8), JDK_Version::undefined(), JDK_Version::undefined() }, - { "AutoGCSelectPauseMillis", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, - { "UseAutoGCSelectPolicy", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, - { "UseParNewGC", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, - { "ExplicitGCInvokesConcurrentAndUnloadsClasses", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, - { "ConvertSleepToYield", JDK_Version::jdk(9), JDK_Version::jdk(10), JDK_Version::jdk(11) }, - { "ConvertYieldToSleep", JDK_Version::jdk(9), JDK_Version::jdk(10), JDK_Version::jdk(11) }, + { "UseConcMarkSweepGC", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::undefined() }, // --- Deprecated alias flags (see also aliased_jvm_flags) - sorted by obsolete_in then expired_in: { "DefaultMaxRAMFraction", JDK_Version::jdk(8), JDK_Version::undefined(), JDK_Version::undefined() }, { "CreateMinidumpOnCrash", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::undefined() }, - { "CMSMarkStackSizeMax", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, - { "CMSMarkStackSize", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, - { "G1MarkStackSize", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, - { "ParallelMarkingThreads", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, - { "ParallelCMSThreads", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::jdk(10) }, // -------------- Obsolete Flags - sorted by expired_in -------------- - { "UseOldInlining", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "SafepointPollOffset", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "UseBoundThreads", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "DefaultThreadPriority", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "NoYieldsInMicrolock", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "BackEdgeThreshold", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "UseNewReflection", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "ReflectionWrapResolutionErrors",JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "VerifyReflectionBytecodes", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "AutoShutdownNMT", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "NmethodSweepFraction", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "NmethodSweepCheckInterval", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "CodeCacheMinimumFreeSpace", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, -#ifndef ZERO - { "UseFastAccessorMethods", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "UseFastEmptyMethods", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, -#endif // ZERO - { "UseCompilerSafepoints", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "AdaptiveSizePausePolicy", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "ParallelGCRetainPLAB", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "ThreadSafetyMargin", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "LazyBootClassLoader", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "StarvationMonitorInterval", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "PreInflateSpin", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "JNIDetachReleasesMonitors", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "UseAltSigs", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "SegmentedHeapDumpThreshold", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "PrintOopAddress", JDK_Version::undefined(), JDK_Version::jdk(9), JDK_Version::jdk(10) }, - { "PermSize", JDK_Version::undefined(), JDK_Version::jdk(8), JDK_Version::jdk(10) }, - { "MaxPermSize", JDK_Version::undefined(), JDK_Version::jdk(8), JDK_Version::jdk(10) }, + { "ConvertSleepToYield", JDK_Version::jdk(9), JDK_Version::jdk(10), JDK_Version::jdk(11) }, + { "ConvertYieldToSleep", JDK_Version::jdk(9), JDK_Version::jdk(10), JDK_Version::jdk(11) }, + { "MinSleepInterval", JDK_Version::jdk(9), JDK_Version::jdk(10), JDK_Version::jdk(11) }, + { "PermSize", JDK_Version::undefined(), JDK_Version::jdk(8), JDK_Version::undefined() }, + { "MaxPermSize", JDK_Version::undefined(), JDK_Version::jdk(8), JDK_Version::undefined() }, #ifdef TEST_VERIFY_SPECIAL_JVM_FLAGS { "dep > obs", JDK_Version::jdk(9), JDK_Version::jdk(8), JDK_Version::undefined() }, @@ -444,11 +409,6 @@ typedef struct { static AliasedFlag const aliased_jvm_flags[] = { { "DefaultMaxRAMFraction", "MaxRAMFraction" }, - { "CMSMarkStackSizeMax", "MarkStackSizeMax" }, - { "CMSMarkStackSize", "MarkStackSize" }, - { "G1MarkStackSize", "MarkStackSize" }, - { "ParallelMarkingThreads", "ConcGCThreads" }, - { "ParallelCMSThreads", "ConcGCThreads" }, { "CreateMinidumpOnCrash", "CreateCoredumpOnCrash" }, { NULL, NULL} }; @@ -1547,7 +1507,6 @@ void Arguments::set_parnew_gc_flags() { assert(!UseSerialGC && !UseParallelOldGC && !UseParallelGC && !UseG1GC, "control point invariant"); assert(UseConcMarkSweepGC, "CMS is expected to be on here"); - assert(UseParNewGC, "ParNew should always be used with CMS"); if (FLAG_IS_DEFAULT(ParallelGCThreads)) { FLAG_SET_DEFAULT(ParallelGCThreads, Abstract_VM_Version::parallel_worker_threads()); @@ -1588,7 +1547,6 @@ void Arguments::set_parnew_gc_flags() { void Arguments::set_cms_and_parnew_gc_flags() { assert(!UseSerialGC && !UseParallelOldGC && !UseParallelGC, "Error"); assert(UseConcMarkSweepGC, "CMS is expected to be on here"); - assert(UseParNewGC, "ParNew should always be used with CMS"); // Turn off AdaptiveSizePolicy by default for cms until it is complete. disable_adaptive_size_policy("UseConcMarkSweepGC"); @@ -1728,16 +1686,6 @@ size_t Arguments::max_heap_for_compressed_oops() { NOT_LP64(ShouldNotReachHere(); return 0); } -bool Arguments::should_auto_select_low_pause_collector() { - if (UseAutoGCSelectPolicy && - !FLAG_IS_DEFAULT(MaxGCPauseMillis) && - (MaxGCPauseMillis <= AutoGCSelectPauseMillis)) { - log_trace(gc)("Automatic selection of the low pause collector based on pause goal of %d (ms)", (int) MaxGCPauseMillis); - return true; - } - return false; -} - void Arguments::set_use_compressed_oops() { #ifndef ZERO #ifdef _LP64 @@ -1841,16 +1789,7 @@ void Arguments::select_compilation_mode_ergonomically() { void Arguments::select_gc_ergonomically() { #if INCLUDE_ALL_GCS if (os::is_server_class_machine()) { - if (!UseAutoGCSelectPolicy) { - FLAG_SET_ERGO_IF_DEFAULT(bool, UseG1GC, true); - } else { - if (should_auto_select_low_pause_collector()) { - FLAG_SET_ERGO_IF_DEFAULT(bool, UseConcMarkSweepGC, true); - FLAG_SET_ERGO_IF_DEFAULT(bool, UseParNewGC, true); - } else { - FLAG_SET_ERGO_IF_DEFAULT(bool, UseParallelGC, true); - } - } + FLAG_SET_ERGO_IF_DEFAULT(bool, UseG1GC, true); } else { FLAG_SET_ERGO_IF_DEFAULT(bool, UseSerialGC, true); } @@ -1859,7 +1798,6 @@ void Arguments::select_gc_ergonomically() { UNSUPPORTED_OPTION(UseParallelGC); UNSUPPORTED_OPTION(UseParallelOldGC); UNSUPPORTED_OPTION(UseConcMarkSweepGC); - UNSUPPORTED_OPTION(UseParNewGC); FLAG_SET_ERGO_IF_DEFAULT(bool, UseSerialGC, true); #endif // INCLUDE_ALL_GCS } @@ -1894,6 +1832,11 @@ void Arguments::set_jvmci_specific_flags() { if (FLAG_IS_DEFAULT(NewSizeThreadIncrease)) { FLAG_SET_DEFAULT(NewSizeThreadIncrease, 4*K); } + if (TieredStopAtLevel != CompLevel_full_optimization) { + // Currently JVMCI compiler can only work at the full optimization level + warning("forcing TieredStopAtLevel to full optimization because JVMCI is enabled"); + TieredStopAtLevel = CompLevel_full_optimization; + } if (FLAG_IS_DEFAULT(TypeProfileLevel)) { FLAG_SET_DEFAULT(TypeProfileLevel, 0); } @@ -2073,7 +2016,6 @@ void Arguments::set_gc_specific_flags() { if (!ClassUnloading) { FLAG_SET_CMDLINE(bool, CMSClassUnloadingEnabled, false); FLAG_SET_CMDLINE(bool, ClassUnloadingWithConcurrentMark, false); - FLAG_SET_CMDLINE(bool, ExplicitGCInvokesConcurrentAndUnloadsClasses, false); } #endif // INCLUDE_ALL_GCS } @@ -2299,8 +2241,6 @@ jint Arguments::set_aggressive_heap_flags() { if (FLAG_SET_CMDLINE(bool, UseParallelGC, true) != Flag::SUCCESS) { return JNI_EINVAL; } - FLAG_SET_DEFAULT(ParallelGCThreads, - Abstract_VM_Version::parallel_worker_threads()); // Encourage steady state memory management if (FLAG_SET_CMDLINE(uintx, ThresholdTolerance, 100) != Flag::SUCCESS) { @@ -2428,18 +2368,6 @@ bool Arguments::check_gc_consistency() { return false; } - if (UseConcMarkSweepGC && !UseParNewGC) { - jio_fprintf(defaultStream::error_stream(), - "It is not possible to combine the DefNew young collector with the CMS collector.\n"); - return false; - } - - if (UseParNewGC && !UseConcMarkSweepGC) { - jio_fprintf(defaultStream::error_stream(), - "It is not possible to combine the ParNew young collector with any collector other than CMS.\n"); - return false; - } - return true; } @@ -2506,11 +2434,14 @@ bool Arguments::check_vm_args_consistency() { } #endif } -#if INCLUDE_JVMCI +#if INCLUDE_JVMCI status = status && check_jvmci_args_consistency(); if (EnableJVMCI) { + PropertyList_unique_add(&_system_properties, "jdk.internal.vm.ci.enabled", "true", + AddProperty, UnwriteableProperty, InternalProperty); + if (!ScavengeRootsInCode) { warning("forcing ScavengeRootsInCode non-zero because JVMCI is enabled"); ScavengeRootsInCode = 1; @@ -2831,11 +2762,14 @@ jint Arguments::parse_each_vm_init_arg(const JavaVMInitArgs* args, bool* patch_m build_jvm_args(option->optionString); } - // -verbose:[class/gc/jni] + // -verbose:[class/module/gc/jni] if (match_option(option, "-verbose", &tail)) { if (!strcmp(tail, ":class") || !strcmp(tail, "")) { LogConfiguration::configure_stdout(LogLevel::Info, true, LOG_TAGS(class, load)); LogConfiguration::configure_stdout(LogLevel::Info, true, LOG_TAGS(class, unload)); + } else if (!strcmp(tail, ":module")) { + LogConfiguration::configure_stdout(LogLevel::Info, true, LOG_TAGS(module, load)); + LogConfiguration::configure_stdout(LogLevel::Info, true, LOG_TAGS(module, unload)); } else if (!strcmp(tail, ":gc")) { LogConfiguration::configure_stdout(LogLevel::Info, true, LOG_TAGS(gc)); } else if (!strcmp(tail, ":jni")) { @@ -2927,6 +2861,10 @@ jint Arguments::parse_each_vm_init_arg(const JavaVMInitArgs* args, bool* patch_m if (res != JNI_OK) { return res; } + } else if (match_option(option, "--permit-illegal-access")) { + if (!create_property("jdk.module.permitIllegalAccess", "true", ExternalProperty)) { + return JNI_ENOMEM; + } // -agentlib and -agentpath } else if (match_option(option, "-agentlib:", &tail) || (is_absolute_path = match_option(option, "-agentpath:", &tail))) { @@ -3169,6 +3107,7 @@ jint Arguments::parse_each_vm_init_arg(const JavaVMInitArgs* args, bool* patch_m // -Xprof } else if (match_option(option, "-Xprof")) { #if INCLUDE_FPROF + log_warning(arguments)("Option -Xprof was deprecated in version 9 and will likely be removed in a future release."); _has_profile = true; #else // INCLUDE_FPROF jio_fprintf(defaultStream::error_stream(), @@ -3700,7 +3639,7 @@ jint Arguments::finalize_vm_init_args() { #if INCLUDE_JVMCI if (EnableJVMCI && - !create_numbered_property("jdk.module.addmods", "jdk.vm.ci", addmods_count++)) { + !create_numbered_property("jdk.module.addmods", "jdk.internal.vm.ci", addmods_count++)) { return JNI_ENOMEM; } #endif @@ -3726,11 +3665,6 @@ jint Arguments::finalize_vm_init_args() { } } - if (UseConcMarkSweepGC && FLAG_IS_DEFAULT(UseParNewGC) && !UseParNewGC) { - // CMS can only be used with ParNew - FLAG_SET_ERGO(bool, UseParNewGC, true); - } - if (!check_vm_args_consistency()) { return JNI_ERR; } diff --git a/hotspot/src/share/vm/runtime/arguments.hpp b/hotspot/src/share/vm/runtime/arguments.hpp index daa91c22bd7..ad2178d7d20 100644 --- a/hotspot/src/share/vm/runtime/arguments.hpp +++ b/hotspot/src/share/vm/runtime/arguments.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -480,9 +480,6 @@ class Arguments : AllStatic { static julong limit_by_allocatable_memory(julong size); // Setup heap size static void set_heap_size(); - // Based on automatic selection criteria, should the - // low pause collector be used. - static bool should_auto_select_low_pause_collector(); // Bytecode rewriting static void set_bytecode_flags(); diff --git a/hotspot/src/share/vm/runtime/commandLineFlagConstraintsRuntime.cpp b/hotspot/src/share/vm/runtime/commandLineFlagConstraintsRuntime.cpp index abcf73ca3a7..9911ffb4e9e 100644 --- a/hotspot/src/share/vm/runtime/commandLineFlagConstraintsRuntime.cpp +++ b/hotspot/src/share/vm/runtime/commandLineFlagConstraintsRuntime.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/hotspot/src/share/vm/runtime/commandLineFlagConstraintsRuntime.hpp b/hotspot/src/share/vm/runtime/commandLineFlagConstraintsRuntime.hpp index 3bfb2825b74..776685ee95b 100644 --- a/hotspot/src/share/vm/runtime/commandLineFlagConstraintsRuntime.hpp +++ b/hotspot/src/share/vm/runtime/commandLineFlagConstraintsRuntime.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/hotspot/src/share/vm/runtime/deoptimization.cpp b/hotspot/src/share/vm/runtime/deoptimization.cpp index e3b88640768..cebdcfc9124 100644 --- a/hotspot/src/share/vm/runtime/deoptimization.cpp +++ b/hotspot/src/share/vm/runtime/deoptimization.cpp @@ -189,19 +189,6 @@ Deoptimization::UnrollBlock* Deoptimization::fetch_unroll_info_helper(JavaThread assert(vf->is_compiled_frame(), "Wrong frame type"); chunk->push(compiledVFrame::cast(vf)); - ScopeDesc* trap_scope = chunk->at(0)->scope(); - Handle exceptionObject; - if (trap_scope->rethrow_exception()) { - if (PrintDeoptimizationDetails) { - tty->print_cr("Exception to be rethrown in the interpreter for method %s::%s at bci %d", trap_scope->method()->method_holder()->name()->as_C_string(), trap_scope->method()->name()->as_C_string(), trap_scope->bci()); - } - GrowableArray* expressions = trap_scope->expressions(); - guarantee(expressions != NULL && expressions->length() > 0, "must have exception to throw"); - ScopeValue* topOfStack = expressions->top(); - exceptionObject = StackValue::create_stack_value(&deoptee, &map, topOfStack)->get_obj(); - assert(exceptionObject() != NULL, "exception oop can not be null"); - } - bool realloc_failures = false; #if defined(COMPILER2) || INCLUDE_JVMCI @@ -221,8 +208,9 @@ Deoptimization::UnrollBlock* Deoptimization::fetch_unroll_info_helper(JavaThread // It is not guaranteed that we can get such information here only // by analyzing bytecode in deoptimized frames. This is why this flag // is set during method compilation (see Compile::Process_OopMap_Node()). - // If the previous frame was popped, we don't have a result. - bool save_oop_result = chunk->at(0)->scope()->return_oop() && !thread->popframe_forcing_deopt_reexecution(); + // If the previous frame was popped or if we are dispatching an exception, + // we don't have an oop result. + bool save_oop_result = chunk->at(0)->scope()->return_oop() && !thread->popframe_forcing_deopt_reexecution() && (exec_mode == Unpack_deopt); Handle return_value; if (save_oop_result) { // Reallocation may trigger GC. If deoptimization happened on return from @@ -295,6 +283,19 @@ Deoptimization::UnrollBlock* Deoptimization::fetch_unroll_info_helper(JavaThread #endif // INCLUDE_JVMCI #endif // COMPILER2 || INCLUDE_JVMCI + ScopeDesc* trap_scope = chunk->at(0)->scope(); + Handle exceptionObject; + if (trap_scope->rethrow_exception()) { + if (PrintDeoptimizationDetails) { + tty->print_cr("Exception to be rethrown in the interpreter for method %s::%s at bci %d", trap_scope->method()->method_holder()->name()->as_C_string(), trap_scope->method()->name()->as_C_string(), trap_scope->bci()); + } + GrowableArray* expressions = trap_scope->expressions(); + guarantee(expressions != NULL && expressions->length() > 0, "must have exception to throw"); + ScopeValue* topOfStack = expressions->top(); + exceptionObject = StackValue::create_stack_value(&deoptee, &map, topOfStack)->get_obj(); + guarantee(exceptionObject() != NULL, "exception oop can not be null"); + } + // Ensure that no safepoint is taken after pointers have been stored // in fields of rematerialized objects. If a safepoint occurs from here on // out the java state residing in the vframeArray will be missed. @@ -1596,9 +1597,9 @@ JRT_ENTRY(void, Deoptimization::uncommon_trap_inner(JavaThread* thread, jint tra get_method_data(thread, profiled_method, create_if_missing); // Log a message - Events::log_deopt_message(thread, "Uncommon trap: reason=%s action=%s pc=" INTPTR_FORMAT " method=%s @ %d", + Events::log_deopt_message(thread, "Uncommon trap: reason=%s action=%s pc=" INTPTR_FORMAT " method=%s @ %d %s", trap_reason_name(reason), trap_action_name(action), p2i(fr.pc()), - trap_method->name_and_sig_as_C_string(), trap_bci); + trap_method->name_and_sig_as_C_string(), trap_bci, nm->compiler_name()); // Print a bunch of diagnostics, if requested. if (TraceDeoptimization || LogCompilation) { @@ -1812,7 +1813,7 @@ JRT_ENTRY(void, Deoptimization::uncommon_trap_inner(JavaThread* thread, jint tra // aggressive optimization. bool inc_recompile_count = false; ProfileData* pdata = NULL; - if (ProfileTraps && update_trap_state && trap_mdo != NULL) { + if (ProfileTraps && !is_client_compilation_mode_vm() && update_trap_state && trap_mdo != NULL) { assert(trap_mdo == get_method_data(thread, profiled_method, false), "sanity"); uint this_trap_count = 0; bool maybe_prior_trap = false; diff --git a/hotspot/src/share/vm/runtime/globals.hpp b/hotspot/src/share/vm/runtime/globals.hpp index 90b274e58a2..5cfe9717128 100644 --- a/hotspot/src/share/vm/runtime/globals.hpp +++ b/hotspot/src/share/vm/runtime/globals.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -657,14 +657,13 @@ public: range(0, 99) \ \ product(bool, UseAES, false, \ - "Control whether AES instructions can be used on x86/x64") \ + "Control whether AES instructions are used when available") \ \ product(bool, UseFMA, false, \ - "Control whether FMA instructions can be used") \ + "Control whether FMA instructions are used when available") \ \ product(bool, UseSHA, false, \ - "Control whether SHA instructions can be used " \ - "on SPARC, on ARM and on x86") \ + "Control whether SHA instructions are used when available") \ \ diagnostic(bool, UseGHASHIntrinsics, false, \ "Use intrinsics for GHASH versions of crypto") \ @@ -1159,13 +1158,6 @@ public: product_pd(bool, DontYieldALot, \ "Throw away obvious excess yield calls") \ \ - product(bool, ConvertSleepToYield, true, \ - "Convert sleep(0) to thread yield ") \ - \ - product(bool, ConvertYieldToSleep, false, \ - "Convert yield to a sleep of MinSleepInterval to simulate Win32 " \ - "behavior") \ - \ develop(bool, UseDetachedThreads, true, \ "Use detached threads that are recycled upon termination " \ "(for Solaris only)") \ @@ -1458,9 +1450,9 @@ public: "Number of threads concurrent gc will use") \ constraint(ConcGCThreadsConstraintFunc,AfterErgo) \ \ - product(uintx, GCTaskTimeStampEntries, 200, \ + product(uint, GCTaskTimeStampEntries, 200, \ "Number of time stamp entries per gc worker thread") \ - range(1, max_uintx) \ + range(1, max_jint) \ \ product(bool, AlwaysTenure, false, \ "Always tenure objects in eden (ParallelGC only)") \ @@ -1479,11 +1471,6 @@ public: "A System.gc() request invokes a concurrent collection; " \ "(effective only when using concurrent collectors)") \ \ - product(bool, ExplicitGCInvokesConcurrentAndUnloadsClasses, false, \ - "A System.gc() request invokes a concurrent collection and " \ - "also unloads classes during such a concurrent gc cycle " \ - "(effective only when UseConcMarkSweepGC)") \ - \ product(bool, GCLockerInvokesConcurrent, false, \ "The exit of a JNI critical section necessitating a scavenge, " \ "also kicks off a background concurrent collection") \ @@ -1501,9 +1488,6 @@ public: product(bool, UseCMSBestFit, true, \ "Use CMS best fit allocation strategy") \ \ - product(bool, UseParNewGC, false, \ - "Use parallel threads in the new generation") \ - \ product(uintx, ParallelGCBufferWastePct, 10, \ "Wasted fraction of parallel allocation buffer") \ range(0, 100) \ @@ -2059,13 +2043,6 @@ public: "Maximum fraction (1/n) of virtual memory used for ergonomically "\ "determining maximum heap size") \ \ - product(bool, UseAutoGCSelectPolicy, false, \ - "Use automatic collection selection policy") \ - \ - product(uintx, AutoGCSelectPauseMillis, 5000, \ - "Automatic GC selection pause threshold in milliseconds") \ - range(0, max_uintx) \ - \ product(bool, UseAdaptiveSizePolicy, true, \ "Use adaptive generation sizing policies") \ \ @@ -3003,10 +2980,6 @@ public: develop(intx, DontYieldALotInterval, 10, \ "Interval between which yields will be dropped (milliseconds)") \ \ - develop(intx, MinSleepInterval, 1, \ - "Minimum sleep() interval (milliseconds) when " \ - "ConvertSleepToYield is off (used for Solaris)") \ - \ develop(intx, ProfilerPCTickThreshold, 15, \ "Number of ticks in a PC buckets to be a hotspot") \ \ @@ -3375,7 +3348,7 @@ public: "Code cache expansion size (in bytes)") \ range(0, max_uintx) \ \ - develop_pd(uintx, CodeCacheMinBlockLength, \ + diagnostic_pd(uintx, CodeCacheMinBlockLength, \ "Minimum number of segments in a code cache block") \ range(1, 100) \ \ @@ -3875,6 +3848,9 @@ public: product(bool, StartAttachListener, false, \ "Always start Attach Listener at VM startup") \ \ + product(bool, EnableDynamicAgentLoading, true, \ + "Allow tools to load agents with the attach mechanism") \ + \ manageable(bool, PrintConcurrentLocks, false, \ "Print java.util.concurrent locks in thread dump") \ \ diff --git a/hotspot/src/share/vm/runtime/java.cpp b/hotspot/src/share/vm/runtime/java.cpp index 0c7187cf745..9223f12b764 100644 --- a/hotspot/src/share/vm/runtime/java.cpp +++ b/hotspot/src/share/vm/runtime/java.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -621,6 +621,13 @@ void vm_notify_during_shutdown(const char* error, const char* message) { } } +void vm_exit_during_initialization() { + vm_notify_during_shutdown(NULL, NULL); + + // Failure during initialization, we don't want to dump core + vm_abort(false); +} + void vm_exit_during_initialization(Handle exception) { tty->print_cr("Error occurred during initialization of VM"); // If there are exceptions on this thread it must be cleared diff --git a/hotspot/src/share/vm/runtime/java.hpp b/hotspot/src/share/vm/runtime/java.hpp index e1e982e3824..3b3a714ee8a 100644 --- a/hotspot/src/share/vm/runtime/java.hpp +++ b/hotspot/src/share/vm/runtime/java.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -45,6 +45,7 @@ extern void vm_abort(bool dump_core=true); extern void notify_vm_shutdown(); // VM exit if error occurs during initialization of VM +extern void vm_exit_during_initialization(); extern void vm_exit_during_initialization(Handle exception); extern void vm_exit_during_initialization(Symbol* exception_name, const char* message); extern void vm_exit_during_initialization(const char* error, const char* message = NULL); diff --git a/hotspot/src/share/vm/runtime/javaCalls.cpp b/hotspot/src/share/vm/runtime/javaCalls.cpp index 5874699a1fc..d83f45cba41 100644 --- a/hotspot/src/share/vm/runtime/javaCalls.cpp +++ b/hotspot/src/share/vm/runtime/javaCalls.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -221,7 +221,7 @@ void JavaCalls::call_virtual(JavaValue* result, Handle receiver, KlassHandle spe void JavaCalls::call_special(JavaValue* result, KlassHandle klass, Symbol* name, Symbol* signature, JavaCallArguments* args, TRAPS) { CallInfo callinfo; LinkInfo link_info(klass, name, signature); - LinkResolver::resolve_special_call(callinfo, link_info, CHECK); + LinkResolver::resolve_special_call(callinfo, args->receiver(), link_info, CHECK); methodHandle method = callinfo.selected_method(); assert(method.not_null(), "should have thrown exception"); @@ -328,9 +328,9 @@ void JavaCalls::call_helper(JavaValue* result, const methodHandle& method, JavaC // Verify the arguments if (CheckJNICalls) { - args->verify(method, result->get_type(), thread); + args->verify(method, result->get_type()); } - else debug_only(args->verify(method, result->get_type(), thread)); + else debug_only(args->verify(method, result->get_type())); #if INCLUDE_JVMCI } #else @@ -442,12 +442,43 @@ void JavaCalls::call_helper(JavaValue* result, const methodHandle& method, JavaC //-------------------------------------------------------------------------------------- // Implementation of JavaCallArguments +inline bool is_value_state_indirect_oop(uint state) { + assert(state != JavaCallArguments::value_state_oop, + "Checking for handles after removal"); + assert(state < JavaCallArguments::value_state_limit, + "Invalid value state %u", state); + return state != JavaCallArguments::value_state_primitive; +} + +inline oop resolve_indirect_oop(intptr_t value, uint state) { + switch (state) { + case JavaCallArguments::value_state_handle: + { + oop* ptr = reinterpret_cast(value); + return Handle::raw_resolve(ptr); + } + + case JavaCallArguments::value_state_jobject: + { + jobject obj = reinterpret_cast(value); + return JNIHandles::resolve(obj); + } + + default: + ShouldNotReachHere(); + return NULL; + } +} + intptr_t* JavaCallArguments::parameters() { // First convert all handles to oops for(int i = 0; i < _size; i++) { - if (_is_oop[i]) { - // Handle conversion - _value[i] = cast_from_oop(Handle::raw_resolve((oop *)_value[i])); + uint state = _value_state[i]; + assert(state != value_state_oop, "Multiple handle conversions"); + if (is_value_state_indirect_oop(state)) { + oop obj = resolve_indirect_oop(_value[i], state); + _value[i] = cast_from_oop(obj); + _value_state[i] = value_state_oop; } } // Return argument vector @@ -457,30 +488,42 @@ intptr_t* JavaCallArguments::parameters() { class SignatureChekker : public SignatureIterator { private: - bool *_is_oop; - int _pos; + int _pos; BasicType _return_type; - intptr_t* _value; - Thread* _thread; + u_char* _value_state; + intptr_t* _value; public: bool _is_return; - SignatureChekker(Symbol* signature, BasicType return_type, bool is_static, bool* is_oop, intptr_t* value, Thread* thread) : SignatureIterator(signature) { - _is_oop = is_oop; - _is_return = false; - _return_type = return_type; - _pos = 0; - _value = value; - _thread = thread; - + SignatureChekker(Symbol* signature, + BasicType return_type, + bool is_static, + u_char* value_state, + intptr_t* value) : + SignatureIterator(signature), + _pos(0), + _return_type(return_type), + _value_state(value_state), + _value(value), + _is_return(false) + { if (!is_static) { check_value(true); // Receiver must be an oop } } void check_value(bool type) { - guarantee(_is_oop[_pos++] == type, "signature does not match pushed arguments"); + uint state = _value_state[_pos++]; + if (type) { + guarantee(is_value_state_indirect_oop(state), + "signature does not match pushed arguments: %u at %d", + state, _pos - 1); + } else { + guarantee(state == JavaCallArguments::value_state_primitive, + "signature does not match pushed arguments: %u at %d", + state, _pos - 1); + } } void check_doing_return(bool state) { _is_return = state; } @@ -515,24 +558,20 @@ class SignatureChekker : public SignatureIterator { return; } - // verify handle and the oop pointed to by handle - int p = _pos; - bool bad = false; - // If argument is oop - if (_is_oop[p]) { - intptr_t v = _value[p]; - if (v != 0 ) { - size_t t = (size_t)v; - bad = (t < (size_t)os::vm_page_size() ) || !Handle::raw_resolve((oop *)v)->is_oop_or_null(true); - if (CheckJNICalls && bad) { - ReportJNIFatalError((JavaThread*)_thread, "Bad JNI oop argument"); - } - } - // for the regular debug case. - assert(!bad, "Bad JNI oop argument"); + intptr_t v = _value[_pos]; + if (v != 0) { + // v is a "handle" referring to an oop, cast to integral type. + // There shouldn't be any handles in very low memory. + guarantee((size_t)v >= (size_t)os::vm_page_size(), + "Bad JNI oop argument %d: " PTR_FORMAT, _pos, v); + // Verify the pointee. + oop vv = resolve_indirect_oop(v, _value_state[_pos]); + guarantee(vv->is_oop_or_null(true), + "Bad JNI oop argument %d: " PTR_FORMAT " -> " PTR_FORMAT, + _pos, v, p2i(vv)); } - check_value(true); + check_value(true); // Verify value state. } void do_bool() { check_int(T_BOOLEAN); } @@ -549,8 +588,7 @@ class SignatureChekker : public SignatureIterator { }; -void JavaCallArguments::verify(const methodHandle& method, BasicType return_type, - Thread *thread) { +void JavaCallArguments::verify(const methodHandle& method, BasicType return_type) { guarantee(method->size_of_parameters() == size_of_parameters(), "wrong no. of arguments pushed"); // Treat T_OBJECT and T_ARRAY as the same @@ -559,7 +597,11 @@ void JavaCallArguments::verify(const methodHandle& method, BasicType return_type // Check that oop information is correct Symbol* signature = method->signature(); - SignatureChekker sc(signature, return_type, method->is_static(),_is_oop, _value, thread); + SignatureChekker sc(signature, + return_type, + method->is_static(), + _value_state, + _value); sc.iterate_parameters(); sc.check_doing_return(true); sc.iterate_returntype(); diff --git a/hotspot/src/share/vm/runtime/javaCalls.hpp b/hotspot/src/share/vm/runtime/javaCalls.hpp index efe1f8b9813..e77abf7d36b 100644 --- a/hotspot/src/share/vm/runtime/javaCalls.hpp +++ b/hotspot/src/share/vm/runtime/javaCalls.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -80,11 +80,11 @@ class JavaCallArguments : public StackObj { _default_size = 8 // Must be at least # of arguments in JavaCalls methods }; - intptr_t _value_buffer [_default_size + 1]; - bool _is_oop_buffer[_default_size + 1]; + intptr_t _value_buffer [_default_size + 1]; + u_char _value_state_buffer[_default_size + 1]; intptr_t* _value; - bool* _is_oop; + u_char* _value_state; int _size; int _max_size; bool _start_at_zero; // Support late setting of receiver @@ -92,8 +92,8 @@ class JavaCallArguments : public StackObj { void initialize() { // Starts at first element to support set_receiver. - _value = &_value_buffer[1]; - _is_oop = &_is_oop_buffer[1]; + _value = &_value_buffer[1]; + _value_state = &_value_state_buffer[1]; _max_size = _default_size; _size = 0; @@ -101,6 +101,23 @@ class JavaCallArguments : public StackObj { JVMCI_ONLY(_alternative_target = NULL;) } + // Helper for push_oop and the like. The value argument is a + // "handle" that refers to an oop. We record the address of the + // handle rather than the designated oop. The handle is later + // resolved to the oop by parameters(). This delays the exposure of + // naked oops until it is GC-safe. + template + inline int push_oop_impl(T handle, int size) { + // JNITypes::put_obj expects an oop value, so we play fast and + // loose with the type system. The cast from handle type to oop + // *must* use a C-style cast. In a product build it performs a + // reinterpret_cast. In a debug build (more accurately, in a + // CHECK_UNHANDLED_OOPS build) it performs a static_cast, invoking + // the debug-only oop class's conversion from void* constructor. + JNITypes::put_obj((oop)handle, _value, size); // Updates size. + return size; // Return the updated size. + } + public: JavaCallArguments() { initialize(); } @@ -111,11 +128,12 @@ class JavaCallArguments : public StackObj { JavaCallArguments(int max_size) { if (max_size > _default_size) { - _value = NEW_RESOURCE_ARRAY(intptr_t, max_size + 1); - _is_oop = NEW_RESOURCE_ARRAY(bool, max_size + 1); + _value = NEW_RESOURCE_ARRAY(intptr_t, max_size + 1); + _value_state = NEW_RESOURCE_ARRAY(u_char, max_size + 1); - // Reserve room for potential receiver in value and is_oop - _value++; _is_oop++; + // Reserve room for potential receiver in value and state + _value++; + _value_state++; _max_size = max_size; _size = 0; @@ -136,25 +154,52 @@ class JavaCallArguments : public StackObj { } #endif - inline void push_oop(Handle h) { _is_oop[_size] = true; - JNITypes::put_obj((oop)h.raw_value(), _value, _size); } + // The possible values for _value_state elements. + enum { + value_state_primitive, + value_state_oop, + value_state_handle, + value_state_jobject, + value_state_limit + }; - inline void push_int(int i) { _is_oop[_size] = false; - JNITypes::put_int(i, _value, _size); } + inline void push_oop(Handle h) { + _value_state[_size] = value_state_handle; + _size = push_oop_impl(h.raw_value(), _size); + } - inline void push_double(double d) { _is_oop[_size] = false; _is_oop[_size + 1] = false; - JNITypes::put_double(d, _value, _size); } + inline void push_jobject(jobject h) { + _value_state[_size] = value_state_jobject; + _size = push_oop_impl(h, _size); + } - inline void push_long(jlong l) { _is_oop[_size] = false; _is_oop[_size + 1] = false; - JNITypes::put_long(l, _value, _size); } + inline void push_int(int i) { + _value_state[_size] = value_state_primitive; + JNITypes::put_int(i, _value, _size); + } - inline void push_float(float f) { _is_oop[_size] = false; - JNITypes::put_float(f, _value, _size); } + inline void push_double(double d) { + _value_state[_size] = value_state_primitive; + _value_state[_size + 1] = value_state_primitive; + JNITypes::put_double(d, _value, _size); + } + + inline void push_long(jlong l) { + _value_state[_size] = value_state_primitive; + _value_state[_size + 1] = value_state_primitive; + JNITypes::put_long(l, _value, _size); + } + + inline void push_float(float f) { + _value_state[_size] = value_state_primitive; + JNITypes::put_float(f, _value, _size); + } // receiver Handle receiver() { assert(_size > 0, "must at least be one argument"); - assert(_is_oop[0], "first argument must be an oop"); + assert(_value_state[0] == value_state_handle, + "first argument must be an oop"); assert(_value[0] != 0, "receiver must be not-null"); return Handle((oop*)_value[0], false); } @@ -162,11 +207,11 @@ class JavaCallArguments : public StackObj { void set_receiver(Handle h) { assert(_start_at_zero == false, "can only be called once"); _start_at_zero = true; - _is_oop--; + _value_state--; _value--; _size++; - _is_oop[0] = true; - _value[0] = (intptr_t)h.raw_value(); + _value_state[0] = value_state_handle; + push_oop_impl(h.raw_value(), 0); } // Converts all Handles to oops, and returns a reference to parameter vector @@ -174,7 +219,7 @@ class JavaCallArguments : public StackObj { int size_of_parameters() const { return _size; } // Verify that pushed arguments fits a given method - void verify(const methodHandle& method, BasicType return_type, Thread *thread); + void verify(const methodHandle& method, BasicType return_type); }; // All calls to Java have to go via JavaCalls. Sets up the stack frame diff --git a/hotspot/src/share/vm/runtime/jniHandles.cpp b/hotspot/src/share/vm/runtime/jniHandles.cpp index 679ade0eaca..f4aae3c20bf 100644 --- a/hotspot/src/share/vm/runtime/jniHandles.cpp +++ b/hotspot/src/share/vm/runtime/jniHandles.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,6 +31,9 @@ #include "runtime/jniHandles.hpp" #include "runtime/mutexLocker.hpp" #include "runtime/thread.inline.hpp" +#if INCLUDE_ALL_GCS +#include "gc/g1/g1SATBCardTableModRefBS.hpp" +#endif JNIHandleBlock* JNIHandles::_global_handles = NULL; JNIHandleBlock* JNIHandles::_weak_global_handles = NULL; @@ -92,28 +95,48 @@ jobject JNIHandles::make_weak_global(Handle obj) { jobject res = NULL; if (!obj.is_null()) { // ignore null handles - MutexLocker ml(JNIGlobalHandle_lock); - assert(Universe::heap()->is_in_reserved(obj()), "sanity check"); - res = _weak_global_handles->allocate_handle(obj()); + { + MutexLocker ml(JNIGlobalHandle_lock); + assert(Universe::heap()->is_in_reserved(obj()), "sanity check"); + res = _weak_global_handles->allocate_handle(obj()); + } + // Add weak tag. + assert(is_ptr_aligned(res, weak_tag_alignment), "invariant"); + char* tptr = reinterpret_cast(res) + weak_tag_value; + res = reinterpret_cast(tptr); } else { CHECK_UNHANDLED_OOPS_ONLY(Thread::current()->clear_unhandled_oops()); } return res; } +template +oop JNIHandles::resolve_jweak(jweak handle) { + assert(is_jweak(handle), "precondition"); + oop result = jweak_ref(handle); + result = guard_value(result); +#if INCLUDE_ALL_GCS + if (result != NULL && UseG1GC) { + G1SATBCardTableModRefBS::enqueue(result); + } +#endif // INCLUDE_ALL_GCS + return result; +} + +template oop JNIHandles::resolve_jweak(jweak); +template oop JNIHandles::resolve_jweak(jweak); void JNIHandles::destroy_global(jobject handle) { if (handle != NULL) { assert(is_global_handle(handle), "Invalid delete of global JNI handle"); - *((oop*)handle) = deleted_handle(); // Mark the handle as deleted, allocate will reuse it + jobject_ref(handle) = deleted_handle(); } } void JNIHandles::destroy_weak_global(jobject handle) { if (handle != NULL) { - assert(!CheckJNICalls || is_weak_global_handle(handle), "Invalid delete of weak global JNI handle"); - *((oop*)handle) = deleted_handle(); // Mark the handle as deleted, allocate will reuse it + jweak_ref(handle) = deleted_handle(); } } diff --git a/hotspot/src/share/vm/runtime/jniHandles.hpp b/hotspot/src/share/vm/runtime/jniHandles.hpp index ce37d940d7c..13e0e155740 100644 --- a/hotspot/src/share/vm/runtime/jniHandles.hpp +++ b/hotspot/src/share/vm/runtime/jniHandles.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -40,7 +40,28 @@ class JNIHandles : AllStatic { static JNIHandleBlock* _weak_global_handles; // First weak global handle block static oop _deleted_handle; // Sentinel marking deleted handles + inline static bool is_jweak(jobject handle); + inline static oop& jobject_ref(jobject handle); // NOT jweak! + inline static oop& jweak_ref(jobject handle); + + template inline static oop guard_value(oop value); + template inline static oop resolve_impl(jobject handle); + template static oop resolve_jweak(jweak handle); + public: + // Low tag bit in jobject used to distinguish a jweak. jweak is + // type equivalent to jobject, but there are places where we need to + // be able to distinguish jweak values from other jobjects, and + // is_weak_global_handle is unsuitable for performance reasons. To + // provide such a test we add weak_tag_value to the (aligned) byte + // address designated by the jobject to produce the corresponding + // jweak. Accessing the value of a jobject must account for it + // being a possibly offset jweak. + static const uintptr_t weak_tag_size = 1; + static const uintptr_t weak_tag_alignment = (1u << weak_tag_size); + static const uintptr_t weak_tag_mask = weak_tag_alignment - 1; + static const int weak_tag_value = 1; + // Resolve handle into oop inline static oop resolve(jobject handle); // Resolve externally provided handle into oop with some guards @@ -176,36 +197,85 @@ class JNIHandleBlock : public CHeapObj { #endif }; +inline bool JNIHandles::is_jweak(jobject handle) { + STATIC_ASSERT(weak_tag_size == 1); + STATIC_ASSERT(weak_tag_value == 1); + return (reinterpret_cast(handle) & weak_tag_mask) != 0; +} + +inline oop& JNIHandles::jobject_ref(jobject handle) { + assert(!is_jweak(handle), "precondition"); + return *reinterpret_cast(handle); +} + +inline oop& JNIHandles::jweak_ref(jobject handle) { + assert(is_jweak(handle), "precondition"); + char* ptr = reinterpret_cast(handle) - weak_tag_value; + return *reinterpret_cast(ptr); +} + +// external_guard is true if called from resolve_external_guard. +// Treat deleted (and possibly zapped) as NULL for external_guard, +// else as (asserted) error. +template +inline oop JNIHandles::guard_value(oop value) { + if (!external_guard) { + assert(value != badJNIHandle, "Pointing to zapped jni handle area"); + assert(value != deleted_handle(), "Used a deleted global handle"); + } else if ((value == badJNIHandle) || (value == deleted_handle())) { + value = NULL; + } + return value; +} + +// external_guard is true if called from resolve_external_guard. +template +inline oop JNIHandles::resolve_impl(jobject handle) { + assert(handle != NULL, "precondition"); + oop result; + if (is_jweak(handle)) { // Unlikely + result = resolve_jweak(handle); + } else { + result = jobject_ref(handle); + // Construction of jobjects canonicalize a null value into a null + // jobject, so for non-jweak the pointee should never be null. + assert(external_guard || result != NULL, + "Invalid value read from jni handle"); + result = guard_value(result); + } + return result; +} inline oop JNIHandles::resolve(jobject handle) { - oop result = (handle == NULL ? (oop)NULL : *(oop*)handle); - assert(result != NULL || (handle == NULL || !CheckJNICalls || is_weak_global_handle(handle)), "Invalid value read from jni handle"); - assert(result != badJNIHandle, "Pointing to zapped jni handle area"); + oop result = NULL; + if (handle != NULL) { + result = resolve_impl(handle); + } return result; -}; - +} +// Resolve some erroneous cases to NULL, rather than treating them as +// possibly unchecked errors. In particular, deleted handles are +// treated as NULL (though a deleted and later reallocated handle +// isn't detected). inline oop JNIHandles::resolve_external_guard(jobject handle) { - if (handle == NULL) return NULL; - oop result = *(oop*)handle; - if (result == NULL || result == badJNIHandle) return NULL; + oop result = NULL; + if (handle != NULL) { + result = resolve_impl(handle); + } return result; -}; - +} inline oop JNIHandles::resolve_non_null(jobject handle) { assert(handle != NULL, "JNI handle should not be null"); - oop result = *(oop*)handle; - assert(result != NULL, "Invalid value read from jni handle"); - assert(result != badJNIHandle, "Pointing to zapped jni handle area"); - // Don't let that private _deleted_handle object escape into the wild. - assert(result != deleted_handle(), "Used a deleted global handle."); + oop result = resolve_impl(handle); + assert(result != NULL, "NULL read from jni handle"); return result; -}; +} inline void JNIHandles::destroy_local(jobject handle) { if (handle != NULL) { - *((oop*)handle) = deleted_handle(); // Mark the handle as deleted, allocate will reuse it + jobject_ref(handle) = deleted_handle(); } } diff --git a/hotspot/src/share/vm/runtime/mutexLocker.cpp b/hotspot/src/share/vm/runtime/mutexLocker.cpp index 29ad520e1f0..8c47a1c308a 100644 --- a/hotspot/src/share/vm/runtime/mutexLocker.cpp +++ b/hotspot/src/share/vm/runtime/mutexLocker.cpp @@ -181,13 +181,13 @@ void mutex_init() { } if (UseG1GC) { - def(SATB_Q_FL_lock , PaddedMutex , special, true, Monitor::_safepoint_check_never); - def(SATB_Q_CBL_mon , PaddedMonitor, nonleaf, true, Monitor::_safepoint_check_never); - def(Shared_SATB_Q_lock , PaddedMutex , nonleaf, true, Monitor::_safepoint_check_never); + def(SATB_Q_FL_lock , PaddedMutex , special , true, Monitor::_safepoint_check_never); + def(SATB_Q_CBL_mon , PaddedMonitor, leaf - 1 , true, Monitor::_safepoint_check_never); + def(Shared_SATB_Q_lock , PaddedMutex , leaf - 1 , true, Monitor::_safepoint_check_never); - def(DirtyCardQ_FL_lock , PaddedMutex , special, true, Monitor::_safepoint_check_never); - def(DirtyCardQ_CBL_mon , PaddedMonitor, nonleaf, true, Monitor::_safepoint_check_never); - def(Shared_DirtyCardQ_lock , PaddedMutex , nonleaf, true, Monitor::_safepoint_check_never); + def(DirtyCardQ_FL_lock , PaddedMutex , special , true, Monitor::_safepoint_check_never); + def(DirtyCardQ_CBL_mon , PaddedMonitor, leaf - 1 , true, Monitor::_safepoint_check_never); + def(Shared_DirtyCardQ_lock , PaddedMutex , leaf - 1 , true, Monitor::_safepoint_check_never); def(FreeList_lock , PaddedMutex , leaf , true, Monitor::_safepoint_check_never); def(SecondaryFreeList_lock , PaddedMonitor, leaf , true, Monitor::_safepoint_check_never); diff --git a/hotspot/src/share/vm/runtime/os_ext.hpp b/hotspot/src/share/vm/runtime/os_ext.hpp index 3aa733a322a..5fcaae13728 100644 --- a/hotspot/src/share/vm/runtime/os_ext.hpp +++ b/hotspot/src/share/vm/runtime/os_ext.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2015 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/hotspot/src/share/vm/runtime/reflection.cpp b/hotspot/src/share/vm/runtime/reflection.cpp index fb4b2ee63cc..68b895c5f05 100644 --- a/hotspot/src/share/vm/runtime/reflection.cpp +++ b/hotspot/src/share/vm/runtime/reflection.cpp @@ -594,9 +594,9 @@ char* Reflection::verify_class_access_msg(const Klass* current_class, current_class_name, module_from_name, new_class_name, module_to_name, module_from_name, module_to_name); } else { - jobject jlrm = module_to->module(); - assert(jlrm != NULL, "Null jlrm in module_to ModuleEntry"); - intptr_t identity_hash = JNIHandles::resolve(jlrm)->identity_hash(); + jobject jlm = module_to->module(); + assert(jlm != NULL, "Null jlm in module_to ModuleEntry"); + intptr_t identity_hash = JNIHandles::resolve(jlm)->identity_hash(); size_t len = 160 + strlen(current_class_name) + 2*strlen(module_from_name) + strlen(new_class_name) + 2*sizeof(uintx); msg = NEW_RESOURCE_ARRAY(char, len); @@ -621,9 +621,9 @@ char* Reflection::verify_class_access_msg(const Klass* current_class, current_class_name, module_from_name, new_class_name, module_to_name, module_to_name, package_name, module_from_name); } else { - jobject jlrm = module_from->module(); - assert(jlrm != NULL, "Null jlrm in module_from ModuleEntry"); - intptr_t identity_hash = JNIHandles::resolve(jlrm)->identity_hash(); + jobject jlm = module_from->module(); + assert(jlm != NULL, "Null jlm in module_from ModuleEntry"); + intptr_t identity_hash = JNIHandles::resolve(jlm)->identity_hash(); size_t len = 170 + strlen(current_class_name) + strlen(new_class_name) + 2*strlen(module_to_name) + strlen(package_name) + 2*sizeof(uintx); msg = NEW_RESOURCE_ARRAY(char, len); diff --git a/hotspot/src/share/vm/runtime/sharedRuntime.cpp b/hotspot/src/share/vm/runtime/sharedRuntime.cpp index c854e4ad84f..b244bb70f18 100644 --- a/hotspot/src/share/vm/runtime/sharedRuntime.cpp +++ b/hotspot/src/share/vm/runtime/sharedRuntime.cpp @@ -549,7 +549,7 @@ address SharedRuntime::get_poll_stub(address pc) { CodeBlob *cb = CodeCache::find_blob(pc); // Should be an nmethod - assert(cb && cb->is_compiled(), "safepoint polling: pc must refer to an nmethod"); + guarantee(cb != NULL && cb->is_compiled(), "safepoint polling: pc must refer to an nmethod"); // Look up the relocation information assert(((CompiledMethod*)cb)->is_at_poll_or_poll_return(pc), @@ -1802,7 +1802,7 @@ bool SharedRuntime::should_fixup_call_destination(address destination, address e if (destination != entry_point) { CodeBlob* callee = CodeCache::find_blob(destination); // callee == cb seems weird. It means calling interpreter thru stub. - if (callee == cb || callee->is_adapter_blob()) { + if (callee != NULL && (callee == cb || callee->is_adapter_blob())) { // static call or optimized virtual if (TraceCallFixup) { tty->print("fixup callsite at " INTPTR_FORMAT " to compiled code for", p2i(caller_pc)); @@ -1851,7 +1851,7 @@ IRT_LEAF(void, SharedRuntime::fixup_callers_callsite(Method* method, address cal // ask me how I know this... CodeBlob* cb = CodeCache::find_blob(caller_pc); - if (!cb->is_compiled() || entry_point == moop->get_c2i_entry()) { + if (cb == NULL || !cb->is_compiled() || entry_point == moop->get_c2i_entry()) { return; } diff --git a/hotspot/src/share/vm/runtime/thread.cpp b/hotspot/src/share/vm/runtime/thread.cpp index abdcab5684c..758020a7c77 100644 --- a/hotspot/src/share/vm/runtime/thread.cpp +++ b/hotspot/src/share/vm/runtime/thread.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -3404,14 +3404,21 @@ static void call_initPhase1(TRAPS) { // // After phase 2, The VM will begin search classes from -Xbootclasspath/a. static void call_initPhase2(TRAPS) { - TraceTime timer("Phase2 initialization", TRACETIME_LOG(Info, modules, startuptime)); + TraceTime timer("Phase2 initialization", TRACETIME_LOG(Info, module, startuptime)); Klass* k = SystemDictionary::resolve_or_fail(vmSymbols::java_lang_System(), true, CHECK); instanceKlassHandle klass (THREAD, k); - JavaValue result(T_VOID); + JavaValue result(T_INT); + JavaCallArguments args; + args.push_int(DisplayVMOutputToStderr); + args.push_int(log_is_enabled(Debug, init)); // print stack trace if exception thrown JavaCalls::call_static(&result, klass, vmSymbols::initPhase2_name(), - vmSymbols::void_method_signature(), CHECK); + vmSymbols::boolean_boolean_int_signature(), &args, CHECK); + if (result.get_jint() != JNI_OK) { + vm_exit_during_initialization(); // no message or exception + } + universe_post_module_init(); } @@ -3458,7 +3465,7 @@ void Threads::initialize_java_lang_classes(JavaThread* main_thread, TRAPS) { java_lang_Thread::RUNNABLE); // The VM creates objects of this class. - initialize_class(vmSymbols::java_lang_reflect_Module(), CHECK); + initialize_class(vmSymbols::java_lang_Module(), CHECK); // The VM preresolves methods to these classes. Make sure that they get initialized initialize_class(vmSymbols::java_lang_reflect_Method(), CHECK); diff --git a/hotspot/src/share/vm/runtime/vframe.cpp b/hotspot/src/share/vm/runtime/vframe.cpp index 7d9a7b39e6e..1759e31dd64 100644 --- a/hotspot/src/share/vm/runtime/vframe.cpp +++ b/hotspot/src/share/vm/runtime/vframe.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -463,14 +463,15 @@ void interpretedVFrame::set_locals(StackValueCollection* values) const { entryVFrame::entryVFrame(const frame* fr, const RegisterMap* reg_map, JavaThread* thread) : externalVFrame(fr, reg_map, thread) {} - -void vframeStreamCommon::found_bad_method_frame() { +#ifdef ASSERT +void vframeStreamCommon::found_bad_method_frame() const { // 6379830 Cut point for an assertion that occasionally fires when // we are using the performance analyzer. // Disable this assert when testing the analyzer with fastdebug. // -XX:SuppressErrorAt=vframe.cpp:XXX (XXX=following line number) - assert(false, "invalid bci or invalid scope desc"); + fatal("invalid bci or invalid scope desc"); } +#endif // top-frame will be skipped vframeStream::vframeStream(JavaThread* thread, frame top_frame, diff --git a/hotspot/src/share/vm/runtime/vframe.hpp b/hotspot/src/share/vm/runtime/vframe.hpp index de7d510fc2d..40c43ad1824 100644 --- a/hotspot/src/share/vm/runtime/vframe.hpp +++ b/hotspot/src/share/vm/runtime/vframe.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -297,14 +297,14 @@ class vframeStreamCommon : StackObj { void fill_from_compiled_frame(int decode_offset); void fill_from_compiled_native_frame(); - void found_bad_method_frame(); - void fill_from_interpreter_frame(); bool fill_from_frame(); // Helper routine for security_get_caller_frame void skip_prefixed_method_and_wrappers(); + DEBUG_ONLY(void found_bad_method_frame() const;) + public: // Constructor vframeStreamCommon(JavaThread* thread) : _reg_map(thread, false) { @@ -407,9 +407,9 @@ inline void vframeStreamCommon::fill_from_compiled_frame(int decode_offset) { nm()->print_code(); nm()->print_pcs(); } + found_bad_method_frame(); #endif // Provide a cheap fallback in product mode. (See comment above.) - found_bad_method_frame(); fill_from_compiled_native_frame(); return; } @@ -523,7 +523,7 @@ inline void vframeStreamCommon::fill_from_interpreter_frame() { // In this scenario, pretend that the interpreter is at the point // of entering the method. if (bci < 0) { - found_bad_method_frame(); + DEBUG_ONLY(found_bad_method_frame();) bci = 0; } _mode = interpreted_mode; diff --git a/hotspot/src/share/vm/runtime/vmStructs.cpp b/hotspot/src/share/vm/runtime/vmStructs.cpp index d5b9e3db03c..dffb9198f3f 100644 --- a/hotspot/src/share/vm/runtime/vmStructs.cpp +++ b/hotspot/src/share/vm/runtime/vmStructs.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -199,6 +199,7 @@ typedef Hashtable KlassHashtable; typedef HashtableEntry KlassHashtableEntry; typedef TwoOopHashtable SymbolTwoOopHashtable; typedef CompactHashtable SymbolCompactHashTable; +typedef RehashableHashtable RehashableSymbolHashtable; //-------------------------------------------------------------------------------- // VM_STRUCTS @@ -584,6 +585,7 @@ typedef CompactHashtable SymbolCompactHashTable; \ static_field(SymbolTable, _the_table, SymbolTable*) \ static_field(SymbolTable, _shared_table, SymbolCompactHashTable) \ + static_field(RehashableSymbolHashtable, _seed, juint) \ \ /***************/ \ /* StringTable */ \ @@ -673,7 +675,7 @@ typedef CompactHashtable SymbolCompactHashTable; \ nonstatic_field(BasicHashtable, _table_size, int) \ nonstatic_field(BasicHashtable, _buckets, HashtableBucket*) \ - nonstatic_field(BasicHashtable, _free_list, BasicHashtableEntry*) \ + volatile_nonstatic_field(BasicHashtable, _free_list, BasicHashtableEntry*) \ nonstatic_field(BasicHashtable, _first_free_entry, char*) \ nonstatic_field(BasicHashtable, _end_block, char*) \ nonstatic_field(BasicHashtable, _entry_size, int) \ @@ -969,6 +971,7 @@ typedef CompactHashtable SymbolCompactHashTable; nonstatic_field(JavaThread, _vframe_array_last, vframeArray*) \ nonstatic_field(JavaThread, _satb_mark_queue, SATBMarkQueue) \ nonstatic_field(JavaThread, _dirty_card_queue, DirtyCardQueue) \ + volatile_nonstatic_field(JavaThread, _terminated, JavaThread::TerminatedTypes) \ nonstatic_field(Thread, _resource_area, ResourceArea*) \ nonstatic_field(CompilerThread, _env, ciEnv*) \ \ @@ -1602,6 +1605,8 @@ typedef CompactHashtable SymbolCompactHashTable; \ declare_toplevel_type(BasicHashtable) \ declare_type(IntptrHashtable, BasicHashtable) \ + declare_toplevel_type(BasicHashtable) \ + declare_type(RehashableSymbolHashtable, BasicHashtable) \ declare_type(SymbolTable, SymbolHashtable) \ declare_type(StringTable, StringHashtable) \ declare_type(LoaderConstraintTable, KlassHashtable) \ @@ -2209,6 +2214,7 @@ typedef CompactHashtable SymbolCompactHashTable; declare_toplevel_type(JavaThread*) \ declare_toplevel_type(java_lang_Class) \ declare_integer_type(JavaThread::AsyncRequests) \ + declare_integer_type(JavaThread::TerminatedTypes) \ declare_toplevel_type(jbyte*) \ declare_toplevel_type(jbyte**) \ declare_toplevel_type(jint*) \ @@ -2431,6 +2437,8 @@ typedef CompactHashtable SymbolCompactHashTable; declare_constant(_thread_in_Java_trans) \ declare_constant(_thread_blocked) \ declare_constant(_thread_blocked_trans) \ + declare_constant(JavaThread::_not_terminated) \ + declare_constant(JavaThread::_thread_exiting) \ \ /******************************/ \ /* Klass misc. enum constants */ \ diff --git a/hotspot/src/share/vm/services/attachListener.cpp b/hotspot/src/share/vm/services/attachListener.cpp index 0de704d6913..99ba58b5200 100644 --- a/hotspot/src/share/vm/services/attachListener.cpp +++ b/hotspot/src/share/vm/services/attachListener.cpp @@ -100,6 +100,36 @@ static jint get_properties(AttachOperation* op, outputStream* out, Symbol* seria return JNI_OK; } +// Implementation of "load" command. +static jint load_agent(AttachOperation* op, outputStream* out) { + // get agent name and options + const char* agent = op->arg(0); + const char* absParam = op->arg(1); + const char* options = op->arg(2); + + // If loading a java agent then need to ensure that the java.instrument module is loaded + if (strcmp(agent, "instrument") == 0) { + Thread* THREAD = Thread::current(); + ResourceMark rm(THREAD); + HandleMark hm(THREAD); + JavaValue result(T_OBJECT); + Handle h_module_name = java_lang_String::create_from_str("java.instrument", THREAD); + JavaCalls::call_static(&result, + SystemDictionary::module_Modules_klass(), + vmSymbols::loadModule_name(), + vmSymbols::loadModule_signature(), + h_module_name, + THREAD); + if (HAS_PENDING_EXCEPTION) { + java_lang_Throwable::print(PENDING_EXCEPTION, out); + CLEAR_PENDING_EXCEPTION; + return JNI_ERR; + } + } + + return JvmtiExport::load_agent_library(agent, absParam, options, out); +} + // Implementation of "properties" command. // See also: PrintSystemPropertiesDCmd class static jint get_system_properties(AttachOperation* op, outputStream* out) { @@ -282,7 +312,7 @@ static AttachOperationFunctionInfo funcs[] = { { "agentProperties", get_agent_properties }, { "datadump", data_dump }, { "dumpheap", dump_heap }, - { "load", JvmtiExport::load_agent_library }, + { "load", load_agent }, { "properties", get_system_properties }, { "threaddump", thread_dump }, { "inspectheap", heap_inspection }, @@ -321,6 +351,10 @@ static void attach_listener_thread_entry(JavaThread* thread, TRAPS) { // handle special detachall operation if (strcmp(op->name(), AttachOperation::detachall_operation_name()) == 0) { AttachListener::detachall(); + } else if (!EnableDynamicAgentLoading && strcmp(op->name(), "load") == 0) { + st.print("Dynamic agent loading is not enabled. " + "Use -XX:+EnableDynamicAgentLoading to launch target VM."); + res = JNI_ERR; } else { // find the function to dispatch too AttachOperationFunctionInfo* info = NULL; diff --git a/hotspot/src/share/vm/services/diagnosticCommand.cpp b/hotspot/src/share/vm/services/diagnosticCommand.cpp index 29aa08daf94..fab6990214a 100644 --- a/hotspot/src/share/vm/services/diagnosticCommand.cpp +++ b/hotspot/src/share/vm/services/diagnosticCommand.cpp @@ -42,6 +42,21 @@ #include "utilities/macros.hpp" #include "oops/objArrayOop.inline.hpp" + +static void loadAgentModule(TRAPS) { + ResourceMark rm(THREAD); + HandleMark hm(THREAD); + + JavaValue result(T_OBJECT); + Handle h_module_name = java_lang_String::create_from_str("jdk.management.agent", CHECK); + JavaCalls::call_static(&result, + SystemDictionary::module_Modules_klass(), + vmSymbols::loadModule_name(), + vmSymbols::loadModule_signature(), + h_module_name, + THREAD); +} + void DCmdRegistrant::register_dcmds(){ // Registration of the diagnostic commands // First argument specifies which interfaces will export the command @@ -753,6 +768,7 @@ void JMXStartRemoteDCmd::execute(DCmdSource source, TRAPS) { // the remote management server. // throw java.lang.NoSuchMethodError if the method doesn't exist + loadAgentModule(CHECK); Handle loader = Handle(THREAD, SystemDictionary::java_system_loader()); Klass* k = SystemDictionary::resolve_or_fail(vmSymbols::jdk_internal_agent_Agent(), loader, Handle(), true, CHECK); instanceKlassHandle ik (THREAD, k); @@ -826,6 +842,7 @@ void JMXStartLocalDCmd::execute(DCmdSource source, TRAPS) { // the local management server // throw java.lang.NoSuchMethodError if method doesn't exist + loadAgentModule(CHECK); Handle loader = Handle(THREAD, SystemDictionary::java_system_loader()); Klass* k = SystemDictionary::resolve_or_fail(vmSymbols::jdk_internal_agent_Agent(), loader, Handle(), true, CHECK); instanceKlassHandle ik (THREAD, k); @@ -843,6 +860,7 @@ void JMXStopRemoteDCmd::execute(DCmdSource source, TRAPS) { // management server // throw java.lang.NoSuchMethodError if method doesn't exist + loadAgentModule(CHECK); Handle loader = Handle(THREAD, SystemDictionary::java_system_loader()); Klass* k = SystemDictionary::resolve_or_fail(vmSymbols::jdk_internal_agent_Agent(), loader, Handle(), true, CHECK); instanceKlassHandle ik (THREAD, k); @@ -864,6 +882,7 @@ void JMXStatusDCmd::execute(DCmdSource source, TRAPS) { // invoke getManagementAgentStatus() method to generate the status info // throw java.lang.NoSuchMethodError if method doesn't exist + loadAgentModule(CHECK); Handle loader = Handle(THREAD, SystemDictionary::java_system_loader()); Klass* k = SystemDictionary::resolve_or_fail(vmSymbols::jdk_internal_agent_Agent(), loader, Handle(), true, CHECK); instanceKlassHandle ik (THREAD, k); diff --git a/hotspot/src/share/vm/shark/sharkIntrinsics.cpp b/hotspot/src/share/vm/shark/sharkIntrinsics.cpp index 51b813f4b8d..15b6679bf4e 100644 --- a/hotspot/src/share/vm/shark/sharkIntrinsics.cpp +++ b/hotspot/src/share/vm/shark/sharkIntrinsics.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright 2009 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -66,7 +66,7 @@ bool SharkIntrinsics::is_intrinsic(ciMethod *target) { return true; // Unsafe - case vmIntrinsics::_compareAndSwapInt: + case vmIntrinsics::_compareAndSetInt: return true; default: @@ -140,8 +140,8 @@ void SharkIntrinsics::do_intrinsic() { break; // Unsafe - case vmIntrinsics::_compareAndSwapInt: - do_Unsafe_compareAndSwapInt(); + case vmIntrinsics::_compareAndSetInt: + do_Unsafe_compareAndSetInt(); break; default: @@ -241,7 +241,7 @@ void SharkIntrinsics::do_Thread_currentThread() { true)); } -void SharkIntrinsics::do_Unsafe_compareAndSwapInt() { +void SharkIntrinsics::do_Unsafe_compareAndSetInt() { // Pop the arguments Value *x = state()->pop()->jint_value(); Value *e = state()->pop()->jint_value(); diff --git a/hotspot/src/share/vm/shark/sharkIntrinsics.hpp b/hotspot/src/share/vm/shark/sharkIntrinsics.hpp index f0699f8948e..8a5d60f17b9 100644 --- a/hotspot/src/share/vm/shark/sharkIntrinsics.hpp +++ b/hotspot/src/share/vm/shark/sharkIntrinsics.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright 2009 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -58,7 +58,7 @@ class SharkIntrinsics : public SharkTargetInvariants { void do_Object_getClass(); void do_System_currentTimeMillis(); void do_Thread_currentThread(); - void do_Unsafe_compareAndSwapInt(); + void do_Unsafe_compareAndSetInt(); }; #endif // SHARE_VM_SHARK_SHARKINTRINSICS_HPP diff --git a/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp b/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp index 53fea3154b8..b9ac6a3ebf5 100644 --- a/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp +++ b/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * Copyright 2009, 2010 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -300,6 +300,7 @@ void SharkNativeWrapper::initialize(const char *name) { not_null, merge); builder()->SetInsertPoint(not_null); +#error Needs to be updated for tagged jweak; see JNIHandles. Value *unboxed_result = builder()->CreateLoad(result); builder()->CreateBr(merge); diff --git a/hotspot/src/share/vm/utilities/debug.hpp b/hotspot/src/share/vm/utilities/debug.hpp index 3a4483e681e..dbb5dc63bfc 100644 --- a/hotspot/src/share/vm/utilities/debug.hpp +++ b/hotspot/src/share/vm/utilities/debug.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -140,6 +140,9 @@ do { \ // For backward compatibility. #define assert(p, ...) vmassert(p, __VA_ARGS__) +#ifndef ASSERT +#define vmassert_status(p, status, msg) +#else // This version of vmassert is for use with checking return status from // library calls that return actual error values eg. EINVAL, // ENOMEM etc, rather than returning -1 and setting errno. @@ -155,6 +158,7 @@ do { \ BREAKPOINT; \ } \ } while (0) +#endif // For backward compatibility. #define assert_status(p, status, msg) vmassert_status(p, status, msg) diff --git a/hotspot/src/share/vm/utilities/globalDefinitions_xlc.hpp b/hotspot/src/share/vm/utilities/globalDefinitions_xlc.hpp index 623a8cbe6cf..1b216359d4c 100644 --- a/hotspot/src/share/vm/utilities/globalDefinitions_xlc.hpp +++ b/hotspot/src/share/vm/utilities/globalDefinitions_xlc.hpp @@ -1,6 +1,6 @@ /* * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 SAP SE. All rights reserved. + * Copyright (c) 2012, 2017 SAP SE. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -153,6 +153,9 @@ inline int wcslen(const jchar* x) { return wcslen((const wchar_t*)x); } // offset_of as it is defined for gcc. #define offset_of(klass,field) (size_t)((intx)&(((klass*)16)->field) - 16) +// AIX 5.3 has buggy __thread support. (see JDK-8176442). +#define USE_LIBRARY_BASED_TLS_ONLY 1 + #ifndef USE_LIBRARY_BASED_TLS_ONLY #define THREAD_LOCAL_DECL __thread #endif diff --git a/hotspot/src/share/vm/utilities/hashtable.cpp b/hotspot/src/share/vm/utilities/hashtable.cpp index f5d37f45fa9..5fce98e2694 100644 --- a/hotspot/src/share/vm/utilities/hashtable.cpp +++ b/hotspot/src/share/vm/utilities/hashtable.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -173,6 +173,35 @@ template void BasicHashtable::reverse() { } } +template void BasicHashtable::BucketUnlinkContext::free_entry(BasicHashtableEntry* entry) { + entry->set_next(_removed_head); + _removed_head = entry; + if (_removed_tail == NULL) { + _removed_tail = entry; + } + _num_removed++; +} + +template void BasicHashtable::bulk_free_entries(BucketUnlinkContext* context) { + if (context->_num_removed == 0) { + assert(context->_removed_head == NULL && context->_removed_tail == NULL, + "Zero entries in the unlink context, but elements linked from " PTR_FORMAT " to " PTR_FORMAT, + p2i(context->_removed_head), p2i(context->_removed_tail)); + return; + } + + // MT-safe add of the list of BasicHashTableEntrys from the context to the free list. + BasicHashtableEntry* current = _free_list; + while (true) { + context->_removed_tail->set_next(current); + BasicHashtableEntry* old = (BasicHashtableEntry*)Atomic::cmpxchg_ptr(context->_removed_head, &_free_list, current); + if (old == current) { + break; + } + current = old; + } + Atomic::add(-context->_num_removed, &_number_of_entries); +} // Copy the table to the shared space. diff --git a/hotspot/src/share/vm/utilities/hashtable.hpp b/hotspot/src/share/vm/utilities/hashtable.hpp index 51324a18c62..54e0b877992 100644 --- a/hotspot/src/share/vm/utilities/hashtable.hpp +++ b/hotspot/src/share/vm/utilities/hashtable.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -173,11 +173,11 @@ private: // Instance variables int _table_size; HashtableBucket* _buckets; - BasicHashtableEntry* _free_list; + BasicHashtableEntry* volatile _free_list; char* _first_free_entry; char* _end_block; int _entry_size; - int _number_of_entries; + volatile int _number_of_entries; protected: @@ -225,6 +225,24 @@ protected: // Free the buckets in this hashtable void free_buckets(); + // Helper data structure containing context for the bucket entry unlink process, + // storing the unlinked buckets in a linked list. + // Also avoids the need to pass around these four members as parameters everywhere. + struct BucketUnlinkContext { + int _num_processed; + int _num_removed; + // Head and tail pointers for the linked list of removed entries. + BasicHashtableEntry* _removed_head; + BasicHashtableEntry* _removed_tail; + + BucketUnlinkContext() : _num_processed(0), _num_removed(0), _removed_head(NULL), _removed_tail(NULL) { + } + + void free_entry(BasicHashtableEntry* entry); + }; + // Add of bucket entries linked together in the given context to the global free list. This method + // is mt-safe wrt. to other calls of this method. + void bulk_free_entries(BucketUnlinkContext* context); public: int table_size() { return _table_size; } void set_entry(int index, BasicHashtableEntry* entry); @@ -294,6 +312,7 @@ protected: }; template class RehashableHashtable : public Hashtable { + friend class VMStructs; protected: enum { diff --git a/hotspot/test/ProblemList.txt b/hotspot/test/ProblemList.txt index bf6811efb15..8101e62a587 100644 --- a/hotspot/test/ProblemList.txt +++ b/hotspot/test/ProblemList.txt @@ -64,21 +64,20 @@ gc/g1/logging/TestG1LoggingFailure.java 8169634 generic-all runtime/CompressedOops/UseCompressedOops.java 8079353 generic-all # This test is disabled since it will stress NMT and timeout during normal testing runtime/NMT/MallocStressTest.java 8166548 generic-all -runtime/SharedArchiveFile/BootAppendTests.java 8150683 generic-all +runtime/SharedArchiveFile/BootAppendTests.java 8179103 generic-all runtime/SharedArchiveFile/DefaultUseWithClient.java 8154204 generic-all ############################################################################# # :hotspot_serviceability -serviceability/jdwp/AllModulesCommandTest.java 8168478 generic-all +serviceability/jdwp/AllModulesCommandTest.java 8170541 generic-all serviceability/sa/sadebugd/SADebugDTest.java 8163805 generic-all +serviceability/jvmti/ModuleAwareAgents/ClassFileLoadHook/MAAClassFileLoadHook.java 8173936 generic-all ############################################################################# # :hotspot_misc -testlibrary_tests/ctw/JarDirTest.java 8172457 windows-all - ############################################################################# diff --git a/hotspot/test/TEST.ROOT b/hotspot/test/TEST.ROOT index 54b61ac1406..fabc5e42672 100644 --- a/hotspot/test/TEST.ROOT +++ b/hotspot/test/TEST.ROOT @@ -50,8 +50,8 @@ requires.properties= \ vm.cpu.features \ vm.debug -# Tests using jtreg 4.2 b04 features -requiredVersion=4.2 b04 +# Tests using jtreg 4.2 b07 features +requiredVersion=4.2 b07 # Path to libraries in the topmost test directory. This is needed so @library # does not need ../../ notation to reach them @@ -59,3 +59,6 @@ external.lib.roots = ../../ # Use new module options useNewOptions=true + +# Use --patch-module instead of -Xmodule: +useNewPatchModule=true diff --git a/hotspot/test/TEST.groups b/hotspot/test/TEST.groups index c50c741f44d..8953467a9b2 100644 --- a/hotspot/test/TEST.groups +++ b/hotspot/test/TEST.groups @@ -1,5 +1,5 @@ # -# Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -209,11 +209,8 @@ needs_full_vm_compact1 = \ gc/g1/TestShrinkToOneRegion.java \ gc/metaspace/G1AddMetaspaceDependency.java \ gc/startup_warnings/TestCMS.java \ - gc/startup_warnings/TestDefNewCMS.java \ gc/startup_warnings/TestParallelGC.java \ gc/startup_warnings/TestParallelScavengeSerialOld.java \ - gc/startup_warnings/TestParNewCMS.java \ - gc/startup_warnings/TestParNewSerialOld.java \ runtime/SharedArchiveFile/SharedArchiveFile.java # Minimal VM on Compact 2 adds in some compact2 tests diff --git a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/ClassSearchTest.java b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/ClassSearchTest.java index b212fc3139c..18983b351c6 100644 --- a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/ClassSearchTest.java +++ b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/ClassSearchTest.java @@ -20,10 +20,19 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + +/** + * @test + * @modules jdk.aot/jdk.tools.jaotc + * jdk.aot/jdk.tools.jaotc.collect + * @run junit/othervm jdk.tools.jaotc.test.collect.ClassSearchTest + */ + package jdk.tools.jaotc.test.collect; import jdk.tools.jaotc.LoadedClass; +import jdk.tools.jaotc.collect.*; import org.junit.Assert; import org.junit.Test; @@ -32,45 +41,90 @@ import java.util.HashSet; import java.util.List; import java.util.Set; import java.util.function.BiConsumer; +import java.util.function.BiFunction; public class ClassSearchTest { @Test(expected = InternalError.class) public void itShouldThrowExceptionIfNoProvidersAvailable() { ClassSearch target = new ClassSearch(); SearchPath searchPath = new SearchPath(); - target.search(list("foo"), searchPath); + target.search(list(new SearchFor("foo")), searchPath); } @Test public void itShouldFindAProviderForEachEntry() { Set searched = new HashSet<>(); ClassSearch target = new ClassSearch(); - target.addProvider(new SourceProvider() { - @Override - public ClassSource findSource(String name, SearchPath searchPath) { + target.addProvider(provider("", (name, searchPath) -> { searched.add(name); return new NoopSource(); - } - }); - target.search(list("foo", "bar", "foobar"), null); + })); + target.search(searchForList("foo", "bar", "foobar"), null); Assert.assertEquals(hashset("foo", "bar", "foobar"), searched); } + private SourceProvider provider(String supports, BiFunction fn) { + return new SourceProvider() { + @Override + public ClassSource findSource(String name, SearchPath searchPath) { + return fn.apply(name, searchPath); + } + + @Override + public boolean supports(String type) { + return supports.equals(type); + } + }; + } + @Test - public void itShouldSearchAllProviders() { + public void itShouldOnlySearchSupportedProvidersForKnownType() { Set visited = new HashSet<>(); ClassSearch target = new ClassSearch(); - target.addProvider((name, searchPath) -> { - visited.add("1"); + + target.addProvider(provider("jar", (name, searchPath) -> { + visited.add("jar"); return null; - }); - target.addProvider((name, searchPath) -> { - visited.add("2"); + })); + + target.addProvider(provider("dir", (name, searchPath) -> { + visited.add("dir"); return null; - }); + })); try { - target.search(list("foo"), null); + target.search(list(new SearchFor("some", "dir")), null); + } catch (InternalError e) { + // throws because no provider gives a source + } + + Assert.assertEquals(hashset("dir"), visited); + } + + @Test(expected = InternalError.class) + public void itShouldThrowErrorIfMultipleSourcesAreAvailable() { + ClassSearch target = new ClassSearch(); + target.addProvider(provider("", (name, searchPath) -> consumer -> Assert.fail())); + target.addProvider(provider("", (name, searchPath) -> consumer -> Assert.fail())); + + target.search(searchForList("somethign"), null); + } + + @Test + public void itShouldSearchAllProvidersForUnknownType() { + Set visited = new HashSet<>(); + ClassSearch target = new ClassSearch(); + target.addProvider(provider("", (name, searchPath) -> { + visited.add("1"); + return null; + })); + target.addProvider(provider("", (name, searchPath) -> { + visited.add("2"); + return null; + })); + + try { + target.search(searchForList("foo"), null); } catch (InternalError e) { // throws because no provider gives a source } @@ -84,6 +138,11 @@ public class ClassSearchTest { ClassSearch target = new ClassSearch(); target.addProvider(new SourceProvider() { + @Override + public boolean supports(String type) { + return true; + } + @Override public ClassSource findSource(String name, SearchPath searchPath) { return new ClassSource() { @@ -101,7 +160,7 @@ public class ClassSearchTest { } }); - java.util.List search = target.search(list("/tmp/something"), null); + java.util.List search = target.search(searchForList("/tmp/something"), null); Assert.assertEquals(list(new LoadedClass("foo.Bar", null)), search); } @@ -115,8 +174,16 @@ public class ClassSearchTest { }; ClassSearch target = new ClassSearch(); - target.addProvider((name, searchPath) -> consumer -> consumer.accept("foo.Bar", classLoader)); - target.search(list("foobar"), null); + target.addProvider(provider("", (name, searchPath) -> consumer -> consumer.accept("foo.Bar", classLoader))); + target.search(searchForList("foobar"), null); + } + + private List searchForList(String... entries) { + List list = new ArrayList<>(); + for (String entry : entries) { + list.add(new SearchFor(entry)); + } + return list; } private List list(T... entries) { diff --git a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/ClassSourceTest.java b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/ClassSourceTest.java index 5fad5f57d76..ac9b8c9d12a 100644 --- a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/ClassSourceTest.java +++ b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/ClassSourceTest.java @@ -20,6 +20,14 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + +/** + * @test + * @modules jdk.aot/jdk.tools.jaotc + * jdk.aot/jdk.tools.jaotc.collect + * @run junit/othervm jdk.tools.jaotc.test.collect.ClassSourceTest + */ + package jdk.tools.jaotc.test.collect; import org.junit.Assert; diff --git a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/FakeFileSupport.java b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/FakeFileSupport.java index 178c3d47353..0e9011ac4f3 100644 --- a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/FakeFileSupport.java +++ b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/FakeFileSupport.java @@ -27,6 +27,8 @@ import java.nio.file.Path; import java.util.HashSet; import java.util.Set; +import jdk.tools.jaotc.collect.FileSupport; + public class FakeFileSupport extends FileSupport { private final Set exists = new HashSet<>(); private final Set directories = new HashSet<>(); diff --git a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/FakeSearchPath.java b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/FakeSearchPath.java index 9a7873ccf96..899d89f6228 100644 --- a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/FakeSearchPath.java +++ b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/FakeSearchPath.java @@ -22,6 +22,8 @@ */ package jdk.tools.jaotc.test.collect; +import jdk.tools.jaotc.collect.SearchPath; + import java.nio.file.FileSystem; import java.nio.file.Path; import java.nio.file.Paths; diff --git a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/SearchPathTest.java b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/SearchPathTest.java index 8ceca8dc5cf..f3d3f56051d 100644 --- a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/SearchPathTest.java +++ b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/SearchPathTest.java @@ -20,6 +20,17 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + +/** + * @test + * @modules jdk.aot/jdk.tools.jaotc + * jdk.aot/jdk.tools.jaotc.collect + * + * @build jdk.tools.jaotc.test.collect.Utils + * @build jdk.tools.jaotc.test.collect.FakeFileSupport + * @run junit/othervm jdk.tools.jaotc.test.collect.SearchPathTest + */ + package jdk.tools.jaotc.test.collect; import org.junit.Before; @@ -30,6 +41,8 @@ import java.nio.file.FileSystems; import java.nio.file.Path; import java.nio.file.Paths; +import jdk.tools.jaotc.collect.*; + import static jdk.tools.jaotc.test.collect.Utils.set; import static org.junit.Assert.*; diff --git a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/directory/DirectorySourceProviderTest.java b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/directory/DirectorySourceProviderTest.java index 6608c01ab50..66ed4e234e2 100644 --- a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/directory/DirectorySourceProviderTest.java +++ b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/directory/DirectorySourceProviderTest.java @@ -21,11 +21,22 @@ * questions. */ +/** + * @test + * @modules jdk.aot/jdk.tools.jaotc + * jdk.aot/jdk.tools.jaotc.collect + * jdk.aot/jdk.tools.jaotc.collect.directory + * @compile ../Utils.java + * @compile ../FakeFileSupport.java + * @run junit/othervm jdk.tools.jaotc.test.collect.directory.DirectorySourceProviderTest + */ + package jdk.tools.jaotc.test.collect.directory; import jdk.tools.jaotc.collect.ClassSource; +import jdk.tools.jaotc.collect.directory.DirectorySourceProvider; import jdk.tools.jaotc.test.collect.FakeFileSupport; -import jdk.tools.jaotc.test.collect.FileSupport; +import jdk.tools.jaotc.collect.FileSupport; import org.junit.Assert; import org.junit.Test; diff --git a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/jar/JarSourceProviderTest.java b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/jar/JarSourceProviderTest.java index 14059883538..a6b687fdad4 100644 --- a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/jar/JarSourceProviderTest.java +++ b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/jar/JarSourceProviderTest.java @@ -20,9 +20,23 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + +/** + * @test + * @modules jdk.aot/jdk.tools.jaotc + * jdk.aot/jdk.tools.jaotc.collect + * jdk.aot/jdk.tools.jaotc.collect.jar + * @compile ../Utils.java + * @compile ../FakeFileSupport.java + * @compile ../FakeSearchPath.java + * + * @run junit/othervm jdk.tools.jaotc.test.collect.jar.JarSourceProviderTest + */ + package jdk.tools.jaotc.test.collect.jar; import jdk.tools.jaotc.collect.ClassSource; +import jdk.tools.jaotc.collect.jar.JarSourceProvider; import jdk.tools.jaotc.test.collect.FakeFileSupport; import jdk.tools.jaotc.test.collect.FakeSearchPath; import org.junit.Assert; diff --git a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/module/ModuleSourceProviderTest.java b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/module/ModuleSourceProviderTest.java index 80f06913269..b8a44041b19 100644 --- a/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/module/ModuleSourceProviderTest.java +++ b/hotspot/test/compiler/aot/jdk.tools.jaotc.test/src/jdk/tools/jaotc/test/collect/module/ModuleSourceProviderTest.java @@ -20,15 +20,31 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + +/** + * @test + * @modules jdk.aot/jdk.tools.jaotc + * jdk.aot/jdk.tools.jaotc.collect + * jdk.aot/jdk.tools.jaotc.collect.module + * @compile ../Utils.java + * @run junit/othervm jdk.tools.jaotc.test.collect.module.ModuleSourceProviderTest + */ + package jdk.tools.jaotc.test.collect.module; -import jdk.tools.jaotc.*; -import jdk.tools.jaotc.test.collect.FakeSearchPath; +import jdk.tools.jaotc.collect.FileSupport; +import jdk.tools.jaotc.collect.module.ModuleSource; +import jdk.tools.jaotc.collect.module.ModuleSourceProvider; import jdk.tools.jaotc.test.collect.Utils; import org.junit.Before; import org.junit.Test; +import java.io.IOException; +import java.nio.file.FileSystem; import java.nio.file.FileSystems; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.function.BiFunction; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNull; @@ -36,28 +52,42 @@ import static org.junit.Assert.assertNull; public class ModuleSourceProviderTest { private ClassLoader classLoader; private ModuleSourceProvider target; + private FileSupport fileSupport; + private BiFunction getSubDirectory = null; @Before public void setUp() { classLoader = new FakeClassLoader(); - target = new ModuleSourceProvider(FileSystems.getDefault(), classLoader); + fileSupport = new FileSupport() { + + @Override + public boolean isDirectory(Path path) { + return true; + } + + @Override + public Path getSubDirectory(FileSystem fileSystem, Path root, Path path) throws IOException { + if (getSubDirectory == null) { + throw new IOException("Nope"); + } + return getSubDirectory.apply(root, path); + } + }; + target = new ModuleSourceProvider(FileSystems.getDefault(), classLoader, fileSupport); } @Test - public void itShouldUseSearchPath() { - FakeSearchPath searchPath = new FakeSearchPath("blah/java.base"); - ModuleSource source = (ModuleSource) target.findSource("java.base", searchPath); - assertEquals(Utils.set("java.base"), searchPath.entries); - assertEquals("blah/java.base", source.getModulePath().toString()); - assertEquals("module:blah/java.base", source.toString()); - } + public void itShouldUseFileSupport() { + getSubDirectory = (root, path) -> { + if (root.toString().equals("modules") && path.toString().equals("test.module")) { + return Paths.get("modules/test.module"); + } + return null; + }; - @Test - public void itShouldReturnNullIfSearchPathReturnsNull() { - FakeSearchPath searchPath = new FakeSearchPath(null); - ModuleSource source = (ModuleSource) target.findSource("jdk.base", searchPath); - assertEquals(Utils.set("jdk.base"), searchPath.entries); - assertNull(source); + ModuleSource source = (ModuleSource) target.findSource("test.module", null); + assertEquals("modules/test.module", source.getModulePath().toString()); + assertEquals("module:modules/test.module", source.toString()); } private static class FakeClassLoader extends ClassLoader { diff --git a/hotspot/test/compiler/arraycopy/TestACSameSrcDst.java b/hotspot/test/compiler/arraycopy/TestACSameSrcDst.java new file mode 100644 index 00000000000..f85bcf27d74 --- /dev/null +++ b/hotspot/test/compiler/arraycopy/TestACSameSrcDst.java @@ -0,0 +1,106 @@ +/* + * Copyright (c) 2017, Red Hat, Inc. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8179678 + * @summary ArrayCopy with same src and dst can cause incorrect execution or compiler crash + * + * @run main/othervm -XX:CompileCommand=compileonly,TestACSameSrcDst::test* TestACSameSrcDst + * + */ + +public class TestACSameSrcDst { + + static int test1(int[] src, int[] dst) { + System.arraycopy(src, 5, dst, 0, 10); + // this shouldn't be transformed to src[5] because the copy + // can modify src[5] if src and dst are the same. + return dst[0]; + } + + static int test2(int[] src) { + System.arraycopy(src, 0, src, 0, 10); + // same source and destination. If load from destination is + // transformed to load of source, the compiler performs that + // optimization in an infinite loop. + return src[0]; + } + + static int test3() { + int[] src = new int[15]; + src[5] = 0x42; + System.arraycopy(src, 5, src, 0, 10); + // That load can't bypass the arraycopy + return src[0]; + } + + static int test4() { + int[] src = new int[15]; + System.arraycopy(src, 0, src, 5, 10); + return src[0]; + } + + // The dst[0] load can't bypass the arraycopy. After ArrayCopyNode + // is expanded, C2 looks for a stub call on the control paths of + // the array copy subgraph to decide whether the load's memory + // input can bypass the arraycopy. This test verifies the case of + // a source array that's not declared as an array. + static int test5(Object src, int l, boolean flag) { + int[] dst = new int[10]; + if (flag) { + dst[0] = 0x42; + System.arraycopy(src, 0, dst, 0, l); + return dst[0]; + } + return 0; + } + + public static void main(String[] args) { + int[] array = new int[15]; + for (int i = 0; i < 20000; i++) { + int res; + for (int j = 0; j < array.length; j++) { + array[j] = j; + } + int expected = array[5]; + res = test1(array, array); + if (res != expected) { + throw new RuntimeException("bad result: " + res + " != " + expected); + } + test2(array); + res = test3(); + if (res != 0x42) { + throw new RuntimeException("bad result: " + res + " != " + 0x42); + } + test4(); + for (int j = 0; j < array.length; j++) { + array[j] = j; + } + res = test5(array, 10, (i%2) == 0); + if (res != 0) { + throw new RuntimeException("bad result: " + res + " != " + 0); + } + } + } +} diff --git a/hotspot/test/compiler/arraycopy/TestDefaultMethodArrayCloneDeoptC2.java b/hotspot/test/compiler/arraycopy/TestDefaultMethodArrayCloneDeoptC2.java new file mode 100644 index 00000000000..c4100ad2f80 --- /dev/null +++ b/hotspot/test/compiler/arraycopy/TestDefaultMethodArrayCloneDeoptC2.java @@ -0,0 +1,117 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8170455 + * @summary C2: Access to [].clone from interfaces fails. + * @library /test/lib / + * + * @requires vm.flavor == "server" & !vm.emulatedClient + * @build sun.hotspot.WhiteBox + * @run driver ClassFileInstaller sun.hotspot.WhiteBox sun.hotspot.WhiteBox$WhiteBoxPermission + * @run main/othervm -Xcomp -Xbatch -Xbootclasspath/a:. -XX:-TieredCompilation -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI + * -XX:CompileCommand=compileonly,*TestDefaultMethodArrayCloneDeoptC2Interface::test + * compiler.arraycopy.TestDefaultMethodArrayCloneDeoptC2 + */ + +package compiler.arraycopy; + +import sun.hotspot.WhiteBox; +import java.lang.reflect.Method; +import compiler.whitebox.CompilerWhiteBoxTest; + + + +interface TestDefaultMethodArrayCloneDeoptC2Interface { + default int[] test(int[] arr) { + return arr.clone(); + } + + default TDMACDC2InterfaceTypeTest[] test(TDMACDC2InterfaceTypeTest[] arr) { + return arr.clone(); + } + + default TDMACDC2ClassTypeTest[] test(TDMACDC2ClassTypeTest[] arr) { + return arr.clone(); + } +} + +public class TestDefaultMethodArrayCloneDeoptC2 implements TestDefaultMethodArrayCloneDeoptC2Interface { + private static final WhiteBox WB = WhiteBox.getWhiteBox(); + public static TestDefaultMethodArrayCloneDeoptC2 a = new TestDefaultMethodArrayCloneDeoptC2(); + + public static void main(String[] args) throws Exception { + testPrimitiveArr(); + testIntfArr(); + testClassArr(); + } + + public static void testPrimitiveArr() throws Exception { + Method m = TestDefaultMethodArrayCloneDeoptC2Interface.class.getMethod("test", int[].class); + a.test(new int[1]); // Compiled + a.test(new int[1]); + if (!WB.isMethodCompiled(m)) { + WB.enqueueMethodForCompilation(m, CompilerWhiteBoxTest.COMP_LEVEL_FULL_OPTIMIZATION); + } + a.test(new int[1]); + if (!WB.isMethodCompiled(m)) { + throw new Exception("Method should be compiled"); + } + } + + public static void testIntfArr() throws Exception { + Method m = TestDefaultMethodArrayCloneDeoptC2Interface.class.getMethod("test", TDMACDC2InterfaceTypeTest[].class); + a.test(new TDMACDC2InterfaceTypeTest[1]); // Compiled, Decompile unloaded + a.test(new TDMACDC2InterfaceTypeTest[1]); // Compiled + a.test(new TDMACDC2InterfaceTypeTest[1]); + if (!WB.isMethodCompiled(m)) { + WB.enqueueMethodForCompilation(m, CompilerWhiteBoxTest.COMP_LEVEL_FULL_OPTIMIZATION); + } + a.test(new TDMACDC2InterfaceTypeTest[1]); + if (!WB.isMethodCompiled(m)) { + throw new Exception("Method should be compiled"); + } + } + + public static void testClassArr() throws Exception { + Method m = TestDefaultMethodArrayCloneDeoptC2Interface.class.getMethod("test", TDMACDC2ClassTypeTest[].class); + a.test(new TDMACDC2ClassTypeTest[1]); // Compiled, Decompile unloaded + a.test(new TDMACDC2ClassTypeTest[1]); // Compiled + a.test(new TDMACDC2ClassTypeTest[1]); + if (!WB.isMethodCompiled(m)) { + WB.enqueueMethodForCompilation(m, CompilerWhiteBoxTest.COMP_LEVEL_FULL_OPTIMIZATION); + } + a.test(new TDMACDC2ClassTypeTest[1]); + if (!WB.isMethodCompiled(m)) { + throw new Exception("Method should be compiled"); + } + } +} + +interface TDMACDC2InterfaceTypeTest { +} + +class TDMACDC2ClassTypeTest { +} + diff --git a/hotspot/test/compiler/arraycopy/TestObjectArrayCopy.java b/hotspot/test/compiler/arraycopy/TestObjectArrayCopy.java new file mode 100644 index 00000000000..0cc8475692b --- /dev/null +++ b/hotspot/test/compiler/arraycopy/TestObjectArrayCopy.java @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2017, SAP SE and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176505 + * @summary Wrong assertion 'should be an array copy/clone' in arraycopynode.cpp + * + * @run main/othervm -Xbatch -XX:-UseOnStackReplacement compiler.arraycopy.TestObjectArrayCopy + * + * @author Volker Simonis + */ + +package compiler.arraycopy; + +public class TestObjectArrayCopy { + + public static boolean crash(Object src) { + String[] dst = new String[1]; + System.arraycopy(src, 0, dst, 0, 1); + return dst[0] == null; + } + + public static void main(String[] args) { + String[] sa = new String[1]; + for (int i = 0; i < 20_000; i++) { + crash(sa); + } + } +} diff --git a/hotspot/test/compiler/c1/TestUnresolvedField.jasm b/hotspot/test/compiler/c1/TestUnresolvedField.jasm new file mode 100644 index 00000000000..e6c2ae4de2b --- /dev/null +++ b/hotspot/test/compiler/c1/TestUnresolvedField.jasm @@ -0,0 +1,38 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + * + */ + +public class compiler/c1/TestUnresolvedField version 52:0 { + public static Method testGetField:"()V" stack 1 locals 1 { + aconst_null; + getfield Field T.f:I; // T does not exist + return; + } + + public static Method testPutField:"()V" stack 2 locals 1 { + aconst_null; + iconst_0; + putfield Field T.f:I; // T does not exist + return; + } +} diff --git a/hotspot/test/compiler/c1/TestUnresolvedFieldMain.java b/hotspot/test/compiler/c1/TestUnresolvedFieldMain.java new file mode 100644 index 00000000000..040f1b17be6 --- /dev/null +++ b/hotspot/test/compiler/c1/TestUnresolvedFieldMain.java @@ -0,0 +1,48 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8173373 + * @compile TestUnresolvedField.jasm + * @run main/othervm -XX:TieredStopAtLevel=1 -Xcomp + * -XX:CompileCommand=compileonly,compiler.c1.TestUnresolvedField::test* + * compiler.c1.TestUnresolvedFieldMain + */ + +package compiler.c1; + +public class TestUnresolvedFieldMain { + public static void main(String[] args) { + try { + TestUnresolvedField.testGetField(); + } catch (java.lang.NoClassDefFoundError error) { + // Expected + } + try { + TestUnresolvedField.testPutField(); + } catch (java.lang.NoClassDefFoundError error) { + // Expected + } + } +} diff --git a/hotspot/test/compiler/c1/UnsafeVolatileGuardTest.java b/hotspot/test/compiler/c1/UnsafeVolatileGuardTest.java new file mode 100644 index 00000000000..b10c4a6285c --- /dev/null +++ b/hotspot/test/compiler/c1/UnsafeVolatileGuardTest.java @@ -0,0 +1,69 @@ +/* + * Copyright (c) 2017, Red Hat Inc. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.lang.reflect.Field; + +/** + * @test + * @bug 8175887 + * @summary C1 value numbering handling of Unsafe.get*Volatile is incorrect + * @modules java.base/jdk.internal.misc + * @run main/othervm -XX:+IgnoreUnrecognizedVMOptions -XX:TieredStopAtLevel=1 UnsafeVolatileGuardTest + */ +public class UnsafeVolatileGuardTest { + volatile static private int a; + static private int b; + + static final jdk.internal.misc.Unsafe UNSAFE = jdk.internal.misc.Unsafe.getUnsafe(); + + static final Object BASE; + static final long OFFSET; + + static { + try { + Field f = UnsafeVolatileGuardTest.class.getDeclaredField("a"); + BASE = UNSAFE.staticFieldBase(f); + OFFSET = UNSAFE.staticFieldOffset(f); + } catch (Exception e) { + throw new RuntimeException(e); + } + } + + static void test() { + int tt = b; // makes the JVM CSE the value of b + + while (UNSAFE.getIntVolatile(BASE, OFFSET) == 0) {} // burn + if (b == 0) { + System.err.println("wrong value of b"); + System.exit(1); // fail hard to report the error + } + } + + public static void main(String [] args) throws Exception { + for (int i = 0; i < 10; i++) { + new Thread(UnsafeVolatileGuardTest::test).start(); + } + b = 1; + a = 1; + } +} diff --git a/jdk/test/java/net/URLClassLoader/B5077773.java b/hotspot/test/compiler/c1/VolatileGuardTest.java similarity index 55% rename from jdk/test/java/net/URLClassLoader/B5077773.java rename to hotspot/test/compiler/c1/VolatileGuardTest.java index 28a4a4ca374..44b603160ad 100644 --- a/jdk/test/java/net/URLClassLoader/B5077773.java +++ b/hotspot/test/compiler/c1/VolatileGuardTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Red Hat Inc. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,25 +21,32 @@ * questions. */ -import java.io.*; -import java.net.*; +/** + * @test + * @bug 8175887 + * @summary C1 doesn't respect the JMM with volatile field loads + * + * @run main/othervm -XX:+IgnoreUnrecognizedVMOptions -XX:TieredStopAtLevel=1 VolatileGuardTest + */ +public class VolatileGuardTest { + volatile static private int a; + static private int b; -public class B5077773 { + static void test() { + int tt = b; // makes the JVM CSE the value of b - public static void main(String[] args) throws Exception { - URLClassLoader loader = new URLClassLoader (new URL[] {new URL("file:foo.jar")}); - /* This test will fail if the file below is removed from rt.jar */ - InputStream is = loader.getResourceAsStream ("javax/swing/text/rtf/charsets/mac.txt"); - if (is == null) { - System.out.println ("could not find mac.txt"); - return; - } - int c=0; - while ((is.read()) != -1) { - c++; - } - if (c == 26) /* size of bad file */ { - throw new RuntimeException ("Wrong mac.txt file was loaded"); + while (a == 0) {} // burn + if (b == 0) { + System.err.println("wrong value of b"); + System.exit(1); // fail hard to report the error } } + + public static void main(String [] args) throws Exception { + for (int i = 0; i < 10; i++) { + new Thread(VolatileGuardTest::test).start(); + } + b = 1; + a = 1; + } } diff --git a/hotspot/test/compiler/c2/TestNPEHeapBased.java b/hotspot/test/compiler/c2/TestNPEHeapBased.java new file mode 100644 index 00000000000..0fdb5d3da37 --- /dev/null +++ b/hotspot/test/compiler/c2/TestNPEHeapBased.java @@ -0,0 +1,64 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017 SAP SE. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8176518 + * @summary Invalid ImplicitNullChecks when heap base not protected + * + * @run main/othervm -XX:ObjectAlignmentInBytes=16 -XX:HeapBaseMinAddress=64g + * -XX:-TieredCompilation -Xbatch + * compiler.c2.TestNPEHeapBased + * @requires vm.bits == "64" + */ + +package compiler.c2; +public class TestNPEHeapBased { + + TestNPEHeapBased instance = null; + int i = 0; + + public void set_i(int value) { + instance.i = value; + } + + + static final int loop_cnt = 200000; + + public static void main(String args[]){ + TestNPEHeapBased xyz = new TestNPEHeapBased(); + xyz.instance = xyz; + for (int x = 0; x < loop_cnt; x++) xyz.set_i(x); + xyz.instance = null; + try { + xyz.set_i(0); + } catch (NullPointerException npe) { + System.out.println("Got expected NullPointerException:"); + npe.printStackTrace(); + return; + } + throw new InternalError("NullPointerException is missing!"); + } + +} diff --git a/hotspot/test/compiler/c2/TestReplacedNodesOSR.java b/hotspot/test/compiler/c2/TestReplacedNodesOSR.java new file mode 100644 index 00000000000..926295e496e --- /dev/null +++ b/hotspot/test/compiler/c2/TestReplacedNodesOSR.java @@ -0,0 +1,86 @@ +/* + * Copyright (c) 2017, Red Hat, Inc. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8174164 + * @summary SafePointNode::_replaced_nodes breaks with irreducible loops + * @run main/othervm -XX:-BackgroundCompilation TestReplacedNodesOSR + * + */ + +public class TestReplacedNodesOSR { + + static Object dummy; + + static interface I { + } + + static class A implements I { + } + + static final class MyException extends Exception { + } + + static final A obj = new A(); + static I static_field() { return obj; } + + // When OSR compiled, this method has an irreducible loop + static void test(int v, MyException e) { + int i = 0; + for (;;) { + if (i == 1000) { + break; + } + try { + if ((i%2) == 0) { + int j = 0; + for (;;) { + j++; + if (i+j != v) { + if (j == 1000) { + break; + } + } else { + A a = (A)static_field(); + // replaced node recorded here + throw e; + } + } + } + } catch(MyException ex) { + } + i++; + // replaced node applied on return of the method + // replaced node used here + dummy = static_field(); + } + } + + + static public void main(String[] args) { + for (int i = 0; i < 1000; i++) { + test(1100, new MyException()); + } + } +} diff --git a/hotspot/test/compiler/c2/cr7200264/TestDriver.java b/hotspot/test/compiler/c2/cr7200264/TestDriver.java index 558592ba693..bc8a987ffb2 100644 --- a/hotspot/test/compiler/c2/cr7200264/TestDriver.java +++ b/hotspot/test/compiler/c2/cr7200264/TestDriver.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,6 @@ package compiler.c2.cr7200264; import java.util.HashMap; import java.util.List; import java.util.Map; -import java.util.regex.Pattern; import jdk.test.lib.Asserts; import jdk.test.lib.process.OutputAnalyzer; @@ -45,7 +44,7 @@ public class TestDriver { } private List executeApplication() throws Throwable { - OutputAnalyzer outputAnalyzer = ProcessTools.executeTestJvmAllArgs( + OutputAnalyzer outputAnalyzer = ProcessTools.executeTestJvm( "-Xbatch", "-XX:-TieredCompilation", "-XX:+PrintCompilation", diff --git a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeDynamic2NativeTest.java b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeDynamic2NativeTest.java index 4c81223b565..5009ba634bf 100644 --- a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeDynamic2NativeTest.java +++ b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeDynamic2NativeTest.java @@ -32,10 +32,10 @@ * @run main compiler.calls.common.InvokeDynamicPatcher * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeDynamic * -compileCaller 1 -checkCallerCompileLevel 1 -nativeCallee - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeDynamic * -compileCaller 4 -checkCallerCompileLevel 4 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeInterface2NativeTest.java b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeInterface2NativeTest.java index 2544b4cc3d8..3387d3e800d 100644 --- a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeInterface2NativeTest.java +++ b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeInterface2NativeTest.java @@ -30,10 +30,10 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeInterface * -compileCaller 1 -checkCallerCompileLevel 1 -nativeCallee - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeInterface * -compileCaller 4 -checkCallerCompileLevel 4 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeSpecial2NativeTest.java b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeSpecial2NativeTest.java index 301811399c2..4948890a985 100644 --- a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeSpecial2NativeTest.java +++ b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeSpecial2NativeTest.java @@ -30,10 +30,10 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeSpecial * -compileCaller 1 -checkCallerCompileLevel 1 -nativeCallee - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeSpecial * -compileCaller 4 -checkCallerCompileLevel 4 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeStatic2NativeTest.java b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeStatic2NativeTest.java index a40d9d41090..563c4c4091f 100644 --- a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeStatic2NativeTest.java +++ b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeStatic2NativeTest.java @@ -30,10 +30,10 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeStatic * -compileCaller 1 -checkCallerCompileLevel 1 -nativeCallee - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeStatic * -compileCaller 4 -checkCallerCompileLevel 4 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeVirtual2NativeTest.java b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeVirtual2NativeTest.java index c82f056bd24..4a1f046583e 100644 --- a/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeVirtual2NativeTest.java +++ b/hotspot/test/compiler/calls/fromCompiled/CompiledInvokeVirtual2NativeTest.java @@ -30,10 +30,10 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeVirtual * -compileCaller 1 -checkCallerCompileLevel 1 -nativeCallee - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeVirtual * -compileCaller 4 -checkCallerCompileLevel 4 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeDynamic2NativeTest.java b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeDynamic2NativeTest.java index 1d5ac09b6c1..b59a4f96ff9 100644 --- a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeDynamic2NativeTest.java +++ b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeDynamic2NativeTest.java @@ -32,7 +32,7 @@ * @run main compiler.calls.common.InvokeDynamicPatcher * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -XX:CompileCommand=exclude,compiler.calls.common.InvokeDynamic::caller compiler.calls.common.InvokeDynamic * -checkCallerCompileLevel 0 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeInterface2NativeTest.java b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeInterface2NativeTest.java index b03e5bd5ec2..63ab11a5a47 100644 --- a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeInterface2NativeTest.java +++ b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeInterface2NativeTest.java @@ -30,7 +30,7 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -XX:CompileCommand=exclude,compiler.calls.common.InvokeInterface::caller compiler.calls.common.InvokeInterface * -checkCallerCompileLevel 0 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeSpecial2NativeTest.java b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeSpecial2NativeTest.java index 8593ebc2551..c7dda1f3faa 100644 --- a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeSpecial2NativeTest.java +++ b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeSpecial2NativeTest.java @@ -30,7 +30,7 @@ * @build compiler.calls.common.InvokeSpecial * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -XX:CompileCommand=exclude,compiler.calls.common.InvokeSpecial::caller compiler.calls.common.InvokeSpecial * -checkCallerCompileLevel 0 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeStatic2NativeTest.java b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeStatic2NativeTest.java index a17e9c5c2a7..ca2613b14a2 100644 --- a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeStatic2NativeTest.java +++ b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeStatic2NativeTest.java @@ -30,7 +30,7 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -XX:CompileCommand=exclude,compiler.calls.common.InvokeStatic::caller compiler.calls.common.InvokeStatic * -checkCallerCompileLevel 0 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeVirtual2NativeTest.java b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeVirtual2NativeTest.java index 9ebf7a359c8..c983efd890f 100644 --- a/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeVirtual2NativeTest.java +++ b/hotspot/test/compiler/calls/fromInterpreted/InterpretedInvokeVirtual2NativeTest.java @@ -30,7 +30,7 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -XX:CompileCommand=exclude,compiler.calls.common.InvokeVirtual::caller compiler.calls.common.InvokeVirtual * -checkCallerCompileLevel 0 -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2CompiledTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2CompiledTest.java index 74007716168..1ddea48c639 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2CompiledTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2CompiledTest.java @@ -30,10 +30,10 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeSpecial * -nativeCaller -compileCallee 1 -checkCalleeCompileLevel 1 - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeSpecial * -nativeCaller -compileCallee 4 -checkCalleeCompileLevel 4 */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2InterpretedTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2InterpretedTest.java index 4efd098904d..961daf545bd 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2InterpretedTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2InterpretedTest.java @@ -30,7 +30,7 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -XX:CompileCommand=exclude,compiler.calls.common.InvokeSpecial::callee compiler.calls.common.InvokeSpecial * -nativeCaller -checkCalleeCompileLevel 0 */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2NativeTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2NativeTest.java index 1005783754c..bde00f6da43 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2NativeTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeSpecial2NativeTest.java @@ -30,7 +30,7 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * compiler.calls.common.InvokeSpecial * -nativeCaller -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2CompiledTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2CompiledTest.java index f1f0634e9f0..f86ca89896c 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2CompiledTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2CompiledTest.java @@ -30,10 +30,10 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeStatic * -nativeCaller -compileCallee 1 -checkCalleeCompileLevel 1 - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeStatic * -nativeCaller -compileCallee 4 -checkCalleeCompileLevel 4 */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2InterpretedTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2InterpretedTest.java index fc0a0592072..fff52824542 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2InterpretedTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2InterpretedTest.java @@ -30,7 +30,7 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -XX:CompileCommand=exclude,compiler.calls.common.InvokeStatic::callee compiler.calls.common.InvokeStatic * -nativeCaller -checkCalleeCompileLevel 0 */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2NativeTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2NativeTest.java index f9da3d65c98..3d106fdf12b 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2NativeTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeStatic2NativeTest.java @@ -30,7 +30,7 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * compiler.calls.common.InvokeStatic * -nativeCaller -nativeCallee */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2CompiledTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2CompiledTest.java index b6cce29b413..7b744249c3c 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2CompiledTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2CompiledTest.java @@ -30,10 +30,10 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeVirtual * -nativeCaller -compileCallee 1 -checkCalleeCompileLevel 1 - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -Xbatch compiler.calls.common.InvokeVirtual * -nativeCaller -compileCallee 4 -checkCalleeCompileLevel 4 */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2InterpretedTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2InterpretedTest.java index 270ecfa6f35..43be4d49c4e 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2InterpretedTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2InterpretedTest.java @@ -30,7 +30,7 @@ * * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * -XX:CompileCommand=exclude,compiler.calls.common.InvokeVirtual::callee compiler.calls.common.InvokeVirtual * -nativeCaller -checkCalleeCompileLevel 0 */ diff --git a/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2NativeTest.java b/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2NativeTest.java index 83564c143b2..9b9fe1a44df 100644 --- a/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2NativeTest.java +++ b/hotspot/test/compiler/calls/fromNative/NativeInvokeVirtual2NativeTest.java @@ -30,7 +30,7 @@ * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * @run main/othervm/native -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. * compiler.calls.common.InvokeVirtual * -nativeCaller -nativeCallee */ diff --git a/hotspot/test/compiler/ciReplay/SABase.java b/hotspot/test/compiler/ciReplay/SABase.java index 0354835b8f9..57690848489 100644 --- a/hotspot/test/compiler/ciReplay/SABase.java +++ b/hotspot/test/compiler/ciReplay/SABase.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -141,7 +141,7 @@ public class SABase extends CiReplayBase { if (Platform.isSolaris()) { try { OutputAnalyzer oa = ProcessTools.executeProcess("coreadm", "-p", "core", - "" + ProcessHandle.current().getPid()); + "" + ProcessHandle.current().pid()); oa.shouldHaveExitValue(0); } catch (Throwable t) { throw new Error("Can't launch coreadm: " + t, t); diff --git a/hotspot/test/compiler/codecache/stress/CodeCacheStressRunner.java b/hotspot/test/compiler/codecache/stress/CodeCacheStressRunner.java index 9f34a8681de..24ec37b89d4 100644 --- a/hotspot/test/compiler/codecache/stress/CodeCacheStressRunner.java +++ b/hotspot/test/compiler/codecache/stress/CodeCacheStressRunner.java @@ -23,7 +23,7 @@ package compiler.codecache.stress; -import jdk.test.lib.wrappers.TimeLimitedRunner; +import jdk.test.lib.TimeLimitedRunner; import jdk.test.lib.Utils; public class CodeCacheStressRunner { diff --git a/hotspot/test/compiler/codecache/stress/Helper.java b/hotspot/test/compiler/codecache/stress/Helper.java index d9fb8d3a843..e759378ffda 100644 --- a/hotspot/test/compiler/codecache/stress/Helper.java +++ b/hotspot/test/compiler/codecache/stress/Helper.java @@ -25,7 +25,7 @@ package compiler.codecache.stress; import jdk.test.lib.Asserts; import jdk.test.lib.ByteCodeLoader; -import jdk.test.lib.wrappers.InfiniteLoop; +import jdk.test.lib.InfiniteLoop; import jdk.test.lib.Utils; import sun.hotspot.WhiteBox; diff --git a/hotspot/test/compiler/codecache/stress/ReturnBlobToWrongHeapTest.java b/hotspot/test/compiler/codecache/stress/ReturnBlobToWrongHeapTest.java new file mode 100644 index 00000000000..52ccab6aff8 --- /dev/null +++ b/hotspot/test/compiler/codecache/stress/ReturnBlobToWrongHeapTest.java @@ -0,0 +1,89 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test ReturnBlobToWrongHeapTest + * @key stress + * @summary Test if VM attempts to return code blobs to an incorrect code heap or to outside of the code cache. + * @library /test/lib / + * @modules java.base/jdk.internal.misc + * java.management + * + * @build sun.hotspot.WhiteBox + * @run driver ClassFileInstaller sun.hotspot.WhiteBox + * sun.hotspot.WhiteBox$WhiteBoxPermission + * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions + * -XX:+WhiteBoxAPI + * -XX:CompileCommand=dontinline,compiler.codecache.stress.Helper$TestCase::method + * -XX:+SegmentedCodeCache + * -XX:ReservedCodeCacheSize=16M + * -XX:CodeCacheMinBlockLength=1 + * compiler.codecache.stress.ReturnBlobToWrongHeapTest + */ + +package compiler.codecache.stress; + +import sun.hotspot.code.BlobType; + +import java.util.ArrayList; + +public class ReturnBlobToWrongHeapTest { + private static final long largeBlobSize = Helper.WHITE_BOX.getUintxVMFlag("ReservedCodeCacheSize") >> 6; + private static final long codeCacheMinBlockLength = Helper.WHITE_BOX.getUintxVMFlag("CodeCacheMinBlockLength"); + private static final BlobType[] BLOB_TYPES = BlobType.getAvailable().toArray(new BlobType[0]); + + // Allocate blob in first code heap (the code heap with index 0). + private static long allocate(int size) { + return Helper.WHITE_BOX.allocateCodeBlob(size, BLOB_TYPES[0].id); + } + + // Free blob. + private static void free(long address) { + Helper.WHITE_BOX.freeCodeBlob(address); + } + + public static void main(String[] args) { + if (codeCacheMinBlockLength == 1) { + // Fill first code heap with large blobs until allocation fails. + long address; + while ((address = allocate((int)largeBlobSize)) != 0) { + } + + // Allocate segment-sized blocks in first code heap. + long lastSegmentSizedAddress = 0; // Address of the last segment-sized blob allocated + while ((address = allocate(0)) != 0) { + lastSegmentSizedAddress = address; + } + + if (lastSegmentSizedAddress == 0) { + throw new RuntimeException("Test failed: Not possible to allocate segment-sized blob"); + } + + // Remove last segment-sized block from the first code heap. + free(lastSegmentSizedAddress); + } else { + throw new RuntimeException("Test requires CodeCacheMinBlockLength==1; CodeCacheMinBlockLength is " + + codeCacheMinBlockLength); + } + } +} diff --git a/hotspot/test/compiler/compilercontrol/jcmd/StressAddJcmdBase.java b/hotspot/test/compiler/compilercontrol/jcmd/StressAddJcmdBase.java index 30baaed7684..cfd9e1c4bb0 100644 --- a/hotspot/test/compiler/compilercontrol/jcmd/StressAddJcmdBase.java +++ b/hotspot/test/compiler/compilercontrol/jcmd/StressAddJcmdBase.java @@ -29,7 +29,7 @@ import compiler.compilercontrol.share.method.MethodDescriptor; import compiler.compilercontrol.share.pool.PoolHelper; import compiler.compilercontrol.share.scenario.Executor; import jdk.test.lib.process.OutputAnalyzer; -import jdk.test.lib.wrappers.TimeLimitedRunner; +import jdk.test.lib.TimeLimitedRunner; import jdk.test.lib.Utils; import java.util.ArrayList; diff --git a/hotspot/test/compiler/compilercontrol/share/scenario/Executor.java b/hotspot/test/compiler/compilercontrol/share/scenario/Executor.java index fbd3f13259b..19ebd612e7c 100644 --- a/hotspot/test/compiler/compilercontrol/share/scenario/Executor.java +++ b/hotspot/test/compiler/compilercontrol/share/scenario/Executor.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,7 @@ package compiler.compilercontrol.share.scenario; import compiler.compilercontrol.share.actions.BaseAction; import jdk.test.lib.Asserts; +import jdk.test.lib.management.InputArguments; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; import jdk.test.lib.dcmd.CommandExecutor; @@ -38,6 +39,7 @@ import java.lang.reflect.Executable; import java.net.ServerSocket; import java.net.Socket; import java.util.ArrayList; +import java.util.Arrays; import java.util.Collections; import java.util.List; import java.util.Map; @@ -97,9 +99,13 @@ public class Executor { // Start separate thread to connect with test VM new Thread(() -> connectTestVM(serverSocket)).start(); } - // Start test VM - output = ProcessTools.executeTestJvmAllArgs( - vmOptions.toArray(new String[vmOptions.size()])); + // Start a test VM using vm flags from @run and from vm options + String[] vmInputArgs = InputArguments.getVmInputArgs(); + String[] cmds = Arrays.copyOf(vmInputArgs, + vmInputArgs.length + vmOptions.size()); + System.arraycopy(vmOptions.toArray(), 0, cmds, vmInputArgs.length, + vmOptions.size()); + output = ProcessTools.executeTestJvm(cmds); } catch (Throwable thr) { throw new Error("Execution failed: " + thr.getMessage(), thr); } diff --git a/hotspot/test/compiler/intrinsics/string/TestStringUTF16IntrinsicRangeChecks.java b/hotspot/test/compiler/intrinsics/string/TestStringUTF16IntrinsicRangeChecks.java new file mode 100644 index 00000000000..86de75132ea --- /dev/null +++ b/hotspot/test/compiler/intrinsics/string/TestStringUTF16IntrinsicRangeChecks.java @@ -0,0 +1,320 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8158168 + * @summary Verifies that callers of StringUTF16 intrinsics throw array out of bounds exceptions. + * @library /compiler/patches /test/lib + * @build java.base/java.lang.Helper + * @run main/othervm -Xbatch -XX:CompileThreshold=100 -XX:+UnlockDiagnosticVMOptions -XX:DisableIntrinsic=_getCharStringU,_putCharStringU compiler.intrinsics.string.TestStringUTF16IntrinsicRangeChecks + * @run main/othervm -Xbatch -XX:CompileThreshold=100 -esa -ea -XX:+UnlockDiagnosticVMOptions -XX:DisableIntrinsic=_getCharStringU,_putCharStringU compiler.intrinsics.string.TestStringUTF16IntrinsicRangeChecks + */ +package compiler.intrinsics.string; + +import java.lang.reflect.Field; +import java.util.Arrays; + +public class TestStringUTF16IntrinsicRangeChecks { + + public static void main(String[] args) throws Exception { + byte[] val = new byte[2]; + byte[] b4 = new byte[4]; + char[] c4 = new char[4]; + String s4 = new String(c4); + byte[] valHigh = new byte[2]; + byte[] valLow = new byte[2]; + Helper.putCharSB(valHigh, 0, Character.MIN_HIGH_SURROGATE); + Helper.putCharSB(valLow, 0, Character.MIN_LOW_SURROGATE); + + for (int i = 0; i < 1000; ++i) { + getChars((int)1234, -5, -5 + 4, val); + getChars((int)1234, -1, -1 + 4, val); + getChars((int)1234, 0, 0 + 4, val); + getChars((int)1234, 1, 1 + 4, val); + + getChars((long)1234, -5, -5 + 4, val); + getChars((long)1234, -1, -1 + 4, val); + getChars((long)1234, 0, 0 + 4, val); + getChars((long)1234, 1, 1 + 4, val); + + byte[] val2 = Arrays.copyOf(val, val.length); + putCharSB(val2, -1, '!'); + putCharSB(val2, 1, '!'); + + byte[] val4 = Arrays.copyOf(b4, b4.length); + char[] c2 = new char[2]; + String s2 = new String(c2); + + putCharsSB(val4, -3, c2, 0, 2); + putCharsSB(val4, -1, c2, 0, 2); + putCharsSB(val4, 0, c4, 0, 4); + putCharsSB(val4, 1, c2, 0, 2); + putCharsSB(val4, -3, s2, 0, 2); + putCharsSB(val4, -1, s2, 0, 2); + putCharsSB(val4, 0, s4, 0, 4); + putCharsSB(val4, 1, s2, 0, 2); + + codePointAtSB(valHigh, -1, 1); + codePointAtSB(valHigh, -1, 2); + codePointAtSB(valHigh, 0, 2); + codePointAtSB(valHigh, 1, 2); + + codePointBeforeSB(valLow, 0); + codePointBeforeSB(valLow, -1); + codePointBeforeSB(valLow, 2); + + if (Helper.codePointCountSB(valHigh, 0, 1) != 1) { + throw new AssertionError("codePointCountSB"); + } + if (Helper.codePointCountSB(valLow, 0, 1) != 1) { + throw new AssertionError("codePointCountSB"); + } + codePointCountSB(valHigh, -1, 0); + codePointCountSB(valHigh, -1, 2); + codePointCountSB(valHigh, 0, 2); + + charAt(val, -1); + charAt(val, 1); + + contentEquals(b4, val, -1); + contentEquals(b4, val, 2); + contentEquals(val, s4, 2); + contentEquals(val, s4, -1); + + StringBuilder sb = new StringBuilder(); + sb.append((String)null).append(true).append(false); + if (!sb.toString().equals("nulltruefalse")) { + throw new AssertionError("append"); + } + + putCharsAt(val2, -1, '1', '2', '3', '4'); + putCharsAt(val2, 0, '1', '2', '3', '4'); + putCharsAt(val2, 2, '1', '2', '3', '4'); + putCharsAt(val2, -1, '1', '2', '3', '4', '5'); + putCharsAt(val2, 0, '1', '2', '3', '4', '5'); + putCharsAt(val2, 2, '1', '2', '3', '4', '5'); + + reverse(valHigh, -1); + reverse(valHigh, 2); + reverse(valLow, -1); + reverse(valLow, 2); + + byte[] d4 = new byte[4]; + inflate(b4, 0, d4, -1, 2); + inflate(b4, 0, d4, 3, 2); + inflate(b4, 0, d4, 4, 1); + + byte[] b0 = new byte[0]; + byte[] b1 = new byte[1]; + byte[] b2 = new byte[2]; + byte[] t1 = new byte[] {1}; + byte[] t2 = new byte[] {1, 2}; + byte[] t4 = new byte[] {1, 2, 3, 4}; + indexOf(b1, 1, t2, 1, 0); + indexOf(b2, 1, t1, 1, 0); + indexOf(b2, 2, t2, 1, 0); + indexOf(b2, 1, t2, 2, 0); + indexOf(b2, -1, t2, 1, 0); + indexOf(b2, 1, t2, -1, 0); + indexOf(b2, 1, t2, 1, 1); + + indexOfLatin1(b1, 1, t1, 1, 0); + indexOfLatin1(b2, 2, t1, 1, 0); + indexOfLatin1(b2, 1, b0, 1, 0); + indexOfLatin1(b2, 1, t1, 2, 0); + indexOfLatin1(b2, -1, t1, 1, 0); + indexOfLatin1(b2, 2, t1, 1, 0); + indexOfLatin1(b2, 1, t1, -1, 0); + indexOfLatin1(b2, 1, t1, 2, 0); + + lastIndexOf(b1, t2, 1, 0); + lastIndexOf(b2, t4, 2, 0); + lastIndexOf(b2, t2, 1, 0); + lastIndexOf(b2, t2, 1, 1); + + lastIndexOfLatin1(b1, t1, 1, 0); + lastIndexOfLatin1(b2, t2, 2, 0); + lastIndexOfLatin1(b2, t1, 1, 0); + lastIndexOfLatin1(b2, t1, 1, 1); + } + } + + static void getChars(int i, int begin, int end, byte[] value) { + try { + Helper.getChars(i, begin, end, value); + throw new AssertionError("getChars"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void getChars(long l, int begin, int end, byte[] value) { + try { + Helper.getChars(l, begin, end, value); + throw new AssertionError("getChars"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void putCharSB(byte[] val, int index, int c) { + try { + Helper.putCharSB(val, index, c); + throw new AssertionError("putCharSB"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void putCharsSB(byte[] val, int index, char[] ca, int off, int end) { + try { + Helper.putCharsSB(val, index, ca, off, end); + throw new AssertionError("putCharsSB"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void putCharsSB(byte[] val, int index, CharSequence s, int off, int end) { + try { + Helper.putCharsSB(val, index, s, off, end); + throw new AssertionError("putCharsSB"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void codePointAtSB(byte[] val, int index, int end) { + try { + Helper.codePointAtSB(val, index, end); + throw new AssertionError("codePointAtSB"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void codePointBeforeSB(byte[] val, int index) { + try { + Helper.codePointBeforeSB(val, index); + throw new AssertionError("codePointBeforeSB"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void codePointCountSB(byte[] val, int beginIndex, int endIndex) { + try { + Helper.codePointCountSB(val, beginIndex, endIndex); + throw new AssertionError("codePointCountSB"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void charAt(byte[] v, int index) { + try { + Helper.charAt(v, index); + throw new AssertionError("charAt"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void contentEquals(byte[] v1, byte[] v2, int len) { + try { + Helper.contentEquals(v1, v2, len); + throw new AssertionError("contentEquals"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void contentEquals(byte[] v, CharSequence cs, int len) { + try { + Helper.contentEquals(v, cs, len); + throw new AssertionError("contentEquals"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void putCharsAt(byte[] v, int i, char c1, char c2, char c3, char c4) { + try { + Helper.putCharsAt(v, i, c1, c2, c3, c4); + throw new AssertionError("putCharsAt"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void putCharsAt(byte[] v, int i, char c1, char c2, char c3, char c4, char c5) { + try { + Helper.putCharsAt(v, i, c1, c2, c3, c4, c5); + throw new AssertionError("putCharsAt"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void reverse(byte[] v, int len) { + try { + Helper.reverse(v, len); + throw new AssertionError("reverse"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void inflate(byte[] v1, int o1, byte[] v2, int o2, int len) { + try { + Helper.inflate(v1, o1, v2, o2, len); + throw new AssertionError("inflate"); + } catch (IndexOutOfBoundsException io) { + } + } + + static void indexOf(byte[] v1, int l1, byte[] v2, int l2, int from) { + try { + if (Helper.indexOf(v1, l1, v2, l2, from) != -1) { + throw new AssertionError("indexOf"); + } + } catch (IndexOutOfBoundsException io) { + } + } + + static void lastIndexOf(byte[] v1, byte[] v2, int l2, int from) { + try { + if (Helper.lastIndexOf(v1, v2, l2, from) != -1) { + throw new AssertionError("lastIndexOf"); + } + } catch (IndexOutOfBoundsException io) { + } + } + + static void indexOfLatin1(byte[] v1, int l1, byte[] v2, int l2, int from) { + try { + if (Helper.indexOfLatin1(v1, l1, v2, l2, from) != -1) { + throw new AssertionError("indexOfLatin1"); + } + } catch (IndexOutOfBoundsException io) { + } + } + + static void lastIndexOfLatin1(byte[] v1, byte[] v2, int l2, int from) { + try { + if (Helper.lastIndexOfLatin1(v1, v2, l2, from) != -1) { + throw new AssertionError("lastIndexOfLatin1"); + } + } catch (IndexOutOfBoundsException io) { + } + } +} diff --git a/hotspot/test/compiler/intrinsics/unsafe/TestCAEAntiDep.java b/hotspot/test/compiler/intrinsics/unsafe/TestCAEAntiDep.java index 5bec829dddd..353c73e43ba 100644 --- a/hotspot/test/compiler/intrinsics/unsafe/TestCAEAntiDep.java +++ b/hotspot/test/compiler/intrinsics/unsafe/TestCAEAntiDep.java @@ -1,4 +1,5 @@ /* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2016, Red Hat, Inc. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -53,7 +54,7 @@ public class TestCAEAntiDep { } static int m(TestCAEAntiDep test, Object expected, Object x) { - C old = (C)UNSAFE.compareAndExchangeObjectVolatile(test, O_OFFSET, expected, x); + C old = (C)UNSAFE.compareAndExchangeObject(test, O_OFFSET, expected, x); int res = old.f1; old.f1 = 0x42; return res; diff --git a/hotspot/test/compiler/intrinsics/unsafe/UnsafeTwoCASLong.java b/hotspot/test/compiler/intrinsics/unsafe/UnsafeTwoCASLong.java index 8f65f1d5e04..772b44b60e4 100644 --- a/hotspot/test/compiler/intrinsics/unsafe/UnsafeTwoCASLong.java +++ b/hotspot/test/compiler/intrinsics/unsafe/UnsafeTwoCASLong.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -72,9 +72,8 @@ public class UnsafeTwoCASLong { } static void testAccess(Object base, long offset) { - UNSAFE.compareAndSwapLong(base, offset, 1L, 2L); - UNSAFE.compareAndSwapLong(base, offset, 2L, 1L); + UNSAFE.compareAndSetLong(base, offset, 1L, 2L); + UNSAFE.compareAndSetLong(base, offset, 2L, 1L); } } - diff --git a/hotspot/test/compiler/intrinsics/zip/TestCRC32.java b/hotspot/test/compiler/intrinsics/zip/TestCRC32.java index 626f506e48c..cacffd98ce2 100644 --- a/hotspot/test/compiler/intrinsics/zip/TestCRC32.java +++ b/hotspot/test/compiler/intrinsics/zip/TestCRC32.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,7 +36,22 @@ import java.util.zip.CRC32; import java.util.zip.Checksum; public class TestCRC32 { - public static void main(String[] args) { + // standard CRC32 polynomial + // coefficients in different forms + // normal: polyBits = 0x04c11db7 = 0b0000 0100 1100 0001 0001 1101 1011 0111 + // reversed: polybits = 0xedb88320 = 0b1110 1101 1011 1000 1000 0011 0010 0000 + // reversed reciprocal polybits = 0x82608edb = 0b1000 0010 0110 0000 1000 1110 1101 1011 + // + // 0 5 9 13 17 21 25 29 + // | | | | | | | | + // reversed shiftL 1 polyBits = 0x1db710641L = 0b1 1101 1011 0111 0001 0000 0110 0100 0001 + final static long polyBits = (1L<<(32-32)) + (1L<<(32-26)) + (1L<<(32-23)) + (1L<<(32-22)) + + (1L<<(32-16)) + (1L<<(32-12)) + (1L<<(32-11)) + (1L<<(32-10)) + + (1L<<(32-8)) + (1L<<(32-7)) + (1L<<(32-5)) + (1L<<(32-4)) + + (1L<<(32-2)) + (1L<<(32-1)) + (1L<<(32-0)); + final static long polyBitsShifted = polyBits>>1; + + public static void main(String[] args) throws Exception { int offset = Integer.getInteger("offset", 0); int msgSize = Integer.getInteger("msgSize", 512); boolean multi = false; @@ -65,11 +80,14 @@ public class TestCRC32 { byte[] b = initializedBytes(msgSize, offset); + final long crcReference = update_byteLoop(0, b, offset); + CRC32 crc0 = new CRC32(); CRC32 crc1 = new CRC32(); CRC32 crc2 = new CRC32(); crc0.update(b, offset, msgSize); + check(crc0, crcReference); System.out.println("-------------------------------------------------------"); @@ -77,27 +95,35 @@ public class TestCRC32 { for (int i = 0; i < warmupIters; i++) { crc1.reset(); crc1.update(b, offset, msgSize); + check(crc1, crcReference); } - /* measure performance */ + /* check correctness + * Do that before measuring performance + * to even better heat up involved methods. + */ + for (int i = 0; i < iters; i++) { + crc1.reset(); + crc1.update(b, offset, msgSize); + check(crc1, crcReference); + } + report("CRCs", crc1, crcReference); + + /* measure performance + * Don't spoil times with error checking. + */ long start = System.nanoTime(); for (int i = 0; i < iters; i++) { crc1.reset(); crc1.update(b, offset, msgSize); } long end = System.nanoTime(); + double total = (double)(end - start)/1e9; // in seconds double thruput = (double)msgSize*iters/1e6/total; // in MB/s System.out.println("CRC32.update(byte[]) runtime = " + total + " seconds"); System.out.println("CRC32.update(byte[]) throughput = " + thruput + " MB/s"); - - /* check correctness */ - for (int i = 0; i < iters; i++) { - crc1.reset(); - crc1.update(b, offset, msgSize); - if (!check(crc0, crc1)) break; - } - report("CRCs", crc0, crc1); + report("CRCs", crc1, crcReference); System.out.println("-------------------------------------------------------"); @@ -110,9 +136,24 @@ public class TestCRC32 { crc2.reset(); crc2.update(buf); buf.rewind(); + check(crc2, crcReference); } - /* measure performance */ + /* check correctness + * Do that before measuring performance + * to even better heat up involved methods. + */ + for (int i = 0; i < iters; i++) { + crc2.reset(); + crc2.update(buf); + buf.rewind(); + check(crc2, crcReference); + } + report("CRCs", crc2, crcReference); + + /* measure performance + * Don't spoil times with error checking. + */ start = System.nanoTime(); for (int i = 0; i < iters; i++) { crc2.reset(); @@ -124,31 +165,57 @@ public class TestCRC32 { thruput = (double)msgSize*iters/1e6/total; // in MB/s System.out.println("CRC32.update(ByteBuffer) runtime = " + total + " seconds"); System.out.println("CRC32.update(ByteBuffer) throughput = " + thruput + " MB/s"); - - /* check correctness */ - for (int i = 0; i < iters; i++) { - crc2.reset(); - crc2.update(buf); - buf.rewind(); - if (!check(crc0, crc2)) break; - } - report("CRCs", crc0, crc2); + report("CRCs", crc2, crcReference); System.out.println("-------------------------------------------------------"); } - private static void report(String s, Checksum crc0, Checksum crc1) { - System.out.printf("%s: crc0 = %08x, crc1 = %08x\n", - s, crc0.getValue(), crc1.getValue()); + // Just a loop over a byte array, updating the CRC byte by byte. + public static long update_byteLoop(long crc, byte[] buf, int offset) { + return update_byteLoop(crc, buf, offset, buf.length-offset); } - private static boolean check(Checksum crc0, Checksum crc1) { - if (crc0.getValue() != crc1.getValue()) { - System.err.printf("ERROR: crc0 = %08x, crc1 = %08x\n", - crc0.getValue(), crc1.getValue()); - return false; + // Just a loop over a byte array, with given length, updating the CRC byte by byte. + public static long update_byteLoop(long crc, byte[] buf, int offset, int length) { + int end = length+offset; + for (int i = offset; i < end; i++) { + crc = update_singlebyte(crc, polyBitsShifted, buf[i]); + } + return crc; + } + + // Straight-forward implementation of CRC update by one byte. + // We use this very basic implementation to calculate reference + // results. It is necessary to have full control over how the + // reference results are calculated. It is not sufficient to rely + // on the interpreter (or c1, or c2) to do the right thing. + public static long update_singlebyte(long crc, long polynomial, int val) { + crc = (crc ^ -1L) & 0x00000000ffffffffL; // use 1's complement of crc + crc = crc ^ (val&0xff); // XOR in next byte from stream + for (int i = 0; i < 8; i++) { + boolean bitset = (crc & 0x01L) != 0; + + crc = crc>>1; + if (bitset) { + crc = crc ^ polynomial; + crc = crc & 0x00000000ffffffffL; + } + } + crc = (crc ^ -1L) & 0x00000000ffffffffL; // revert taking 1's complement + return crc; + } + + private static void report(String s, Checksum crc, long crcReference) { + System.out.printf("%s: crc = %08x, crcReference = %08x\n", + s, crc.getValue(), crcReference); + } + + private static void check(Checksum crc, long crcReference) throws Exception { + if (crc.getValue() != crcReference) { + System.err.printf("ERROR: crc = %08x, crcReference = %08x\n", + crc.getValue(), crcReference); + throw new Exception("TestCRC32 Error"); } - return true; } private static byte[] initializedBytes(int M, int offset) { @@ -162,7 +229,7 @@ public class TestCRC32 { return bytes; } - private static void test_multi(int iters) { + private static void test_multi(int iters) throws Exception { int len1 = 8; // the 8B/iteration loop int len2 = 32; // the 32B/iteration loop int len3 = 4096; // the 4KB/iteration loop @@ -185,37 +252,31 @@ public class TestCRC32 { (len1+len2+len3)*2+5, (len1+len2+len3)*2+7, (len1+len2+len3)*3, (len1+len2+len3)*3-1, (len1+len2+len3)*3-3, (len1+len2+len3)*3-5, (len1+len2+len3)*3-7 }; - CRC32[] crc0 = new CRC32[offsets.length*sizes.length]; CRC32[] crc1 = new CRC32[offsets.length*sizes.length]; + long[] crcReference = new long[offsets.length*sizes.length]; int i, j, k; System.out.printf("testing %d cases ...\n", offsets.length*sizes.length); - /* set the result from interpreter as reference */ + // Initialize CRC32 result arrays, CRC32 reference array. + // Reference is calculated using a very basic Java implementation. for (i = 0; i < offsets.length; i++) { for (j = 0; j < sizes.length; j++) { - crc0[i*sizes.length + j] = new CRC32(); crc1[i*sizes.length + j] = new CRC32(); - crc0[i*sizes.length + j].update(b, offsets[i], sizes[j]); + crcReference[i*sizes.length + j] = update_byteLoop(0, b, offsets[i], sizes[j]); } } - /* warm up the JIT compiler and get result */ + // Warm up the JIT compiler. Over time, all methods involved will + // be executed by the interpreter, then get compiled by c1 and + // finally by c2. Each calculated CRC value must, in each iteration, + // be equal to the precalculated reference value for the test to pass. for (k = 0; k < iters; k++) { for (i = 0; i < offsets.length; i++) { for (j = 0; j < sizes.length; j++) { crc1[i*sizes.length + j].reset(); crc1[i*sizes.length + j].update(b, offsets[i], sizes[j]); - } - } - } - - /* check correctness */ - for (i = 0; i < offsets.length; i++) { - for (j = 0; j < sizes.length; j++) { - if (!check(crc0[i*sizes.length + j], crc1[i*sizes.length + j])) { - System.out.printf("offsets[%d] = %d", i, offsets[i]); - System.out.printf("\tsizes[%d] = %d\n", j, sizes[j]); + check(crc1[i*sizes.length + j], crcReference[i*sizes.length + j]); } } } diff --git a/hotspot/test/compiler/intrinsics/zip/TestCRC32C.java b/hotspot/test/compiler/intrinsics/zip/TestCRC32C.java index 2f280aa1254..2955af3478c 100644 --- a/hotspot/test/compiler/intrinsics/zip/TestCRC32C.java +++ b/hotspot/test/compiler/intrinsics/zip/TestCRC32C.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,7 +36,23 @@ import java.util.zip.CRC32C; import java.util.zip.Checksum; public class TestCRC32C { - public static void main(String[] args) { + // CRC32C (Castagnoli) polynomial + // coefficients in different forms + // normal: polyBits = 0x1edc6f41 = 0b0001 1110 1101 1100 0110 1111 0100 0001 + // reversed: polybits = 0x82f63b78 = 0b1000 0010 1111 0110 0011 1011 0111 1000 + // reversed reciprocal polybits = 0x8f6e37a0 = 0b1000 1111 0110 1110 0011 0111 1010 0000 + // + // 0 5 9 13 17 21 25 29 + // | | | | | | | | + // reversed shiftL 1 polyBits = 0x105ec76f1L = 0b1 0000 0101 1110 1100 0111 0110 1111 0001 + final static long polyBits = (1L<<(32-32)) + (1L<<(32-28)) + (1L<<(32-27)) + + (1L<<(32-26)) + (1L<<(32-25)) + (1L<<(32-23)) + (1L<<(32-22)) + + (1L<<(32-20)) + (1L<<(32-19)) + (1L<<(32-18)) + (1L<<(32-14)) + + (1L<<(32-13)) + (1L<<(32-11)) + (1L<<(32-10)) + (1L<<(32-9)) + + (1L<<(32-8)) + (1L<<(32-6)) + (1L<<(32-0)); + final static long polyBitsShifted = polyBits>>1; + + public static void main(String[] args) throws Exception { int offset = Integer.getInteger("offset", 0); int msgSize = Integer.getInteger("msgSize", 512); boolean multi = false; @@ -65,11 +81,14 @@ public class TestCRC32C { byte[] b = initializedBytes(msgSize, offset); + final long crcReference = update_byteLoop(0, b, offset); + CRC32C crc0 = new CRC32C(); CRC32C crc1 = new CRC32C(); CRC32C crc2 = new CRC32C(); crc0.update(b, offset, msgSize); + check(crc0, crcReference); System.out.println("-------------------------------------------------------"); @@ -77,27 +96,35 @@ public class TestCRC32C { for (int i = 0; i < warmupIters; i++) { crc1.reset(); crc1.update(b, offset, msgSize); + check(crc1, crcReference); } - /* measure performance */ + /* check correctness + * Do that before measuring performance + * to even better heat up involved methods. + */ + for (int i = 0; i < iters; i++) { + crc1.reset(); + crc1.update(b, offset, msgSize); + check(crc1, crcReference); + } + report("CRCs", crc1, crcReference); + + /* measure performance + * Don't spoil times with error checking. + */ long start = System.nanoTime(); for (int i = 0; i < iters; i++) { crc1.reset(); crc1.update(b, offset, msgSize); } long end = System.nanoTime(); + double total = (double)(end - start)/1e9; // in seconds double thruput = (double)msgSize*iters/1e6/total; // in MB/s System.out.println("CRC32C.update(byte[]) runtime = " + total + " seconds"); System.out.println("CRC32C.update(byte[]) throughput = " + thruput + " MB/s"); - - /* check correctness */ - for (int i = 0; i < iters; i++) { - crc1.reset(); - crc1.update(b, offset, msgSize); - if (!check(crc0, crc1)) break; - } - report("CRCs", crc0, crc1); + report("CRCs", crc1, crcReference); System.out.println("-------------------------------------------------------"); @@ -110,9 +137,24 @@ public class TestCRC32C { crc2.reset(); crc2.update(buf); buf.rewind(); + check(crc2, crcReference); } - /* measure performance */ + /* check correctness + * Do that before measuring performance + * to even better heat up involved methods. + */ + for (int i = 0; i < iters; i++) { + crc2.reset(); + crc2.update(buf); + buf.rewind(); + check(crc2, crcReference); + } + report("CRCs", crc2, crcReference); + + /* measure performance + * Don't spoil times with error checking. + */ start = System.nanoTime(); for (int i = 0; i < iters; i++) { crc2.reset(); @@ -124,31 +166,57 @@ public class TestCRC32C { thruput = (double)msgSize*iters/1e6/total; // in MB/s System.out.println("CRC32C.update(ByteBuffer) runtime = " + total + " seconds"); System.out.println("CRC32C.update(ByteBuffer) throughput = " + thruput + " MB/s"); - - /* check correctness */ - for (int i = 0; i < iters; i++) { - crc2.reset(); - crc2.update(buf); - buf.rewind(); - if (!check(crc0, crc2)) break; - } - report("CRCs", crc0, crc2); + report("CRCs", crc2, crcReference); System.out.println("-------------------------------------------------------"); } - private static void report(String s, Checksum crc0, Checksum crc1) { - System.out.printf("%s: crc0 = %08x, crc1 = %08x\n", - s, crc0.getValue(), crc1.getValue()); + // Just a loop over a byte array, updating the CRC byte by byte. + public static long update_byteLoop(long crc, byte[] buf, int offset) { + return update_byteLoop(crc, buf, offset, buf.length-offset); } - private static boolean check(Checksum crc0, Checksum crc1) { - if (crc0.getValue() != crc1.getValue()) { - System.err.printf("ERROR: crc0 = %08x, crc1 = %08x\n", - crc0.getValue(), crc1.getValue()); - return false; + // Just a loop over a byte array, with given length, updating the CRC byte by byte. + public static long update_byteLoop(long crc, byte[] buf, int offset, int length) { + int end = length+offset; + for (int i = offset; i < end; i++) { + crc = update_singlebyte(crc, polyBitsShifted, buf[i]); + } + return crc; + } + + // Straight-forward implementation of CRC update by one byte. + // We use this very basic implementation to calculate reference + // results. It is necessary to have full control over how the + // reference results are calculated. It is not sufficient to rely + // on the interpreter (or c1, or c2) to do the right thing. + public static long update_singlebyte(long crc, long polynomial, int val) { + crc = (crc ^ -1L) & 0x00000000ffffffffL; // use 1's complement of crc + crc = crc ^ (val&0xff); // XOR in next byte from stream + for (int i = 0; i < 8; i++) { + boolean bitset = (crc & 0x01L) != 0; + + crc = crc>>1; + if (bitset) { + crc = crc ^ polynomial; + crc = crc & 0x00000000ffffffffL; + } + } + crc = (crc ^ -1L) & 0x00000000ffffffffL; // revert taking 1's complement + return crc; + } + + private static void report(String s, Checksum crc, long crcReference) { + System.out.printf("%s: crc = %08x, crcReference = %08x\n", + s, crc.getValue(), crcReference); + } + + private static void check(Checksum crc, long crcReference) throws Exception { + if (crc.getValue() != crcReference) { + System.err.printf("ERROR: crc = %08x, crcReference = %08x\n", + crc.getValue(), crcReference); + throw new Exception("TestCRC32C Error"); } - return true; } private static byte[] initializedBytes(int M, int offset) { @@ -162,7 +230,7 @@ public class TestCRC32C { return bytes; } - private static void test_multi(int iters) { + private static void test_multi(int iters) throws Exception { int len1 = 8; // the 8B/iteration loop int len2 = 32; // the 32B/iteration loop int len3 = 4096; // the 4KB/iteration loop @@ -185,37 +253,31 @@ public class TestCRC32C { (len1+len2+len3)*2+5, (len1+len2+len3)*2+7, (len1+len2+len3)*3, (len1+len2+len3)*3-1, (len1+len2+len3)*3-3, (len1+len2+len3)*3-5, (len1+len2+len3)*3-7 }; - CRC32C[] crc0 = new CRC32C[offsets.length*sizes.length]; CRC32C[] crc1 = new CRC32C[offsets.length*sizes.length]; + long[] crcReference = new long[offsets.length*sizes.length]; int i, j, k; System.out.printf("testing %d cases ...\n", offsets.length*sizes.length); - /* set the result from interpreter as reference */ + // Initialize CRC32C result arrays, CRC32C reference array. + // Reference is calculated using a very basic Java implementation. for (i = 0; i < offsets.length; i++) { for (j = 0; j < sizes.length; j++) { - crc0[i*sizes.length + j] = new CRC32C(); crc1[i*sizes.length + j] = new CRC32C(); - crc0[i*sizes.length + j].update(b, offsets[i], sizes[j]); + crcReference[i*sizes.length + j] = update_byteLoop(0, b, offsets[i], sizes[j]); } } - /* warm up the JIT compiler and get result */ + // Warm up the JIT compiler. Over time, all methods involved will + // be executed by the interpreter, then get compiled by c1 and + // finally by c2. Each calculated CRC value must, in each iteration, + // be equal to the precalculated reference value for the test to pass. for (k = 0; k < iters; k++) { for (i = 0; i < offsets.length; i++) { for (j = 0; j < sizes.length; j++) { crc1[i*sizes.length + j].reset(); crc1[i*sizes.length + j].update(b, offsets[i], sizes[j]); - } - } - } - - /* check correctness */ - for (i = 0; i < offsets.length; i++) { - for (j = 0; j < sizes.length; j++) { - if (!check(crc0[i*sizes.length + j], crc1[i*sizes.length + j])) { - System.out.printf("offsets[%d] = %d", i, offsets[i]); - System.out.printf("\tsizes[%d] = %d\n", j, sizes[j]); + check(crc1[i*sizes.length + j], crcReference[i*sizes.length + j]); } } } diff --git a/hotspot/test/compiler/jsr292/ContinuousCallSiteTargetChange.java b/hotspot/test/compiler/jsr292/ContinuousCallSiteTargetChange.java index d9f2ddb1721..7fdd282033d 100644 --- a/hotspot/test/compiler/jsr292/ContinuousCallSiteTargetChange.java +++ b/hotspot/test/compiler/jsr292/ContinuousCallSiteTargetChange.java @@ -23,7 +23,6 @@ /** * @test - * @modules java.base/jdk.internal.misc * @library /test/lib / * * @run driver compiler.jsr292.ContinuousCallSiteTargetChange @@ -31,6 +30,7 @@ package compiler.jsr292; +import jdk.test.lib.Asserts; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; @@ -39,15 +39,26 @@ import java.lang.invoke.MethodHandle; import java.lang.invoke.MethodHandles; import java.lang.invoke.MethodType; import java.lang.invoke.MutableCallSite; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; public class ContinuousCallSiteTargetChange { - static void testServer() throws Exception { + static final int ITERATIONS = Integer.parseInt(System.getProperty("iterations", "50")); + + static void runTest(Class test, String... extraArgs) throws Exception { + List argsList = new ArrayList<>( + List.of("-XX:+IgnoreUnrecognizedVMOptions", + "-XX:PerBytecodeRecompilationCutoff=10", "-XX:PerMethodRecompilationCutoff=10", + "-XX:+PrintCompilation", "-XX:+UnlockDiagnosticVMOptions", "-XX:+PrintInlining")); + + argsList.addAll(Arrays.asList(extraArgs)); + + argsList.add(test.getName()); + argsList.add(Integer.toString(ITERATIONS)); + ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( - "-XX:+IgnoreUnrecognizedVMOptions", - "-server", "-XX:-TieredCompilation", "-Xbatch", - "-XX:PerBytecodeRecompilationCutoff=10", "-XX:PerMethodRecompilationCutoff=10", - "-XX:+PrintCompilation", "-XX:+UnlockDiagnosticVMOptions", "-XX:+PrintInlining", - Test.class.getName(), "100"); + argsList.toArray(new String[argsList.size()])); OutputAnalyzer analyzer = new OutputAnalyzer(pb.start()); @@ -55,30 +66,42 @@ public class ContinuousCallSiteTargetChange { analyzer.shouldNotContain("made not compilable"); analyzer.shouldNotContain("decompile_count > PerMethodRecompilationCutoff"); + } - static void testClient() throws Exception { - ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( - "-XX:+IgnoreUnrecognizedVMOptions", - "-client", "-XX:+TieredCompilation", "-XX:TieredStopAtLevel=1", "-Xbatch", - "-XX:PerBytecodeRecompilationCutoff=10", "-XX:PerMethodRecompilationCutoff=10", - "-XX:+PrintCompilation", "-XX:+UnlockDiagnosticVMOptions", "-XX:+PrintInlining", - Test.class.getName(), "100"); + static void testServer(Class test, String... args) throws Exception { + List extraArgsList = new ArrayList<>( + List.of("-server", "-XX:-TieredCompilation")); + extraArgsList.addAll(Arrays.asList(args)); - OutputAnalyzer analyzer = new OutputAnalyzer(pb.start()); + runTest(test, extraArgsList.toArray(new String[extraArgsList.size()])); + } - analyzer.shouldHaveExitValue(0); + static void testClient(Class test, String... args) throws Exception { + List extraArgsList = new ArrayList<>( + List.of("-client", "-XX:+TieredCompilation", "-XX:TieredStopAtLevel=1")); + extraArgsList.addAll(Arrays.asList(args)); - analyzer.shouldNotContain("made not compilable"); - analyzer.shouldNotContain("decompile_count > PerMethodRecompilationCutoff"); + runTest(test, extraArgsList.toArray(new String[extraArgsList.size()])); } public static void main(String[] args) throws Exception { - testServer(); - testClient(); + testServer(RecompilationTest.class, "-Xbatch"); + testClient(RecompilationTest.class, "-Xbatch"); + + testServer(PingPongTest.class); + testClient(PingPongTest.class); } - static class Test { + static MethodHandle findStatic(Class cls, String name, MethodType mt) { + try { + return MethodHandles.lookup().findStatic(cls, name, mt); + } catch (Exception e) { + throw new Error(e); + } + } + + static class RecompilationTest { static final MethodType mt = MethodType.methodType(void.class); static final CallSite cs = new MutableCallSite(mt); @@ -96,7 +119,7 @@ public class ContinuousCallSiteTargetChange { } static void iteration() throws Throwable { - MethodHandle mh1 = MethodHandles.lookup().findStatic(ContinuousCallSiteTargetChange.Test.class, "f", mt); + MethodHandle mh1 = findStatic(RecompilationTest.class, "f", mt); cs.setTarget(mh1); for (int i = 0; i < 20_000; i++) { test1(); @@ -111,4 +134,38 @@ public class ContinuousCallSiteTargetChange { } } } + + static class PingPongTest { + static final MethodType mt = MethodType.methodType(void.class); + static final CallSite cs = new MutableCallSite(mt); + + static final MethodHandle mh = cs.dynamicInvoker(); + + static final MethodHandle ping = findStatic(PingPongTest.class, "ping", mt); + static final MethodHandle pong = findStatic(PingPongTest.class, "pong", mt); + + static void ping() { + Asserts.assertEQ(cs.getTarget(), ping, "wrong call site target"); + cs.setTarget(pong); + } + + static void pong() { + Asserts.assertEQ(cs.getTarget(), pong, "wrong call site target"); + cs.setTarget(ping); + } + + static void iteration() throws Throwable { + cs.setTarget(ping); + for (int i = 0; i < 20_000; i++) { + mh.invokeExact(); + } + } + + public static void main(String[] args) throws Throwable { + int iterations = Integer.parseInt(args[0]); + for (int i = 0; i < iterations; i++) { + iteration(); + } + } + } } diff --git a/hotspot/test/compiler/jsr292/InvokerSignatureMismatch.java b/hotspot/test/compiler/jsr292/InvokerSignatureMismatch.java new file mode 100644 index 00000000000..dbd9e0101fc --- /dev/null +++ b/hotspot/test/compiler/jsr292/InvokerSignatureMismatch.java @@ -0,0 +1,56 @@ +package compiler.jsr292; + +import java.lang.invoke.MethodHandle; +import java.lang.invoke.MethodHandles; +import java.lang.invoke.MethodType; +import java.lang.invoke.MethodHandleHelper; +import jdk.internal.vm.annotation.ForceInline; + +/* + * @test + * @bug 8166110 + * @library /test/lib / patches + * @modules java.base/jdk.internal.misc + * java.base/jdk.internal.vm.annotation + * + * @build java.base/java.lang.invoke.MethodHandleHelper + * @run main/bootclasspath/othervm -XX:+IgnoreUnrecognizedVMOptions -Xbatch -XX:-TieredCompilation + * compiler.jsr292.InvokerSignatureMismatch + */ +public class InvokerSignatureMismatch { + + static final MethodHandle INT_MH; + + static { + MethodHandle mhI = null; + try { + mhI = MethodHandles.lookup().findStatic(InvokerSignatureMismatch.class, "bodyI", MethodType.methodType(void.class, int.class)); + } catch (Throwable e) { + } + INT_MH = mhI; + } + + public static void main(String[] args) throws Throwable { + for (int i = 0; i < 50_000; i++) { // OSR + mainLink(i); + mainInvoke(i); + } + } + + static void mainLink(int i) throws Throwable { + Object name = MethodHandleHelper.internalMemberName(INT_MH); + MethodHandleHelper.linkToStatic(INT_MH, (float) i, name); + } + + static void mainInvoke(int i) throws Throwable { + MethodHandleHelper.invokeBasicV(INT_MH, (float) i); + } + + static int cnt = 0; + static void bodyI(int x) { + if ((x & 1023) == 0) { // already optimized x % 1024 == 0 + ++cnt; + } + } + +} diff --git a/hotspot/test/compiler/jsr292/RedefineMethodUsedByMultipleMethodHandles.java b/hotspot/test/compiler/jsr292/RedefineMethodUsedByMultipleMethodHandles.java index e923258e480..e792ad170c9 100644 --- a/hotspot/test/compiler/jsr292/RedefineMethodUsedByMultipleMethodHandles.java +++ b/hotspot/test/compiler/jsr292/RedefineMethodUsedByMultipleMethodHandles.java @@ -32,7 +32,7 @@ * java.management * jdk.attach * - * @run main/othervm compiler.jsr292.RedefineMethodUsedByMultipleMethodHandles + * @run main/othervm -Djdk.attach.allowAttachSelf compiler.jsr292.RedefineMethodUsedByMultipleMethodHandles */ package compiler.jsr292; diff --git a/hotspot/test/compiler/jsr292/patches/java.base/java/lang/invoke/MethodHandleHelper.java b/hotspot/test/compiler/jsr292/patches/java.base/java/lang/invoke/MethodHandleHelper.java index a4732624a3a..c7406282274 100644 --- a/hotspot/test/compiler/jsr292/patches/java.base/java/lang/invoke/MethodHandleHelper.java +++ b/hotspot/test/compiler/jsr292/patches/java.base/java/lang/invoke/MethodHandleHelper.java @@ -43,6 +43,21 @@ public class MethodHandleHelper { mh.customize(); } + @ForceInline + public static Object internalMemberName(MethodHandle mh) throws Throwable { + return mh.internalMemberName(); + } + + @ForceInline + public static void linkToStatic(MethodHandle mh, float arg, Object name) throws Throwable { + MethodHandle.linkToStatic(mh, arg, name); + } + + @ForceInline + public static void invokeBasicV(MethodHandle mh, float arg) throws Throwable { + mh.invokeBasic(arg); + } + @ForceInline public static Object invokeBasicL(MethodHandle mh) throws Throwable { return mh.invokeBasic(); @@ -84,7 +99,7 @@ public class MethodHandleHelper { public static MethodHandle make(MethodHandle target) { LambdaForm lform = DelegatingMethodHandle.makeReinvokerForm( - target, -1, DelegatingMethodHandle.class, "reinvoker.dontInline", + target, -1, DelegatingMethodHandle.class, /*forceInline=*/false, DelegatingMethodHandle.NF_getTarget, null); return new NonInlinedReinvoker(target, lform); } diff --git a/hotspot/test/compiler/jvmci/JVM_GetJVMCIRuntimeTest.java b/hotspot/test/compiler/jvmci/JVM_GetJVMCIRuntimeTest.java index 481334f4ca4..3d01b4adbd9 100644 --- a/hotspot/test/compiler/jvmci/JVM_GetJVMCIRuntimeTest.java +++ b/hotspot/test/compiler/jvmci/JVM_GetJVMCIRuntimeTest.java @@ -27,10 +27,10 @@ * @requires vm.jvmci * @library /test/lib / * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.runtime * @run main/othervm -XX:+UnlockExperimentalVMOptions * -Dcompiler.jvmci.JVM_GetJVMCIRuntimeTest.positive=true - * -XX:+EnableJVMCI + * -XX:+EnableJVMCI -Djvmci.Compiler=null * compiler.jvmci.JVM_GetJVMCIRuntimeTest * @run main/othervm -XX:+UnlockExperimentalVMOptions * -Dcompiler.jvmci.JVM_GetJVMCIRuntimeTest.positive=false @@ -39,7 +39,7 @@ * @run main/othervm -XX:+UnlockExperimentalVMOptions * -Dcompiler.jvmci.JVM_GetJVMCIRuntimeTest.positive=true * -Dcompiler.jvmci.JVM_GetJVMCIRuntimeTest.threaded=true - * -XX:+EnableJVMCI + * -XX:+EnableJVMCI -Djvmci.Compiler=null * compiler.jvmci.JVM_GetJVMCIRuntimeTest * @run main/othervm -XX:+UnlockExperimentalVMOptions * -Dcompiler.jvmci.JVM_GetJVMCIRuntimeTest.positive=false diff --git a/hotspot/test/compiler/jvmci/SecurityRestrictionsTest.java b/hotspot/test/compiler/jvmci/SecurityRestrictionsTest.java index b86cfbf6dd9..a52e19b3817 100644 --- a/hotspot/test/compiler/jvmci/SecurityRestrictionsTest.java +++ b/hotspot/test/compiler/jvmci/SecurityRestrictionsTest.java @@ -28,8 +28,8 @@ * @library /test/lib / * @library common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions * -XX:+EnableJVMCI * compiler.jvmci.SecurityRestrictionsTest diff --git a/hotspot/test/compiler/jvmci/TestJVMCIPrintProperties.java b/hotspot/test/compiler/jvmci/TestJVMCIPrintProperties.java index 4f40c5b8a2d..2779db7b213 100644 --- a/hotspot/test/compiler/jvmci/TestJVMCIPrintProperties.java +++ b/hotspot/test/compiler/jvmci/TestJVMCIPrintProperties.java @@ -36,11 +36,11 @@ public class TestJVMCIPrintProperties { public static void main(String[] args) throws Exception { ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( "-XX:+UnlockExperimentalVMOptions", - "-XX:+EnableJVMCI", + "-XX:+EnableJVMCI", "-Djvmci.Compiler=null", "-XX:+JVMCIPrintProperties"); OutputAnalyzer output = new OutputAnalyzer(pb.start()); output.shouldContain("[JVMCI properties]"); // expected message - output.shouldContain("jvmci.Compiler = null"); // expected message + output.shouldContain("jvmci.Compiler := \"null\""); // expected message output.shouldContain("jvmci.InitTimer = false"); // expected message output.shouldContain("jvmci.PrintConfig = false"); // expected message output.shouldContain("jvmci.TraceMethodDataFilter = null"); // expected message diff --git a/hotspot/test/compiler/jvmci/common/CTVMUtilities.java b/hotspot/test/compiler/jvmci/common/CTVMUtilities.java index 7ba6d00debf..7f32d95855d 100644 --- a/hotspot/test/compiler/jvmci/common/CTVMUtilities.java +++ b/hotspot/test/compiler/jvmci/common/CTVMUtilities.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -41,7 +41,6 @@ import java.lang.reflect.Executable; import java.lang.reflect.Field; import java.lang.reflect.Method; import java.lang.reflect.Modifier; -import java.lang.reflect.Module; import java.lang.reflect.Parameter; import java.util.HashMap; import java.util.Map; diff --git a/hotspot/test/compiler/jvmci/common/patches/jdk.vm.ci/jdk/vm/ci/hotspot/CompilerToVMHelper.java b/hotspot/test/compiler/jvmci/common/patches/jdk.internal.vm.ci/jdk/vm/ci/hotspot/CompilerToVMHelper.java similarity index 98% rename from hotspot/test/compiler/jvmci/common/patches/jdk.vm.ci/jdk/vm/ci/hotspot/CompilerToVMHelper.java rename to hotspot/test/compiler/jvmci/common/patches/jdk.internal.vm.ci/jdk/vm/ci/hotspot/CompilerToVMHelper.java index fc03353f76a..1cdee2d2974 100644 --- a/hotspot/test/compiler/jvmci/common/patches/jdk.vm.ci/jdk/vm/ci/hotspot/CompilerToVMHelper.java +++ b/hotspot/test/compiler/jvmci/common/patches/jdk.internal.vm.ci/jdk/vm/ci/hotspot/CompilerToVMHelper.java @@ -48,6 +48,10 @@ public class CompilerToVMHelper { return CTVM.getExceptionTableStart((HotSpotResolvedJavaMethodImpl)method); } + public static Object getFlagValue(String name) { + return CTVM.getFlagValue(name); + } + public static boolean isCompilable(HotSpotResolvedJavaMethod method) { return CTVM.isCompilable((HotSpotResolvedJavaMethodImpl)method); } @@ -128,7 +132,7 @@ public class CompilerToVMHelper { } public static HotSpotResolvedObjectType resolveFieldInPool( - ConstantPool constantPool, int cpi, ResolvedJavaMethod method, byte opcode, long[] info) { + ConstantPool constantPool, int cpi, ResolvedJavaMethod method, byte opcode, int[] info) { return CTVM.resolveFieldInPool((HotSpotConstantPool) constantPool, cpi, (HotSpotResolvedJavaMethodImpl) method, opcode, info); } diff --git a/hotspot/test/compiler/jvmci/common/patches/jdk.vm.ci/jdk/vm/ci/hotspot/MetaAccessWrapper.java b/hotspot/test/compiler/jvmci/common/patches/jdk.internal.vm.ci/jdk/vm/ci/hotspot/MetaAccessWrapper.java similarity index 100% rename from hotspot/test/compiler/jvmci/common/patches/jdk.vm.ci/jdk/vm/ci/hotspot/MetaAccessWrapper.java rename to hotspot/test/compiler/jvmci/common/patches/jdk.internal.vm.ci/jdk/vm/ci/hotspot/MetaAccessWrapper.java diff --git a/hotspot/test/compiler/jvmci/common/patches/jdk.vm.ci/jdk/vm/ci/hotspot/PublicMetaspaceWrapperObject.java b/hotspot/test/compiler/jvmci/common/patches/jdk.internal.vm.ci/jdk/vm/ci/hotspot/PublicMetaspaceWrapperObject.java similarity index 100% rename from hotspot/test/compiler/jvmci/common/patches/jdk.vm.ci/jdk/vm/ci/hotspot/PublicMetaspaceWrapperObject.java rename to hotspot/test/compiler/jvmci/common/patches/jdk.internal.vm.ci/jdk/vm/ci/hotspot/PublicMetaspaceWrapperObject.java diff --git a/hotspot/test/compiler/jvmci/compilerToVM/AllocateCompileIdTest.java b/hotspot/test/compiler/jvmci/compilerToVM/AllocateCompileIdTest.java index adfece82f94..7aaf6bd4cb9 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/AllocateCompileIdTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/AllocateCompileIdTest.java @@ -30,10 +30,10 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. diff --git a/hotspot/test/compiler/jvmci/compilerToVM/AsResolvedJavaMethodTest.java b/hotspot/test/compiler/jvmci/compilerToVM/AsResolvedJavaMethodTest.java index 09e8f0e2b5b..92b00bd48a6 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/AsResolvedJavaMethodTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/AsResolvedJavaMethodTest.java @@ -30,11 +30,11 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.meta - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper - * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.meta + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.AsResolvedJavaMethodTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/CollectCountersTest.java b/hotspot/test/compiler/jvmci/compilerToVM/CollectCountersTest.java index 507c56987d7..f729894dd55 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/CollectCountersTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/CollectCountersTest.java @@ -28,8 +28,8 @@ * @library / /test/lib/ * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run main/othervm -XX:+UnlockExperimentalVMOptions * -XX:+EnableJVMCI * -XX:JVMCICounterSize=0 diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ConstantPoolTestCase.java b/hotspot/test/compiler/jvmci/compilerToVM/ConstantPoolTestCase.java index 6f2ccb0f3c0..f799f0c2734 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ConstantPoolTestCase.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ConstantPoolTestCase.java @@ -202,13 +202,13 @@ public class ConstantPoolTestCase { public final String type; public final ResolvedJavaMethod[] methods; public final byte[] opcodes; - public final long accFlags; + public final int accFlags; - public TestedCPEntry(String klass, String name, String type, byte[] opcodes, long accFlags) { + public TestedCPEntry(String klass, String name, String type, byte[] opcodes, int accFlags) { this(klass, name, type, null, opcodes, accFlags); } - public TestedCPEntry(String klass, String name, String type, ResolvedJavaMethod[] methods, byte[] opcodes, long accFlags) { + public TestedCPEntry(String klass, String name, String type, ResolvedJavaMethod[] methods, byte[] opcodes, int accFlags) { this.klass = klass; this.name = name; this.type = type; diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ConstantPoolTestsHelper.java b/hotspot/test/compiler/jvmci/compilerToVM/ConstantPoolTestsHelper.java index e0bb9d41c8e..0ac7f3d6a6f 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ConstantPoolTestsHelper.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ConstantPoolTestsHelper.java @@ -206,7 +206,7 @@ public class ConstantPoolTestsHelper { "stringFieldEmpty", "Ljava/lang/String;", new byte[] {(byte) Opcodes.PUTFIELD | (byte) Opcodes.GETFIELD}, - 0L), + 0), } ); CP_MAP_FOR_CLASS.put(CONSTANT_METHODREF, @@ -362,7 +362,7 @@ public class ConstantPoolTestsHelper { "stringFieldEmpty", "Ljava/lang/String;", new byte[] {(byte) Opcodes.PUTFIELD | (byte) Opcodes.GETFIELD}, - 0L), + 0), } ); CP_MAP_FOR_ABS_CLASS.put(CONSTANT_METHODREF, diff --git a/hotspot/test/compiler/jvmci/compilerToVM/DebugOutputTest.java b/hotspot/test/compiler/jvmci/compilerToVM/DebugOutputTest.java index 806c2e7e349..f07c570fa16 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/DebugOutputTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/DebugOutputTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,13 +28,11 @@ * @library / /test/lib * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper - * @run main/othervm compiler.jvmci.compilerToVM.DebugOutputTest + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @run driver compiler.jvmci.compilerToVM.DebugOutputTest */ - // as soon as CODETOOLS-7901589 fixed, '@run main/othervm' should be replaced w/ '@run driver' - package compiler.jvmci.compilerToVM; import jdk.test.lib.process.OutputAnalyzer; @@ -42,8 +40,11 @@ import jdk.test.lib.process.ProcessTools; import jdk.vm.ci.hotspot.CompilerToVMHelper; import java.util.Arrays; +import java.nio.file.Path; +import java.nio.file.Paths; public class DebugOutputTest { + private static final String VM_CI_MODULE = "jdk.internal.vm.ci"; public static void main(String[] args) { new DebugOutputTest().test(); } @@ -53,10 +54,18 @@ public class DebugOutputTest { System.out.println(testCase); OutputAnalyzer oa; try { - oa = ProcessTools.executeTestJvmAllArgs( + Path patch = Paths.get(System.getProperty("test.patch.path")); + Path jvmciPath = patch.resolve(VM_CI_MODULE).toAbsolutePath(); + if (!jvmciPath.toFile().exists()) { + throw new Error("TESTBUG: patch for " + VM_CI_MODULE + " : " + + jvmciPath.toString() + " does not exist"); + } + oa = ProcessTools.executeTestJvm( "-XX:+UnlockExperimentalVMOptions", "-XX:+EnableJVMCI", - "-Xbootclasspath/a:.", + "--add-exports", "java.base/jdk.internal.misc=ALL-UNNAMED", + "--add-exports", "jdk.internal.vm.ci/jdk.vm.ci.hotspot=ALL-UNNAMED", + "--patch-module", VM_CI_MODULE + "=" + jvmciPath.toString(), DebugOutputTest.Worker.class.getName(), testCase.name()); } catch (Throwable e) { diff --git a/hotspot/test/compiler/jvmci/compilerToVM/DisassembleCodeBlobTest.java b/hotspot/test/compiler/jvmci/compilerToVM/DisassembleCodeBlobTest.java index 9101d2a66e5..09f9b94d426 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/DisassembleCodeBlobTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/DisassembleCodeBlobTest.java @@ -30,10 +30,10 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @build sun.hotspot.WhiteBox * compiler.jvmci.compilerToVM.DisassembleCodeBlobTest * @run driver ClassFileInstaller sun.hotspot.WhiteBox diff --git a/hotspot/test/compiler/jvmci/compilerToVM/DoNotInlineOrCompileTest.java b/hotspot/test/compiler/jvmci/compilerToVM/DoNotInlineOrCompileTest.java index 57e2e1fea1c..e8c9a086253 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/DoNotInlineOrCompileTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/DoNotInlineOrCompileTest.java @@ -30,15 +30,16 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.DoNotInlineOrCompileTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ExecuteInstalledCodeTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ExecuteInstalledCodeTest.java index 5d7c4d376ba..02e4b68c938 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ExecuteInstalledCodeTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ExecuteInstalledCodeTest.java @@ -21,6 +21,26 @@ * questions. */ +/* + * @test + * @bug 8136421 + * @requires vm.jvmci + * @library /test/lib / + * @library ../common/patches + * @modules java.base/jdk.internal.misc + * @modules java.base/jdk.internal.org.objectweb.asm + * java.base/jdk.internal.org.objectweb.asm.tree + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @run driver ClassFileInstaller sun.hotspot.WhiteBox + * sun.hotspot.WhiteBox$WhiteBoxPermission + * @run main/othervm -Xbootclasspath/a:. + * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI + * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * compiler.jvmci.compilerToVM.ExecuteInstalledCodeTest + */ + package compiler.jvmci.compilerToVM; import jdk.test.lib.Asserts; @@ -36,26 +56,6 @@ import java.lang.reflect.Modifier; import java.util.ArrayList; import java.util.List; -/* - * @test - * @bug 8136421 - * @requires vm.jvmci - * @library /test/lib / - * @library ../common/patches - * @modules java.base/jdk.internal.misc - * @modules java.base/jdk.internal.org.objectweb.asm - * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox - * @run driver ClassFileInstaller sun.hotspot.WhiteBox - * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -Xbootclasspath/a:. - * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI - * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * compiler.jvmci.compilerToVM.ExecuteInstalledCodeTest - */ - public class ExecuteInstalledCodeTest { public static void main(String[] args) { diff --git a/hotspot/test/compiler/jvmci/compilerToVM/FindUniqueConcreteMethodTest.java b/hotspot/test/compiler/jvmci/compilerToVM/FindUniqueConcreteMethodTest.java index 4f39cf05c6c..82d5d10d46c 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/FindUniqueConcreteMethodTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/FindUniqueConcreteMethodTest.java @@ -30,12 +30,13 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.FindUniqueConcreteMethodTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetBytecodeTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetBytecodeTest.java index e959482d0f1..0cdcbc9f88b 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetBytecodeTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetBytecodeTest.java @@ -30,10 +30,11 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetBytecodeTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetClassInitializerTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetClassInitializerTest.java index 5dcc9f4e7e7..51cc6392cec 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetClassInitializerTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetClassInitializerTest.java @@ -28,9 +28,10 @@ * @library / /test/lib * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetClassInitializerTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetConstantPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetConstantPoolTest.java index 2aa39371567..7b51c257da0 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetConstantPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetConstantPoolTest.java @@ -29,15 +29,16 @@ * @library ../common/patches * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm - java.base/jdk.internal.org.objectweb.asm.tree - jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.code + * java.base/jdk.internal.org.objectweb.asm.tree + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.code * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetConstantPoolTest */ package compiler.jvmci.compilerToVM; diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetExceptionTableTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetExceptionTableTest.java index af7c9bb8985..66386522965 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetExceptionTableTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetExceptionTableTest.java @@ -30,10 +30,11 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetExceptionTableTest */ @@ -137,4 +138,3 @@ public class GetExceptionTableTest { } } } - diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetFlagValueTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetFlagValueTest.java new file mode 100644 index 00000000000..b074ca8140d --- /dev/null +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetFlagValueTest.java @@ -0,0 +1,93 @@ +/* + * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8173912 + * @requires vm.jvmci + * @library / /test/lib + * @library ../common/patches + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot:+open + * @build sun.hotspot.WhiteBox + * @run driver ClassFileInstaller sun.hotspot.WhiteBox + * sun.hotspot.WhiteBox$WhiteBoxPermission + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. + * compiler.jvmci.compilerToVM.GetFlagValueTest + */ + +package compiler.jvmci.compilerToVM; + +import jdk.test.lib.Asserts; +import jdk.vm.ci.hotspot.CompilerToVMHelper; +import jdk.test.lib.process.OutputAnalyzer; +import jdk.test.lib.process.ProcessTools; +import java.math.BigInteger; +import java.util.Arrays; +import java.util.regex.Pattern; +import java.util.regex.Matcher; +import sun.hotspot.WhiteBox; + +public class GetFlagValueTest { + public static void main(String[] args) throws Exception { + try { + CompilerToVMHelper.getFlagValue(null); + Asserts.fail("Expected NullPointerException when calling getFlagValue(null)"); + } catch (NullPointerException e) { + // expected + } + + Object missing = CompilerToVMHelper.getFlagValue("this is surely not a flag"); + Asserts.assertEquals(CompilerToVMHelper.CTVM, missing); + + ProcessBuilder pb; + OutputAnalyzer out; + + String[] arguments = {"-XX:+UnlockExperimentalVMOptions", "-XX:+EnableJVMCI", "-XX:+PrintFlagsFinal", "-version"}; + pb = ProcessTools.createJavaProcessBuilder(arguments); + out = new OutputAnalyzer(pb.start()); + + out.shouldHaveExitValue(0); + String[] lines = out.getStdout().split("\\r?\\n"); + Asserts.assertTrue(lines.length > 1, "Expected output from -XX:+PrintFlagsFinal"); + + final WhiteBox wb = WhiteBox.getWhiteBox(); + + // Line example: ccstr PrintIdealGraphAddress = 127.0.0.1 {C2 notproduct} {default} + Pattern flagLine = Pattern.compile("(\\w+)\\s+(\\w+)\\s+:?= (?:(.+))\\{[^}]+\\}\\s+\\{[^}]+\\}"); + for (String line : lines) { + if (line.indexOf('=') != -1) { + line = line.trim(); + Matcher m = flagLine.matcher(line); + Asserts.assertTrue(m.matches(), "Unexpected line in -XX:+PrintFlagsFinal output: " + line); + String type = m.group(1); + String name = m.group(2); + String expect = m.group(3).trim(); + Object value = CompilerToVMHelper.getFlagValue(name); + Object wbValue = wb.getVMFlag(name); + Asserts.assertEquals(value, wbValue, "Value of flag " + name); + } + } + } +} diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetImplementorTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetImplementorTest.java index 3811c74abf6..9b33cc6fb48 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetImplementorTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetImplementorTest.java @@ -28,9 +28,10 @@ * @library / /test/lib/ * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetImplementorTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetLineNumberTableTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetLineNumberTableTest.java index 33b20f2f4bb..b6518820926 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetLineNumberTableTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetLineNumberTableTest.java @@ -31,10 +31,11 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetLineNumberTableTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetLocalVariableTableTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetLocalVariableTableTest.java index 8202d1260c1..53d0ce5c2da 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetLocalVariableTableTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetLocalVariableTableTest.java @@ -30,14 +30,15 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code * @clean compiler.jvmci.compilerToVM.* * @compile -g DummyInterface.java * @compile -g DummyAbstractClass.java * @compile -g DummyClass.java - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetLocalVariableTableTest * @clean compiler.jvmci.compilerToVM.* */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetMaxCallTargetOffsetTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetMaxCallTargetOffsetTest.java index 0923e10c9b7..bf43ca431b6 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetMaxCallTargetOffsetTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetMaxCallTargetOffsetTest.java @@ -28,8 +28,8 @@ * @library / /test/lib/ * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI * compiler.jvmci.compilerToVM.GetMaxCallTargetOffsetTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetNextStackFrameTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetNextStackFrameTest.java index 0b079f3741f..10a75a81402 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetNextStackFrameTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetNextStackFrameTest.java @@ -30,11 +30,12 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.meta - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.meta + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetNextStackFrameTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetResolvedJavaMethodTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetResolvedJavaMethodTest.java index b50dd8e1e2e..b7d4b5d0ae7 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetResolvedJavaMethodTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetResolvedJavaMethodTest.java @@ -28,16 +28,17 @@ * @library / /test/lib * @library ../common/patches * @modules java.base/jdk.internal.misc:+open - * @modules jdk.vm.ci/jdk.vm.ci.hotspot:+open + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot:+open * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper - * jdk.vm.ci/jdk.vm.ci.hotspot.PublicMetaspaceWrapperObject + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot.PublicMetaspaceWrapperObject * sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetResolvedJavaMethodTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetResolvedJavaTypeTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetResolvedJavaTypeTest.java index 483f1416e93..39a40d39a9d 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetResolvedJavaTypeTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetResolvedJavaTypeTest.java @@ -28,11 +28,11 @@ * @library / /test/lib * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper - * jdk.vm.ci/jdk.vm.ci.hotspot.PublicMetaspaceWrapperObject + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot.PublicMetaspaceWrapperObject * sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission @@ -44,7 +44,7 @@ * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * -XX:-UseCompressedOops + * -XX:-UseCompressedOops -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetResolvedJavaTypeTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetStackTraceElementTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetStackTraceElementTest.java index 0c3e4ba92cc..d24806720ea 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetStackTraceElementTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetStackTraceElementTest.java @@ -30,10 +30,11 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetStackTraceElementTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetSymbolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetSymbolTest.java index 87c40534e7b..bde201af7ab 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetSymbolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetSymbolTest.java @@ -30,11 +30,12 @@ * @modules java.base/jdk.internal.misc:+open * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * @modules jdk.vm.ci/jdk.vm.ci.hotspot:+open - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.meta - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot:+open + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.meta + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetSymbolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/GetVtableIndexForInterfaceTest.java b/hotspot/test/compiler/jvmci/compilerToVM/GetVtableIndexForInterfaceTest.java index 8cfc1d89cf9..fbe44716b71 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/GetVtableIndexForInterfaceTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/GetVtableIndexForInterfaceTest.java @@ -30,10 +30,11 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.GetVtableIndexForInterfaceTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/HasCompiledCodeForOSRTest.java b/hotspot/test/compiler/jvmci/compilerToVM/HasCompiledCodeForOSRTest.java index 969a7f6d5ff..f9e50cb69f8 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/HasCompiledCodeForOSRTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/HasCompiledCodeForOSRTest.java @@ -30,16 +30,16 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * -XX:-BackgroundCompilation + * -XX:-BackgroundCompilation -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.HasCompiledCodeForOSRTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/HasFinalizableSubclassTest.java b/hotspot/test/compiler/jvmci/compilerToVM/HasFinalizableSubclassTest.java index 57ec63acd3e..ad4319de20e 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/HasFinalizableSubclassTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/HasFinalizableSubclassTest.java @@ -28,10 +28,11 @@ * @library / /test/lib * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * compiler.jvmci.compilerToVM.HasFinalizableSubclassTest + * -Djvmci.Compiler=null + * compiler.jvmci.compilerToVM.HasFinalizableSubclassTest */ package compiler.jvmci.compilerToVM; diff --git a/hotspot/test/compiler/jvmci/compilerToVM/HasNeverInlineDirectiveTest.java b/hotspot/test/compiler/jvmci/compilerToVM/HasNeverInlineDirectiveTest.java index 7efd8d2d994..12b808f072f 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/HasNeverInlineDirectiveTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/HasNeverInlineDirectiveTest.java @@ -30,15 +30,16 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.HasNeverInlineDirectiveTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/InvalidateInstalledCodeTest.java b/hotspot/test/compiler/jvmci/compilerToVM/InvalidateInstalledCodeTest.java index 828dc7788d5..de6f2f6f1a3 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/InvalidateInstalledCodeTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/InvalidateInstalledCodeTest.java @@ -30,11 +30,11 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.runtime * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @build compiler.jvmci.compilerToVM.InvalidateInstalledCodeTest * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox @@ -42,6 +42,7 @@ * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.InvalidateInstalledCodeTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/IsCompilableTest.java b/hotspot/test/compiler/jvmci/compilerToVM/IsCompilableTest.java index 02436906636..ce0f5335270 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/IsCompilableTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/IsCompilableTest.java @@ -30,19 +30,21 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -XX:+UseJVMCICompiler + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.IsCompilableTest * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI - * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -XX:-UseJVMCICompiler + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.IsCompilableTest */ @@ -69,20 +71,17 @@ public class IsCompilableTest { } private static void runSanityTest(Executable aMethod) { - boolean UseJVMCICompiler = (Boolean) WB.getVMFlag("UseJVMCICompiler"); HotSpotResolvedJavaMethod method = CTVMUtilities .getResolvedMethod(aMethod); boolean isCompilable = CompilerToVMHelper.isCompilable(method); - boolean expected = UseJVMCICompiler || WB.isMethodCompilable(aMethod); + boolean expected = WB.isMethodCompilable(aMethod); Asserts.assertEQ(isCompilable, expected, "Unexpected initial " + "value of property 'compilable'"); - if (!UseJVMCICompiler) { - WB.makeMethodNotCompilable(aMethod); - isCompilable = CompilerToVMHelper.isCompilable(method); - Asserts.assertFalse(isCompilable, aMethod + "Unexpected value of " + - "property 'isCompilable' after setting 'compilable' to false"); - } + WB.makeMethodNotCompilable(aMethod); + isCompilable = CompilerToVMHelper.isCompilable(method); + Asserts.assertFalse(isCompilable, aMethod + "Unexpected value of " + + "property 'isCompilable' after setting 'compilable' to false"); } private static List createTestCases() { diff --git a/hotspot/test/compiler/jvmci/compilerToVM/IsMatureTest.java b/hotspot/test/compiler/jvmci/compilerToVM/IsMatureTest.java index e1427d0becb..329990e2a7d 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/IsMatureTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/IsMatureTest.java @@ -28,9 +28,9 @@ * @library / /test/lib * ../common/patches * @modules java.base/jdk.internal.misc - * jdk.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.hotspot * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission diff --git a/hotspot/test/compiler/jvmci/compilerToVM/IsMatureVsReprofileTest.java b/hotspot/test/compiler/jvmci/compilerToVM/IsMatureVsReprofileTest.java new file mode 100644 index 00000000000..b748403c2b0 --- /dev/null +++ b/hotspot/test/compiler/jvmci/compilerToVM/IsMatureVsReprofileTest.java @@ -0,0 +1,99 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8136421 + * @requires vm.jvmci + * @library / /test/lib + * ../common/patches + * @modules java.base/jdk.internal.misc + * java.base/jdk.internal.org.objectweb.asm + * java.base/jdk.internal.org.objectweb.asm.tree + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * sun.hotspot.WhiteBox + * @run driver ClassFileInstaller sun.hotspot.WhiteBox + * sun.hotspot.WhiteBox$WhiteBoxPermission + * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions + * -XX:+WhiteBoxAPI -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Xbatch + * -Djvmci.Compiler=null + * compiler.jvmci.compilerToVM.IsMatureVsReprofileTest + */ + +package compiler.jvmci.compilerToVM; + +import compiler.jvmci.common.CTVMUtilities; +import compiler.jvmci.common.testcases.SimpleClass; +import jdk.vm.ci.hotspot.CompilerToVMHelper; +import jdk.test.lib.Asserts; +import sun.hotspot.WhiteBox; +import compiler.whitebox.CompilerWhiteBoxTest; +import java.lang.reflect.Executable; +import jdk.vm.ci.hotspot.HotSpotResolvedJavaMethod; +import jdk.test.lib.Platform; + +public class IsMatureVsReprofileTest { + private static final WhiteBox WB = WhiteBox.getWhiteBox(); + private static final boolean TIERED = WB.getBooleanVMFlag("TieredCompilation"); + private static final boolean IS_XCOMP = Platform.isComp(); + + public static void main(String[] args) throws Exception { + new IsMatureVsReprofileTest().test(); + } + + public void test() throws Exception { + SimpleClass sclass = new SimpleClass(); + Executable method = SimpleClass.class.getDeclaredMethod("testMethod"); + long metaspaceMethodData = WB.getMethodData(method); + Asserts.assertEQ(metaspaceMethodData, 0L, "MDO should be null for a " + + "never invoked method"); + boolean isMature = CompilerToVMHelper.isMature(metaspaceMethodData); + Asserts.assertFalse(isMature, "null MDO can't be mature"); + for (int i = 0; i < CompilerWhiteBoxTest.THRESHOLD; i++) { + sclass.testMethod(); + } + Asserts.assertTrue(WB.isMethodCompiled(method), + "Method should be compiled"); + metaspaceMethodData = WB.getMethodData(method); + Asserts.assertNE(metaspaceMethodData, 0L, + "Multiple times invoked method should have MDO"); + isMature = CompilerToVMHelper.isMature(metaspaceMethodData); + /* a method is not mature for -Xcomp and -Tiered, + see NonTieredCompPolicy::is_mature */ + Asserts.assertEQ(!IS_XCOMP || TIERED, isMature, + "Unexpected isMature state for compiled method"); + HotSpotResolvedJavaMethod resolvedMethod + = CTVMUtilities.getResolvedMethod(method); + CompilerToVMHelper.reprofile(resolvedMethod); + Asserts.assertFalse(WB.isMethodCompiled(method), + "Unexpected method compilation state after reprofile"); + metaspaceMethodData = WB.getMethodData(method); + isMature = CompilerToVMHelper.isMature(metaspaceMethodData); + Asserts.assertNE(metaspaceMethodData, 0L, + "Got null MDO after reprofile"); + Asserts.assertEQ(TIERED && IS_XCOMP, isMature, + "Got unexpected isMature state after reprofiling"); + } +} diff --git a/hotspot/test/compiler/jvmci/compilerToVM/JVM_RegisterJVMCINatives.java b/hotspot/test/compiler/jvmci/compilerToVM/JVM_RegisterJVMCINatives.java index 826868ae54d..0c0e60bfd39 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/JVM_RegisterJVMCINatives.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/JVM_RegisterJVMCINatives.java @@ -27,8 +27,8 @@ * @requires vm.jvmci * @library /test/lib / * @modules java.base/jdk.internal.misc:open - * @modules jdk.vm.ci/jdk.vm.ci.hotspot:open - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot:open + * jdk.internal.vm.ci/jdk.vm.ci.runtime * @run main/othervm -XX:+UnlockExperimentalVMOptions * -Dcompiler.jvmci.compilerToVM.JVM_RegisterJVMCINatives.positive=true * -XX:+EnableJVMCI diff --git a/hotspot/test/compiler/jvmci/compilerToVM/LookupKlassInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/LookupKlassInPoolTest.java index 690ef34b195..4b7e81e4b80 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/LookupKlassInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/LookupKlassInPoolTest.java @@ -32,16 +32,17 @@ * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.LookupKlassInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/LookupKlassRefIndexInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/LookupKlassRefIndexInPoolTest.java index e53d695161d..d952505718a 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/LookupKlassRefIndexInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/LookupKlassRefIndexInPoolTest.java @@ -31,15 +31,16 @@ * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions * -XX:+WhiteBoxAPI -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.LookupKlassRefIndexInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/LookupMethodInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/LookupMethodInPoolTest.java index f6d139c3b05..42bd66cd30f 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/LookupMethodInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/LookupMethodInPoolTest.java @@ -31,15 +31,16 @@ * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions * -XX:+WhiteBoxAPI -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.LookupMethodInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/LookupNameAndTypeRefIndexInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/LookupNameAndTypeRefIndexInPoolTest.java index ed376e04e41..e75a531b4e4 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/LookupNameAndTypeRefIndexInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/LookupNameAndTypeRefIndexInPoolTest.java @@ -31,15 +31,16 @@ * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions * -XX:+WhiteBoxAPI -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.LookupNameAndTypeRefIndexInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/LookupNameInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/LookupNameInPoolTest.java index e01f023f716..91b7867d6a2 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/LookupNameInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/LookupNameInPoolTest.java @@ -31,16 +31,17 @@ * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions * -XX:+WhiteBoxAPI -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.LookupNameInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/LookupSignatureInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/LookupSignatureInPoolTest.java index 3dc8a64bdd2..0953363e67e 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/LookupSignatureInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/LookupSignatureInPoolTest.java @@ -31,16 +31,17 @@ * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @build sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions * -XX:+WhiteBoxAPI -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.LookupSignatureInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/LookupTypeTest.java b/hotspot/test/compiler/jvmci/compilerToVM/LookupTypeTest.java index 225da6983e4..2b838bc0bd8 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/LookupTypeTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/LookupTypeTest.java @@ -28,9 +28,10 @@ * @library / /test/lib * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.LookupTypeTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/MaterializeVirtualObjectTest.java b/hotspot/test/compiler/jvmci/compilerToVM/MaterializeVirtualObjectTest.java index dee13cfef8d..8e919fb5ba9 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/MaterializeVirtualObjectTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/MaterializeVirtualObjectTest.java @@ -32,28 +32,60 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @run main/othervm -Xmixed -Xbootclasspath/a:. + * @run main/othervm -Xmixed -Xbatch -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * -XX:CompileCommand=exclude,*::check + * -XX:CompileCommand=exclude,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::check + * -XX:CompileCommand=dontinline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::testFrame + * -XX:CompileCommand=dontinline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::testFrame2 + * -XX:CompileCommand=inline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::recurse * -XX:+DoEscapeAnalysis -XX:-UseCounterDecay - * -Xbatch + * -Dcompiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.materializeFirst=true * -Dcompiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.invalidate=false + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest - * @run main/othervm -Xmixed -Xbootclasspath/a:. + * @run main/othervm -Xmixed -Xbatch -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * -XX:CompileCommand=exclude,*::check + * -XX:CompileCommand=exclude,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::check + * -XX:CompileCommand=dontinline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::testFrame + * -XX:CompileCommand=dontinline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::testFrame2 + * -XX:CompileCommand=inline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::recurse * -XX:+DoEscapeAnalysis -XX:-UseCounterDecay - * -Xbatch + * -Dcompiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.materializeFirst=false + * -Dcompiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.invalidate=false + * -Djvmci.Compiler=null + * compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest + * @run main/othervm -Xmixed -Xbatch -Xbootclasspath/a:. + * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI + * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -XX:CompileCommand=exclude,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::check + * -XX:CompileCommand=dontinline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::testFrame + * -XX:CompileCommand=dontinline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::testFrame2 + * -XX:CompileCommand=inline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::recurse + * -XX:+DoEscapeAnalysis -XX:-UseCounterDecay + * -Dcompiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.materializeFirst=true * -Dcompiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.invalidate=true + * -Djvmci.Compiler=null + * compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest + * @run main/othervm -Xmixed -Xbatch -Xbootclasspath/a:. + * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI + * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -XX:CompileCommand=exclude,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::check + * -XX:CompileCommand=dontinline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::testFrame + * -XX:CompileCommand=dontinline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::testFrame2 + * -XX:CompileCommand=inline,compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest::recurse + * -XX:+DoEscapeAnalysis -XX:-UseCounterDecay + * -Dcompiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.materializeFirst=false + * -Dcompiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.invalidate=true + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest */ @@ -72,25 +104,41 @@ import java.lang.reflect.Method; public class MaterializeVirtualObjectTest { private static final WhiteBox WB; - private static final Method METHOD; - private static final ResolvedJavaMethod RESOLVED_METHOD; private static final boolean INVALIDATE; private static final int COMPILE_THRESHOLD; + private static final Method MATERIALIZED_METHOD; + private static final Method NOT_MATERIALIZED_METHOD; + private static final ResolvedJavaMethod MATERIALIZED_RESOLVED; + private static final ResolvedJavaMethod NOT_MATERIALIZED_RESOLVED; + private static final boolean MATERIALIZE_FIRST; static { + Method method1; + Method method2; WB = WhiteBox.getWhiteBox(); try { - METHOD = MaterializeVirtualObjectTest.class.getDeclaredMethod( - "testFrame", String.class, int.class); + method1 = MaterializeVirtualObjectTest.class.getDeclaredMethod("testFrame", + String.class, int.class); + method2 = MaterializeVirtualObjectTest.class.getDeclaredMethod("testFrame2", + String.class, int.class); } catch (NoSuchMethodException e) { throw new Error("Can't get executable for test method", e); } - RESOLVED_METHOD = CTVMUtilities.getResolvedMethod(METHOD); + ResolvedJavaMethod resolved1; + ResolvedJavaMethod resolved2; + resolved1 = CTVMUtilities.getResolvedMethod(method1); + resolved2 = CTVMUtilities.getResolvedMethod(method2); INVALIDATE = Boolean.getBoolean( "compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.invalidate"); COMPILE_THRESHOLD = WB.getBooleanVMFlag("TieredCompilation") ? CompilerWhiteBoxTest.THRESHOLD : CompilerWhiteBoxTest.THRESHOLD * 2; + MATERIALIZE_FIRST = Boolean.getBoolean( + "compiler.jvmci.compilerToVM.MaterializeVirtualObjectTest.materializeFirst"); + MATERIALIZED_RESOLVED = MATERIALIZE_FIRST ? resolved1 : resolved2; + NOT_MATERIALIZED_RESOLVED = MATERIALIZE_FIRST ? resolved2 : resolved1; + MATERIALIZED_METHOD = MATERIALIZE_FIRST ? method1 : method2; + NOT_MATERIALIZED_METHOD = MATERIALIZE_FIRST ? method2 : method1; } public static void main(String[] args) { @@ -105,47 +153,87 @@ public class MaterializeVirtualObjectTest { } private static String getName() { - return "CASE: invalidate=" + INVALIDATE; + return "CASE: invalidate=" + INVALIDATE + ", materializedMethod=" + + (MATERIALIZE_FIRST ? "testFrame" : "testFrame2") + + ", notMaterializedMethod=" + + (MATERIALIZE_FIRST ? "testFrame2" : "testFrame"); } private void test() { System.out.println(getName()); - Asserts.assertFalse(WB.isMethodCompiled(METHOD), getName() - + " : method unexpectedly compiled"); - /* need to trigger compilation by multiple method invocations - in order to have method profile data to be gathered */ - for (int i = 0; i < COMPILE_THRESHOLD; i++) { + Asserts.assertFalse(WB.isMethodCompiled(MATERIALIZED_METHOD), + getName() + " : materialized method is compiled"); + Asserts.assertFalse(WB.isMethodCompiled(NOT_MATERIALIZED_METHOD), + getName() + " : not materialized method is compiled"); + for (int i = 0; i < CompilerWhiteBoxTest.THRESHOLD; i++) { testFrame("someString", i); } - Asserts.assertTrue(WB.isMethodCompiled(METHOD), getName() - + "Method unexpectedly not compiled"); - testFrame("someString", COMPILE_THRESHOLD); + Asserts.assertTrue(WB.isMethodCompiled(MATERIALIZED_METHOD), getName() + + " : materialized method not compiled"); + Asserts.assertTrue(WB.isMethodCompiled(NOT_MATERIALIZED_METHOD), + getName() + " : not materialized method not compiled"); + testFrame("someString", /* materialize */ CompilerWhiteBoxTest.THRESHOLD); } private void testFrame(String str, int iteration) { Helper helper = new Helper(str); - check(iteration); + testFrame2(str, iteration); Asserts.assertTrue((helper.string != null) && (this != null) - && (helper != null), getName() + " : some locals are null"); + && (helper != null), String.format("%s : some locals are null", getName())); + } + + private void testFrame2(String str, int iteration) { + Helper helper = new Helper(str); + recurse(2, iteration); + Asserts.assertTrue((helper.string != null) && (this != null) + && (helper != null), String.format("%s : some locals are null", getName())); + } + + private void recurse(int depth, int iteration) { + if (depth == 0) { + check(iteration); + } else { + Integer s = new Integer(depth); + recurse(depth - 1, iteration); + Asserts.assertEQ(s.intValue(), depth, + String.format("different values: %s != %s", s.intValue(), depth)); + } } private void check(int iteration) { // Materialize virtual objects on last invocation if (iteration == COMPILE_THRESHOLD) { - HotSpotStackFrameReference hsFrame = CompilerToVMHelper - .getNextStackFrame(/* topmost frame */ null, - new ResolvedJavaMethod[]{ - RESOLVED_METHOD}, /* don't skip any */ 0); - Asserts.assertNotNull(hsFrame, getName() + " : got null frame"); - Asserts.assertTrue(WB.isMethodCompiled(METHOD), getName() - + "Test method should be compiled"); - Asserts.assertTrue(hsFrame.hasVirtualObjects(), getName() - + ": has no virtual object before materialization"); - CompilerToVMHelper.materializeVirtualObjects(hsFrame, INVALIDATE); - Asserts.assertFalse(hsFrame.hasVirtualObjects(), getName() - + " : has virtual object after materialization"); - Asserts.assertEQ(WB.isMethodCompiled(METHOD), !INVALIDATE, getName() - + " : unexpected compiled status"); + // get frames and check not-null + HotSpotStackFrameReference materialized = CompilerToVMHelper.getNextStackFrame( + /* topmost frame */ null, new ResolvedJavaMethod[]{MATERIALIZED_RESOLVED}, + /* don't skip any */ 0); + Asserts.assertNotNull(materialized, getName() + + " : got null frame for materialized method"); + HotSpotStackFrameReference notMaterialized = CompilerToVMHelper.getNextStackFrame( + /* topmost frame */ null, new ResolvedJavaMethod[]{NOT_MATERIALIZED_RESOLVED}, + /* don't skip any */ 0); + Asserts.assertNE(materialized, notMaterialized, + "Got same frame pointer for both tested frames"); + Asserts.assertNotNull(notMaterialized, getName() + + " : got null frame for not materialized method"); + // check that frames has virtual objects before materialization stage + Asserts.assertTrue(materialized.hasVirtualObjects(), getName() + + ": materialized frame has no virtual object before materialization"); + Asserts.assertTrue(notMaterialized.hasVirtualObjects(), getName() + + ": notMaterialized frame has no virtual object before materialization"); + // materialize + CompilerToVMHelper.materializeVirtualObjects(materialized, INVALIDATE); + // check that only not materialized frame has virtual objects + Asserts.assertFalse(materialized.hasVirtualObjects(), getName() + + " : materialized has virtual object after materialization"); + Asserts.assertTrue(notMaterialized.hasVirtualObjects(), getName() + + " : notMaterialized has no virtual object after materialization"); + // check that materialized frame was deoptimized in case invalidate=true + Asserts.assertEQ(WB.isMethodCompiled(MATERIALIZED_METHOD), !INVALIDATE, getName() + + " : materialized method has unexpected compiled status"); + // check that not materialized frame wasn't deoptimized + Asserts.assertTrue(WB.isMethodCompiled(NOT_MATERIALIZED_METHOD), getName() + + " : not materialized method has unexpected compiled status"); } } diff --git a/hotspot/test/compiler/jvmci/compilerToVM/MethodIsIgnoredBySecurityStackWalkTest.java b/hotspot/test/compiler/jvmci/compilerToVM/MethodIsIgnoredBySecurityStackWalkTest.java index 6f87bcfcd2d..a854c6e798a 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/MethodIsIgnoredBySecurityStackWalkTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/MethodIsIgnoredBySecurityStackWalkTest.java @@ -31,10 +31,11 @@ * @modules java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.MethodIsIgnoredBySecurityStackWalkTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ReadConfigurationTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ReadConfigurationTest.java index 866756c5b42..080e0e81c9c 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ReadConfigurationTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ReadConfigurationTest.java @@ -28,16 +28,18 @@ * @library / /test/lib * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @build compiler.jvmci.compilerToVM.ReadConfigurationTest * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.ReadConfigurationTest */ package compiler.jvmci.compilerToVM; import jdk.test.lib.Asserts; +import jdk.vm.ci.hotspot.VMField; import jdk.vm.ci.hotspot.HotSpotJVMCIRuntime; import jdk.vm.ci.hotspot.HotSpotVMConfigAccess; import jdk.vm.ci.hotspot.HotSpotVMConfigStore; @@ -49,10 +51,19 @@ public class ReadConfigurationTest { } private void runTest() { - TestHotSpotVMConfig config = new TestHotSpotVMConfig(HotSpotJVMCIRuntime.runtime().getConfigStore()); + HotSpotVMConfigStore store = HotSpotJVMCIRuntime.runtime().getConfigStore(); + TestHotSpotVMConfig config = new TestHotSpotVMConfig(store); Asserts.assertNE(config.codeCacheHighBound, 0L, "Got null address"); Asserts.assertNE(config.stubRoutineJintArrayCopy, 0L, "Got null address"); + for (VMField field : store.getFields().values()) { + Object value = field.value; + if (value != null) { + Asserts.assertTrue(value instanceof Long || value instanceof Boolean, + "Got unexpected value type for VM field " + field.name + ": " + value.getClass()); + } + } + for (VMIntrinsicMethod m : config.getStore().getIntrinsics()) { Asserts.assertNotNull(m); Asserts.assertNotNull(m.declaringClass); diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ReprofileTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ReprofileTest.java index 9953d4c596a..c9e24fe4f2b 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ReprofileTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ReprofileTest.java @@ -30,17 +30,17 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * -Xmixed -Xbatch + * -Xmixed -Xbatch -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.ReprofileTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ResolveConstantInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ResolveConstantInPoolTest.java index 63aef07deee..68709ee2d67 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ResolveConstantInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ResolveConstantInPoolTest.java @@ -30,16 +30,17 @@ * @modules java.base/jdk.internal.misc * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.ResolveConstantInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ResolveFieldInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ResolveFieldInPoolTest.java index 2ee506ba4f9..38e9ede8f7b 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ResolveFieldInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ResolveFieldInPoolTest.java @@ -31,15 +31,16 @@ * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions * -XX:+WhiteBoxAPI -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.ResolveFieldInPoolTest */ @@ -103,7 +104,7 @@ public class ResolveFieldInPoolTest { cached = "cached "; } for (int j = 0; j < entry.opcodes.length; j++) { - long[] info = new long[2]; + int[] info = new int[3]; HotSpotResolvedObjectType fieldToVerify = CompilerToVMHelper.resolveFieldInPool(constantPoolCTVM, index, @@ -147,11 +148,11 @@ public class ResolveFieldInPoolTest { } catch (Exception ex) { throw new Error("Unexpected exception", ex); } - long offsetToRefer; + int offsetToRefer; if ((entry.accFlags & Opcodes.ACC_STATIC) != 0) { - offsetToRefer = UNSAFE.staticFieldOffset(fieldToRefer); + offsetToRefer = (int) UNSAFE.staticFieldOffset(fieldToRefer); } else { - offsetToRefer = UNSAFE.objectFieldOffset(fieldToRefer); + offsetToRefer = (int) UNSAFE.objectFieldOffset(fieldToRefer); } msg = String.format("Field offset returned by resolveFieldInPool" + " method is wrong for the field %s.%s" diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ResolveMethodTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ResolveMethodTest.java index 248077d615e..99ac158f3c5 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ResolveMethodTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ResolveMethodTest.java @@ -30,10 +30,11 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.ResolveMethodTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ResolvePossiblyCachedConstantInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ResolvePossiblyCachedConstantInPoolTest.java index ca91e75011f..1aa57ca8cc5 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ResolvePossiblyCachedConstantInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ResolvePossiblyCachedConstantInPoolTest.java @@ -31,15 +31,16 @@ * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions * -XX:+WhiteBoxAPI -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.ResolvePossiblyCachedConstantInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ResolveTypeInPoolTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ResolveTypeInPoolTest.java index 3f48fd2f7b0..593ea7aa6e0 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ResolveTypeInPoolTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ResolveTypeInPoolTest.java @@ -31,16 +31,17 @@ * @modules java.base/jdk.internal.misc * java.base/jdk.internal.reflect * java.base/jdk.internal.org.objectweb.asm - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.ResolveTypeInPoolTest */ diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ShouldDebugNonSafepointsTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ShouldDebugNonSafepointsTest.java index 18a571ba660..0cefb66e711 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ShouldDebugNonSafepointsTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ShouldDebugNonSafepointsTest.java @@ -28,8 +28,8 @@ * @library / /test/lib/ * @library ../common/patches * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI * -XX:+UnlockDiagnosticVMOptions * -XX:+DebugNonSafepoints diff --git a/hotspot/test/compiler/jvmci/compilerToVM/ShouldInlineMethodTest.java b/hotspot/test/compiler/jvmci/compilerToVM/ShouldInlineMethodTest.java index 675a1364041..89801842a09 100644 --- a/hotspot/test/compiler/jvmci/compilerToVM/ShouldInlineMethodTest.java +++ b/hotspot/test/compiler/jvmci/compilerToVM/ShouldInlineMethodTest.java @@ -30,15 +30,16 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper sun.hotspot.WhiteBox * @run driver ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null * compiler.jvmci.compilerToVM.ShouldInlineMethodTest */ diff --git a/hotspot/test/compiler/jvmci/errors/TestInvalidCompilationResult.java b/hotspot/test/compiler/jvmci/errors/TestInvalidCompilationResult.java index 7ef5f8e4800..e9670786c9e 100644 --- a/hotspot/test/compiler/jvmci/errors/TestInvalidCompilationResult.java +++ b/hotspot/test/compiler/jvmci/errors/TestInvalidCompilationResult.java @@ -24,14 +24,15 @@ /** * @test * @requires vm.jvmci - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.common + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.common * @compile CodeInstallerTest.java - * @run junit/othervm -da:jdk.vm.ci... -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI compiler.jvmci.errors.TestInvalidCompilationResult + * @run junit/othervm -da:jdk.vm.ci... -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null compiler.jvmci.errors.TestInvalidCompilationResult */ package compiler.jvmci.errors; diff --git a/hotspot/test/compiler/jvmci/errors/TestInvalidDebugInfo.java b/hotspot/test/compiler/jvmci/errors/TestInvalidDebugInfo.java index 8d3e92b1912..0d3a583141c 100644 --- a/hotspot/test/compiler/jvmci/errors/TestInvalidDebugInfo.java +++ b/hotspot/test/compiler/jvmci/errors/TestInvalidDebugInfo.java @@ -24,14 +24,15 @@ /** * @test * @requires vm.jvmci - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.common + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.common * @compile CodeInstallerTest.java - * @run junit/othervm -da:jdk.vm.ci... -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI compiler.jvmci.errors.TestInvalidDebugInfo + * @run junit/othervm -da:jdk.vm.ci... -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null compiler.jvmci.errors.TestInvalidDebugInfo */ package compiler.jvmci.errors; diff --git a/hotspot/test/compiler/jvmci/errors/TestInvalidOopMap.java b/hotspot/test/compiler/jvmci/errors/TestInvalidOopMap.java index 2e3f5f65e97..ddab47481d8 100644 --- a/hotspot/test/compiler/jvmci/errors/TestInvalidOopMap.java +++ b/hotspot/test/compiler/jvmci/errors/TestInvalidOopMap.java @@ -24,14 +24,15 @@ /** * @test * @requires vm.jvmci - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.common + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.common * @compile CodeInstallerTest.java - * @run junit/othervm -da:jdk.vm.ci... -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI compiler.jvmci.errors.TestInvalidOopMap + * @run junit/othervm -da:jdk.vm.ci... -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null compiler.jvmci.errors.TestInvalidOopMap */ package compiler.jvmci.errors; diff --git a/hotspot/test/compiler/jvmci/events/JvmciNotifyBootstrapFinishedEventTest.java b/hotspot/test/compiler/jvmci/events/JvmciNotifyBootstrapFinishedEventTest.java index 84a4c90938b..f9e3392384a 100644 --- a/hotspot/test/compiler/jvmci/events/JvmciNotifyBootstrapFinishedEventTest.java +++ b/hotspot/test/compiler/jvmci/events/JvmciNotifyBootstrapFinishedEventTest.java @@ -30,12 +30,13 @@ * @modules java.base/jdk.internal.misc * java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.services * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @build compiler.jvmci.common.JVMCIHelpers * @run driver jdk.test.lib.FileInstaller ./JvmciNotifyBootstrapFinishedEventTest.config * ./META-INF/services/jdk.vm.ci.services.JVMCIServiceLocator diff --git a/hotspot/test/compiler/jvmci/events/JvmciNotifyInstallEventTest.java b/hotspot/test/compiler/jvmci/events/JvmciNotifyInstallEventTest.java index bb888c36a00..4e661d25b6d 100644 --- a/hotspot/test/compiler/jvmci/events/JvmciNotifyInstallEventTest.java +++ b/hotspot/test/compiler/jvmci/events/JvmciNotifyInstallEventTest.java @@ -30,13 +30,14 @@ * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.org.objectweb.asm * java.base/jdk.internal.org.objectweb.asm.tree - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.services * - * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper + * @build jdk.internal.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper * @build compiler.jvmci.common.JVMCIHelpers * @run driver jdk.test.lib.FileInstaller ./JvmciNotifyInstallEventTest.config * ./META-INF/services/jdk.vm.ci.services.JVMCIServiceLocator @@ -48,21 +49,14 @@ * @run main/othervm -XX:+UnlockExperimentalVMOptions * -Xbootclasspath/a:. -Xmixed * -XX:+UseJVMCICompiler -XX:-BootstrapJVMCI - * -Dcompiler.jvmci.events.JvmciNotifyInstallEventTest.failoninit=false * compiler.jvmci.events.JvmciNotifyInstallEventTest * @run main/othervm -XX:+UnlockExperimentalVMOptions - * -Djvmci.compiler=EmptyCompiler -Xbootclasspath/a:. -Xmixed + * -Djvmci.Compiler=EmptyCompiler -Xbootclasspath/a:. -Xmixed * -XX:+UseJVMCICompiler -XX:-BootstrapJVMCI - * -Dcompiler.jvmci.events.JvmciNotifyInstallEventTest.failoninit=false * compiler.jvmci.events.JvmciNotifyInstallEventTest * @run main/othervm -XX:+UnlockExperimentalVMOptions - * -Djvmci.compiler=EmptyCompiler -Xbootclasspath/a:. -Xmixed + * -Djvmci.Compiler=EmptyCompiler -Xbootclasspath/a:. -Xmixed * -XX:+UseJVMCICompiler -XX:-BootstrapJVMCI -XX:JVMCINMethodSizeLimit=0 - * -Dcompiler.jvmci.events.JvmciNotifyInstallEventTest.failoninit=false - * compiler.jvmci.events.JvmciNotifyInstallEventTest - * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:-EnableJVMCI - * -Djvmci.compiler=EmptyCompiler -Xbootclasspath/a:. -Xmixed - * -Dcompiler.jvmci.events.JvmciNotifyInstallEventTest.failoninit=true * compiler.jvmci.events.JvmciNotifyInstallEventTest */ @@ -90,8 +84,6 @@ import java.lang.reflect.Method; public class JvmciNotifyInstallEventTest extends JVMCIServiceLocator implements HotSpotVMEventListener { private static final String METHOD_NAME = "testMethod"; - private static final boolean FAIL_ON_INIT = !Boolean.getBoolean( - "compiler.jvmci.events.JvmciNotifyInstallEventTest.failoninit"); private static volatile int gotInstallNotification = 0; public static void main(String args[]) { @@ -115,16 +107,9 @@ public class JvmciNotifyInstallEventTest extends JVMCIServiceLocator implements codeCache = (HotSpotCodeCacheProvider) HotSpotJVMCIRuntime.runtime() .getHostJVMCIBackend().getCodeCache(); } catch (InternalError ie) { - if (FAIL_ON_INIT) { - throw new AssertionError( - "Got unexpected InternalError trying to get code cache", - ie); - } // passed return; } - Asserts.assertTrue(FAIL_ON_INIT, - "Haven't caught InternalError in negative case"); Method testMethod; try { testMethod = SimpleClass.class.getDeclaredMethod(METHOD_NAME); diff --git a/hotspot/test/compiler/jvmci/events/JvmciShutdownEventTest.java b/hotspot/test/compiler/jvmci/events/JvmciShutdownEventTest.java index 76f6538bac6..40069651d59 100644 --- a/hotspot/test/compiler/jvmci/events/JvmciShutdownEventTest.java +++ b/hotspot/test/compiler/jvmci/events/JvmciShutdownEventTest.java @@ -27,10 +27,11 @@ * @requires vm.jvmci * @library /test/lib / * @modules java.base/jdk.internal.misc - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.services * * @build compiler.jvmci.common.JVMCIHelpers * compiler.jvmci.events.JvmciShutdownEventListener diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/DataPatchTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/DataPatchTest.java index 10a968f696c..135bb9284d1 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/DataPatchTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/DataPatchTest.java @@ -25,15 +25,15 @@ * @test * @requires vm.jvmci & (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9") * @library / - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.amd64 - * jdk.vm.ci/jdk.vm.ci.sparc + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.amd64 + * jdk.internal.vm.ci/jdk.vm.ci.sparc * @compile CodeInstallationTest.java DebugInfoTest.java TestAssembler.java TestHotSpotVMConfig.java amd64/AMD64TestAssembler.java sparc/SPARCTestAssembler.java - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.code.test.DataPatchTest + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.code.test.DataPatchTest */ package jdk.vm.ci.code.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/InterpreterFrameSizeTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/InterpreterFrameSizeTest.java index 05d8bdb9c44..75d0748da52 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/InterpreterFrameSizeTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/InterpreterFrameSizeTest.java @@ -24,16 +24,16 @@ /** * @test * @requires vm.jvmci & (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9") - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.common - * jdk.vm.ci/jdk.vm.ci.amd64 - * jdk.vm.ci/jdk.vm.ci.sparc + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.common + * jdk.internal.vm.ci/jdk.vm.ci.amd64 + * jdk.internal.vm.ci/jdk.vm.ci.sparc * @compile CodeInstallationTest.java TestAssembler.java TestHotSpotVMConfig.java amd64/AMD64TestAssembler.java sparc/SPARCTestAssembler.java - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.code.test.InterpreterFrameSizeTest + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.code.test.InterpreterFrameSizeTest */ package jdk.vm.ci.code.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/MaxOopMapStackOffsetTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/MaxOopMapStackOffsetTest.java index 78965574ff2..a67fa2c1dfe 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/MaxOopMapStackOffsetTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/MaxOopMapStackOffsetTest.java @@ -25,16 +25,16 @@ * @test * @requires vm.jvmci & (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9") * @library / - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.common - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.amd64 - * jdk.vm.ci/jdk.vm.ci.sparc + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.common + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.amd64 + * jdk.internal.vm.ci/jdk.vm.ci.sparc * @compile CodeInstallationTest.java DebugInfoTest.java TestAssembler.java TestHotSpotVMConfig.java amd64/AMD64TestAssembler.java sparc/SPARCTestAssembler.java - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.code.test.MaxOopMapStackOffsetTest + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.code.test.MaxOopMapStackOffsetTest */ package jdk.vm.ci.code.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/NativeCallTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/NativeCallTest.java index 49a52f8c01e..61f0e729fa4 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/NativeCallTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/NativeCallTest.java @@ -25,14 +25,14 @@ * @test * @requires vm.jvmci & (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9") * @library /test/lib / - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.common - * jdk.vm.ci/jdk.vm.ci.amd64 - * jdk.vm.ci/jdk.vm.ci.sparc + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.common + * jdk.internal.vm.ci/jdk.vm.ci.amd64 + * jdk.internal.vm.ci/jdk.vm.ci.sparc * @compile CodeInstallationTest.java TestHotSpotVMConfig.java NativeCallTest.java TestAssembler.java sparc/SPARCTestAssembler.java amd64/AMD64TestAssembler.java * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Xbootclasspath/a:. jdk.vm.ci.code.test.NativeCallTest */ diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/SimpleCodeInstallationTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/SimpleCodeInstallationTest.java index 908eaf6e79a..9b921140553 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/SimpleCodeInstallationTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/SimpleCodeInstallationTest.java @@ -25,15 +25,15 @@ * @test * @requires vm.jvmci & (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9") * @library / - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.amd64 - * jdk.vm.ci/jdk.vm.ci.sparc + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.amd64 + * jdk.internal.vm.ci/jdk.vm.ci.sparc * @compile CodeInstallationTest.java DebugInfoTest.java TestAssembler.java TestHotSpotVMConfig.java amd64/AMD64TestAssembler.java sparc/SPARCTestAssembler.java - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.code.test.SimpleCodeInstallationTest + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.code.test.SimpleCodeInstallationTest */ package jdk.vm.ci.code.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/SimpleDebugInfoTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/SimpleDebugInfoTest.java index 6f3833ed9fd..5b2204868c4 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/SimpleDebugInfoTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/SimpleDebugInfoTest.java @@ -25,15 +25,15 @@ * @test * @requires vm.jvmci & (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9") * @library / - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.amd64 - * jdk.vm.ci/jdk.vm.ci.sparc + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.amd64 + * jdk.internal.vm.ci/jdk.vm.ci.sparc * @compile CodeInstallationTest.java DebugInfoTest.java TestAssembler.java TestHotSpotVMConfig.java amd64/AMD64TestAssembler.java sparc/SPARCTestAssembler.java - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.code.test.SimpleDebugInfoTest + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.code.test.SimpleDebugInfoTest */ package jdk.vm.ci.code.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/VirtualObjectDebugInfoTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/VirtualObjectDebugInfoTest.java index c0dadbbc99e..a10e90acdaf 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/VirtualObjectDebugInfoTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/VirtualObjectDebugInfoTest.java @@ -25,15 +25,15 @@ * @test * @requires vm.jvmci & (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9") * @library / - * @modules jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.code - * jdk.vm.ci/jdk.vm.ci.code.site - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.amd64 - * jdk.vm.ci/jdk.vm.ci.sparc + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.code + * jdk.internal.vm.ci/jdk.vm.ci.code.site + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.amd64 + * jdk.internal.vm.ci/jdk.vm.ci.sparc * @compile CodeInstallationTest.java DebugInfoTest.java TestAssembler.java TestHotSpotVMConfig.java amd64/AMD64TestAssembler.java sparc/SPARCTestAssembler.java - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.code.test.VirtualObjectDebugInfoTest + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.code.test.VirtualObjectDebugInfoTest */ package jdk.vm.ci.code.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/HotSpotConstantReflectionProviderTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/HotSpotConstantReflectionProviderTest.java index b3ee6312348..a9bba4a4bb6 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/HotSpotConstantReflectionProviderTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/HotSpotConstantReflectionProviderTest.java @@ -24,9 +24,9 @@ /* * @test jdk.vm.ci.hotspot.test.HotSpotConstantReflectionProviderTest * @requires vm.jvmci - * @modules jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.hotspot + * @modules jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.hotspot * java.base/jdk.internal.vm.annotation * java.base/jdk.internal.misc * @library /test/lib /compiler/jvmci/jdk.vm.ci.hotspot.test/src @@ -34,7 +34,7 @@ * @run driver ClassFileInstaller jdk.vm.ci.hotspot.test.DummyClass * @run testng/othervm/timeout=300 -Xbootclasspath/a:. * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * jdk.vm.ci.hotspot.test.HotSpotConstantReflectionProviderTest + * -Djvmci.Compiler=null jdk.vm.ci.hotspot.test.HotSpotConstantReflectionProviderTest */ package jdk.vm.ci.hotspot.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MemoryAccessProviderData.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MemoryAccessProviderData.java index fcbc721caa8..1122bd7eb5d 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MemoryAccessProviderData.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MemoryAccessProviderData.java @@ -27,6 +27,7 @@ import java.lang.reflect.Field; import org.testng.annotations.DataProvider; +import sun.hotspot.WhiteBox; import jdk.internal.misc.Unsafe; import jdk.vm.ci.hotspot.HotSpotConstantReflectionProvider; import jdk.vm.ci.hotspot.HotSpotJVMCIRuntimeProvider; @@ -36,6 +37,10 @@ import jdk.vm.ci.meta.Constant; import jdk.vm.ci.meta.JavaConstant; import jdk.vm.ci.meta.JavaKind; import jdk.vm.ci.runtime.JVMCI; +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; public class MemoryAccessProviderData { private static final Unsafe UNSAFE = Unsafe.getUnsafe(); @@ -43,6 +48,18 @@ public class MemoryAccessProviderData { private static final TestClass TEST_OBJECT = new TestClass(); private static final JavaConstant TEST_CONSTANT = CONSTANT_REFLECTION.forObject(TEST_OBJECT); private static final JavaConstant TEST_CLASS_CONSTANT = CONSTANT_REFLECTION.forObject(TestClass.class); + private static KindData[] PRIMITIVE_KIND_DATA = { + new KindData(JavaKind.Boolean, TEST_OBJECT), + new KindData(JavaKind.Byte, TEST_OBJECT), + new KindData(JavaKind.Char, TEST_OBJECT), + new KindData(JavaKind.Short, TEST_OBJECT), + new KindData(JavaKind.Int, TEST_OBJECT), + new KindData(JavaKind.Float, TEST_OBJECT), + new KindData(JavaKind.Long, TEST_OBJECT), + new KindData(JavaKind.Double, TEST_OBJECT) + }; + private static final WhiteBox WHITE_BOX = WhiteBox.getWhiteBox(); + @DataProvider(name = "positiveObject") public static Object[][] getPositiveObjectJavaKind() { @@ -54,51 +71,40 @@ public class MemoryAccessProviderData { @DataProvider(name = "positivePrimitive") public static Object[][] getPositivePrimitiveJavaKinds() { - Field booleanField; - Field byteField; - Field shortField; - Field intField; - Field longField; - Field floatField; - Field doubleField; - Field charField; - try { - booleanField = MemoryAccessProviderData.TestClass.class.getDeclaredField("booleanField"); - byteField = MemoryAccessProviderData.TestClass.class.getDeclaredField("byteField"); - shortField = MemoryAccessProviderData.TestClass.class.getDeclaredField("shortField"); - intField = MemoryAccessProviderData.TestClass.class.getDeclaredField("intField"); - longField = MemoryAccessProviderData.TestClass.class.getDeclaredField("longField"); - floatField = MemoryAccessProviderData.TestClass.class.getDeclaredField("floatField"); - doubleField = MemoryAccessProviderData.TestClass.class.getDeclaredField("doubleField"); - charField = MemoryAccessProviderData.TestClass.class.getDeclaredField("charField"); - } catch (NoSuchFieldException e) { - throw new Error("TESTBUG: can't find test field " + e, e); + List result = new ArrayList<>(); + for (KindData k : PRIMITIVE_KIND_DATA) { + result.add(new Object[] {k.kind, TEST_CONSTANT, k.instanceFieldOffset, k.instanceFieldValue, Math.max(8, k.kind.getBitCount())}); + result.add(new Object[] {k.kind, TEST_CLASS_CONSTANT, k.staticFieldOffset, k.staticFieldValue, Math.max(8, k.kind.getBitCount())}); } - long booleanFieldOffset = UNSAFE.objectFieldOffset(booleanField); - long byteFieldOffset = UNSAFE.objectFieldOffset(byteField); - long shortFieldOffset = UNSAFE.objectFieldOffset(shortField); - long intFieldOffset = UNSAFE.objectFieldOffset(intField); - long longFieldOffset = UNSAFE.objectFieldOffset(longField); - long floatFieldOffset = UNSAFE.objectFieldOffset(floatField); - long doubleFieldOffset = UNSAFE.objectFieldOffset(doubleField); - long charFieldOffset = UNSAFE.objectFieldOffset(charField); - return new Object[][]{ - new Object[]{JavaKind.Boolean, TEST_CONSTANT, booleanFieldOffset, - JavaConstant.forBoolean(TEST_OBJECT.booleanField), 8}, - new Object[]{JavaKind.Byte, TEST_CONSTANT, byteFieldOffset, - JavaConstant.forByte(TEST_OBJECT.byteField), 8}, - new Object[]{JavaKind.Short, TEST_CONSTANT, shortFieldOffset, - JavaConstant.forShort(TEST_OBJECT.shortField), 16}, - new Object[]{JavaKind.Int, TEST_CONSTANT, intFieldOffset, - JavaConstant.forInt(TEST_OBJECT.intField), 32}, - new Object[]{JavaKind.Long, TEST_CONSTANT, longFieldOffset, - JavaConstant.forLong(TEST_OBJECT.longField), 64}, - new Object[]{JavaKind.Float, TEST_CONSTANT, floatFieldOffset, - JavaConstant.forFloat(TEST_OBJECT.floatField), 32}, - new Object[]{JavaKind.Double, TEST_CONSTANT, doubleFieldOffset, - JavaConstant.forDouble(TEST_OBJECT.doubleField), 64}, - new Object[]{JavaKind.Char, TEST_CONSTANT, charFieldOffset, - JavaConstant.forChar(TEST_OBJECT.charField), 16}}; + return result.toArray(new Object[result.size()][]); + } + + @DataProvider(name = "outOfBoundsInstanceFields") + public static Object[][] getOutOfBoundsStaticFieldReads() { + long instanceSize = WHITE_BOX.getObjectSize(TEST_OBJECT); + List result = new ArrayList<>(); + for (KindData k : PRIMITIVE_KIND_DATA) { + long lastValidOffset = instanceSize - (k.kind.getByteCount()); + result.add(new Object[] {k.kind, TEST_CONSTANT, lastValidOffset, false}); + result.add(new Object[] {k.kind, TEST_CONSTANT, (long) -1, true}); + result.add(new Object[] {k.kind, TEST_CONSTANT, lastValidOffset + 1, true}); + result.add(new Object[] {k.kind, TEST_CONSTANT, lastValidOffset + 100, true}); + } + return result.toArray(new Object[result.size()][]); + } + + @DataProvider(name = "outOfBoundsStaticFields") + public static Object[][] getOutOfBoundsInstanceFieldReads() { + long staticsSize = WHITE_BOX.getObjectSize(TEST_OBJECT.getClass()); + List result = new ArrayList<>(); + for (KindData k : PRIMITIVE_KIND_DATA) { + long lastValidOffset = staticsSize - (k.kind.getByteCount()); + result.add(new Object[] {k.kind, TEST_CLASS_CONSTANT, lastValidOffset, false}); + result.add(new Object[] {k.kind, TEST_CLASS_CONSTANT, (long) -1, true}); + result.add(new Object[] {k.kind, TEST_CLASS_CONSTANT, lastValidOffset + 1, true}); + result.add(new Object[] {k.kind, TEST_CLASS_CONSTANT, lastValidOffset + 100, true}); + } + return result.toArray(new Object[result.size()][]); } @DataProvider(name = "negative") @@ -108,6 +114,7 @@ public class MemoryAccessProviderData { new Object[]{JavaKind.Illegal, JavaConstant.INT_1}}; } + private static class TestClass { public final boolean booleanField = true; public final byte byteField = 2; @@ -117,6 +124,43 @@ public class MemoryAccessProviderData { public final double doubleField = 6.0d; public final float floatField = 7.0f; public final char charField = 'a'; - public final String stringField = "abc"; + public final String objectField = "abc"; + + public static final boolean booleanStaticField = true; + public static final byte byteStaticField = 2; + public static final short shortStaticField = 3; + public static final int intStaticField = 4; + public static final long longStaticField = 5L; + public static final double doubleStaticField = 6.0d; + public static final float floatStaticField = 7.0f; + public static final char charStaticField = 'a'; + public static final String objectStaticField = "abc"; + } + + + static class KindData { + final JavaKind kind; + final Field instanceField; + final Field staticField; + final long instanceFieldOffset; + final long staticFieldOffset; + final JavaConstant instanceFieldValue; + final JavaConstant staticFieldValue; + KindData(JavaKind kind, Object testObject) { + this.kind = kind; + try { + Class c = testObject.getClass(); + instanceField = c.getDeclaredField(kind.getJavaName() + "Field"); + staticField = c.getDeclaredField(kind.getJavaName() + "StaticField"); + instanceField.setAccessible(true); + staticField.setAccessible(true); + instanceFieldOffset = UNSAFE.objectFieldOffset(instanceField); + staticFieldOffset = UNSAFE.staticFieldOffset(staticField); + instanceFieldValue = JavaConstant.forBoxedPrimitive(instanceField.get(testObject)); + staticFieldValue = JavaConstant.forBoxedPrimitive(staticField.get(null)); + } catch (Exception e) { + throw new Error("TESTBUG for kind " + kind, e); + } + } } } diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MemoryAccessProviderTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MemoryAccessProviderTest.java index bbf4c3a1ab9..d119a2bca06 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MemoryAccessProviderTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MemoryAccessProviderTest.java @@ -26,17 +26,24 @@ * @bug 8152341 * @requires vm.jvmci * @library /test/lib /compiler/jvmci/jdk.vm.ci.hotspot.test/src - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.common - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.hotspot + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.common + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.hotspot * java.base/jdk.internal.misc - * @run testng/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * jdk.vm.ci.hotspot.test.MemoryAccessProviderTest + * @build sun.hotspot.WhiteBox + * @run driver ClassFileInstaller sun.hotspot.WhiteBox + * sun.hotspot.WhiteBox$WhiteBoxPermission + * @run testng/othervm -Xbootclasspath/a:. + * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI + * -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI + * -Djvmci.Compiler=null jdk.vm.ci.hotspot.test.MemoryAccessProviderTest */ package jdk.vm.ci.hotspot.test; +import sun.hotspot.WhiteBox; + import jdk.vm.ci.meta.Constant; import jdk.vm.ci.meta.JavaKind; import jdk.vm.ci.meta.MemoryAccessProvider; @@ -59,7 +66,27 @@ public class MemoryAccessProviderTest { @Test(dataProvider = "negative", dataProviderClass = MemoryAccessProviderData.class, expectedExceptions = {IllegalArgumentException.class}) public void testNegativeReadPrimitiveConstant(JavaKind kind, Constant base) { - PROVIDER.readPrimitiveConstant(kind, base, 0L, kind == null ? 0 : kind.getBitCount()); + PROVIDER.readPrimitiveConstant(kind, base, 0L, kind == null ? 0 : kind.getByteCount() / 8); + } + + @Test(dataProvider = "outOfBoundsInstanceFields", dataProviderClass = MemoryAccessProviderData.class) + public void testReadPrimitiveInstanceFieldOutOfBounds(JavaKind kind, Constant base, Long offset, boolean isOutOfBounds) { + try { + PROVIDER.readPrimitiveConstant(kind, base, offset, kind.getByteCount() * 8); + Assert.assertFalse(isOutOfBounds); + } catch (IllegalArgumentException iae) { + Assert.assertTrue(isOutOfBounds); + } + } + + @Test(dataProvider = "outOfBoundsStaticFields", dataProviderClass = MemoryAccessProviderData.class) + public void testReadPrimitiveStaticFieldOutOFBounds(JavaKind kind, Constant base, Long offset, boolean isOutOfBounds) { + try { + PROVIDER.readPrimitiveConstant(kind, base, offset, kind.getByteCount() * 8); + Assert.assertFalse(isOutOfBounds); + } catch (IllegalArgumentException iae) { + Assert.assertTrue(isOutOfBounds); + } } @Test(dataProvider = "positiveObject", dataProviderClass = MemoryAccessProviderData.class, expectedExceptions = {IllegalArgumentException.class}) @@ -87,7 +114,7 @@ public class MemoryAccessProviderTest { Assert.assertNull(PROVIDER.readObjectConstant(base, offset + 1), "Expected null"); } - @Test(dataProvider = "positivePrimitive", dataProviderClass = MemoryAccessProviderData.class) + @Test(dataProvider = "positivePrimitive", dataProviderClass = MemoryAccessProviderData.class, expectedExceptions = {IllegalArgumentException.class}) public void testNegativeReadObjectConstantPrimitiveBase(JavaKind kind, Constant base, Long offset, Object expected, int bitsCount) { Assert.assertNull(PROVIDER.readObjectConstant(base, offset), "Expected null"); } diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MethodHandleAccessProviderTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MethodHandleAccessProviderTest.java index 153cfc9698e..a1fea7d8f0f 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MethodHandleAccessProviderTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.hotspot.test/src/jdk/vm/ci/hotspot/test/MethodHandleAccessProviderTest.java @@ -28,11 +28,11 @@ * @requires vm.jvmci * @library /test/lib /compiler/jvmci/jdk.vm.ci.hotspot.test/src * @modules java.base/java.lang.invoke:+open - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * @modules jdk.vm.ci/jdk.vm.ci.hotspot:+open + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.hotspot:+open * @run testng/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI - * jdk.vm.ci.hotspot.test.MethodHandleAccessProviderTest + * -Djvmci.Compiler=null jdk.vm.ci.hotspot.test.MethodHandleAccessProviderTest */ package jdk.vm.ci.hotspot.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ConstantTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ConstantTest.java index fb0f1a2bd80..a0a9218b220 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ConstantTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ConstantTest.java @@ -25,10 +25,10 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.ConstantTest + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.ConstantTest */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/RedefineClassTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/RedefineClassTest.java index 8f0ce0c2cc9..c9e027a8807 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/RedefineClassTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/RedefineClassTest.java @@ -25,11 +25,11 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * jdk.attach * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.RedefineClassTest + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null -Djdk.attach.allowAttachSelf jdk.vm.ci.runtime.test.RedefineClassTest */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveConcreteMethodTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveConcreteMethodTest.java index 78c5a79f81c..20bb4d872c6 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveConcreteMethodTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveConcreteMethodTest.java @@ -24,9 +24,9 @@ /** * @test * @requires vm.jvmci - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.ResolvedJavaTypeResolveConcreteMethodTest + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.ResolvedJavaTypeResolveConcreteMethodTest */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveMethodTest.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveMethodTest.java index f4b15b2dc82..1d754b1f381 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveMethodTest.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/ResolvedJavaTypeResolveMethodTest.java @@ -24,9 +24,9 @@ /** * @test * @requires vm.jvmci - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.ResolvedJavaTypeResolveMethodTest + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.ResolvedJavaTypeResolveMethodTest */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestConstantReflectionProvider.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestConstantReflectionProvider.java index 43cd69f0352..6f11bd5d5de 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestConstantReflectionProvider.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestConstantReflectionProvider.java @@ -25,10 +25,10 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.TestConstantReflectionProvider + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.TestConstantReflectionProvider */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaField.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaField.java index 792901898a3..4d4313981c5 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaField.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaField.java @@ -25,10 +25,10 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.TestJavaField + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.TestJavaField */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaMethod.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaMethod.java index a8edfec11e5..357d1097597 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaMethod.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaMethod.java @@ -25,10 +25,10 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.TestJavaMethod + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.TestJavaMethod */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaType.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaType.java index 669b579d51b..45aa1b73dbd 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaType.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestJavaType.java @@ -25,10 +25,10 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.TestJavaType + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.TestJavaType */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestMetaAccessProvider.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestMetaAccessProvider.java index 37d7d5233da..fc7cecdaba2 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestMetaAccessProvider.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestMetaAccessProvider.java @@ -25,10 +25,10 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.TestMetaAccessProvider + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.TestMetaAccessProvider */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaField.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaField.java index 48a6dc8613e..20800d4478b 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaField.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaField.java @@ -25,10 +25,10 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.TestResolvedJavaField + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.TestResolvedJavaField */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaMethod.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaMethod.java index 5087814bdaf..3a27644ab6a 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaMethod.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaMethod.java @@ -25,10 +25,10 @@ * @test * @requires vm.jvmci * @library ../../../../../ - * @modules jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * @modules jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.TestResolvedJavaMethod + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.TestResolvedJavaMethod */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaType.java b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaType.java index e8f9f9ba082..b732aca979a 100644 --- a/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaType.java +++ b/hotspot/test/compiler/jvmci/jdk.vm.ci.runtime.test/src/jdk/vm/ci/runtime/test/TestResolvedJavaType.java @@ -26,11 +26,11 @@ * @requires vm.jvmci * @library ../../../../../ * @modules java.base/jdk.internal.reflect - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime - * jdk.vm.ci/jdk.vm.ci.common + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.common * java.base/jdk.internal.misc - * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI jdk.vm.ci.runtime.test.TestResolvedJavaType + * @run junit/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null jdk.vm.ci.runtime.test.TestResolvedJavaType */ package jdk.vm.ci.runtime.test; diff --git a/hotspot/test/compiler/jvmci/meta/StableFieldTest.java b/hotspot/test/compiler/jvmci/meta/StableFieldTest.java index 147811f6b6f..05849847603 100644 --- a/hotspot/test/compiler/jvmci/meta/StableFieldTest.java +++ b/hotspot/test/compiler/jvmci/meta/StableFieldTest.java @@ -28,13 +28,13 @@ * @library /test/lib / * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.vm.annotation - * jdk.vm.ci/jdk.vm.ci.hotspot - * jdk.vm.ci/jdk.vm.ci.meta - * jdk.vm.ci/jdk.vm.ci.runtime + * jdk.internal.vm.ci/jdk.vm.ci.hotspot + * jdk.internal.vm.ci/jdk.vm.ci.meta + * jdk.internal.vm.ci/jdk.vm.ci.runtime * * @compile StableFieldTest.java * @run driver ClassFileInstaller compiler.jvmci.meta.StableFieldTest - * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Xbootclasspath/a:. compiler.jvmci.meta.StableFieldTest + * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Djvmci.Compiler=null -Xbootclasspath/a:. compiler.jvmci.meta.StableFieldTest */ package compiler.jvmci.meta; diff --git a/hotspot/test/compiler/loopopts/TestLoopPeeling.java b/hotspot/test/compiler/loopopts/TestLoopPeeling.java index 3627ff5726c..a32f3cb851a 100644 --- a/hotspot/test/compiler/loopopts/TestLoopPeeling.java +++ b/hotspot/test/compiler/loopopts/TestLoopPeeling.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8078262 + * @bug 8078262 8177095 * @summary Tests correct dominator information after loop peeling. * * @run main/othervm -Xcomp @@ -40,14 +40,16 @@ public class TestLoopPeeling { public static void main(String args[]) { TestLoopPeeling test = new TestLoopPeeling(); try { - test.testArrayAccess(0, 1); + test.testArrayAccess1(0, 1); + test.testArrayAccess2(0); + test.testArrayAccess3(0, false); test.testArrayAllocation(0, 1); } catch (Exception e) { // Ignore exceptions } } - public void testArrayAccess(int index, int inc) { + public void testArrayAccess1(int index, int inc) { int storeIndex = -1; for (; index < 10; index += inc) { @@ -63,7 +65,7 @@ public class TestLoopPeeling { if (index == 42) { // This store and the corresponding range check are moved out of the - // loop and both used after old loop and the peeled iteration exit. + // loop and both used after main loop and the peeled iteration exit. // For the peeled iteration, storeIndex is always -1 and the ConvI2L // is replaced by TOP. However, the range check is not folded because // we don't do the split if optimization in PhaseIdealLoop2. @@ -77,6 +79,44 @@ public class TestLoopPeeling { } } + public int testArrayAccess2(int index) { + // Load1 and the corresponding range check are moved out of the loop + // and both are used after the main loop and the peeled iteration exit. + // For the peeled iteration, storeIndex is always Integer.MIN_VALUE and + // for the main loop it is 0. Hence, the merging phi has type int:<=0. + // Load1 reads the array at index ConvI2L(CastII(AddI(storeIndex, -1))) + // where the CastII is range check dependent and has type int:>=0. + // The CastII gets pushed through the AddI and its type is changed to int:>=1 + // which does not overlap with the input type of storeIndex (int:<=0). + // The CastII is replaced by TOP causing a cascade of other eliminations. + // Since the control path through the range check CmpU(AddI(storeIndex, -1)) + // is not eliminated, the graph is in a corrupted state. We fail once we merge + // with the result of Load2 because we get data from a non-dominating region. + int storeIndex = Integer.MIN_VALUE; + for (; index < 10; ++index) { + if (index == 42) { + return array[storeIndex-1]; // Load1 + } + storeIndex = 0; + } + return array[42]; // Load2 + } + + public int testArrayAccess3(int index, boolean b) { + // Same as testArrayAccess2 but manifests as crash in register allocator. + int storeIndex = Integer.MIN_VALUE; + for (; index < 10; ++index) { + if (b) { + return 0; + } + if (index == 42) { + return array[storeIndex-1]; // Load1 + } + storeIndex = 0; + } + return array[42]; // Load2 + } + public byte[] testArrayAllocation(int index, int inc) { int allocationCount = -1; byte[] result; @@ -88,7 +128,7 @@ public class TestLoopPeeling { if (index == 42) { // This allocation and the corresponding size check are moved out of the - // loop and both used after old loop and the peeled iteration exit. + // loop and both used after main loop and the peeled iteration exit. // For the peeled iteration, allocationCount is always -1 and the ConvI2L // is replaced by TOP. However, the size check is not folded because // we don't do the split if optimization in PhaseIdealLoop2. diff --git a/hotspot/test/compiler/patches/java.base/java/lang/Helper.java b/hotspot/test/compiler/patches/java.base/java/lang/Helper.java index 65347c87b1b..b38bebba309 100644 --- a/hotspot/test/compiler/patches/java.base/java/lang/Helper.java +++ b/hotspot/test/compiler/patches/java.base/java/lang/Helper.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -73,4 +73,84 @@ public class Helper { StringUTF16.getChars(value, srcBegin, srcEnd, dst, dstBegin); return dst; } + + public static void putCharSB(byte[] val, int index, int c) { + StringUTF16.putCharSB(val, index, c); + } + + public static void putCharsSB(byte[] val, int index, char[] ca, int off, int end) { + StringUTF16.putCharsSB(val, index, ca, off, end); + } + + public static void putCharsSB(byte[] val, int index, CharSequence s, int off, int end) { + StringUTF16.putCharsSB(val, index, s, off, end); + } + + public static int codePointAtSB(byte[] val, int index, int end) { + return StringUTF16.codePointAtSB(val, index, end); + } + + public static int codePointBeforeSB(byte[] val, int index) { + return StringUTF16.codePointBeforeSB(val, index); + } + + public static int codePointCountSB(byte[] val, int beginIndex, int endIndex) { + return StringUTF16.codePointCountSB(val, beginIndex, endIndex); + } + + public static int getChars(int i, int begin, int end, byte[] value) { + return StringUTF16.getChars(i, begin, end, value); + } + + public static int getChars(long l, int begin, int end, byte[] value) { + return StringUTF16.getChars(l, begin, end, value); + } + + public static boolean contentEquals(byte[] v1, byte[] v2, int len) { + return StringUTF16.contentEquals(v1, v2, len); + } + + public static boolean contentEquals(byte[] value, CharSequence cs, int len) { + return StringUTF16.contentEquals(value, cs, len); + } + + public static int putCharsAt(byte[] value, int i, char c1, char c2, char c3, char c4) { + return StringUTF16.putCharsAt(value, i, c1, c2, c3, c4); + } + + public static int putCharsAt(byte[] value, int i, char c1, char c2, char c3, char c4, char c5) { + return StringUTF16.putCharsAt(value, i, c1, c2, c3, c4, c5); + } + + public static char charAt(byte[] value, int index) { + return StringUTF16.charAt(value, index); + } + + public static void reverse(byte[] value, int count) { + StringUTF16.reverse(value, count); + } + + public static void inflate(byte[] src, int srcOff, byte[] dst, int dstOff, int len) { + StringUTF16.inflate(src, srcOff, dst, dstOff, len); + } + + public static int indexOf(byte[] src, int srcCount, + byte[] tgt, int tgtCount, int fromIndex) { + return StringUTF16.indexOf(src, srcCount, tgt, tgtCount, fromIndex); + } + + public static int indexOfLatin1(byte[] src, int srcCount, + byte[] tgt, int tgtCount, int fromIndex) { + return StringUTF16.indexOfLatin1(src, srcCount, tgt, tgtCount, fromIndex); + } + public static int lastIndexOf(byte[] src, byte[] tgt, int tgtCount, int fromIndex) { + int srcCount = StringUTF16.length(src); // ignored + return StringUTF16.lastIndexOf(src, srcCount, tgt, tgtCount, fromIndex); + } + + public static int lastIndexOfLatin1(byte[] src, byte[] tgt, int tgtCount, int fromIndex) { + int srcCount = StringUTF16.length(src); // ignored + return StringUTF16.lastIndexOfLatin1(src, srcCount, tgt, tgtCount, fromIndex); + } + } diff --git a/hotspot/test/compiler/profiling/spectrapredefineclass/Launcher.java b/hotspot/test/compiler/profiling/spectrapredefineclass/Launcher.java index 9ca9ba0283b..d2e1b136980 100644 --- a/hotspot/test/compiler/profiling/spectrapredefineclass/Launcher.java +++ b/hotspot/test/compiler/profiling/spectrapredefineclass/Launcher.java @@ -33,7 +33,7 @@ * @run driver compiler.profiling.spectrapredefineclass.Launcher * @run main/othervm -XX:-TieredCompilation -XX:-BackgroundCompilation * -XX:-UseOnStackReplacement -XX:TypeProfileLevel=222 - * -XX:ReservedCodeCacheSize=3M + * -XX:ReservedCodeCacheSize=3M -Djdk.attach.allowAttachSelf * compiler.profiling.spectrapredefineclass.Agent */ diff --git a/hotspot/test/compiler/profiling/spectrapredefineclass_classloaders/Launcher.java b/hotspot/test/compiler/profiling/spectrapredefineclass_classloaders/Launcher.java index 857fbbbbd84..cea5a477d1d 100644 --- a/hotspot/test/compiler/profiling/spectrapredefineclass_classloaders/Launcher.java +++ b/hotspot/test/compiler/profiling/spectrapredefineclass_classloaders/Launcher.java @@ -36,7 +36,7 @@ * @run driver compiler.profiling.spectrapredefineclass_classloaders.Launcher * @run main/othervm -XX:-TieredCompilation -XX:-BackgroundCompilation * -XX:-UseOnStackReplacement -XX:TypeProfileLevel=222 - * -XX:ReservedCodeCacheSize=3M + * -XX:ReservedCodeCacheSize=3M -Djdk.attach.allowAttachSelf * compiler.profiling.spectrapredefineclass_classloaders.Agent */ diff --git a/hotspot/test/compiler/testlibrary/rtm/predicate/SupportedVM.java b/hotspot/test/compiler/testlibrary/rtm/predicate/SupportedVM.java index f4958a607c2..fee36b9e5c1 100644 --- a/hotspot/test/compiler/testlibrary/rtm/predicate/SupportedVM.java +++ b/hotspot/test/compiler/testlibrary/rtm/predicate/SupportedVM.java @@ -30,6 +30,6 @@ import java.util.function.BooleanSupplier; public class SupportedVM implements BooleanSupplier { @Override public boolean getAsBoolean() { - return Platform.isServer(); + return Platform.isServer() && !Platform.isEmulatedClient(); } } diff --git a/hotspot/test/compiler/types/correctness/OffTest.java b/hotspot/test/compiler/types/correctness/OffTest.java index 7593fc68a0d..5a8fe5953ac 100644 --- a/hotspot/test/compiler/types/correctness/OffTest.java +++ b/hotspot/test/compiler/types/correctness/OffTest.java @@ -24,6 +24,7 @@ /* * @test CorrectnessTest * @bug 8038418 + * @requires vm.flavor == "server" & !vm.emulatedClient * @library /test/lib / * @modules java.base/jdk.internal.misc * java.management diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestBoolean.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestBoolean.java index 50e505bd840..75c33c9984c 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestBoolean.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestBoolean.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -151,32 +151,32 @@ public class JdkInternalMiscUnsafeAccessTestBoolean { // Compare { - boolean r = UNSAFE.compareAndSwapBoolean(base, offset, true, false); - assertEquals(r, true, "success compareAndSwap boolean"); + boolean r = UNSAFE.compareAndSetBoolean(base, offset, true, false); + assertEquals(r, true, "success compareAndSet boolean"); boolean x = UNSAFE.getBoolean(base, offset); - assertEquals(x, false, "success compareAndSwap boolean value"); + assertEquals(x, false, "success compareAndSet boolean value"); } { - boolean r = UNSAFE.compareAndSwapBoolean(base, offset, true, false); - assertEquals(r, false, "failing compareAndSwap boolean"); + boolean r = UNSAFE.compareAndSetBoolean(base, offset, true, false); + assertEquals(r, false, "failing compareAndSet boolean"); boolean x = UNSAFE.getBoolean(base, offset); - assertEquals(x, false, "failing compareAndSwap boolean value"); + assertEquals(x, false, "failing compareAndSet boolean value"); } // Advanced compare { - boolean r = UNSAFE.compareAndExchangeBooleanVolatile(base, offset, false, true); - assertEquals(r, false, "success compareAndExchangeVolatile boolean"); + boolean r = UNSAFE.compareAndExchangeBoolean(base, offset, false, true); + assertEquals(r, false, "success compareAndExchange boolean"); boolean x = UNSAFE.getBoolean(base, offset); - assertEquals(x, true, "success compareAndExchangeVolatile boolean value"); + assertEquals(x, true, "success compareAndExchange boolean value"); } { - boolean r = UNSAFE.compareAndExchangeBooleanVolatile(base, offset, false, false); - assertEquals(r, true, "failing compareAndExchangeVolatile boolean"); + boolean r = UNSAFE.compareAndExchangeBoolean(base, offset, false, false); + assertEquals(r, true, "failing compareAndExchange boolean"); boolean x = UNSAFE.getBoolean(base, offset); - assertEquals(x, true, "failing compareAndExchangeVolatile boolean value"); + assertEquals(x, true, "failing compareAndExchange boolean value"); } { @@ -210,41 +210,41 @@ public class JdkInternalMiscUnsafeAccessTestBoolean { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapBoolean(base, offset, true, false); + success = UNSAFE.weakCompareAndSetBooleanPlain(base, offset, true, false); } - assertEquals(success, true, "weakCompareAndSwap boolean"); + assertEquals(success, true, "weakCompareAndSetPlain boolean"); boolean x = UNSAFE.getBoolean(base, offset); - assertEquals(x, false, "weakCompareAndSwap boolean value"); + assertEquals(x, false, "weakCompareAndSetPlain boolean value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapBooleanAcquire(base, offset, false, true); + success = UNSAFE.weakCompareAndSetBooleanAcquire(base, offset, false, true); } - assertEquals(success, true, "weakCompareAndSwapAcquire boolean"); + assertEquals(success, true, "weakCompareAndSetAcquire boolean"); boolean x = UNSAFE.getBoolean(base, offset); - assertEquals(x, true, "weakCompareAndSwapAcquire boolean"); + assertEquals(x, true, "weakCompareAndSetAcquire boolean"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapBooleanRelease(base, offset, true, false); + success = UNSAFE.weakCompareAndSetBooleanRelease(base, offset, true, false); } - assertEquals(success, true, "weakCompareAndSwapRelease boolean"); + assertEquals(success, true, "weakCompareAndSetRelease boolean"); boolean x = UNSAFE.getBoolean(base, offset); - assertEquals(x, false, "weakCompareAndSwapRelease boolean"); + assertEquals(x, false, "weakCompareAndSetRelease boolean"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapBooleanVolatile(base, offset, false, true); + success = UNSAFE.weakCompareAndSetBoolean(base, offset, false, true); } - assertEquals(success, true, "weakCompareAndSwapVolatile boolean"); + assertEquals(success, true, "weakCompareAndSet boolean"); boolean x = UNSAFE.getBoolean(base, offset); - assertEquals(x, true, "weakCompareAndSwapVolatile boolean"); + assertEquals(x, true, "weakCompareAndSet boolean"); } UNSAFE.putBoolean(base, offset, false); @@ -260,4 +260,3 @@ public class JdkInternalMiscUnsafeAccessTestBoolean { } } - diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestByte.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestByte.java index e35e5904d93..30ffae395df 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestByte.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestByte.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -180,32 +180,32 @@ public class JdkInternalMiscUnsafeAccessTestByte { // Compare { - boolean r = UNSAFE.compareAndSwapByte(base, offset, (byte)0x01, (byte)0x23); - assertEquals(r, true, "success compareAndSwap byte"); + boolean r = UNSAFE.compareAndSetByte(base, offset, (byte)0x01, (byte)0x23); + assertEquals(r, true, "success compareAndSet byte"); byte x = UNSAFE.getByte(base, offset); - assertEquals(x, (byte)0x23, "success compareAndSwap byte value"); + assertEquals(x, (byte)0x23, "success compareAndSet byte value"); } { - boolean r = UNSAFE.compareAndSwapByte(base, offset, (byte)0x01, (byte)0x45); - assertEquals(r, false, "failing compareAndSwap byte"); + boolean r = UNSAFE.compareAndSetByte(base, offset, (byte)0x01, (byte)0x45); + assertEquals(r, false, "failing compareAndSet byte"); byte x = UNSAFE.getByte(base, offset); - assertEquals(x, (byte)0x23, "failing compareAndSwap byte value"); + assertEquals(x, (byte)0x23, "failing compareAndSet byte value"); } // Advanced compare { - byte r = UNSAFE.compareAndExchangeByteVolatile(base, offset, (byte)0x23, (byte)0x01); - assertEquals(r, (byte)0x23, "success compareAndExchangeVolatile byte"); + byte r = UNSAFE.compareAndExchangeByte(base, offset, (byte)0x23, (byte)0x01); + assertEquals(r, (byte)0x23, "success compareAndExchange byte"); byte x = UNSAFE.getByte(base, offset); - assertEquals(x, (byte)0x01, "success compareAndExchangeVolatile byte value"); + assertEquals(x, (byte)0x01, "success compareAndExchange byte value"); } { - byte r = UNSAFE.compareAndExchangeByteVolatile(base, offset, (byte)0x23, (byte)0x45); - assertEquals(r, (byte)0x01, "failing compareAndExchangeVolatile byte"); + byte r = UNSAFE.compareAndExchangeByte(base, offset, (byte)0x23, (byte)0x45); + assertEquals(r, (byte)0x01, "failing compareAndExchange byte"); byte x = UNSAFE.getByte(base, offset); - assertEquals(x, (byte)0x01, "failing compareAndExchangeVolatile byte value"); + assertEquals(x, (byte)0x01, "failing compareAndExchange byte value"); } { @@ -239,41 +239,41 @@ public class JdkInternalMiscUnsafeAccessTestByte { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapByte(base, offset, (byte)0x01, (byte)0x23); + success = UNSAFE.weakCompareAndSetBytePlain(base, offset, (byte)0x01, (byte)0x23); } - assertEquals(success, true, "weakCompareAndSwap byte"); + assertEquals(success, true, "weakCompareAndSetPlain byte"); byte x = UNSAFE.getByte(base, offset); - assertEquals(x, (byte)0x23, "weakCompareAndSwap byte value"); + assertEquals(x, (byte)0x23, "weakCompareAndSetPlain byte value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapByteAcquire(base, offset, (byte)0x23, (byte)0x01); + success = UNSAFE.weakCompareAndSetByteAcquire(base, offset, (byte)0x23, (byte)0x01); } - assertEquals(success, true, "weakCompareAndSwapAcquire byte"); + assertEquals(success, true, "weakCompareAndSetAcquire byte"); byte x = UNSAFE.getByte(base, offset); - assertEquals(x, (byte)0x01, "weakCompareAndSwapAcquire byte"); + assertEquals(x, (byte)0x01, "weakCompareAndSetAcquire byte"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapByteRelease(base, offset, (byte)0x01, (byte)0x23); + success = UNSAFE.weakCompareAndSetByteRelease(base, offset, (byte)0x01, (byte)0x23); } - assertEquals(success, true, "weakCompareAndSwapRelease byte"); + assertEquals(success, true, "weakCompareAndSetRelease byte"); byte x = UNSAFE.getByte(base, offset); - assertEquals(x, (byte)0x23, "weakCompareAndSwapRelease byte"); + assertEquals(x, (byte)0x23, "weakCompareAndSetRelease byte"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapByteVolatile(base, offset, (byte)0x23, (byte)0x01); + success = UNSAFE.weakCompareAndSetByte(base, offset, (byte)0x23, (byte)0x01); } - assertEquals(success, true, "weakCompareAndSwapVolatile byte"); + assertEquals(success, true, "weakCompareAndSet byte"); byte x = UNSAFE.getByte(base, offset); - assertEquals(x, (byte)0x01, "weakCompareAndSwapVolatile byte"); + assertEquals(x, (byte)0x01, "weakCompareAndSet byte"); } UNSAFE.putByte(base, offset, (byte)0x23); @@ -306,4 +306,3 @@ public class JdkInternalMiscUnsafeAccessTestByte { } } } - diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestChar.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestChar.java index 0bb36c898bc..817af4b18c1 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestChar.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestChar.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -198,32 +198,32 @@ public class JdkInternalMiscUnsafeAccessTestChar { // Compare { - boolean r = UNSAFE.compareAndSwapChar(base, offset, '\u0123', '\u4567'); - assertEquals(r, true, "success compareAndSwap char"); + boolean r = UNSAFE.compareAndSetChar(base, offset, '\u0123', '\u4567'); + assertEquals(r, true, "success compareAndSet char"); char x = UNSAFE.getChar(base, offset); - assertEquals(x, '\u4567', "success compareAndSwap char value"); + assertEquals(x, '\u4567', "success compareAndSet char value"); } { - boolean r = UNSAFE.compareAndSwapChar(base, offset, '\u0123', '\u89AB'); - assertEquals(r, false, "failing compareAndSwap char"); + boolean r = UNSAFE.compareAndSetChar(base, offset, '\u0123', '\u89AB'); + assertEquals(r, false, "failing compareAndSet char"); char x = UNSAFE.getChar(base, offset); - assertEquals(x, '\u4567', "failing compareAndSwap char value"); + assertEquals(x, '\u4567', "failing compareAndSet char value"); } // Advanced compare { - char r = UNSAFE.compareAndExchangeCharVolatile(base, offset, '\u4567', '\u0123'); - assertEquals(r, '\u4567', "success compareAndExchangeVolatile char"); + char r = UNSAFE.compareAndExchangeChar(base, offset, '\u4567', '\u0123'); + assertEquals(r, '\u4567', "success compareAndExchange char"); char x = UNSAFE.getChar(base, offset); - assertEquals(x, '\u0123', "success compareAndExchangeVolatile char value"); + assertEquals(x, '\u0123', "success compareAndExchange char value"); } { - char r = UNSAFE.compareAndExchangeCharVolatile(base, offset, '\u4567', '\u89AB'); - assertEquals(r, '\u0123', "failing compareAndExchangeVolatile char"); + char r = UNSAFE.compareAndExchangeChar(base, offset, '\u4567', '\u89AB'); + assertEquals(r, '\u0123', "failing compareAndExchange char"); char x = UNSAFE.getChar(base, offset); - assertEquals(x, '\u0123', "failing compareAndExchangeVolatile char value"); + assertEquals(x, '\u0123', "failing compareAndExchange char value"); } { @@ -257,41 +257,41 @@ public class JdkInternalMiscUnsafeAccessTestChar { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapChar(base, offset, '\u0123', '\u4567'); + success = UNSAFE.weakCompareAndSetCharPlain(base, offset, '\u0123', '\u4567'); } - assertEquals(success, true, "weakCompareAndSwap char"); + assertEquals(success, true, "weakCompareAndSetPlain char"); char x = UNSAFE.getChar(base, offset); - assertEquals(x, '\u4567', "weakCompareAndSwap char value"); + assertEquals(x, '\u4567', "weakCompareAndSetPlain char value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapCharAcquire(base, offset, '\u4567', '\u0123'); + success = UNSAFE.weakCompareAndSetCharAcquire(base, offset, '\u4567', '\u0123'); } - assertEquals(success, true, "weakCompareAndSwapAcquire char"); + assertEquals(success, true, "weakCompareAndSetAcquire char"); char x = UNSAFE.getChar(base, offset); - assertEquals(x, '\u0123', "weakCompareAndSwapAcquire char"); + assertEquals(x, '\u0123', "weakCompareAndSetAcquire char"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapCharRelease(base, offset, '\u0123', '\u4567'); + success = UNSAFE.weakCompareAndSetCharRelease(base, offset, '\u0123', '\u4567'); } - assertEquals(success, true, "weakCompareAndSwapRelease char"); + assertEquals(success, true, "weakCompareAndSetRelease char"); char x = UNSAFE.getChar(base, offset); - assertEquals(x, '\u4567', "weakCompareAndSwapRelease char"); + assertEquals(x, '\u4567', "weakCompareAndSetRelease char"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapCharVolatile(base, offset, '\u4567', '\u0123'); + success = UNSAFE.weakCompareAndSetChar(base, offset, '\u4567', '\u0123'); } - assertEquals(success, true, "weakCompareAndSwapVolatile char"); + assertEquals(success, true, "weakCompareAndSet char"); char x = UNSAFE.getChar(base, offset); - assertEquals(x, '\u0123', "weakCompareAndSwapVolatile char"); + assertEquals(x, '\u0123', "weakCompareAndSet char"); } UNSAFE.putChar(base, offset, '\u4567'); @@ -324,4 +324,3 @@ public class JdkInternalMiscUnsafeAccessTestChar { } } } - diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestDouble.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestDouble.java index 48a98c619fd..37c15e57a6a 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestDouble.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestDouble.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -180,32 +180,32 @@ public class JdkInternalMiscUnsafeAccessTestDouble { // Compare { - boolean r = UNSAFE.compareAndSwapDouble(base, offset, 1.0d, 2.0d); - assertEquals(r, true, "success compareAndSwap double"); + boolean r = UNSAFE.compareAndSetDouble(base, offset, 1.0d, 2.0d); + assertEquals(r, true, "success compareAndSet double"); double x = UNSAFE.getDouble(base, offset); - assertEquals(x, 2.0d, "success compareAndSwap double value"); + assertEquals(x, 2.0d, "success compareAndSet double value"); } { - boolean r = UNSAFE.compareAndSwapDouble(base, offset, 1.0d, 3.0d); - assertEquals(r, false, "failing compareAndSwap double"); + boolean r = UNSAFE.compareAndSetDouble(base, offset, 1.0d, 3.0d); + assertEquals(r, false, "failing compareAndSet double"); double x = UNSAFE.getDouble(base, offset); - assertEquals(x, 2.0d, "failing compareAndSwap double value"); + assertEquals(x, 2.0d, "failing compareAndSet double value"); } // Advanced compare { - double r = UNSAFE.compareAndExchangeDoubleVolatile(base, offset, 2.0d, 1.0d); - assertEquals(r, 2.0d, "success compareAndExchangeVolatile double"); + double r = UNSAFE.compareAndExchangeDouble(base, offset, 2.0d, 1.0d); + assertEquals(r, 2.0d, "success compareAndExchange double"); double x = UNSAFE.getDouble(base, offset); - assertEquals(x, 1.0d, "success compareAndExchangeVolatile double value"); + assertEquals(x, 1.0d, "success compareAndExchange double value"); } { - double r = UNSAFE.compareAndExchangeDoubleVolatile(base, offset, 2.0d, 3.0d); - assertEquals(r, 1.0d, "failing compareAndExchangeVolatile double"); + double r = UNSAFE.compareAndExchangeDouble(base, offset, 2.0d, 3.0d); + assertEquals(r, 1.0d, "failing compareAndExchange double"); double x = UNSAFE.getDouble(base, offset); - assertEquals(x, 1.0d, "failing compareAndExchangeVolatile double value"); + assertEquals(x, 1.0d, "failing compareAndExchange double value"); } { @@ -239,41 +239,41 @@ public class JdkInternalMiscUnsafeAccessTestDouble { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapDouble(base, offset, 1.0d, 2.0d); + success = UNSAFE.weakCompareAndSetDoublePlain(base, offset, 1.0d, 2.0d); } - assertEquals(success, true, "weakCompareAndSwap double"); + assertEquals(success, true, "weakCompareAndSetPlain double"); double x = UNSAFE.getDouble(base, offset); - assertEquals(x, 2.0d, "weakCompareAndSwap double value"); + assertEquals(x, 2.0d, "weakCompareAndSetPlain double value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapDoubleAcquire(base, offset, 2.0d, 1.0d); + success = UNSAFE.weakCompareAndSetDoubleAcquire(base, offset, 2.0d, 1.0d); } - assertEquals(success, true, "weakCompareAndSwapAcquire double"); + assertEquals(success, true, "weakCompareAndSetAcquire double"); double x = UNSAFE.getDouble(base, offset); - assertEquals(x, 1.0d, "weakCompareAndSwapAcquire double"); + assertEquals(x, 1.0d, "weakCompareAndSetAcquire double"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapDoubleRelease(base, offset, 1.0d, 2.0d); + success = UNSAFE.weakCompareAndSetDoubleRelease(base, offset, 1.0d, 2.0d); } - assertEquals(success, true, "weakCompareAndSwapRelease double"); + assertEquals(success, true, "weakCompareAndSetRelease double"); double x = UNSAFE.getDouble(base, offset); - assertEquals(x, 2.0d, "weakCompareAndSwapRelease double"); + assertEquals(x, 2.0d, "weakCompareAndSetRelease double"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapDoubleVolatile(base, offset, 2.0d, 1.0d); + success = UNSAFE.weakCompareAndSetDouble(base, offset, 2.0d, 1.0d); } - assertEquals(success, true, "weakCompareAndSwapVolatile double"); + assertEquals(success, true, "weakCompareAndSet double"); double x = UNSAFE.getDouble(base, offset); - assertEquals(x, 1.0d, "weakCompareAndSwapVolatile double"); + assertEquals(x, 1.0d, "weakCompareAndSet double"); } UNSAFE.putDouble(base, offset, 2.0d); @@ -306,4 +306,3 @@ public class JdkInternalMiscUnsafeAccessTestDouble { } } } - diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestFloat.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestFloat.java index 2a91a7c20c3..0ac9fa1e55a 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestFloat.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestFloat.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -180,32 +180,32 @@ public class JdkInternalMiscUnsafeAccessTestFloat { // Compare { - boolean r = UNSAFE.compareAndSwapFloat(base, offset, 1.0f, 2.0f); - assertEquals(r, true, "success compareAndSwap float"); + boolean r = UNSAFE.compareAndSetFloat(base, offset, 1.0f, 2.0f); + assertEquals(r, true, "success compareAndSet float"); float x = UNSAFE.getFloat(base, offset); - assertEquals(x, 2.0f, "success compareAndSwap float value"); + assertEquals(x, 2.0f, "success compareAndSet float value"); } { - boolean r = UNSAFE.compareAndSwapFloat(base, offset, 1.0f, 3.0f); - assertEquals(r, false, "failing compareAndSwap float"); + boolean r = UNSAFE.compareAndSetFloat(base, offset, 1.0f, 3.0f); + assertEquals(r, false, "failing compareAndSet float"); float x = UNSAFE.getFloat(base, offset); - assertEquals(x, 2.0f, "failing compareAndSwap float value"); + assertEquals(x, 2.0f, "failing compareAndSet float value"); } // Advanced compare { - float r = UNSAFE.compareAndExchangeFloatVolatile(base, offset, 2.0f, 1.0f); - assertEquals(r, 2.0f, "success compareAndExchangeVolatile float"); + float r = UNSAFE.compareAndExchangeFloat(base, offset, 2.0f, 1.0f); + assertEquals(r, 2.0f, "success compareAndExchange float"); float x = UNSAFE.getFloat(base, offset); - assertEquals(x, 1.0f, "success compareAndExchangeVolatile float value"); + assertEquals(x, 1.0f, "success compareAndExchange float value"); } { - float r = UNSAFE.compareAndExchangeFloatVolatile(base, offset, 2.0f, 3.0f); - assertEquals(r, 1.0f, "failing compareAndExchangeVolatile float"); + float r = UNSAFE.compareAndExchangeFloat(base, offset, 2.0f, 3.0f); + assertEquals(r, 1.0f, "failing compareAndExchange float"); float x = UNSAFE.getFloat(base, offset); - assertEquals(x, 1.0f, "failing compareAndExchangeVolatile float value"); + assertEquals(x, 1.0f, "failing compareAndExchange float value"); } { @@ -239,41 +239,41 @@ public class JdkInternalMiscUnsafeAccessTestFloat { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapFloat(base, offset, 1.0f, 2.0f); + success = UNSAFE.weakCompareAndSetFloatPlain(base, offset, 1.0f, 2.0f); } - assertEquals(success, true, "weakCompareAndSwap float"); + assertEquals(success, true, "weakCompareAndSetPlain float"); float x = UNSAFE.getFloat(base, offset); - assertEquals(x, 2.0f, "weakCompareAndSwap float value"); + assertEquals(x, 2.0f, "weakCompareAndSetPlain float value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapFloatAcquire(base, offset, 2.0f, 1.0f); + success = UNSAFE.weakCompareAndSetFloatAcquire(base, offset, 2.0f, 1.0f); } - assertEquals(success, true, "weakCompareAndSwapAcquire float"); + assertEquals(success, true, "weakCompareAndSetAcquire float"); float x = UNSAFE.getFloat(base, offset); - assertEquals(x, 1.0f, "weakCompareAndSwapAcquire float"); + assertEquals(x, 1.0f, "weakCompareAndSetAcquire float"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapFloatRelease(base, offset, 1.0f, 2.0f); + success = UNSAFE.weakCompareAndSetFloatRelease(base, offset, 1.0f, 2.0f); } - assertEquals(success, true, "weakCompareAndSwapRelease float"); + assertEquals(success, true, "weakCompareAndSetRelease float"); float x = UNSAFE.getFloat(base, offset); - assertEquals(x, 2.0f, "weakCompareAndSwapRelease float"); + assertEquals(x, 2.0f, "weakCompareAndSetRelease float"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapFloatVolatile(base, offset, 2.0f, 1.0f); + success = UNSAFE.weakCompareAndSetFloat(base, offset, 2.0f, 1.0f); } - assertEquals(success, true, "weakCompareAndSwapVolatile float"); + assertEquals(success, true, "weakCompareAndSet float"); float x = UNSAFE.getFloat(base, offset); - assertEquals(x, 1.0f, "weakCompareAndSwapVolatile float"); + assertEquals(x, 1.0f, "weakCompareAndSet float"); } UNSAFE.putFloat(base, offset, 2.0f); @@ -306,4 +306,3 @@ public class JdkInternalMiscUnsafeAccessTestFloat { } } } - diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestInt.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestInt.java index b55e3672427..0f0f1f101d3 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestInt.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestInt.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -198,32 +198,32 @@ public class JdkInternalMiscUnsafeAccessTestInt { // Compare { - boolean r = UNSAFE.compareAndSwapInt(base, offset, 0x01234567, 0x89ABCDEF); - assertEquals(r, true, "success compareAndSwap int"); + boolean r = UNSAFE.compareAndSetInt(base, offset, 0x01234567, 0x89ABCDEF); + assertEquals(r, true, "success compareAndSet int"); int x = UNSAFE.getInt(base, offset); - assertEquals(x, 0x89ABCDEF, "success compareAndSwap int value"); + assertEquals(x, 0x89ABCDEF, "success compareAndSet int value"); } { - boolean r = UNSAFE.compareAndSwapInt(base, offset, 0x01234567, 0xCAFEBABE); - assertEquals(r, false, "failing compareAndSwap int"); + boolean r = UNSAFE.compareAndSetInt(base, offset, 0x01234567, 0xCAFEBABE); + assertEquals(r, false, "failing compareAndSet int"); int x = UNSAFE.getInt(base, offset); - assertEquals(x, 0x89ABCDEF, "failing compareAndSwap int value"); + assertEquals(x, 0x89ABCDEF, "failing compareAndSet int value"); } // Advanced compare { - int r = UNSAFE.compareAndExchangeIntVolatile(base, offset, 0x89ABCDEF, 0x01234567); - assertEquals(r, 0x89ABCDEF, "success compareAndExchangeVolatile int"); + int r = UNSAFE.compareAndExchangeInt(base, offset, 0x89ABCDEF, 0x01234567); + assertEquals(r, 0x89ABCDEF, "success compareAndExchange int"); int x = UNSAFE.getInt(base, offset); - assertEquals(x, 0x01234567, "success compareAndExchangeVolatile int value"); + assertEquals(x, 0x01234567, "success compareAndExchange int value"); } { - int r = UNSAFE.compareAndExchangeIntVolatile(base, offset, 0x89ABCDEF, 0xCAFEBABE); - assertEquals(r, 0x01234567, "failing compareAndExchangeVolatile int"); + int r = UNSAFE.compareAndExchangeInt(base, offset, 0x89ABCDEF, 0xCAFEBABE); + assertEquals(r, 0x01234567, "failing compareAndExchange int"); int x = UNSAFE.getInt(base, offset); - assertEquals(x, 0x01234567, "failing compareAndExchangeVolatile int value"); + assertEquals(x, 0x01234567, "failing compareAndExchange int value"); } { @@ -257,41 +257,41 @@ public class JdkInternalMiscUnsafeAccessTestInt { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapInt(base, offset, 0x01234567, 0x89ABCDEF); + success = UNSAFE.weakCompareAndSetIntPlain(base, offset, 0x01234567, 0x89ABCDEF); } - assertEquals(success, true, "weakCompareAndSwap int"); + assertEquals(success, true, "weakCompareAndSetPlain int"); int x = UNSAFE.getInt(base, offset); - assertEquals(x, 0x89ABCDEF, "weakCompareAndSwap int value"); + assertEquals(x, 0x89ABCDEF, "weakCompareAndSetPlain int value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapIntAcquire(base, offset, 0x89ABCDEF, 0x01234567); + success = UNSAFE.weakCompareAndSetIntAcquire(base, offset, 0x89ABCDEF, 0x01234567); } - assertEquals(success, true, "weakCompareAndSwapAcquire int"); + assertEquals(success, true, "weakCompareAndSetAcquire int"); int x = UNSAFE.getInt(base, offset); - assertEquals(x, 0x01234567, "weakCompareAndSwapAcquire int"); + assertEquals(x, 0x01234567, "weakCompareAndSetAcquire int"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapIntRelease(base, offset, 0x01234567, 0x89ABCDEF); + success = UNSAFE.weakCompareAndSetIntRelease(base, offset, 0x01234567, 0x89ABCDEF); } - assertEquals(success, true, "weakCompareAndSwapRelease int"); + assertEquals(success, true, "weakCompareAndSetRelease int"); int x = UNSAFE.getInt(base, offset); - assertEquals(x, 0x89ABCDEF, "weakCompareAndSwapRelease int"); + assertEquals(x, 0x89ABCDEF, "weakCompareAndSetRelease int"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapIntVolatile(base, offset, 0x89ABCDEF, 0x01234567); + success = UNSAFE.weakCompareAndSetInt(base, offset, 0x89ABCDEF, 0x01234567); } - assertEquals(success, true, "weakCompareAndSwapVolatile int"); + assertEquals(success, true, "weakCompareAndSet int"); int x = UNSAFE.getInt(base, offset); - assertEquals(x, 0x01234567, "weakCompareAndSwapVolatile int"); + assertEquals(x, 0x01234567, "weakCompareAndSet int"); } UNSAFE.putInt(base, offset, 0x89ABCDEF); @@ -324,4 +324,3 @@ public class JdkInternalMiscUnsafeAccessTestInt { } } } - diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestLong.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestLong.java index fc78b375071..69a51bb698b 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestLong.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestLong.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -198,32 +198,32 @@ public class JdkInternalMiscUnsafeAccessTestLong { // Compare { - boolean r = UNSAFE.compareAndSwapLong(base, offset, 0x0123456789ABCDEFL, 0xCAFEBABECAFEBABEL); - assertEquals(r, true, "success compareAndSwap long"); + boolean r = UNSAFE.compareAndSetLong(base, offset, 0x0123456789ABCDEFL, 0xCAFEBABECAFEBABEL); + assertEquals(r, true, "success compareAndSet long"); long x = UNSAFE.getLong(base, offset); - assertEquals(x, 0xCAFEBABECAFEBABEL, "success compareAndSwap long value"); + assertEquals(x, 0xCAFEBABECAFEBABEL, "success compareAndSet long value"); } { - boolean r = UNSAFE.compareAndSwapLong(base, offset, 0x0123456789ABCDEFL, 0xDEADBEEFDEADBEEFL); - assertEquals(r, false, "failing compareAndSwap long"); + boolean r = UNSAFE.compareAndSetLong(base, offset, 0x0123456789ABCDEFL, 0xDEADBEEFDEADBEEFL); + assertEquals(r, false, "failing compareAndSet long"); long x = UNSAFE.getLong(base, offset); - assertEquals(x, 0xCAFEBABECAFEBABEL, "failing compareAndSwap long value"); + assertEquals(x, 0xCAFEBABECAFEBABEL, "failing compareAndSet long value"); } // Advanced compare { - long r = UNSAFE.compareAndExchangeLongVolatile(base, offset, 0xCAFEBABECAFEBABEL, 0x0123456789ABCDEFL); - assertEquals(r, 0xCAFEBABECAFEBABEL, "success compareAndExchangeVolatile long"); + long r = UNSAFE.compareAndExchangeLong(base, offset, 0xCAFEBABECAFEBABEL, 0x0123456789ABCDEFL); + assertEquals(r, 0xCAFEBABECAFEBABEL, "success compareAndExchange long"); long x = UNSAFE.getLong(base, offset); - assertEquals(x, 0x0123456789ABCDEFL, "success compareAndExchangeVolatile long value"); + assertEquals(x, 0x0123456789ABCDEFL, "success compareAndExchange long value"); } { - long r = UNSAFE.compareAndExchangeLongVolatile(base, offset, 0xCAFEBABECAFEBABEL, 0xDEADBEEFDEADBEEFL); - assertEquals(r, 0x0123456789ABCDEFL, "failing compareAndExchangeVolatile long"); + long r = UNSAFE.compareAndExchangeLong(base, offset, 0xCAFEBABECAFEBABEL, 0xDEADBEEFDEADBEEFL); + assertEquals(r, 0x0123456789ABCDEFL, "failing compareAndExchange long"); long x = UNSAFE.getLong(base, offset); - assertEquals(x, 0x0123456789ABCDEFL, "failing compareAndExchangeVolatile long value"); + assertEquals(x, 0x0123456789ABCDEFL, "failing compareAndExchange long value"); } { @@ -257,41 +257,41 @@ public class JdkInternalMiscUnsafeAccessTestLong { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapLong(base, offset, 0x0123456789ABCDEFL, 0xCAFEBABECAFEBABEL); + success = UNSAFE.weakCompareAndSetLongPlain(base, offset, 0x0123456789ABCDEFL, 0xCAFEBABECAFEBABEL); } - assertEquals(success, true, "weakCompareAndSwap long"); + assertEquals(success, true, "weakCompareAndSetPlain long"); long x = UNSAFE.getLong(base, offset); - assertEquals(x, 0xCAFEBABECAFEBABEL, "weakCompareAndSwap long value"); + assertEquals(x, 0xCAFEBABECAFEBABEL, "weakCompareAndSetPlain long value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapLongAcquire(base, offset, 0xCAFEBABECAFEBABEL, 0x0123456789ABCDEFL); + success = UNSAFE.weakCompareAndSetLongAcquire(base, offset, 0xCAFEBABECAFEBABEL, 0x0123456789ABCDEFL); } - assertEquals(success, true, "weakCompareAndSwapAcquire long"); + assertEquals(success, true, "weakCompareAndSetAcquire long"); long x = UNSAFE.getLong(base, offset); - assertEquals(x, 0x0123456789ABCDEFL, "weakCompareAndSwapAcquire long"); + assertEquals(x, 0x0123456789ABCDEFL, "weakCompareAndSetAcquire long"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapLongRelease(base, offset, 0x0123456789ABCDEFL, 0xCAFEBABECAFEBABEL); + success = UNSAFE.weakCompareAndSetLongRelease(base, offset, 0x0123456789ABCDEFL, 0xCAFEBABECAFEBABEL); } - assertEquals(success, true, "weakCompareAndSwapRelease long"); + assertEquals(success, true, "weakCompareAndSetRelease long"); long x = UNSAFE.getLong(base, offset); - assertEquals(x, 0xCAFEBABECAFEBABEL, "weakCompareAndSwapRelease long"); + assertEquals(x, 0xCAFEBABECAFEBABEL, "weakCompareAndSetRelease long"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapLongVolatile(base, offset, 0xCAFEBABECAFEBABEL, 0x0123456789ABCDEFL); + success = UNSAFE.weakCompareAndSetLong(base, offset, 0xCAFEBABECAFEBABEL, 0x0123456789ABCDEFL); } - assertEquals(success, true, "weakCompareAndSwapVolatile long"); + assertEquals(success, true, "weakCompareAndSet long"); long x = UNSAFE.getLong(base, offset); - assertEquals(x, 0x0123456789ABCDEFL, "weakCompareAndSwapVolatile long"); + assertEquals(x, 0x0123456789ABCDEFL, "weakCompareAndSet long"); } UNSAFE.putLong(base, offset, 0xCAFEBABECAFEBABEL); @@ -324,4 +324,3 @@ public class JdkInternalMiscUnsafeAccessTestLong { } } } - diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestObject.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestObject.java index 039b472ccf7..b2e5fc57e1e 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestObject.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestObject.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -151,32 +151,32 @@ public class JdkInternalMiscUnsafeAccessTestObject { // Compare { - boolean r = UNSAFE.compareAndSwapObject(base, offset, "foo", "bar"); - assertEquals(r, true, "success compareAndSwap Object"); + boolean r = UNSAFE.compareAndSetObject(base, offset, "foo", "bar"); + assertEquals(r, true, "success compareAndSet Object"); Object x = UNSAFE.getObject(base, offset); - assertEquals(x, "bar", "success compareAndSwap Object value"); + assertEquals(x, "bar", "success compareAndSet Object value"); } { - boolean r = UNSAFE.compareAndSwapObject(base, offset, "foo", "baz"); - assertEquals(r, false, "failing compareAndSwap Object"); + boolean r = UNSAFE.compareAndSetObject(base, offset, "foo", "baz"); + assertEquals(r, false, "failing compareAndSet Object"); Object x = UNSAFE.getObject(base, offset); - assertEquals(x, "bar", "failing compareAndSwap Object value"); + assertEquals(x, "bar", "failing compareAndSet Object value"); } // Advanced compare { - Object r = UNSAFE.compareAndExchangeObjectVolatile(base, offset, "bar", "foo"); - assertEquals(r, "bar", "success compareAndExchangeVolatile Object"); + Object r = UNSAFE.compareAndExchangeObject(base, offset, "bar", "foo"); + assertEquals(r, "bar", "success compareAndExchange Object"); Object x = UNSAFE.getObject(base, offset); - assertEquals(x, "foo", "success compareAndExchangeVolatile Object value"); + assertEquals(x, "foo", "success compareAndExchange Object value"); } { - Object r = UNSAFE.compareAndExchangeObjectVolatile(base, offset, "bar", "baz"); - assertEquals(r, "foo", "failing compareAndExchangeVolatile Object"); + Object r = UNSAFE.compareAndExchangeObject(base, offset, "bar", "baz"); + assertEquals(r, "foo", "failing compareAndExchange Object"); Object x = UNSAFE.getObject(base, offset); - assertEquals(x, "foo", "failing compareAndExchangeVolatile Object value"); + assertEquals(x, "foo", "failing compareAndExchange Object value"); } { @@ -210,41 +210,41 @@ public class JdkInternalMiscUnsafeAccessTestObject { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapObject(base, offset, "foo", "bar"); + success = UNSAFE.weakCompareAndSetObjectPlain(base, offset, "foo", "bar"); } - assertEquals(success, true, "weakCompareAndSwap Object"); + assertEquals(success, true, "weakCompareAndSetPlain Object"); Object x = UNSAFE.getObject(base, offset); - assertEquals(x, "bar", "weakCompareAndSwap Object value"); + assertEquals(x, "bar", "weakCompareAndSetPlain Object value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapObjectAcquire(base, offset, "bar", "foo"); + success = UNSAFE.weakCompareAndSetObjectAcquire(base, offset, "bar", "foo"); } - assertEquals(success, true, "weakCompareAndSwapAcquire Object"); + assertEquals(success, true, "weakCompareAndSetAcquire Object"); Object x = UNSAFE.getObject(base, offset); - assertEquals(x, "foo", "weakCompareAndSwapAcquire Object"); + assertEquals(x, "foo", "weakCompareAndSetAcquire Object"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapObjectRelease(base, offset, "foo", "bar"); + success = UNSAFE.weakCompareAndSetObjectRelease(base, offset, "foo", "bar"); } - assertEquals(success, true, "weakCompareAndSwapRelease Object"); + assertEquals(success, true, "weakCompareAndSetRelease Object"); Object x = UNSAFE.getObject(base, offset); - assertEquals(x, "bar", "weakCompareAndSwapRelease Object"); + assertEquals(x, "bar", "weakCompareAndSetRelease Object"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapObjectVolatile(base, offset, "bar", "foo"); + success = UNSAFE.weakCompareAndSetObject(base, offset, "bar", "foo"); } - assertEquals(success, true, "weakCompareAndSwapVolatile Object"); + assertEquals(success, true, "weakCompareAndSet Object"); Object x = UNSAFE.getObject(base, offset); - assertEquals(x, "foo", "weakCompareAndSwapVolatile Object"); + assertEquals(x, "foo", "weakCompareAndSet Object"); } UNSAFE.putObject(base, offset, "bar"); @@ -260,4 +260,3 @@ public class JdkInternalMiscUnsafeAccessTestObject { } } - diff --git a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestShort.java b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestShort.java index f854979c73f..a6b845eec6b 100644 --- a/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestShort.java +++ b/hotspot/test/compiler/unsafe/JdkInternalMiscUnsafeAccessTestShort.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -198,32 +198,32 @@ public class JdkInternalMiscUnsafeAccessTestShort { // Compare { - boolean r = UNSAFE.compareAndSwapShort(base, offset, (short)0x0123, (short)0x4567); - assertEquals(r, true, "success compareAndSwap short"); + boolean r = UNSAFE.compareAndSetShort(base, offset, (short)0x0123, (short)0x4567); + assertEquals(r, true, "success compareAndSet short"); short x = UNSAFE.getShort(base, offset); - assertEquals(x, (short)0x4567, "success compareAndSwap short value"); + assertEquals(x, (short)0x4567, "success compareAndSet short value"); } { - boolean r = UNSAFE.compareAndSwapShort(base, offset, (short)0x0123, (short)0x89AB); - assertEquals(r, false, "failing compareAndSwap short"); + boolean r = UNSAFE.compareAndSetShort(base, offset, (short)0x0123, (short)0x89AB); + assertEquals(r, false, "failing compareAndSet short"); short x = UNSAFE.getShort(base, offset); - assertEquals(x, (short)0x4567, "failing compareAndSwap short value"); + assertEquals(x, (short)0x4567, "failing compareAndSet short value"); } // Advanced compare { - short r = UNSAFE.compareAndExchangeShortVolatile(base, offset, (short)0x4567, (short)0x0123); - assertEquals(r, (short)0x4567, "success compareAndExchangeVolatile short"); + short r = UNSAFE.compareAndExchangeShort(base, offset, (short)0x4567, (short)0x0123); + assertEquals(r, (short)0x4567, "success compareAndExchange short"); short x = UNSAFE.getShort(base, offset); - assertEquals(x, (short)0x0123, "success compareAndExchangeVolatile short value"); + assertEquals(x, (short)0x0123, "success compareAndExchange short value"); } { - short r = UNSAFE.compareAndExchangeShortVolatile(base, offset, (short)0x4567, (short)0x89AB); - assertEquals(r, (short)0x0123, "failing compareAndExchangeVolatile short"); + short r = UNSAFE.compareAndExchangeShort(base, offset, (short)0x4567, (short)0x89AB); + assertEquals(r, (short)0x0123, "failing compareAndExchange short"); short x = UNSAFE.getShort(base, offset); - assertEquals(x, (short)0x0123, "failing compareAndExchangeVolatile short value"); + assertEquals(x, (short)0x0123, "failing compareAndExchange short value"); } { @@ -257,41 +257,41 @@ public class JdkInternalMiscUnsafeAccessTestShort { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapShort(base, offset, (short)0x0123, (short)0x4567); + success = UNSAFE.weakCompareAndSetShortPlain(base, offset, (short)0x0123, (short)0x4567); } - assertEquals(success, true, "weakCompareAndSwap short"); + assertEquals(success, true, "weakCompareAndSetPlain short"); short x = UNSAFE.getShort(base, offset); - assertEquals(x, (short)0x4567, "weakCompareAndSwap short value"); + assertEquals(x, (short)0x4567, "weakCompareAndSetPlain short value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapShortAcquire(base, offset, (short)0x4567, (short)0x0123); + success = UNSAFE.weakCompareAndSetShortAcquire(base, offset, (short)0x4567, (short)0x0123); } - assertEquals(success, true, "weakCompareAndSwapAcquire short"); + assertEquals(success, true, "weakCompareAndSetAcquire short"); short x = UNSAFE.getShort(base, offset); - assertEquals(x, (short)0x0123, "weakCompareAndSwapAcquire short"); + assertEquals(x, (short)0x0123, "weakCompareAndSetAcquire short"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapShortRelease(base, offset, (short)0x0123, (short)0x4567); + success = UNSAFE.weakCompareAndSetShortRelease(base, offset, (short)0x0123, (short)0x4567); } - assertEquals(success, true, "weakCompareAndSwapRelease short"); + assertEquals(success, true, "weakCompareAndSetRelease short"); short x = UNSAFE.getShort(base, offset); - assertEquals(x, (short)0x4567, "weakCompareAndSwapRelease short"); + assertEquals(x, (short)0x4567, "weakCompareAndSetRelease short"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwapShortVolatile(base, offset, (short)0x4567, (short)0x0123); + success = UNSAFE.weakCompareAndSetShort(base, offset, (short)0x4567, (short)0x0123); } - assertEquals(success, true, "weakCompareAndSwapVolatile short"); + assertEquals(success, true, "weakCompareAndSet short"); short x = UNSAFE.getShort(base, offset); - assertEquals(x, (short)0x0123, "weakCompareAndSwapVolatile short"); + assertEquals(x, (short)0x0123, "weakCompareAndSet short"); } UNSAFE.putShort(base, offset, (short)0x4567); @@ -324,4 +324,3 @@ public class JdkInternalMiscUnsafeAccessTestShort { } } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestBoolean.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestBoolean.java index 7200bf754c8..a1b68c7305d 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestBoolean.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestBoolean.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -138,4 +138,3 @@ public class SunMiscUnsafeAccessTestBoolean { } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestByte.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestByte.java index a30c01ff0f6..c086315cb8a 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestByte.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestByte.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -175,4 +175,3 @@ public class SunMiscUnsafeAccessTestByte { } } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestChar.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestChar.java index 12dbb25030b..3a55939826d 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestChar.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestChar.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -175,4 +175,3 @@ public class SunMiscUnsafeAccessTestChar { } } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestDouble.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestDouble.java index 5fedde71510..52bde3f08d6 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestDouble.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestDouble.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -175,4 +175,3 @@ public class SunMiscUnsafeAccessTestDouble { } } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestFloat.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestFloat.java index 621e4ae3863..478efa4dbc3 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestFloat.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestFloat.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -175,4 +175,3 @@ public class SunMiscUnsafeAccessTestFloat { } } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestInt.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestInt.java index 1e49aacb287..0bf8b641066 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestInt.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestInt.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -216,4 +216,3 @@ public class SunMiscUnsafeAccessTestInt { } } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestLong.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestLong.java index e484bcec291..64014df3340 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestLong.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestLong.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -216,4 +216,3 @@ public class SunMiscUnsafeAccessTestLong { } } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestObject.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestObject.java index 1241f0fbcd4..0145124c7bd 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestObject.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestObject.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -170,4 +170,3 @@ public class SunMiscUnsafeAccessTestObject { } } - diff --git a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestShort.java b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestShort.java index d1d7b632389..9a815670595 100644 --- a/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestShort.java +++ b/hotspot/test/compiler/unsafe/SunMiscUnsafeAccessTestShort.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -175,4 +175,3 @@ public class SunMiscUnsafeAccessTestShort { } } } - diff --git a/hotspot/test/compiler/unsafe/TestRawAliasing.java b/hotspot/test/compiler/unsafe/TestRawAliasing.java new file mode 100644 index 00000000000..c4042b81e2c --- /dev/null +++ b/hotspot/test/compiler/unsafe/TestRawAliasing.java @@ -0,0 +1,71 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8178047 + * @run main/othervm -XX:CompileCommand=exclude,*.main -XX:-TieredCompilation -XX:-BackgroundCompilation compiler.unsafe.TestRawAliasing + * @modules java.base/jdk.internal.misc:+open + */ + +package compiler.unsafe; + +import java.lang.reflect.Field; + +public class TestRawAliasing { + static private final jdk.internal.misc.Unsafe UNSAFE; + static { + try { + Field f = jdk.internal.misc.Unsafe.class.getDeclaredField("theUnsafe"); + f.setAccessible(true); + UNSAFE = (jdk.internal.misc.Unsafe) f.get(null); + } catch (Exception e) { + throw new RuntimeException("Unable to get Unsafe instance.", e); + } + } + + static private final int OFFSET_X = 50; + static private final int OFFSET_Y = 100; + + private static int test(long base_plus_offset_x, long base_plus_offset_y, int magic_value) { + // write 0 to a location + UNSAFE.putByte(base_plus_offset_x - OFFSET_X, (byte)0); + // write unfoldable value to really the same location with another base + UNSAFE.putByte(base_plus_offset_y - OFFSET_Y, (byte)magic_value); + // read the value back, should be equal to "unfoldable_value" + return UNSAFE.getByte(base_plus_offset_x - OFFSET_X); + } + + private static final int OFF_HEAP_AREA_SIZE = 128; + private static final byte MAGIC = 123; + + // main is excluded from compilation since we don't want the test method to inline and make base values fold + public static void main(String... args) { + long base = UNSAFE.allocateMemory(OFF_HEAP_AREA_SIZE); + for (int i = 0; i < 100_000; i++) { + if (test(base + OFFSET_X, base + OFFSET_Y, MAGIC) != MAGIC) { + throw new RuntimeException("Unexpected magic value"); + } + } + } +} diff --git a/hotspot/test/compiler/unsafe/X-UnsafeAccessTest.java.template b/hotspot/test/compiler/unsafe/X-UnsafeAccessTest.java.template index 55ed81fc059..f28791765a1 100644 --- a/hotspot/test/compiler/unsafe/X-UnsafeAccessTest.java.template +++ b/hotspot/test/compiler/unsafe/X-UnsafeAccessTest.java.template @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,11 @@ * @bug 8143628 * @summary Test unsafe access for $type$ * +#if[JdkInternalMisc] + * @modules $module$/$package$:+open +#else[JdkInternalMisc] * @modules $module$/$package$ +#end[JdkInternalMisc] * @run testng/othervm -Diters=100 -Xint compiler.unsafe.$Qualifier$UnsafeAccessTest$Type$ * @run testng/othervm -Diters=20000 -XX:TieredStopAtLevel=1 compiler.unsafe.$Qualifier$UnsafeAccessTest$Type$ * @run testng/othervm -Diters=20000 -XX:-TieredCompilation compiler.unsafe.$Qualifier$UnsafeAccessTest$Type$ @@ -219,33 +223,51 @@ public class $Qualifier$UnsafeAccessTest$Type$ { // Compare { +#if[JdkInternalMisc] + boolean r = UNSAFE.compareAndSet$Type$(base, offset, $value1$, $value2$); + assertEquals(r, true, "success compareAndSet $type$"); +#else[JdkInternalMisc] boolean r = UNSAFE.compareAndSwap$Type$(base, offset, $value1$, $value2$); assertEquals(r, true, "success compareAndSwap $type$"); +#end[JdkInternalMisc] $type$ x = UNSAFE.get$Type$(base, offset); +#if[JdkInternalMisc] + assertEquals(x, $value2$, "success compareAndSet $type$ value"); +#else[JdkInternalMisc] assertEquals(x, $value2$, "success compareAndSwap $type$ value"); +#end[JdkInternalMisc] } { +#if[JdkInternalMisc] + boolean r = UNSAFE.compareAndSet$Type$(base, offset, $value1$, $value3$); + assertEquals(r, false, "failing compareAndSet $type$"); +#else[JdkInternalMisc] boolean r = UNSAFE.compareAndSwap$Type$(base, offset, $value1$, $value3$); assertEquals(r, false, "failing compareAndSwap $type$"); +#end[JdkInternalMisc] $type$ x = UNSAFE.get$Type$(base, offset); +#if[JdkInternalMisc] + assertEquals(x, $value2$, "failing compareAndSet $type$ value"); +#else[JdkInternalMisc] assertEquals(x, $value2$, "failing compareAndSwap $type$ value"); +#end[JdkInternalMisc] } #if[JdkInternalMisc] // Advanced compare { - $type$ r = UNSAFE.compareAndExchange$Type$Volatile(base, offset, $value2$, $value1$); - assertEquals(r, $value2$, "success compareAndExchangeVolatile $type$"); + $type$ r = UNSAFE.compareAndExchange$Type$(base, offset, $value2$, $value1$); + assertEquals(r, $value2$, "success compareAndExchange $type$"); $type$ x = UNSAFE.get$Type$(base, offset); - assertEquals(x, $value1$, "success compareAndExchangeVolatile $type$ value"); + assertEquals(x, $value1$, "success compareAndExchange $type$ value"); } { - $type$ r = UNSAFE.compareAndExchange$Type$Volatile(base, offset, $value2$, $value3$); - assertEquals(r, $value1$, "failing compareAndExchangeVolatile $type$"); + $type$ r = UNSAFE.compareAndExchange$Type$(base, offset, $value2$, $value3$); + assertEquals(r, $value1$, "failing compareAndExchange $type$"); $type$ x = UNSAFE.get$Type$(base, offset); - assertEquals(x, $value1$, "failing compareAndExchangeVolatile $type$ value"); + assertEquals(x, $value1$, "failing compareAndExchange $type$ value"); } { @@ -279,41 +301,41 @@ public class $Qualifier$UnsafeAccessTest$Type$ { { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwap$Type$(base, offset, $value1$, $value2$); + success = UNSAFE.weakCompareAndSet$Type$Plain(base, offset, $value1$, $value2$); } - assertEquals(success, true, "weakCompareAndSwap $type$"); + assertEquals(success, true, "weakCompareAndSetPlain $type$"); $type$ x = UNSAFE.get$Type$(base, offset); - assertEquals(x, $value2$, "weakCompareAndSwap $type$ value"); + assertEquals(x, $value2$, "weakCompareAndSetPlain $type$ value"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwap$Type$Acquire(base, offset, $value2$, $value1$); + success = UNSAFE.weakCompareAndSet$Type$Acquire(base, offset, $value2$, $value1$); } - assertEquals(success, true, "weakCompareAndSwapAcquire $type$"); + assertEquals(success, true, "weakCompareAndSetAcquire $type$"); $type$ x = UNSAFE.get$Type$(base, offset); - assertEquals(x, $value1$, "weakCompareAndSwapAcquire $type$"); + assertEquals(x, $value1$, "weakCompareAndSetAcquire $type$"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwap$Type$Release(base, offset, $value1$, $value2$); + success = UNSAFE.weakCompareAndSet$Type$Release(base, offset, $value1$, $value2$); } - assertEquals(success, true, "weakCompareAndSwapRelease $type$"); + assertEquals(success, true, "weakCompareAndSetRelease $type$"); $type$ x = UNSAFE.get$Type$(base, offset); - assertEquals(x, $value2$, "weakCompareAndSwapRelease $type$"); + assertEquals(x, $value2$, "weakCompareAndSetRelease $type$"); } { boolean success = false; for (int c = 0; c < WEAK_ATTEMPTS && !success; c++) { - success = UNSAFE.weakCompareAndSwap$Type$Volatile(base, offset, $value2$, $value1$); + success = UNSAFE.weakCompareAndSet$Type$(base, offset, $value2$, $value1$); } - assertEquals(success, true, "weakCompareAndSwapVolatile $type$"); + assertEquals(success, true, "weakCompareAndSet $type$"); $type$ x = UNSAFE.get$Type$(base, offset); - assertEquals(x, $value1$, "weakCompareAndSwapVolatile $type$"); + assertEquals(x, $value1$, "weakCompareAndSet $type$"); } #end[JdkInternalMisc] @@ -354,4 +376,3 @@ public class $Qualifier$UnsafeAccessTest$Type$ { #end[!boolean] #end[!Object] } - diff --git a/hotspot/test/compiler/whitebox/AllocationCodeBlobTest.java b/hotspot/test/compiler/whitebox/AllocationCodeBlobTest.java index 0f323a8c52e..80d89d33de7 100644 --- a/hotspot/test/compiler/whitebox/AllocationCodeBlobTest.java +++ b/hotspot/test/compiler/whitebox/AllocationCodeBlobTest.java @@ -44,7 +44,7 @@ package compiler.whitebox; import jdk.test.lib.Asserts; -import jdk.test.lib.wrappers.InfiniteLoop; +import jdk.test.lib.InfiniteLoop; import sun.hotspot.WhiteBox; import sun.hotspot.code.BlobType; diff --git a/hotspot/test/gc/arguments/TestAggressiveHeap.java b/hotspot/test/gc/arguments/TestAggressiveHeap.java new file mode 100644 index 00000000000..417e98090ea --- /dev/null +++ b/hotspot/test/gc/arguments/TestAggressiveHeap.java @@ -0,0 +1,93 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test TestAggressiveHeap + * @key gc + * @bug 8179084 + * @requires vm.gc.Parallel + * @summary Test argument processing for -XX:+AggressiveHeap. + * @library /test/lib + * @modules java.base java.management + * @run driver TestAggressiveHeap + */ + +import java.lang.management.ManagementFactory; +import javax.management.MBeanServer; +import javax.management.ObjectName; + +import jdk.test.lib.process.OutputAnalyzer; +import jdk.test.lib.process.ProcessTools; + +public class TestAggressiveHeap { + + public static void main(String args[]) throws Exception { + if (canUseAggressiveHeapOption()) { + testFlag(); + } + } + + // Note: Not a normal boolean flag; -XX:-AggressiveHeap is invalid. + private static final String option = "-XX:+AggressiveHeap"; + + // Option requires at least 256M, else error during option processing. + private static final long minMemory = 256 * 1024 * 1024; + + // bool UseParallelGC = true {product} {command line} + private static final String parallelGCPattern = + " *bool +UseParallelGC *= *true +\\{product\\} *\\{command line\\}"; + + private static void testFlag() throws Exception { + ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( + option, "-XX:+PrintFlagsFinal", "-version"); + + OutputAnalyzer output = new OutputAnalyzer(pb.start()); + + output.shouldHaveExitValue(0); + + String value = output.firstMatch(parallelGCPattern); + if (value == null) { + throw new RuntimeException( + option + " didn't set UseParallelGC as if from command line"); + } + } + + private static boolean haveRequiredMemory() throws Exception { + MBeanServer server = ManagementFactory.getPlatformMBeanServer(); + ObjectName os = new ObjectName("java.lang", "type", "OperatingSystem"); + Object attr = server.getAttribute(os, "TotalPhysicalMemorySize"); + String value = attr.toString(); + long memory = Long.parseLong(value); + return memory >= minMemory; + } + + private static boolean canUseAggressiveHeapOption() throws Exception { + if (!haveRequiredMemory()) { + System.out.println( + "Skipping test of " + option + " : insufficient memory"); + return false; + } + return true; + } +} + diff --git a/hotspot/test/gc/arguments/TestDynMaxHeapFreeRatio.java b/hotspot/test/gc/arguments/TestDynMaxHeapFreeRatio.java index c6d2b547357..4b7fd30ab41 100644 --- a/hotspot/test/gc/arguments/TestDynMaxHeapFreeRatio.java +++ b/hotspot/test/gc/arguments/TestDynMaxHeapFreeRatio.java @@ -24,7 +24,7 @@ import static jdk.test.lib.Asserts.assertEQ; import static jdk.test.lib.Asserts.assertFalse; import static jdk.test.lib.Asserts.assertTrue; -import jdk.test.lib.DynamicVMOption; +import jdk.test.lib.management.DynamicVMOption; /** * @test TestDynMaxHeapFreeRatio diff --git a/hotspot/test/gc/arguments/TestDynMinHeapFreeRatio.java b/hotspot/test/gc/arguments/TestDynMinHeapFreeRatio.java index e21f066b0a0..09f24e7af35 100644 --- a/hotspot/test/gc/arguments/TestDynMinHeapFreeRatio.java +++ b/hotspot/test/gc/arguments/TestDynMinHeapFreeRatio.java @@ -38,7 +38,7 @@ import static jdk.test.lib.Asserts.assertEQ; import static jdk.test.lib.Asserts.assertFalse; import static jdk.test.lib.Asserts.assertTrue; -import jdk.test.lib.DynamicVMOption; +import jdk.test.lib.management.DynamicVMOption; public class TestDynMinHeapFreeRatio { diff --git a/hotspot/test/gc/arguments/TestSelectDefaultGC.java b/hotspot/test/gc/arguments/TestSelectDefaultGC.java index de770b283b8..084ee04a86b 100644 --- a/hotspot/test/gc/arguments/TestSelectDefaultGC.java +++ b/hotspot/test/gc/arguments/TestSelectDefaultGC.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -66,7 +66,6 @@ public class TestSelectDefaultGC { assertVMOption(output, "UseSerialGC", !isServer); // CMS is never default assertVMOption(output, "UseConcMarkSweepGC", false); - assertVMOption(output, "UseParNewGC", false); } public static void main(String[] args) throws Exception { diff --git a/hotspot/test/gc/class_unloading/TestClassUnloadingDisabled.java b/hotspot/test/gc/class_unloading/TestClassUnloadingDisabled.java index 96f10bbcd60..6d1c2d602cb 100644 --- a/hotspot/test/gc/class_unloading/TestClassUnloadingDisabled.java +++ b/hotspot/test/gc/class_unloading/TestClassUnloadingDisabled.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reqserved. + * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/hotspot/test/gc/metaspace/TestMetaspacePerfCounters.java b/hotspot/test/gc/metaspace/TestMetaspacePerfCounters.java index 06be649608d..f648be9f484 100644 --- a/hotspot/test/gc/metaspace/TestMetaspacePerfCounters.java +++ b/hotspot/test/gc/metaspace/TestMetaspacePerfCounters.java @@ -26,7 +26,7 @@ import java.util.List; import java.util.ArrayList; import jdk.test.lib.ByteCodeLoader; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.Platform; import sun.management.ManagementFactoryHelper; diff --git a/hotspot/test/gc/parallel/TestDynShrinkHeap.java b/hotspot/test/gc/parallel/TestDynShrinkHeap.java index f5e78ab7346..78c5946c4b7 100644 --- a/hotspot/test/gc/parallel/TestDynShrinkHeap.java +++ b/hotspot/test/gc/parallel/TestDynShrinkHeap.java @@ -31,7 +31,7 @@ * @library /test/lib / * @run main/othervm -XX:+UseAdaptiveSizePolicyWithSystemGC -XX:+UseParallelGC -XX:MinHeapFreeRatio=0 -XX:MaxHeapFreeRatio=100 -Xmx1g -verbose:gc TestDynShrinkHeap */ -import jdk.test.lib.DynamicVMOption; +import jdk.test.lib.management.DynamicVMOption; import java.lang.management.ManagementFactory; import java.lang.management.MemoryUsage; import java.util.ArrayList; diff --git a/hotspot/test/gc/parallel/TestPrintGCDetailsVerbose.java b/hotspot/test/gc/parallel/TestPrintGCDetailsVerbose.java index 1069b417d47..ccba8fcb8d5 100644 --- a/hotspot/test/gc/parallel/TestPrintGCDetailsVerbose.java +++ b/hotspot/test/gc/parallel/TestPrintGCDetailsVerbose.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,12 +23,13 @@ /* * @test TestPrintGCDetailsVerbose - * @bug 8016740 + * @bug 8016740 8177963 * @summary Tests that jvm with maximally verbose GC logging does not crash when ParOldGC has no memory * @key gc * @requires vm.gc.Parallel * @modules java.base/jdk.internal.misc * @run main/othervm -Xmx50m -XX:+UseParallelGC -Xlog:gc*=trace TestPrintGCDetailsVerbose + * @run main/othervm -Xmx50m -XX:+UseParallelGC -XX:GCTaskTimeStampEntries=1 -Xlog:gc*=trace TestPrintGCDetailsVerbose */ public class TestPrintGCDetailsVerbose { diff --git a/hotspot/test/gc/startup_warnings/TestCMS.java b/hotspot/test/gc/startup_warnings/TestCMS.java index d51a3ded1c0..a5b7cc9fc89 100644 --- a/hotspot/test/gc/startup_warnings/TestCMS.java +++ b/hotspot/test/gc/startup_warnings/TestCMS.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,8 +24,8 @@ /* * @test TestCMS * @key gc -* @bug 8006398 8155948 -* @summary Test that CMS prints a warning message only for a commercial build +* @bug 8006398 8155948 8179013 +* @summary Test that CMS prints a warning message * @library /test/lib * @modules java.base/jdk.internal.misc * java.management @@ -33,19 +33,13 @@ import jdk.test.lib.process.ProcessTools; import jdk.test.lib.process.OutputAnalyzer; -import jdk.test.lib.BuildHelper; public class TestCMS { public static void runTest(String[] args) throws Exception { - boolean isCommercial = BuildHelper.isCommercialBuild(); ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(args); OutputAnalyzer output = new OutputAnalyzer(pb.start()); - if (isCommercial) { - output.shouldContain("deprecated"); - } else { - output.shouldNotContain("deprecated"); - } + output.shouldContain("deprecated"); output.shouldNotContain("error"); output.shouldHaveExitValue(0); } diff --git a/hotspot/test/gc/startup_warnings/TestDefNewCMS.java b/hotspot/test/gc/startup_warnings/TestDefNewCMS.java deleted file mode 100644 index f8780679733..00000000000 --- a/hotspot/test/gc/startup_warnings/TestDefNewCMS.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -/* -* @test TestDefNewCMS -* @key gc -* @bug 8065972 -* @summary Test that the unsupported DefNew+CMS combination does not start -* @library /test/lib -* @modules java.base/jdk.internal.misc -* java.management -*/ - -import jdk.test.lib.process.ProcessTools; -import jdk.test.lib.process.OutputAnalyzer; - -public class TestDefNewCMS { - - public static void main(String args[]) throws Exception { - ProcessBuilder pb = ProcessTools.createJavaProcessBuilder("-XX:-UseParNewGC", "-XX:+UseConcMarkSweepGC", "-version"); - OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("It is not possible to combine the DefNew young collector with the CMS collector."); - output.shouldContain("Error"); - output.shouldHaveExitValue(1); - } - -} diff --git a/hotspot/test/gc/startup_warnings/TestParNewSerialOld.java b/hotspot/test/gc/startup_warnings/TestParNewSerialOld.java deleted file mode 100644 index a4c8d5c31e1..00000000000 --- a/hotspot/test/gc/startup_warnings/TestParNewSerialOld.java +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -/* -* @test TestParNewSerialOld -* @key gc -* @bug 8065972 -* @summary Test that the unsupported ParNew+SerialOld combination does not start -* @library /test/lib -* @modules java.base/jdk.internal.misc -* java.management -*/ - -import jdk.test.lib.process.ProcessTools; -import jdk.test.lib.process.OutputAnalyzer; - - -public class TestParNewSerialOld { - - public static void main(String args[]) throws Exception { - ProcessBuilder pb = ProcessTools.createJavaProcessBuilder("-XX:+UseParNewGC", "-version"); - OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("It is not possible to combine the ParNew young collector with any collector other than CMS."); - output.shouldContain("Error"); - output.shouldHaveExitValue(1); - } - -} diff --git a/hotspot/test/native/logging/test_logTagSetDescriptions.cpp b/hotspot/test/native/logging/test_logTagSetDescriptions.cpp index 77c0a3191dc..b0e9364c525 100644 --- a/hotspot/test/native/logging/test_logTagSetDescriptions.cpp +++ b/hotspot/test/native/logging/test_logTagSetDescriptions.cpp @@ -10,7 +10,7 @@ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that - * ac_heapanied this code). + * accompanied this code). * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, diff --git a/hotspot/test/native/memory/test_metachunk.cpp b/hotspot/test/native/memory/test_metachunk.cpp index e99bf42a121..9a4c6dae3a1 100644 --- a/hotspot/test/native/memory/test_metachunk.cpp +++ b/hotspot/test/native/memory/test_metachunk.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/hotspot/test/native/runtime/test_globals.cpp b/hotspot/test/native/runtime/test_globals.cpp index 2b6a99771d2..3a84f2ce714 100644 --- a/hotspot/test/native/runtime/test_globals.cpp +++ b/hotspot/test/native/runtime/test_globals.cpp @@ -53,7 +53,7 @@ TEST_VM(FlagGuard, uint_flag) { } TEST_VM(FlagGuard, uintx_flag) { - TEST_FLAG(GCTaskTimeStampEntries, uintx, 1337); + TEST_FLAG(GCTaskTimeStampEntries, uint, 1337); } TEST_VM(FlagGuard, size_t_flag) { diff --git a/hotspot/test/runtime/BadObjectClass/BootstrapRedefine.java b/hotspot/test/runtime/BadObjectClass/BootstrapRedefine.java index 186b235f0de..249993961b2 100644 --- a/hotspot/test/runtime/BadObjectClass/BootstrapRedefine.java +++ b/hotspot/test/runtime/BadObjectClass/BootstrapRedefine.java @@ -31,7 +31,7 @@ * @run main BootstrapRedefine */ -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.ProcessTools; import jdk.test.lib.process.OutputAnalyzer; diff --git a/hotspot/test/runtime/CommandLine/ObsoleteFlagErrorMessage.java b/hotspot/test/runtime/CommandLine/ObsoleteFlagErrorMessage.java index 31d8b47a2ba..59d245548a5 100644 --- a/hotspot/test/runtime/CommandLine/ObsoleteFlagErrorMessage.java +++ b/hotspot/test/runtime/CommandLine/ObsoleteFlagErrorMessage.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,18 +37,18 @@ public class ObsoleteFlagErrorMessage { // Case 1: Newly obsolete flags with extra junk appended should not be treated as newly obsolete (8060449) ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( - "-XX:UseOldInliningPlusJunk", "-version"); + "-XX:ConvertSleepToYieldPlusJunk", "-version"); OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("Unrecognized VM option 'UseOldInliningPlusJunk'"); // Must identify bad option. + output.shouldContain("Unrecognized VM option 'ConvertSleepToYieldPlusJunk'"); // Must identify bad option. output.shouldHaveExitValue(1); - // Case 2: Newly obsolete integer-valued flags should be recognized as newly obsolete (8073989) + // Case 2: Newly obsolete flags should be recognized as newly obsolete (8073989) ProcessBuilder pb2 = ProcessTools.createJavaProcessBuilder( - "-XX:NmethodSweepFraction=10", "-version"); + "-XX:+ConvertSleepToYield", "-version"); OutputAnalyzer output2 = new OutputAnalyzer(pb2.start()); output2.shouldContain("Ignoring option").shouldContain("support was removed"); - output2.shouldContain("NmethodSweepFraction"); + output2.shouldContain("ConvertSleepToYield"); } } diff --git a/hotspot/test/runtime/CommandLine/OptionsValidation/TestJcmdOutput.java b/hotspot/test/runtime/CommandLine/OptionsValidation/TestJcmdOutput.java index d15d536b751..1a46eb01877 100644 --- a/hotspot/test/runtime/CommandLine/OptionsValidation/TestJcmdOutput.java +++ b/hotspot/test/runtime/CommandLine/OptionsValidation/TestJcmdOutput.java @@ -34,7 +34,7 @@ */ import jdk.test.lib.Asserts; -import jdk.test.lib.DynamicVMOption; +import jdk.test.lib.management.DynamicVMOption; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; import jdk.test.lib.dcmd.PidJcmdExecutor; diff --git a/hotspot/test/runtime/CommandLine/OptionsValidation/TestOptionsWithRangesDynamic.java b/hotspot/test/runtime/CommandLine/OptionsValidation/TestOptionsWithRangesDynamic.java index d5f20b5d4d2..4fb53dfe1ea 100644 --- a/hotspot/test/runtime/CommandLine/OptionsValidation/TestOptionsWithRangesDynamic.java +++ b/hotspot/test/runtime/CommandLine/OptionsValidation/TestOptionsWithRangesDynamic.java @@ -28,7 +28,7 @@ * @modules java.base/jdk.internal.misc * jdk.attach/sun.tools.attach * java.management - * @run main/othervm -XX:MinHeapFreeRatio=0 -XX:MaxHeapFreeRatio=100 TestOptionsWithRangesDynamic + * @run main/othervm -XX:MinHeapFreeRatio=0 -XX:MaxHeapFreeRatio=100 -Djdk.attach.allowAttachSelf TestOptionsWithRangesDynamic */ import java.util.List; diff --git a/hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOption.java b/hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOption.java index b10ac75c56e..dd19e352d32 100644 --- a/hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOption.java +++ b/hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOption.java @@ -29,7 +29,7 @@ import java.util.Arrays; import java.util.HashSet; import java.util.List; import java.util.Set; -import jdk.test.lib.DynamicVMOption; +import jdk.test.lib.management.DynamicVMOption; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; import jdk.test.lib.dcmd.CommandExecutor; diff --git a/hotspot/test/runtime/CommandLine/PermGenFlagsTest.java b/hotspot/test/runtime/CommandLine/PermGenFlagsTest.java index 9a821e0059e..3ce993f57d4 100644 --- a/hotspot/test/runtime/CommandLine/PermGenFlagsTest.java +++ b/hotspot/test/runtime/CommandLine/PermGenFlagsTest.java @@ -8,7 +8,7 @@ * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * diff --git a/hotspot/test/runtime/CommandLine/VMAliasOptions.java b/hotspot/test/runtime/CommandLine/VMAliasOptions.java index eae37477c08..d82b4ae2274 100644 --- a/hotspot/test/runtime/CommandLine/VMAliasOptions.java +++ b/hotspot/test/runtime/CommandLine/VMAliasOptions.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -40,11 +40,6 @@ public class VMAliasOptions { */ public static final String[][] ALIAS_OPTIONS = { {"DefaultMaxRAMFraction", "MaxRAMFraction", "1032"}, - {"CMSMarkStackSizeMax", "MarkStackSizeMax", "1032"}, - {"CMSMarkStackSize", "MarkStackSize", "1032"}, - {"G1MarkStackSize", "MarkStackSize", "1032"}, - {"ParallelMarkingThreads", "ConcGCThreads", "2"}, - {"ParallelCMSThreads", "ConcGCThreads", "2"}, {"CreateMinidumpOnCrash", "CreateCoredumpOnCrash", "false" }, }; diff --git a/hotspot/test/runtime/CommandLine/VMDeprecatedOptions.java b/hotspot/test/runtime/CommandLine/VMDeprecatedOptions.java index 06f73568460..bbd2ea5c49f 100644 --- a/hotspot/test/runtime/CommandLine/VMDeprecatedOptions.java +++ b/hotspot/test/runtime/CommandLine/VMDeprecatedOptions.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -41,17 +41,9 @@ public class VMDeprecatedOptions { public static final String[][] DEPRECATED_OPTIONS = { // deprecated non-alias flags: {"MaxGCMinorPauseMillis", "1032"}, - {"UseParNewGC", "false"}, - {"ConvertSleepToYield", "false" }, - {"ConvertYieldToSleep", "false" }, // deprecated alias flags (see also aliased_jvm_flags): {"DefaultMaxRAMFraction", "4"}, - {"CMSMarkStackSizeMax", "1032"}, - {"CMSMarkStackSize", "1032"}, - {"G1MarkStackSize", "1032"}, - {"ParallelMarkingThreads", "2"}, - {"ParallelCMSThreads", "2"}, {"CreateMinidumpOnCrash", "false"} }; diff --git a/hotspot/test/runtime/CommandLine/VMOptionsFile/TestVMOptionsFile.java b/hotspot/test/runtime/CommandLine/VMOptionsFile/TestVMOptionsFile.java index 865fb9b8556..b88c50683b2 100644 --- a/hotspot/test/runtime/CommandLine/VMOptionsFile/TestVMOptionsFile.java +++ b/hotspot/test/runtime/CommandLine/VMOptionsFile/TestVMOptionsFile.java @@ -51,7 +51,7 @@ import java.util.List; import java.util.Properties; import java.util.Set; import jdk.test.lib.Asserts; -import jdk.test.lib.DynamicVMOption; +import jdk.test.lib.management.DynamicVMOption; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/LocalLong/LocalLongHelper.java b/hotspot/test/runtime/LocalLong/LocalLongHelper.java index 2134aee069e..065d7d8cbcb 100644 --- a/hotspot/test/runtime/LocalLong/LocalLongHelper.java +++ b/hotspot/test/runtime/LocalLong/LocalLongHelper.java @@ -30,10 +30,10 @@ import java.lang.StackWalker.StackFrame; public class LocalLongHelper { static StackWalker sw; - static Method intValue; + static Method longValue; static Method getLocals; static Class primitiveValueClass; - static Method primitiveType; + static Method primitiveSize; static Method getMethodType; static Field memberName; static Field offset; @@ -43,27 +43,29 @@ public class LocalLongHelper { new LocalLongHelper().longArg(0xC0FFEE, 0x1234567890ABCDEFL); } - // locals[2] contains the high byte of the long argument. + // locals[2] contains the unused slot of the long argument. public long longArg(int i, long l) throws Throwable { List frames = sw.walk(s -> s.collect(Collectors.toList())); Object[] locals = (Object[]) getLocals.invoke(frames.get(0)); - int locals_2 = (int) intValue.invoke(locals[2]); - if (locals_2 != 0){ - throw new RuntimeException("Expected locals_2 == 0"); + if (8 == (int) primitiveSize.invoke(locals[2])) { // Only test 64-bit + long locals_2 = (long) longValue.invoke(locals[2]); + if (locals_2 != 0){ + throw new RuntimeException("Expected locals_2 == 0"); + } } return l; // Don't want l to become a dead var } private static void setupReflectionStatics() throws Throwable { Class liveStackFrameClass = Class.forName("java.lang.LiveStackFrame"); - primitiveValueClass = Class.forName("java.lang.LiveStackFrame$PrimitiveValue"); + primitiveValueClass = Class.forName("java.lang.LiveStackFrame$PrimitiveSlot"); getLocals = liveStackFrameClass.getDeclaredMethod("getLocals"); getLocals.setAccessible(true); - intValue = primitiveValueClass.getDeclaredMethod("intValue"); - intValue.setAccessible(true); + longValue = primitiveValueClass.getDeclaredMethod("longValue"); + longValue.setAccessible(true); Class stackFrameInfoClass = Class.forName("java.lang.StackFrameInfo"); memberName = stackFrameInfoClass.getDeclaredField("memberName"); @@ -80,20 +82,8 @@ public class LocalLongHelper { f.setAccessible(true); Object localsAndOperandsOption = f.get(null); - primitiveType = primitiveValueClass.getDeclaredMethod("type"); - primitiveType.setAccessible(true); - + primitiveSize = primitiveValueClass.getDeclaredMethod("size"); + primitiveSize.setAccessible(true); sw = (StackWalker) ewsNI.invoke(null, java.util.Collections.emptySet(), localsAndOperandsOption); } - - private static String type(Object o) throws Throwable { - if (primitiveValueClass.isInstance(o)) { - final char c = (char) primitiveType.invoke(o); - return String.valueOf(c); - } else if (o != null) { - return o.getClass().getName(); - } else { - return "null"; - } - } } diff --git a/hotspot/test/runtime/Metaspace/DefineClass.java b/hotspot/test/runtime/Metaspace/DefineClass.java new file mode 100644 index 00000000000..6225e1555fc --- /dev/null +++ b/hotspot/test/runtime/Metaspace/DefineClass.java @@ -0,0 +1,381 @@ +/* + * Copyright (c) 2017 SAP SE. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8173743 + * @requires vm.compMode != "Xcomp" + * @summary Failures during class definition can lead to memory leaks in metaspace + * @library /test/lib + * @run main/othervm test.DefineClass defineClass + * @run main/othervm test.DefineClass defineSystemClass + * @run main/othervm -XX:+UnlockDiagnosticVMOptions + -XX:+UnsyncloadClass -XX:+AllowParallelDefineClass + test.DefineClass defineClassParallel + * @run main/othervm -XX:+UnlockDiagnosticVMOptions + -XX:+UnsyncloadClass -XX:-AllowParallelDefineClass + test.DefineClass defineClassParallel + * @run main/othervm -XX:+UnlockDiagnosticVMOptions + -XX:-UnsyncloadClass -XX:+AllowParallelDefineClass + test.DefineClass defineClassParallel + * @run main/othervm -XX:+UnlockDiagnosticVMOptions + -XX:-UnsyncloadClass -XX:-AllowParallelDefineClass + test.DefineClass defineClassParallel + * @run main/othervm -Djdk.attach.allowAttachSelf test.DefineClass redefineClass + * @run main/othervm -Djdk.attach.allowAttachSelf test.DefineClass redefineClassWithError + * @author volker.simonis@gmail.com + */ + +package test; + +import java.io.ByteArrayOutputStream; +import java.io.File; +import java.io.FileOutputStream; +import java.io.InputStream; +import java.lang.instrument.ClassDefinition; +import java.lang.instrument.Instrumentation; +import java.lang.management.ManagementFactory; +import java.util.Scanner; +import java.util.concurrent.CountDownLatch; +import java.util.jar.Attributes; +import java.util.jar.JarEntry; +import java.util.jar.JarOutputStream; +import java.util.jar.Manifest; + +import javax.management.MBeanServer; +import javax.management.ObjectName; + +import com.sun.tools.attach.VirtualMachine; + +import jdk.test.lib.process.ProcessTools; + +public class DefineClass { + + private static Instrumentation instrumentation; + + public void getID(CountDownLatch start, CountDownLatch stop) { + String id = "AAAAAAAA"; + System.out.println(id); + try { + // Signal that we've entered the activation.. + start.countDown(); + //..and wait until we can leave it. + stop.await(); + } catch (InterruptedException e) { + e.printStackTrace(); + } + System.out.println(id); + return; + } + + private static class MyThread extends Thread { + private DefineClass dc; + private CountDownLatch start, stop; + + public MyThread(DefineClass dc, CountDownLatch start, CountDownLatch stop) { + this.dc = dc; + this.start = start; + this.stop = stop; + } + + public void run() { + dc.getID(start, stop); + } + } + + private static class ParallelLoadingThread extends Thread { + private MyParallelClassLoader pcl; + private CountDownLatch stop; + private byte[] buf; + + public ParallelLoadingThread(MyParallelClassLoader pcl, byte[] buf, CountDownLatch stop) { + this.pcl = pcl; + this.stop = stop; + this.buf = buf; + } + + public void run() { + try { + stop.await(); + } catch (InterruptedException e) { + e.printStackTrace(); + } + try { + @SuppressWarnings("unchecked") + Class dc = (Class) pcl.myDefineClass(DefineClass.class.getName(), buf, 0, buf.length); + } + catch (LinkageError jle) { + // Expected with a parallel capable class loader and + // -XX:+UnsyncloadClass or -XX:+AllowParallelDefineClass + pcl.incrementLinkageErrors(); + } + + } + } + + static private class MyClassLoader extends ClassLoader { + public Class myDefineClass(String name, byte[] b, int off, int len) throws ClassFormatError { + return defineClass(name, b, off, len, null); + } + } + + static private class MyParallelClassLoader extends ClassLoader { + static { + System.out.println("parallelCapable : " + registerAsParallelCapable()); + } + public Class myDefineClass(String name, byte[] b, int off, int len) throws ClassFormatError { + return defineClass(name, b, off, len, null); + } + public synchronized void incrementLinkageErrors() { + linkageErrors++; + } + public int getLinkageErrors() { + return linkageErrors; + } + private volatile int linkageErrors; + } + + public static void agentmain(String args, Instrumentation inst) { + System.out.println("Loading Java Agent."); + instrumentation = inst; + } + + + private static void loadInstrumentationAgent(String myName, byte[] buf) throws Exception { + // Create agent jar file on the fly + Manifest m = new Manifest(); + m.getMainAttributes().put(Attributes.Name.MANIFEST_VERSION, "1.0"); + m.getMainAttributes().put(new Attributes.Name("Agent-Class"), myName); + m.getMainAttributes().put(new Attributes.Name("Can-Redefine-Classes"), "true"); + File jarFile = File.createTempFile("agent", ".jar"); + jarFile.deleteOnExit(); + JarOutputStream jar = new JarOutputStream(new FileOutputStream(jarFile), m); + jar.putNextEntry(new JarEntry(myName.replace('.', '/') + ".class")); + jar.write(buf); + jar.close(); + String pid = Long.toString(ProcessTools.getProcessId()); + System.out.println("Our pid is = " + pid); + VirtualMachine vm = VirtualMachine.attach(pid); + vm.loadAgent(jarFile.getAbsolutePath()); + } + + private static byte[] getBytecodes(String myName) throws Exception { + InputStream is = DefineClass.class.getResourceAsStream(myName + ".class"); + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + byte[] buf = new byte[4096]; + int len; + while ((len = is.read(buf)) != -1) baos.write(buf, 0, len); + buf = baos.toByteArray(); + System.out.println("sizeof(" + myName + ".class) == " + buf.length); + return buf; + } + + private static int getStringIndex(String needle, byte[] buf) { + return getStringIndex(needle, buf, 0); + } + + private static int getStringIndex(String needle, byte[] buf, int offset) { + outer: + for (int i = offset; i < buf.length - offset - needle.length(); i++) { + for (int j = 0; j < needle.length(); j++) { + if (buf[i + j] != (byte)needle.charAt(j)) continue outer; + } + return i; + } + return 0; + } + + private static void replaceString(byte[] buf, String name, int index) { + for (int i = index; i < index + name.length(); i++) { + buf[i] = (byte)name.charAt(i - index); + } + } + + private static MBeanServer mbserver = ManagementFactory.getPlatformMBeanServer(); + + private static int getClassStats(String pattern) { + try { + ObjectName diagCmd = new ObjectName("com.sun.management:type=DiagnosticCommand"); + + String result = (String)mbserver.invoke(diagCmd , "gcClassStats" , new Object[] { null }, new String[] {String[].class.getName()}); + int count = 0; + try (Scanner s = new Scanner(result)) { + if (s.hasNextLine()) { + System.out.println(s.nextLine()); + } + while (s.hasNextLine()) { + String l = s.nextLine(); + if (l.endsWith(pattern)) { + count++; + System.out.println(l); + } + } + } + return count; + } + catch (Exception e) { + throw new RuntimeException("Test failed because we can't read the class statistics!", e); + } + } + + private static void printClassStats(int expectedCount, boolean reportError) { + int count = getClassStats("DefineClass"); + String res = "Should have " + expectedCount + + " DefineClass instances and we have: " + count; + System.out.println(res); + if (reportError && count != expectedCount) { + throw new RuntimeException(res); + } + } + + public static final int ITERATIONS = 10; + + public static void main(String[] args) throws Exception { + String myName = DefineClass.class.getName(); + byte[] buf = getBytecodes(myName.substring(myName.lastIndexOf(".") + 1)); + int iterations = (args.length > 1 ? Integer.parseInt(args[1]) : ITERATIONS); + + if (args.length == 0 || "defineClass".equals(args[0])) { + MyClassLoader cl = new MyClassLoader(); + for (int i = 0; i < iterations; i++) { + try { + @SuppressWarnings("unchecked") + Class dc = (Class) cl.myDefineClass(myName, buf, 0, buf.length); + System.out.println(dc); + } + catch (LinkageError jle) { + // Can only define once! + if (i == 0) throw new Exception("Should succeed the first time."); + } + } + // We expect to have two instances of DefineClass here: the initial version in which we are + // executing and another version which was loaded into our own classloader 'MyClassLoader'. + // All the subsequent attempts to reload DefineClass into our 'MyClassLoader' should have failed. + printClassStats(2, false); + System.gc(); + System.out.println("System.gc()"); + // At least after System.gc() the failed loading attempts should leave no instances around! + printClassStats(2, true); + } + else if ("defineSystemClass".equals(args[0])) { + MyClassLoader cl = new MyClassLoader(); + int index = getStringIndex("test/DefineClass", buf); + replaceString(buf, "java/DefineClass", index); + while ((index = getStringIndex("Ltest/DefineClass;", buf, index + 1)) != 0) { + replaceString(buf, "Ljava/DefineClass;", index); + } + index = getStringIndex("test.DefineClass", buf); + replaceString(buf, "java.DefineClass", index); + + for (int i = 0; i < iterations; i++) { + try { + @SuppressWarnings("unchecked") + Class dc = (Class) cl.myDefineClass(null, buf, 0, buf.length); + throw new RuntimeException("Defining a class in the 'java' package should fail!"); + } + catch (java.lang.SecurityException jlse) { + // Expected, because we're not allowed to define a class in the 'java' package + } + } + // We expect to stay with one (the initial) instances of DefineClass. + // All the subsequent attempts to reload DefineClass into the 'java' package should have failed. + printClassStats(1, false); + System.gc(); + System.out.println("System.gc()"); + // At least after System.gc() the failed loading attempts should leave no instances around! + printClassStats(1, true); + } + else if ("defineClassParallel".equals(args[0])) { + MyParallelClassLoader pcl = new MyParallelClassLoader(); + CountDownLatch stop = new CountDownLatch(1); + + Thread[] threads = new Thread[iterations]; + for (int i = 0; i < iterations; i++) { + (threads[i] = new ParallelLoadingThread(pcl, buf, stop)).start(); + } + stop.countDown(); // start parallel class loading.. + // ..and wait until all threads loaded the class + for (int i = 0; i < iterations; i++) { + threads[i].join(); + } + System.out.print("Counted " + pcl.getLinkageErrors() + " LinkageErrors "); + System.out.println(pcl.getLinkageErrors() == 0 ? + "" : "(use -XX:+UnsyncloadClass and/or -XX:+AllowParallelDefineClass to avoid this)"); + System.gc(); + System.out.println("System.gc()"); + // After System.gc() we expect to remain with two instances: one is the initial version which is + // kept alive by this main method and another one in the parallel class loader. + printClassStats(2, true); + } + else if ("redefineClass".equals(args[0])) { + loadInstrumentationAgent(myName, buf); + int index = getStringIndex("AAAAAAAA", buf); + CountDownLatch stop = new CountDownLatch(1); + + Thread[] threads = new Thread[iterations]; + for (int i = 0; i < iterations; i++) { + buf[index] = (byte) ('A' + i + 1); // Change string constant in getID() which is legal in redefinition + instrumentation.redefineClasses(new ClassDefinition(DefineClass.class, buf)); + DefineClass dc = DefineClass.class.newInstance(); + CountDownLatch start = new CountDownLatch(1); + (threads[i] = new MyThread(dc, start, stop)).start(); + start.await(); // Wait until the new thread entered the getID() method + } + // We expect to have one instance for each redefinition because they are all kept alive by an activation + // plus the initial version which is kept active by this main method. + printClassStats(iterations + 1, false); + stop.countDown(); // Let all threads leave the DefineClass.getID() activation.. + // ..and wait until really all of them returned from DefineClass.getID() + for (int i = 0; i < iterations; i++) { + threads[i].join(); + } + System.gc(); + System.out.println("System.gc()"); + // After System.gc() we expect to remain with two instances: one is the initial version which is + // kept alive by this main method and another one which is the latest redefined version. + printClassStats(2, true); + } + else if ("redefineClassWithError".equals(args[0])) { + loadInstrumentationAgent(myName, buf); + int index = getStringIndex("getID", buf); + + for (int i = 0; i < iterations; i++) { + buf[index] = (byte) 'X'; // Change getID() to XetID() which is illegal in redefinition + try { + instrumentation.redefineClasses(new ClassDefinition(DefineClass.class, buf)); + throw new RuntimeException("Class redefinition isn't allowed to change method names!"); + } + catch (UnsupportedOperationException uoe) { + // Expected because redefinition can't change the name of methods + } + } + // We expect just a single DefineClass instance because failed redefinitions should + // leave no garbage around. + printClassStats(1, false); + System.gc(); + System.out.println("System.gc()"); + // At least after a System.gc() we should definitely stay with a single instance! + printClassStats(1, true); + } + } +} diff --git a/hotspot/test/runtime/MinimalVM/JMX.java b/hotspot/test/runtime/MinimalVM/JMX.java index e57325ebaa7..5a9dc20abf0 100644 --- a/hotspot/test/runtime/MinimalVM/JMX.java +++ b/hotspot/test/runtime/MinimalVM/JMX.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,9 +47,8 @@ public class JMX { .shouldContain("-Dcom.sun.management is not supported in this VM.") .shouldHaveExitValue(1); - pb.command(new String[] { JDKToolFinder.getJDKTool("jcmd"), Long.toString(ProcessTools.getProcessId()), "VM.print_threads"}); + pb.command(new String[] { JDKToolFinder.getJDKTool("jcmd"), "-l"}); new OutputAnalyzer(pb.start()) - .shouldContain("Could not find any processes matching ") - .shouldHaveExitValue(1); + .shouldNotMatch("^" + Long.toString(ProcessTools.getProcessId()) + "\\s+.*$"); } } diff --git a/hotspot/test/runtime/RedefineTests/ModifyAnonymous.java b/hotspot/test/runtime/RedefineTests/ModifyAnonymous.java index 700a8f04e93..3eeb96e4a0a 100644 --- a/hotspot/test/runtime/RedefineTests/ModifyAnonymous.java +++ b/hotspot/test/runtime/RedefineTests/ModifyAnonymous.java @@ -34,15 +34,14 @@ import java.io.FileNotFoundException; import java.io.PrintWriter; -import java.lang.NoSuchFieldException; -import java.lang.NoSuchMethodException; import java.lang.RuntimeException; import java.lang.instrument.ClassDefinition; import java.lang.instrument.ClassFileTransformer; import java.lang.instrument.IllegalClassFormatException; import java.lang.instrument.Instrumentation; import java.security.ProtectionDomain; -import jdk.test.lib.*; + +import jdk.test.lib.compiler.InMemoryJavaCompiler; public class ModifyAnonymous { diff --git a/hotspot/test/runtime/Unsafe/DefineClass.java b/hotspot/test/runtime/Unsafe/DefineClass.java index 5973f666122..1c48d95b49b 100644 --- a/hotspot/test/runtime/Unsafe/DefineClass.java +++ b/hotspot/test/runtime/Unsafe/DefineClass.java @@ -32,8 +32,8 @@ */ import java.security.ProtectionDomain; -import java.io.InputStream; -import jdk.test.lib.InMemoryJavaCompiler; + +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.internal.misc.Unsafe; import static jdk.test.lib.Asserts.*; diff --git a/hotspot/test/runtime/Unsafe/NestedUnsafe.java b/hotspot/test/runtime/Unsafe/NestedUnsafe.java index a1a995ab636..ec63bf271f6 100644 --- a/hotspot/test/runtime/Unsafe/NestedUnsafe.java +++ b/hotspot/test/runtime/Unsafe/NestedUnsafe.java @@ -31,12 +31,9 @@ * @run main NestedUnsafe */ -import java.security.ProtectionDomain; -import java.io.InputStream; import java.lang.*; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.internal.misc.Unsafe; -import static jdk.test.lib.Asserts.*; // package p; diff --git a/hotspot/test/runtime/classFileParserBug/AccModuleTest.java b/hotspot/test/runtime/classFileParserBug/AccModuleTest.java new file mode 100644 index 00000000000..2adc1e3db43 --- /dev/null +++ b/hotspot/test/runtime/classFileParserBug/AccModuleTest.java @@ -0,0 +1,54 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8174725 + * @summary Throw NoClassDefFoundError if class access_flags have ACC_MODULE set + * @compile BadAccModule.jcod BadAccModInrClss.jcod + * @run main AccModuleTest + */ + +// Test that classes with access_flags containing ACC_MODULE cause ClassDefNotFoundErrors. +public class AccModuleTest { + public static void main(String args[]) throws Throwable { + + System.out.println("Regression test for bug 8174725"); + try { + Class newClass = Class.forName("BadAccModule"); + throw new RuntimeException("Expected NoClassDefFoundError exception not thrown"); + } catch (java.lang.NoClassDefFoundError e) { + if (!e.getMessage().contains("BadAccModule is not a class because access_flag ACC_MODULE is set")) { + throw new RuntimeException("Wrong NoClassDefFoundError exception for AccModuleTest: " + e.getMessage()); + } + } + try { + Class newClass = Class.forName("BadAccModInrClss"); + throw new RuntimeException("Expected NoClassDefFoundError exception not thrown"); + } catch (java.lang.NoClassDefFoundError e) { + if (!e.getMessage().contains("BadAccModInrClss is not a class because access_flag ACC_MODULE is set")) { + throw new RuntimeException("Wrong NoClassDefFoundError exception for BadAccModInrClss: " + e.getMessage()); + } + } + } +} diff --git a/hotspot/test/runtime/classFileParserBug/BadAccModInrClss.jcod b/hotspot/test/runtime/classFileParserBug/BadAccModInrClss.jcod new file mode 100644 index 00000000000..bba5d08794b --- /dev/null +++ b/hotspot/test/runtime/classFileParserBug/BadAccModInrClss.jcod @@ -0,0 +1,113 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * This tests that a class in an InnerClasses attribute with ACC_MODULE set + * causes a NoClassDefFoundError exception to get thrown. + */ + +class BadAccModInrClss { + 0xCAFEBABE; + 0; // minor version + 53; // version + [22] { // Constant Pool + ; // first element is empty + Field #3 #14; // #1 at 0x0A + Method #4 #15; // #2 at 0x0F + class #16; // #3 at 0x14 + class #19; // #4 at 0x17 + Utf8 "this$0"; // #5 at 0x1A + Utf8 "La;"; // #6 at 0x23 + Utf8 "Synthetic"; // #7 at 0x29 + Utf8 ""; // #8 at 0x35 + Utf8 "(Ljava/lang/Object;)V"; // #9 at 0x3E + Utf8 "Code"; // #10 at 0x56 + Utf8 "LineNumberTable"; // #11 at 0x5D + Utf8 "SourceFile"; // #12 at 0x6F + Utf8 "a.java"; // #13 at 0x7C + NameAndType #5 #6; // #14 at 0x85 + NameAndType #8 #20; // #15 at 0x8A + Utf8 "BadAccModInrClss"; // #16 at 0x8F + Utf8 "Loc"; // #17 at 0x9E + Utf8 "InnerClasses"; // #18 at 0xA4 + Utf8 "java/lang/Object"; // #19 at 0xB3 + Utf8 "()V"; // #20 at 0xC6 + Utf8 "EnclosingMethod"; // #21 at 0xCC + } // Constant Pool + + 0x0000; // access + #3;// this_cpx + #4;// super_cpx + + [0] { // Interfaces + } // Interfaces + + [1] { // fields + { // Member at 0xE8 + 0x0000; // access + #5; // name_cpx + #6; // sig_cpx + [1] { // Attributes + Attr(#7, 0) { // Synthetic at 0xF0 + } // end Synthetic + } // Attributes + } // Member + } // fields + + [1] { // methods + { // Member at 0xF8 + 0x0001; // access + #8; // name_cpx + #20; // sig_cpx + [1] { // Attributes + Attr(#10, 17) { // Code at 0x0100 + 2; // max_stack + 2; // max_locals + Bytes[5]{ + 0x2AB70002B1; + }; + [0] { // Traps + } // end Traps + [0] { // Attributes + } // Attributes + } // end Code + } // Attributes + } // Member + } // methods + + [3] { // Attributes + Attr(#12, 2) { // SourceFile at 0x0119 + #13; + } // end SourceFile + ; + Attr(#18, 10) { // InnerClasses at 0x0121 + [1] { // InnerClasses + #3 #0 #17 0x8000; // at 0x0131 + } + } // end InnerClasses + ; + Attr(#21, 4) { // EnclosingMethod at 0x0131 + 0x0004000F; + } // end EnclosingMethod + } // Attributes +} // end class BadAccModInrClss diff --git a/hotspot/test/runtime/classFileParserBug/BadAccModule.jcod b/hotspot/test/runtime/classFileParserBug/BadAccModule.jcod new file mode 100644 index 00000000000..6d7d1ec1211 --- /dev/null +++ b/hotspot/test/runtime/classFileParserBug/BadAccModule.jcod @@ -0,0 +1,140 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + * + */ + +// This is a .jcod file for a simple "Hello World" program with ACC_MODULE added +// to its access_flags. (See line 67.) This should cause a NoClassDefFoundError +// when loading the class. +class BadAccModule { + 0xCAFEBABE; + 0; // minor version + 53; // version + [32] { // Constant Pool + ; // first element is empty + Method #6 #17; // #1 at 0x0A + Field #18 #19; // #2 at 0x0F + String #20; // #3 at 0x14 + Method #21 #22; // #4 at 0x17 + class #23; // #5 at 0x1C + class #24; // #6 at 0x1F + Utf8 ""; // #7 at 0x22 + Utf8 "()V"; // #8 at 0x2B + Utf8 "Code"; // #9 at 0x31 + Utf8 "LineNumberTable"; // #10 at 0x38 + Utf8 "main"; // #11 at 0x4A + Utf8 "([Ljava/lang/String;)V"; // #12 at 0x51 + Utf8 "Exceptions"; // #13 at 0x6A + class #25; // #14 at 0x77 + Utf8 "SourceFile"; // #15 at 0x7A + Utf8 "BadAccModule.java"; // #16 at 0x87 + NameAndType #7 #8; // #17 at 0x9B + class #26; // #18 at 0xA0 + NameAndType #27 #28; // #19 at 0xA3 + Utf8 "Hello World"; // #20 at 0xA8 + class #29; // #21 at 0xB6 + NameAndType #30 #31; // #22 at 0xB9 + Utf8 "BadAccModule"; // #23 at 0xBE + Utf8 "java/lang/Object"; // #24 at 0xCD + Utf8 "java/lang/Throwable"; // #25 at 0xE0 + Utf8 "java/lang/System"; // #26 at 0xF6 + Utf8 "out"; // #27 at 0x0109 + Utf8 "Ljava/io/PrintStream;"; // #28 at 0x010F + Utf8 "java/io/PrintStream"; // #29 at 0x0127 + Utf8 "println"; // #30 at 0x013D + Utf8 "(Ljava/lang/String;)V"; // #31 at 0x0147 + } // Constant Pool + + 0x8021; // access Added ACC_MODULE (0x8000) !!! + #5;// this_cpx + #6;// super_cpx + + [0] { // Interfaces + } // Interfaces + + [0] { // fields + } // fields + + [2] { // methods + { // Member at 0x016B + 0x0001; // access + #7; // name_cpx + #8; // sig_cpx + [1] { // Attributes + Attr(#9, 29) { // Code at 0x0173 + 1; // max_stack + 1; // max_locals + Bytes[5]{ + 0x2AB70001B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#10, 6) { // LineNumberTable at 0x018A + [1] { // LineNumberTable + 0 1; // at 0x0196 + } + } // end LineNumberTable + } // Attributes + } // end Code + } // Attributes + } // Member + ; + { // Member at 0x0196 + 0x0009; // access + #11; // name_cpx + #12; // sig_cpx + [2] { // Attributes + Attr(#9, 37) { // Code at 0x019E + 2; // max_stack + 1; // max_locals + Bytes[9]{ + 0xB200021203B60004; + 0xB1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#10, 10) { // LineNumberTable at 0x01B9 + [2] { // LineNumberTable + 0 4; // at 0x01C5 + 8 5; // at 0x01C9 + } + } // end LineNumberTable + } // Attributes + } // end Code + ; + Attr(#13, 4) { // Exceptions at 0x01C9 + [1] { // Exceptions + #14; // at 0x01D3 + } + } // end Exceptions + } // Attributes + } // Member + } // methods + + [1] { // Attributes + Attr(#15, 2) { // SourceFile at 0x01D5 + #16; + } // end SourceFile + } // Attributes +} // end class BadAccModule diff --git a/hotspot/test/runtime/classFileParserBug/fakeMethodAccessor.jasm b/hotspot/test/runtime/classFileParserBug/fakeMethodAccessor.jasm index 36cebcb5049..207438a59a7 100644 --- a/hotspot/test/runtime/classFileParserBug/fakeMethodAccessor.jasm +++ b/hotspot/test/runtime/classFileParserBug/fakeMethodAccessor.jasm @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,6 @@ // to create a sub-type of jdk.internal.reflect.MethodAccessorImpl in order // to bypass Reflection.getCallerClass. That should fail with an IAE. // - import java.lang.reflect.Module; class fakeMethodAccessor extends jdk.internal.reflect.MethodAccessorImpl { public static void main(String[] a) throws Exception { fakeMethodAccessor f = new fakeMethodAccessor(); @@ -60,11 +59,11 @@ public static Method main:"([Ljava/lang/String;)V" astore_1; getstatic Field java/lang/System.out:"Ljava/io/PrintStream;"; ldc class java/lang/String; - invokevirtual Method java/lang/Class.getModule:"()Ljava/lang/reflect/Module;"; + invokevirtual Method java/lang/Class.getModule:"()Ljava/lang/Module;"; ldc String "jdk.internal.misc"; ldc class FakeMethodAccessor; - invokevirtual Method java/lang/Class.getModule:"()Ljava/lang/reflect/Module;"; - invokevirtual Method java/lang/reflect/Module.isExported:"(Ljava/lang/String;Ljava/lang/reflect/Module;)Z"; + invokevirtual Method java/lang/Class.getModule:"()Ljava/lang/Module;"; + invokevirtual Method java/lang/Module.isExported:"(Ljava/lang/String;Ljava/lang/Module;)Z"; invokevirtual Method java/io/PrintStream.println:"(Z)V"; return; } diff --git a/hotspot/test/runtime/constantPool/ACCModule52.java b/hotspot/test/runtime/constantPool/ACCModule52.java new file mode 100644 index 00000000000..241425076ca --- /dev/null +++ b/hotspot/test/runtime/constantPool/ACCModule52.java @@ -0,0 +1,69 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import jdk.internal.org.objectweb.asm.*; + +/* + * @test + * @summary Test that the JVM ignores ACC_MODULE if it is set for a version + * 52 class file. + * @bug 8175383 + * @library /test/lib + * @modules java.base/jdk.internal.org.objectweb.asm + * @compile -XDignore.symbol.file ACCModule52.java + * @run main ACCModule52 + */ + +public class ACCModule52 { + + static final String CLASS_NAME = "ACCModule52Pkg"; + + public static void main(String[] args) throws Exception { + int ACC_MODULE = 0x8000; + ClassWriter cw = new ClassWriter(0); + cw.visit(Opcodes.V1_8, + Opcodes.ACC_INTERFACE + Opcodes.ACC_ABSTRACT + Opcodes.ACC_SYNTHETIC + ACC_MODULE, + CLASS_NAME, + null, + "java/lang/Object", + null); + + cw.visitEnd(); + byte[] bytes = cw.toByteArray(); + + + ClassLoader loader = new ClassLoader(ACCModule52.class.getClassLoader()) { + @Override + protected Class findClass(String cn)throws ClassNotFoundException { + if (cn.equals(CLASS_NAME)) { + Class superClass = super.defineClass(cn, bytes, 0, bytes.length); + } else { + throw new ClassNotFoundException(cn); + } + return null; + } + }; + + Class clazz = loader.loadClass(CLASS_NAME); + } +} diff --git a/hotspot/test/runtime/constantPool/ConstModule.java b/hotspot/test/runtime/constantPool/ConstModule.java new file mode 100644 index 00000000000..94e577a29ef --- /dev/null +++ b/hotspot/test/runtime/constantPool/ConstModule.java @@ -0,0 +1,255 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import jdk.internal.org.objectweb.asm.*; + +/* + * @test + * @summary Test scenarios for constant pool CONSTANT_Module and CONSTANT_Package + * types, for class file versions 53 and 52, when ACC_MODULE is set and + * not set in the access_flags. + * @bug 8175383 + * @library /test/lib + * @modules java.base/jdk.internal.org.objectweb.asm + * @compile -XDignore.symbol.file ConstModule.java + * @run main ConstModule + */ + +public class ConstModule { + + static final int ACC_MODULE = 0x8000; + static final boolean MODULE_TEST = true; + static final boolean PACKAGE_TEST = false; + static final boolean CFE_EXCEPTION = true; + static final boolean NCDFE_EXCEPTION = false; + + public static void main(String[] args) throws Exception { + + // Test that the JVM throws CFE for constant pool CONSTANT_Module type, for + // class file version 53, when ACC_MODULE is not set in the access_flags. + ConstModule.write_and_load(Opcodes.V1_9, + Opcodes.ACC_INTERFACE + Opcodes.ACC_ABSTRACT + Opcodes.ACC_SYNTHETIC, + "jdk.fooMod", "FooMod", MODULE_TEST, CFE_EXCEPTION); + + // Test that the JVM throws NCDFE for constant pool CONSTANT_Module type, + // for class file version 53, when ACC_MODULE is set in the access_flags. + ConstModule.write_and_load(Opcodes.V1_9, + Opcodes.ACC_INTERFACE + Opcodes.ACC_ABSTRACT + Opcodes.ACC_SYNTHETIC + ACC_MODULE, + "jdk.fooModACC", "FooModACC", MODULE_TEST, NCDFE_EXCEPTION); + + // Test that the JVM throws CFE for constant pool CONSTANT_Module type, for + // class file version 52, even when ACC_MODULE is set in the access_flags. + ConstModule.write_and_load(Opcodes.V1_8, + Opcodes.ACC_INTERFACE + Opcodes.ACC_ABSTRACT + Opcodes.ACC_SYNTHETIC + ACC_MODULE, + "jdk.fooModACC52", "FooModACC52", MODULE_TEST, CFE_EXCEPTION); + + // Test that the JVM throws CFE for constant pool CONSTANT_Package type, for + // class file version 53, when ACC_MODULE is not set in the access_flags. + ConstModule.write_and_load(Opcodes.V1_9, + Opcodes.ACC_INTERFACE + Opcodes.ACC_ABSTRACT + Opcodes.ACC_SYNTHETIC, + "jdk.fooPkg", "FooPkg", PACKAGE_TEST, CFE_EXCEPTION); + + // Test that the JVM throws NCDFE for constant pool CONSTANT_Package type, + // for class file version 53, when ACC_MODULE is set in the access_flags. + ConstModule.write_and_load(Opcodes.V1_9, + Opcodes.ACC_INTERFACE + Opcodes.ACC_ABSTRACT + Opcodes.ACC_SYNTHETIC + ACC_MODULE, + "jdk.fooModACC", "FooModACC", PACKAGE_TEST, NCDFE_EXCEPTION); + + // Test that the JVM throws CFE for constant pool CONSTANT_Package type, for + // class file version 52, even when ACC_MODULE is set in the access_flags. + ConstModule.write_and_load(Opcodes.V1_8, + Opcodes.ACC_INTERFACE + Opcodes.ACC_ABSTRACT + Opcodes.ACC_SYNTHETIC + ACC_MODULE, + "jdk.fooModACC52", "FooModACC52", PACKAGE_TEST, CFE_EXCEPTION); + + } + + public static void write_and_load(int version, + int access_flags, + String attr, + String class_name, + boolean module_test, + boolean throwCFE) throws Exception { + ClassWriter cw = new ClassWriter(0); + cw.visit(version, + access_flags, + class_name, + null, + "java/lang/Object", + null); + + if (module_test) + cw.visitAttribute(new TestModuleAttribute(attr)); + else + cw.visitAttribute(new TestPackageAttribute(attr)); + + cw.visitEnd(); + byte[] bytes = cw.toByteArray(); + + + ClassLoader loader = new ClassLoader(ConstModule.class.getClassLoader()) { + @Override + protected Class findClass(String cn)throws ClassNotFoundException { + if (cn.equals(class_name)) { + try { + Class superClass = super.defineClass(cn, bytes, 0, bytes.length); + throw new RuntimeException("Expected ClassFormatError not thrown"); + } catch (java.lang.ClassFormatError e) { + if (!throwCFE) { + throw new RuntimeException("Unexpected ClassFormatError exception: " + e.getMessage()); + } + if (module_test && !e.getMessage().contains( + "Unknown constant tag 19 in class file")) { + throw new RuntimeException("Wrong ClassFormatError exception: " + e.getMessage()); + } else if (!module_test && !e.getMessage().contains( + "Unknown constant tag 20 in class file")) { + throw new RuntimeException("Wrong ClassFormatError exception: " + e.getMessage()); + } + } catch (java.lang.NoClassDefFoundError f) { + if (throwCFE) { + throw new RuntimeException("Unexpected NoClassDefFoundError exception: " + f.getMessage()); + } + if (!f.getMessage().contains( + "is not a class because access_flag ACC_MODULE is set")) { + throw new RuntimeException("Wrong NoClassDefFoundError exception: " + f.getMessage()); + } + } + } else { + throw new ClassNotFoundException(cn); + } + return null; + } + }; + + Class clazz = loader.loadClass(class_name); + } + + /** + * ConstModuleAttr attribute. + * + *
     {@code
    +     *
    +     * MainClass_attribute {
    +     *   // index to CONSTANT_utf8_info structure in constant pool representing
    +     *   // the string "ConstModuleAttr"
    +     *   u2 attribute_name_index;
    +     *   u4 attribute_length;
    +     *
    +     *   // index to CONSTANT_Module_info structure
    +     *   u2 module_name_index
    +     * }
    +     *
    +     * } 
    + */ + public static class TestModuleAttribute extends Attribute { + private final String moduleName; + + public TestModuleAttribute(String moduleName) { + super("ConstModuleAttr"); + this.moduleName = moduleName; + } + + public TestModuleAttribute() { + this(null); + } + + @Override + protected Attribute read(ClassReader cr, + int off, + int len, + char[] buf, + int codeOff, + Label[] labels) + { + String mn = cr.readModule(off, buf); + off += 2; + return new TestModuleAttribute(mn); + } + + @Override + protected ByteVector write(ClassWriter cw, + byte[] code, + int len, + int maxStack, + int maxLocals) + { + ByteVector attr = new ByteVector(); + attr.putShort(cw.newModule(moduleName)); + return attr; + } + } + + /** + * ConstPackageAttr attribute. + * + *
     {@code
    +     *
    +     * MainClass_attribute {
    +     *   // index to CONSTANT_utf8_info structure in constant pool representing
    +     *   // the string "ConstPackageAttr"
    +     *   u2 attribute_name_index;
    +     *   u4 attribute_length;
    +     *
    +     *   // index to CONSTANT_Package_info structure
    +     *   u2 module_name_index
    +     * }
    +     *
    +     * } 
    + */ + public static class TestPackageAttribute extends Attribute { + private final String packageName; + + public TestPackageAttribute(String packageName) { + super("ConstPackageAttr"); + this.packageName = packageName; + } + + public TestPackageAttribute() { + this(null); + } + + @Override + protected Attribute read(ClassReader cr, + int off, + int len, + char[] buf, + int codeOff, + Label[] labels) + { + String mn = cr.readPackage(off, buf); + off += 2; + return new TestPackageAttribute(mn); + } + + @Override + protected ByteVector write(ClassWriter cw, + byte[] code, + int len, + int maxStack, + int maxLocals) + { + ByteVector attr = new ByteVector(); + attr.putShort(cw.newPackage(packageName)); + return attr; + } + } +} diff --git a/hotspot/test/runtime/defineAnonClass/NestedUnsafe.java b/hotspot/test/runtime/defineAnonClass/NestedUnsafe.java index f4a80a61a59..247a42c4291 100644 --- a/hotspot/test/runtime/defineAnonClass/NestedUnsafe.java +++ b/hotspot/test/runtime/defineAnonClass/NestedUnsafe.java @@ -34,11 +34,10 @@ package p; -import java.security.ProtectionDomain; -import java.io.InputStream; import java.lang.*; -import jdk.test.lib.*; + import jdk.internal.misc.Unsafe; +import jdk.test.lib.compiler.InMemoryJavaCompiler; // Test that an anonymous class in package 'p' cannot define its own anonymous class diff --git a/hotspot/test/runtime/defineAnonClass/NestedUnsafe2.java b/hotspot/test/runtime/defineAnonClass/NestedUnsafe2.java index 0d773a56feb..459b9f704b4 100644 --- a/hotspot/test/runtime/defineAnonClass/NestedUnsafe2.java +++ b/hotspot/test/runtime/defineAnonClass/NestedUnsafe2.java @@ -34,11 +34,10 @@ package p; -import java.security.ProtectionDomain; -import java.io.InputStream; import java.lang.*; -import jdk.test.lib.*; + import jdk.internal.misc.Unsafe; +import jdk.test.lib.compiler.InMemoryJavaCompiler; // Test that an anonymous class that gets put in its host's package cannot define diff --git a/hotspot/test/runtime/duplAttributes/DupSignatureAttrs.jcod b/hotspot/test/runtime/duplAttributes/DupSignatureAttrs.jcod new file mode 100644 index 00000000000..b43db02f5b5 --- /dev/null +++ b/hotspot/test/runtime/duplAttributes/DupSignatureAttrs.jcod @@ -0,0 +1,615 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +// Class containing duplicate Signature attributes. Loading it should cause a +// ClassFormatError exception. +class DupClassSigAttrs { + 0xCAFEBABE; + 0; // minor version + 53; // version + [33] { // Constant Pool + ; // first element is empty + Method #6 #17; // #1 at 0x0A + Field #18 #19; // #2 at 0x0F + String #20; // #3 at 0x14 + Method #21 #22; // #4 at 0x17 + class #23; // #5 at 0x1C + class #24; // #6 at 0x1F + Utf8 ""; // #7 at 0x22 + Utf8 "()V"; // #8 at 0x2B + Utf8 "Code"; // #9 at 0x31 + Utf8 "LineNumberTable"; // #10 at 0x38 + Utf8 "main"; // #11 at 0x4A + Utf8 "([Ljava/lang/String;)V"; // #12 at 0x51 + Utf8 "Exceptions"; // #13 at 0x6A + class #25; // #14 at 0x77 + Utf8 "SourceFile"; // #15 at 0x7A + Utf8 "DupClassSigAttrs.java"; // #16 at 0x87 + NameAndType #7 #8; // #17 at 0x9F + class #26; // #18 at 0xA4 + NameAndType #27 #28; // #19 at 0xA7 + Utf8 "hi"; // #20 at 0xAC + class #29; // #21 at 0xB1 + NameAndType #30 #31; // #22 at 0xB4 + Utf8 "DupClassSigAttrs"; // #23 at 0xB9 + Utf8 "java/lang/Object"; // #24 at 0xCC + Utf8 "java/lang/Throwable"; // #25 at 0xDF + Utf8 "java/lang/System"; // #26 at 0xF5 + Utf8 "out"; // #27 at 0x0108 + Utf8 "Ljava/io/PrintStream;"; // #28 at 0x010E + Utf8 "java/io/PrintStream"; // #29 at 0x0126 + Utf8 "println"; // #30 at 0x013C + Utf8 "(Ljava/lang/String;)V"; // #31 at 0x0146 + Utf8 "Signature"; // #32 at 0x015E + } // Constant Pool + + 0x0021; // access + #5;// this_cpx + #6;// super_cpx + + [0] { // Interfaces + } // Interfaces + + [0] { // fields + } // fields + + [2] { // methods + { // Member at 0x0176 + 0x0001; // access + #7; // name_cpx + #8; // sig_cpx + [1] { // Attributes + Attr(#9, 29) { // Code at 0x017E + 1; // max_stack + 1; // max_locals + Bytes[5]{ + 0x2AB70001B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#10, 6) { // LineNumberTable at 0x0195 + [1] { // LineNumberTable + 0 1; // at 0x01A1 + } + } // end LineNumberTable + } // Attributes + } // end Code + } // Attributes + } // Member + ; + { // Member at 0x01A1 + 0x0009; // access + #11; // name_cpx + #12; // sig_cpx + [2] { // Attributes + Attr(#9, 37) { // Code at 0x01A9 + 2; // max_stack + 1; // max_locals + Bytes[9]{ + 0xB200021203B60004; + 0xB1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#10, 10) { // LineNumberTable at 0x01C4 + [2] { // LineNumberTable + 0 4; // at 0x01D0 + 8 5; // at 0x01D4 + } + } // end LineNumberTable + } // Attributes + } // end Code + ; + Attr(#13, 4) { // Exceptions at 0x01D4 + [1] { // Exceptions + #14; // at 0x01DE + } + } // end Exceptions + } // Attributes + } // Member + } // methods + + [3] { // Attributes + Attr(#15, 2) { // SourceFile at 0x01E0 + #16; + } // end SourceFile + ; + Attr(#32, 2) { // Signature at 0x01E8 + #16; + } // end Signature + ; + Attr(#32, 2) { // *** Duplicate *** Signature at 0x01F0 + #16; + } // end Signature + } // Attributes +} // end class DupClassSigAttrs + + +// Class containing a method with duplicate Signature attributes. Loading it +// should cause a ClassFormatError exception. +class DupMthSigAttrs { + 0xCAFEBABE; + 0; // minor version + 53; // version + [33] { // Constant Pool + ; // first element is empty + Method #6 #17; // #1 at 0x0A + Field #18 #19; // #2 at 0x0F + String #20; // #3 at 0x14 + Method #21 #22; // #4 at 0x17 + class #23; // #5 at 0x1C + class #24; // #6 at 0x1F + Utf8 ""; // #7 at 0x22 + Utf8 "()V"; // #8 at 0x2B + Utf8 "Code"; // #9 at 0x31 + Utf8 "LineNumberTable"; // #10 at 0x38 + Utf8 "main"; // #11 at 0x4A + Utf8 "([Ljava/lang/String;)V"; // #12 at 0x51 + Utf8 "Exceptions"; // #13 at 0x6A + class #25; // #14 at 0x77 + Utf8 "SourceFile"; // #15 at 0x7A + Utf8 "DupMthSigAttrs.java"; // #16 at 0x87 + NameAndType #7 #8; // #17 at 0x9D + class #26; // #18 at 0xA2 + NameAndType #27 #28; // #19 at 0xA5 + Utf8 "hi"; // #20 at 0xAA + class #29; // #21 at 0xAF + NameAndType #30 #31; // #22 at 0xB2 + Utf8 "DupMthSigAttrs"; // #23 at 0xB7 + Utf8 "java/lang/Object"; // #24 at 0xC8 + Utf8 "java/lang/Throwable"; // #25 at 0xDB + Utf8 "java/lang/System"; // #26 at 0xF1 + Utf8 "out"; // #27 at 0x0104 + Utf8 "Ljava/io/PrintStream;"; // #28 at 0x010A + Utf8 "java/io/PrintStream"; // #29 at 0x0122 + Utf8 "println"; // #30 at 0x0138 + Utf8 "(Ljava/lang/String;)V"; // #31 at 0x0142 + Utf8 "Signature"; // #32 at 0x015A + } // Constant Pool + + 0x0021; // access + #5;// this_cpx + #6;// super_cpx + + [0] { // Interfaces + } // Interfaces + + [0] { // fields + } // fields + + [2] { // methods + { // Member at 0x0172 + 0x0001; // access + #7; // name_cpx + #8; // sig_cpx + [1] { // Attributes + Attr(#9, 29) { // Code at 0x017A + 1; // max_stack + 1; // max_locals + Bytes[5]{ + 0x2AB70001B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#10, 6) { // LineNumberTable at 0x0191 + [1] { // LineNumberTable + 0 1; // at 0x019D + } + } // end LineNumberTable + } // Attributes + } // end Code + } // Attributes + } // Member + ; + { // Member at 0x019D + 0x0009; // access + #11; // name_cpx + #12; // sig_cpx + [4] { // Attributes + Attr(#9, 37) { // Code at 0x01A5 + 2; // max_stack + 1; // max_locals + Bytes[9]{ + 0xB200021203B60004; + 0xB1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#10, 10) { // LineNumberTable at 0x01C0 + [2] { // LineNumberTable + 0 4; // at 0x01CC + 8 5; // at 0x01D0 + } + } // end LineNumberTable + } // Attributes + } // end Code + ; + Attr(#32, 2) { // Signature at 0x01D0 + #16; + } // end Signature + ; + Attr(#13, 4) { // Exceptions at 0x01D8 + [1] { // Exceptions + #14; // at 0x01E2 + } + } // end Exceptions + ; + Attr(#32, 2) { // *** Duplicate *** Signature at 0x01E2 + #16; + } // end Signature + } // Attributes + } // Member + } // methods + + [1] { // Attributes + Attr(#15, 2) { // SourceFile at 0x01EC + #16; + } // end SourceFile + } // Attributes +} // end class DupMthSigAttrs + + +// Class containing a field with duplicate Signature attributes. Loading it +// should cause a ClassFormatError exception. +class DupFldSigAttrs { + 0xCAFEBABE; + 0; // minor version + 53; // version + [42] { // Constant Pool + ; // first element is empty + Method #9 #23; // #1 at 0x0A + Field #24 #25; // #2 at 0x0F + Field #8 #26; // #3 at 0x14 + Method #27 #28; // #4 at 0x19 + class #29; // #5 at 0x1E + String #30; // #6 at 0x21 + Method #5 #31; // #7 at 0x24 + class #32; // #8 at 0x29 + class #33; // #9 at 0x2C + Utf8 "str"; // #10 at 0x2F + Utf8 "Ljava/lang/String;"; // #11 at 0x35 + Utf8 ""; // #12 at 0x4A + Utf8 "()V"; // #13 at 0x53 + Utf8 "Code"; // #14 at 0x59 + Utf8 "LineNumberTable"; // #15 at 0x60 + Utf8 "main"; // #16 at 0x72 + Utf8 "([Ljava/lang/String;)V"; // #17 at 0x79 + Utf8 "Exceptions"; // #18 at 0x92 + class #34; // #19 at 0x9F + Utf8 ""; // #20 at 0xA2 + Utf8 "SourceFile"; // #21 at 0xAD + Utf8 "DupFldSigAttrs.java"; // #22 at 0xBA + NameAndType #12 #13; // #23 at 0xD0 + class #35; // #24 at 0xD5 + NameAndType #36 #37; // #25 at 0xD8 + NameAndType #10 #11; // #26 at 0xDD + class #38; // #27 at 0xE2 + NameAndType #39 #40; // #28 at 0xE5 + Utf8 "java/lang/String"; // #29 at 0xEA + Utf8 "Hi"; // #30 at 0xFD + NameAndType #12 #40; // #31 at 0x0102 + Utf8 "DupFldSigAttrs"; // #32 at 0x0107 + Utf8 "java/lang/Object"; // #33 at 0x0118 + Utf8 "java/lang/Throwable"; // #34 at 0x012B + Utf8 "java/lang/System"; // #35 at 0x0141 + Utf8 "out"; // #36 at 0x0154 + Utf8 "Ljava/io/PrintStream;"; // #37 at 0x015A + Utf8 "java/io/PrintStream"; // #38 at 0x0172 + Utf8 "println"; // #39 at 0x0188 + Utf8 "(Ljava/lang/String;)V"; // #40 at 0x0192 + Utf8 "Signature"; // #41 at 0x01AA + } // Constant Pool + + 0x0021; // access + #8;// this_cpx + #9;// super_cpx + + [0] { // Interfaces + } // Interfaces + + [1] { // fields + { // Member at 0x01C0 + 0x0008; // access + #10; // name_cpx + #11; // sig_cpx + [2] { // Attributes + Attr(#41, 2) { // Signature at 0x01C8 + #16; + } // end Signature + ; + Attr(#41, 2) { // *** Duplicate *** Signature at 0x01D0 + #16; + } // end Signature + } // Attributes + } // Member + } // fields + + [3] { // methods + { // Member at 0x01DA + 0x0001; // access + #12; // name_cpx + #13; // sig_cpx + [1] { // Attributes + Attr(#14, 29) { // Code at 0x01E2 + 1; // max_stack + 1; // max_locals + Bytes[5]{ + 0x2AB70001B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#15, 6) { // LineNumberTable at 0x01F9 + [1] { // LineNumberTable + 0 1; // at 0x0205 + } + } // end LineNumberTable + } // Attributes + } // end Code + } // Attributes + } // Member + ; + { // Member at 0x0205 + 0x0009; // access + #16; // name_cpx + #17; // sig_cpx + [2] { // Attributes + Attr(#14, 38) { // Code at 0x020D + 2; // max_stack + 1; // max_locals + Bytes[10]{ + 0xB20002B20003B600; + 0x04B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#15, 10) { // LineNumberTable at 0x0229 + [2] { // LineNumberTable + 0 6; // at 0x0235 + 9 7; // at 0x0239 + } + } // end LineNumberTable + } // Attributes + } // end Code + ; + Attr(#18, 4) { // Exceptions at 0x0239 + [1] { // Exceptions + #19; // at 0x0243 + } + } // end Exceptions + } // Attributes + } // Member + ; + { // Member at 0x0243 + 0x0008; // access + #20; // name_cpx + #13; // sig_cpx + [1] { // Attributes + Attr(#14, 37) { // Code at 0x024B + 3; // max_stack + 0; // max_locals + Bytes[13]{ + 0xBB0005591206B700; + 0x07B30003B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#15, 6) { // LineNumberTable at 0x026A + [1] { // LineNumberTable + 0 3; // at 0x0276 + } + } // end LineNumberTable + } // Attributes + } // end Code + } // Attributes + } // Member + } // methods + + [1] { // Attributes + Attr(#21, 2) { // SourceFile at 0x0278 + #22; + } // end SourceFile + } // Attributes +} // end class DupFldSigAttrs + + +// Class containing a Signature attribute and a field and methods with Signature +// attributes. Since neither the class nor any of its fields or methods have +// duplicate Signature attributes, loading this class should not cause a +// ClassFormatError exception. +class OkaySigAttrs { + 0xCAFEBABE; + 0; // minor version + 53; // version + [42] { // Constant Pool + ; // first element is empty + Method #9 #23; // #1 at 0x0A + Field #24 #25; // #2 at 0x0F + Field #8 #26; // #3 at 0x14 + Method #27 #28; // #4 at 0x19 + class #29; // #5 at 0x1E + String #30; // #6 at 0x21 + Method #5 #31; // #7 at 0x24 + class #32; // #8 at 0x29 + class #33; // #9 at 0x2C + Utf8 "str"; // #10 at 0x2F + Utf8 "Ljava/lang/String;"; // #11 at 0x35 + Utf8 ""; // #12 at 0x4A + Utf8 "()V"; // #13 at 0x53 + Utf8 "Code"; // #14 at 0x59 + Utf8 "LineNumberTable"; // #15 at 0x60 + Utf8 "main"; // #16 at 0x72 + Utf8 "([Ljava/lang/String;)V"; // #17 at 0x79 + Utf8 "Exceptions"; // #18 at 0x92 + class #34; // #19 at 0x9F + Utf8 ""; // #20 at 0xA2 + Utf8 "SourceFile"; // #21 at 0xAD + Utf8 "OkaySigAttrs.java"; // #22 at 0xBA + NameAndType #12 #13; // #23 at 0xCE + class #35; // #24 at 0xD3 + NameAndType #36 #37; // #25 at 0xD6 + NameAndType #10 #11; // #26 at 0xDB + class #38; // #27 at 0xE0 + NameAndType #39 #40; // #28 at 0xE3 + Utf8 "java/lang/String"; // #29 at 0xE8 + Utf8 "Hi"; // #30 at 0xFB + NameAndType #12 #40; // #31 at 0x0100 + Utf8 "OkaySigAttrs"; // #32 at 0x0105 + Utf8 "java/lang/Object"; // #33 at 0x0114 + Utf8 "java/lang/Throwable"; // #34 at 0x0127 + Utf8 "java/lang/System"; // #35 at 0x013D + Utf8 "out"; // #36 at 0x0150 + Utf8 "Ljava/io/PrintStream;"; // #37 at 0x0156 + Utf8 "java/io/PrintStream"; // #38 at 0x016E + Utf8 "println"; // #39 at 0x0184 + Utf8 "(Ljava/lang/String;)V"; // #40 at 0x018E + Utf8 "Signature"; // #41 at 0x01A6 + } // Constant Pool + + 0x0021; // access + #8;// this_cpx + #9;// super_cpx + + [0] { // Interfaces + } // Interfaces + + [1] { // fields + { // Member at 0x01BC + 0x0008; // access + #10; // name_cpx + #11; // sig_cpx + [1] { // Attributes + Attr(#41, 2) { // Signature at 0x01C4 + #16; + } // end Signature + } // Attributes + } // Member + } // fields + + [3] { // methods + { // Member at 0x01CE + 0x0001; // access + #12; // name_cpx + #13; // sig_cpx + [2] { // Attributes + Attr(#14, 29) { // Code at 0x01D6 + 1; // max_stack + 1; // max_locals + Bytes[5]{ + 0x2AB70001B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#15, 6) { // LineNumberTable at 0x01ED + [1] { // LineNumberTable + 0 1; // at 0x01F9 + } + } // end LineNumberTable + } // Attributes + } // end Code + ; + Attr(#41, 2) { // Signature at 0x01F9 + #16; + } // end Signature + } // Attributes + } // Member + ; + { // Member at 0x0201 + 0x0009; // access + #16; // name_cpx + #17; // sig_cpx + [3] { // Attributes + Attr(#14, 38) { // Code at 0x0209 + 2; // max_stack + 1; // max_locals + Bytes[10]{ + 0xB20002B20003B600; + 0x04B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#15, 10) { // LineNumberTable at 0x0225 + [2] { // LineNumberTable + 0 6; // at 0x0231 + 9 7; // at 0x0235 + } + } // end LineNumberTable + } // Attributes + } // end Code + ; + Attr(#41, 2) { // Signature at 0x0235 + #16; + } // end Signature + ; + Attr(#18, 4) { // Exceptions at 0x023D + [1] { // Exceptions + #19; // at 0x0247 + } + } // end Exceptions + } // Attributes + } // Member + ; + { // Member at 0x0247 + 0x0008; // access + #20; // name_cpx + #13; // sig_cpx + [1] { // Attributes + Attr(#14, 37) { // Code at 0x024F + 3; // max_stack + 0; // max_locals + Bytes[13]{ + 0xBB0005591206B700; + 0x07B30003B1; + }; + [0] { // Traps + } // end Traps + [1] { // Attributes + Attr(#15, 6) { // LineNumberTable at 0x026E + [1] { // LineNumberTable + 0 3; // at 0x027A + } + } // end LineNumberTable + } // Attributes + } // end Code + } // Attributes + } // Member + } // methods + + [2] { // Attributes + Attr(#21, 2) { // SourceFile at 0x027C + #22; + } // end SourceFile + ; + Attr(#41, 2) { // Signature at 0x0284 + #16; + } // end Signature + } // Attributes +} // end class OkaySigAttrs diff --git a/hotspot/test/runtime/duplAttributes/TestDupSignatureAttr.java b/hotspot/test/runtime/duplAttributes/TestDupSignatureAttr.java new file mode 100644 index 00000000000..856d0617d59 --- /dev/null +++ b/hotspot/test/runtime/duplAttributes/TestDupSignatureAttr.java @@ -0,0 +1,63 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176147 + * @summary Throw ClassFormatError exception for multiple Signature attributes + * @compile DupSignatureAttrs.jcod + * @run main TestDupSignatureAttr + */ + +public class TestDupSignatureAttr { + public static void main(String args[]) throws Throwable { + + System.out.println("Regression test for bug 8176147"); + + String[] badClasses = new String[] { + "DupClassSigAttrs", + "DupMthSigAttrs", + "DupFldSigAttrs", + }; + String[] messages = new String[] { + "Multiple Signature attributes in class file", + "Multiple Signature attributes for method", + "Multiple Signature attributes for field", + }; + + for (int x = 0; x < badClasses.length; x++) { + try { + Class newClass = Class.forName(badClasses[x]); + throw new RuntimeException("Expected ClassFormatError exception not thrown"); + } catch (java.lang.ClassFormatError e) { + if (!e.getMessage().contains(messages[x])) { + throw new RuntimeException("Wrong ClassFormatError exception thrown: " + + e.getMessage()); + } + } + } + + // Multiple Signature attributes but no duplicates. + Class newClass = Class.forName("OkaySigAttrs"); + } +} diff --git a/hotspot/test/runtime/getSysPackage/GetSysPkgTest.java b/hotspot/test/runtime/getSysPackage/GetSysPkgTest.java index d3f3ca700d6..75360e2e394 100644 --- a/hotspot/test/runtime/getSysPackage/GetSysPkgTest.java +++ b/hotspot/test/runtime/getSysPackage/GetSysPkgTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,7 +33,7 @@ import java.io.File; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.ProcessTools; import jdk.test.lib.process.OutputAnalyzer; @@ -55,7 +55,7 @@ public class GetSysPkgTest { return m; } } - throw new RuntimeException("Failed to find method " + name + " in java.lang.reflect.Module"); + throw new RuntimeException("Failed to find method " + name + " in java.lang.Module"); } // Throw RuntimeException if getSystemPackageLocation() does not return diff --git a/hotspot/test/runtime/jni/CallWithJNIWeak/CallWithJNIWeak.java b/hotspot/test/runtime/jni/CallWithJNIWeak/CallWithJNIWeak.java new file mode 100644 index 00000000000..3aaec5e4fd5 --- /dev/null +++ b/hotspot/test/runtime/jni/CallWithJNIWeak/CallWithJNIWeak.java @@ -0,0 +1,72 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8166188 + * @summary Test call of native function with JNI weak global ref. + * @modules java.base + * @run main/othervm/native CallWithJNIWeak + */ + +public class CallWithJNIWeak { + static { + System.loadLibrary("CallWithJNIWeak"); + } + + private static native void testJNIFieldAccessors(CallWithJNIWeak o); + + // The field initializations must be kept in sync with the JNI code + // which reads verifies the values of these fields. + private int i = 1; + private long j = 2; + private boolean z = true; + private char c = 'a'; + private short s = 3; + private float f = 1.0f; + private double d = 2.0; + private Object l; + + private CallWithJNIWeak() { + this.l = this; + } + + private native void weakReceiverTest0(); + private void weakReceiverTest() { + weakReceiverTest0(); + } + + private synchronized void synchonizedWeakReceiverTest() { + this.notifyAll(); + } + + + private static native void runTests(CallWithJNIWeak o); + + public static void main(String[] args) { + CallWithJNIWeak w = new CallWithJNIWeak(); + for (int i = 0; i < 20000; i++) { + runTests(w); + } + } +} diff --git a/hotspot/test/runtime/jni/CallWithJNIWeak/libCallWithJNIWeak.c b/hotspot/test/runtime/jni/CallWithJNIWeak/libCallWithJNIWeak.c new file mode 100644 index 00000000000..83a5784c1e8 --- /dev/null +++ b/hotspot/test/runtime/jni/CallWithJNIWeak/libCallWithJNIWeak.c @@ -0,0 +1,142 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +#include + +/* + * Class: CallWithJNIWeak + * Method: testJNIFieldAccessors + * Signature: (LCallWithJNIWeak;)V + */ +JNIEXPORT void JNICALL +Java_CallWithJNIWeak_testJNIFieldAccessors(JNIEnv *env, jclass clazz, jobject this) { + // Make sure that we have a weak reference to the receiver + + jweak self = (*env)->NewWeakGlobalRef(env, this); + + jclass this_class = (*env)->GetObjectClass(env, self); + + jclass exception = (*env)->FindClass(env, "java/lang/RuntimeException"); + + jfieldID id_i = (*env)->GetFieldID(env, this_class, "i", "I"); + jfieldID id_j = (*env)->GetFieldID(env, this_class, "j", "J"); + jfieldID id_z = (*env)->GetFieldID(env, this_class, "z", "Z"); + jfieldID id_c = (*env)->GetFieldID(env, this_class, "c", "C"); + jfieldID id_s = (*env)->GetFieldID(env, this_class, "s", "S"); + jfieldID id_f = (*env)->GetFieldID(env, this_class, "f", "F"); + jfieldID id_d = (*env)->GetFieldID(env, this_class, "d", "D"); + jfieldID id_l = (*env)->GetFieldID(env, this_class, "l", "Ljava/lang/Object;"); + jvalue v; + +#define CHECK(variable, expected) \ + do { \ + if ((variable) != (expected)) { \ + (*env)->ThrowNew(env, exception, #variable" != " #expected); \ + return; \ + } \ + } while(0) + + // The values checked below must be kept in sync with the Java source file. + + v.i = (*env)->GetIntField(env, self, id_i); + CHECK(v.i, 1); + + v.j = (*env)->GetLongField(env, self, id_j); + CHECK(v.j, 2); + + v.z = (*env)->GetBooleanField(env, self, id_z); + CHECK(v.z, JNI_TRUE); + + v.c = (*env)->GetCharField(env, self, id_c); + CHECK(v.c, 'a'); + + v.s = (*env)->GetShortField(env, self, id_s); + CHECK(v.s, 3); + + v.f = (*env)->GetFloatField(env, self, id_f); + CHECK(v.f, 1.0f); + + v.d = (*env)->GetDoubleField(env, self, id_d); + CHECK(v.d, 2.0); + +#undef CHECK + + v.l = (*env)->GetObjectField(env, self, id_l); + if (v.l == NULL) { + (*env)->ThrowNew(env, exception, "Object field was null"); + return; + } + { + jclass clz = (*env)->GetObjectClass(env, v.l); + if (!(*env)->IsSameObject(env, clazz, clz)) { + (*env)->ThrowNew(env, exception, "Bad object class"); + } + } + + (*env)->DeleteWeakGlobalRef(env, self); +} + +/* + * Class: CallWithJNIWeak + * Method: runTests + * Signature: (LCallWithJNIWeak;)V + */ +JNIEXPORT void JNICALL +Java_CallWithJNIWeak_runTests(JNIEnv *env, jclass clazz, jobject this) { + jweak that = (*env)->NewWeakGlobalRef(env, this); + { + jmethodID method = (*env)->GetStaticMethodID(env, + clazz, "testJNIFieldAccessors", "(LCallWithJNIWeak;)V"); + (*env)->CallStaticVoidMethod(env, clazz, method, that); + if ((*env)->ExceptionCheck(env)) { + return; + } + } + + { + jmethodID method = (*env)->GetMethodID(env, clazz, "weakReceiverTest", "()V"); + (*env)->CallVoidMethod(env, that, method); + if ((*env)->ExceptionCheck(env)) { + return; + } + } + + { + jmethodID method = (*env)->GetMethodID(env, clazz, "synchonizedWeakReceiverTest", "()V"); + (*env)->CallVoidMethod(env, that, method); + if ((*env)->ExceptionCheck(env)) { + return; + } + } + (*env)->DeleteWeakGlobalRef(env, that); +} + +/* + * Class: CallWithJNIWeak + * Method: weakReceiverTest0 + * Signature: ()V + */ +JNIEXPORT void JNICALL +Java_CallWithJNIWeak_weakReceiverTest0(JNIEnv *env, jobject obj) { + (*env)->GetObjectClass(env, obj); +} diff --git a/hotspot/test/runtime/jni/ReturnJNIWeak/ReturnJNIWeak.java b/hotspot/test/runtime/jni/ReturnJNIWeak/ReturnJNIWeak.java new file mode 100644 index 00000000000..6d581000fb8 --- /dev/null +++ b/hotspot/test/runtime/jni/ReturnJNIWeak/ReturnJNIWeak.java @@ -0,0 +1,132 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* @test + * @bug 8166188 + * @requires vm.opt.ExplicitGCInvokesConcurrent != true + * @summary Test return of JNI weak global refs from native calls. + * @modules java.base + * @run main/othervm/native -Xint ReturnJNIWeak + * @run main/othervm/native -Xcomp ReturnJNIWeak + */ + +public final class ReturnJNIWeak { + + static { + System.loadLibrary("ReturnJNIWeak"); + } + + private static final class TestObject { + public final int value; + + public TestObject(int value) { + this.value = value; + } + } + + private static volatile TestObject testObject = null; + + private static native void registerObject(Object o); + private static native void unregisterObject(); + private static native Object getObject(); + + // Create the test object and record it both strongly and weakly. + private static void remember(int value) { + TestObject o = new TestObject(value); + registerObject(o); + testObject = o; + } + + // Remove both strong and weak references to the current test object. + private static void forget() { + unregisterObject(); + testObject = null; + } + + // Verify the weakly recorded object + private static void checkValue(int value) throws Exception { + Object o = getObject(); + if (o == null) { + throw new RuntimeException("Weak reference unexpectedly null"); + } + TestObject t = (TestObject)o; + if (t.value != value) { + throw new RuntimeException("Incorrect value"); + } + } + + // Verify we can create a weak reference and get it back. + private static void testSanity() throws Exception { + System.out.println("running testSanity"); + int value = 5; + try { + remember(value); + checkValue(value); + } finally { + forget(); + } + } + + // Verify weak ref value survives across collection if strong ref exists. + private static void testSurvival() throws Exception { + System.out.println("running testSurvival"); + int value = 10; + try { + remember(value); + checkValue(value); + System.gc(); + // Verify weak ref still has expected value. + checkValue(value); + } finally { + forget(); + } + } + + // Verify weak ref cleared if no strong ref exists. + private static void testClear() throws Exception { + System.out.println("running testClear"); + int value = 15; + try { + remember(value); + checkValue(value); + // Verify still good. + checkValue(value); + // Drop reference. + testObject = null; + System.gc(); + // Verify weak ref cleared as expected. + Object recorded = getObject(); + if (recorded != null) { + throw new RuntimeException("expected clear"); + } + } finally { + forget(); + } + } + + public static void main(String[] args) throws Exception { + testSanity(); + testSurvival(); + testClear(); + } +} diff --git a/hotspot/test/runtime/jni/ReturnJNIWeak/libReturnJNIWeak.c b/hotspot/test/runtime/jni/ReturnJNIWeak/libReturnJNIWeak.c new file mode 100644 index 00000000000..12d7ae92e6e --- /dev/null +++ b/hotspot/test/runtime/jni/ReturnJNIWeak/libReturnJNIWeak.c @@ -0,0 +1,52 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * Native support for ReturnJNIWeak test. + */ + +#include "jni.h" + +static jweak registered = NULL; + +JNIEXPORT void JNICALL +Java_ReturnJNIWeak_registerObject(JNIEnv* env, + jclass jclazz, + jobject value) { + // assert registered == NULL + registered = (*env)->NewWeakGlobalRef(env, value); +} + +JNIEXPORT void JNICALL +Java_ReturnJNIWeak_unregisterObject(JNIEnv* env, jclass jclazz) { + if (registered != NULL) { + (*env)->DeleteWeakGlobalRef(env, registered); + registered = NULL; + } +} + +JNIEXPORT jobject JNICALL +Java_ReturnJNIWeak_getObject(JNIEnv* env, jclass jclazz) { + // assert registered != NULL + return registered; +} diff --git a/hotspot/test/runtime/libadimalloc.solaris.sparc/Testlibadimalloc.java b/hotspot/test/runtime/libadimalloc.solaris.sparc/Testlibadimalloc.java index 9d744f22f40..1c3220333d4 100644 --- a/hotspot/test/runtime/libadimalloc.solaris.sparc/Testlibadimalloc.java +++ b/hotspot/test/runtime/libadimalloc.solaris.sparc/Testlibadimalloc.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -67,7 +67,7 @@ public class Testlibadimalloc { // Start the process, get the pid and then wait for the test to finish Process process = builder.start(); - long pid = process.getPid(); + long pid = process.pid(); int retval = process.waitFor(); // make sure the SEGVOverflow test crashed diff --git a/hotspot/test/runtime/logging/ModulesTest.java b/hotspot/test/runtime/logging/ModulesTest.java index 58b94cc3579..0a469d30fec 100644 --- a/hotspot/test/runtime/logging/ModulesTest.java +++ b/hotspot/test/runtime/logging/ModulesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @summary modules=debug should have logging from statements in the code + * @summary -Xlog:module should emit logging output * @library /test/lib * @modules java.base/jdk.internal.misc * java.management @@ -35,9 +35,16 @@ import jdk.test.lib.process.ProcessTools; public class ModulesTest { public static void main(String[] args) throws Exception { - ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( - "-Xlog:modules=trace", "-version"); - OutputAnalyzer output = new OutputAnalyzer(pb.start()); + testModuleTrace("-Xlog:module=trace", "-version"); + testModuleLoad("-Xlog:module+load", "-version"); + testModuleUnload("-Xlog:module+unload", "-version"); + + // same as -Xlog:module+load -Xlog:module+unload + testModuleLoad("-verbose:module", "-version"); + } + + static void testModuleTrace(String... args) throws Exception { + OutputAnalyzer output = run(args); output.shouldContain("define_javabase_module(): Definition of module:"); output.shouldContain("define_javabase_module(): creation of package"); output.shouldContain("define_module(): creation of module"); @@ -48,5 +55,22 @@ public class ModulesTest { output.shouldContain("Setting package: class:"); output.shouldHaveExitValue(0); } + + static void testModuleLoad(String... args) throws Exception { + OutputAnalyzer output = run(args); + output.shouldContain("java.base location:"); + output.shouldContain("java.management location:"); + output.shouldHaveExitValue(0); + } + + static void testModuleUnload(String... args) throws Exception { + OutputAnalyzer output = run(args); + output.shouldHaveExitValue(0); + } + + static OutputAnalyzer run(String... args) throws Exception { + ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(args); + return new OutputAnalyzer(pb.start()); + } } diff --git a/hotspot/test/runtime/logging/StartupTimeTest.java b/hotspot/test/runtime/logging/StartupTimeTest.java index 4448caeac07..4069b02401e 100644 --- a/hotspot/test/runtime/logging/StartupTimeTest.java +++ b/hotspot/test/runtime/logging/StartupTimeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -57,7 +57,7 @@ public class StartupTimeTest { static void analyzeModulesOutputOff(ProcessBuilder pb) throws Exception { OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldNotContain("[modules,startuptime]"); + output.shouldNotContain("[module,startuptime]"); output.shouldHaveExitValue(0); } @@ -70,11 +70,11 @@ public class StartupTimeTest { InnerClass.class.getName()); analyzeOutputOff(pb); - pb = ProcessTools.createJavaProcessBuilder("-Xlog:startuptime+modules", + pb = ProcessTools.createJavaProcessBuilder("-Xlog:startuptime+module", InnerClass.class.getName()); analyzeModulesOutputOn(pb); - pb = ProcessTools.createJavaProcessBuilder("-Xlog:startuptime+modules=off", + pb = ProcessTools.createJavaProcessBuilder("-Xlog:startuptime+module=off", InnerClass.class.getName()); analyzeModulesOutputOff(pb); } diff --git a/hotspot/test/runtime/logging/ThreadLoggingTest.java b/hotspot/test/runtime/logging/ThreadLoggingTest.java index 1f06e0594d9..80b8cc6e3d8 100644 --- a/hotspot/test/runtime/logging/ThreadLoggingTest.java +++ b/hotspot/test/runtime/logging/ThreadLoggingTest.java @@ -9,7 +9,7 @@ * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * diff --git a/hotspot/test/runtime/logging/p2/B.jcod b/hotspot/test/runtime/logging/p2/B.jcod index 724c180aa16..b30d1e32876 100644 --- a/hotspot/test/runtime/logging/p2/B.jcod +++ b/hotspot/test/runtime/logging/p2/B.jcod @@ -8,7 +8,7 @@ * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * diff --git a/hotspot/test/runtime/modules/AccModuleTest.java b/hotspot/test/runtime/modules/AccModuleTest.java index 8deac7f327e..84e2de3552f 100644 --- a/hotspot/test/runtime/modules/AccModuleTest.java +++ b/hotspot/test/runtime/modules/AccModuleTest.java @@ -28,8 +28,6 @@ * @run main AccModuleTest */ -import java.io.File; - public class AccModuleTest { public static void main(String args[]) throws Throwable { diff --git a/hotspot/test/runtime/modules/AccessCheck/AccessExportTwice.java b/hotspot/test/runtime/modules/AccessCheck/AccessExportTwice.java index a1eb2cce85d..465c709fd86 100644 --- a/hotspot/test/runtime/modules/AccessCheck/AccessExportTwice.java +++ b/hotspot/test/runtime/modules/AccessCheck/AccessExportTwice.java @@ -39,8 +39,6 @@ import static jdk.test.lib.Asserts.*; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.HashMap; import java.util.Map; import java.util.Set; @@ -58,7 +56,7 @@ import myloaders.MySameClassLoader; public class AccessExportTwice { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publicly defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { @@ -68,7 +66,7 @@ public class AccessExportTwice { // Packages: none // Packages exported: none ModuleDescriptor descriptor_first_mod = - ModuleDescriptor.module("first_mod") + ModuleDescriptor.newModule("first_mod") .requires("java.base") .requires("second_mod") .build(); @@ -78,7 +76,7 @@ public class AccessExportTwice { // Packages: p2 // Packages exported: p2 is exported to first_mod ModuleDescriptor descriptor_second_mod = - ModuleDescriptor.module("second_mod") + ModuleDescriptor.newModule("second_mod") .requires("java.base") .exports("p2", Set.of("first_mod")) .build(); @@ -87,17 +85,17 @@ public class AccessExportTwice { ModuleFinder finder = ModuleLibrary.of(descriptor_first_mod, descriptor_second_mod); // Resolves "first_mod" - Configuration cf = Layer.boot() + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("first_mod")); + .resolve(finder, ModuleFinder.of(), Set.of("first_mod")); // Map each module to the same class loader Map map = new HashMap<>(); map.put("first_mod", MySameClassLoader.loader1); map.put("second_mod", MySameClassLoader.loader1); - // Create Layer that contains first_mod & second_mod - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains first_mod & second_mod + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); assertTrue(layer.findLoader("first_mod") == MySameClassLoader.loader1); assertTrue(layer.findLoader("second_mod") == MySameClassLoader.loader1); diff --git a/hotspot/test/runtime/modules/AccessCheck/AccessReadTwice.java b/hotspot/test/runtime/modules/AccessCheck/AccessReadTwice.java index 5d1a690a740..74752d3d136 100644 --- a/hotspot/test/runtime/modules/AccessCheck/AccessReadTwice.java +++ b/hotspot/test/runtime/modules/AccessCheck/AccessReadTwice.java @@ -39,8 +39,6 @@ import static jdk.test.lib.Asserts.*; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.HashMap; import java.util.Map; import java.util.Set; @@ -56,7 +54,7 @@ import java.util.Set; public class AccessReadTwice { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publicly defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { @@ -66,9 +64,9 @@ public class AccessReadTwice { // Packages: p1, p4 // Packages exported: none ModuleDescriptor descriptor_first_mod = - ModuleDescriptor.module("first_mod") + ModuleDescriptor.newModule("first_mod") .requires("java.base") - .contains(Set.of("p1", "p4")) + .packages(Set.of("p1", "p4")) .build(); // Define module: second_mod @@ -76,7 +74,7 @@ public class AccessReadTwice { // Packages: p2 // Packages exported: p2 is exported to first_mod ModuleDescriptor descriptor_second_mod = - ModuleDescriptor.module("second_mod") + ModuleDescriptor.newModule("second_mod") .requires("java.base") .exports("p2", Set.of("first_mod")) .build(); @@ -85,9 +83,9 @@ public class AccessReadTwice { ModuleFinder finder = ModuleLibrary.of(descriptor_first_mod, descriptor_second_mod); // Resolves "first_mod" and "second_mod" - Configuration cf = Layer.boot() + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("first_mod", "second_mod")); + .resolve(finder, ModuleFinder.of(), Set.of("first_mod", "second_mod")); // Map each module to this class loader Map map = new HashMap<>(); @@ -95,8 +93,8 @@ public class AccessReadTwice { map.put("first_mod", loader); map.put("second_mod", loader); - // Create Layer that contains first_mod & second_mod - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains first_mod & second_mod + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); assertTrue(layer.findLoader("first_mod") == loader); assertTrue(layer.findLoader("second_mod") == loader); diff --git a/hotspot/test/runtime/modules/AccessCheck/CheckRead.java b/hotspot/test/runtime/modules/AccessCheck/CheckRead.java index 6143f0b94b0..bc8aaeed8bd 100644 --- a/hotspot/test/runtime/modules/AccessCheck/CheckRead.java +++ b/hotspot/test/runtime/modules/AccessCheck/CheckRead.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if module m1 can not read module m2, then class p1.c1 - * in module m1 can not access p2.c2 in module m2. + * @summary Test that if module m1x can not read module m2x, then class p1.c1 + * in module m1x can not access p2.c2 in module m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,82 +46,82 @@ import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// defines m2 --> packages p2 -// defines m3 --> packages p3 +// ClassLoader1 --> defines m1x --> packages p1 +// defines m2x --> packages p2 +// defines m3x --> packages p3 // -// m1 can not read m2 -// package p2 in m2 is exported to m1 +// m1x can not read m2x +// package p2 in m2x is exported to m1x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2. -// Access denied since m1 can not read m2. +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x. +// Access denied since m1x can not read m2x. // public class CheckRead { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publicly defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m3 + // Define module: m1x + // Can read: java.base, m3x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m3") + .requires("m3x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 - // Packages exported: p2 is exported to m1 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: p2 is exported to m1x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m1")) + .exports("p2", Set.of("m1x")) .build(); - // Define module: m3 - // Can read: java.base, m2 + // Define module: m3x + // Can read: java.base, m2x // Packages: p3 // Packages exported: none - ModuleDescriptor descriptor_m3 = - ModuleDescriptor.module("m3") + ModuleDescriptor descriptor_m3x = + ModuleDescriptor.newModule("m3x") .requires("java.base") - .requires("m2") - .contains("p3") + .requires("m2x") + .packages(Set.of("p3")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2, descriptor_m3); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x, descriptor_m3x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); - map.put("m3", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); + map.put("m3x", MySameClassLoader.loader1); - // Create Layer that contains m1, m2 and m3 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x, m2x and m3x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m3") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m3x") == MySameClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 Class p1_c1_class = MySameClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is exported to m1 but m2 is not readable from m1)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is exported to m1x but m2x is not readable from m1x)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("cannot access")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/DiffCL_CheckRead.java b/hotspot/test/runtime/modules/AccessCheck/DiffCL_CheckRead.java index b0b64a46d95..732c326ccc1 100644 --- a/hotspot/test/runtime/modules/AccessCheck/DiffCL_CheckRead.java +++ b/hotspot/test/runtime/modules/AccessCheck/DiffCL_CheckRead.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if module m1 can not read module m2, then class p1.c1 - * in module m1 can not access p2.c2 in module m2. + * @summary Test that if module m1x can not read module m2x, then class p1.c1 + * in module m1x can not access p2.c2 in module m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,82 +46,82 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// ClassLoader2 --> defines m2 --> packages p2 -// defines m3 --> packages p3 +// ClassLoader1 --> defines m1x --> packages p1 +// ClassLoader2 --> defines m2x --> packages p2 +// defines m3x --> packages p3 // -// m1 can not read m2 -// package p2 in m2 is exported to m1 +// m1x can not read m2x +// package p2 in m2x is exported to m1x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2. -// Access denied since m1 can not read m2. +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x. +// Access denied since m1x can not read m2x. // public class DiffCL_CheckRead { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publicly defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m3 + // Define module: m1x + // Can read: java.base, m3x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m3") + .requires("m3x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 - // Packages exported: p2 is exported to m1 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: p2 is exported to m1x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m1")) + .exports("p2", Set.of("m1x")) .build(); - // Define module: m3 - // Can read: java.base, m2 + // Define module: m3x + // Can read: java.base, m2x // Packages: p3 // Packages exported: none - ModuleDescriptor descriptor_m3 = - ModuleDescriptor.module("m3") + ModuleDescriptor descriptor_m3x = + ModuleDescriptor.newModule("m3x") .requires("java.base") - .requires("m2") - .contains("p3") + .requires("m2x") + .packages(Set.of("p3")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2, descriptor_m3); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x, descriptor_m3x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); - map.put("m3", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); + map.put("m3x", MyDiffClassLoader.loader2); - // Create Layer that contains m1, m2 and m3 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x, m2x and m3x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); - assertTrue(layer.findLoader("m3") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m3x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 Class p1_c1_class = MyDiffClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is exported to m1 but m2 is not readable from m1)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is exported to m1x but m2x is not readable from m1x)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("cannot access")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpQualOther.java b/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpQualOther.java index b7088553bad..66062c4a2d9 100644 --- a/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpQualOther.java +++ b/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpQualOther.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,9 @@ /* * @test - * @summary Test that if module m1 can read module m2, but package p2 in m2 - * is exported specifically to module m3, then class p1.c1 in m1 can not - * access p2.c2 in m2. + * @summary Test that if module m1x can read module m2x, but package p2 in m2x + * is exported specifically to module m3x, then class p1.c1 in m1x can not + * access p2.c2 in m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -38,7 +38,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -48,83 +47,83 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// ClassLoader2 --> defines m2 --> packages p2 -// defines m3 --> packages p3 +// ClassLoader1 --> defines m1x --> packages p1 +// ClassLoader2 --> defines m2x --> packages p2 +// defines m3x --> packages p3 // -// m1 can read m2 -// package p2 in m2 is exported to m3 +// m1x can read m2x +// package p2 in m2x is exported to m3x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 -// Access denied since although m1 can read m2, p2 is exported only to m3. +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x +// Access denied since although m1x can read m2x, p2 is exported only to m3x. // public class DiffCL_ExpQualOther { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2, m3 + // Define module: m1x + // Can read: java.base, m2x, m3x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") - .requires("m3") + .requires("m2x") + .requires("m3x") .exports("p1") .build(); - // Define module: m2 - // Can read: java.base, m3 + // Define module: m2x + // Can read: java.base, m3x // Packages: p2 - // Packages exported: p2 is exported to m3 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: p2 is exported to m3x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m3")) + .exports("p2", Set.of("m3x")) .build(); - // Define module: m3 - // Can read: java.base, m2 + // Define module: m3x + // Can read: java.base, m2x // Packages: p3 // Packages exported: none - ModuleDescriptor descriptor_m3 = - ModuleDescriptor.module("m3") + ModuleDescriptor descriptor_m3x = + ModuleDescriptor.newModule("m3x") .requires("java.base") - .requires("m2") - .contains("p3") + .requires("m2x") + .packages(Set.of("p3")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2, descriptor_m3); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x, descriptor_m3x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); - map.put("m3", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); + map.put("m3x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); - assertTrue(layer.findLoader("m3") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m3x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 Class p1_c1_class = MyDiffClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is exported to m3 not to m1)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is exported to m3x not to m1x)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpQualToM1.java b/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpQualToM1.java index 8ca888b312f..3088a972803 100644 --- a/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpQualToM1.java +++ b/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpQualToM1.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary class p1.c1 defined in m1 tries to access p2.c2 defined in m2. - * Access allowed since m1 can read m2 and package p2 is exported to m1. + * @summary class p1.c1 defined in m1x tries to access p2.c2 defined in m2x. + * Access allowed since m1x can read m2x and package p2 is exported to m1x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,61 +46,61 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// ClassLoader2 --> defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> packages p1 +// ClassLoader2 --> defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is exported to m1 +// m1x can read m2x +// package p2 in m2x is exported to m1x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 -// Access allowed since m1 can read m2 and package p2 is exported to m1. +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x +// Access allowed since m1x can read m2x and package p2 is exported to m1x. // public class DiffCL_ExpQualToM1 { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: p1 // Packages exported: p1 is exported to unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 - // Packages exported: package p2 is exported to m1 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: package p2 is exported to m1x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m1")) + .exports("p2", Set.of("m1x")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 @@ -109,7 +108,7 @@ public class DiffCL_ExpQualToM1 { try { p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1"); + throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1x"); } } diff --git a/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpUnqual.java b/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpUnqual.java index e38d54166ed..6cb7ea9bdcb 100644 --- a/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpUnqual.java +++ b/hotspot/test/runtime/modules/AccessCheck/DiffCL_ExpUnqual.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if module m1 can read module m2, and package p2 in m2 is - * exported unqualifiedly, then class p1.c1 in m1 can read p2.c2 in m2. + * @summary Test that if module m1x can read module m2x, and package p2 in m2x is + * exported unqualifiedly, then class p1.c1 in m1x can read p2.c2 in m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,62 +46,62 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// ClassLoader2 --> defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> packages p1 +// ClassLoader2 --> defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is exported to m1 +// m1x can read m2x +// package p2 in m2x is exported to m1x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 -// Access allowed since m1 can read m2 and package p2 is exported +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x +// Access allowed since m1x can read m2x and package p2 is exported // unqualifiedly. // public class DiffCL_ExpUnqual { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 - // Packages exported: package p2 is exported to m1 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: package p2 is exported to m1x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") .exports("p2") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 @@ -110,7 +109,7 @@ public class DiffCL_ExpUnqual { try { p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1"); + throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1x"); } } diff --git a/hotspot/test/runtime/modules/AccessCheck/DiffCL_PkgNotExp.java b/hotspot/test/runtime/modules/AccessCheck/DiffCL_PkgNotExp.java index 0cc88f7a69b..e235d895751 100644 --- a/hotspot/test/runtime/modules/AccessCheck/DiffCL_PkgNotExp.java +++ b/hotspot/test/runtime/modules/AccessCheck/DiffCL_PkgNotExp.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if module m1 can read module m2, but package p2 in m2 is not - * exported, then class p1.c1 in m1 can not read p2.c2 in m2. + * @summary Test that if module m1x can read module m2x, but package p2 in m2x is not + * exported, then class p1.c1 in m1x can not read p2.c2 in m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,68 +46,68 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// ClassLoader2 --> defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> packages p1 +// ClassLoader2 --> defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is not exported +// m1x can read m2x +// package p2 in m2x is not exported // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x // Access denied since p2 is not exported. // public class DiffCL_PkgNotExp { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: none - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .contains("p2") + .packages(Set.of("p2")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 Class p1_c1_class = MyDiffClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is not exported)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is not exported)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/DiffCL_Umod.java b/hotspot/test/runtime/modules/AccessCheck/DiffCL_Umod.java index 2a5c723c76f..fafd41af3fa 100644 --- a/hotspot/test/runtime/modules/AccessCheck/DiffCL_Umod.java +++ b/hotspot/test/runtime/modules/AccessCheck/DiffCL_Umod.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,7 @@ /* * @test - * @summary class p1.c1 defined in m1 tries to access p2.c2 defined in unnamed module. + * @summary class p1.c1 defined in m1x tries to access p2.c2 defined in unnamed module. * @library /test/lib * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.module @@ -42,18 +42,16 @@ import static jdk.test.lib.Asserts.*; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.HashMap; import java.util.Map; import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// package p1 in m1 is exported unqualifiedly +// ClassLoader1 --> defines m1x --> packages p1 +// package p1 in m1x is exported unqualifiedly // -// class p1.c1 defined in m1 tries to access p2.c2 defined in +// class p1.c1 defined in m1x tries to access p2.c2 defined in // in unnamed module. // // Three access attempts occur in this test: @@ -62,50 +60,50 @@ import myloaders.MyDiffClassLoader; // 2. In this scenario a strict module establishes readability // to the particular unnamed module it is trying to access. // Access is allowed. -// 3. Module m1 in the test_looseModuleLayer() method +// 3. Module m1x in the test_looseModuleLayer() method // is transitioned to a loose module, access // to all unnamed modules is allowed. // public class DiffCL_Umod { - // Create Layers over the boot layer to test different + // Create layers over the boot layer to test different // accessing scenarios of a named module to an unnamed module. - // Module m1 is a strict module and has not established + // Module m1x is a strict module and has not established // readability to an unnamed module that p2.c2 is defined in. public void test_strictModuleLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p1") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); MyDiffClassLoader.loader1 = new MyDiffClassLoader(); MyDiffClassLoader.loader2 = new MyDiffClassLoader(); - // map module m1 to class loader. + // map module m1x to class loader. // class c2 will be loaded in an unnamed module/loader2 // to achieve differing class loaders. Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); + map.put("m1x", MyDiffClassLoader.loader1); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 @@ -114,109 +112,109 @@ public class DiffCL_Umod { // Attempt access try { p1_c1_class.newInstance(); - throw new RuntimeException("Test Failed, strict module m1 should not be able " + + throw new RuntimeException("Test Failed, strict module m1x should not be able " + "to access public type p2.c2 defined in unnamed module"); } catch (IllegalAccessError e) { } } - // Module m1 is a strict module and has established + // Module m1x is a strict module and has established // readability to an unnamed module that p2.c2 is defined in. public void test_strictModuleUnnamedReadableLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p1") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); MyDiffClassLoader.loader1 = new MyDiffClassLoader(); MyDiffClassLoader.loader2 = new MyDiffClassLoader(); - // map module m1 to class loader. + // map module m1x to class loader. // class c2 will be loaded in an unnamed module/loader2 // to achieve differing class loaders. Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); + map.put("m1x", MyDiffClassLoader.loader1); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1ReadEdgeDiffLoader Class p1_c1_class = MyDiffClassLoader.loader1.loadClass("p1.c1ReadEdgeDiffLoader"); try { - // Read edge between m1 and the unnamed module that loads p2.c2 is established in + // Read edge between m1x and the unnamed module that loads p2.c2 is established in // c1ReadEdgeDiffLoader's ctor before attempting access. p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, module m1 has established readability to p2/c2 loader's " + + throw new RuntimeException("Test Failed, module m1x has established readability to p2/c2 loader's " + "unnamed module, access should be allowed: " + e.getMessage()); } } - // Module m1 is a loose module and thus can read all unnamed modules. + // Module m1x is a loose module and thus can read all unnamed modules. public void test_looseModuleLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p1") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); MyDiffClassLoader.loader1 = new MyDiffClassLoader(); MyDiffClassLoader.loader2 = new MyDiffClassLoader(); - // map module m1 to class loader. + // map module m1x to class loader. // class c2 will be loaded in an unnamed module/loader2 // to achieve differing class loaders. Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); + map.put("m1x", MyDiffClassLoader.loader1); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1Loose Class p1_c1_class = MyDiffClassLoader.loader1.loadClass("p1.c1Loose"); - // change m1 to read all unnamed modules - Module m1 = layer.findModule("m1").get(); - jdk.internal.module.Modules.addReadsAllUnnamed(m1); + // change m1x to read all unnamed modules + Module m1x = layer.findModule("m1x").get(); + jdk.internal.module.Modules.addReadsAllUnnamed(m1x); try { p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, loose module m1 should be able to access " + + throw new RuntimeException("Test Failed, loose module m1x should be able to access " + "public type p2.c2 defined in unnamed module: " + e.getMessage()); } } diff --git a/hotspot/test/runtime/modules/AccessCheck/DiffCL_UmodUpkg.java b/hotspot/test/runtime/modules/AccessCheck/DiffCL_UmodUpkg.java index b8420c2e5c6..8a0d6a35af9 100644 --- a/hotspot/test/runtime/modules/AccessCheck/DiffCL_UmodUpkg.java +++ b/hotspot/test/runtime/modules/AccessCheck/DiffCL_UmodUpkg.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,7 @@ /* * @test - * @summary class p3.c3 defined in module m1 tries to access c4 defined in an unnamed package + * @summary class p3.c3 defined in module m1x tries to access c4 defined in an unnamed package * and an unnamed module. * @modules java.base/jdk.internal.misc * @library /test/lib @@ -38,7 +38,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -48,10 +47,10 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> packages p3 -// package p3 in m1 is exported unqualifiedly +// ClassLoader1 --> defines m1x --> packages p3 +// package p3 in m1x is exported unqualifiedly // -// class p3.c3 defined in m1 tries to access c4 defined in +// class p3.c3 defined in m1x tries to access c4 defined in // in unnamed module. // // Two access attempts occur in this test: @@ -63,44 +62,44 @@ import myloaders.MyDiffClassLoader; // public class DiffCL_UmodUpkg { - // Create Layers over the boot layer to test different + // Create layers over the boot layer to test different // accessing scenarios of a named module to an unnamed module. - // Module m1 is a strict module and has not established + // Module m1x is a strict module and has not established // readability to an unnamed module that c4 is defined in. public void test_strictModuleLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p3 // Packages exported: p3 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p3") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); MyDiffClassLoader.loader1 = new MyDiffClassLoader(); MyDiffClassLoader.loader2 = new MyDiffClassLoader(); - // map module m1 to class loader. + // map module m1x to class loader. // class c2 will be loaded in an unnamed module/loader2 // to achieve differing class loaders. Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); + map.put("m1x", MyDiffClassLoader.loader1); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p3.c3 @@ -109,58 +108,58 @@ public class DiffCL_UmodUpkg { // Attempt access try { p3_c3_class.newInstance(); - throw new RuntimeException("Test Failed, strict module m1 should not be able to access " + + throw new RuntimeException("Test Failed, strict module m1x should not be able to access " + "public type c4 defined in unnamed module"); } catch (IllegalAccessError e) { } } - // Module m1 is a strict module and has established + // Module m1x is a strict module and has established // readability to an unnamed module that c4 is defined in. public void test_strictModuleUnnamedReadableLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p3 // Packages exported: p3 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p3") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); MyDiffClassLoader.loader1 = new MyDiffClassLoader(); MyDiffClassLoader.loader2 = new MyDiffClassLoader(); - // map module m1 to class loader. + // map module m1x to class loader. // class c2 will be loaded in an unnamed module/loader2 // to achieve differing class loaders. Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); + map.put("m1x", MyDiffClassLoader.loader1); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p3.c3ReadEdgeDiffLoader Class p3_c3_class = MyDiffClassLoader.loader1.loadClass("p3.c3ReadEdgeDiffLoader"); try { - // Read edge between m1 and the unnamed module that loads c4 is established in + // Read edge between m1x and the unnamed module that loads c4 is established in // C3ReadEdgeDiffLoader's ctor before attempting access. p3_c3_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, module m1 has established readability to " + + throw new RuntimeException("Test Failed, module m1x has established readability to " + "c4 loader's unnamed module, access should be allowed: " + e.getMessage()); } } diff --git a/hotspot/test/runtime/modules/AccessCheck/ExpQualOther.java b/hotspot/test/runtime/modules/AccessCheck/ExpQualOther.java index 330d7239f3a..d3d8395b13a 100644 --- a/hotspot/test/runtime/modules/AccessCheck/ExpQualOther.java +++ b/hotspot/test/runtime/modules/AccessCheck/ExpQualOther.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,9 @@ /* * @test - * @summary Test that if module m1 can read module m2, but package p2 in m2 - * is exported specifically to module m3, then class p1.c1 in m1 can not - * access p2.c2 in m2. + * @summary Test that if module m1x can read module m2x, but package p2 in m2x + * is exported specifically to module m3x, then class p1.c1 in m1x can not + * access p2.c2 in m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -38,7 +38,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -48,83 +47,83 @@ import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// defines m2 --> packages p2 -// defines m3 --> packages p3 +// ClassLoader1 --> defines m1x --> packages p1 +// defines m2x --> packages p2 +// defines m3x --> packages p3 // -// m1 can read m2 -// package p2 in m2 is exported to m3 +// m1x can read m2x +// package p2 in m2x is exported to m3x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 -// Access denied since although m1 can read m2, p2 is exported only to m3. +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x +// Access denied since although m1x can read m2x, p2 is exported only to m3x. // public class ExpQualOther { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2, m3 + // Define module: m1x + // Can read: java.base, m2x, m3x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") - .requires("m3") + .requires("m2x") + .requires("m3x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 - // Packages exported: p2 is exported to m3 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: p2 is exported to m3x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m3")) + .exports("p2", Set.of("m3x")) .build(); - // Define module: m3 - // Can read: java.base, m2 + // Define module: m3x + // Can read: java.base, m2x // Packages: p3 // Packages exported: none - ModuleDescriptor descriptor_m3 = - ModuleDescriptor.module("m3") + ModuleDescriptor descriptor_m3x = + ModuleDescriptor.newModule("m3x") .requires("java.base") - .requires("m2") - .contains("p3") + .requires("m2x") + .packages(Set.of("p3")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2, descriptor_m3); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x, descriptor_m3x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); - map.put("m3", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); + map.put("m3x", MySameClassLoader.loader1); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m3") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m3x") == MySameClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 Class p1_c1_class = MySameClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is exported to m3 not to m1)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is exported to m3x not to m1x)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/ExpQualToM1.java b/hotspot/test/runtime/modules/AccessCheck/ExpQualToM1.java index 31de4576d90..1545bcb50e5 100644 --- a/hotspot/test/runtime/modules/AccessCheck/ExpQualToM1.java +++ b/hotspot/test/runtime/modules/AccessCheck/ExpQualToM1.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if module m1 can read module m2, AND package p2 in m2 is - * exported qualifiedly to m1, then class p1.c1 in m1 can read p2.c2 in m2. + * @summary Test that if module m1x can read module m2x, AND package p2 in m2x is + * exported qualifiedly to m1x, then class p1.c1 in m1x can read p2.c2 in m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -48,57 +47,57 @@ import myloaders.MySameClassLoader; public class ExpQualToM1 { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 - // Packages exported: p2 is exported qualifiedly to m1 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: p2 is exported qualifiedly to m1x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m1")) + .exports("p2", Set.of("m1x")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to the same class loader for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); // now use the same loader to load class p1.c1 Class p1_c1_class = MySameClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1"); + throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1x"); } } diff --git a/hotspot/test/runtime/modules/AccessCheck/ExpUnqual.java b/hotspot/test/runtime/modules/AccessCheck/ExpUnqual.java index 03a377027de..0daba28d73e 100644 --- a/hotspot/test/runtime/modules/AccessCheck/ExpUnqual.java +++ b/hotspot/test/runtime/modules/AccessCheck/ExpUnqual.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if module m1 can read module m2, AND package p2 in module2 is - * exported unqualifiedly, then class p1.c1 in m1 can read p2.c2 in m2. + * @summary Test that if module m1x can read module m2x, AND package p2 in module_two is + * exported unqualifiedly, then class p1.c1 in m1x can read p2.c2 in m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -48,50 +47,50 @@ import myloaders.MySameClassLoader; public class ExpUnqual { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: p2 is exported unqualifiedly - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") .exports("p2") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to the same class loader for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); // now use the same loader to load class p1.c1 Class p1_c1_class = MySameClassLoader.loader1.loadClass("p1.c1"); diff --git a/hotspot/test/runtime/modules/AccessCheck/ExportAllUnnamed.java b/hotspot/test/runtime/modules/AccessCheck/ExportAllUnnamed.java index c9a89c8ba9f..69f2ca14869 100644 --- a/hotspot/test/runtime/modules/AccessCheck/ExportAllUnnamed.java +++ b/hotspot/test/runtime/modules/AccessCheck/ExportAllUnnamed.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test if package p2 in module m2 is exported to all unnamed, - * then class p1.c1 in an unnamed module can read p2.c2 in module m2. + * @summary Test if package p2 in module m2x is exported to all unnamed, + * then class p1.c1 in an unnamed module can read p2.c2 in module m2x. * @library /test/lib * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.module @@ -41,76 +41,74 @@ import static jdk.test.lib.Asserts.*; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.HashMap; import java.util.Map; import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> no packages +// defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is exported unqualifiedly +// m1x can read m2x +// package p2 in m2x is exported unqualifiedly // -// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2 +// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2x // Access allowed, an unnamed module can read all modules and p2 in module -// m2 is exported to all unnamed modules. +// m2x is exported to all unnamed modules. public class ExportAllUnnamed { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: p2 is exported unqualifiedly - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m1")) + .exports("p2", Set.of("m1x")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); Class p2_c2_class = MySameClassLoader.loader1.loadClass("p2.c2"); - Module m2 = p2_c2_class.getModule(); + Module m2x = p2_c2_class.getModule(); - // Export m2/p2 to all unnamed modules. - jdk.internal.module.Modules.addExportsToAllUnnamed(m2, "p2"); + // Export m2x/p2 to all unnamed modules. + jdk.internal.module.Modules.addExportsToAllUnnamed(m2x, "p2"); // now use the same loader to load class p1.c1 Class p1_c1_class = MySameClassLoader.loader1.loadClass("p1.c1"); diff --git a/hotspot/test/runtime/modules/AccessCheck/PkgNotExp.java b/hotspot/test/runtime/modules/AccessCheck/PkgNotExp.java index 4f592a19002..baabe54cd85 100644 --- a/hotspot/test/runtime/modules/AccessCheck/PkgNotExp.java +++ b/hotspot/test/runtime/modules/AccessCheck/PkgNotExp.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if module m1 can read module m2, but package p2 in m2 is not - * exported, then class p1.c1 in m1 can not read p2.c2 in m2. + * @summary Test that if module m1x can read module m2x, but package p2 in m2x is not + * exported, then class p1.c1 in m1x can not read p2.c2 in m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,67 +46,67 @@ import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> packages p1 +// defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is not exported +// m1x can read m2x +// package p2 in m2x is not exported // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x // Access denied since p2 is not exported. // public class PkgNotExp { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: none - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .contains("p2") + .packages(Set.of("p2")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to the same class loader for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); - // Create Layer that contains m1 and m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x and m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); // now use the same loader to load class p1.c1 Class p1_c1_class = MySameClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is not exported)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is not exported)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/Umod.java b/hotspot/test/runtime/modules/AccessCheck/Umod.java index 255950c7f37..20b97edd11e 100644 --- a/hotspot/test/runtime/modules/AccessCheck/Umod.java +++ b/hotspot/test/runtime/modules/AccessCheck/Umod.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,7 @@ /* * @test - * @summary class p1.c1 defined in m1 tries to access p2.c2 defined in unnamed module. + * @summary class p1.c1 defined in m1x tries to access p2.c2 defined in unnamed module. * @library /test/lib * @modules java.base/jdk.internal.misc * @modules java.base/jdk.internal.module @@ -39,21 +39,19 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; -import java.lang.reflect.Module; import java.util.HashMap; import java.util.Map; import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> packages p1 -// package p1 in m1 is exported unqualifiedly +// ClassLoader1 --> defines m1x --> packages p1 +// package p1 in m1x is exported unqualifiedly // -// class p1.c1 defined in m1 tries to access p2.c2 defined in +// class p1.c1 defined in m1x tries to access p2.c2 defined in // in unnamed module. // // Three access attempts occur in this test: @@ -62,47 +60,47 @@ import myloaders.MySameClassLoader; // 2. In this scenario a strict module establishes readability // to the particular unnamed module it is trying to access. // Access is allowed. -// 3. Module m1 in the test_looseModuleLayer() method +// 3. Module m1x in the test_looseModuleLayer() method // is transitioned to a loose module, access // to all unnamed modules is allowed. // public class Umod { - // Create Layers over the boot layer to test different + // Create layers over the boot layer to test different // accessing scenarios of a named module to an unnamed module. - // Module m1 is a strict module and has not established + // Module m1x is a strict module and has not established // readability to an unnamed module that p2.c2 is defined in. public void test_strictModuleLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p1") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); - // map module m1 to class loader. + // map module m1x to class loader. // class c2 will be loaded in an unnamed module/loader. MySameClassLoader loader = new MySameClassLoader(); Map map = new HashMap<>(); - map.put("m1", loader); + map.put("m1x", loader); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == loader); + assertTrue(layer.findLoader("m1x") == loader); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 @@ -111,103 +109,103 @@ public class Umod { // Attempt access try { p1_c1_class.newInstance(); - throw new RuntimeException("Test Failed, strict module m1, type p1.c1, should not be able " + + throw new RuntimeException("Test Failed, strict module m1x, type p1.c1, should not be able " + "to access public type p2.c2 defined in unnamed module"); } catch (IllegalAccessError e) { } } - // Module m1 is a strict module and has established + // Module m1x is a strict module and has established // readability to an unnamed module that p2.c2 is defined in. public void test_strictModuleUnnamedReadableLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p1") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); MySameClassLoader loader = new MySameClassLoader(); - // map module m1 to class loader. + // map module m1x to class loader. // class c2 will be loaded in an unnamed module/loader. Map map = new HashMap<>(); - map.put("m1", loader); + map.put("m1x", loader); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == loader); + assertTrue(layer.findLoader("m1x") == loader); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1ReadEdge Class p1_c1_class = loader.loadClass("p1.c1ReadEdge"); try { - // Read edge between m1 and the unnamed module that loads p2.c2 is established in + // Read edge between m1x and the unnamed module that loads p2.c2 is established in // c1ReadEdge's ctor before attempting access. p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, strict module m1, type p1.c1ReadEdge, should be able to acccess public type " + + throw new RuntimeException("Test Failed, strict module m1x, type p1.c1ReadEdge, should be able to acccess public type " + "p2.c2 defined in unnamed module: " + e.getMessage()); } } - // Module m1 is a loose module and thus can read all unnamed modules. + // Module m1x is a loose module and thus can read all unnamed modules. public void test_looseModuleLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p1 // Packages exported: p1 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p1") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); MySameClassLoader loader = new MySameClassLoader(); - // map module m1 to class loader. + // map module m1x to class loader. // class c2 will be loaded in an unnamed module/loader. Map map = new HashMap<>(); - map.put("m1", loader); + map.put("m1x", loader); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == loader); + assertTrue(layer.findLoader("m1x") == loader); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1Loose Class p1_c1_class = loader.loadClass("p1.c1Loose"); - // change m1 to read all unnamed modules - Module m1 = layer.findModule("m1").get(); - jdk.internal.module.Modules.addReadsAllUnnamed(m1); + // change m1x to read all unnamed modules + Module m1x = layer.findModule("m1x").get(); + jdk.internal.module.Modules.addReadsAllUnnamed(m1x); try { p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, strict module m1, type p1.c1Loose, should be able to acccess public type " + + throw new RuntimeException("Test Failed, strict module m1x, type p1.c1Loose, should be able to acccess public type " + "p2.c2 defined in unnamed module: " + e.getMessage()); } } diff --git a/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_ExpQualOther.java b/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_ExpQualOther.java index 5fcc629096c..a017c9f74b6 100644 --- a/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_ExpQualOther.java +++ b/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_ExpQualOther.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,9 @@ /* * @test - * @summary class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2. + * @summary class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2x. * Access is denied, since an unnamed module can read all modules but p2 in module - * m2 is exported specifically to module m1, not to all modules. + * m2x is exported specifically to module m1x, not to all modules. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -38,7 +38,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -48,70 +47,70 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// ClassLoader2 --> defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> no packages +// ClassLoader2 --> defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is not exported +// m1x can read m2x +// package p2 in m2x is not exported // -// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2 +// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2x // Access denied, an unnamed module can read all modules but p2 in module -// m2 is exported specifically to module m1 not to all modules. +// m2x is exported specifically to module m1x not to all modules. // public class UmodDiffCL_ExpQualOther { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: none - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m1")) + .exports("p2", Set.of("m1x")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 - // NOTE: module m1 does not define a package named p1. + // NOTE: module m1x does not define a package named p1. // p1 will be loaded in an unnamed module. Class p1_c1_class = MyDiffClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is exported to m1, not unqualifiedly"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is exported to m1x, not unqualifiedly"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_ExpUnqual.java b/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_ExpUnqual.java index ade483acd46..724a92d7748 100644 --- a/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_ExpUnqual.java +++ b/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_ExpUnqual.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2. - * Access allowed, an unnamed module can read all modules and p2 in module m2 + * @summary class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2x. + * Access allowed, an unnamed module can read all modules and p2 in module m2x * which is exported unqualifiedly. * @modules java.base/jdk.internal.misc * @library /test/lib @@ -38,7 +38,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -48,70 +47,70 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// ClassLoader2 --> defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> no packages +// ClassLoader2 --> defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is exported unqualifiedly. +// m1x can read m2x +// package p2 in m2x is exported unqualifiedly. // -// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2 +// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2x // Access allowed, an unnamed module can read all modules and p2 in module -// m2 which is exported unqualifiedly. +// m2x which is exported unqualifiedly. // public class UmodDiffCL_ExpUnqual { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: none - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") .exports("p2") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); - // NOTE: module m1 does not define a package named p1. + // NOTE: module m1x does not define a package named p1. // p1 will be loaded in an unnamed module. Class p1_c1_class = MyDiffClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, p1.c1 defined in unnamed module can access p2.c2 in module m2"); + throw new RuntimeException("Test Failed, p1.c1 defined in unnamed module can access p2.c2 in module m2x"); } } diff --git a/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_PkgNotExp.java b/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_PkgNotExp.java index b5ec6c6a6b0..c95ab7fb031 100644 --- a/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_PkgNotExp.java +++ b/hotspot/test/runtime/modules/AccessCheck/UmodDiffCL_PkgNotExp.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,9 @@ /* * @test - * @summary class p1.c1 defined in unnamed module tries to access p2.c2 defined in m2. + * @summary class p1.c1 defined in unnamed module tries to access p2.c2 defined in m2x. * Access is denied since even though unnamed module can read all modules, p2 - * in module m2 is not exported at all. + * in module m2x is not exported at all. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,70 +46,70 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// ClassLoader2 --> defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> no packages +// ClassLoader2 --> defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is not exported +// m1x can read m2x +// package p2 in m2x is not exported // -// class p1.c1 defined in unnamed module tries to access p2.c2 defined in m2 +// class p1.c1 defined in unnamed module tries to access p2.c2 defined in m2x // Access denied since even though unnamed module can read all modules, p2 -// in module m2 is not exported at all. +// in module m2x is not exported at all. // public class UmodDiffCL_PkgNotExp { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: none - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .contains("p2") + .packages(Set.of("p2")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 - // NOTE: module m1 does not define a package named p1. + // NOTE: module m1x does not define a package named p1. // p1 will be loaded in an unnamed module. Class p1_c1_class = MyDiffClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is not exported to an unnamed module)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is not exported to an unnamed module)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/UmodUPkg.java b/hotspot/test/runtime/modules/AccessCheck/UmodUPkg.java index 7cfcdabe42b..f84425ba4a6 100644 --- a/hotspot/test/runtime/modules/AccessCheck/UmodUPkg.java +++ b/hotspot/test/runtime/modules/AccessCheck/UmodUPkg.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,7 @@ /* * @test - * @summary class p3.c3 defined in module m1 tries to access c4 defined in unnamed module. + * @summary class p3.c3 defined in module m1x tries to access c4 defined in unnamed module. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -40,18 +40,16 @@ import static jdk.test.lib.Asserts.*; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.HashMap; import java.util.Map; import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> packages p3 -// package p3 in m1 is exported unqualifiedly +// ClassLoader1 --> defines m1x --> packages p3 +// package p3 in m1x is exported unqualifiedly // -// class p3.c3 defined in m1 tries to access c4 defined in +// class p3.c3 defined in m1x tries to access c4 defined in // in unnamed module. // // Two access attempts occur in this test: @@ -63,41 +61,41 @@ import myloaders.MySameClassLoader; // public class UmodUPkg { - // Create Layers over the boot layer to test different + // Create layers over the boot layer to test different // accessing scenarios of a named module to an unnamed module. - // Module m1 is a strict module and has not established + // Module m1x is a strict module and has not established // readability to an unnamed module that c4 is defined in. public void test_strictModuleLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p3 // Packages exported: p3 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p3") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); - // map module m1 to class loader. + // map module m1x to class loader. // class c4 will be loaded in an unnamed module/loader. MySameClassLoader loader = new MySameClassLoader(); Map map = new HashMap<>(); - map.put("m1", loader); + map.put("m1x", loader); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == loader); + assertTrue(layer.findLoader("m1x") == loader); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p3.c3 @@ -106,55 +104,55 @@ public class UmodUPkg { // Attempt access try { p3_c3_class.newInstance(); - throw new RuntimeException("Test Failed, strict module m1, type p3.c3, should not be able to access " + + throw new RuntimeException("Test Failed, strict module m1x, type p3.c3, should not be able to access " + "public type c4 defined in unnamed module"); } catch (IllegalAccessError e) { } } - // Module m1 is a strict module and has established + // Module m1x is a strict module and has established // readability to an unnamed module that c4 is defined in. public void test_strictModuleUnnamedReadableLayer() throws Throwable { - // Define module: m1 + // Define module: m1x // Can read: java.base // Packages: p3 // Packages exported: p3 is exported unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") .exports("p3") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); MySameClassLoader loader = new MySameClassLoader(); - // map module m1 to class loader. + // map module m1x to class loader. // class c4 will be loaded in an unnamed module/loader. Map map = new HashMap<>(); - map.put("m1", loader); + map.put("m1x", loader); - // Create Layer that contains m1 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == loader); + assertTrue(layer.findLoader("m1x") == loader); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p3.c3ReadEdge Class p3_c3_class = loader.loadClass("p3.c3ReadEdge"); try { - // Read edge between m1 and the unnamed module that loads c4 is established in + // Read edge between m1x and the unnamed module that loads c4 is established in // c3ReadEdge's ctor before attempting access. p3_c3_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, module m1, type p3.c3ReadEdge, has established readability to " + + throw new RuntimeException("Test Failed, module m1x, type p3.c3ReadEdge, has established readability to " + "c4 loader's unnamed module, access should be allowed: " + e.getMessage()); } } diff --git a/hotspot/test/runtime/modules/AccessCheck/UmodUpkgDiffCL_ExpQualOther.java b/hotspot/test/runtime/modules/AccessCheck/UmodUpkgDiffCL_ExpQualOther.java index 01ec39aa1a5..85ecface508 100644 --- a/hotspot/test/runtime/modules/AccessCheck/UmodUpkgDiffCL_ExpQualOther.java +++ b/hotspot/test/runtime/modules/AccessCheck/UmodUpkgDiffCL_ExpQualOther.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,9 @@ /* * @test - * @summary class c5 defined in an unnamed module tries to access p6.c6 defined in m2. + * @summary class c5 defined in an unnamed module tries to access p6.c6 defined in m2x. * Access is denied, since an unnamed module can read all modules but p6 in module - * m2 is exported specifically to module m1, not to all modules. + * m2x is exported specifically to module m1x, not to all modules. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -38,7 +38,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -48,68 +47,68 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// ClassLoader2 --> defines m2 --> packages p6 +// ClassLoader1 --> defines m1x --> no packages +// ClassLoader2 --> defines m2x --> packages p6 // -// m1 can read m2 -// package p6 in m2 is not exported +// m1x can read m2x +// package p6 in m2x is not exported // -// class c5 defined in an unnamed module tries to access p6.c6 defined in m2 +// class c5 defined in an unnamed module tries to access p6.c6 defined in m2x // Access denied, an unnamed module can read all modules but p6 in module -// m2 is exported specifically to module m1 not to all modules. +// m2x is exported specifically to module m1x not to all modules. // public class UmodUpkgDiffCL_ExpQualOther { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p6 - // Packages exported: p6 exported to m1 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: p6 exported to m1x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p6", Set.of("m1")) + .exports("p6", Set.of("m1x")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class c5 Class c5_class = MyDiffClassLoader.loader1.loadClass("c5"); try { c5_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p6 in m2 is exported to m1, not unqualifiedly"); + throw new RuntimeException("Failed to get IAE (p6 in m2x is exported to m1x, not unqualifiedly"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/UmodUpkgDiffCL_NotExp.java b/hotspot/test/runtime/modules/AccessCheck/UmodUpkgDiffCL_NotExp.java index 68dd3778b5c..b55a19ea1b5 100644 --- a/hotspot/test/runtime/modules/AccessCheck/UmodUpkgDiffCL_NotExp.java +++ b/hotspot/test/runtime/modules/AccessCheck/UmodUpkgDiffCL_NotExp.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary class c5 in an unnamed module can read module m2, but package p6 in module m2 is not exported. - * Access denied since even though unnamed module can read all modules, p6 in module m2 is not exported at all. + * @summary class c5 in an unnamed module can read module m2x, but package p6 in module m2x is not exported. + * Access denied since even though unnamed module can read all modules, p6 in module m2x is not exported at all. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MyDiffClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,70 +46,70 @@ import java.util.Set; import myloaders.MyDiffClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// ClassLoader2 --> defines m2 --> packages p6 +// ClassLoader1 --> defines m1x --> no packages +// ClassLoader2 --> defines m2x --> packages p6 // -// m1 can read m2 -// package p6 in m2 is not exported +// m1x can read m2x +// package p6 in m2x is not exported // -// class c5 defined in unnamed module tries to access p6.c6 defined in m2 +// class c5 defined in unnamed module tries to access p6.c6 defined in m2x // Access denied since even though unnamed module can read all modules, p6 -// in module m2 is not exported at all. +// in module m2x is not exported at all. // public class UmodUpkgDiffCL_NotExp { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p6 // Packages exported: none - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .contains("p6") + .packages(Set.of("p6")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MyDiffClassLoader.loader1); - map.put("m2", MyDiffClassLoader.loader2); + map.put("m1x", MyDiffClassLoader.loader1); + map.put("m2x", MyDiffClassLoader.loader2); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MyDiffClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MyDiffClassLoader.loader2); + assertTrue(layer.findLoader("m1x") == MyDiffClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MyDiffClassLoader.loader2); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class c5 - // NOTE: module m1 does not define any packages. + // NOTE: module m1x does not define any packages. // c5 will be loaded in an unnamed module. Class c5_class = MyDiffClassLoader.loader1.loadClass("c5"); try { c5_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p6 in m2 is not exported to " + + throw new RuntimeException("Failed to get IAE (p6 in m2x is not exported to " + "an unnamed module that c5 is defined within)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); diff --git a/hotspot/test/runtime/modules/AccessCheck/UmodUpkg_ExpQualOther.java b/hotspot/test/runtime/modules/AccessCheck/UmodUpkg_ExpQualOther.java index 68abe56b7a1..081dc0a2ba2 100644 --- a/hotspot/test/runtime/modules/AccessCheck/UmodUpkg_ExpQualOther.java +++ b/hotspot/test/runtime/modules/AccessCheck/UmodUpkg_ExpQualOther.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if class c5 in an unnamed module can read package p6 in module m2, but package p6 in module m2 is - * exported qualifiedly to module m3, then class c5 in an unnamed module can not read p6.c6 in module m2. + * @summary Test that if class c5 in an unnamed module can read package p6 in module m2x, but package p6 in module m2x is + * exported qualifiedly to module m3x, then class c5 in an unnamed module can not read p6.c6 in module m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,80 +46,80 @@ import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// defines m2 --> packages p6 -// defines m3 --> packages p3 +// ClassLoader1 --> defines m1x --> no packages +// defines m2x --> packages p6 +// defines m3x --> packages p3 // -// m1 can read m2 -// package p6 in m2 is exported to m3 +// m1x can read m2x +// package p6 in m2x is exported to m3x // -// class c5 defined in m1 tries to access p6.c6 defined in m2 -// Access denied since although m1 can read m2, p6 is exported only to m3. +// class c5 defined in m1x tries to access p6.c6 defined in m2x +// Access denied since although m1x can read m2x, p6 is exported only to m3x. // public class UmodUpkg_ExpQualOther { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 (need to define m1 to establish the Layer successfully) - // Can read: java.base, m2, m3 + // Define module: m1x (need to define m1x to establish the layer successfully) + // Can read: java.base, m2x, m3x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") - .requires("m3") + .requires("m2x") + .requires("m3x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p6 - // Packages exported: p6 is exported to m3 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: p6 is exported to m3x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p6", Set.of("m3")) + .exports("p6", Set.of("m3x")) .build(); - // Define module: m3 + // Define module: m3x // Can read: java.base // Packages: p3 // Packages exported: none - ModuleDescriptor descriptor_m3 = - ModuleDescriptor.module("m3") + ModuleDescriptor descriptor_m3x = + ModuleDescriptor.newModule("m3x") .requires("java.base") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2, descriptor_m3); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x, descriptor_m3x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); - map.put("m3", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); + map.put("m3x", MySameClassLoader.loader1); - // Create Layer that contains m1, m2 and m3 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x, m2x and m3x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m3") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m3x") == MySameClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class c5 Class c5_class = MySameClassLoader.loader1.loadClass("c5"); try { c5_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p6 in m2 is exported to m3, not unqualifiedly to everyone)"); + throw new RuntimeException("Failed to get IAE (p6 in m2x is exported to m3x, not unqualifiedly to everyone)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/UmodUpkg_NotExp.java b/hotspot/test/runtime/modules/AccessCheck/UmodUpkg_NotExp.java index da69805e580..d7e3287ac9d 100644 --- a/hotspot/test/runtime/modules/AccessCheck/UmodUpkg_NotExp.java +++ b/hotspot/test/runtime/modules/AccessCheck/UmodUpkg_NotExp.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test if package p6 in module m2 is not exported, then class c5 - * in an unnamed module can not access p6.c2 in module m2. + * @summary Test if package p6 in module m2x is not exported, then class c5 + * in an unnamed module can not access p6.c2 in module m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -46,67 +45,67 @@ import java.util.Map; import java.util.Set; import myloaders.MySameClassLoader; -// ClassLoader1 --> defines m1 --> no packages -// defines m2 --> packages p6 +// ClassLoader1 --> defines m1x --> no packages +// defines m2x --> packages p6 // -// m1 can read m2 -// package p6 in m2 is not exported +// m1x can read m2x +// package p6 in m2x is not exported // -// class c5 defined in an unnamed module tries to access p6.c2 defined in m2 +// class c5 defined in an unnamed module tries to access p6.c2 defined in m2x // Access denied since p6 is not exported. // public class UmodUpkg_NotExp { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p6 // Packages exported: none - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .contains("p6") + .packages(Set.of("p6")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to the same class loader for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); - // Create Layer that contains m1 and m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x and m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class c5 Class c5_class = MySameClassLoader.loader1.loadClass("c5"); try { c5_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p6 in m2 is not exported)"); + throw new RuntimeException("Failed to get IAE (p6 in m2x is not exported)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/Umod_ExpQualOther.java b/hotspot/test/runtime/modules/AccessCheck/Umod_ExpQualOther.java index 0f5aaf21585..1032eecb27f 100644 --- a/hotspot/test/runtime/modules/AccessCheck/Umod_ExpQualOther.java +++ b/hotspot/test/runtime/modules/AccessCheck/Umod_ExpQualOther.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test that if package p2 in module m2 is exported to module m3, - * then class p1.c1 in an unnamed module can not read p2.c2 in module m2. + * @summary Test that if package p2 in module m2x is exported to module m3x, + * then class p1.c1 in an unnamed module can not read p2.c2 in module m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,80 +46,80 @@ import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// defines m2 --> packages p2 -// defines m3 --> packages p3 +// ClassLoader1 --> defines m1x --> no packages +// defines m2x --> packages p2 +// defines m3x --> packages p3 // -// m1 can read m2 -// package p2 in m2 is exported to m3 +// m1x can read m2x +// package p2 in m2x is exported to m3x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 -// Access denied since although m1 can read m2, p2 is exported only to m3. +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x +// Access denied since although m1x can read m2x, p2 is exported only to m3x. // public class Umod_ExpQualOther { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 (need to define m1 to establish the Layer successfully) - // Can read: java.base, m2, m3 + // Define module: m1x (need to define m1x to establish the layer successfully) + // Can read: java.base, m2x, m3x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") - .requires("m3") + .requires("m2x") + .requires("m3x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 - // Packages exported: p2 is exported to m3 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: p2 is exported to m3x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m3")) + .exports("p2", Set.of("m3x")) .build(); - // Define module: m3 + // Define module: m3x // Can read: java.base // Packages: p3 // Packages exported: none - ModuleDescriptor descriptor_m3 = - ModuleDescriptor.module("m3") + ModuleDescriptor descriptor_m3x = + ModuleDescriptor.newModule("m3x") .requires("java.base") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2, descriptor_m3); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x, descriptor_m3x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); - map.put("m3", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); + map.put("m3x", MySameClassLoader.loader1); - // Create Layer that contains m1, m2 and m3 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x, m2x and m3x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m3") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m3x") == MySameClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 Class p1_c1_class = MySameClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is exported to m3, not unqualifiedly to everyone)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is exported to m3x, not unqualifiedly to everyone)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/Umod_ExpUnqual.java b/hotspot/test/runtime/modules/AccessCheck/Umod_ExpUnqual.java index db90a08bd44..05971cec727 100644 --- a/hotspot/test/runtime/modules/AccessCheck/Umod_ExpUnqual.java +++ b/hotspot/test/runtime/modules/AccessCheck/Umod_ExpUnqual.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test if package p2 in module m2 is exported unqualifiedly, - * then class p1.c1 in an unnamed module can read p2.c2 in module m2. + * @summary Test if package p2 in module m2x is exported unqualifiedly, + * then class p1.c1 in an unnamed module can read p2.c2 in module m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -47,61 +46,61 @@ import java.util.Set; import myloaders.MySameClassLoader; // -// ClassLoader1 --> defines m1 --> no packages -// defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> no packages +// defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is exported unqualifiedly +// m1x can read m2x +// package p2 in m2x is exported unqualifiedly // -// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2 +// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2x // Access allowed, an unnamed module can read all modules and p2 in module -// m2 which is exported unqualifiedly. +// m2x which is exported unqualifiedly. public class Umod_ExpUnqual { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: p2 is exported unqualifiedly - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") .exports("p2") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing class loaders for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 diff --git a/hotspot/test/runtime/modules/AccessCheck/Umod_PkgNotExp.java b/hotspot/test/runtime/modules/AccessCheck/Umod_PkgNotExp.java index d140cf84d69..46e692934c6 100644 --- a/hotspot/test/runtime/modules/AccessCheck/Umod_PkgNotExp.java +++ b/hotspot/test/runtime/modules/AccessCheck/Umod_PkgNotExp.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @summary Test if package p2 in module m2 is not exported, then class p1.c1 - * in an unnamed module can not access p2.c2 in module m2. + * @summary Test if package p2 in module m2x is not exported, then class p1.c1 + * in an unnamed module can not access p2.c2 in module m2x. * @modules java.base/jdk.internal.misc * @library /test/lib * @compile myloaders/MySameClassLoader.java @@ -37,7 +37,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -46,67 +45,67 @@ import java.util.Map; import java.util.Set; import myloaders.MySameClassLoader; -// ClassLoader1 --> defines m1 --> no packages -// defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> no packages +// defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is not exported +// m1x can read m2x +// package p2 in m2x is not exported // -// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2 +// class p1.c1 defined in an unnamed module tries to access p2.c2 defined in m2x // Access denied since p2 is not exported. // public class Umod_PkgNotExp { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: none // Packages exported: none - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 // Packages exported: none - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .contains("p2") + .packages(Set.of("p2")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to the same class loader for this test Map map = new HashMap<>(); - map.put("m1", MySameClassLoader.loader1); - map.put("m2", MySameClassLoader.loader1); + map.put("m1x", MySameClassLoader.loader1); + map.put("m2x", MySameClassLoader.loader1); - // Create Layer that contains m1 and m2 - Layer layer = Layer.boot().defineModules(cf, map::get); + // Create layer that contains m1x and m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == MySameClassLoader.loader1); - assertTrue(layer.findLoader("m2") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m1x") == MySameClassLoader.loader1); + assertTrue(layer.findLoader("m2x") == MySameClassLoader.loader1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 Class p1_c1_class = MySameClassLoader.loader1.loadClass("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is not exported)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is not exported)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheck/p1/c1Loose.java b/hotspot/test/runtime/modules/AccessCheck/p1/c1Loose.java index 3722927e1b4..ab03e5de9c0 100644 --- a/hotspot/test/runtime/modules/AccessCheck/p1/c1Loose.java +++ b/hotspot/test/runtime/modules/AccessCheck/p1/c1Loose.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,7 @@ import p2.c2; public class c1Loose { public c1Loose() { - // Attempt access - access should succeed since m1 is a loose module + // Attempt access - access should succeed since m1x is a loose module p2.c2 c2_obj = new p2.c2(); c2_obj.method2(); } diff --git a/hotspot/test/runtime/modules/AccessCheck/p1/c1ReadEdge.java b/hotspot/test/runtime/modules/AccessCheck/p1/c1ReadEdge.java index 55d4a8b7d13..40b31cc49f6 100644 --- a/hotspot/test/runtime/modules/AccessCheck/p1/c1ReadEdge.java +++ b/hotspot/test/runtime/modules/AccessCheck/p1/c1ReadEdge.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,17 +22,16 @@ */ package p1; -import java.lang.reflect.*; import p2.c2; public class c1ReadEdge { public c1ReadEdge() { - // Establish read edge from module m1, where c1ReadEdge is defined, + // Establish read edge from module m1x, where c1ReadEdge is defined, // to the unnamed module, where p2.c2 will be defined. - Module m1 = c1ReadEdge.class.getModule(); + Module m1x = c1ReadEdge.class.getModule(); ClassLoader loader = c1ReadEdge.class.getClassLoader(); Module unnamed_module = loader.getUnnamedModule(); - m1.addReads(unnamed_module); + m1x.addReads(unnamed_module); // Attempt access - access should succeed p2.c2 c2_obj = new p2.c2(); diff --git a/hotspot/test/runtime/modules/AccessCheck/p1/c1ReadEdgeDiffLoader.java b/hotspot/test/runtime/modules/AccessCheck/p1/c1ReadEdgeDiffLoader.java index daaee5843c8..51b8955673e 100644 --- a/hotspot/test/runtime/modules/AccessCheck/p1/c1ReadEdgeDiffLoader.java +++ b/hotspot/test/runtime/modules/AccessCheck/p1/c1ReadEdgeDiffLoader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,38 +22,37 @@ */ package p1; -import java.lang.reflect.*; import myloaders.MyDiffClassLoader; import p2.c2; public class c1ReadEdgeDiffLoader { public c1ReadEdgeDiffLoader() { - // The goal is to establish a read edge between module m1 + // The goal is to establish a read edge between module m1x // which is the module where p1.c1ReadEdgeDiffLoader is defined, // and the unnamed module that defines p2.c2. This must be // done in 2 steps: // - // Step #1: Establish a read edge between m1, where c1ReadEdgeDiffLoader + // Step #1: Establish a read edge between m1x, where c1ReadEdgeDiffLoader // is defined, and the System ClassLoader's unnamed module, // where MyDiffClassLoader is defined. This read edge // is needed before we can obtain MyDiffClassLoader.loader2's unnamed module. // - // Step #2: Establish a read edge between m1, where c1ReadEdgeDiffLoader + // Step #2: Establish a read edge between m1x, where c1ReadEdgeDiffLoader // is defined, and the MyDiffClassLoader.loader2's unnamed module, // where p2.c2 will be defined. - // Step #1: read edge m1 -> System ClassLoader's unnamed module - Module m1 = c1ReadEdgeDiffLoader.class.getModule(); + // Step #1: read edge m1x -> System ClassLoader's unnamed module + Module m1x = c1ReadEdgeDiffLoader.class.getModule(); ClassLoader system_loader = ClassLoader.getSystemClassLoader(); - Module unnamed_module1 = system_loader.getUnnamedModule(); - m1.addReads(unnamed_module1); + Module unnamed_module_one = system_loader.getUnnamedModule(); + m1x.addReads(unnamed_module_one); - // Step #2: read edge m1 -> MyDiffClassLoader.loader2's unnamed module + // Step #2: read edge m1x -> MyDiffClassLoader.loader2's unnamed module ClassLoader loader2 = MyDiffClassLoader.loader2; - Module unnamed_module2 = loader2.getUnnamedModule(); - m1.addReads(unnamed_module2); + Module unnamed_module_two = loader2.getUnnamedModule(); + m1x.addReads(unnamed_module_two); - // Attempt access - access should succeed since m1 can read + // Attempt access - access should succeed since m1x can read // MyDiffClassLoader.loader2's unnamed module p2.c2 c2_obj = new p2.c2(); c2_obj.method2(); diff --git a/hotspot/test/runtime/modules/AccessCheck/p3/c3ReadEdge.jcod b/hotspot/test/runtime/modules/AccessCheck/p3/c3ReadEdge.jcod index 50df6180233..cc529395226 100644 --- a/hotspot/test/runtime/modules/AccessCheck/p3/c3ReadEdge.jcod +++ b/hotspot/test/runtime/modules/AccessCheck/p3/c3ReadEdge.jcod @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,15 +23,14 @@ /* * package p3; - * import java.lang.reflect.*; * public class c3ReadEdge { * public c3ReadEdge() { - * // Establish read edge from module m1, where c3ReadEdge is defined, + * // Establish read edge from module m1x, where c3ReadEdge is defined, * // to the unnamed module, where c4 will be defined. - * Module m1 = c3ReadEdge.class.getModule(); + * Module m1x = c3ReadEdge.class.getModule(); * ClassLoader loader = c3ReadEdge.class.getClassLoader(); * Module unnamed_module = loader.getUnnamedModule(); - * m1.addReads(unnamed_module); + * m1x.addReads(unnamed_module); * // Attempt access - access should succeed * c4 c4_obj = new c4(); * c4_obj.method4(); @@ -75,14 +74,14 @@ class p3/c3ReadEdge { Utf8 "java/lang/Object"; // #28 at 0xBC Utf8 "java/lang/Class"; // #29 at 0xCF Utf8 "getModule"; // #30 at 0xE1 - Utf8 "()Ljava/lang/reflect/Module;"; // #31 at 0xED + Utf8 "()Ljava/lang/Module;"; // #31 at 0xED Utf8 "getClassLoader"; // #32 at 0x010C Utf8 "()Ljava/lang/ClassLoader;"; // #33 at 0x011D Utf8 "java/lang/ClassLoader"; // #34 at 0x0139 Utf8 "getUnnamedModule"; // #35 at 0x0151 - Utf8 "java/lang/reflect/Module"; // #36 at 0x0164 + Utf8 "java/lang/Module"; // #36 at 0x0164 Utf8 "addReads"; // #37 at 0x017F - Utf8 "(Ljava/lang/reflect/Module;)Ljava/lang/reflect/Module;"; // #38 at 0x018A + Utf8 "(Ljava/lang/Module;)Ljava/lang/Module;"; // #38 at 0x018A Utf8 "method4"; // #39 at 0x01C3 } // Constant Pool diff --git a/hotspot/test/runtime/modules/AccessCheck/p3/c3ReadEdgeDiffLoader.jcod b/hotspot/test/runtime/modules/AccessCheck/p3/c3ReadEdgeDiffLoader.jcod index 103f7eea2c7..e1602cdf9fb 100644 --- a/hotspot/test/runtime/modules/AccessCheck/p3/c3ReadEdgeDiffLoader.jcod +++ b/hotspot/test/runtime/modules/AccessCheck/p3/c3ReadEdgeDiffLoader.jcod @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,37 +23,36 @@ /* * package p3; - * import java.lang.reflect.*; * import myloaders.MyDiffClassLoader; * * public class c3ReadEdgeDiffLoader { * public c3ReadEdgeDiffLoader() { - * // The goal is to establish a read edge between module m1 + * // The goal is to establish a read edge between module m1x * // which is the module where p3.c3ReadEdgeDiffLoader is defined, * // and the unnamed module that defines c4. This must be * // done in 2 steps: * // - * // Step #1: Establish a read edge between m1, where c3ReadEdgeDiffLoader + * // Step #1: Establish a read edge between m1x, where c3ReadEdgeDiffLoader * // is defined, and the System ClassLoader's unnamed module, * // where MyDiffClassLoader is defined. This read edge * // is needed before we can obtain MyDiffClassLoader.loader2's unnamed module. * // - * // Step #2: Establish a read edge between m1, where c3ReadEdgeDiffLoader + * // Step #2: Establish a read edge between m1x, where c3ReadEdgeDiffLoader * // is defined, and the MyDiffClassLoader.loader2's unnamed module, * // where c4 will be defined. * - * // Step #1: read edge m1 -> System ClassLoader's unnamed module - * Module m1 = c3ReadEdgeDiffLoader.class.getModule(); + * // Step #1: read edge m1x -> System ClassLoader's unnamed module + * Module m1x = c3ReadEdgeDiffLoader.class.getModule(); * ClassLoader system_loader = ClassLoader.getSystemClassLoader(); - * Module unnamed_module1 = system_loader.getUnnamedModule(); - * m1.addReads(unnamed_module1); + * Module unnamed_module_one = system_loader.getUnnamedModule(); + * m1x.addReads(unnamed_module_one); * - * // Step #2: read edge m1 -> MyDiffClassLoader.loader2's unnamed module + * // Step #2: read edge m1x -> MyDiffClassLoader.loader2's unnamed module * ClassLoader loader2 = MyDiffClassLoader.loader2; - * Module unnamed_module2 = loader2.getUnnamedModule(); - * m1.addReads(unnamed_module2); + * Module unnamed_module_two = loader2.getUnnamedModule(); + * m1x.addReads(unnamed_module_two); * - * // Attempt access - should succeed since m1 can read + * // Attempt access - should succeed since m1x can read * // MyDiffClassLoader.loader2's unnamed module * c4 c4_obj = new c4(); * c4_obj.method4(); @@ -100,14 +99,14 @@ class p3/c3ReadEdgeDiffLoader { Utf8 "java/lang/Object"; // #31 at 0xDD Utf8 "java/lang/Class"; // #32 at 0xF0 Utf8 "getModule"; // #33 at 0x0102 - Utf8 "()Ljava/lang/reflect/Module;"; // #34 at 0x010E + Utf8 "()Ljava/lang/Module;"; // #34 at 0x010E Utf8 "java/lang/ClassLoader"; // #35 at 0x012D Utf8 "getSystemClassLoader"; // #36 at 0x0145 Utf8 "()Ljava/lang/ClassLoader;"; // #37 at 0x015C Utf8 "getUnnamedModule"; // #38 at 0x0178 - Utf8 "java/lang/reflect/Module"; // #39 at 0x018B + Utf8 "java/lang/Module"; // #39 at 0x018B Utf8 "addReads"; // #40 at 0x01A6 - Utf8 "(Ljava/lang/reflect/Module;)Ljava/lang/reflect/Module;"; // #41 at 0x01B1 + Utf8 "(Ljava/lang/Module;)Ljava/lang/Module;"; // #41 at 0x01B1 Utf8 "myloaders/MyDiffClassLoader"; // #42 at 0x01EA Utf8 "loader2"; // #43 at 0x0208 Utf8 "Lmyloaders/MyDiffClassLoader;"; // #44 at 0x0212 diff --git a/hotspot/test/runtime/modules/AccessCheck/p4/c4.java b/hotspot/test/runtime/modules/AccessCheck/p4/c4.java index d0098674672..8df98a646f8 100644 --- a/hotspot/test/runtime/modules/AccessCheck/p4/c4.java +++ b/hotspot/test/runtime/modules/AccessCheck/p4/c4.java @@ -25,8 +25,6 @@ package p4; -import java.lang.reflect.Module; - public class c4 { // Add a read edge from c4's module to given module m public void addReads(Module m) { diff --git a/hotspot/test/runtime/modules/AccessCheckAllUnnamed.java b/hotspot/test/runtime/modules/AccessCheckAllUnnamed.java index 7872d0d3306..69ee6d6cf31 100644 --- a/hotspot/test/runtime/modules/AccessCheckAllUnnamed.java +++ b/hotspot/test/runtime/modules/AccessCheckAllUnnamed.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,6 @@ * questions. */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; /* @@ -31,7 +30,7 @@ import static jdk.test.lib.Asserts.*; * @compile p2/c2.java * @compile p1/c1.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI AccessCheckAllUnnamed @@ -43,28 +42,28 @@ public class AccessCheckAllUnnamed { // and then test that a class in the unnamed module can access a package in a // named module that has been exported to all unnamed modules. public static void main(String args[]) throws Throwable { - Object m1, m2; + Object m1x, m2x; - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlM = jlObject.getModule(); + assertNotNull(jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for AccessCheckWorks and assume it's also used to // load class p2.c2. ClassLoader this_cldr = AccessCheckAllUnnamed.class.getClassLoader(); // Define a module for p3. - m1 = ModuleHelper.ModuleObject("module1", this_cldr, new String[] { "p3" }); - assertNotNull(m1, "Module should not be null"); - ModuleHelper.DefineModule(m1, "9.0", "m1/there", new String[] { "p3" }); - ModuleHelper.AddReadsModule(m1, jlObject_jlrM); + m1x = ModuleHelper.ModuleObject("module_one", this_cldr, new String[] { "p3" }); + assertNotNull(m1x, "Module should not be null"); + ModuleHelper.DefineModule(m1x, "9.0", "m1x/there", new String[] { "p3" }); + ModuleHelper.AddReadsModule(m1x, jlM); // Define a module for p2. - m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); - ModuleHelper.AddReadsModule(m2, jlObject_jlrM); + m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); + ModuleHelper.AddReadsModule(m2x, jlM); try { ModuleHelper.AddModuleExportsToAllUnnamed((Module)null, "p2"); @@ -74,7 +73,7 @@ public class AccessCheckAllUnnamed { } try { - ModuleHelper.AddModuleExportsToAllUnnamed(m2, null); + ModuleHelper.AddModuleExportsToAllUnnamed(m2x, null); throw new RuntimeException("Failed to get the expected NPE for null package"); } catch(NullPointerException e) { // Expected @@ -88,21 +87,21 @@ public class AccessCheckAllUnnamed { } try { - ModuleHelper.AddModuleExportsToAllUnnamed(m2, "p3"); + ModuleHelper.AddModuleExportsToAllUnnamed(m2x, "p3"); throw new RuntimeException("Failed to get the expected IAE for package in other module"); } catch(IllegalArgumentException e) { // Expected } try { - ModuleHelper.AddModuleExportsToAllUnnamed(m2, "p4"); + ModuleHelper.AddModuleExportsToAllUnnamed(m2x, "p4"); throw new RuntimeException("Failed to get the expected IAE for package not in module"); } catch(IllegalArgumentException e) { // Expected } - // Export package p2 in m2 to allUnnamed. - ModuleHelper.AddModuleExportsToAllUnnamed(m2, "p2"); + // Export package p2 in m2x to allUnnamed. + ModuleHelper.AddModuleExportsToAllUnnamed(m2x, "p2"); // p1.c1's ctor tries to call a method in p2.c2. This should succeed because // p1 is in an unnamed module and p2.c2 is exported to all unnamed modules. diff --git a/hotspot/test/runtime/modules/AccessCheckExp.java b/hotspot/test/runtime/modules/AccessCheckExp.java index fa624b0783a..18c02937a82 100644 --- a/hotspot/test/runtime/modules/AccessCheckExp.java +++ b/hotspot/test/runtime/modules/AccessCheckExp.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,54 +28,53 @@ * @compile p2/c2.java * @compile p1/c1.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI AccessCheckExp */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; public class AccessCheckExp { - // Test that if module1 can read module2, but package p2 in module2 is not - // exported then class p1.c1 in module1 can not read p2.c2 in module2. + // Test that if module_one can read module_two, but package p2 in module_two is not + // exported then class p1.c1 in module_one can not read p2.c2 in module_two. public static void main(String args[]) throws Throwable { - Object m1, m2; + Object m1x, m2x; - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for AccessCheckExp and assume it's also used to // load classes p1.c1 and p2.c2. ClassLoader this_cldr = AccessCheckExp.class.getClassLoader(); // Define a module for p1. - m1 = ModuleHelper.ModuleObject("module1", this_cldr, new String[] { "p1" }); - assertNotNull(m1, "Module should not be null"); - ModuleHelper.DefineModule(m1, "9.0", "m1/here", new String[] { "p1" }); - ModuleHelper.AddReadsModule(m1, jlObject_jlrM); + m1x = ModuleHelper.ModuleObject("module_one", this_cldr, new String[] { "p1" }); + assertNotNull(m1x, "Module should not be null"); + ModuleHelper.DefineModule(m1x, "9.0", "m1x/here", new String[] { "p1" }); + ModuleHelper.AddReadsModule(m1x, jlObject_jlM); // Define a module for p2. - m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); - ModuleHelper.AddReadsModule(m2, jlObject_jlrM); + m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); + ModuleHelper.AddReadsModule(m2x, jlObject_jlM); - // Make package p1 in m1 visible to everyone. - ModuleHelper.AddModuleExportsToAll(m1, "p1"); + // Make package p1 in m1x visible to everyone. + ModuleHelper.AddModuleExportsToAll(m1x, "p1"); // p1.c1's ctor tries to call a method in p2.c2, but p2.c2 is not // exported. So should get IllegalAccessError. - ModuleHelper.AddReadsModule(m1, m2); + ModuleHelper.AddReadsModule(m1x, m2x); Class p1_c1_class = Class.forName("p1.c1"); try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is not exported"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is not exported"); } catch (IllegalAccessError f) { System.out.println(f.getMessage()); if (!f.getMessage().contains("does not export")) { diff --git a/hotspot/test/runtime/modules/AccessCheckJavaBase.java b/hotspot/test/runtime/modules/AccessCheckJavaBase.java index 24f2f77e115..0402f129658 100644 --- a/hotspot/test/runtime/modules/AccessCheckJavaBase.java +++ b/hotspot/test/runtime/modules/AccessCheckJavaBase.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,27 +27,26 @@ * @library /test/lib .. * @compile p2/c2.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI AccessCheckJavaBase */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; public class AccessCheckJavaBase { - // Test that a class defined to module2 always can read java.base. + // Test that a class defined to module_two always can read java.base. public static void main(String args[]) throws Throwable { // Get the class loader for AccessCheckJavaBase and assume it's also used to // load class p2.c2. ClassLoader this_cldr = AccessCheckJavaBase.class.getClassLoader(); // Define a module for p2. - Object m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); + Object m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); // p2.c2 can read its superclass java.lang.Object defined within java.base try { diff --git a/hotspot/test/runtime/modules/AccessCheckRead.java b/hotspot/test/runtime/modules/AccessCheckRead.java index a36268ace02..c25c33a61da 100644 --- a/hotspot/test/runtime/modules/AccessCheckRead.java +++ b/hotspot/test/runtime/modules/AccessCheckRead.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,45 +28,44 @@ * @compile p2/c2.java * @compile p1/c1.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI AccessCheckRead */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; public class AccessCheckRead { - // Test that a class in a package in module1 cannot access a class in - // a package n module2 if module1 cannot read module2. + // Test that a class in a package in module_one cannot access a class in + // a package in module_two if module_one cannot read module_two. public static void main(String args[]) throws Throwable { - Object m1, m2; + Object m1x, m2x; - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for AccessCheckRead and assume it's also used to // load classes p1.c1 and p2.c2. ClassLoader this_cldr = AccessCheckRead.class.getClassLoader(); // Define a module for p1. - m1 = ModuleHelper.ModuleObject("module1", this_cldr, new String[] { "p1" }); - assertNotNull(m1, "Module should not be null"); - ModuleHelper.DefineModule(m1, "9.0", "m1/here", new String[] { "p1" }); - ModuleHelper.AddReadsModule(m1, jlObject_jlrM); + m1x = ModuleHelper.ModuleObject("module_one", this_cldr, new String[] { "p1" }); + assertNotNull(m1x, "Module should not be null"); + ModuleHelper.DefineModule(m1x, "9.0", "m1x/here", new String[] { "p1" }); + ModuleHelper.AddReadsModule(m1x, jlObject_jlM); // Define a module for p2. - m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); - ModuleHelper.AddReadsModule(m2, jlObject_jlrM); + m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); + ModuleHelper.AddReadsModule(m2x, jlObject_jlM); - // Make package p1 in m1 visible to everyone. - ModuleHelper.AddModuleExportsToAll(m1, "p1"); + // Make package p1 in m1x visible to everyone. + ModuleHelper.AddModuleExportsToAll(m1x, "p1"); Class p1_c1_class = Class.forName("p1.c1"); @@ -74,7 +73,7 @@ public class AccessCheckRead { // cannot read p2's module. So should get IllegalAccessError. try { p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (m1 can't read m2)"); + throw new RuntimeException("Failed to get IAE (m1x can't read m2x)"); } catch (IllegalAccessError e) { System.out.println(e.getMessage()); if (!e.getMessage().contains("does not read") || diff --git a/hotspot/test/runtime/modules/AccessCheckSuper.java b/hotspot/test/runtime/modules/AccessCheckSuper.java index 594c1921e0f..c227db254a1 100644 --- a/hotspot/test/runtime/modules/AccessCheckSuper.java +++ b/hotspot/test/runtime/modules/AccessCheckSuper.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,13 +28,12 @@ * @compile p2/c2.java * @compile p3/c3.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI AccessCheckSuper */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; public class AccessCheckSuper { @@ -48,17 +47,17 @@ public class AccessCheckSuper { ClassLoader this_cldr = AccessCheckSuper.class.getClassLoader(); // Define a module for p2. - Object m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); + Object m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); // Define a module for p3. - Object m3 = ModuleHelper.ModuleObject("module3", this_cldr, new String[] { "p3" }); - assertNotNull(m3, "Module should not be null"); - ModuleHelper.DefineModule(m3, "9.0", "m3/there", new String[] { "p3" }); + Object m3x = ModuleHelper.ModuleObject("module_three", this_cldr, new String[] { "p3" }); + assertNotNull(m3x, "Module should not be null"); + ModuleHelper.DefineModule(m3x, "9.0", "m3x/there", new String[] { "p3" }); - // Since a readability edge has not been established between module2 - // and module3, p3.c3 cannot read its superclass p2.c2. + // Since a readability edge has not been established between module_two + // and module_three, p3.c3 cannot read its superclass p2.c2. try { Class p3_c3_class = Class.forName("p3.c3"); throw new RuntimeException("Failed to get IAE (can't read superclass)"); diff --git a/hotspot/test/runtime/modules/AccessCheckUnnamed.java b/hotspot/test/runtime/modules/AccessCheckUnnamed.java index 4a2ab3e4951..14b48b107b6 100644 --- a/hotspot/test/runtime/modules/AccessCheckUnnamed.java +++ b/hotspot/test/runtime/modules/AccessCheckUnnamed.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,6 @@ * questions. */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; /* @@ -31,7 +30,7 @@ import static jdk.test.lib.Asserts.*; * @compile p2/c2.java * @compile p1/c1.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI AccessCheckUnnamed @@ -42,29 +41,29 @@ public class AccessCheckUnnamed { // Test that a class in the unnamed module can not access a package in a // named module that has not been unqualifiedly exported. public static void main(String args[]) throws Throwable { - Object m1, m2; + Object m1x, m2x; - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for AccessCheckWorks and assume it's also used to // load class p2.c2. ClassLoader this_cldr = AccessCheckUnnamed.class.getClassLoader(); // Define a module for p2. - m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); - ModuleHelper.AddReadsModule(m2, jlObject_jlrM); + m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); + ModuleHelper.AddReadsModule(m2x, jlObject_jlM); // p1.c1's ctor tries to call a method in p2.c2. This should fail because // p1 is in the unnamed module and p2.c2 is not unqualifiedly exported. Class p1_c1_class = Class.forName("p1.c1"); try { Object c1_obj = p1_c1_class.newInstance(); - throw new RuntimeException("Failed to get IAE (p2 in m2 is not exported to unnamed module)"); + throw new RuntimeException("Failed to get IAE (p2 in m2x is not exported to unnamed module)"); } catch (IllegalAccessError f) { System.out.println(f.getMessage()); if (!f.getMessage().contains("does not export p2 to unnamed module")) { diff --git a/hotspot/test/runtime/modules/AccessCheckWorks.java b/hotspot/test/runtime/modules/AccessCheckWorks.java index 48d6660f195..9cb638ade3a 100644 --- a/hotspot/test/runtime/modules/AccessCheckWorks.java +++ b/hotspot/test/runtime/modules/AccessCheckWorks.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,51 +28,50 @@ * @compile p2/c2.java * @compile p1/c1.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI AccessCheckWorks */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; public class AccessCheckWorks { - // Check that a class in a package in module1 can successfully access a - // class in module2 when module1 can read module2 and the class's package + // Check that a class in a package in module_one can successfully access a + // class in module_two when module_one can read module_two and the class's package // has been exported. public static void main(String args[]) throws Throwable { - Object m1, m2; + Object m1x, m2x; - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for AccessCheckWorks and assume it's also used to // load classes p1.c1 and p2.c2. ClassLoader this_cldr = AccessCheckWorks.class.getClassLoader(); // Define a module for p1. - m1 = ModuleHelper.ModuleObject("module1", this_cldr, new String[] { "p1" }); - assertNotNull(m1, "Module should not be null"); - ModuleHelper.DefineModule(m1, "9.0", "m1/here", new String[] { "p1" }); - ModuleHelper.AddReadsModule(m1, jlObject_jlrM); + m1x = ModuleHelper.ModuleObject("module_one", this_cldr, new String[] { "p1" }); + assertNotNull(m1x, "Module should not be null"); + ModuleHelper.DefineModule(m1x, "9.0", "m1x/here", new String[] { "p1" }); + ModuleHelper.AddReadsModule(m1x, jlObject_jlM); // Define a module for p2. - m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); - ModuleHelper.AddReadsModule(m2, jlObject_jlrM); + m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); + ModuleHelper.AddReadsModule(m2x, jlObject_jlM); - // Make package p1 in m1 visible to everyone. - ModuleHelper.AddModuleExportsToAll(m1, "p1"); + // Make package p1 in m1x visible to everyone. + ModuleHelper.AddModuleExportsToAll(m1x, "p1"); // p1.c1's ctor tries to call a method in p2.c2. This should work because // p1's module can read p2's module and p2 is exported to p1's module. - ModuleHelper.AddReadsModule(m1, m2); - ModuleHelper.AddModuleExports(m2, "p2", m1); + ModuleHelper.AddReadsModule(m1x, m2x); + ModuleHelper.AddModuleExports(m2x, "p2", m1x); Class p1_c1_class = Class.forName("p1.c1"); p1_c1_class.newInstance(); } diff --git a/hotspot/test/runtime/modules/CCE_module_msg.java b/hotspot/test/runtime/modules/CCE_module_msg.java index 38ff41fde2d..7e593dfcee9 100644 --- a/hotspot/test/runtime/modules/CCE_module_msg.java +++ b/hotspot/test/runtime/modules/CCE_module_msg.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,14 +28,13 @@ * @compile p2/c2.java * @compile p4/c4.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI CCE_module_msg */ import java.io.*; -import java.lang.reflect.Module; import java.net.URL; import java.net.URLClassLoader; import java.nio.file.Path; @@ -73,31 +72,31 @@ public class CCE_module_msg { } public static void invalidClassToString() throws Throwable { - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for CCE_module_msg and assume it's also used to // load classes p1.c1 and p2.c2. ClassLoader this_cldr = CCE_module_msg.class.getClassLoader(); // Define a module for p2. - Object m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); - ModuleHelper.AddReadsModule(m2, jlObject_jlrM); + Object m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); + ModuleHelper.AddReadsModule(m2x, jlObject_jlM); try { - ModuleHelper.AddModuleExportsToAll(m2, "p2"); + ModuleHelper.AddModuleExportsToAll(m2x, "p2"); Object p2Obj = new p2.c2(); System.out.println((String)p2Obj); throw new RuntimeException("ClassCastException wasn't thrown, test failed."); } catch (ClassCastException cce) { String exception = cce.getMessage(); System.out.println(exception); - if (exception.contains("module2/p2.c2") || - !(exception.contains("module2@") && + if (exception.contains("module_two/p2.c2") || + !(exception.contains("module_two@") && exception.contains("/p2.c2 cannot be cast to java.base/java.lang.String"))) { throw new RuntimeException("Wrong message: " + exception); } @@ -105,10 +104,10 @@ public class CCE_module_msg { } public static void invalidClassToStringCustomLoader() throws Throwable { - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Create a customer class loader to load class p4/c4. URL[] urls = new URL[] { CLASSES_DIR.toUri().toURL() }; diff --git a/hotspot/test/runtime/modules/ExportTwice.java b/hotspot/test/runtime/modules/ExportTwice.java index 538c65926c0..abdad3a7822 100644 --- a/hotspot/test/runtime/modules/ExportTwice.java +++ b/hotspot/test/runtime/modules/ExportTwice.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,13 +28,12 @@ * @compile p2/c2.java * @compile p1/c1.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI ExportTwice */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; public class ExportTwice { @@ -44,49 +43,49 @@ public class ExportTwice { // Also, check that a package can be exported to a specific package and then // exported unqualifiedly. public static void main(String args[]) throws Throwable { - Object m1, m2, m3; + Object m1x, m2x, m3x; - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for ExportTwice and assume it's also used to // load classes p1.c1 and p2.c2. ClassLoader this_cldr = ExportTwice.class.getClassLoader(); // Define a module for p1. - m1 = ModuleHelper.ModuleObject("module1", this_cldr, new String[] { "p1" }); - assertNotNull(m1, "Module should not be null"); - ModuleHelper.DefineModule(m1, "9.0", "m1/here", new String[] { "p1" }); - ModuleHelper.AddReadsModule(m1, jlObject_jlrM); + m1x = ModuleHelper.ModuleObject("module_one", this_cldr, new String[] { "p1" }); + assertNotNull(m1x, "Module should not be null"); + ModuleHelper.DefineModule(m1x, "9.0", "m1x/here", new String[] { "p1" }); + ModuleHelper.AddReadsModule(m1x, jlObject_jlM); // Define a module for p2. - m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); - ModuleHelper.AddReadsModule(m2, jlObject_jlrM); + m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); + ModuleHelper.AddReadsModule(m2x, jlObject_jlM); // Define a module for p3. - m3 = ModuleHelper.ModuleObject("module3", this_cldr, new String[] { "p3" }); - assertNotNull(m3, "Module should not be null"); - ModuleHelper.DefineModule(m3, "9.0", "m3/there", new String[] { "p3" }); - ModuleHelper.AddReadsModule(m3, jlObject_jlrM); + m3x = ModuleHelper.ModuleObject("module_three", this_cldr, new String[] { "p3" }); + assertNotNull(m3x, "Module should not be null"); + ModuleHelper.DefineModule(m3x, "9.0", "m3x/there", new String[] { "p3" }); + ModuleHelper.AddReadsModule(m3x, jlObject_jlM); - // Make package p1 in m1 visible to everyone. - ModuleHelper.AddModuleExportsToAll(m1, "p1"); + // Make package p1 in m1x visible to everyone. + ModuleHelper.AddModuleExportsToAll(m1x, "p1"); - // Try to export p1 only to m2 after it was exported unqualifiedly. It + // Try to export p1 only to m2x after it was exported unqualifiedly. It // should silently succeed. - ModuleHelper.AddModuleExports(m1, "p1", m2); + ModuleHelper.AddModuleExports(m1x, "p1", m2x); - // Export p2 to m3 then export it again unqualifiedly. - ModuleHelper.AddModuleExports(m2, "p2", m3); - ModuleHelper.AddModuleExportsToAll(m2, "p2"); + // Export p2 to m3x then export it again unqualifiedly. + ModuleHelper.AddModuleExports(m2x, "p2", m3x); + ModuleHelper.AddModuleExportsToAll(m2x, "p2"); // p1.c1's ctor tries to call a method in p2.c2. This should work because // p1's module can read p2's module and p2 is now exported unqualifiedly. - ModuleHelper.AddReadsModule(m1, m2); + ModuleHelper.AddReadsModule(m1x, m2x); Class p1_c1_class = Class.forName("p1.c1"); p1_c1_class.newInstance(); } diff --git a/hotspot/test/runtime/modules/IgnoreModulePropertiesTest.java b/hotspot/test/runtime/modules/IgnoreModulePropertiesTest.java index e3748530fa7..0d7b2f60e14 100644 --- a/hotspot/test/runtime/modules/IgnoreModulePropertiesTest.java +++ b/hotspot/test/runtime/modules/IgnoreModulePropertiesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -44,7 +44,7 @@ public class IgnoreModulePropertiesTest { ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( "-D" + prop + "=" + value, "-version"); OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("java version "); + output.shouldContain(" version "); output.shouldHaveExitValue(0); // Ensure that the property and its value aren't available. @@ -67,8 +67,8 @@ public class IgnoreModulePropertiesTest { } public static void main(String[] args) throws Exception { - testOption("--add-modules", "java.sqlx", "jdk.module.addmods.0", "java.lang.module.ResolutionException"); - testOption("--limit-modules", "java.sqlx", "jdk.module.limitmods", "java.lang.module.ResolutionException"); + testOption("--add-modules", "java.sqlx", "jdk.module.addmods.0", "java.lang.module.FindException"); + testOption("--limit-modules", "java.sqlx", "jdk.module.limitmods", "java.lang.module.FindException"); testOption("--add-reads", "xyzz=yyzd", "jdk.module.addreads.0", "WARNING: Unknown module: xyzz"); testOption("--add-exports", "java.base/xyzz=yyzd", "jdk.module.addexports.0", "WARNING: package xyzz not in java.base"); diff --git a/hotspot/test/runtime/modules/JVMAddModuleExportToAllUnnamed.java b/hotspot/test/runtime/modules/JVMAddModuleExportToAllUnnamed.java index 7a08787c696..71fba9816f2 100644 --- a/hotspot/test/runtime/modules/JVMAddModuleExportToAllUnnamed.java +++ b/hotspot/test/runtime/modules/JVMAddModuleExportToAllUnnamed.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,37 +30,36 @@ * @build sun.hotspot.WhiteBox * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI JVMAddModuleExportToAllUnnamed */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; public class JVMAddModuleExportToAllUnnamed { - // Check that a class in a package in module1 cannot access a class + // Check that a class in a package in module_one cannot access a class // that is in the unnamed module if the accessing package is strict. public static void main(String args[]) throws Throwable { - Object m1; + Object m1x; - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for JVMAddModuleExportToAllUnnamed and assume it's also used to // load class p1.c1. ClassLoader this_cldr = JVMAddModuleExportToAllUnnamed.class.getClassLoader(); // Define a module for p1. - m1 = ModuleHelper.ModuleObject("module1", this_cldr, new String[] { "p1" }); - assertNotNull(m1, "Module should not be null"); - ModuleHelper.DefineModule(m1, "9.0", "m1/here", new String[] { "p1" }); - ModuleHelper.AddReadsModule(m1, jlObject_jlrM); + m1x = ModuleHelper.ModuleObject("module_one", this_cldr, new String[] { "p1" }); + assertNotNull(m1x, "Module should not be null"); + ModuleHelper.DefineModule(m1x, "9.0", "m1x/here", new String[] { "p1" }); + ModuleHelper.AddReadsModule(m1x, jlObject_jlM); - // Make package p1 in m1 visible to everyone. - ModuleHelper.AddModuleExportsToAll(m1, "p1"); + // Make package p1 in m1x visible to everyone. + ModuleHelper.AddModuleExportsToAll(m1x, "p1"); // p1.c1's ctor tries to call a method in p2.c2. This should not work // because p2 is in the unnamed module and p1.c1 is strict. diff --git a/hotspot/test/runtime/modules/JVMAddModuleExports.java b/hotspot/test/runtime/modules/JVMAddModuleExports.java index 689523639f4..da839829610 100644 --- a/hotspot/test/runtime/modules/JVMAddModuleExports.java +++ b/hotspot/test/runtime/modules/JVMAddModuleExports.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,13 +26,12 @@ * @modules java.base/jdk.internal.misc * @library /test/lib .. * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI JVMAddModuleExports */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; public class JVMAddModuleExports { @@ -42,12 +41,12 @@ public class JVMAddModuleExports { MyClassLoader to_cl = new MyClassLoader(); Module from_module, to_module; - from_module = ModuleHelper.ModuleObject("from_module", from_cl, new String[] { "mypackage", "this/package" }); + from_module = ModuleHelper.ModuleObject("from_module", from_cl, new String[] { "mypackage", "x/apackage" }); assertNotNull(from_module, "Module should not be null"); - ModuleHelper.DefineModule(from_module, "9.0", "from_module/here", new String[] { "mypackage", "this/package" }); - to_module = ModuleHelper.ModuleObject("to_module", to_cl, new String[] { "yourpackage", "that/package" }); + ModuleHelper.DefineModule(from_module, "9.0", "from_module/here", new String[] { "mypackage", "x/apackage" }); + to_module = ModuleHelper.ModuleObject("to_module", to_cl, new String[] { "yourpackage", "that/apackage" }); assertNotNull(to_module, "Module should not be null"); - ModuleHelper.DefineModule(to_module, "9.0", "to_module/here", new String[] { "yourpackage", "that/package" }); + ModuleHelper.DefineModule(to_module, "9.0", "to_module/here", new String[] { "yourpackage", "that/apackage" }); // Null from_module argument, expect an NPE try { @@ -118,19 +117,19 @@ public class JVMAddModuleExports { // Export a package, that is not in from_module, to from_module try { - ModuleHelper.AddModuleExports(from_module, "that/package", from_module); + ModuleHelper.AddModuleExports(from_module, "that/apackage", from_module); throw new RuntimeException("Failed to get the expected IAE"); } catch(IllegalArgumentException e) { // Expected } // Export the same package twice to the same module - ModuleHelper.AddModuleExports(from_module, "this/package", to_module); - ModuleHelper.AddModuleExports(from_module, "this/package", to_module); + ModuleHelper.AddModuleExports(from_module, "x/apackage", to_module); + ModuleHelper.AddModuleExports(from_module, "x/apackage", to_module); // Export a package, using '.' instead of '/' try { - ModuleHelper.AddModuleExports(from_module, "this.package", to_module); + ModuleHelper.AddModuleExports(from_module, "x.apackage", to_module); throw new RuntimeException("Failed to get the expected IAE"); } catch(IllegalArgumentException e) { // Expected @@ -138,8 +137,8 @@ public class JVMAddModuleExports { // Export a package to the unnamed module and then to a specific module. // The qualified export should be ignored. - ModuleHelper.AddModuleExportsToAll(to_module, "that/package"); - ModuleHelper.AddModuleExports(to_module, "that/package", from_module); + ModuleHelper.AddModuleExportsToAll(to_module, "that/apackage"); + ModuleHelper.AddModuleExports(to_module, "that/apackage", from_module); } static class MyClassLoader extends ClassLoader { } diff --git a/hotspot/test/runtime/modules/JVMAddModuleExportsToAll.java b/hotspot/test/runtime/modules/JVMAddModuleExportsToAll.java index 80db658a99d..f6499644b48 100644 --- a/hotspot/test/runtime/modules/JVMAddModuleExportsToAll.java +++ b/hotspot/test/runtime/modules/JVMAddModuleExportsToAll.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,6 @@ * questions. */ -import java.lang.reflect.Module; import static jdk.test.lib.Asserts.*; /* @@ -31,7 +30,7 @@ import static jdk.test.lib.Asserts.*; * @compile p2/c2.java * @compile p1/c1.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI JVMAddModuleExportsToAll @@ -43,28 +42,28 @@ public class JVMAddModuleExportsToAll { // and then test that a class in the unnamed module can access a package in // a named module that has been exported unqualifiedly. public static void main(String args[]) throws Throwable { - Object m1, m2, m3; + Object m1x, m2x, m3x; - // Get the java.lang.reflect.Module object for module java.base. + // Get the java.lang.Module object for module java.base. Class jlObject = Class.forName("java.lang.Object"); - Object jlObject_jlrM = jlObject.getModule(); - assertNotNull(jlObject_jlrM, "jlrModule object of java.lang.Object should not be null"); + Object jlObject_jlM = jlObject.getModule(); + assertNotNull(jlObject_jlM, "jlModule object of java.lang.Object should not be null"); // Get the class loader for JVMAddModuleExportsToAll and assume it's also used to // load class p2.c2. ClassLoader this_cldr = JVMAddModuleExportsToAll.class.getClassLoader(); // Define a module for p3. - m1 = ModuleHelper.ModuleObject("module1", this_cldr, new String[] { "p3" }); - assertNotNull(m1, "Module should not be null"); - ModuleHelper.DefineModule(m1, "9.0", "m1/there", new String[] { "p3" }); - ModuleHelper.AddReadsModule(m1, jlObject_jlrM); + m1x = ModuleHelper.ModuleObject("module_one", this_cldr, new String[] { "p3" }); + assertNotNull(m1x, "Module should not be null"); + ModuleHelper.DefineModule(m1x, "9.0", "m1x/there", new String[] { "p3" }); + ModuleHelper.AddReadsModule(m1x, jlObject_jlM); // Define a module for p2. - m2 = ModuleHelper.ModuleObject("module2", this_cldr, new String[] { "p2" }); - assertNotNull(m2, "Module should not be null"); - ModuleHelper.DefineModule(m2, "9.0", "m2/there", new String[] { "p2" }); - ModuleHelper.AddReadsModule(m2, jlObject_jlrM); + m2x = ModuleHelper.ModuleObject("module_two", this_cldr, new String[] { "p2" }); + assertNotNull(m2x, "Module should not be null"); + ModuleHelper.DefineModule(m2x, "9.0", "m2x/there", new String[] { "p2" }); + ModuleHelper.AddReadsModule(m2x, jlObject_jlM); try { ModuleHelper.AddModuleExportsToAll((Module)null, "p2"); @@ -74,13 +73,13 @@ public class JVMAddModuleExportsToAll { } try { - ModuleHelper.AddModuleExportsToAll(m2, null); + ModuleHelper.AddModuleExportsToAll(m2x, null); throw new RuntimeException("Failed to get the expected NPE for null package"); } catch(NullPointerException e) { // Expected } - try { // Expect IAE when passing a ClassLoader object instead of a java.lang.reflect.Module object. + try { // Expect IAE when passing a ClassLoader object instead of a java.lang.Module object. ModuleHelper.AddModuleExportsToAll(this_cldr, "p2"); throw new RuntimeException("Failed to get the expected IAE for bad module"); } catch(IllegalArgumentException e) { @@ -88,26 +87,26 @@ public class JVMAddModuleExportsToAll { } try { - ModuleHelper.AddModuleExportsToAll(m2, "p3"); + ModuleHelper.AddModuleExportsToAll(m2x, "p3"); throw new RuntimeException("Failed to get the expected IAE for package that is in another module"); } catch(IllegalArgumentException e) { // Expected } try { - ModuleHelper.AddModuleExportsToAll(m2, "p4"); + ModuleHelper.AddModuleExportsToAll(m2x, "p4"); throw new RuntimeException("Failed to get the expected IAE for package not in any module"); } catch(IllegalArgumentException e) { // Expected } - // Export package p2 in m2 unqualifiedly. Then, do a qualified export - // of p2 in m2 to m3. This should not affect the unqualified export. - m3 = ModuleHelper.ModuleObject("module3", this_cldr, new String[] { "p4" }); - assertNotNull(m3, "Module m3 should not be null"); - ModuleHelper.DefineModule(m3, "9.0", "m3/there", new String[] { "p4" }); - ModuleHelper.AddModuleExportsToAll(m2, "p2"); - ModuleHelper.AddModuleExports(m2, "p2", m3); + // Export package p2 in m2x unqualifiedly. Then, do a qualified export + // of p2 in m2x to m3x. This should not affect the unqualified export. + m3x = ModuleHelper.ModuleObject("module_three", this_cldr, new String[] { "p4" }); + assertNotNull(m3x, "Module m3x should not be null"); + ModuleHelper.DefineModule(m3x, "9.0", "m3x/there", new String[] { "p4" }); + ModuleHelper.AddModuleExportsToAll(m2x, "p2"); + ModuleHelper.AddModuleExports(m2x, "p2", m3x); // p1.c1's ctor tries to call a method in p2.c2. This should succeed because // p1 is in an unnamed module and p2.c2 is exported unqualifiedly. diff --git a/hotspot/test/runtime/modules/JVMAddModulePackage.java b/hotspot/test/runtime/modules/JVMAddModulePackage.java index 3f7f2fd29a0..dc2237f39e3 100644 --- a/hotspot/test/runtime/modules/JVMAddModulePackage.java +++ b/hotspot/test/runtime/modules/JVMAddModulePackage.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,7 @@ * @modules java.base/jdk.internal.misc * @library /test/lib .. * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI JVMAddModulePackage @@ -40,25 +40,25 @@ public class JVMAddModulePackage { public static void main(String args[]) throws Throwable { MyClassLoader cl1 = new MyClassLoader(); MyClassLoader cl3 = new MyClassLoader(); - Object module1, module2, module3; + Object module_one, module_two, module_three; boolean result; - module1 = ModuleHelper.ModuleObject("module1", cl1, new String[] { "mypackage" }); - assertNotNull(module1, "Module should not be null"); - ModuleHelper.DefineModule(module1, "9.0", "module1/here", new String[] { "mypackage" }); - module2 = ModuleHelper.ModuleObject("module2", cl1, new String[] { "yourpackage" }); - assertNotNull(module2, "Module should not be null"); - ModuleHelper.DefineModule(module2, "9.0", "module2/here", new String[] { "yourpackage" }); - module3 = ModuleHelper.ModuleObject("module3", cl3, new String[] { "package/num3" }); - assertNotNull(module3, "Module should not be null"); - ModuleHelper.DefineModule(module3, "9.0", "module3/here", new String[] { "package/num3" }); + module_one = ModuleHelper.ModuleObject("module_one", cl1, new String[] { "mypackage" }); + assertNotNull(module_one, "Module should not be null"); + ModuleHelper.DefineModule(module_one, "9.0", "module_one/here", new String[] { "mypackage" }); + module_two = ModuleHelper.ModuleObject("module_two", cl1, new String[] { "yourpackage" }); + assertNotNull(module_two, "Module should not be null"); + ModuleHelper.DefineModule(module_two, "9.0", "module_two/here", new String[] { "yourpackage" }); + module_three = ModuleHelper.ModuleObject("module_three", cl3, new String[] { "apackage/num3" }); + assertNotNull(module_three, "Module should not be null"); + ModuleHelper.DefineModule(module_three, "9.0", "module_three/here", new String[] { "apackage/num3" }); // Simple call - ModuleHelper.AddModulePackage(module1, "new_package"); + ModuleHelper.AddModulePackage(module_one, "new_package"); // Add a package and export it - ModuleHelper.AddModulePackage(module1, "package/num3"); - ModuleHelper.AddModuleExportsToAll(module1, "package/num3"); + ModuleHelper.AddModulePackage(module_one, "apackage/num3"); + ModuleHelper.AddModuleExportsToAll(module_one, "apackage/num3"); // Null module argument, expect an NPE try { @@ -78,7 +78,7 @@ public class JVMAddModulePackage { // Null package argument, expect an NPE try { - ModuleHelper.AddModulePackage(module1, null); + ModuleHelper.AddModulePackage(module_one, null); throw new RuntimeException("Failed to get the expected NPE"); } catch(NullPointerException e) { // Expected @@ -86,7 +86,7 @@ public class JVMAddModulePackage { // Existing package, expect an ISE try { - ModuleHelper.AddModulePackage(module1, "yourpackage"); + ModuleHelper.AddModulePackage(module_one, "yourpackage"); throw new RuntimeException("Failed to get the expected ISE"); } catch(IllegalStateException e) { // Expected @@ -94,7 +94,7 @@ public class JVMAddModulePackage { // Invalid package name, expect an IAE try { - ModuleHelper.AddModulePackage(module1, "your.package"); + ModuleHelper.AddModulePackage(module_one, "your.apackage"); throw new RuntimeException("Failed to get the expected IAE"); } catch(IllegalArgumentException e) { // Expected @@ -102,7 +102,7 @@ public class JVMAddModulePackage { // Invalid package name, expect an IAE try { - ModuleHelper.AddModulePackage(module1, ";your/package"); + ModuleHelper.AddModulePackage(module_one, ";your/apackage"); throw new RuntimeException("Failed to get the expected IAE"); } catch(IllegalArgumentException e) { // Expected @@ -110,7 +110,7 @@ public class JVMAddModulePackage { // Invalid package name, expect an IAE try { - ModuleHelper.AddModulePackage(module1, "7[743"); + ModuleHelper.AddModulePackage(module_one, "7[743"); throw new RuntimeException("Failed to get the expected IAE"); } catch(IllegalArgumentException e) { // Expected @@ -118,7 +118,7 @@ public class JVMAddModulePackage { // Empty package name, expect an IAE try { - ModuleHelper.AddModulePackage(module1, ""); + ModuleHelper.AddModulePackage(module_one, ""); throw new RuntimeException("Failed to get the expected IAE"); } catch(IllegalArgumentException e) { // Expected @@ -126,8 +126,8 @@ public class JVMAddModulePackage { // Add package named "java" to an module defined to a class loader other than the boot or platform loader. try { - // module1 is defined to a MyClassLoader class loader. - ModuleHelper.AddModulePackage(module1, "java/foo"); + // module_one is defined to a MyClassLoader class loader. + ModuleHelper.AddModulePackage(module_one, "java/foo"); throw new RuntimeException("Failed to get the expected IAE"); } catch(IllegalArgumentException e) { if (!e.getMessage().contains("prohibited package name")) { @@ -136,10 +136,10 @@ public class JVMAddModulePackage { } // Package "javabar" should be ok - ModuleHelper.AddModulePackage(module1, "javabar"); + ModuleHelper.AddModulePackage(module_one, "javabar"); // Package named "java" defined to the boot class loader, should be ok - Object module_javabase = module1.getClass().getModule(); + Object module_javabase = module_one.getClass().getModule(); ModuleHelper.AddModulePackage(module_javabase, "java/foo"); // Package named "java" defined to the platform class loader, should be ok diff --git a/hotspot/test/runtime/modules/JVMAddReadsModule.java b/hotspot/test/runtime/modules/JVMAddReadsModule.java index a25bcfc64f6..bf0b838403e 100644 --- a/hotspot/test/runtime/modules/JVMAddReadsModule.java +++ b/hotspot/test/runtime/modules/JVMAddReadsModule.java @@ -26,7 +26,7 @@ * @modules java.base/jdk.internal.misc * @library /test/lib .. * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI JVMAddReadsModule diff --git a/hotspot/test/runtime/modules/JVMDefineModule.java b/hotspot/test/runtime/modules/JVMDefineModule.java index 9e44878490d..3c40f026100 100644 --- a/hotspot/test/runtime/modules/JVMDefineModule.java +++ b/hotspot/test/runtime/modules/JVMDefineModule.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,7 @@ * @modules java.base/jdk.internal.misc * @library /test/lib .. * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI JVMDefineModule @@ -49,7 +49,7 @@ public class JVMDefineModule { /* Invalid test, won't compile. // Invalid classloader argument, expect an IAE try { - m = ModuleHelper.ModuleObject("mymodule1", new Object(), new String[] { "mypackage1" }); + m = ModuleHelper.ModuleObject("mymodule_one", new Object(), new String[] { "mypackage1" }); ModuleHelper.DefineModule(m, "9.0", "mymodule/here", new String[] { "mypackage1" }); throw new RuntimeException("Failed to get expected IAE for bad loader"); } catch(IllegalArgumentException e) { @@ -78,7 +78,7 @@ public class JVMDefineModule { ModuleHelper.DefineModule(new Object(), "9.0", "mymodule/here", new String[] { "mypackage1" }); throw new RuntimeException("Failed to get expected IAE or NPE for bad module"); } catch(IllegalArgumentException e) { - if (!e.getMessage().contains("module is not an instance of type java.lang.reflect.Module")) { + if (!e.getMessage().contains("module is not an instance of type java.lang.Module")) { throw new RuntimeException("Failed to get expected IAE message for bad module: " + e.getMessage()); } } @@ -207,10 +207,10 @@ public class JVMDefineModule { ModuleHelper.DefineModule(m, "9.0", "module.name/here", new String[] { }); // Invalid package name, expect an IAE - m = ModuleHelper.ModuleObject("moduleFive", cl, new String[] { "your.package" }); + m = ModuleHelper.ModuleObject("moduleFive", cl, new String[] { "your.apackage" }); try { - ModuleHelper.DefineModule(m, "9.0", "module.name/here", new String[] { "your.package" }); - throw new RuntimeException("Failed to get expected IAE for your.package"); + ModuleHelper.DefineModule(m, "9.0", "module.name/here", new String[] { "your.apackage" }); + throw new RuntimeException("Failed to get expected IAE for your.apackage"); } catch(IllegalArgumentException e) { if (!e.getMessage().contains("Invalid package name")) { throw new RuntimeException("Failed to get expected IAE message for bad package name: " + e.getMessage()); @@ -220,8 +220,8 @@ public class JVMDefineModule { // Invalid package name, expect an IAE m = ModuleHelper.ModuleObject("moduleSix", cl, new String[] { "foo" }); // Name irrelevant try { - ModuleHelper.DefineModule(m, "9.0", "module.name/here", new String[] { ";your/package" }); - throw new RuntimeException("Failed to get expected IAE for ;your.package"); + ModuleHelper.DefineModule(m, "9.0", "module.name/here", new String[] { ";your/apackage" }); + throw new RuntimeException("Failed to get expected IAE for ;your.apackage"); } catch(IllegalArgumentException e) { if (!e.getMessage().contains("Invalid package name")) { throw new RuntimeException("Failed to get expected IAE message for bad package name: " + e.getMessage()); diff --git a/hotspot/test/runtime/modules/JVMGetModuleByPkgName.java b/hotspot/test/runtime/modules/JVMGetModuleByPkgName.java index 1f58193c676..da3224826eb 100644 --- a/hotspot/test/runtime/modules/JVMGetModuleByPkgName.java +++ b/hotspot/test/runtime/modules/JVMGetModuleByPkgName.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,7 @@ * @library /test/lib .. * @compile p2/c2.java * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI JVMGetModuleByPkgName @@ -35,7 +35,6 @@ import static jdk.test.lib.Asserts.*; import java.lang.ClassLoader; -import java.lang.reflect.Module; public class JVMGetModuleByPkgName { @@ -79,10 +78,10 @@ public class JVMGetModuleByPkgName { } MyClassLoader cl1 = new MyClassLoader(); - Module module1 = (Module)ModuleHelper.ModuleObject("module1", cl1, new String[] { "mypackage" }); - assertNotNull(module1, "Module should not be null"); - ModuleHelper.DefineModule(module1, "9.0", "module1/here", new String[] { "mypackage" }); - if (ModuleHelper.GetModuleByPackageName(cl1, "mypackage") != module1) { + Module module_one = (Module)ModuleHelper.ModuleObject("module_one", cl1, new String[] { "mypackage" }); + assertNotNull(module_one, "Module should not be null"); + ModuleHelper.DefineModule(module_one, "9.0", "module_one/here", new String[] { "mypackage" }); + if (ModuleHelper.GetModuleByPackageName(cl1, "mypackage") != module_one) { throw new RuntimeException("Wrong module returned for cl1 mypackage"); } } diff --git a/hotspot/test/runtime/modules/LoadUnloadModuleStress.java b/hotspot/test/runtime/modules/LoadUnloadModuleStress.java index 1f27ba9b432..20cde3a5f60 100644 --- a/hotspot/test/runtime/modules/LoadUnloadModuleStress.java +++ b/hotspot/test/runtime/modules/LoadUnloadModuleStress.java @@ -27,7 +27,7 @@ * @modules java.base/jdk.internal.misc * @library /test/lib .. * @build sun.hotspot.WhiteBox - * @compile/module=java.base java/lang/reflect/ModuleHelper.java + * @compile/module=java.base java/lang/ModuleHelper.java * @run main ClassFileInstaller sun.hotspot.WhiteBox * sun.hotspot.WhiteBox$WhiteBoxPermission * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xmx64m -Xmx64m LoadUnloadModuleStress 15000 diff --git a/hotspot/test/runtime/modules/ModuleHelper.java b/hotspot/test/runtime/modules/ModuleHelper.java index 2f0d7f6ec11..e4db0f53a18 100644 --- a/hotspot/test/runtime/modules/ModuleHelper.java +++ b/hotspot/test/runtime/modules/ModuleHelper.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,6 @@ import java.net.URI; import java.lang.module.ModuleDescriptor; -import java.lang.reflect.Module; import java.util.Collections; import java.util.HashSet; import java.util.Set; @@ -41,19 +40,19 @@ public class ModuleHelper { public static void AddModuleExports(Object from, String pkg, Object to) throws Throwable { WhiteBox wb = WhiteBox.getWhiteBox(); wb.AddModuleExports(from, pkg, to); - java.lang.reflect.ModuleHelper.addExportsNoSync((Module)from, pkg, (Module)to); + java.lang.ModuleHelper.addExportsNoSync((Module)from, pkg, (Module)to); } public static void AddReadsModule(Object from, Object to) throws Throwable { WhiteBox wb = WhiteBox.getWhiteBox(); wb.AddReadsModule(from, to); - java.lang.reflect.ModuleHelper.addReadsNoSync((Module)from, (Module)to); + java.lang.ModuleHelper.addReadsNoSync((Module)from, (Module)to); } public static void AddModulePackage(Object m, String pkg) throws Throwable { WhiteBox wb = WhiteBox.getWhiteBox(); wb.AddModulePackage(m, pkg); - java.lang.reflect.ModuleHelper.addPackageNoSync((Module)m, pkg); + java.lang.ModuleHelper.addPackageNoSync((Module)m, pkg); } public static Module GetModuleByPackageName(Object ldr, String pkg) throws Throwable { @@ -64,13 +63,13 @@ public class ModuleHelper { public static void AddModuleExportsToAllUnnamed(Object m, String pkg) throws Throwable { WhiteBox wb = WhiteBox.getWhiteBox(); wb.AddModuleExportsToAllUnnamed(m, pkg); - //java.lang.reflect.ModuleHelper.addExportsToAllUnnamedNoSync((Module)m, pkg); + //java.lang.ModuleHelper.addExportsToAllUnnamedNoSync((Module)m, pkg); } public static void AddModuleExportsToAll(Object m, String pkg) throws Throwable { WhiteBox wb = WhiteBox.getWhiteBox(); wb.AddModuleExportsToAll(m, pkg); - java.lang.reflect.ModuleHelper.addExportsNoSync((Module)m, pkg, (Module)null); + java.lang.ModuleHelper.addExportsNoSync((Module)m, pkg, (Module)null); } public static Module ModuleObject(String name, ClassLoader loader, String[] pkgs) throws Throwable { @@ -84,10 +83,10 @@ public class ModuleHelper { } ModuleDescriptor descriptor = - ModuleDescriptor.module(name).contains(pkg_set).build(); + ModuleDescriptor.newModule(name).packages(pkg_set).build(); URI uri = URI.create("module:/" + name); - return java.lang.reflect.ModuleHelper.newModule(loader, descriptor); + return java.lang.ModuleHelper.newModule(loader, descriptor); } } diff --git a/hotspot/test/runtime/modules/ModuleOptionsTest.java b/hotspot/test/runtime/modules/ModuleOptionsTest.java index 28064bddc27..e526e06abe1 100644 --- a/hotspot/test/runtime/modules/ModuleOptionsTest.java +++ b/hotspot/test/runtime/modules/ModuleOptionsTest.java @@ -43,7 +43,7 @@ public class ModuleOptionsTest { ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( "--add-modules=i_dont_exist", "--add-modules=java.base", "-version"); OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("ResolutionException"); + output.shouldContain("FindException"); output.shouldContain("i_dont_exist"); output.shouldHaveExitValue(1); diff --git a/hotspot/test/runtime/modules/ModuleStress/CustomSystemClassLoader.java b/hotspot/test/runtime/modules/ModuleStress/CustomSystemClassLoader.java index dca359f6458..643e4bfd547 100644 --- a/hotspot/test/runtime/modules/ModuleStress/CustomSystemClassLoader.java +++ b/hotspot/test/runtime/modules/ModuleStress/CustomSystemClassLoader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,7 +22,7 @@ */ /** - * A custom system ClassLoader to define the module "m2" to during iterations of + * A custom system ClassLoader to define the module "m2x" to during iterations of * differing test runs within the test ModuleStress.java */ public class CustomSystemClassLoader extends ClassLoader { diff --git a/hotspot/test/runtime/modules/ModuleStress/ModuleNonBuiltinCLMain.java b/hotspot/test/runtime/modules/ModuleStress/ModuleNonBuiltinCLMain.java index 79e56f2a457..772293f91a8 100644 --- a/hotspot/test/runtime/modules/ModuleStress/ModuleNonBuiltinCLMain.java +++ b/hotspot/test/runtime/modules/ModuleStress/ModuleNonBuiltinCLMain.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -35,79 +34,79 @@ import java.util.Map; import java.util.Set; // -// ClassLoader1 --> defines m1 --> packages p1 -// ClassLoader2 --> defines m2 --> packages p2 -// Java System Class Loader --> defines m3 --> packages p3 +// ClassLoader1 --> defines m1x --> packages p1 +// ClassLoader2 --> defines m2x --> packages p2 +// Java System Class Loader --> defines m3x --> packages p3 // -// m1 can read m2 -// package p2 in m2 is exported to m1 and m3 +// m1x can read m2x +// package p2 in m2x is exported to m1x and m3x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 -// Access allowed since m1 can read m2 and package p2 is exported to m1. +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x +// Access allowed since m1x can read m2x and package p2 is exported to m1x. // public class ModuleNonBuiltinCLMain { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: p1 // Packages exported: p1 is exported to unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .exports("p1") .build(); - // Define module: m2 - // Can read: java.base, m3 + // Define module: m2x + // Can read: java.base, m3x // Packages: p2 - // Packages exported: package p2 is exported to m1 and m3 + // Packages exported: package p2 is exported to m1x and m3x Set targets = new HashSet<>(); - targets.add("m1"); - targets.add("m3"); - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + targets.add("m1x"); + targets.add("m3x"); + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .requires("m3") + .requires("m3x") .exports("p2", targets) .build(); - // Define module: m3 + // Define module: m3x // Can read: java.base // Packages: p3 // Packages exported: none - ModuleDescriptor descriptor_m3 = - ModuleDescriptor.module("m3") + ModuleDescriptor descriptor_m3x = + ModuleDescriptor.newModule("m3x") .requires("java.base") .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2, descriptor_m3); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x, descriptor_m3x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to differing user defined class loaders for this test Map map = new HashMap<>(); Loader1 cl1 = new Loader1(); Loader2 cl2 = new Loader2(); ClassLoader cl3 = ClassLoader.getSystemClassLoader(); - map.put("m1", cl1); - map.put("m2", cl2); - map.put("m3", cl3); + map.put("m1x", cl1); + map.put("m2x", cl2); + map.put("m3x", cl3); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == cl1); - assertTrue(layer.findLoader("m2") == cl2); - assertTrue(layer.findLoader("m3") == cl3); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); + assertTrue(layer.findLoader("m1x") == cl1); + assertTrue(layer.findLoader("m2x") == cl2); + assertTrue(layer.findLoader("m3x") == cl3); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 @@ -115,7 +114,7 @@ public class ModuleNonBuiltinCLMain { try { p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1"); + throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1x"); } } diff --git a/hotspot/test/runtime/modules/ModuleStress/ModuleSameCLMain.java b/hotspot/test/runtime/modules/ModuleStress/ModuleSameCLMain.java index cdbc9002405..1eab8308495 100644 --- a/hotspot/test/runtime/modules/ModuleStress/ModuleSameCLMain.java +++ b/hotspot/test/runtime/modules/ModuleStress/ModuleSameCLMain.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,6 @@ import static jdk.test.lib.Asserts.*; -import java.lang.reflect.Layer; import java.lang.module.Configuration; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -34,61 +33,61 @@ import java.util.Map; import java.util.Set; // -// ClassLoader1 --> defines m1 --> packages p1 -// ClassLoader1 --> defines m2 --> packages p2 +// ClassLoader1 --> defines m1x --> packages p1 +// ClassLoader1 --> defines m2x --> packages p2 // -// m1 can read m2 -// package p2 in m2 is exported to m1 +// m1x can read m2x +// package p2 in m2x is exported to m1x // -// class p1.c1 defined in m1 tries to access p2.c2 defined in m2 -// Access allowed since m1 can read m2 and package p2 is exported to m1. +// class p1.c1 defined in m1x tries to access p2.c2 defined in m2x +// Access allowed since m1x can read m2x and package p2 is exported to m1x. // public class ModuleSameCLMain { - // Create a Layer over the boot layer. + // Create a layer over the boot layer. // Define modules within this layer to test access between // publically defined classes within packages of those modules. public void createLayerOnBoot() throws Throwable { - // Define module: m1 - // Can read: java.base, m2 + // Define module: m1x + // Can read: java.base, m2x // Packages: p1 // Packages exported: p1 is exported to unqualifiedly - ModuleDescriptor descriptor_m1 = - ModuleDescriptor.module("m1") + ModuleDescriptor descriptor_m1x = + ModuleDescriptor.newModule("m1x") .requires("java.base") - .requires("m2") + .requires("m2x") .exports("p1") .build(); - // Define module: m2 + // Define module: m2x // Can read: java.base // Packages: p2 - // Packages exported: package p2 is exported to m1 - ModuleDescriptor descriptor_m2 = - ModuleDescriptor.module("m2") + // Packages exported: package p2 is exported to m1x + ModuleDescriptor descriptor_m2x = + ModuleDescriptor.newModule("m2x") .requires("java.base") - .exports("p2", Set.of("m1")) + .exports("p2", Set.of("m1x")) .build(); // Set up a ModuleFinder containing all modules for this layer. - ModuleFinder finder = ModuleLibrary.of(descriptor_m1, descriptor_m2); + ModuleFinder finder = ModuleLibrary.of(descriptor_m1x, descriptor_m2x); - // Resolves "m1" - Configuration cf = Layer.boot() + // Resolves "m1x" + Configuration cf = ModuleLayer.boot() .configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of("m1")); + .resolve(finder, ModuleFinder.of(), Set.of("m1x")); // map each module to the same class loader for this test Map map = new HashMap<>(); Loader1 cl1 = new Loader1(); - map.put("m1", cl1); - map.put("m2", cl1); + map.put("m1x", cl1); + map.put("m2x", cl1); - // Create Layer that contains m1 & m2 - Layer layer = Layer.boot().defineModules(cf, map::get); - assertTrue(layer.findLoader("m1") == cl1); - assertTrue(layer.findLoader("m2") == cl1); + // Create layer that contains m1x & m2x + ModuleLayer layer = ModuleLayer.boot().defineModules(cf, map::get); + assertTrue(layer.findLoader("m1x") == cl1); + assertTrue(layer.findLoader("m2x") == cl1); assertTrue(layer.findLoader("java.base") == null); // now use the same loader to load class p1.c1 @@ -96,7 +95,7 @@ public class ModuleSameCLMain { try { p1_c1_class.newInstance(); } catch (IllegalAccessError e) { - throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1"); + throw new RuntimeException("Test Failed, an IAE should not be thrown since p2 is exported qualifiedly to m1x"); } } diff --git a/hotspot/test/runtime/modules/ModuleStress/ModuleStress.java b/hotspot/test/runtime/modules/ModuleStress/ModuleStress.java index 2da921d4d8c..bc6341aa9cb 100644 --- a/hotspot/test/runtime/modules/ModuleStress/ModuleStress.java +++ b/hotspot/test/runtime/modules/ModuleStress/ModuleStress.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -38,8 +38,7 @@ import jdk.test.lib.process.ProcessTools; import jdk.test.lib.process.OutputAnalyzer; -import jdk.test.lib.InMemoryJavaCompiler; -import java.io.File; +import jdk.test.lib.compiler.InMemoryJavaCompiler; public class ModuleStress { @@ -53,7 +52,7 @@ public class ModuleStress { // those loaders never die. ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( "-Xbootclasspath/a:.", - "-Xlog:modules=trace", + "-Xlog:module=trace", "-version"); OutputAnalyzer oa = new OutputAnalyzer(pb.start()); @@ -83,12 +82,12 @@ public class ModuleStress { InMemoryJavaCompiler.compile("p1.c1", source1), System.getProperty("test.classes")); // Test #2: Load two modules defined to the same customer class loader. - // m1's module readability list and package p2's exportability should + // m1x's module readability list and package p2's exportability should // not be walked at a GC safepoint since both modules are defined to // the same loader and thus have the exact same life cycle. pb = ProcessTools.createJavaProcessBuilder( "-Xbootclasspath/a:.", - "-Xlog:modules=trace", + "-Xlog:module=trace", "ModuleSameCLMain"); oa = new OutputAnalyzer(pb.start()); @@ -97,35 +96,35 @@ public class ModuleStress { .shouldHaveExitValue(0); // Test #3: Load two modules in differing custom class loaders. - // m1's module readability list and package p2's exportability list must + // m1x's module readability list and package p2's exportability list must // be walked at a GC safepoint since both modules are defined to non-builtin // class loaders which could die and thus be unloaded. pb = ProcessTools.createJavaProcessBuilder( "-Xbootclasspath/a:.", - "-Xlog:modules=trace", + "-Xlog:module=trace", "ModuleNonBuiltinCLMain"); oa = new OutputAnalyzer(pb.start()); - oa.shouldContain("module m1 reads list must be walked") - .shouldContain("package p2 defined in module m2, exports list must be walked") - .shouldNotContain("module m2 reads list must be walked") + oa.shouldContain("module m1x reads list must be walked") + .shouldContain("package p2 defined in module m2x, exports list must be walked") + .shouldNotContain("module m2x reads list must be walked") .shouldHaveExitValue(0); // Test #4: Load two modules in differing custom class loaders, // of which one has been designated as the custom system class loader // via -Djava.system.class.loader=CustomSystemClassLoader. Since - // m3 is defined to the system class loader, m2's module readability + // m3x is defined to the system class loader, m2x's module readability // list does not have to be walked at a GC safepoint, but package p2's // exportability list does. pb = ProcessTools.createJavaProcessBuilder( "-Djava.system.class.loader=CustomSystemClassLoader", "-Xbootclasspath/a:.", - "-Xlog:modules=trace", + "-Xlog:module=trace", "ModuleNonBuiltinCLMain"); oa = new OutputAnalyzer(pb.start()); - oa.shouldContain("package p2 defined in module m2, exports list must be walked") - .shouldNotContain("module m2 reads list must be walked") + oa.shouldContain("package p2 defined in module m2x, exports list must be walked") + .shouldNotContain("module m2x reads list must be walked") .shouldHaveExitValue(0); } diff --git a/hotspot/test/runtime/modules/ModuleStress/ModuleStressGC.java b/hotspot/test/runtime/modules/ModuleStress/ModuleStressGC.java index 9db70d4b137..dacc0189280 100644 --- a/hotspot/test/runtime/modules/ModuleStress/ModuleStressGC.java +++ b/hotspot/test/runtime/modules/ModuleStress/ModuleStressGC.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -73,7 +73,7 @@ public class ModuleStressGC { // test's, defined to module jdk.translet, export list at // GC safepoints. ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( - "-Xlog:modules=trace", + "-Xlog:module=trace", "-p", MODS_DIR.toString(), "-m", "jdk.test/test.MainGC"); OutputAnalyzer oa = new OutputAnalyzer(pb.start()); diff --git a/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/Main.java b/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/Main.java index 16e8dbc79e1..3c6c84794ab 100644 --- a/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/Main.java +++ b/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/Main.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,7 @@ package test; import java.lang.module.Configuration; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; import java.lang.reflect.Method; -import java.lang.reflect.Module; import java.nio.file.Path; import java.nio.file.Paths; import java.util.*; @@ -44,11 +42,11 @@ public class Main { public static void main(String[] args) throws Exception { ModuleFinder finder = ModuleFinder.of(MODS_DIR); - Layer layerBoot = Layer.boot(); + ModuleLayer layerBoot = ModuleLayer.boot(); Configuration cf = layerBoot .configuration() - .resolveRequires(ModuleFinder.of(), finder, Set.of(MODULE_NAME)); + .resolve(ModuleFinder.of(), finder, Set.of(MODULE_NAME)); Module testModule = Main.class.getModule(); ClassLoader scl = ClassLoader.getSystemClassLoader(); @@ -58,7 +56,7 @@ public class Main { Callable task = new Callable() { @Override public Void call() throws Exception { - Layer layer = Layer.boot().defineModulesWithOneLoader(cf, scl); + ModuleLayer layer = ModuleLayer.boot().defineModulesWithOneLoader(cf, scl); Module transletModule = layer.findModule(MODULE_NAME).get(); testModule.addExports("test", transletModule); Class c = layer.findLoader(MODULE_NAME).loadClass("translet.Main"); diff --git a/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/MainGC.java b/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/MainGC.java index 25c121d3625..ddc4bdc4792 100644 --- a/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/MainGC.java +++ b/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/MainGC.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,7 @@ package test; import java.lang.module.Configuration; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; import java.lang.reflect.Method; -import java.lang.reflect.Module; import java.nio.file.Path; import java.nio.file.Paths; import java.util.*; @@ -44,11 +42,11 @@ public class MainGC { public static void main(String[] args) throws Exception { ModuleFinder finder = ModuleFinder.of(MODS_DIR); - Layer layerBoot = Layer.boot(); + ModuleLayer layerBoot = ModuleLayer.boot(); Configuration cf = layerBoot .configuration() - .resolveRequires(ModuleFinder.of(), finder, Set.of(MODULE_NAME)); + .resolve(ModuleFinder.of(), finder, Set.of(MODULE_NAME)); Module testModule = MainGC.class.getModule(); ClassLoader scl = ClassLoader.getSystemClassLoader(); @@ -59,7 +57,7 @@ public class MainGC { Callable task = new Callable() { @Override public Void call() throws Exception { - Layer layer = Layer.boot().defineModulesWithOneLoader(cf, scl); + ModuleLayer layer = ModuleLayer.boot().defineModulesWithOneLoader(cf, scl); Module transletModule = layer.findModule(MODULE_NAME).get(); testModule.addExports("test", transletModule); testModule.addReads(transletModule); diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModule2Dirs.java b/hotspot/test/runtime/modules/PatchModule/PatchModule2Dirs.java index 5af477b5c30..4c49e6613ce 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModule2Dirs.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModule2Dirs.java @@ -30,10 +30,9 @@ * @run main PatchModule2Dirs */ -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; -import java.io.File; public class PatchModule2Dirs { diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModuleCDS.java b/hotspot/test/runtime/modules/PatchModule/PatchModuleCDS.java index cd9a66e49ab..2ebc75ec2db 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModuleCDS.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModuleCDS.java @@ -31,8 +31,7 @@ * @run main PatchModuleCDS */ -import java.io.File; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModuleClassList.java b/hotspot/test/runtime/modules/PatchModule/PatchModuleClassList.java index e590e63a3fc..ec9776f20a8 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModuleClassList.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModuleClassList.java @@ -33,7 +33,7 @@ import java.nio.file.Files; import java.nio.file.Paths; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModuleDupModule.java b/hotspot/test/runtime/modules/PatchModule/PatchModuleDupModule.java index f87a582d30a..75489a665fb 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModuleDupModule.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModuleDupModule.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -38,8 +38,8 @@ public class PatchModuleDupModule { public static void main(String args[]) throws Exception { ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( - "--patch-module=module1=module1_dir", - "--patch-module=module1=module1_dir", + "--patch-module=module_one=module_one_dir", + "--patch-module=module_one=module_one_dir", "-version"); OutputAnalyzer output = new OutputAnalyzer(pb.start()); output.shouldContain("java.lang.ExceptionInInitializerError"); diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModuleJavaBase.java b/hotspot/test/runtime/modules/PatchModule/PatchModuleJavaBase.java index e43325703e9..e7fe2da1705 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModuleJavaBase.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModuleJavaBase.java @@ -31,7 +31,7 @@ * @run main PatchModuleJavaBase */ -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModuleTest.java b/hotspot/test/runtime/modules/PatchModule/PatchModuleTest.java index a5eb563a230..d58ca4240ef 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModuleTest.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModuleTest.java @@ -31,7 +31,7 @@ * @run main PatchModuleTest */ -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModuleTestJar.java b/hotspot/test/runtime/modules/PatchModule/PatchModuleTestJar.java index c7775c0c136..5979da68a5c 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModuleTestJar.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModuleTestJar.java @@ -31,7 +31,7 @@ * @run main PatchModuleTestJar */ -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModuleTestJarDir.java b/hotspot/test/runtime/modules/PatchModule/PatchModuleTestJarDir.java index 18cc2597c2b..5c5a12e7c4b 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModuleTestJarDir.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModuleTestJarDir.java @@ -32,8 +32,8 @@ */ import java.io.File; -import java.nio.file.Files; -import jdk.test.lib.InMemoryJavaCompiler; + +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/PatchModule/PatchModuleTraceCL.java b/hotspot/test/runtime/modules/PatchModule/PatchModuleTraceCL.java index 7dda4a51d55..d1255d61e68 100644 --- a/hotspot/test/runtime/modules/PatchModule/PatchModuleTraceCL.java +++ b/hotspot/test/runtime/modules/PatchModule/PatchModuleTraceCL.java @@ -32,8 +32,7 @@ * @run main PatchModuleTraceCL */ -import java.io.File; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/Visibility/PatchModuleVisibility.java b/hotspot/test/runtime/modules/Visibility/PatchModuleVisibility.java index 95fbce1b125..124fd7a5665 100644 --- a/hotspot/test/runtime/modules/Visibility/PatchModuleVisibility.java +++ b/hotspot/test/runtime/modules/Visibility/PatchModuleVisibility.java @@ -36,7 +36,7 @@ import java.io.File; import java.nio.file.Files; import java.nio.file.Paths; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/Visibility/XbootcpNoVisibility.java b/hotspot/test/runtime/modules/Visibility/XbootcpNoVisibility.java index 5f56b2573eb..4ea90f03b2c 100644 --- a/hotspot/test/runtime/modules/Visibility/XbootcpNoVisibility.java +++ b/hotspot/test/runtime/modules/Visibility/XbootcpNoVisibility.java @@ -31,7 +31,7 @@ * @run main/othervm XbootcpNoVisibility */ -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.ProcessTools; import jdk.test.lib.process.OutputAnalyzer; diff --git a/hotspot/test/runtime/modules/Visibility/XbootcpVisibility.java b/hotspot/test/runtime/modules/Visibility/XbootcpVisibility.java index 1530d8bed13..4b36695c29d 100644 --- a/hotspot/test/runtime/modules/Visibility/XbootcpVisibility.java +++ b/hotspot/test/runtime/modules/Visibility/XbootcpVisibility.java @@ -36,7 +36,7 @@ import java.io.File; import java.nio.file.Files; import java.nio.file.Paths; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; diff --git a/hotspot/test/runtime/modules/acc_module.jcod b/hotspot/test/runtime/modules/acc_module.jcod index 573c7dde2a6..09b21bc0484 100644 --- a/hotspot/test/runtime/modules/acc_module.jcod +++ b/hotspot/test/runtime/modules/acc_module.jcod @@ -23,7 +23,8 @@ /* * This class consists of the following java code, but has an illegal class - * access_flags value of 0x8000, that should be ignored by the JVM. + * access_flags value of 0x8000, that should be ignored by the JVM because + * the class file version is < 53. * * public class acc_module { * public static void main(String[] args) { diff --git a/hotspot/test/runtime/modules/getModuleJNI/GetModule.java b/hotspot/test/runtime/modules/getModuleJNI/GetModule.java index 01d00648cd9..182632ac9e2 100644 --- a/hotspot/test/runtime/modules/getModuleJNI/GetModule.java +++ b/hotspot/test/runtime/modules/getModuleJNI/GetModule.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,6 @@ * @run main/native GetModule */ -import java.lang.reflect.Module; import java.lang.management.LockInfo; public class GetModule { diff --git a/hotspot/test/runtime/modules/java.base/java/lang/reflect/ModuleHelper.java b/hotspot/test/runtime/modules/java.base/java/lang/ModuleHelper.java similarity index 86% rename from hotspot/test/runtime/modules/java.base/java/lang/reflect/ModuleHelper.java rename to hotspot/test/runtime/modules/java.base/java/lang/ModuleHelper.java index 19bbff48a76..6aef814acf2 100644 --- a/hotspot/test/runtime/modules/java.base/java/lang/reflect/ModuleHelper.java +++ b/hotspot/test/runtime/modules/java.base/java/lang/ModuleHelper.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,14 +21,14 @@ * questions. */ -package java.lang.reflect; +package java.lang; import java.lang.module.ModuleDescriptor; /** - * A helper class intended to be injected into java.lang.reflect using the + * A helper class intended to be injected into java.lang using the * java --patch-module option. The helper class provides access to package private - * methods in java.lang.reflect.Module. + * methods in java.lang.Module. */ public final class ModuleHelper { @@ -56,7 +56,11 @@ public final class ModuleHelper { * {@code null} then the package is exported unconditionally. */ public static void addExportsNoSync(Module from, String pkg, Module to) { - from.implAddExportsNoSync(pkg, to); + if (to == null) { + from.implAddExportsNoSync(pkg); + } else { + from.implAddExportsNoSync(pkg, to); + } } /** diff --git a/hotspot/test/serviceability/attach/AttachSetGetFlag.java b/hotspot/test/serviceability/attach/AttachSetGetFlag.java index 2d6a28cfce3..8ec530e19c3 100644 --- a/hotspot/test/serviceability/attach/AttachSetGetFlag.java +++ b/hotspot/test/serviceability/attach/AttachSetGetFlag.java @@ -80,7 +80,7 @@ public class AttachSetGetFlag { try { waitForReady(target); - int pid = (int)target.getPid(); + int pid = (int)target.pid(); HotSpotVirtualMachine vm = (HotSpotVirtualMachine)VirtualMachine.attach(((Integer)pid).toString()); @@ -116,7 +116,7 @@ public class AttachSetGetFlag { try { waitForReady(target); - int pid = (int)target.getPid(); + int pid = (int)target.pid(); HotSpotVirtualMachine vm = (HotSpotVirtualMachine)VirtualMachine.attach(((Integer)pid).toString()); diff --git a/hotspot/test/serviceability/jdwp/AllModulesCommandTest.java b/hotspot/test/serviceability/jdwp/AllModulesCommandTest.java index 92a2aa4e003..76a6aa4a3e3 100644 --- a/hotspot/test/serviceability/jdwp/AllModulesCommandTest.java +++ b/hotspot/test/serviceability/jdwp/AllModulesCommandTest.java @@ -32,7 +32,6 @@ import static jdk.test.lib.Asserts.assertTrue; * @test * @summary Tests the modules-related JDWP commands * @library /test/lib - * @ignore 8170541 * @modules jdk.jdwp.agent * @modules java.base/jdk.internal.misc * @compile AllModulesCommandTestDebuggee.java diff --git a/hotspot/test/serviceability/jdwp/AllModulesCommandTestDebuggee.java b/hotspot/test/serviceability/jdwp/AllModulesCommandTestDebuggee.java index 1b686ec9ae4..5c919f40c49 100644 --- a/hotspot/test/serviceability/jdwp/AllModulesCommandTestDebuggee.java +++ b/hotspot/test/serviceability/jdwp/AllModulesCommandTestDebuggee.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,8 +21,6 @@ * questions. */ -import java.lang.reflect.Module; -import java.lang.reflect.Layer; import java.util.Set; import java.util.HashSet; @@ -35,10 +33,10 @@ public class AllModulesCommandTestDebuggee { public static void main(String[] args) throws InterruptedException { - int modCount = Layer.boot().modules().size(); + int modCount = ModuleLayer.boot().modules().size(); // Send all modules names via the process output - for (Module mod : Layer.boot().modules()) { + for (Module mod : ModuleLayer.boot().modules()) { String info = String.format("module %s", mod.getName()); write(info); } diff --git a/hotspot/test/serviceability/jvmti/AddModuleExportsAndOpens/MyPackage/AddModuleExportsAndOpensTest.java b/hotspot/test/serviceability/jvmti/AddModuleExportsAndOpens/MyPackage/AddModuleExportsAndOpensTest.java index 04446a6c87d..94da0f081d4 100644 --- a/hotspot/test/serviceability/jvmti/AddModuleExportsAndOpens/MyPackage/AddModuleExportsAndOpensTest.java +++ b/hotspot/test/serviceability/jvmti/AddModuleExportsAndOpens/MyPackage/AddModuleExportsAndOpensTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,6 @@ package MyPackage; */ import java.io.PrintStream; -import java.lang.reflect.Module; public class AddModuleExportsAndOpensTest { diff --git a/hotspot/test/serviceability/jvmti/AddModuleExportsAndOpens/libAddModuleExportsAndOpensTest.c b/hotspot/test/serviceability/jvmti/AddModuleExportsAndOpens/libAddModuleExportsAndOpensTest.c index e028ee50c9c..b5ccf258659 100644 --- a/hotspot/test/serviceability/jvmti/AddModuleExportsAndOpens/libAddModuleExportsAndOpensTest.c +++ b/hotspot/test/serviceability/jvmti/AddModuleExportsAndOpens/libAddModuleExportsAndOpensTest.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,7 +47,7 @@ extern "C" { #define FAILED 2 static const char *EXC_CNAME = "java/lang/Exception"; -static const char* MOD_CNAME = "Ljava/lang/reflect/Module;"; +static const char* MOD_CNAME = "Ljava/lang/Module;"; static jvmtiEnv *jvmti = NULL; static jint result = PASSED; @@ -97,7 +97,7 @@ void throw_exc(JNIEnv *env, char *msg) { } static -jclass jlrM(JNIEnv *env) { +jclass jlM(JNIEnv *env) { jclass cls = NULL; cls = JNI_ENV_PTR(env)->FindClass(JNI_ENV_ARG(env, MOD_CNAME)); @@ -127,7 +127,7 @@ jboolean is_exported(JNIEnv *env, jobject module, const char* pkg, jboolean open if (mIsExported == NULL) { const char* sign = "(Ljava/lang/String;)Z"; const char* name = open ? "isOpen" : "isExported"; - mIsExported = get_method(env, jlrM(env), name, sign); + mIsExported = get_method(env, jlM(env), name, sign); } jstr = JNI_ENV_PTR(env)->NewStringUTF(JNI_ENV_ARG(env, pkg)); res = JNI_ENV_PTR(env)->CallBooleanMethod(JNI_ENV_ARG(env, module), @@ -143,9 +143,9 @@ jboolean is_exported_to(JNIEnv *env, jobject module, const char* pkg, jobject to jboolean res = JNI_FALSE; if (mIsExportedTo == NULL) { - const char* sign = "(Ljava/lang/String;Ljava/lang/reflect/Module;)Z"; + const char* sign = "(Ljava/lang/String;Ljava/lang/Module;)Z"; const char* name = open ? "isOpen" : "isExported"; - mIsExportedTo = get_method(env, jlrM(env), name, sign); + mIsExportedTo = get_method(env, jlM(env), name, sign); } jstr = JNI_ENV_PTR(env)->NewStringUTF(JNI_ENV_ARG(env, pkg)); res = JNI_ENV_PTR(env)->CallBooleanMethod(JNI_ENV_ARG(env, module), diff --git a/hotspot/test/serviceability/jvmti/AddModuleReads/MyPackage/AddModuleReadsTest.java b/hotspot/test/serviceability/jvmti/AddModuleReads/MyPackage/AddModuleReadsTest.java index 940172af807..a3915f72920 100644 --- a/hotspot/test/serviceability/jvmti/AddModuleReads/MyPackage/AddModuleReadsTest.java +++ b/hotspot/test/serviceability/jvmti/AddModuleReads/MyPackage/AddModuleReadsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,7 +32,6 @@ package MyPackage; import java.io.PrintStream; import java.lang.instrument.Instrumentation; -import java.lang.reflect.Module; public class AddModuleReadsTest { diff --git a/hotspot/test/serviceability/jvmti/AddModuleReads/libAddModuleReadsTest.c b/hotspot/test/serviceability/jvmti/AddModuleReads/libAddModuleReadsTest.c index 4863a4aa5c9..be259ff4821 100644 --- a/hotspot/test/serviceability/jvmti/AddModuleReads/libAddModuleReadsTest.c +++ b/hotspot/test/serviceability/jvmti/AddModuleReads/libAddModuleReadsTest.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,7 +47,7 @@ extern "C" { #define FAILED 2 static const char *EXC_CNAME = "java/lang/Exception"; -static const char* MOD_CNAME = "Ljava/lang/reflect/Module;"; +static const char* MOD_CNAME = "Ljava/lang/Module;"; static jvmtiEnv *jvmti = NULL; static jint result = PASSED; @@ -96,7 +96,7 @@ void throw_exc(JNIEnv *env, char *msg) { } static -jclass jlrM(JNIEnv *env) { +jclass jlM(JNIEnv *env) { jclass cls = NULL; cls = JNI_ENV_PTR(env)->FindClass(JNI_ENV_ARG(env, MOD_CNAME)); @@ -123,8 +123,8 @@ jboolean can_module_read(JNIEnv *env, jobject module, jobject to_module) { jboolean res = JNI_FALSE; if (mCanRead == NULL) { - const char* sign = "(Ljava/lang/reflect/Module;)Z"; - mCanRead = get_method(env, jlrM(env), "canRead", sign); + const char* sign = "(Ljava/lang/Module;)Z"; + mCanRead = get_method(env, jlM(env), "canRead", sign); } res = JNI_ENV_PTR(env)->CallBooleanMethod(JNI_ENV_ARG(env, module), mCanRead, to_module); diff --git a/hotspot/test/serviceability/jvmti/AddModuleUsesAndProvides/MyPackage/AddModuleUsesAndProvidesTest.java b/hotspot/test/serviceability/jvmti/AddModuleUsesAndProvides/MyPackage/AddModuleUsesAndProvidesTest.java index e6d9d57c01d..634b2eaf57c 100644 --- a/hotspot/test/serviceability/jvmti/AddModuleUsesAndProvides/MyPackage/AddModuleUsesAndProvidesTest.java +++ b/hotspot/test/serviceability/jvmti/AddModuleUsesAndProvides/MyPackage/AddModuleUsesAndProvidesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,7 +34,6 @@ package MyPackage; import java.io.PrintStream; import java.lang.TestProvider; -import java.lang.reflect.Module; public class AddModuleUsesAndProvidesTest { diff --git a/hotspot/test/serviceability/jvmti/AddModuleUsesAndProvides/libAddModuleUsesAndProvidesTest.c b/hotspot/test/serviceability/jvmti/AddModuleUsesAndProvides/libAddModuleUsesAndProvidesTest.c index 5ce1bf46d4f..86f9993c703 100644 --- a/hotspot/test/serviceability/jvmti/AddModuleUsesAndProvides/libAddModuleUsesAndProvidesTest.c +++ b/hotspot/test/serviceability/jvmti/AddModuleUsesAndProvides/libAddModuleUsesAndProvidesTest.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,7 +47,7 @@ extern "C" { #define FAILED 2 static const char *EXC_CNAME = "java/lang/Exception"; -static const char* MOD_CNAME = "Ljava/lang/reflect/Module;"; +static const char* MOD_CNAME = "Ljava/lang/Module;"; static jvmtiEnv *jvmti = NULL; static jint result = PASSED; @@ -97,7 +97,7 @@ void throw_exc(JNIEnv *env, char *msg) { } static -jclass jlrM(JNIEnv *env) { +jclass jlM(JNIEnv *env) { jclass cls = NULL; cls = JNI_ENV_PTR(env)->FindClass(JNI_ENV_ARG(env, MOD_CNAME)); @@ -125,7 +125,7 @@ jboolean can_use_service(JNIEnv *env, jobject module, jclass service) { if (mCanUse == NULL) { const char* sign = "(Ljava/lang/Class;)Z"; - mCanUse = get_method(env, jlrM(env), "canUse", sign); + mCanUse = get_method(env, jlM(env), "canUse", sign); } res = JNI_ENV_PTR(env)->CallBooleanMethod(JNI_ENV_ARG(env, module), mCanUse, service); diff --git a/hotspot/test/serviceability/jvmti/GetModulesInfo/JvmtiGetAllModulesTest.java b/hotspot/test/serviceability/jvmti/GetModulesInfo/JvmtiGetAllModulesTest.java index 7c682b5dfa0..4b700ef0b09 100644 --- a/hotspot/test/serviceability/jvmti/GetModulesInfo/JvmtiGetAllModulesTest.java +++ b/hotspot/test/serviceability/jvmti/GetModulesInfo/JvmtiGetAllModulesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,8 +28,6 @@ * @run main/othervm -agentlib:JvmtiGetAllModulesTest JvmtiGetAllModulesTest * */ -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.lang.module.ModuleReference; import java.lang.module.ModuleFinder; import java.lang.module.ModuleReader; @@ -79,16 +77,15 @@ public class JvmtiGetAllModulesTest { final String MY_MODULE_NAME = "myModule"; // Verify that JVMTI reports exactly the same info as Java regarding the named modules - Asserts.assertEquals(Layer.boot().modules(), getModulesJVMTI()); + Asserts.assertEquals(ModuleLayer.boot().modules(), getModulesJVMTI()); // Load a new named module - ModuleDescriptor descriptor - = ModuleDescriptor.module(MY_MODULE_NAME).build(); + ModuleDescriptor descriptor = ModuleDescriptor.newModule(MY_MODULE_NAME).build(); ModuleFinder finder = finderOf(descriptor); ClassLoader loader = new ClassLoader() {}; - Configuration parent = Layer.boot().configuration(); - Configuration cf = parent.resolveRequires(finder, ModuleFinder.of(), Set.of(MY_MODULE_NAME)); - Layer my = Layer.boot().defineModules(cf, m -> loader); + Configuration parent = ModuleLayer.boot().configuration(); + Configuration cf = parent.resolve(finder, ModuleFinder.of(), Set.of(MY_MODULE_NAME)); + ModuleLayer my = ModuleLayer.boot().defineModules(cf, m -> loader); // Verify that the loaded module is indeed reported by JVMTI Set jvmtiModules = getModulesJVMTI(); diff --git a/hotspot/test/serviceability/jvmti/GetModulesInfo/libJvmtiGetAllModulesTest.c b/hotspot/test/serviceability/jvmti/GetModulesInfo/libJvmtiGetAllModulesTest.c index ed83d19784c..fcabaa4bfb9 100644 --- a/hotspot/test/serviceability/jvmti/GetModulesInfo/libJvmtiGetAllModulesTest.c +++ b/hotspot/test/serviceability/jvmti/GetModulesInfo/libJvmtiGetAllModulesTest.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -53,7 +53,7 @@ extern "C" { return NULL; } - array = (*env)->NewObjectArray(env, modules_count, (*env)->FindClass(env, "java/lang/reflect/Module"), NULL); + array = (*env)->NewObjectArray(env, modules_count, (*env)->FindClass(env, "java/lang/Module"), NULL); for (i = 0; i < modules_count; ++i) { (*env)->SetObjectArrayElement(env, array, i, modules_ptr[i]); diff --git a/hotspot/test/serviceability/jvmti/GetNamedModule/libGetNamedModuleTest.c b/hotspot/test/serviceability/jvmti/GetNamedModule/libGetNamedModuleTest.c index 6e9b0300232..307fab0f2b0 100644 --- a/hotspot/test/serviceability/jvmti/GetNamedModule/libGetNamedModuleTest.c +++ b/hotspot/test/serviceability/jvmti/GetNamedModule/libGetNamedModuleTest.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,7 +47,7 @@ extern "C" { #define FAILED 2 static const char *EXC_CNAME = "java/lang/Exception"; -static const char* MOD_CNAME = "Ljava/lang/reflect/Module;"; +static const char* MOD_CNAME = "Ljava/lang/Module;"; static jvmtiEnv *jvmti = NULL; static jint result = PASSED; @@ -115,7 +115,7 @@ jobject get_class_loader(jclass cls) { } static -jclass jlrM(JNIEnv *env) { +jclass jlM(JNIEnv *env) { jclass cls = NULL; cls = JNI_ENV_PTR(env)->FindClass(JNI_ENV_ARG(env, MOD_CNAME)); @@ -142,7 +142,7 @@ jobject get_module_loader(JNIEnv *env, jobject module) { jobject loader = NULL; if (cl_method == NULL) { - cl_method = get_method(env, jlrM(env), "getClassLoader", "()Ljava/lang/ClassLoader;"); + cl_method = get_method(env, jlM(env), "getClassLoader", "()Ljava/lang/ClassLoader;"); } loader = (jobject)JNI_ENV_PTR(env)->CallObjectMethod(JNI_ENV_ARG(env, module), cl_method); return loader; @@ -157,7 +157,7 @@ const char* get_module_name(JNIEnv *env, jobject module) { const char *nstr = NULL; if (method == NULL) { - method = get_method(env, jlrM(env), "getName", "()Ljava/lang/String;"); + method = get_method(env, jlM(env), "getName", "()Ljava/lang/String;"); } jstr = (jstring)JNI_ENV_PTR(env)->CallObjectMethod(JNI_ENV_ARG(env, module), method); if (jstr != NULL) { @@ -183,7 +183,7 @@ jvmtiError get_module(JNIEnv *env, err = (*jvmti)->GetNamedModule(jvmti, loader, pkg_name, module_ptr); if (err != JVMTI_ERROR_NONE) { printf(" Error in GetNamedModule for package \"%s\": %s (%d)\n", - pkg_name, TranslateError(err), err); + name, TranslateError(err), err); return err; } printf(" returned module: %p\n", *module_ptr); diff --git a/hotspot/test/gc/startup_warnings/TestParNewCMS.java b/hotspot/test/serviceability/sa/LingeredAppWithInterface.java similarity index 50% rename from hotspot/test/gc/startup_warnings/TestParNewCMS.java rename to hotspot/test/serviceability/sa/LingeredAppWithInterface.java index 75dbe4bf7b3..4b65bf1f637 100644 --- a/hotspot/test/gc/startup_warnings/TestParNewCMS.java +++ b/hotspot/test/serviceability/sa/LingeredAppWithInterface.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,28 +21,38 @@ * questions. */ -/* -* @test TestParNewCMS -* @key gc -* @bug 8065972 -* @summary Test that specifying -XX:+UseParNewGC on the command line logs a warning message -* @library /test/lib -* @modules java.base/jdk.internal.misc -* java.management -*/ - -import jdk.test.lib.process.ProcessTools; -import jdk.test.lib.process.OutputAnalyzer; - - -public class TestParNewCMS { - - public static void main(String args[]) throws Exception { - ProcessBuilder pb = ProcessTools.createJavaProcessBuilder("-XX:+UseParNewGC", "-XX:+UseConcMarkSweepGC", "-version"); - OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("warning: Option UseParNewGC was deprecated in version"); - output.shouldNotContain("error"); - output.shouldHaveExitValue(0); - } +import jdk.test.lib.apps.LingeredApp; +interface Language { + static final long nbrOfWords = 99999; + public abstract long getNbrOfWords(); +} + +class ParselTongue implements Language { + public long getNbrOfWords() { + return nbrOfWords * 4; + } +} + +public class LingeredAppWithInterface extends LingeredApp { + + public static void main(String args[]) { + ParselTongue lang = new ParselTongue(); + Language muggleSpeak = new Language() { + public long getNbrOfWords() { + return nbrOfWords * 8; + } + }; + + // Not tested at this point. The test needs to be enhanced + // later to test for the sizes of the Lambda MetaFactory + // generated anonymous classes too. (After JDK-8160228 gets + // fixed.) + Runnable r2 = () -> System.out.println("Hello world!"); + r2.run(); + + System.out.println(lang.getNbrOfWords() + muggleSpeak.getNbrOfWords()); + + LingeredApp.main(args); + } } diff --git a/hotspot/test/serviceability/sa/LingeredAppWithLargeArray.java b/hotspot/test/serviceability/sa/LingeredAppWithLargeArray.java new file mode 100644 index 00000000000..44929f05b15 --- /dev/null +++ b/hotspot/test/serviceability/sa/LingeredAppWithLargeArray.java @@ -0,0 +1,31 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import jdk.test.lib.apps.LingeredApp; + +public class LingeredAppWithLargeArray extends LingeredApp { + public static void main(String args[]) { + int[] hugeArray = new int[Integer.MAX_VALUE/2]; + LingeredApp.main(args); + } + } diff --git a/hotspot/test/serviceability/sa/TestCpoolForInvokeDynamic.java b/hotspot/test/serviceability/sa/TestCpoolForInvokeDynamic.java index e8f1fd86703..901fbab83ef 100644 --- a/hotspot/test/serviceability/sa/TestCpoolForInvokeDynamic.java +++ b/hotspot/test/serviceability/sa/TestCpoolForInvokeDynamic.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -51,7 +51,6 @@ import jdk.test.lib.Asserts; * jdk.hotspot.agent/sun.jvm.hotspot.oops * jdk.hotspot.agent/sun.jvm.hotspot.debugger * jdk.hotspot.agent/sun.jvm.hotspot.ui.classbrowser - * @ignore 8169232 * @run main/othervm TestCpoolForInvokeDynamic */ diff --git a/hotspot/test/serviceability/sa/TestHeapDumpForLargeArray.java b/hotspot/test/serviceability/sa/TestHeapDumpForLargeArray.java new file mode 100644 index 00000000000..70f26fb48eb --- /dev/null +++ b/hotspot/test/serviceability/sa/TestHeapDumpForLargeArray.java @@ -0,0 +1,117 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.util.ArrayList; +import java.util.List; +import java.io.File; +import java.nio.file.Files; +import java.io.IOException; +import java.io.BufferedInputStream; +import java.util.stream.Collectors; +import java.io.FileInputStream; + +import sun.jvm.hotspot.HotSpotAgent; +import sun.jvm.hotspot.debugger.*; + +import jdk.test.lib.apps.LingeredApp; +import jdk.test.lib.JDKToolLauncher; +import jdk.test.lib.JDKToolFinder; +import jdk.test.lib.Platform; +import jdk.test.lib.process.ProcessTools; +import jdk.test.lib.process.OutputAnalyzer; +import jdk.test.lib.Utils; +import jdk.test.lib.Asserts; + +/* + * @test + * @library /test/lib + * @bug 8171084 + * @requires (vm.bits == "64" & os.maxMemory > 8g) + * @modules java.base/jdk.internal.misc + * jdk.hotspot.agent/sun.jvm.hotspot + * jdk.hotspot.agent/sun.jvm.hotspot.utilities + * jdk.hotspot.agent/sun.jvm.hotspot.oops + * jdk.hotspot.agent/sun.jvm.hotspot.debugger + * @run main/timeout=1800/othervm -Xmx8g TestHeapDumpForLargeArray + */ + +public class TestHeapDumpForLargeArray { + + private static LingeredAppWithLargeArray theApp = null; + + private static void attachAndDump(String heapDumpFileName, + long lingeredAppPid) throws Exception { + + JDKToolLauncher launcher = JDKToolLauncher.createUsingTestJDK("jhsdb"); + launcher.addToolArg("jmap"); + launcher.addToolArg("--binaryheap"); + launcher.addToolArg("--dumpfile"); + launcher.addToolArg(heapDumpFileName); + launcher.addToolArg("--pid"); + launcher.addToolArg(Long.toString(lingeredAppPid)); + + ProcessBuilder processBuilder = new ProcessBuilder(); + processBuilder.command(launcher.getCommand()); + System.out.println( + processBuilder.command().stream().collect(Collectors.joining(" "))); + + OutputAnalyzer SAOutput = ProcessTools.executeProcess(processBuilder); + SAOutput.shouldHaveExitValue(0); + SAOutput.shouldNotContain("Heap segment size overflow"); + SAOutput.shouldContain("truncating to"); + SAOutput.shouldContain("heap written to"); + SAOutput.shouldContain(heapDumpFileName); + System.out.println(SAOutput.getOutput()); + + } + + public static void main (String... args) throws Exception { + + String heapDumpFileName = "LargeArrayHeapDump.bin"; + + if (!Platform.shouldSAAttach()) { + System.out.println( + "SA attach not expected to work - test skipped."); + return; + } + + File heapDumpFile = new File(heapDumpFileName); + if (heapDumpFile.exists()) { + heapDumpFile.delete(); + } + + try { + List vmArgs = new ArrayList(); + vmArgs.add("-XX:+UsePerfData"); + vmArgs.add("-Xmx8g"); + vmArgs.addAll(Utils.getVmOptions()); + + theApp = new LingeredAppWithLargeArray(); + LingeredApp.startApp(vmArgs, theApp); + attachAndDump(heapDumpFileName, theApp.getPid()); + } finally { + LingeredApp.stopApp(theApp); + heapDumpFile.delete(); + } + } +} diff --git a/hotspot/test/serviceability/sa/TestInstanceKlassSizeForInterface.java b/hotspot/test/serviceability/sa/TestInstanceKlassSizeForInterface.java index 5369c761073..d660249ecd2 100644 --- a/hotspot/test/serviceability/sa/TestInstanceKlassSizeForInterface.java +++ b/hotspot/test/serviceability/sa/TestInstanceKlassSizeForInterface.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,11 +21,15 @@ * questions. */ +import java.util.ArrayList; +import java.util.List; + import sun.jvm.hotspot.HotSpotAgent; import sun.jvm.hotspot.utilities.SystemDictionaryHelper; import sun.jvm.hotspot.oops.InstanceKlass; import sun.jvm.hotspot.debugger.*; +import jdk.test.lib.apps.LingeredApp; import jdk.test.lib.JDKToolLauncher; import jdk.test.lib.JDKToolFinder; import jdk.test.lib.Platform; @@ -45,29 +49,20 @@ import jdk.test.lib.Asserts; * @run main/othervm TestInstanceKlassSizeForInterface */ -interface Language { - static final long nbrOfWords = 99999; - public abstract long getNbrOfWords(); -} - -class ParselTongue implements Language { - public long getNbrOfWords() { - return nbrOfWords * 4; - } -} - public class TestInstanceKlassSizeForInterface { - private static void SAInstanceKlassSize(int pid, + private static LingeredAppWithInterface theApp = null; + + private static void SAInstanceKlassSize(int lingeredAppPid, String[] instanceKlassNames) { HotSpotAgent agent = new HotSpotAgent(); try { - agent.attach((int)pid); + agent.attach(lingeredAppPid); } catch (DebuggerException e) { System.out.println(e.getMessage()); - System.err.println("Unable to connect to process ID: " + pid); + System.err.println("Unable to connect to process ID: " + lingeredAppPid); agent.detach(); e.printStackTrace(); @@ -98,11 +93,9 @@ public class TestInstanceKlassSizeForInterface { } private static void createAnotherToAttach( - String[] instanceKlassNames) throws Exception { + String[] instanceKlassNames, + int lingeredAppPid) throws Exception { - ProcessBuilder pb = new ProcessBuilder(); - - // Grab the pid from the current java process and pass it String[] toolArgs = { "--add-modules=jdk.hotspot.agent", "--add-exports=jdk.hotspot.agent/sun.jvm.hotspot=ALL-UNNAMED", @@ -110,23 +103,26 @@ public class TestInstanceKlassSizeForInterface { "--add-exports=jdk.hotspot.agent/sun.jvm.hotspot.oops=ALL-UNNAMED", "--add-exports=jdk.hotspot.agent/sun.jvm.hotspot.debugger=ALL-UNNAMED", "TestInstanceKlassSizeForInterface", - Long.toString(ProcessTools.getProcessId()) + Integer.toString(lingeredAppPid) }; + // Start a new process to attach to the LingeredApp process + ProcessBuilder processBuilder = ProcessTools + .createJavaProcessBuilder(toolArgs); + OutputAnalyzer SAOutput = ProcessTools.executeProcess(processBuilder); + SAOutput.shouldHaveExitValue(0); + System.out.println(SAOutput.getOutput()); + + // Run jcmd on the LingeredApp process + ProcessBuilder pb = new ProcessBuilder(); pb.command(new String[] { JDKToolFinder.getJDKTool("jcmd"), - Long.toString(ProcessTools.getProcessId()), + Long.toString(lingeredAppPid), "GC.class_stats", "VTab,ITab,OopMap,KlassBytes" } ); - // Start a new process to attach to the current process - ProcessBuilder processBuilder = ProcessTools - .createJavaProcessBuilder(toolArgs); - OutputAnalyzer SAOutput = ProcessTools.executeProcess(processBuilder); - System.out.println(SAOutput.getOutput()); - OutputAnalyzer jcmdOutput = new OutputAnalyzer(pb.start()); System.out.println(jcmdOutput.getOutput()); @@ -153,7 +149,7 @@ public class TestInstanceKlassSizeForInterface { String[] instanceKlassNames = new String[] { "Language", "ParselTongue", - "TestInstanceKlassSizeForInterface$1" + "LingeredAppWithInterface$1" }; if (!Platform.shouldSAAttach()) { @@ -163,22 +159,17 @@ public class TestInstanceKlassSizeForInterface { } if (args == null || args.length == 0) { - ParselTongue lang = new ParselTongue(); + try { + List vmArgs = new ArrayList(); + vmArgs.addAll(Utils.getVmOptions()); - Language ventro = new Language() { - public long getNbrOfWords() { - return nbrOfWords * 8; - } - }; - - // Not tested at this point. The test needs to be enhanced - // later to test for the sizes of the Lambda MetaFactory - // generated anonymous classes too. (After JDK-8160228 gets - // fixed.) - Runnable r2 = () -> System.out.println("Hello world!"); - r2.run(); - - createAnotherToAttach(instanceKlassNames); + theApp = new LingeredAppWithInterface(); + LingeredApp.startApp(vmArgs, theApp); + createAnotherToAttach(instanceKlassNames, + (int)theApp.getPid()); + } finally { + LingeredApp.stopApp(theApp); + } } else { SAInstanceKlassSize(Integer.parseInt(args[0]), instanceKlassNames); } diff --git a/hotspot/test/serviceability/sa/TestPrintMdo.java b/hotspot/test/serviceability/sa/TestPrintMdo.java new file mode 100644 index 00000000000..48b0b0840b8 --- /dev/null +++ b/hotspot/test/serviceability/sa/TestPrintMdo.java @@ -0,0 +1,176 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.util.ArrayList; +import java.util.Scanner; +import java.util.List; +import java.io.File; +import java.io.IOException; +import java.util.stream.Collectors; +import java.io.OutputStream; +import jdk.test.lib.apps.LingeredApp; +import jdk.test.lib.JDKToolLauncher; +import jdk.test.lib.Platform; +import jdk.test.lib.process.ProcessTools; +import jdk.test.lib.process.OutputAnalyzer; +import jdk.test.lib.Utils; +import jdk.test.lib.Asserts; + +/* + * @test + * @library /test/lib + * @requires vm.flavor == "server" & !vm.emulatedClient & !(vm.opt.TieredStopAtLevel == 1) + * @build jdk.test.lib.apps.* + * @run main/othervm TestPrintMdo + */ + +public class TestPrintMdo { + + private static final String PRINTMDO_OUT_FILE = "printmdo_out.txt"; + + private static void verifyPrintMdoOutput() throws Exception { + + Exception unexpected = null; + File printMdoFile = new File(PRINTMDO_OUT_FILE); + Asserts.assertTrue(printMdoFile.exists() && printMdoFile.isFile(), + "File with printmdo output not created: " + + printMdoFile.getAbsolutePath()); + try { + Scanner scanner = new Scanner(printMdoFile); + + String unexpectedMsg = + "One or more of 'VirtualCallData', 'CounterData', " + + "'ReceiverTypeData', 'bci', 'MethodData' " + + "or 'java/lang/Object' not found"; + boolean knownClassFound = false; + boolean knownProfileDataTypeFound = false; + boolean knownTokensFound = false; + + while (scanner.hasNextLine()) { + String line = scanner.nextLine(); + line = line.trim(); + System.out.println(line); + + if (line.contains("missing reason for ")) { + unexpected = new RuntimeException("Unexpected msg: missing reason for "); + break; + } + if (line.contains("VirtualCallData") || + line.contains("CounterData") || + line.contains("ReceiverTypeData")) { + knownProfileDataTypeFound = true; + } + if (line.contains("bci") || + line.contains("MethodData")) { + knownTokensFound = true; + } + if (line.contains("java/lang/Object")) { + knownClassFound = true; + } + } + if ((knownClassFound == false) || + (knownTokensFound == false) || + (knownProfileDataTypeFound == false)) { + unexpected = new RuntimeException(unexpectedMsg); + } + if (unexpected != null) { + throw unexpected; + } + } catch (Exception ex) { + throw new RuntimeException("Test ERROR " + ex, ex); + } finally { + printMdoFile.delete(); + } + } + + private static void startClhsdbForPrintMdo(long lingeredAppPid) throws Exception { + + Process p; + JDKToolLauncher launcher = JDKToolLauncher.createUsingTestJDK("jhsdb"); + launcher.addToolArg("clhsdb"); + launcher.addToolArg("--pid"); + launcher.addToolArg(Long.toString(lingeredAppPid)); + + ProcessBuilder pb = new ProcessBuilder(); + pb.command(launcher.getCommand()); + System.out.println( + pb.command().stream().collect(Collectors.joining(" "))); + + try { + p = pb.start(); + } catch (Exception attachE) { + throw new Error("Couldn't start jhsdb or attach to LingeredApp : " + attachE); + } + + // Issue the 'printmdo' input at the clhsdb prompt. + OutputStream input = p.getOutputStream(); + String str = "printmdo -a > " + PRINTMDO_OUT_FILE + "\nquit\n"; + try { + input.write(str.getBytes()); + input.flush(); + } catch (IOException ioe) { + throw new Error("Problem issuing the printmdo command: " + str, ioe); + } + + try { + p.waitFor(); + } catch (InterruptedException ie) { + throw new Error("Problem awaiting the child process: " + ie, ie); + } + + int exitValue = p.exitValue(); + if (exitValue != 0) { + String output; + try { + output = new OutputAnalyzer(p).getOutput(); + } catch (IOException ioe) { + throw new Error("Can't get failed clhsdb process output: " + ioe, ioe); + } + throw new AssertionError("clhsdb wasn't run successfully: " + output); + } + } + + public static void main (String... args) throws Exception { + + LingeredApp app = null; + + if (!Platform.shouldSAAttach()) { + System.out.println( + "SA attach not expected to work - test skipped."); + return; + } + + try { + List vmArgs = new ArrayList(); + vmArgs.add("-XX:+ProfileInterpreter"); + vmArgs.addAll(Utils.getVmOptions()); + + app = LingeredApp.startApp(vmArgs); + System.out.println ("Started LingeredApp with pid " + app.getPid()); + startClhsdbForPrintMdo(app.getPid()); + verifyPrintMdoOutput(); + } finally { + LingeredApp.stopApp(app); + } + } +} diff --git a/hotspot/test/serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java b/hotspot/test/serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java index 2a46621d118..50531949002 100644 --- a/hotspot/test/serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java +++ b/hotspot/test/serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java @@ -53,7 +53,6 @@ import jdk.test.lib.process.ProcessTools; public class JMapHProfLargeHeapTest { private static final String HEAP_DUMP_FILE_NAME = "heap.bin"; - private static final String HPROF_HEADER_1_0_1 = "JAVA PROFILE 1.0.1"; private static final String HPROF_HEADER_1_0_2 = "JAVA PROFILE 1.0.2"; private static final long M = 1024L; private static final long G = 1024L * M; @@ -65,9 +64,7 @@ public class JMapHProfLargeHeapTest { } // All heap dumps should create 1.0.2 file format - // Hotspot internal heapdumper always use HPROF_HEADER_1_0_2 format, - // but SA heapdumper still use HPROF_HEADER_1_0_1 for small heaps - testHProfFileFormat("-Xmx1g", 22 * M, HPROF_HEADER_1_0_1); + testHProfFileFormat("-Xmx1g", 22 * M, HPROF_HEADER_1_0_2); /** * This test was deliberately commented out since the test system lacks diff --git a/hotspot/test/serviceability/sa/sadebugd/SADebugDTest.java b/hotspot/test/serviceability/sa/sadebugd/SADebugDTest.java index 80b45ecb6fd..0bbb42d4f58 100644 --- a/hotspot/test/serviceability/sa/sadebugd/SADebugDTest.java +++ b/hotspot/test/serviceability/sa/sadebugd/SADebugDTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -60,7 +60,7 @@ public class SADebugDTest { return; } - long ourPid = ProcessHandle.current().getPid(); + long ourPid = ProcessHandle.current().pid(); // The string we are expecting in the debugd ouput String golden = String.format(GOLDEN, ourPid); diff --git a/hotspot/test/serviceability/tmtools/jstack/DaemonThreadTest.java b/hotspot/test/serviceability/tmtools/jstack/DaemonThreadTest.java index 23bba681fc1..29251d80378 100644 --- a/hotspot/test/serviceability/tmtools/jstack/DaemonThreadTest.java +++ b/hotspot/test/serviceability/tmtools/jstack/DaemonThreadTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -78,7 +78,7 @@ public class DaemonThreadTest { thread.start(); // Run jstack tool and collect the output - JstackTool jstackTool = new JstackTool(ProcessHandle.current().getPid()); + JstackTool jstackTool = new JstackTool(ProcessHandle.current().pid()); ToolResults results = jstackTool.measure(); // Analyze the jstack output for the correct thread type diff --git a/hotspot/test/serviceability/tmtools/jstack/SpreadLockTest.java b/hotspot/test/serviceability/tmtools/jstack/SpreadLockTest.java index 8f3be8153c6..e3928d03731 100644 --- a/hotspot/test/serviceability/tmtools/jstack/SpreadLockTest.java +++ b/hotspot/test/serviceability/tmtools/jstack/SpreadLockTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -96,7 +96,7 @@ public class SpreadLockTest { debuggee.start(); // Collect output from the jstack tool - JstackTool jstackTool = new JstackTool(ProcessHandle.current().getPid()); + JstackTool jstackTool = new JstackTool(ProcessHandle.current().pid()); ToolResults results1 = jstackTool.measure(); // Go to method b() diff --git a/hotspot/test/serviceability/tmtools/jstack/ThreadNamesTest.java b/hotspot/test/serviceability/tmtools/jstack/ThreadNamesTest.java index 6402c2265c4..e0b6f06d125 100644 --- a/hotspot/test/serviceability/tmtools/jstack/ThreadNamesTest.java +++ b/hotspot/test/serviceability/tmtools/jstack/ThreadNamesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -61,7 +61,7 @@ public class ThreadNamesTest { thread.start(); // Run jstack tool and collect the output - JstackTool jstackTool = new JstackTool(ProcessHandle.current().getPid()); + JstackTool jstackTool = new JstackTool(ProcessHandle.current().pid()); ToolResults results = jstackTool.measure(); // Analyze the jstack output for the strange thread name diff --git a/hotspot/test/serviceability/tmtools/jstack/TraveledLockTest.java b/hotspot/test/serviceability/tmtools/jstack/TraveledLockTest.java index 9a87d6bdc13..ac765997fa7 100644 --- a/hotspot/test/serviceability/tmtools/jstack/TraveledLockTest.java +++ b/hotspot/test/serviceability/tmtools/jstack/TraveledLockTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -95,7 +95,7 @@ public class TraveledLockTest { debuggee.start(); // Collect output from the jstack tool - JstackTool jstackTool = new JstackTool(ProcessHandle.current().getPid()); + JstackTool jstackTool = new JstackTool(ProcessHandle.current().pid()); ToolResults results1 = jstackTool.measure(); // Go to method b() diff --git a/hotspot/test/serviceability/tmtools/jstack/WaitNotifyThreadTest.java b/hotspot/test/serviceability/tmtools/jstack/WaitNotifyThreadTest.java index 9b5a5449326..c4fe1cc8ba9 100644 --- a/hotspot/test/serviceability/tmtools/jstack/WaitNotifyThreadTest.java +++ b/hotspot/test/serviceability/tmtools/jstack/WaitNotifyThreadTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -105,7 +105,7 @@ public class WaitNotifyThreadTest { waitThread.start(); // Collect output from the jstack tool - JstackTool jstackTool = new JstackTool(ProcessHandle.current().getPid()); + JstackTool jstackTool = new JstackTool(ProcessHandle.current().pid()); ToolResults results = jstackTool.measure(); // Analyze the jstack output for the patterns needed diff --git a/hotspot/test/serviceability/tmtools/jstat/GarbageProducerTest.java b/hotspot/test/serviceability/tmtools/jstat/GarbageProducerTest.java new file mode 100644 index 00000000000..dfe1a8f12dc --- /dev/null +++ b/hotspot/test/serviceability/tmtools/jstat/GarbageProducerTest.java @@ -0,0 +1,89 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.lang.management.ManagementFactory; +import utils.GarbageProducer; +import common.TmTool; +import utils.JstatResults; + +/** + * Base class for jstat testing which uses GarbageProducer to allocate garbage. + */ +public class GarbageProducerTest { + + // Iterations of measurement to get consistent value of counters and jstat. + private final static int ITERATIONS = 10; + private final static float TARGET_MEMORY_USAGE = 0.7f; + private final static float MEASUREMENT_TOLERANCE = 0.05f; + private final GarbageProducer garbageProducer; + private final TmTool jstatTool; + + public GarbageProducerTest(TmTool tool) { + garbageProducer = new GarbageProducer(TARGET_MEMORY_USAGE); + // We will be running jstat tool + jstatTool = tool; + } + + public void run() throws Exception { + // Run once and get the results asserting that they are reasonable + JstatResults measurement1 = jstatTool.measure(); + measurement1.assertConsistency(); + // Eat metaspace and heap then run the tool again and get the results asserting that they are reasonable + System.gc(); + garbageProducer.allocateMetaspaceAndHeap(); + // Collect garbage. Also update VM statistics + System.gc(); + int i = 0; + long collectionCountBefore = getCollectionCount(); + JstatResults measurement2 = jstatTool.measure(); + do { + System.out.println("Measurement #" + i); + long currentCounter = getCollectionCount(); + // Check if GC cycle occured during measurement + if (currentCounter == collectionCountBefore) { + measurement2.assertConsistency(); + checkOldGenMeasurement(measurement2); + return; + } else { + System.out.println("GC happened during measurement."); + } + collectionCountBefore = getCollectionCount(); + measurement2 = jstatTool.measure(); + + } while (i++ < ITERATIONS); + // Checking will be performed without consistency guarantee. + checkOldGenMeasurement(measurement2); + } + + private void checkOldGenMeasurement(JstatResults measurement2) { + float oldGenAllocationRatio = garbageProducer.getOldGenAllocationRatio() - MEASUREMENT_TOLERANCE; + // Assert that space has been utilized accordingly + JstatResults.assertSpaceUtilization(measurement2, TARGET_MEMORY_USAGE, oldGenAllocationRatio); + } + + private static long getCollectionCount() { + return ManagementFactory.getGarbageCollectorMXBeans().stream() + .mapToLong(b -> b.getCollectionCount()) + .sum(); + } +} diff --git a/hotspot/test/serviceability/tmtools/jstat/GcCapacityTest.java b/hotspot/test/serviceability/tmtools/jstat/GcCapacityTest.java index 6723e6e02d1..820c8dab35d 100644 --- a/hotspot/test/serviceability/tmtools/jstat/GcCapacityTest.java +++ b/hotspot/test/serviceability/tmtools/jstat/GcCapacityTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -38,7 +38,7 @@ public class GcCapacityTest { public static void main(String[] args) throws Exception { // We will be running "jstat -gc" tool - JstatGcCapacityTool jstatGcTool = new JstatGcCapacityTool(ProcessHandle.current().getPid()); + JstatGcCapacityTool jstatGcTool = new JstatGcCapacityTool(ProcessHandle.current().pid()); // Run once and get the results asserting that they are reasonable JstatGcCapacityResults measurement1 = jstatGcTool.measure(); diff --git a/hotspot/test/serviceability/tmtools/jstat/GcCauseTest01.java b/hotspot/test/serviceability/tmtools/jstat/GcCauseTest01.java index 9e4c5eb2e64..96f0728a349 100644 --- a/hotspot/test/serviceability/tmtools/jstat/GcCauseTest01.java +++ b/hotspot/test/serviceability/tmtools/jstat/GcCauseTest01.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -41,7 +41,7 @@ public class GcCauseTest01 { public static void main(String[] args) throws Exception { // We will be running "jstat -gc" tool - JstatGcCauseTool jstatGcTool = new JstatGcCauseTool(ProcessHandle.current().getPid()); + JstatGcCauseTool jstatGcTool = new JstatGcCauseTool(ProcessHandle.current().pid()); // Run once and get the results asserting that they are reasonable JstatGcCauseResults measurement1 = jstatGcTool.measure(); diff --git a/hotspot/test/serviceability/tmtools/jstat/GcCauseTest02.java b/hotspot/test/serviceability/tmtools/jstat/GcCauseTest02.java index 2bdf04d39c2..b92ea57d0a8 100644 --- a/hotspot/test/serviceability/tmtools/jstat/GcCauseTest02.java +++ b/hotspot/test/serviceability/tmtools/jstat/GcCauseTest02.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,39 +25,19 @@ * @test * @summary Test checks output displayed with jstat -gccause. * Test scenario: - * tests forces debuggee application eat ~70% of heap and runs jstat. - * jstat should show that ~70% of heap (OC/OU ~= 70%). + * test forces debuggee application eat ~70% of heap and runs jstat. + * jstat should show actual usage of old gen (OC/OU ~= old gen usage). * @requires vm.opt.ExplicitGCInvokesConcurrent != true * @modules java.base/jdk.internal.misc * @library /test/lib * @library ../share - * @run main/othervm -XX:+UsePerfData -XX:InitialHeapSize=128M -XX:MaxHeapSize=128M -XX:MaxMetaspaceSize=128M GcCauseTest02 + * @run main/othervm -XX:+UsePerfData -XX:MaxNewSize=4m -XX:MaxHeapSize=128M -XX:MaxMetaspaceSize=128M GcCauseTest02 */ import utils.*; public class GcCauseTest02 { - private final static float targetMemoryUsagePercent = 0.7f; - public static void main(String[] args) throws Exception { - - // We will be running "jstat -gc" tool - JstatGcCauseTool jstatGcTool = new JstatGcCauseTool(ProcessHandle.current().getPid()); - - // Run once and get the results asserting that they are reasonable - JstatGcCauseResults measurement1 = jstatGcTool.measure(); - measurement1.assertConsistency(); - - GcProvoker gcProvoker = new GcProvoker(); - - // Eat metaspace and heap then run the tool again and get the results asserting that they are reasonable - gcProvoker.allocateAvailableMetaspaceAndHeap(targetMemoryUsagePercent); - // Collect garbage. Also update VM statistics - System.gc(); - JstatGcCauseResults measurement2 = jstatGcTool.measure(); - measurement2.assertConsistency(); - - // Assert that space has been utilized acordingly - JstatResults.assertSpaceUtilization(measurement2, targetMemoryUsagePercent); + new GarbageProducerTest(new JstatGcCauseTool(ProcessHandle.current().pid())).run(); } } diff --git a/hotspot/test/serviceability/tmtools/jstat/GcCauseTest03.java b/hotspot/test/serviceability/tmtools/jstat/GcCauseTest03.java index 91ebd0ffcee..13bd73b5303 100644 --- a/hotspot/test/serviceability/tmtools/jstat/GcCauseTest03.java +++ b/hotspot/test/serviceability/tmtools/jstat/GcCauseTest03.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -41,7 +41,7 @@ public class GcCauseTest03 { public static void main(String[] args) throws Exception { // We will be running "jstat -gc" tool - JstatGcCauseTool jstatGcTool = new JstatGcCauseTool(ProcessHandle.current().getPid()); + JstatGcCauseTool jstatGcTool = new JstatGcCauseTool(ProcessHandle.current().pid()); System.gc(); diff --git a/hotspot/test/serviceability/tmtools/jstat/GcNewTest.java b/hotspot/test/serviceability/tmtools/jstat/GcNewTest.java index 8e1d6ae364a..4719baa6239 100644 --- a/hotspot/test/serviceability/tmtools/jstat/GcNewTest.java +++ b/hotspot/test/serviceability/tmtools/jstat/GcNewTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -40,7 +40,7 @@ public class GcNewTest { public static void main(String[] args) throws Exception { // We will be running "jstat -gc" tool - JstatGcNewTool jstatGcTool = new JstatGcNewTool(ProcessHandle.current().getPid()); + JstatGcNewTool jstatGcTool = new JstatGcNewTool(ProcessHandle.current().pid()); // Run once and get the results asserting that they are reasonable JstatGcNewResults measurement1 = jstatGcTool.measure(); diff --git a/hotspot/test/serviceability/tmtools/jstat/GcTest01.java b/hotspot/test/serviceability/tmtools/jstat/GcTest01.java index cc0bf5261e2..6ee18f3f3bb 100644 --- a/hotspot/test/serviceability/tmtools/jstat/GcTest01.java +++ b/hotspot/test/serviceability/tmtools/jstat/GcTest01.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -44,7 +44,7 @@ public class GcTest01 { public static void main(String[] args) throws Exception { // We will be running "jstat -gc" tool - JstatGcTool jstatGcTool = new JstatGcTool(ProcessHandle.current().getPid()); + JstatGcTool jstatGcTool = new JstatGcTool(ProcessHandle.current().pid()); // Run once and get the results asserting that they are reasonable JstatGcResults measurement1 = jstatGcTool.measure(); diff --git a/hotspot/test/serviceability/tmtools/jstat/GcTest02.java b/hotspot/test/serviceability/tmtools/jstat/GcTest02.java index 91406fa3838..a0e0cb4fcac 100644 --- a/hotspot/test/serviceability/tmtools/jstat/GcTest02.java +++ b/hotspot/test/serviceability/tmtools/jstat/GcTest02.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,43 +21,23 @@ * questions. */ -import utils.*; /* * @test * @summary Test checks output displayed with jstat -gc. * Test scenario: - * tests forces debuggee application eat ~70% of heap and runs jstat. - * jstat should show that ~70% of heap is utilized (OC/OU ~= 70%). + * test forces debuggee application eat ~70% of heap and runs jstat. + * jstat should show actual usage of old gen (OC/OU ~= old gen usage). * @requires vm.opt.ExplicitGCInvokesConcurrent != true * @modules java.base/jdk.internal.misc * @library /test/lib * @library ../share - * @run main/othervm -XX:+UsePerfData -XX:InitialHeapSize=128M -XX:MaxHeapSize=128M -XX:MaxMetaspaceSize=128M GcTest02 + * @run main/othervm -XX:+UsePerfData -XX:MaxNewSize=4m -XX:MaxHeapSize=128M -XX:MaxMetaspaceSize=128M GcTest02 */ +import utils.*; public class GcTest02 { - private final static float targetMemoryUsagePercent = 0.7f; - public static void main(String[] args) throws Exception { - - // We will be running "jstat -gc" tool - JstatGcTool jstatGcTool = new JstatGcTool(ProcessHandle.current().getPid()); - - // Run once and get the results asserting that they are reasonable - JstatGcResults measurement1 = jstatGcTool.measure(); - measurement1.assertConsistency(); - - GcProvoker gcProvoker = new GcProvoker(); - - // Eat metaspace and heap then run the tool again and get the results asserting that they are reasonable - gcProvoker.allocateAvailableMetaspaceAndHeap(targetMemoryUsagePercent); - // Collect garbage. Also updates VM statistics - System.gc(); - JstatGcResults measurement2 = jstatGcTool.measure(); - measurement2.assertConsistency(); - - // Assert that space has been utilized acordingly - JstatResults.assertSpaceUtilization(measurement2, targetMemoryUsagePercent); + new GarbageProducerTest(new JstatGcTool(ProcessHandle.current().pid())).run(); } } diff --git a/hotspot/test/serviceability/tmtools/jstat/utils/GarbageProducer.java b/hotspot/test/serviceability/tmtools/jstat/utils/GarbageProducer.java new file mode 100644 index 00000000000..0dd7c858482 --- /dev/null +++ b/hotspot/test/serviceability/tmtools/jstat/utils/GarbageProducer.java @@ -0,0 +1,121 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +package utils; + +import java.lang.management.ManagementFactory; +import java.lang.management.MemoryMXBean; +import java.lang.management.MemoryPoolMXBean; +import java.lang.management.MemoryUsage; +import java.util.ArrayList; +import java.util.List; + +/** + * This is an class used to allocate specified amount of metaspace and heap. + */ +public class GarbageProducer { + + // Uses fixed small objects to avoid Humongous objects allocation with G1 GC. + private static final int MEMORY_CHUNK = 2048; + + public static List allocatedMetaspace; + public static List allocatedMemory; + + private final MemoryMXBean memoryMXBean; + private final float targetMemoryUsagePercent; + private final long targetMemoryUsage; + + /** + * @param targetMemoryUsagePercent how many percent of metaspace and heap to + * allocate + */ + public GarbageProducer(float targetMemoryUsagePercent) { + memoryMXBean = ManagementFactory.getMemoryMXBean(); + this.targetMemoryUsagePercent = targetMemoryUsagePercent; + targetMemoryUsage = (long) (memoryMXBean.getHeapMemoryUsage().getMax() * targetMemoryUsagePercent); + } + + /** + * Allocates heap and metaspace upon exit targetMemoryUsagePercent percents + * of heap and metaspace have been consumed. + */ + public void allocateMetaspaceAndHeap() { + // Metaspace should be filled before Java Heap to prevent unexpected OOME + // in the Java Heap while filling Metaspace + allocatedMetaspace = eatMetaspace(targetMemoryUsagePercent); + allocatedMemory = allocateGarbage(targetMemoryUsage); + } + + private List eatMetaspace(float targetUsage) { + List list = new ArrayList<>(); + MemoryPoolMXBean metaspacePool = getMatchedMemoryPool(".*Metaspace.*"); + float currentUsage; + GeneratedClassProducer gp = new GeneratedClassProducer(); + do { + try { + list.add(gp.create(0)); + } catch (OutOfMemoryError oome) { + list = null; + throw new RuntimeException("Unexpected OOME '" + oome.getMessage() + "' while eating " + targetUsage + " of Metaspace."); + } + MemoryUsage memoryUsage = metaspacePool.getUsage(); + currentUsage = (((float) memoryUsage.getUsed()) / memoryUsage.getMax()); + } while (currentUsage < targetUsage); + return list; + } + + private MemoryPoolMXBean getMatchedMemoryPool(String patternPoolName) { + return ManagementFactory.getMemoryPoolMXBeans().stream() + .filter(bean -> bean.getName().matches(patternPoolName)) + .findFirst() + .orElseThrow(() -> new RuntimeException("Cannot find '" + patternPoolName + "' memory pool.")); + } + + private List allocateGarbage(long targetMemoryUsage) { + List list = new ArrayList<>(); + do { + try { + list.add(new byte[MEMORY_CHUNK]); + } catch (OutOfMemoryError e) { + list = null; + throw new RuntimeException("Unexpected OOME '" + e.getMessage() + "'"); + } + } while (memoryMXBean.getHeapMemoryUsage().getUsed() < targetMemoryUsage); + return list; + } + + /** + * Returns allocation rate for old gen based on appropriate MemoryPoolMXBean + * memory usage. + * + * @return allocation rate + */ + public float getOldGenAllocationRatio() { + MemoryPoolMXBean oldGenBean = getMatchedMemoryPool(".*Old.*|.*Tenured.*"); + MemoryUsage usage = oldGenBean.getUsage(); + System.out.format("Memory usage for %1s.\n", oldGenBean.getName()); + System.out.format("Used: %1d\n", usage.getUsed()); + System.out.format("Commited: %1d\n", usage.getCommitted()); + System.out.format("Max: %1d\n", usage.getMax()); + return ((float) usage.getUsed()) / usage.getCommitted(); + } +} diff --git a/hotspot/test/serviceability/tmtools/jstat/utils/GcProvoker.java b/hotspot/test/serviceability/tmtools/jstat/utils/GcProvoker.java index f2111fa5724..8457091800c 100644 --- a/hotspot/test/serviceability/tmtools/jstat/utils/GcProvoker.java +++ b/hotspot/test/serviceability/tmtools/jstat/utils/GcProvoker.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,9 +22,6 @@ */ package utils; -import java.lang.management.ManagementFactory; -import java.lang.management.MemoryPoolMXBean; -import java.lang.management.MemoryUsage; import java.util.ArrayList; import java.util.List; @@ -36,11 +33,7 @@ import java.util.List; public class GcProvoker{ // Uses fixed small objects to avoid Humongous objects allocation in G1 - public static final int MEMORY_CHUNK = 2048; - public static final float ALLOCATION_TOLERANCE = 0.05f; - - public static List allocatedMetaspace; - public static List allocatedMemory; + private static final int MEMORY_CHUNK = 2048; private final Runtime runtime; @@ -61,21 +54,6 @@ public class GcProvoker{ return list; } - private List allocateAvailableHeap(float targetUsage) { - // Calculates size of free memory after allocation with small tolerance. - long minFreeMemory = (long) ((1.0 - (targetUsage + ALLOCATION_TOLERANCE)) * runtime.maxMemory()); - List list = new ArrayList<>(); - do { - try { - list.add(new byte[MEMORY_CHUNK]); - } catch (OutOfMemoryError e) { - list = null; - throw new RuntimeException("Unexpected OOME '" + e.getMessage() + "' while eating " + targetUsage + " of heap memory."); - } - } while (runtime.freeMemory() > minFreeMemory); - return list; - } - /** * This method provokes a GC */ @@ -93,65 +71,7 @@ public class GcProvoker{ } } - /** - * Allocates heap and metaspace upon exit not less than targetMemoryUsagePercent percents - * of heap and metaspace have been consumed. - * - * @param targetMemoryUsagePercent how many percent of heap and metaspace to - * allocate - */ - - public void allocateMetaspaceAndHeap(float targetMemoryUsagePercent) { - // Metaspace should be filled before Java Heap to prevent unexpected OOME - // in the Java Heap while filling Metaspace - allocatedMetaspace = eatMetaspace(targetMemoryUsagePercent); - allocatedMemory = allocateHeap(targetMemoryUsagePercent); - } - - /** - * Allocates heap and metaspace upon exit targetMemoryUsagePercent percents - * of heap and metaspace have been consumed. - * - * @param targetMemoryUsagePercent how many percent of heap and metaspace to - * allocate - */ - public void allocateAvailableMetaspaceAndHeap(float targetMemoryUsagePercent) { - // Metaspace should be filled before Java Heap to prevent unexpected OOME - // in the Java Heap while filling Metaspace - allocatedMetaspace = eatMetaspace(targetMemoryUsagePercent); - allocatedMemory = allocateAvailableHeap(targetMemoryUsagePercent); - } - - private List eatMetaspace(float targetUsage) { - List list = new ArrayList<>(); - final String metaspacePoolName = "Metaspace"; - MemoryPoolMXBean metaspacePool = null; - for (MemoryPoolMXBean pool : ManagementFactory.getMemoryPoolMXBeans()) { - if (pool.getName().contains(metaspacePoolName)) { - metaspacePool = pool; - break; - } - } - if (metaspacePool == null) { - throw new RuntimeException("MXBean for Metaspace pool wasn't found"); - } - float currentUsage; - GeneratedClassProducer gp = new GeneratedClassProducer(); - do { - try { - list.add(gp.create(0)); - } catch (OutOfMemoryError oome) { - list = null; - throw new RuntimeException("Unexpected OOME '" + oome.getMessage() + "' while eating " + targetUsage + " of Metaspace."); - } - MemoryUsage memoryUsage = metaspacePool.getUsage(); - currentUsage = (((float) memoryUsage.getUsed()) / memoryUsage.getMax()); - } while (currentUsage < targetUsage); - return list; - } - public GcProvoker() { runtime = Runtime.getRuntime(); } - } diff --git a/hotspot/test/serviceability/tmtools/jstat/utils/GcProvokerImpl.java b/hotspot/test/serviceability/tmtools/jstat/utils/GcProvokerImpl.java deleted file mode 100644 index 565d86cf377..00000000000 --- a/hotspot/test/serviceability/tmtools/jstat/utils/GcProvokerImpl.java +++ /dev/null @@ -1,113 +0,0 @@ -/* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ -package utils; - -import java.lang.management.ManagementFactory; -import java.lang.management.MemoryPoolMXBean; -import java.lang.management.MemoryUsage; -import java.util.ArrayList; -import java.util.List; - -/** - * - * Utilities to provoke GC in various ways - */ -public class GcProvokerImpl implements GcProvoker { - - private static List eatenMetaspace; - private static List eatenMemory; - - static List eatHeapMemory(float targetUsage) { - long maxMemory = Runtime.getRuntime().maxMemory(); - // uses fixed small objects to avoid Humongous objects allocation in G1 - int memoryChunk = 2048; - List list = new ArrayList<>(); - long used = 0; - long target = (long) (maxMemory * targetUsage); - while (used < target) { - try { - list.add(new byte[memoryChunk]); - used += memoryChunk; - } catch (OutOfMemoryError e) { - list = null; - throw new RuntimeException("Unexpected OOME '" + e.getMessage() + "' while eating " + targetUsage + " of heap memory."); - } - } - return list; - } - - @Override - public void provokeGc() { - for (int i = 0; i < 3; i++) { - long edenSize = Pools.getEdenCommittedSize(); - long heapSize = Pools.getHeapCommittedSize(); - float targetPercent = ((float) edenSize) / (heapSize); - if ((targetPercent < 0) || (targetPercent > 1.0)) { - throw new RuntimeException("Error in the percent calculation" + " (eden size: " + edenSize + ", heap size: " + heapSize + ", calculated eden percent: " + targetPercent + ")"); - } - eatHeapMemory(targetPercent); - eatHeapMemory(targetPercent); - System.gc(); - } - } - - @Override - public void eatMetaspaceAndHeap(float targetMemoryUsagePercent) { - // Metaspace should be filled before Java Heap to prevent unexpected OOME - // in the Java Heap while filling Metaspace - eatenMetaspace = eatMetaspace(targetMemoryUsagePercent); - eatenMemory = eatHeapMemory(targetMemoryUsagePercent); - } - - private static List eatMetaspace(float targetUsage) { - List list = new ArrayList<>(); - final String metaspacePoolName = "Metaspace"; - MemoryPoolMXBean metaspacePool = null; - for (MemoryPoolMXBean pool : ManagementFactory.getMemoryPoolMXBeans()) { - if (pool.getName().contains(metaspacePoolName)) { - metaspacePool = pool; - break; - } - } - if (metaspacePool == null) { - throw new RuntimeException("MXBean for Metaspace pool wasn't found"); - } - float currentUsage; - GeneratedClassProducer gp = new GeneratedClassProducer(); - do { - try { - list.add(gp.create(0)); - } catch (OutOfMemoryError oome) { - list = null; - throw new RuntimeException("Unexpected OOME '" + oome.getMessage() + "' while eating " + targetUsage + " of Metaspace."); - } - MemoryUsage memoryUsage = metaspacePool.getUsage(); - currentUsage = (((float) memoryUsage.getUsed()) / memoryUsage.getMax()); - } while (currentUsage < targetUsage); - return list; - } - - public GcProvokerImpl() { - } - -} diff --git a/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcCapacityResults.java b/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcCapacityResults.java index 6ac62fa48ef..350a2a6470d 100644 --- a/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcCapacityResults.java +++ b/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcCapacityResults.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -62,6 +62,7 @@ public class JstatGcCapacityResults extends JstatResults { /** * Checks the overall consistency of the results reported by the tool */ + @Override public void assertConsistency() { // Check exit code @@ -117,8 +118,6 @@ public class JstatGcCapacityResults extends JstatResults { float MC = getFloatValue("MC"); assertThat(MC >= MCMN, "MC < MCMN (generation capacity < min generation capacity)"); assertThat(MC <= MCMX, "MGC > MCMX (generation capacity > max generation capacity)"); - - } /** @@ -139,21 +138,4 @@ public class JstatGcCapacityResults extends JstatResults { } return false; } - - private static final float FLOAT_COMPARISON_TOLERANCE = 0.0011f; - - private static boolean checkFloatIsSum(float sum, float... floats) { - for (float f : floats) { - sum -= f; - } - - return Math.abs(sum) <= FLOAT_COMPARISON_TOLERANCE; - } - - private void assertThat(boolean b, String message) { - if (!b) { - throw new RuntimeException(message); - } - } - } diff --git a/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcCauseResults.java b/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcCauseResults.java index 3bb708dd7ba..cf435f8dba7 100644 --- a/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcCauseResults.java +++ b/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcCauseResults.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -56,6 +56,7 @@ public class JstatGcCauseResults extends JstatResults { /** * Checks the overall consistency of the results reported by the tool */ + @Override public void assertConsistency() { assertThat(getExitCode() == 0, "Unexpected exit code: " + getExitCode()); @@ -83,21 +84,4 @@ public class JstatGcCauseResults extends JstatResults { assertThat(checkFloatIsSum(GCT, YGCT, FGCT), "GCT != (YGCT + FGCT) " + "(GCT = " + GCT + ", YGCT = " + YGCT + ", FGCT = " + FGCT + ", (YCGT + FGCT) = " + (YGCT + FGCT) + ")"); } - - private static final float FLOAT_COMPARISON_TOLERANCE = 0.0011f; - - private static boolean checkFloatIsSum(float sum, float... floats) { - for (float f : floats) { - sum -= f; - } - - return Math.abs(sum) <= FLOAT_COMPARISON_TOLERANCE; - } - - private void assertThat(boolean b, String message) { - if (!b) { - throw new RuntimeException(message); - } - } - } diff --git a/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcNewResults.java b/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcNewResults.java index 24ff4490b80..ca3c04af67c 100644 --- a/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcNewResults.java +++ b/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcNewResults.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -54,6 +54,7 @@ public class JstatGcNewResults extends JstatResults { /** * Checks the overall consistency of the results reported by the tool */ + @Override public void assertConsistency() { assertThat(getExitCode() == 0, "Unexpected exit code: " + getExitCode()); @@ -84,10 +85,4 @@ public class JstatGcNewResults extends JstatResults { int MTT = getIntValue("MTT"); assertThat(TT <= MTT, "TT > MTT (tenuring threshold > maximum tenuring threshold)"); } - - private void assertThat(boolean b, String message) { - if (!b) { - throw new RuntimeException(message); - } - } } diff --git a/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcResults.java b/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcResults.java index 95905418a37..7b736d9f071 100644 --- a/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcResults.java +++ b/hotspot/test/serviceability/tmtools/jstat/utils/JstatGcResults.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -61,6 +61,7 @@ public class JstatGcResults extends JstatResults { /** * Checks the overall consistency of the results reported by the tool */ + @Override public void assertConsistency() { assertThat(getExitCode() == 0, "Unexpected exit code: " + getExitCode()); @@ -112,21 +113,4 @@ public class JstatGcResults extends JstatResults { assertThat(checkFloatIsSum(GCT, YGCT, FGCT), "GCT != (YGCT + FGCT) " + "(GCT = " + GCT + ", YGCT = " + YGCT + ", FGCT = " + FGCT + ", (YCGT + FGCT) = " + (YGCT + FGCT) + ")"); } - - private static final float FLOAT_COMPARISON_TOLERANCE = 0.0011f; - - private static boolean checkFloatIsSum(float sum, float... floats) { - for (float f : floats) { - sum -= f; - } - - return Math.abs(sum) <= FLOAT_COMPARISON_TOLERANCE; - } - - private void assertThat(boolean b, String message) { - if (!b) { - throw new RuntimeException(message); - } - } - } diff --git a/hotspot/test/serviceability/tmtools/jstat/utils/JstatResults.java b/hotspot/test/serviceability/tmtools/jstat/utils/JstatResults.java index d4f961051f8..f628a27d1de 100644 --- a/hotspot/test/serviceability/tmtools/jstat/utils/JstatResults.java +++ b/hotspot/test/serviceability/tmtools/jstat/utils/JstatResults.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,6 +30,8 @@ import common.ToolResults; */ abstract public class JstatResults extends ToolResults { + private static final float FLOAT_COMPARISON_TOLERANCE = 0.0011f; + public JstatResults(ToolResults rawResults) { super(rawResults); } @@ -110,38 +112,61 @@ abstract public class JstatResults extends ToolResults { * space has been utilized */ public static void assertSpaceUtilization(JstatResults measurement, float targetMemoryUsagePercent) { + assertSpaceUtilization(measurement, targetMemoryUsagePercent, targetMemoryUsagePercent); + } + + /** + * Helper function to assert the utilization of the space + * + * @param measurement - measurement results to analyze + * @param targetMetaspaceUsagePercent -assert that not less than this amount + * of metaspace has been utilized + * @param targetOldSpaceUsagePercent -assert that not less than this amount + * of old space has been utilized + */ + public static void assertSpaceUtilization(JstatResults measurement, float targetMetaspaceUsagePercent, + float targetOldSpaceUsagePercent) { if (measurement.valueExists("OU")) { float OC = measurement.getFloatValue("OC"); float OU = measurement.getFloatValue("OU"); - assertThat((OU / OC) > targetMemoryUsagePercent, "Old space utilization should be > " - + (targetMemoryUsagePercent * 100) + "%, actually OU / OC = " + (OU / OC)); + assertThat((OU / OC) > targetOldSpaceUsagePercent, "Old space utilization should be > " + + (targetOldSpaceUsagePercent * 100) + "%, actually OU / OC = " + (OU / OC)); } if (measurement.valueExists("MU")) { float MC = measurement.getFloatValue("MC"); float MU = measurement.getFloatValue("MU"); - assertThat((MU / MC) > targetMemoryUsagePercent, "Metaspace utilization should be > " - + (targetMemoryUsagePercent * 100) + "%, actually MU / MC = " + (MU / MC)); + assertThat((MU / MC) > targetMetaspaceUsagePercent, "Metaspace utilization should be > " + + (targetMetaspaceUsagePercent * 100) + "%, actually MU / MC = " + (MU / MC)); } if (measurement.valueExists("O")) { float O = measurement.getFloatValue("O"); - assertThat(O > targetMemoryUsagePercent * 100, "Old space utilization should be > " - + (targetMemoryUsagePercent * 100) + "%, actually O = " + O); + assertThat(O > targetOldSpaceUsagePercent * 100, "Old space utilization should be > " + + (targetOldSpaceUsagePercent * 100) + "%, actually O = " + O); } if (measurement.valueExists("M")) { float M = measurement.getFloatValue("M"); - assertThat(M > targetMemoryUsagePercent * 100, "Metaspace utilization should be > " - + (targetMemoryUsagePercent * 100) + "%, actually M = " + M); + assertThat(M > targetMetaspaceUsagePercent * 100, "Metaspace utilization should be > " + + (targetMetaspaceUsagePercent * 100) + "%, actually M = " + M); } } - private static void assertThat(boolean result, String message) { + public static void assertThat(boolean result, String message) { if (!result) { throw new RuntimeException(message); } } + public static boolean checkFloatIsSum(float sum, float... floats) { + for (float f : floats) { + sum -= f; + } + + return Math.abs(sum) <= FLOAT_COMPARISON_TOLERANCE; + } + + abstract public void assertConsistency(); } diff --git a/hotspot/test/test_env.sh b/hotspot/test/test_env.sh index 43d1a76ed92..0c300d4fd96 100644 --- a/hotspot/test/test_env.sh +++ b/hotspot/test/test_env.sh @@ -214,6 +214,11 @@ if [ $? = 0 ] then VM_CPU="aarch64" fi +grep "arm64" vm_version.out > ${NULL} +if [ $? = 0 ] +then + VM_CPU="aarch64" +fi export VM_TYPE VM_BITS VM_OS VM_CPU echo "VM_TYPE=${VM_TYPE}" echo "VM_BITS=${VM_BITS}" diff --git a/hotspot/test/testlibrary/ctw/Makefile b/hotspot/test/testlibrary/ctw/Makefile index db7204b1f12..3b521188daf 100644 --- a/hotspot/test/testlibrary/ctw/Makefile +++ b/hotspot/test/testlibrary/ctw/Makefile @@ -1,5 +1,5 @@ # -# Copyright (c) 2013, 2016. Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it diff --git a/hotspot/test/testlibrary/ctw/src/sun/hotspot/tools/ctw/PathHandler.java b/hotspot/test/testlibrary/ctw/src/sun/hotspot/tools/ctw/PathHandler.java index 36e6ddea8be..f5347cd8242 100644 --- a/hotspot/test/testlibrary/ctw/src/sun/hotspot/tools/ctw/PathHandler.java +++ b/hotspot/test/testlibrary/ctw/src/sun/hotspot/tools/ctw/PathHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -151,8 +151,9 @@ public abstract class PathHandler { if (id >= Utils.COMPILE_THE_WORLD_START_AT) { try { Class aClass = loader.loadClass(name); - if (name != "sun.reflect.misc.Trampoline" - && name != "sun.tools.jconsole.OutputViewer") { // workaround for JDK-8159155 + if (!"sun.reflect.misc.Trampoline".equals(name) + // workaround for JDK-8159155 + && !"sun.tools.jconsole.OutputViewer".equals(name)) { UNSAFE.ensureClassInitialized(aClass); } CompileTheWorld.OUT.printf("[%d]\t%s%n", id, name); diff --git a/hotspot/test/testlibrary/jittester/Makefile b/hotspot/test/testlibrary/jittester/Makefile index 14f0cb3fba1..e4dd97cff23 100644 --- a/hotspot/test/testlibrary/jittester/Makefile +++ b/hotspot/test/testlibrary/jittester/Makefile @@ -108,7 +108,7 @@ INIT: $(DIST_DIR) $(shell if [ ! -d $(CLASSES_DIR) ]; then mkdir -p $(CLASSES_DIR); fi) install: clean_testbase testgroup testroot copytestlibrary copyaot JAR cleantmp - $(JAVA) --add-exports=java.base/jdk.internal.org.objectweb.asm=ALL-UNNAMED -ea -jar $(DIST_JAR) $(APPLICATION_ARGS) + $(JAVA) --add-exports=java.base/jdk.internal.org.objectweb.asm=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED -ea -jar $(DIST_JAR) $(APPLICATION_ARGS) clean_testbase: @rm -rf $(TESTBASE_DIR) diff --git a/hotspot/test/testlibrary/jittester/src/jdk/test/lib/jittester/TestsGenerator.java b/hotspot/test/testlibrary/jittester/src/jdk/test/lib/jittester/TestsGenerator.java index 3974f078d7b..952e34182a3 100644 --- a/hotspot/test/testlibrary/jittester/src/jdk/test/lib/jittester/TestsGenerator.java +++ b/hotspot/test/testlibrary/jittester/src/jdk/test/lib/jittester/TestsGenerator.java @@ -43,6 +43,7 @@ public abstract class TestsGenerator implements BiConsumer { protected final Path generatorDir; protected final Function preRunActions; protected final String jtDriverOptions; + private static final String DISABLE_WARNINGS = "-XX:-PrintWarnings"; protected TestsGenerator(String suffix) { this(suffix, s -> new String[0], ""); @@ -57,8 +58,8 @@ public abstract class TestsGenerator implements BiConsumer { protected void generateGoldenOut(String mainClassName) { String classPath = getRoot() + File.pathSeparator + generatorDir; - ProcessBuilder pb = new ProcessBuilder(JAVA, "-Xint", "-Xverify", "-cp", classPath, - mainClassName); + ProcessBuilder pb = new ProcessBuilder(JAVA, "-Xint", DISABLE_WARNINGS, "-Xverify", + "-cp", classPath, mainClassName); String goldFile = mainClassName + ".gold"; try { runProcess(pb, generatorDir.resolve(goldFile).toString()); @@ -128,6 +129,8 @@ public abstract class TestsGenerator implements BiConsumer { .append("\n"); } header.append(" * @run driver jdk.test.lib.jittester.jtreg.JitTesterDriver ") + .append(DISABLE_WARNINGS) + .append(" ") .append(jtDriverOptions) .append(" ") .append(mainClassName) diff --git a/hotspot/test/testlibrary_tests/ctw/CtwTest.java b/hotspot/test/testlibrary_tests/ctw/CtwTest.java index eb6aedc1fbe..514df0e5cd0 100644 --- a/hotspot/test/testlibrary_tests/ctw/CtwTest.java +++ b/hotspot/test/testlibrary_tests/ctw/CtwTest.java @@ -37,6 +37,7 @@ import java.nio.file.Paths; import java.nio.file.StandardCopyOption; import java.nio.charset.Charset; +import jdk.test.lib.Platform; import jdk.test.lib.JDKToolFinder; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; @@ -93,7 +94,12 @@ public abstract class CtwTest { // concat CTW_COMMAND and args w/o 0th element String[] cmd = Arrays.copyOf(CTW_COMMAND, CTW_COMMAND.length + args.length - 1); System.arraycopy(args, 1, cmd, CTW_COMMAND.length, args.length - 1); - + if (Platform.isWindows()) { + // '*' has to be escaped on windows + for (int i = 0; i < cmd.length; ++i) { + cmd[i] = cmd[i].replace("*", "\"*\""); + } + } ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(true, cmd); OutputAnalyzer output = new OutputAnalyzer(pb.start()); dump(output, "compile"); diff --git a/jaxp/.hgtags b/jaxp/.hgtags index 9804e10e82f..76676759917 100644 --- a/jaxp/.hgtags +++ b/jaxp/.hgtags @@ -396,5 +396,35 @@ f85154af719f99a3b4d81b67a8b4c18a650d10f9 jdk-9+150 13c6906bfc861d99dc35a19c80b7a99f0b0ac58d jdk-9+151 7e3da313b1746578da648155e37dd8526e83153d jdk-9+152 1384504d2cd0e55c5e0becaeaf40ab05cae959d6 jdk-9+153 +0908877116d17c6e59092ec7d53ef687a96d3278 jdk-10+0 7fa738305436d14c0926df0f04892890cacc766b jdk-9+154 48fa77af153288b08ba794e1616a7b0685f3b67e jdk-9+155 +e930c373aaa4e0e712c9a25ba4b03d473b48c294 jdk-9+156 +b4257a40e55d5dea9fe27f7cc11c430531b7ad66 jdk-10+1 +412df235a8a229469a2cb9e7bb274d43277077d2 jdk-9+157 +60e670a65e07cc309951bd838b484401e6dd7847 jdk-9+158 +5695854e8831d0c088ab0ecf83b367ec16c9760a jdk-9+159 +fb8f2c8e15295120ff0f281dc057cfffb309e90e jdk-9+160 +51b63f1b8001a48a16805b43babc3af7b314d501 jdk-9+161 +d02b6fbcab06c59a5f5a4a6736bd4ec6d2567855 jdk-9+162 +92a38c75cd277d8b11f4382511a62087044659a1 jdk-9+163 +6dc790a4e8310c86712cfdf7561a9820818546e6 jdk-9+164 +55419603989707ec50c84bb379bbdc1adeec3ab2 jdk-9+165 +8d3febd5c9d82e49f3e6e5f8eb10f959e7b50f83 jdk-9+166 +fb8f87183981ae0ea7afdafec64763e2f1a88227 jdk-10+2 +97423b4995a216d3fb566dcc5825f3d54dcfe17f jdk-10+3 +1f64e853c72b269a3e45878515c07dad9c533592 jdk-10+4 +ac697b2bdf486ef18caad2092bd24036e14946ac jdk-10+5 +26ed5e84fa13b8dca066b01ece5bc029323611be jdk-10+6 +646567dcfa64b9a39b33d71330427737d1c1a0d5 jdk-9+167 +23a87f409371fb8ce7b764cccb3a74c3f6b29900 jdk-9+168 +5d9d2a65fb26aa183019346c11d9314819621665 jdk-9+169 +6e78f902f477a093afca85a1042f97410d01eb69 jdk-9+170 +09cae4c36242734f5450de739b8264523a030809 jdk-10+7 +856998840907b67b7e1fc49259f785ac085a189b jdk-10+8 +3c75f07b2a49cb0a4f4eb5df8bbcbc64dda3153f jdk-10+9 +c27321c889cf4c8e465a61b84572c00ef7ee6004 jdk-9+171 +bd4b2c8835f35760a51c1475b03a16cc20c62973 jdk-10+10 +eedb6e54c8bd6197ecba5fc0d8568bac8ae852dd jdk-9+172 +95bab8bf9201ae8bfdf28e164bf33b78e49477e7 jdk-10+11 +9788347e0629d0cb3a0e55a903494ff741d4fa15 jdk-9+173 diff --git a/jaxp/.jcheck/conf b/jaxp/.jcheck/conf index 5c6f62dc12c..b2581358014 100644 --- a/jaxp/.jcheck/conf +++ b/jaxp/.jcheck/conf @@ -1 +1 @@ -project=jdk9 +project=jdk10 diff --git a/jaxp/README b/jaxp/README deleted file mode 100644 index 4d65125b34c..00000000000 --- a/jaxp/README +++ /dev/null @@ -1,19 +0,0 @@ -README: - - This file should be located at the top of the Mercurial repository. - - See http://openjdk.java.net/ for more information about the OpenJDK. - - See ../README-builds.html for complete details on build machine requirements. - -Simple Build Instructions: - This repository can be loaded as a NetBeans project, built with ant, or - built with GNU make, e.g. - ant - -OR- - cd make && gnumake - - The built files that will be imported into the jdk build will be in the - "dist" directory. - Help information is available by running "ant -projecthelp" or "make help". - diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/Constants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/Constants.java index d7fc6bcedf0..a5e02cafa5e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/Constants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/Constants.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Constants for the project, mostly defined in the JVM specification. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/ExceptionConstants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/ExceptionConstants.java index 8fd320424f1..da004ea462d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/ExceptionConstants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/ExceptionConstants.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Exception constants. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/Repository.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/Repository.java index 6549b8a7650..14a935f1bb8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/Repository.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/Repository.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.JavaClass; import com.sun.org.apache.bcel.internal.util.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/AccessFlags.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/AccessFlags.java index ad50a97b501..c779c942301 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/AccessFlags.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/AccessFlags.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Attribute.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Attribute.java index 204bb2506bb..3ca3d9adc01 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Attribute.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Attribute.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/AttributeReader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/AttributeReader.java index d1f395180aa..ec9593932ee 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/AttributeReader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/AttributeReader.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Unknown (non-standard) attributes may be read via user-defined factory diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ClassFormatException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ClassFormatException.java index 203faf3c101..6ab8dfa4f2b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ClassFormatException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ClassFormatException.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Thrown when the BCEL attempts to read a class file and determines diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ClassParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ClassParser.java index d8f32fc5a43..354891d0181 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ClassParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ClassParser.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Code.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Code.java index f7ace6f5480..5f02da73349 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Code.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Code.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/CodeException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/CodeException.java index 4cf1725a9d6..0fd1040bb10 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/CodeException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/CodeException.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Constant.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Constant.java index 931b8e27c79..18554f0f649 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Constant.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Constant.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantCP.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantCP.java index b12d752c2cb..7494c56336f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantCP.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantCP.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.Constants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantClass.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantClass.java index e047ca88db5..faabc476376 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantClass.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantClass.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantDouble.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantDouble.java index 74e7ef8129d..0471f684863 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantDouble.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantDouble.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantFieldref.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantFieldref.java index 5d76e11fdd9..b6cea00cbc3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantFieldref.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantFieldref.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantFloat.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantFloat.java index e18eb14f973..693ed70c13b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantFloat.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantFloat.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantInteger.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantInteger.java index a1e811e9b5e..5e8e098c0ef 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantInteger.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantInteger.java @@ -2,62 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantInterfaceMethodref.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantInterfaceMethodref.java index 46b742651b8..a242396d2a0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantInterfaceMethodref.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantInterfaceMethodref.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantLong.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantLong.java index e29a7c9c1a3..d1d1ab30a89 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantLong.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantLong.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantMethodref.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantMethodref.java index 044c99be955..f879d0ac875 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantMethodref.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantMethodref.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantNameAndType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantNameAndType.java index 19ad468d7f3..018adb8dfa5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantNameAndType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantNameAndType.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantObject.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantObject.java index 61440e54a5c..fbe7d4a6719 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantObject.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantObject.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * This interface denotes those constants that have a "natural" value, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantPool.java index 091e70cbfbf..8308d1adfdf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantPool.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantString.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantString.java index 40ea5299f43..30744dc695f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantString.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantString.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantUtf8.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantUtf8.java index 32e9555e1b1..59df746065f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantUtf8.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantUtf8.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantValue.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantValue.java index e16d47b2fbd..a3b754ec498 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantValue.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ConstantValue.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Deprecated.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Deprecated.java index 096f77f3b7a..a48fd812345 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Deprecated.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Deprecated.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/DescendingVisitor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/DescendingVisitor.java index 763eca6e1e5..a21586c8c9e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/DescendingVisitor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/DescendingVisitor.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.util.Stack; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/EmptyVisitor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/EmptyVisitor.java index 32a1cc144cf..11b5b22a30b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/EmptyVisitor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/EmptyVisitor.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; import com.sun.org.apache.bcel.internal.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ExceptionTable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ExceptionTable.java index 0a9e1dcf155..6780e9f534b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ExceptionTable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/ExceptionTable.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Field.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Field.java index 6bc42ee48be..a9089fcb1bb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Field.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Field.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.generic.Type; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/FieldOrMethod.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/FieldOrMethod.java index 86b7da20be7..78fa6e837ed 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/FieldOrMethod.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/FieldOrMethod.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/InnerClass.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/InnerClass.java index 8693fa6a1f0..32372eb7458 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/InnerClass.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/InnerClass.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/InnerClasses.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/InnerClasses.java index da320361327..ee12da6f781 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/InnerClasses.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/InnerClasses.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/JavaClass.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/JavaClass.java index db83c73b299..2ccb0646231 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/JavaClass.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/JavaClass.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.util.SyntheticRepository; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LineNumber.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LineNumber.java index ec8b4728036..55caded5352 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LineNumber.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LineNumber.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LineNumberTable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LineNumberTable.java index 1fa9bfeaf3e..a05331b4c01 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LineNumberTable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LineNumberTable.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LocalVariable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LocalVariable.java index a80bc3bb6c4..f33140ff3ef 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LocalVariable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LocalVariable.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LocalVariableTable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LocalVariableTable.java index db0631f5b89..88e51f662e3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LocalVariableTable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/LocalVariableTable.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Method.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Method.java index 63d7689e5f0..dadd64c2a12 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Method.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Method.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.generic.Type; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Node.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Node.java index 8d239c4949a..61e1ab7e1a1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Node.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Node.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denote class to have an accept method(); diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/PMGClass.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/PMGClass.java index 999d876bb3b..ebe72756070 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/PMGClass.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/PMGClass.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Signature.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Signature.java index e0b9cc50c50..60bb1ca779e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Signature.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Signature.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/SourceFile.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/SourceFile.java index 5120cd6b2bc..4942152a5e6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/SourceFile.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/SourceFile.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMap.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMap.java index 4d44a6f3107..01106aa207d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMap.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMap.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMapEntry.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMapEntry.java index 5b5c46fffb7..8d09356d8cb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMapEntry.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMapEntry.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMapType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMapType.java index 357d53d825d..f57fba91d12 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMapType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/StackMapType.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Synthetic.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Synthetic.java index 4b743a66c87..737067f94cc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Synthetic.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Synthetic.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Unknown.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Unknown.java index 16fc4760fd4..d5b13965842 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Unknown.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Unknown.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Utility.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Utility.java index 9e4cddc3f37..2641b1f62ef 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Utility.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Utility.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Visitor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Visitor.java index a076768700c..2e7b855f72c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Visitor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/classfile/Visitor.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.classfile; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Interface to make use of the Visitor pattern programming style. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AALOAD.java index 914d5b3e699..fe68c2fecfb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * AALOAD - Load reference from array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AASTORE.java index e8a2ddd0c2a..e68c8b853fc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * AASTORE - Store into reference array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ACONST_NULL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ACONST_NULL.java index 7d1003519ee..777580befe6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ACONST_NULL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ACONST_NULL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ACONST_NULL - Push null reference diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ALOAD.java index 2d0a1137740..2b9d3d2ee3c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ALOAD - Load reference from local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ANEWARRAY.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ANEWARRAY.java index 4ab55505ee5..71571a1bb19 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ANEWARRAY.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ANEWARRAY.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.ExceptionConstants; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ARETURN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ARETURN.java index b0c738972ab..ec37dae4d3d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ARETURN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ARETURN.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ARETURN - Return reference from method diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ARRAYLENGTH.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ARRAYLENGTH.java index 33f10e65cbf..fdd575e2ea3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ARRAYLENGTH.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ARRAYLENGTH.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ARRAYLENGTH - Get length of array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ASTORE.java index 4b15efe1d84..d2cc7f5e18d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ASTORE - Store reference into local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ATHROW.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ATHROW.java index f0afea7d316..226bf2c6ec9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ATHROW.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ATHROW.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ATHROW - Throw exception diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AllocationInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AllocationInstruction.java index 10064407592..4944d892cdb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AllocationInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/AllocationInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denote family of instructions that allocates space in the heap. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArithmeticInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArithmeticInstruction.java index 5b35a8c2607..becf27342d0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArithmeticInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArithmeticInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; /** * Super class for the family of arithmetic instructions. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArrayInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArrayInstruction.java index 5b902c3c899..62e90a44b01 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArrayInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArrayInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Super class for instructions dealing with array access such as IALOAD. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArrayType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArrayType.java index 54bd83a0a0b..035602d8351 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArrayType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ArrayType.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BALOAD.java index 9ed9afa204e..b198401b455 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * BALOAD - Load byte or boolean from array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BASTORE.java index 300719e1693..67a5fab11a3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * BASTORE - Store into byte or boolean array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BIPUSH.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BIPUSH.java index 0ed9962e756..b1859d5ae0f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BIPUSH.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BIPUSH.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BREAKPOINT.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BREAKPOINT.java index 0490be623f7..9715ea5324e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BREAKPOINT.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BREAKPOINT.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * BREAKPOINT, JVM dependent, ignored by default diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BasicType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BasicType.java index c7340a62b15..00a5def2646 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BasicType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BasicType.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BranchHandle.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BranchHandle.java index 1f7cbb0d1c7..3ab01f5d821 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BranchHandle.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BranchHandle.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * BranchHandle is returned by specialized InstructionList.append() whenever a diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BranchInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BranchInstruction.java index 36960f8438f..77f5a86af57 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BranchInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/BranchInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CALOAD.java index f738f000fb7..e0cd6aac454 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * CALOAD - Load char from array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CASTORE.java index 94187cceab3..2bb7678b3bb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * CASTORE - Store into char array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CHECKCAST.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CHECKCAST.java index 20302f907cc..02ebaf3a20f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CHECKCAST.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CHECKCAST.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.ExceptionConstants; /** * CHECKCAST - Check whether object is of given type diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CPInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CPInstruction.java index 5f9650bcdaf..84ac4ef0de1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CPInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CPInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassGen.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassGen.java index 005a50b2834..2e1b4d37e73 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassGen.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassGen.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassGenException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassGenException.java index bc4bb71e189..6bc4ee6c534 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassGenException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassGenException.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Thrown on internal errors. Extends RuntimeException so it hasn't to be declared diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassObserver.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassObserver.java index 3ef714df85a..a01e5b6288c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassObserver.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ClassObserver.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Implement this interface if you're interested in changes to a ClassGen object diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CodeExceptionGen.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CodeExceptionGen.java index 0fb252ba576..96bd2124f37 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CodeExceptionGen.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CodeExceptionGen.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CompoundInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CompoundInstruction.java index b543a2e3b89..b54af3aacf4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CompoundInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/CompoundInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Wrapper class for `compound' operations, virtual instructions that diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConstantPoolGen.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConstantPoolGen.java index 1b53aeb5b65..4eb12e2e693 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConstantPoolGen.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConstantPoolGen.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConstantPushInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConstantPushInstruction.java index e7ad698ecef..f5fdaa11541 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConstantPushInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConstantPushInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denotes a push instruction that produces a literal on the stack diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConversionInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConversionInstruction.java index 8227ab01d74..2a1d8b6c2c3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConversionInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ConversionInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; /** * Super class for the x2y family of instructions. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2F.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2F.java index b19d59fb565..1d5cda8ae83 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2F.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2F.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * D2F - Convert double to float diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2I.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2I.java index 9aff1f148c6..cdc20b64f0e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2I.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2I.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * D2I - Convert double to int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2L.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2L.java index 9cb87a2af30..3774d4826fa 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2L.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/D2L.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * D2L - Convert double to long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DADD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DADD.java index 190790bbb12..af23bf2c94f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DADD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DADD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DADD - Add doubles diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DALOAD.java index ab3b36180ae..a414eb01432 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DALOAD - Load double from array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DASTORE.java index b615479a296..c100ead3e54 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DASTORE - Store into double array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCMPG.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCMPG.java index 3ea2fd89824..1d447c93062 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCMPG.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCMPG.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DCMPG - Compare doubles: value1 > value2 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCMPL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCMPL.java index 1b9c5bd2084..3874a682fe6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCMPL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCMPL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DCMPL - Compare doubles: value1 < value2 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCONST.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCONST.java index 8d43e0926ab..e3c69483137 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCONST.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DCONST.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DCONST - Push 0.0 or 1.0, other values cause an exception diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DDIV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DDIV.java index 103bcc3cf4d..1c91493800f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DDIV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DDIV.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DDIV - Divide doubles diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DLOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DLOAD.java index 0da6a5b372a..3e83f1edb30 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DLOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DLOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DLOAD - Load double from local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DMUL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DMUL.java index ff31fad323e..908dec0da4f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DMUL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DMUL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DMUL - Multiply doubles diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DNEG.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DNEG.java index 7bf5917345e..48becc3d66a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DNEG.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DNEG.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DNEG - Negate double diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DREM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DREM.java index 5ccd5634f44..d1f0bd09d03 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DREM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DREM.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DREM - Remainder of doubles diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DRETURN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DRETURN.java index 68329eb15e2..7c4906e8c5d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DRETURN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DRETURN.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DRETURN - Return double from method diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DSTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DSTORE.java index f9c41f8be17..ada5407136f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DSTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DSTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DSTORE - Store double into local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DSUB.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DSUB.java index e9042572f8f..8d6a311d6aa 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DSUB.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DSUB.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DSUB - Substract doubles diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP.java index 161dfe476c6..2d61cf06218 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DUP - Duplicate top operand stack word diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2.java index cbd1972381c..a44f07814e6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DUP2 - Duplicate two top operand stack words diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2_X1.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2_X1.java index 6362c07993a..b0b6d4c6fe2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2_X1.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2_X1.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DUP2_X1 - Duplicate two top operand stack words and put three down diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2_X2.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2_X2.java index d806b12b1f3..4e394bc4012 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2_X2.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP2_X2.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DUP2_X2 - Duplicate two top operand stack words and put four down diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP_X1.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP_X1.java index 7f5b9b70edb..ee895c6571c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP_X1.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP_X1.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DUP_X1 - Duplicate top operand stack word and put two down diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP_X2.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP_X2.java index 94c3608a24b..5d86a30169b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP_X2.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/DUP_X2.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * DUP_X2 - Duplicate top operand stack word and put three down diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/EmptyVisitor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/EmptyVisitor.java index fdc77b1191d..275af64d69f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/EmptyVisitor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/EmptyVisitor.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Supplies empty method bodies to be overridden by subclasses. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ExceptionThrower.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ExceptionThrower.java index 23b84907f81..d41af1032c8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ExceptionThrower.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ExceptionThrower.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denote an instruction that may throw a run-time or a linking diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2D.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2D.java index 49b1ae65d1d..417b429c682 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2D.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2D.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * F2D - Convert float to double diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2I.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2I.java index 471a9f43cb7..a8d75d1389f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2I.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2I.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * F2I - Convert float to int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2L.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2L.java index 67425079747..2f58b563fd5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2L.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/F2L.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * F2L - Convert float to long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FADD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FADD.java index 3daab6215bd..6460c871037 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FADD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FADD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FADD - Add floats diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FALOAD.java index f82001545f9..c3e67ab8f26 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FALOAD - Load float from array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FASTORE.java index 48336d10ffe..231eb319684 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FASTORE - Store into float array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCMPG.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCMPG.java index c1926e12102..761df11e7e9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCMPG.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCMPG.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FCMPG - Compare floats: value1 > value2 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCMPL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCMPL.java index 4ed62bf00a0..a6aa1780681 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCMPL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCMPL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FCMPL - Compare floats: value1 < value2 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCONST.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCONST.java index 12e8bcd9b0c..e54a8c0d576 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCONST.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FCONST.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FCONST - Push 0.0, 1.0 or 2.0, other values cause an exception diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FDIV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FDIV.java index 639ea5bbac1..8c7da046dfe 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FDIV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FDIV.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FDIV - Divide floats diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FLOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FLOAD.java index 6ffb86dcf52..afd730cf528 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FLOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FLOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FLOAD - Load float from local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FMUL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FMUL.java index f8fc49eb331..fbba7f71f34 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FMUL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FMUL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FMUL - Multiply floats diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FNEG.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FNEG.java index 6428fb61d94..33fe74faa22 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FNEG.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FNEG.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FNEG - Negate float diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FREM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FREM.java index 6ec99a03ed0..ad0f94de62d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FREM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FREM.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FREM - Remainder of floats diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FRETURN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FRETURN.java index 32e9a80ae04..d2198f82162 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FRETURN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FRETURN.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FRETURN - Return float from method diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FSTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FSTORE.java index bf80791f3cf..124e8b347f1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FSTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FSTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FSTORE - Store float into local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FSUB.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FSUB.java index da59fcf3552..213c802a23f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FSUB.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FSUB.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * FSUB - Substract floats diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldGen.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldGen.java index 290a3c03eee..eb139241b91 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldGen.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldGen.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldGenOrMethodGen.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldGenOrMethodGen.java index e75d8d8e4a2..677dba091df 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldGenOrMethodGen.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldGenOrMethodGen.java @@ -2,62 +2,26 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; import com.sun.org.apache.bcel.internal.Constants; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; import java.util.ArrayList; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldInstruction.java index 1c9f6e394fb..30224f1e20d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.ConstantPool; import com.sun.org.apache.bcel.internal.classfile.ConstantUtf8; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldObserver.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldObserver.java index e4d7ba50c4b..b2ee9d1a957 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldObserver.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldObserver.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Imnplement this interface if you're interested in changes to a FieldGen object diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldOrMethod.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldOrMethod.java index ac4e83b91a2..5d32603ac5c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldOrMethod.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/FieldOrMethod.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GETFIELD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GETFIELD.java index 139f139cbc3..2f2ae53ae31 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GETFIELD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GETFIELD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GETSTATIC.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GETSTATIC.java index 1968ce39ff0..d66b2ddef0c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GETSTATIC.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GETSTATIC.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GOTO.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GOTO.java index cfdb421a5b0..64707b27532 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GOTO.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GOTO.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GOTO_W.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GOTO_W.java index b4944820f9c..95e1727d205 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GOTO_W.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GOTO_W.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GotoInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GotoInstruction.java index 2beaea57404..aa5ac98971c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GotoInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/GotoInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Super class for GOTO diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2B.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2B.java index c933cf479a3..4bc35f44a9e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2B.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2B.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * I2B - Convert int to byte diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2C.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2C.java index 7da43e4292f..704001a96f7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2C.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2C.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * I2C - Convert int to char diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2D.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2D.java index a75907a812e..c35511dc17d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2D.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2D.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * I2D - Convert int to double diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2F.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2F.java index 7ec7befddb8..567e4b08cd3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2F.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2F.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * I2F - Convert int to float diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2L.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2L.java index 4663588b302..f087d4507e7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2L.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2L.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * I2L - Convert int to long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2S.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2S.java index 52a71a6828e..e917e3e6a70 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2S.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/I2S.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * I2S - Convert int to short diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IADD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IADD.java index ac804e5c808..71127939b4d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IADD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IADD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IADD - Add ints diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IALOAD.java index 0e999344d2c..e957e6c19b8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IALOAD - Load int from array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IAND.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IAND.java index 69826858e33..f62d301c2a5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IAND.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IAND.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IAND - Bitwise AND int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IASTORE.java index cf1277f73b4..a5f0aa2499d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IASTORE - Store into int array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ICONST.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ICONST.java index 52d1eeceff7..e7668d186f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ICONST.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ICONST.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ICONST - Push value between -1, ..., 5, other values cause an exception diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IDIV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IDIV.java index fba149b0e05..7043f0408a3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IDIV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IDIV.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IDIV - Divide ints diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFEQ.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFEQ.java index 73496cb48d5..87c2bb61e2a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFEQ.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFEQ.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IFEQ - Branch if int comparison with zero succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFGE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFGE.java index 73a14a4e2d6..90636622e7f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFGE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFGE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IFGE - Branch if int comparison with zero succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFGT.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFGT.java index 167826c3163..0195733021f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFGT.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFGT.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IFGT - Branch if int comparison with zero succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFLE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFLE.java index 84b7fa374e9..b5fd9fec1c8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFLE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFLE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IFLE - Branch if int comparison with zero succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFLT.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFLT.java index 5f904cd7ac1..124e874bbfb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFLT.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFLT.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IFLT - Branch if int comparison with zero succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNE.java index 0baf4a87cdf..1d99492a6d0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IFNE - Branch if int comparison with zero succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNONNULL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNONNULL.java index 9131bb25ec7..9b519f5e129 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNONNULL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNONNULL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IFNONNULL - Branch if reference is not null diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNULL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNULL.java index 1a5ccaf5ccf..45b15c22b4f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNULL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IFNULL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IFNULL - Branch if reference is not null diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ACMPEQ.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ACMPEQ.java index 7c0920f6e5d..c18b9c84329 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ACMPEQ.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ACMPEQ.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IF_ACMPEQ - Branch if reference comparison succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ACMPNE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ACMPNE.java index 2813007c97a..5a3df6d8a43 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ACMPNE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ACMPNE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IF_ACMPNE - Branch if reference comparison doesn't succeed diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPEQ.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPEQ.java index a14573653f9..f14a5b88217 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPEQ.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPEQ.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IF_ICMPEQ - Branch if int comparison succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPGE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPGE.java index c629f2c9e66..9b978416da1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPGE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPGE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IF_ICMPGE - Branch if int comparison succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPGT.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPGT.java index 013a72ef721..f0de3fc407d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPGT.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPGT.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IF_ICMPGT - Branch if int comparison succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPLE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPLE.java index 7ada1323c0a..3c13250cafb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPLE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPLE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IF_ICMPLE - Branch if int comparison succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPLT.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPLT.java index 833f06c9e30..849951cf548 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPLT.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPLT.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IF_ICMPLT - Branch if int comparison succeeds diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPNE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPNE.java index ae5ae87bc3a..f1de6f641a3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPNE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IF_ICMPNE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IF_ICMPNE - Branch if int comparison doesn't succeed diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IINC.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IINC.java index 92860079800..897d426a549 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IINC.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IINC.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ILOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ILOAD.java index 05989d93e1d..748da0b860f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ILOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ILOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ILOAD - Load int from local variable onto stack diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMPDEP1.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMPDEP1.java index 281f0878e85..20555243e3d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMPDEP1.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMPDEP1.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IMPDEP1 - Implementation dependent diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMPDEP2.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMPDEP2.java index ba5789be6d5..9caa3523bde 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMPDEP2.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMPDEP2.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IMPDEP2 - Implementation dependent diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMUL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMUL.java index 1df780f199b..8c8e150c725 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMUL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IMUL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IMUL - Multiply ints diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INEG.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INEG.java index fa8931d39b9..c874e95c440 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INEG.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INEG.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * INEG - Negate int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INSTANCEOF.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INSTANCEOF.java index ed1c491c95c..c67ffeb3fd9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INSTANCEOF.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INSTANCEOF.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * INSTANCEOF - Determine if object is of given type diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKEINTERFACE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKEINTERFACE.java index aed34bde497..bda3a357a46 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKEINTERFACE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKEINTERFACE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.ConstantPool; import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKESPECIAL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKESPECIAL.java index d40deed9225..566f58e2112 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKESPECIAL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKESPECIAL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKESTATIC.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKESTATIC.java index 2a32c69b1b7..2946d477a73 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKESTATIC.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKESTATIC.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKEVIRTUAL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKEVIRTUAL.java index a4ffe5b93ca..9e7d7e2622a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKEVIRTUAL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/INVOKEVIRTUAL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IOR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IOR.java index 8cf0f092a14..3b030d9f34d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IOR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IOR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IOR - Bitwise OR int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IREM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IREM.java index 650f7730e66..472ce73bde8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IREM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IREM.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IREM - Remainder of int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IRETURN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IRETURN.java index 9678b5bb41c..53d9384a1aa 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IRETURN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IRETURN.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IRETURN - Return int from method diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISHL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISHL.java index 5f26b9a0b3c..577e3b204a7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISHL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISHL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ISHL - Arithmetic shift left int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISHR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISHR.java index 6a3cb3e0625..e9b121f00c3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISHR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISHR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ISHR - Arithmetic shift right int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISTORE.java index 22cd14dbfba..fd270fd4d65 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ISTORE - Store int from stack into local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISUB.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISUB.java index 413e9d48915..824b0e3bc60 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISUB.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ISUB.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * ISUB - Substract ints diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IUSHR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IUSHR.java index 917ad39e89b..b9fe7308803 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IUSHR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IUSHR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IUSHR - Logical shift right int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IXOR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IXOR.java index d51ad6cbc77..27545563dc2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IXOR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IXOR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * IXOR - Bitwise XOR int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IfInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IfInstruction.java index e5fa48460bf..d677f220b66 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IfInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IfInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Super class for the IFxxx family of instructions. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IndexedInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IndexedInstruction.java index db8e05f4b1e..5c6fb7bc618 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IndexedInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/IndexedInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denote entity that refers to an index, e.g. local variable instructions, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Instruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Instruction.java index ed58b5dec60..889d6f8ca79 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Instruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Instruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.Utility; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionComparator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionComparator.java index 5a42652a52b..03589cb2dbc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionComparator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionComparator.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Equality of instructions isn't clearly to be defined. You might diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionConstants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionConstants.java index 1ff55ddfdf4..4b624d7cf0a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionConstants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionConstants.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionFactory.java index f7378aaaf4d..bc4420961ed 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionFactory.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionHandle.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionHandle.java index 6594e01be08..c490f3550f3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionHandle.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionHandle.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.Utility; import java.util.HashSet; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionList.java index 235950f7d7d..c5bf9b46555 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionList.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.Constant; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionListObserver.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionListObserver.java index 91ad321a5e0..e9721ed6c42 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionListObserver.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionListObserver.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Implement this interface if you're interested in changes to an InstructionList object diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionTargeter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionTargeter.java index 3eaeb3a2f96..1d8d25a6a68 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionTargeter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InstructionTargeter.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denote that a class targets InstructionHandles within an InstructionList. Namely diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InvokeInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InvokeInstruction.java index cae2bd59c36..592d11d6ecc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InvokeInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/InvokeInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.*; import java.util.StringTokenizer; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JSR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JSR.java index d5b563bce10..babfc422dba 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JSR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JSR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JSR_W.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JSR_W.java index 32ceb29b2cc..2776c513e5f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JSR_W.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JSR_W.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JsrInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JsrInstruction.java index f71e1650faf..a67702e7aa0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JsrInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/JsrInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Super class for JSR - Jump to subroutine diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2D.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2D.java index 8d14914bd01..fb0926faa9f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2D.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2D.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * L2D - Convert long to double diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2F.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2F.java index 36571d6db54..afc5b0016b5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2F.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2F.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * L2F - Convert long to float diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2I.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2I.java index cacf3adec9b..be9615f20dd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2I.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/L2I.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * L2I - Convert long to int diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LADD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LADD.java index 6ab1f426cca..999c39c77f8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LADD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LADD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LADD - Add longs diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LALOAD.java index e7185ac5ce1..7068be8f28e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LALOAD - Load long from array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LAND.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LAND.java index c225cac93be..a5fa96c1b17 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LAND.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LAND.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LAND - Bitwise AND longs diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LASTORE.java index c0e928a7405..04d25d20181 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LASTORE - Store into long array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LCMP.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LCMP.java index 05c1aee26e2..cb2fb4f8404 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LCMP.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LCMP.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LCMP - Compare longs: diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LCONST.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LCONST.java index 7fe94a23fb1..a209eadb939 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LCONST.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LCONST.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LCONST - Push 0 or 1, other values cause an exception diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC.java index 001d80e804b..7dc55289e7b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC2_W.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC2_W.java index 4a97a2054a4..f06c2cf46b7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC2_W.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC2_W.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LDC2_W - Push long or double from constant pool diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC_W.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC_W.java index 640554e4831..be3f5693f0e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC_W.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDC_W.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.IOException; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDIV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDIV.java index 754696eb05a..55f82cab10e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDIV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LDIV.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LDIV - Divide longs diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LLOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LLOAD.java index 1276d37149c..b36e57549e2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LLOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LLOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LLOAD - Load long from local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LMUL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LMUL.java index 16cb083a1d6..aa746fb623a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LMUL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LMUL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LMUL - Multiply longs diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LNEG.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LNEG.java index 61df1bb81ab..b08f303bf55 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LNEG.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LNEG.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LNEG - Negate long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LOOKUPSWITCH.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LOOKUPSWITCH.java index 19188849fd7..1b026df5289 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LOOKUPSWITCH.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LOOKUPSWITCH.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LOR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LOR.java index baf79332314..19a25deaf8c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LOR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LOR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LOR - Bitwise OR long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LREM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LREM.java index 293684a4778..7f2892d25e7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LREM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LREM.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LREM - Remainder of long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LRETURN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LRETURN.java index 480ba01f9ce..b09344aee5d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LRETURN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LRETURN.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LRETURN - Return long from method diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSHL.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSHL.java index 780ef7a2556..ae677302842 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSHL.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSHL.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LSHL - Arithmetic shift left long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSHR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSHR.java index b4993b57e9c..f6a520b2831 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSHR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSHR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LSHR - Arithmetic shift right long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSTORE.java index 41d348169b9..3b560d28b03 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LSTORE - Store long into local variable diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSUB.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSUB.java index 38ea67d1791..789c47fe143 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSUB.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LSUB.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LSUB - Substract longs diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LUSHR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LUSHR.java index 6d89c272147..19d83c8f7b7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LUSHR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LUSHR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LUSHR - Logical shift right long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LXOR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LXOR.java index 6ebd5da7bdf..56f680125f6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LXOR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LXOR.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * LXOR - Bitwise XOR long diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LineNumberGen.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LineNumberGen.java index a8427a8c812..ebda36320c0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LineNumberGen.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LineNumberGen.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LoadClass.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LoadClass.java index e40190429c8..0cf2b23509c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LoadClass.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LoadClass.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denotes that an instruction may start the process of loading and resolving diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LoadInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LoadInstruction.java index a35e020c2de..6d663263e58 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LoadInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LoadInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denotes an unparameterized instruction to load a value from a local diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LocalVariableGen.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LocalVariableGen.java index 1f2fd868e40..92ae424b8cc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LocalVariableGen.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LocalVariableGen.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LocalVariableInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LocalVariableInstruction.java index f10b91d10e7..26e14a3787f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LocalVariableInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/LocalVariableInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; import com.sun.org.apache.bcel.internal.classfile.Utility; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MONITORENTER.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MONITORENTER.java index e50dde4bf65..5fd6d61692c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MONITORENTER.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MONITORENTER.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * MONITORENTER - Enter monitor for object diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MONITOREXIT.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MONITOREXIT.java index c088aa89176..d6a87fd64b5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MONITOREXIT.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MONITOREXIT.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * MONITOREXIT - Exit monitor for object diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MULTIANEWARRAY.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MULTIANEWARRAY.java index 6a490116578..54c9d8b11df 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MULTIANEWARRAY.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MULTIANEWARRAY.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; import com.sun.org.apache.bcel.internal.classfile.ConstantPool; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MethodGen.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MethodGen.java index 69345824091..61a3daf61ea 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MethodGen.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MethodGen.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MethodObserver.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MethodObserver.java index 1135984dc40..c50acc69558 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MethodObserver.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/MethodObserver.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Implement this interface if you're interested in changes to a MethodGen object diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NEW.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NEW.java index de0e2f831c0..9fd3014caa1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NEW.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NEW.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NEWARRAY.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NEWARRAY.java index b6d716e3d06..dbf157d847a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NEWARRAY.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NEWARRAY.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NOP.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NOP.java index 1e6ee0aeaf6..8dec0dafbff 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NOP.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NOP.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * NOP - Do nothing diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NamedAndTyped.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NamedAndTyped.java index a1501f45c68..006d6dffd70 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NamedAndTyped.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/NamedAndTyped.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denote entity that has both name and type. This is true for local variables, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ObjectType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ObjectType.java index a506edd9540..d3af662a1fc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ObjectType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ObjectType.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.Repository; import com.sun.org.apache.bcel.internal.classfile.JavaClass; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/POP.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/POP.java index 300a6be5452..76c460a21d5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/POP.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/POP.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * POP - Pop top operand stack word diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/POP2.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/POP2.java index aebcadab39e..f63925841f6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/POP2.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/POP2.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * POP2 - Pop two top operand stack words diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUSH.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUSH.java index 31a7884fbfe..da73c7fd6af 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUSH.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUSH.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUTFIELD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUTFIELD.java index 95725545774..9f7b42f108c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUTFIELD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUTFIELD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUTSTATIC.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUTSTATIC.java index a4116b66558..ffb7a626bc2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUTSTATIC.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PUTSTATIC.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PopInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PopInstruction.java index 4168d2f9d13..f195a83477d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PopInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PopInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denotes an unparameterized instruction to pop a value on top from the stack, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PushInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PushInstruction.java index f143c978a46..bb702276412 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PushInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/PushInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denotes an unparameterized instruction to produce a value on top of the stack, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/RET.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/RET.java index 27e242a433f..093a870d27f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/RET.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/RET.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/RETURN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/RETURN.java index f937e50fc16..c9b6621152d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/RETURN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/RETURN.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * RETURN - Return from void method diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReferenceType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReferenceType.java index 0956b58008e..0513c1c76de 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReferenceType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReferenceType.java @@ -1,62 +1,25 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.Repository; @@ -298,6 +261,7 @@ public abstract class ReferenceType extends Type { * @deprecated use getFirstCommonSuperclass(ReferenceType t) which has * slightly changed semantics. */ + @Deprecated public ReferenceType firstCommonSuperclass(ReferenceType t) { if (this.equals(Type.NULL)) return t; if (t.equals(Type.NULL)) return this; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReturnInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReturnInstruction.java index 63181d01a4f..12906a06391 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReturnInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReturnInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.ExceptionConstants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReturnaddressType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReturnaddressType.java index 501efdd09ec..f62f6db9ccf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReturnaddressType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReturnaddressType.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import java.util.Objects; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SALOAD.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SALOAD.java index 06d03ac7cc2..126f599a38d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SALOAD.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SALOAD.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * SALOAD - Load short from array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SASTORE.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SASTORE.java index 9b20b93f34a..10e4f215abf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SASTORE.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SASTORE.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * SASTORE - Store into short array diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SIPUSH.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SIPUSH.java index e1717310b26..b0413b6fd3f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SIPUSH.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SIPUSH.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SWAP.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SWAP.java index 625cbdb5435..a85e91da980 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SWAP.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SWAP.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * SWAP - Swa top operand stack word diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SWITCH.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SWITCH.java index df1fd81eac3..fb4dce327ea 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SWITCH.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/SWITCH.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * SWITCH - Branch depending on int value, generates either LOOKUPSWITCH or diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Select.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Select.java index 0cf47f634ca..94d20cba11a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Select.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Select.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackConsumer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackConsumer.java index efea4a6858c..1dd12439cfb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackConsumer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackConsumer.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denote an instruction that may consume a value from the stack. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackInstruction.java index b6a0c39b936..82fdd2c89e3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Super class for stack operations like DUP and POP. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackProducer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackProducer.java index dc1231c3680..9aa3795c040 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackProducer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StackProducer.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denote an instruction that may produce a value on top of the stack diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StoreInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StoreInstruction.java index ed3197a48b9..3f27a250cc5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StoreInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/StoreInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denotes an unparameterized instruction to store a value into a local variable, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TABLESWITCH.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TABLESWITCH.java index 5fb9075b5fd..13d91c825c5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TABLESWITCH.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TABLESWITCH.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import com.sun.org.apache.bcel.internal.util.ByteSequence; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TargetLostException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TargetLostException.java index fcac0fe3753..2acd713f3a1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TargetLostException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TargetLostException.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Thrown by InstructionList.remove() when one or multiple disposed instruction diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Type.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Type.java index b496ed85edc..e936ca9b891 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Type.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Type.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.Constants; import com.sun.org.apache.bcel.internal.classfile.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TypedInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TypedInstruction.java index 09ddae4b979..6332a4e5747 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TypedInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/TypedInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Get the type associated with an instruction, int for ILOAD, or the type diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/UnconditionalBranch.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/UnconditionalBranch.java index c310a46e171..5c96001f0c2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/UnconditionalBranch.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/UnconditionalBranch.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denotes an instruction to perform an unconditional branch, i.e., GOTO, JSR. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/VariableLengthInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/VariableLengthInstruction.java index 9026a16b2fe..6395b8d9ec0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/VariableLengthInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/VariableLengthInstruction.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Denotes an instruction to be a variable length instruction, such as diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Visitor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Visitor.java index 97c4469d657..0a1eb5ee1d5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Visitor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/Visitor.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.generic; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Interface implementing the Visitor pattern programming style. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/AttributeHTML.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/AttributeHTML.java index 3cafcba3780..15417bdd19a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/AttributeHTML.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/AttributeHTML.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/BCELFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/BCELFactory.java index a3b2543707b..084fc7bbd7f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/BCELFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/BCELFactory.java @@ -2,6 +2,23 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; import com.sun.org.apache.bcel.internal.generic.*; @@ -10,59 +27,6 @@ import com.sun.org.apache.bcel.internal.Constants; import java.io.PrintWriter; import java.util.*; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ /** * Factory creates il.append() statements, and sets instruction targets. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/BCELifier.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/BCELifier.java index 87a82447a67..de157f0d345 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/BCELifier.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/BCELifier.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; import com.sun.org.apache.bcel.internal.generic.*; import com.sun.org.apache.bcel.internal.Repository; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ByteSequence.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ByteSequence.java index e0dacd7c59b..f1ea3f9c108 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ByteSequence.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ByteSequence.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/Class2HTML.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/Class2HTML.java index 52b9df945c7..1ecbb71d632 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/Class2HTML.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/Class2HTML.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; import java.util.BitSet; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassLoader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassLoader.java index 1be5b3b2a51..12708ad89f3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassLoader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassLoader.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.util.Hashtable; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassLoaderRepository.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassLoaderRepository.java index eec10f4e3a3..80e844216d6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassLoaderRepository.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassLoaderRepository.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassQueue.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassQueue.java index 2817094ff19..a4dda645d10 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassQueue.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassQueue.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.util.LinkedList; import com.sun.org.apache.bcel.internal.classfile.JavaClass; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassSet.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassSet.java index e7ea2e437d0..27dd9b7ce82 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassSet.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassSet.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.util.HashMap; import java.util.Collection; import com.sun.org.apache.bcel.internal.classfile.JavaClass; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassStack.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassStack.java index 87029e2f6fe..52275dda1f1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassStack.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassStack.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.util.Stack; import com.sun.org.apache.bcel.internal.classfile.JavaClass; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassVector.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassVector.java index 28c4789dbe6..f95ef244dce 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassVector.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ClassVector.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.util.ArrayList; import com.sun.org.apache.bcel.internal.classfile.JavaClass; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/CodeHTML.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/CodeHTML.java index cae2ea62312..eb9d4bf65ec 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/CodeHTML.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/CodeHTML.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ConstantHTML.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ConstantHTML.java index 52f359188d8..ac1d8501783 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ConstantHTML.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/ConstantHTML.java @@ -2,62 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/MethodHTML.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/MethodHTML.java index d6d5429471f..b2c6725c1e1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/MethodHTML.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/MethodHTML.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.*; import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/Repository.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/Repository.java index d588ba9e37d..f38198a236b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/Repository.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/Repository.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import com.sun.org.apache.bcel.internal.classfile.JavaClass; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/SecuritySupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/SecuritySupport.java index 059a5cd1915..c33995983f7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/SecuritySupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/SecuritySupport.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/SyntheticRepository.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/SyntheticRepository.java index f1cb8913b01..42fa078a37c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/SyntheticRepository.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/util/SyntheticRepository.java @@ -2,61 +2,25 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.sun.org.apache.bcel.internal.util; -/* ==================================================================== - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2001 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Apache" and "Apache Software Foundation" and - * "Apache BCEL" must not be used to endorse or promote products - * derived from this software without prior written permission. For - * written permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * "Apache BCEL", nor may "Apache" appear in their name, without - * prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * . - */ import java.io.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/extensions/ExpressionContext.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/extensions/ExpressionContext.java index 703e2af54e7..b6f5a7ff50a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/extensions/ExpressionContext.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/extensions/ExpressionContext.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExpressionContext.java,v 1.2.4.1 2005/09/10 19:34:03 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.extensions; import javax.xml.transform.ErrorListener; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltBase.java index 31f80b86c97..0b99ee44713 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltBase.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExsltBase.java,v 1.1.2.1 2005/08/01 02:08:51 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.lib; import com.sun.org.apache.xml.internal.dtm.ref.DTMNodeProxy; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltCommon.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltCommon.java index b4493c06d0e..e272192ec7b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltCommon.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltCommon.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExsltCommon.java,v 1.2.4.1 2005/09/15 02:45:24 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.lib; import com.sun.org.apache.xalan.internal.extensions.ExpressionContext; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltDatetime.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltDatetime.java index d717d8d1fa2..479f152813c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltDatetime.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltDatetime.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExsltDatetime.java,v 1.2.4.1 2005/09/10 18:50:49 jeffsuttor Exp $ - */ package com.sun.org.apache.xalan.internal.lib; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltDynamic.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltDynamic.java index 7f55d89180d..9446b332867 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltDynamic.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltDynamic.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExsltDynamic.java,v 1.1.2.1 2005/08/01 02:08:51 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.lib; import javax.xml.parsers.DocumentBuilder; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltMath.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltMath.java index 6066832a2a6..25cf7249184 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltMath.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltMath.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExsltMath.java,v 1.1.2.1 2005/08/01 02:08:50 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.lib; import com.sun.org.apache.xpath.internal.NodeSet; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltSets.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltSets.java index 46d5df19c7e..3b90b0e14a1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltSets.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltSets.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,7 +22,7 @@ */ package com.sun.org.apache.xalan.internal.lib; -import com.sun.org.apache.xml.internal.utils.DOMHelper; +import com.sun.org.apache.xml.internal.utils.DOM2Helper; import com.sun.org.apache.xpath.internal.NodeSet; import java.util.HashMap; import java.util.Map; @@ -72,8 +72,8 @@ public class ExsltSets extends ExsltBase for (int i = 0; i < nl1.getLength(); i++) { Node testNode = nl1.item(i); - if (DOMHelper.isNodeAfter(testNode, endNode) - && !DOMHelper.isNodeTheSame(testNode, endNode)) + if (DOM2Helper.isNodeAfter(testNode, endNode) + && !DOM2Helper.isNodeTheSame(testNode, endNode)) leadNodes.addElement(testNode); } return leadNodes; @@ -107,8 +107,8 @@ public class ExsltSets extends ExsltBase for (int i = 0; i < nl1.getLength(); i++) { Node testNode = nl1.item(i); - if (DOMHelper.isNodeAfter(startNode, testNode) - && !DOMHelper.isNodeTheSame(startNode, testNode)) + if (DOM2Helper.isNodeAfter(startNode, testNode) + && !DOM2Helper.isNodeTheSame(startNode, testNode)) trailNodes.addElement(testNode); } return trailNodes; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltStrings.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltStrings.java index aa8bea5b0ce..31fb531a90d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltStrings.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltStrings.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExsltStrings.java,v 1.1.2.1 2005/08/01 02:08:48 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.lib; import java.util.StringTokenizer; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/Extensions.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/Extensions.java index 17ff0567cd6..02ed1c06ebb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/Extensions.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/Extensions.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Extensions.java,v 1.2.4.1 2005/09/10 18:53:32 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.lib; import java.util.StringTokenizer; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/NodeInfo.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/NodeInfo.java index 05caa00aba2..ed7b9ca1e67 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/NodeInfo.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/NodeInfo.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeInfo.java,v 1.2.4.1 2005/09/10 18:54:37 jeffsuttor Exp $ - */ package com.sun.org.apache.xalan.internal.lib; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLMessages.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLMessages.java index 00d11e97f51..63df7798fbe 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLMessages.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLMessages.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XSLMessages.java,v 1.2.4.1 2005/09/09 07:41:10 pvedula Exp $ - */ + package com.sun.org.apache.xalan.internal.res; import com.sun.org.apache.xalan.internal.utils.SecuritySupport; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources.java index 5ef374f3fae..f4a1b385d17 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1424,24 +1422,4 @@ public class XSLTErrorResources extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - } diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_de.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_de.java index d1a408f6762..3d190be4482 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_de.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_de.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1424,24 +1422,4 @@ public class XSLTErrorResources_de extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_en.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_en.java index fb5348b52e5..0748aa37948 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_en.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_en.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XSLTErrorResources_en.java,v 1.2.4.1 2005/09/13 10:18:30 pvedula Exp $ - */ + package com.sun.org.apache.xalan.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_es.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_es.java index ef0b0f6af22..417aa6848a1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_es.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_es.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1423,25 +1421,4 @@ public class XSLTErrorResources_es extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - } diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_fr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_fr.java index 2ffbbba856b..03e48840275 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_fr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_fr.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1423,25 +1421,4 @@ public class XSLTErrorResources_fr extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_it.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_it.java index aae3c36dfc8..30da18c0475 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_it.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_it.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1013,7 +1011,7 @@ public class XSLTErrorResources_it extends ListResourceBundle "Propriet\u00E0 di sistema org.xml.sax.parser non specificata"}, { ER_PARSER_ARG_CANNOT_BE_NULL, - "L''argomento del parser non deve essere nullo"}, + "L'argomento del parser non deve essere nullo"}, { ER_FEATURE, "Funzione: {0}"}, @@ -1423,25 +1421,4 @@ public class XSLTErrorResources_it extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ja.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ja.java index 7460d3efef8..a336e5d4b84 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ja.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ja.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1423,25 +1421,4 @@ public class XSLTErrorResources_ja extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ko.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ko.java index fe292ee08d6..641a651cdaf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ko.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ko.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1423,25 +1421,4 @@ public class XSLTErrorResources_ko extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_pt_BR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_pt_BR.java index 7eedeb87ff9..2b30eec8756 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_pt_BR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_pt_BR.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1423,25 +1421,4 @@ public class XSLTErrorResources_pt_BR extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_sv.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_sv.java index 183697b5025..789dfd665d0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_sv.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_sv.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1424,24 +1422,4 @@ public class XSLTErrorResources_sv extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_CN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_CN.java index bd8f9a5dd67..2f13d84c5f3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_CN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_CN.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1423,25 +1421,4 @@ public class XSLTErrorResources_zh_CN extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_TW.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_TW.java index ee8a11b35f6..edab6cfc8eb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_TW.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_TW.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,12 +17,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1022,7 +1020,7 @@ public class XSLTErrorResources_zh_TW extends ListResourceBundle "\u5C6C\u6027: {0}"}, { ER_NULL_ENTITY_RESOLVER, - "\u7A7A\u503C\u500B\u9AD4\u89E3\u6790\u5668"}, + "\u7A7A\u503C\u5BE6\u9AD4\u89E3\u6790\u5668"}, { ER_NULL_DTD_HANDLER, "\u7A7A\u503C DTD \u8655\u7406\u7A0B\u5F0F"}, @@ -1356,8 +1354,8 @@ public class XSLTErrorResources_zh_TW extends ListResourceBundle { "optionLXCIN", " [-LXCIN compiledStylesheetFileNameIn]"}, { "optionLXCOUT", " [-LXCOUT compiledStylesheetFileNameOutOut]"}, { "optionPARSER", " [-PARSER \u5256\u6790\u5668\u806F\u7D61\u7684\u5B8C\u6574\u985E\u5225\u540D\u7A31]"}, - { "optionE", " [-E (\u52FF\u5C55\u958B\u500B\u9AD4\u53C3\u7167)]"}, - { "optionV", " [-E (\u52FF\u5C55\u958B\u500B\u9AD4\u53C3\u7167)]"}, + { "optionE", " [-E (\u52FF\u5C55\u958B\u5BE6\u9AD4\u53C3\u7167)]"}, + { "optionV", " [-E (\u52FF\u5C55\u958B\u5BE6\u9AD4\u53C3\u7167)]"}, { "optionQC", " [-QC (\u975C\u97F3\u6A23\u5F0F\u885D\u7A81\u8B66\u544A)]"}, { "optionQ", " [-Q (\u975C\u97F3\u6A21\u5F0F)]"}, { "optionLF", " [-LF (\u8F38\u51FA\u4E0A\u50C5\u4F7F\u7528\u63DB\u884C\u5B57\u5143 {\u9810\u8A2D\u70BA CR/LF})]"}, @@ -1381,7 +1379,7 @@ public class XSLTErrorResources_zh_TW extends ListResourceBundle { "noParsermsg4", "\u82E5\u7121 IBM \u7684 XML Parser for Java\uFF0C\u53EF\u4E0B\u8F09\u81EA"}, { "noParsermsg5", "IBM \u7684 AlphaWorks: http://www.alphaworks.ibm.com/formula/xml"}, { "optionURIRESOLVER", " [-URIRESOLVER \u5B8C\u6574\u985E\u5225\u540D\u7A31 (\u7528\u4F86\u89E3\u6790 URI \u7684 URIResolver)]"}, - { "optionENTITYRESOLVER", " [-ENTITYRESOLVER \u5B8C\u6574\u985E\u5225\u540D\u7A31 (\u7528\u4F86\u89E3\u6790\u500B\u9AD4\u7684 EntityResolver )]"}, + { "optionENTITYRESOLVER", " [-ENTITYRESOLVER \u5B8C\u6574\u985E\u5225\u540D\u7A31 (\u7528\u4F86\u89E3\u6790\u5BE6\u9AD4\u7684 EntityResolver )]"}, { "optionCONTENTHANDLER", " [-CONTENTHANDLER \u5B8C\u6574\u985E\u5225\u540D\u7A31 (\u7528\u4F86\u5E8F\u5217\u5316\u8F38\u51FA\u7684 ContentHandler)]"}, { "optionLINENUMBERS", " [-L \u4F7F\u7528\u884C\u865F\u65BC\u4F86\u6E90\u6587\u4EF6]"}, { "optionSECUREPROCESSING", " [-SECURE (\u5C07\u5B89\u5168\u8655\u7406\u529F\u80FD\u8A2D\u70BA\u771F\u3002)]"}, @@ -1423,25 +1421,4 @@ public class XSLTErrorResources_zh_TW extends ListResourceBundle /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/templates/Constants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/templates/Constants.java index e4c75393649..6fe0f26014f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/templates/Constants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/templates/Constants.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Constants.java,v 1.2.4.1 2005/09/10 19:50:56 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.templates; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/ConfigurationError.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/ConfigurationError.java index 5832f82868b..26438e437c8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/ConfigurationError.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/ConfigurationError.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ObjectFactory.java,v 1.2.4.1 2005/09/15 02:39:54 jeffsuttor Exp $ - */ package com.sun.org.apache.xalan.internal.utils; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/ObjectFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/ObjectFactory.java index 0908e205173..e858ac47b63 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/ObjectFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/ObjectFactory.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ObjectFactory.java,v 1.2.4.1 2005/09/15 02:39:54 jeffsuttor Exp $ - */ package com.sun.org.apache.xalan.internal.utils; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/SecuritySupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/SecuritySupport.java index 0f486f482dc..d1ad28ac9c1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/SecuritySupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/utils/SecuritySupport.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SecuritySupport.java,v 1.1.2.1 2005/08/01 02:08:48 jeffsuttor Exp $ - */ package com.sun.org.apache.xalan.internal.utils; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/CollatorFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/CollatorFactory.java index a45c3538eb2..318485d427e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/CollatorFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/CollatorFactory.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CollatorFactory.java,v 1.2.4.1 2005/08/31 10:16:33 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/DOMCache.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/DOMCache.java index 1a8efb1be18..6d37efb0348 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/DOMCache.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/DOMCache.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOMCache.java,v 1.2.4.1 2005/08/31 10:23:55 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/DOMEnhancedForDTM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/DOMEnhancedForDTM.java index f7e1b30e84f..0194201bb42 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/DOMEnhancedForDTM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/DOMEnhancedForDTM.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOMEnhancedForDTM.java,v 1.2.4.1 2005/08/31 10:25:13 pvedula Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/NodeIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/NodeIterator.java index 65039f475db..a8eba9135b0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/NodeIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/NodeIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeIterator.java,v 1.2.4.1 2005/08/31 10:26:27 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/ProcessorVersion.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/ProcessorVersion.java index f3d8e4d507f..dcfab47dc8e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/ProcessorVersion.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/ProcessorVersion.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ProcessorVersion.java,v 1.2.4.1 2005/08/31 10:30:36 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/StripFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/StripFilter.java index ed5b878eae0..53393019c5e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/StripFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/StripFilter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StripFilter.java,v 1.2.4.1 2005/08/31 10:43:36 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/Translet.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/Translet.java index ca6ff50ef0f..5eb07d04e24 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/Translet.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/Translet.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Translet.java,v 1.2.4.1 2005/08/31 10:46:27 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/TransletException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/TransletException.java index 19e12fe024d..d330f6b1c1b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/TransletException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/TransletException.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: TransletException.java,v 1.2.4.1 2005/08/31 10:47:50 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AbsoluteLocationPath.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AbsoluteLocationPath.java index 8bfe6cb9907..ca9ca3e397a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AbsoluteLocationPath.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AbsoluteLocationPath.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AbsoluteLocationPath.java,v 1.2.4.1 2005/09/12 09:44:03 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AbsolutePathPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AbsolutePathPattern.java index c25bae43675..9de660708f1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AbsolutePathPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AbsolutePathPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AbsolutePathPattern.java,v 1.2.4.1 2005/09/01 09:17:09 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AlternativePattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AlternativePattern.java index 7adcb483fcb..9a727f9607b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AlternativePattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AlternativePattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AlternativePattern.java,v 1.2.4.1 2005/09/01 09:18:46 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AncestorPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AncestorPattern.java index 10bfa7d5b9a..bda61123c45 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AncestorPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AncestorPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AncestorPattern.java,v 1.2.4.1 2005/09/01 09:19:41 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ApplyImports.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ApplyImports.java index ceba568e279..ac19717af58 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ApplyImports.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ApplyImports.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ApplyImports.java,v 1.2.4.1 2005/09/13 12:22:02 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ArgumentList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ArgumentList.java index 6c1757c11b4..ce654252e81 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ArgumentList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ArgumentList.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ArgumentList.java,v 1.2.4.1 2005/09/01 10:18:19 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Attribute.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Attribute.java index 25f6b56a97f..a659d2e5ed8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Attribute.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Attribute.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Attribute.java,v 1.2.4.1 2005/09/01 10:20:59 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AttributeValue.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AttributeValue.java index bd1a3179a94..3130ee9cb49 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AttributeValue.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/AttributeValue.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AttributeValue.java,v 1.2.4.1 2005/09/01 10:25:49 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BinOpExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BinOpExpr.java index 8185d11d3d4..0b6f593c568 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BinOpExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BinOpExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: BinOpExpr.java,v 1.2.4.1 2005/09/01 11:42:27 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BooleanCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BooleanCall.java index 16eb6d412b5..4f18bdcf3ee 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BooleanCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BooleanCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: BooleanCall.java,v 1.2.4.1 2005/09/01 11:43:50 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BooleanExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BooleanExpr.java index 27fe966b692..5d66ff4d7ce 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BooleanExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/BooleanExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: BooleanExpr.java,v 1.2.4.1 2005/09/01 11:44:57 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CallTemplate.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CallTemplate.java index 2e2ca146e84..93a2b2cbf44 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CallTemplate.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CallTemplate.java @@ -2,13 +2,14 @@ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CastCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CastCall.java index c1131f3b9c4..06862ee0dd0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CastCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CastCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CastCall.java,v 1.2.4.1 2005/09/01 11:47:58 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CeilingCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CeilingCall.java index b0b9de9d7ad..1b5ee13d6f1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CeilingCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CeilingCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CeilingCall.java,v 1.2.4.1 2005/09/01 11:59:19 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Closure.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Closure.java index 06d7801a407..b89b9dfbe4a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Closure.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Closure.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Closure.java,v 1.2.4.1 2005/09/01 12:01:23 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Comment.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Comment.java index 0b25a453073..37ce5a1fd46 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Comment.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Comment.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Comment.java,v 1.2.4.1 2005/09/01 12:02:37 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CompilerException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CompilerException.java index c8f673e2fdf..76786aa471d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CompilerException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CompilerException.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CompilerException.java,v 1.2.4.1 2005/09/01 12:04:22 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ConcatCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ConcatCall.java index 4b3ac6a08a5..040320d3eff 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ConcatCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ConcatCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ConcatCall.java,v 1.2.4.1 2005/09/01 12:07:31 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Constants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Constants.java index def384b8c48..22bc7616a2c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Constants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Constants.java @@ -99,7 +99,7 @@ public interface Constants extends InstructionConstants { = com.sun.org.apache.bcel.internal.Constants.ACC_STATIC; public static final String MODULE_SIG - = "Ljava/lang/reflect/Module;"; + = "Ljava/lang/Module;"; public static final String CLASS_SIG = "Ljava/lang/Class;"; public static final String STRING_SIG @@ -255,7 +255,7 @@ public interface Constants extends InstructionConstants { public static final String CLASS_CLASS = "java.lang.Class"; public static final String MODULE_CLASS - = "java.lang.reflect.Module"; + = "java.lang.Module"; public static final String STRING_CLASS = "java.lang.String"; public static final String OBJECT_CLASS diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ContainsCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ContainsCall.java index e0cd56c0728..18610a49c4a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ContainsCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ContainsCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ContainsCall.java,v 1.2.4.1 2005/09/01 12:12:06 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Copy.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Copy.java index 6c921bb8383..f485275783e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Copy.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Copy.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Copy.java,v 1.2.4.1 2005/09/01 12:14:32 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CopyOf.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CopyOf.java index ed60f4fec8e..5cc06737a0c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CopyOf.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CopyOf.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CopyOf.java,v 1.2.4.1 2005/09/01 12:16:22 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CurrentCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CurrentCall.java index cca6ea3147f..9cdae02c6fb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CurrentCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/CurrentCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CurrentCall.java,v 1.2.4.1 2005/09/01 12:23:16 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/DecimalFormatting.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/DecimalFormatting.java index 8c89eaef400..0e82c7f196d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/DecimalFormatting.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/DecimalFormatting.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DecimalFormatting.java,v 1.2.4.1 2005/09/12 10:14:32 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/DocumentCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/DocumentCall.java index 44063a3d6a9..f2b9312b0a4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/DocumentCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/DocumentCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DocumentCall.java,v 1.2.4.1 2005/09/01 14:10:13 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ElementAvailableCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ElementAvailableCall.java index 4b49f1cb83d..74abd4f1e0b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ElementAvailableCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ElementAvailableCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ElementAvailableCall.java,v 1.2.4.1 2005/09/01 14:13:01 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/EqualityExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/EqualityExpr.java index e1d9b0a25cd..e6fe7ee3052 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/EqualityExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/EqualityExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: EqualityExpr.java,v 1.2.4.1 2005/09/12 10:16:52 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Expression.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Expression.java index 64e440d9863..6067dc3ac61 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Expression.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Expression.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Expression.java,v 1.2.4.1 2005/09/01 14:17:51 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Fallback.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Fallback.java index d04eb9af615..f509a8bc40e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Fallback.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Fallback.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Fallback.java,v 1.2.4.1 2005/09/01 14:22:25 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilterExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilterExpr.java index c4842835537..733159cacf5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilterExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilterExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FilterExpr.java,v 1.2.4.1 2005/09/12 10:22:50 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilterParentPath.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilterParentPath.java index 2d3b75dc4ec..f2971ae8621 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilterParentPath.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilterParentPath.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FilterParentPath.java,v 1.2.4.1 2005/09/12 10:24:55 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilteredAbsoluteLocationPath.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilteredAbsoluteLocationPath.java index 82174b58834..6602b9a0db1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilteredAbsoluteLocationPath.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FilteredAbsoluteLocationPath.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FilteredAbsoluteLocationPath.java,v 1.2.4.1 2005/09/12 10:26:50 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FloorCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FloorCall.java index bd39136cc3e..085cd22098e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FloorCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FloorCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FloorCall.java,v 1.2.4.1 2005/09/01 15:16:15 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FlowList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FlowList.java index 43244b378bf..ae5459a5fc4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FlowList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FlowList.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FlowList.java,v 1.2.4.1 2005/09/01 15:21:43 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FormatNumberCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FormatNumberCall.java index 4aa9311bf2f..c41a050cf80 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FormatNumberCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FormatNumberCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FormatNumberCall.java,v 1.2.4.1 2005/09/01 15:26:46 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FunctionAvailableCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FunctionAvailableCall.java index 8cad4275a5b..fc3d1d93752 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FunctionAvailableCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/FunctionAvailableCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FunctionAvailableCall.java,v 1.2.4.1 2005/09/01 15:30:25 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/GenerateIdCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/GenerateIdCall.java index 9ffae4186aa..f686218e919 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/GenerateIdCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/GenerateIdCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: GenerateIdCall.java,v 1.2.4.1 2005/09/01 15:33:17 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IdKeyPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IdKeyPattern.java index 845117d9680..cf32ae16814 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IdKeyPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IdKeyPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IdKeyPattern.java,v 1.5 2005/09/28 13:48:10 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IdPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IdPattern.java index ef3362c6437..c9e9847815d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IdPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IdPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IdPattern.java,v 1.2.4.1 2005/09/01 15:37:33 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/If.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/If.java index a92a6a0dd8f..dd8f82752e4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/If.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/If.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: If.java,v 1.2.4.1 2005/09/01 15:39:47 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IllegalCharException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IllegalCharException.java index 62271b2ae2b..353dd3b4df6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IllegalCharException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IllegalCharException.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IllegalCharException.java,v 1.2.4.1 2005/09/13 12:39:15 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Instruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Instruction.java index 50624cfe47f..1275fcd460e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Instruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Instruction.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Instruction.java,v 1.2.4.1 2005/09/01 15:45:11 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IntExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IntExpr.java index 06a581cffa5..658d306f580 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IntExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/IntExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IntExpr.java,v 1.2.4.1 2005/09/01 15:46:32 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/KeyCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/KeyCall.java index e85c8edfd8b..e47d6c9626c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/KeyCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/KeyCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2006 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: KeyCall.java,v 1.7 2006/06/19 19:49:04 spericas Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/KeyPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/KeyPattern.java index 5a8abdb4145..77ead97efba 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/KeyPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/KeyPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: KeyPattern.java,v 1.2.4.1 2005/09/01 15:50:14 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LangCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LangCall.java index ceb6bbf16bf..212c74ffd2f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LangCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LangCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: LangCall.java,v 1.2.4.1 2005/09/01 15:54:25 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LastCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LastCall.java index 7159ece439c..84614a4429f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LastCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LastCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: LastCall.java,v 1.2.4.1 2005/09/01 15:55:34 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LiteralAttribute.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LiteralAttribute.java index dc99a8d7b68..67ee1a88df9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LiteralAttribute.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LiteralAttribute.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: LiteralAttribute.java,v 1.2.4.1 2005/09/12 10:38:03 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LiteralExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LiteralExpr.java index d97001c1fb6..da84c2e1b25 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LiteralExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LiteralExpr.java @@ -2,15 +2,15 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ - /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: LiteralExpr.java,v 1.2.4.1 2005/09/01 15:58:53 pvedula Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LocalNameCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LocalNameCall.java index 8a9fcae0417..7581eeae21c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LocalNameCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LocalNameCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: LocalNameCall.java,v 1.2.4.1 2005/09/01 16:00:21 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LocationPathPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LocationPathPattern.java index 391809d3e48..d3f68348a82 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LocationPathPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LocationPathPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: LocationPathPattern.java,v 1.2.4.1 2005/09/12 10:42:42 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LogicalExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LogicalExpr.java index 6e295ba79dd..3144d2a11ac 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LogicalExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/LogicalExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: LogicalExpr.java,v 1.2.4.1 2005/09/01 16:03:31 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Message.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Message.java index 034a26782ef..cda255f0fca 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Message.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Message.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Message.java,v 1.2.4.1 2005/09/02 06:47:02 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NameBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NameBase.java index fc94c15cb73..fb977d1c832 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NameBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NameBase.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NameBase.java,v 1.2.4.1 2005/09/02 10:17:31 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NameCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NameCall.java index cb169d03388..712f5adde8a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NameCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NameCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NameCall.java,v 1.2.4.1 2005/09/02 10:19:11 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NamespaceAlias.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NamespaceAlias.java index 8d480998eea..2ac30482c47 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NamespaceAlias.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NamespaceAlias.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NamespaceAlias.java,v 1.2.4.1 2005/09/02 10:20:55 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NamespaceUriCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NamespaceUriCall.java index 2fe7f3fafb9..9a398a79517 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NamespaceUriCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NamespaceUriCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NamespaceUriCall.java,v 1.2.4.1 2005/09/02 10:25:26 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NodeTest.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NodeTest.java index 5ae7c898d4e..26c8b929622 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NodeTest.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NodeTest.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeTest.java,v 1.2.4.1 2005/09/02 10:31:14 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NotCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NotCall.java index bcc2463e5d5..b4e1a0d7e63 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NotCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NotCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NotCall.java,v 1.2.4.1 2005/09/02 10:32:18 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Number.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Number.java index 9b586ac265a..20aff53298a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Number.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Number.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Number.java,v 1.2.4.1 2005/09/21 09:40:51 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NumberCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NumberCall.java index d621bf20ab7..619bb38f22f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NumberCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/NumberCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NumberCall.java,v 1.2.4.1 2005/09/02 10:39:10 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Otherwise.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Otherwise.java index b1358905ea1..fa0a4d9962c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Otherwise.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Otherwise.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Otherwise.java,v 1.2.4.1 2005/09/02 10:58:56 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Output.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Output.java index 0f183b95272..90f1e5f766c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Output.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Output.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Output.java,v 1.2.4.1 2005/09/12 10:53:00 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Param.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Param.java index 41c8ff356cd..031ff811f19 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Param.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Param.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Param.java,v 1.2.4.1 2005/09/02 11:03:42 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParameterRef.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParameterRef.java index ed051fa6607..2ce8e5939eb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParameterRef.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParameterRef.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ParameterRef.java,v 1.2.4.1 2005/09/02 11:05:08 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParentLocationPath.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParentLocationPath.java index 9ecd74a5aab..50106da2eb2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParentLocationPath.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParentLocationPath.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ParentLocationPath.java,v 1.2.4.1 2005/09/12 10:56:30 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParentPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParentPattern.java index 26b01a21980..4743f1b4919 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParentPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ParentPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ParentPattern.java,v 1.2.4.1 2005/09/02 11:10:09 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Pattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Pattern.java index 79b2e0e88fa..06cdab30e37 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Pattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Pattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Pattern.java,v 1.2.4.1 2005/09/12 11:00:31 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/PositionCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/PositionCall.java index f656aece747..680ce56fda8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/PositionCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/PositionCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: PositionCall.java,v 1.2.4.1 2005/09/02 11:17:10 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Predicate.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Predicate.java index 4327f0de939..709815e2eac 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Predicate.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Predicate.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Predicate.java,v 1.2.4.1 2005/09/12 11:02:18 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ProcessingInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ProcessingInstruction.java index 53971c91bef..6780980a82d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ProcessingInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ProcessingInstruction.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ProcessingInstruction.java,v 1.2.4.1 2005/09/12 11:03:05 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ProcessingInstructionPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ProcessingInstructionPattern.java index 9fcdf1c6c6e..9dc13cba95f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ProcessingInstructionPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ProcessingInstructionPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ProcessingInstructionPattern.java,v 1.2.4.1 2005/09/12 11:04:08 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/QName.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/QName.java index 896b216a428..087eaeb66dd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/QName.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/QName.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: QName.java,v 1.2.4.1 2005/09/02 11:45:56 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RealExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RealExpr.java index 5471fe59487..bec4e47cebc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RealExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RealExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: RealExpr.java,v 1.2 2005/08/16 22:30:35 jeffsuttor Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelationalExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelationalExpr.java index fca7e67fcdf..a4e9b9b6226 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelationalExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelationalExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: RelationalExpr.java,v 1.2.4.1 2005/09/12 11:05:00 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelativeLocationPath.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelativeLocationPath.java index 3b68004544f..8e4aee4da48 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelativeLocationPath.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelativeLocationPath.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: RelativeLocationPath.java,v 1.2.4.1 2005/09/02 11:59:22 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelativePathPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelativePathPattern.java index 90bc2d90046..6ab96a9b14e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelativePathPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RelativePathPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: RelativePathPattern.java,v 1.2.4.1 2005/09/02 12:09:38 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RoundCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RoundCall.java index 4a0d1fb1263..ea6df8ffefe 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RoundCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/RoundCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: RoundCall.java,v 1.2.4.1 2005/09/02 12:12:35 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/SimpleAttributeValue.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/SimpleAttributeValue.java index 131ed310bf7..2b95b13c471 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/SimpleAttributeValue.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/SimpleAttributeValue.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SimpleAttributeValue.java,v 1.2.4.1 2005/09/05 08:58:46 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Sort.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Sort.java index f7309e50125..0fa119006e7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Sort.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Sort.java @@ -2,13 +2,14 @@ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/SourceLoader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/SourceLoader.java index cc07708cba3..47f998bd8c1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/SourceLoader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/SourceLoader.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SourceLoader.java,v 1.2.4.1 2005/09/05 09:02:30 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StartsWithCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StartsWithCall.java index 5b946c9b330..6de4ccce03c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StartsWithCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StartsWithCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StartsWithCall.java,v 1.2.4.1 2005/09/05 09:05:28 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Step.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Step.java index cca28f90a9d..0490aeabc3b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Step.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Step.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Step.java,v 1.6 2006/06/06 22:34:34 spericas Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StepPattern.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StepPattern.java index 82582ae24bc..e8ed0e1da56 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StepPattern.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StepPattern.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StepPattern.java,v 1.2.4.1 2005/09/12 11:13:19 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StringCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StringCall.java index ce2d98afb0d..f4303edc4f7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StringCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StringCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StringCall.java,v 1.2.4.1 2005/09/05 09:08:15 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StringLengthCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StringLengthCall.java index 212a6d86a54..3beda444414 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StringLengthCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/StringLengthCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StringLengthCall.java,v 1.2.4.1 2005/09/05 09:08:46 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Text.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Text.java index 3c62f2b926d..db3a6231cbd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Text.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Text.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Text.java,v 1.2.4.1 2005/09/12 11:33:09 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/TopLevelElement.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/TopLevelElement.java index d1676840fbf..b1b14c15bf0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/TopLevelElement.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/TopLevelElement.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: TopLevelElement.java,v 1.5 2005/09/28 13:48:17 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnaryOpExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnaryOpExpr.java index 367b13bf053..6d96e14c0e5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnaryOpExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnaryOpExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: UnaryOpExpr.java,v 1.2.4.1 2005/09/05 09:21:00 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnionPathExpr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnionPathExpr.java index 5cb06be3477..ce9dd64fe23 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnionPathExpr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnionPathExpr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: UnionPathExpr.java,v 1.2.4.1 2005/09/12 11:34:14 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnparsedEntityUriCall.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnparsedEntityUriCall.java index b55edcfe001..205d6ceaa45 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnparsedEntityUriCall.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnparsedEntityUriCall.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: UnparsedEntityUriCall.java,v 1.2.4.1 2005/09/05 09:22:36 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnresolvedRef.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnresolvedRef.java index 963e3c8dba6..53976480f43 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnresolvedRef.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UnresolvedRef.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: UnresolvedRef.java,v 1.5 2005/09/28 13:48:17 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UseAttributeSets.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UseAttributeSets.java index 3751ae3ce7a..79055959743 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UseAttributeSets.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/UseAttributeSets.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: UseAttributeSets.java,v 1.5 2005/09/28 13:48:17 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ValueOf.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ValueOf.java index 9873edd6e0e..5cee916a961 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ValueOf.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/ValueOf.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ValueOf.java,v 1.2.4.1 2005/09/05 09:30:04 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Variable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Variable.java index 3226a36a898..fdc1bd3f2e4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Variable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Variable.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Variable.java,v 1.2.4.1 2005/09/12 11:36:46 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableBase.java index 02e1a5f3ef4..660952efc9a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableBase.java @@ -2,13 +2,14 @@ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableRef.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableRef.java index fe918b0011a..ab39e9ae622 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableRef.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableRef.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: VariableRef.java,v 1.2.4.1 2005/09/05 09:33:50 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableRefBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableRefBase.java index 76cee04a87a..a6267113c7f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableRefBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableRefBase.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: VariableRefBase.java,v 1.5 2005/09/28 13:48:18 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/When.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/When.java index 9efe14283cc..19f34f1a8bb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/When.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/When.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: When.java,v 1.2.4.1 2005/09/05 09:36:58 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Whitespace.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Whitespace.java index edfa5a8d3dd..86e3e24bcc9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Whitespace.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/Whitespace.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Whitespace.java,v 1.5 2005/09/28 13:48:18 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/WithParam.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/WithParam.java index 37d4cf93a2a..d802a5fa2ae 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/WithParam.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/WithParam.java @@ -2,13 +2,14 @@ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XPathLexer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XPathLexer.java index ecdd00f1e41..c5dc46865d3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XPathLexer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XPathLexer.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: xpath.lex,v 1.12 2005/08/02 02:59:03 mcnamara Exp $ - */ /* * @author Jacek Ambroziak * @author Santiago Pericas-Geertsen diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XPathParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XPathParser.java index f33b34b29cf..fbc5a603afc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XPathParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/XPathParser.java @@ -1,8 +1,27 @@ - -//---------------------------------------------------- -// The following code was generated by CUP v0.10j -// Thu Oct 06 10:09:26 PDT 2005 -//---------------------------------------------------- +/* + * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ package com.sun.org.apache.xalan.internal.xsltc.compiler; @@ -16,8 +35,10 @@ import com.sun.org.apache.xml.internal.dtm.Axis; import com.sun.org.apache.xalan.internal.xsltc.runtime.Operators; import com.sun.org.apache.xalan.internal.xsltc.compiler.util.ErrorMsg; -/** CUP v0.10j generated parser. - */ +/** + * CUP v0.10j generated parser. + * This class was generated by CUP v0.10j on Thu Oct 06 10:09:26 PDT 2005. + */ public class XPathParser extends com.sun.java_cup.internal.runtime.lr_parser { /** Default constructor. */ diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/sym.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/sym.java index d64dc3fd046..843521e419a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/sym.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/sym.java @@ -1,12 +1,34 @@ - -//---------------------------------------------------- -// The following code was generated by CUP v0.10j -// Fri Feb 27 13:01:50 PST 2004 -//---------------------------------------------------- +/* + * Copyright (c) 2004, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ package com.sun.org.apache.xalan.internal.xsltc.compiler; -/** CUP generated class containing symbol constants. */ +/** + * CUP generated class containing symbol constants. + * This class was generated by CUP v0.10j on Fri Feb 27 13:01:50 PST 2004. + */ public class sym { /* terminals */ public static final int Literal = 26; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/AttributeSetMethodGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/AttributeSetMethodGenerator.java index 82af0b84db5..79c4aad1996 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/AttributeSetMethodGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/AttributeSetMethodGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AttributeSetMethodGenerator.java,v 1.5 2005/09/28 13:48:24 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/BooleanType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/BooleanType.java index 1feca890e42..c29304fd83f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/BooleanType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/BooleanType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: BooleanType.java,v 1.2.4.1 2005/09/05 11:03:37 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ClassGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ClassGenerator.java index d747075ea8f..c5297e79e27 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ClassGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ClassGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ClassGenerator.java,v 1.2.4.1 2005/09/05 11:07:09 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/CompareGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/CompareGenerator.java index bb40dc1a072..5dbc6851992 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/CompareGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/CompareGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CompareGenerator.java,v 1.2.4.1 2005/09/05 11:08:02 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_ca.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_ca.java index 708f7444b89..3af790e444e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_ca.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_ca.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ErrorMessages_ca.java,v 1.1.6.1 2005/09/05 11:52:59 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_cs.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_cs.java index f172643766d..83587915afe 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_cs.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_cs.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ErrorMessages_cs.java,v 1.1.6.1 2005/09/05 11:52:59 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_ko.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_ko.java index 1de0bb1e5aa..92ff7e1de48 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_ko.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_ko.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -417,7 +417,7 @@ public class ErrorMessages_ko extends ListResourceBundle { * XSLTC to process the XML input document had a configuration problem. */ {ErrorMsg.SAX_PARSER_CONFIG_ERR, - "JAXP \uAD6C\uBB38 \uBD84\uC11D\uAE30\uAC00 \uC81C\uB300\uB85C \uAD6C\uC131\uB418\uC9C0 \uC54A\uC558\uC2B5\uB2C8\uB2E4."}, + "JAXP \uAD6C\uBB38\uBD84\uC11D\uAE30\uAC00 \uC81C\uB300\uB85C \uAD6C\uC131\uB418\uC9C0 \uC54A\uC558\uC2B5\uB2C8\uB2E4."}, /* * Note to translators: The substitution text names the internal error diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_sk.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_sk.java index 17646e9c51d..27c81236a12 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_sk.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ErrorMessages_sk.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ErrorMessages_sk.java,v 1.1.6.1 2005/09/05 11:53:00 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/FilterGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/FilterGenerator.java index 96f680fe4a1..1e8f00fc8a8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/FilterGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/FilterGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FilterGenerator.java,v 1.2.4.1 2005/09/05 11:13:52 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/IntType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/IntType.java index 247e6e2b3aa..a1f81ed6f0e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/IntType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/IntType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IntType.java,v 1.2.4.1 2005/09/05 11:14:44 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/InternalError.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/InternalError.java index 2bb0c3df3c5..406e78d9864 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/InternalError.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/InternalError.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +19,7 @@ * limitations under the License. */ -/* - * $Id: InternalError.java,v 1.0 2011-08-18 04:34:19 joehw Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.compiler.util; /** * Marks a class of errors in which XSLTC has reached some incorrect internal diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MarkerInstruction.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MarkerInstruction.java index e76a3fe500f..929a8dca4d2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MarkerInstruction.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MarkerInstruction.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +19,7 @@ * limitations under the License. */ -/* - * $Id: MethodGenerator.java,v 1.10 2010-11-01 04:34:19 joehw Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.compiler.util; import java.io.DataOutputStream; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MatchGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MatchGenerator.java index 5972bebb5d0..9db88e8d991 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MatchGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MatchGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: MatchGenerator.java,v 1.2.4.1 2005/09/05 11:15:21 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MethodType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MethodType.java index 8cd03083084..9c076a97b08 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MethodType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/MethodType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: MethodType.java,v 1.2.4.1 2005/09/05 11:18:05 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NamedMethodGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NamedMethodGenerator.java index 0913a7bc1e5..0c5fc69afc8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NamedMethodGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NamedMethodGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NamedMethodGenerator.java,v 1.2.4.1 2005/09/05 11:19:56 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeCounterGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeCounterGenerator.java index 68ddc8999dc..aa4ba8264dd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeCounterGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeCounterGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeCounterGenerator.java,v 1.2.4.1 2005/09/05 11:20:48 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSetType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSetType.java index 616fd706b59..f599fb2c543 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSetType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSetType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeSetType.java,v 1.2.4.1 2005/09/05 11:21:45 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSortRecordFactGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSortRecordFactGenerator.java index bacccac2724..21d726b3a04 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSortRecordFactGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSortRecordFactGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeSortRecordFactGenerator.java,v 1.2.4.1 2005/09/05 11:23:07 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSortRecordGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSortRecordGenerator.java index 0e533388e81..7e90d4fc191 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSortRecordGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeSortRecordGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeSortRecordGenerator.java,v 1.2.4.1 2005/09/05 11:23:42 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeType.java index e48a092055e..ebf18b307f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NodeType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeType.java,v 1.2.4.1 2005/09/05 11:24:25 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NumberType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NumberType.java index c50e153709d..9d109a32816 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NumberType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/NumberType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NumberType.java,v 1.2.4.1 2005/09/05 11:25:11 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ObjectType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ObjectType.java index 206b59efe62..acf2bc3c984 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ObjectType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ObjectType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ObjectType.java,v 1.2.4.1 2005/09/12 11:45:54 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/OutlineableChunkEnd.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/OutlineableChunkEnd.java index b2daff35cf0..26543d29beb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/OutlineableChunkEnd.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/OutlineableChunkEnd.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +19,7 @@ * limitations under the License. */ -/* - * $Id: OutlineableChunkEnd.java,v 1.10 2010-11-01 04:34:19 joehw Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.compiler.util; import com.sun.org.apache.bcel.internal.generic.Instruction; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/OutlineableChunkStart.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/OutlineableChunkStart.java index 9b54cac0f22..d6d83db22d5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/OutlineableChunkStart.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/OutlineableChunkStart.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +19,7 @@ * limitations under the License. */ -/* - * $Id: MethodGenerator.java,v 1.10 2010-11-01 04:34:19 joehw Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.compiler.util; import com.sun.org.apache.bcel.internal.generic.Instruction; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/RealType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/RealType.java index f70a210c0ab..4a2e034afc9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/RealType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/RealType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: RealType.java,v 1.2.4.1 2005/09/05 11:28:45 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ReferenceType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ReferenceType.java index 1ceccf26a92..aafeba1b7d1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ReferenceType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ReferenceType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ReferenceType.java,v 1.2.4.1 2005/09/05 11:29:12 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ResultTreeType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ResultTreeType.java index e61f7cbc87a..eb7f6d28fe5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ResultTreeType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/ResultTreeType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ResultTreeType.java,v 1.2.4.1 2005/09/05 11:30:01 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/RtMethodGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/RtMethodGenerator.java index a31dec64598..f104f78ad05 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/RtMethodGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/RtMethodGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: RtMethodGenerator.java,v 1.2.4.1 2005/09/05 11:30:49 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/SlotAllocator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/SlotAllocator.java index 0bd7387f169..960bf5f12c6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/SlotAllocator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/SlotAllocator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SlotAllocator.java,v 1.2.4.1 2005/09/05 11:32:51 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/StringStack.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/StringStack.java index 4cd2b576f63..46cafd86958 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/StringStack.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/StringStack.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StringStack.java,v 1.2.4.1 2005/09/05 11:33:32 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/StringType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/StringType.java index 784482ba8db..0fb1dac60d5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/StringType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/StringType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StringType.java,v 1.2.4.1 2005/09/05 11:35:57 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/TestGenerator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/TestGenerator.java index f6a62c061b6..b5452e91ffd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/TestGenerator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/TestGenerator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: TestGenerator.java,v 1.2.4.1 2005/09/05 11:36:49 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/Type.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/Type.java index b0829dc9ed3..a2bcb312473 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/Type.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/Type.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Type.java,v 1.8 2007/03/28 16:51:19 joehw Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/TypeCheckError.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/TypeCheckError.java index 74aed6412a8..dd34d69a6de 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/TypeCheckError.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/TypeCheckError.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: TypeCheckError.java,v 1.2.4.1 2005/09/05 11:42:57 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/Util.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/Util.java index f1f92221072..ef012cec5d5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/Util.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/Util.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Util.java,v 1.2.4.1 2005/09/12 11:47:15 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/VoidType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/VoidType.java index cb904f190be..6e4918eb14f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/VoidType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/util/VoidType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: VoidType.java,v 1.2.4.1 2005/09/05 11:45:26 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.compiler.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/AbsoluteIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/AbsoluteIterator.java index c7962e7a82c..1884d4885be 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/AbsoluteIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/AbsoluteIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AbsoluteIterator.java,v 1.2.4.1 2005/09/06 05:46:46 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/AnyNodeCounter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/AnyNodeCounter.java index ebae63dfd51..6e79e3174da 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/AnyNodeCounter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/AnyNodeCounter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AnyNodeCounter.java,v 1.2.4.1 2005/09/06 05:54:53 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ArrayNodeListIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ArrayNodeListIterator.java index d7cf3a54fd0..780ed2e5ceb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ArrayNodeListIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ArrayNodeListIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +19,7 @@ * limitations under the License. */ -/* - * $Id: ArrayNodeListIterator.java,v 1.0 2009-11-25 04:34:24 joehw Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.dom; import com.sun.org.apache.xml.internal.dtm.DTMAxisIterator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/BitArray.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/BitArray.java index aadfb5495d5..b218a921402 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/BitArray.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/BitArray.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: BitArray.java,v 1.2.4.1 2005/09/06 05:56:52 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CachedNodeListIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CachedNodeListIterator.java index 3a3ed93359d..7270d1618de 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CachedNodeListIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CachedNodeListIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CachedNodeListIterator.java,v 1.2.4.1 2005/09/06 05:57:47 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ClonedNodeListIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ClonedNodeListIterator.java index 71d59495935..0d803e6e0a9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ClonedNodeListIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ClonedNodeListIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ClonedNodeListIterator.java,v 1.2.4.1 2005/09/06 06:02:12 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CollatorFactoryBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CollatorFactoryBase.java index 83d394e86db..ce509409620 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CollatorFactoryBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CollatorFactoryBase.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CollatorFactoryBase.java,v 1.2.4.1 2005/09/06 06:03:08 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CurrentNodeListFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CurrentNodeListFilter.java index 5457be51e6c..022b0e6dfc3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CurrentNodeListFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CurrentNodeListFilter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CurrentNodeListFilter.java,v 1.2.4.1 2005/09/06 06:04:06 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CurrentNodeListIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CurrentNodeListIterator.java index 512e1e9310f..ba868a32b66 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CurrentNodeListIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/CurrentNodeListIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CurrentNodeListIterator.java,v 1.2.4.1 2005/09/06 06:04:45 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/DOMBuilder.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/DOMBuilder.java index 4f163667cb1..e80313b9a87 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/DOMBuilder.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/DOMBuilder.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOMBuilder.java,v 1.2.4.1 2005/09/06 06:08:23 pvedula Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/DupFilterIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/DupFilterIterator.java index 8ba00f4c6bf..955b40aaa4b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/DupFilterIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/DupFilterIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DupFilterIterator.java,v 1.2.4.1 2005/09/06 06:16:11 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/EmptyFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/EmptyFilter.java index 57420ff89d3..dc7f2ab8806 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/EmptyFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/EmptyFilter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: EmptyFilter.java,v 1.2.4.1 2005/09/06 06:17:05 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ExtendedSAX.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ExtendedSAX.java index 2eb927d82be..a720d49f0a4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ExtendedSAX.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ExtendedSAX.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExtendedSAX.java,v 1.2.4.1 2005/09/06 06:17:46 pvedula Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.dom; import org.xml.sax.ContentHandler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/Filter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/Filter.java index 245ebff1cba..5408a01bc9a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/Filter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/Filter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Filter.java,v 1.2.4.1 2005/09/06 06:18:58 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/FilterIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/FilterIterator.java index d27c7599cf8..d20f6e6db8d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/FilterIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/FilterIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FilterIterator.java,v 1.2.4.1 2005/09/06 06:21:10 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/FilteredStepIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/FilteredStepIterator.java index 704ebb42058..f4785f24a2f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/FilteredStepIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/FilteredStepIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: FilteredStepIterator.java,v 1.2.4.1 2005/09/06 06:20:13 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ForwardPositionIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ForwardPositionIterator.java index f902df9c281..dec62c2eed7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ForwardPositionIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ForwardPositionIterator.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +17,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ForwardPositionIterator.java,v 1.2.4.1 2005/09/06 06:22:05 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; @@ -62,6 +59,7 @@ import com.sun.org.apache.xml.internal.dtm.ref.DTMAxisIteratorBase; * @deprecated This class exists only for backwards compatibility with old * translets. New code should not reference it. */ +@Deprecated public final class ForwardPositionIterator extends DTMAxisIteratorBase { private DTMAxisIterator _source; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/KeyIndex.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/KeyIndex.java index b89b098a283..47acd8a9482 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/KeyIndex.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/KeyIndex.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -115,6 +115,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * Merge the current value's nodeset set by lookupKey() with _nodes. * @deprecated */ + @Deprecated public void merge(KeyIndex other) { if (other == null) return; @@ -136,6 +137,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * key() function. * @deprecated */ + @Deprecated public void lookupId(Object value) { // Clear _nodes array _nodes = null; @@ -205,6 +207,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public void lookupKey(Object value) { IntegerArray nodes = _index.get(value); _nodes = (nodes != null) ? (IntegerArray) nodes.clone() : null; @@ -217,6 +220,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public int next() { if (_nodes == null) return DTMAxisIterator.END; @@ -313,6 +317,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public DTMAxisIterator reset() { _position = 0; return this; @@ -324,6 +329,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public int getLast() { return (_nodes == null) ? 0 : _nodes.cardinality(); } @@ -334,6 +340,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public int getPosition() { return _position; } @@ -344,6 +351,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public void setMark() { _markedPosition = _position; } @@ -354,6 +362,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public void gotoMark() { _position = _markedPosition; } @@ -365,6 +374,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public DTMAxisIterator setStartNode(int start) { if (start == DTMAxisIterator.END) { _nodes = null; @@ -382,6 +392,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public int getStartNode() { return 0; } @@ -392,6 +403,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public boolean isReverse() { return(false); } @@ -402,6 +414,7 @@ public class KeyIndex extends DTMAxisIteratorBase { * deprecated.

    * @deprecated */ + @Deprecated public DTMAxisIterator cloneIterator() { KeyIndex other = new KeyIndex(0); other._index = _index; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/LoadDocument.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/LoadDocument.java index f3e28791a2f..347f4f192b8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/LoadDocument.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/LoadDocument.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: LoadDocument.java,v 1.2.4.1 2005/09/06 07:14:12 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MatchingIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MatchingIterator.java index d0bc39c4d27..7e8c24bae16 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MatchingIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MatchingIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: MatchingIterator.java,v 1.2.4.1 2005/09/06 09:22:07 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MultiValuedNodeHeapIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MultiValuedNodeHeapIterator.java index efc22514853..46aecfdc137 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MultiValuedNodeHeapIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MultiValuedNodeHeapIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2006 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MultipleNodeCounter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MultipleNodeCounter.java index 44ff62c77d2..64644f39705 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MultipleNodeCounter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/MultipleNodeCounter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: MultipleNodeCounter.java,v 1.2.4.1 2005/09/12 11:49:56 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeCounter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeCounter.java index cad02f51c41..5fd120ef797 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeCounter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeCounter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeCounter.java,v 1.2.4.1 2005/09/12 11:52:36 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeIteratorBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeIteratorBase.java index d51354a400e..e06ad14be0f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeIteratorBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeIteratorBase.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeIteratorBase.java,v 1.2.4.1 2005/09/06 09:37:02 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecord.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecord.java index aaf997a726c..45920a15409 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecord.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecord.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +17,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeSortRecord.java,v 1.5 2005/09/28 13:48:36 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; @@ -51,6 +48,7 @@ public abstract class NodeSortRecord { * @deprecated This field continues to exist for binary compatibility. * New code should not refer to it. */ + @Deprecated private static final Collator DEFAULT_COLLATOR = Collator.getInstance(); /** @@ -58,6 +56,7 @@ public abstract class NodeSortRecord { * @deprecated This field continues to exist for binary compatibility. * New code should not refer to it. */ + @Deprecated protected Collator _collator = DEFAULT_COLLATOR; protected Collator[] _collators; @@ -66,6 +65,7 @@ public abstract class NodeSortRecord { * @deprecated This field continues to exist for binary compatibility. * New code should not refer to it. */ + @Deprecated protected Locale _locale; protected CollatorFactory _collatorFactory; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecordFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecordFactory.java index 1cc464c4937..6ba882d8ad5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecordFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecordFactory.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +17,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeSortRecordFactory.java,v 1.2.4.1 2005/09/06 09:53:40 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; @@ -57,6 +54,7 @@ public class NodeSortRecordFactory { * @deprecated This constructor is no longer used in generated code. It * exists only for backwards compatibility. */ + @Deprecated public NodeSortRecordFactory(DOM dom, String className, Translet translet, String order[], String type[]) throws TransletException diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NthIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NthIterator.java index 612188f03f1..a98632400ba 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NthIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NthIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NthIterator.java,v 1.2.4.1 2005/09/06 09:57:04 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SimpleResultTreeImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SimpleResultTreeImpl.java index 812258a8f76..14a280bffb4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SimpleResultTreeImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SimpleResultTreeImpl.java @@ -2,13 +2,14 @@ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SingleNodeCounter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SingleNodeCounter.java index 2042e4aa4d8..0906a53e425 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SingleNodeCounter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SingleNodeCounter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SingleNodeCounter.java,v 1.2.4.1 2005/09/12 11:58:23 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SingletonIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SingletonIterator.java index 0e8dacadf71..3fad0b8f93c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SingletonIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SingletonIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SingletonIterator.java,v 1.2.4.1 2005/09/06 10:15:18 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SortSettings.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SortSettings.java index 631c5e7bbf2..759210d50ab 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SortSettings.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SortSettings.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SortSettings.java,v 1.2.4.1 2005/09/06 10:19:22 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SortingIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SortingIterator.java index eff263a5df8..bc17490a646 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SortingIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/SortingIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SortingIterator.java,v 1.2.4.1 2005/09/06 10:23:32 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/StepIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/StepIterator.java index 3acec748a90..3896547bdb7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/StepIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/StepIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StepIterator.java,v 1.2.4.1 2005/09/06 10:26:47 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/StripWhitespaceFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/StripWhitespaceFilter.java index 8218009a3e9..02b0b7021af 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/StripWhitespaceFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/StripWhitespaceFilter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StripWhitespaceFilter.java,v 1.2.4.1 2005/09/06 10:32:05 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/UnionIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/UnionIterator.java index d054c7ed1d0..597c445cfb6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/UnionIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/UnionIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2006 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: UnionIterator.java,v 1.5 2005/09/28 13:48:38 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.dom; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/XSLTCDTMManager.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/XSLTCDTMManager.java index 0cc6d073164..0de66e3ae58 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/XSLTCDTMManager.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/XSLTCDTMManager.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XSLTCDTMManager.java,v 1.2 2005/08/16 22:32:54 jeffsuttor Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.dom; import javax.xml.stream.XMLEventReader; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Attributes.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Attributes.java index 62e57a6cf91..a3aba1cecd7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Attributes.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Attributes.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Attributes.java,v 1.2.4.1 2005/09/06 10:53:04 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/BasisLibrary.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/BasisLibrary.java index 1ef07039c8f..f2892d07c64 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/BasisLibrary.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/BasisLibrary.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -100,6 +100,7 @@ public final class BasisLibrary { * @deprecated This method exists only for backwards compatibility with old * translets. New code should not reference it. */ + @Deprecated public static int positionF(DTMAxisIterator iterator) { return iterator.isReverse() ? iterator.getLast() - iterator.getPosition() + 1 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Constants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Constants.java index 74a87a737e4..da7fc74415b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Constants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Constants.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Constants.java,v 1.2.4.1 2005/09/06 11:01:29 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages.java index fe98ae968c0..54ecd80e55e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ca.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ca.java index a2b2ba14caa..20bd7af3dc4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ca.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ca.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ErrorMessages_ca.java,v 1.1.6.1 2005/09/06 10:45:37 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_cs.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_cs.java index 88409e1a507..35c3af49c7b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_cs.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_cs.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ErrorMessages_cs.java,v 1.1.6.1 2005/09/06 10:45:37 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_de.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_de.java index b86e7dedcca..6b44ace762d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_de.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_de.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_es.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_es.java index 350d75fae40..375173c9189 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_es.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_es.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_fr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_fr.java index f60f2a52ec9..40b2c11bc11 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_fr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_fr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_it.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_it.java index e4a7b2d18f5..9229c7593f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_it.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_it.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ja.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ja.java index 3cd3712c611..8108e8f7218 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ja.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ja.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ko.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ko.java index e24a7c103be..b21265791db 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ko.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_ko.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -209,7 +210,7 @@ public class ErrorMessages_ko extends ListResourceBundle { * DTD. */ {BasisLibrary.PARSER_DTD_SUPPORT_ERR, - "\uC0AC\uC6A9 \uC911\uC778 SAX \uAD6C\uBB38 \uBD84\uC11D\uAE30\uAC00 DTD \uC120\uC5B8 \uC774\uBCA4\uD2B8\uB97C \uCC98\uB9AC\uD558\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4."}, + "\uC0AC\uC6A9 \uC911\uC778 SAX \uAD6C\uBB38\uBD84\uC11D\uAE30\uAC00 DTD \uC120\uC5B8 \uC774\uBCA4\uD2B8\uB97C \uCC98\uB9AC\uD558\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4."}, /* * Note to translators: The following message indicates that the XML @@ -218,7 +219,7 @@ public class ErrorMessages_ko extends ListResourceBundle { * declarations. */ {BasisLibrary.NAMESPACES_SUPPORT_ERR, - "\uC0AC\uC6A9 \uC911\uC778 SAX \uAD6C\uBB38 \uBD84\uC11D\uAE30\uAC00 XML \uB124\uC784\uC2A4\uD398\uC774\uC2A4\uB97C \uC9C0\uC6D0\uD558\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4."}, + "\uC0AC\uC6A9 \uC911\uC778 SAX \uAD6C\uBB38\uBD84\uC11D\uAE30\uAC00 XML \uB124\uC784\uC2A4\uD398\uC774\uC2A4\uB97C \uC9C0\uC6D0\uD558\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4."}, /* * Note to translators: The substitution text is the URI that was in diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_pt_BR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_pt_BR.java index 45e2654bf1f..0449d56d528 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_pt_BR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_pt_BR.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_sk.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_sk.java index 6ee58b7c614..cdaae51704c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_sk.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_sk.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ErrorMessages_sk.java,v 1.1.6.1 2005/09/06 10:45:39 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_sv.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_sv.java index 2c2b40eca2b..214c20c5e28 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_sv.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_sv.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_zh_CN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_zh_CN.java index a34d42c933e..076b06d50db 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_zh_CN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_zh_CN.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_zh_TW.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_zh_TW.java index 67e3831f810..92736a4154c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_zh_TW.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/ErrorMessages_zh_TW.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/InternalRuntimeError.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/InternalRuntimeError.java index 1f11788021e..d51e8457c2d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/InternalRuntimeError.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/InternalRuntimeError.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +19,7 @@ * limitations under the License. */ -/* - * $Id: InternalRuntimeError.java,v 1.0 2009-11-25 04:34:28 joehw Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.runtime; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/MessageHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/MessageHandler.java index da227f5d9b9..f7b47713a6c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/MessageHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/MessageHandler.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: MessageHandler.java,v 1.2.4.1 2005/09/06 11:06:49 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Node.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Node.java index add4114ad5b..69c8292ea13 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Node.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Node.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Node.java,v 1.2.4.1 2005/09/06 11:10:29 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Operators.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Operators.java index da71f8c096b..3ba86c1fdc1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Operators.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Operators.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Operators.java,v 1.2.4.1 2005/09/12 12:02:15 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Parameter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Parameter.java index e3b682dfed0..6a32cdd48a8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Parameter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/Parameter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Parameter.java,v 1.2.4.1 2005/09/06 11:21:58 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/StringValueHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/StringValueHandler.java index 83083527203..06b81511b2d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/StringValueHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/StringValueHandler.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StringValueHandler.java,v 1.2.4.1 2005/09/06 11:33:25 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/OutputBuffer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/OutputBuffer.java index 01f1ca9bc2e..997b71af886 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/OutputBuffer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/OutputBuffer.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: OutputBuffer.java,v 1.2.4.1 2005/09/06 11:35:23 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime.output; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/StringOutputBuffer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/StringOutputBuffer.java index 2f9c43e3193..b76ccb035c9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/StringOutputBuffer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/StringOutputBuffer.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StringOutputBuffer.java,v 1.2.4.1 2005/09/06 11:36:16 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime.output; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/TransletOutputHandlerFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/TransletOutputHandlerFactory.java index 8b76f3a68b0..6ebdc780edb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/TransletOutputHandlerFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/TransletOutputHandlerFactory.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: TransletOutputHandlerFactory.java,v 1.2.4.2 2005/09/15 19:12:05 jeffsuttor Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime.output; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/WriterOutputBuffer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/WriterOutputBuffer.java index 2b04e01fea4..bbff564ae41 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/WriterOutputBuffer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/output/WriterOutputBuffer.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: WriterOutputBuffer.java,v 1.2.4.1 2005/09/06 11:43:01 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.runtime.output; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/DOM2TO.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/DOM2TO.java index 053773df2ce..233cf326f89 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/DOM2TO.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/DOM2TO.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOM2TO.java,v 1.5 2005/09/28 13:48:44 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.trax; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/OutputSettings.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/OutputSettings.java index cd30df3561f..d397641da92 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/OutputSettings.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/OutputSettings.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: OutputSettings.java,v 1.2.4.1 2005/09/06 11:59:11 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.trax; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/SAX2DOM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/SAX2DOM.java index 8cf62c05fa0..c54fa5188c4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/SAX2DOM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/SAX2DOM.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SAX2DOM.java,v 1.8.2.1 2006/12/04 18:45:41 spericas Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.trax; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TemplatesImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TemplatesImpl.java index e5fac8b7395..bdbdca9137e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TemplatesImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TemplatesImpl.java @@ -43,8 +43,6 @@ import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; import java.lang.module.ModuleReference; import java.lang.module.ModuleReader; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.security.AccessController; import java.security.CodeSigner; import java.security.CodeSource; @@ -435,13 +433,13 @@ public final class TemplatesImpl implements Templates, Serializable { } }; - Layer bootLayer = Layer.boot(); + ModuleLayer bootLayer = ModuleLayer.boot(); Configuration cf = bootLayer.configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of(mn)); + .resolve(finder, ModuleFinder.of(), Set.of(mn)); - PrivilegedAction pa = () -> bootLayer.defineModules(cf, name -> loader); - Layer layer = AccessController.doPrivileged(pa); + PrivilegedAction pa = () -> bootLayer.defineModules(cf, name -> loader); + ModuleLayer layer = AccessController.doPrivileged(pa); Module m = layer.findModule(mn).get(); assert m.getLayer() == layer; @@ -483,10 +481,11 @@ public final class TemplatesImpl implements Templates, Serializable { String pn = _tfactory.getPackageName(); assert pn != null && pn.length() > 0; - ModuleDescriptor descriptor = ModuleDescriptor.module(mn) - .requires("java.xml") - .exports(pn) - .build(); + ModuleDescriptor descriptor = + ModuleDescriptor.newModule(mn, Set.of(ModuleDescriptor.Modifier.SYNTHETIC)) + .requires("java.xml") + .exports(pn, Set.of("java.xml")) + .build(); Module m = createModule(descriptor, loader); diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TrAXFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TrAXFilter.java index 172907e7af0..77e68d43010 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TrAXFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TrAXFilter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: TrAXFilter.java,v 1.2.4.1 2005/09/06 12:23:19 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.trax; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TransformerHandlerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TransformerHandlerImpl.java index cd4b4be14e2..05d38640a16 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TransformerHandlerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/TransformerHandlerImpl.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: TransformerHandlerImpl.java,v 1.2.4.1 2005/09/15 06:25:12 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.trax; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/XSLTCSource.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/XSLTCSource.java index 4d96b597fa8..5237868d42e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/XSLTCSource.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/trax/XSLTCSource.java @@ -2,15 +2,15 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ - /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XSLTCSource.java,v 1.2.4.1 2005/09/06 12:43:28 pvedula Exp $ - */ + package com.sun.org.apache.xalan.internal.xsltc.trax; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/util/IntegerArray.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/util/IntegerArray.java index 4b9d3414f44..f99e9d5005e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/util/IntegerArray.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/util/IntegerArray.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IntegerArray.java,v 1.2.4.1 2005/09/06 11:44:56 pvedula Exp $ - */ package com.sun.org.apache.xalan.internal.xsltc.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrImpl.java index 873f7be9842..33823e22e5f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrImpl.java @@ -1,13 +1,13 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -515,6 +515,7 @@ public class AttrImpl * @deprecated Previous working draft of DOM Level 2. New method * is getOwnerElement(). */ + @Deprecated public Element getElement() { // if we have an owner, ownerNode is our ownerElement, otherwise it's // our ownerDocument and we don't have an ownerElement diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrNSImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrNSImpl.java index 34de50dccde..0eba0744c27 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrNSImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrNSImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttributeMap.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttributeMap.java index 5f7f4e17340..0ad1a07e258 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttributeMap.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttributeMap.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CDATASectionImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CDATASectionImpl.java index 0a495601454..f2ea4c3cb37 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CDATASectionImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CDATASectionImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CharacterDataImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CharacterDataImpl.java index 6f3e5a3dcf7..93443e75523 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CharacterDataImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CharacterDataImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ChildNode.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ChildNode.java index 3dab9c9eea8..c8c2f3e2f83 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ChildNode.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ChildNode.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CommentImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CommentImpl.java index 418e2cc4824..d2b469b5bd4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CommentImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CommentImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CoreDocumentImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CoreDocumentImpl.java index e87ff9c675a..2d446c3fb41 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CoreDocumentImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CoreDocumentImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -832,6 +832,7 @@ public class CoreDocumentImpl * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public void setEncoding(String value) { setXmlEncoding(value); } @@ -849,6 +850,7 @@ public class CoreDocumentImpl * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public String getEncoding() { return getXmlEncoding(); } @@ -890,6 +892,7 @@ public class CoreDocumentImpl * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public void setVersion(String value) { setXmlVersion(value); } @@ -908,6 +911,7 @@ public class CoreDocumentImpl * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public String getVersion() { return getXmlVersion(); } @@ -932,6 +936,7 @@ public class CoreDocumentImpl * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public void setStandalone(boolean value) { setXmlStandalone(value); } @@ -950,6 +955,7 @@ public class CoreDocumentImpl * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public boolean getStandalone() { return getXmlStandalone(); } diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMErrorImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMErrorImpl.java index 90dec38e2f6..a496d412ef2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMErrorImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMErrorImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationImpl.java index 3875a8329d7..ac520b79401 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationListImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationListImpl.java index 15791a36f8c..8ad9cff4880 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationListImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationListImpl.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationSourceImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationSourceImpl.java index 6c2a9b75257..7620eafc060 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationSourceImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMImplementationSourceImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMInputImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMInputImpl.java index bb6abf968fb..49874b5b965 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMInputImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMInputImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMLocatorImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMLocatorImpl.java index 2a421b5201f..8b0ca5e6ff9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMLocatorImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMLocatorImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMMessageFormatter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMMessageFormatter.java index 1d30c9e76b4..ab48b8dddd0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMMessageFormatter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMMessageFormatter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMNormalizer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMNormalizer.java index c2f33916772..2b1b8000081 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMNormalizer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMNormalizer.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004, 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMOutputImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMOutputImpl.java index c9249163ee4..11e1b316672 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMOutputImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMOutputImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMXSImplementationSourceImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMXSImplementationSourceImpl.java index 34a311a34d1..1874e28fa44 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMXSImplementationSourceImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DOMXSImplementationSourceImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeepNodeListImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeepNodeListImpl.java index 1acf62ee67e..85cdef30b26 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeepNodeListImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeepNodeListImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredAttrImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredAttrImpl.java index c3e134296f9..20fa9a23c2c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredAttrImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredAttrImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredAttrNSImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredAttrNSImpl.java index 3b4052146cd..917254cda3a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredAttrNSImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredAttrNSImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredCDATASectionImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredCDATASectionImpl.java index 52132f0567c..e3be7863b6f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredCDATASectionImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredCDATASectionImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredCommentImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredCommentImpl.java index 3f80492959a..4c808190f6c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredCommentImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredCommentImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDOMImplementationImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDOMImplementationImpl.java index 2ba1c9e9abf..0b6c7970b3c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDOMImplementationImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDOMImplementationImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.dom; import org.w3c.dom.DOMImplementation; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentImpl.java index 3ada1eda33c..ba60cd788f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -369,6 +369,7 @@ public class DeferredDocumentImpl * Creates an element node with a URI in the table and type information. * @deprecated */ + @Deprecated public int createDeferredElement(String elementURI, String elementName, Object type) { @@ -389,6 +390,7 @@ public class DeferredDocumentImpl * Creates an element node in the table. * @deprecated */ + @Deprecated public int createDeferredElement(String elementName) { return createDeferredElement(null, elementName); } @@ -474,6 +476,7 @@ public class DeferredDocumentImpl * Sets an attribute on an element node. * @deprecated */ + @Deprecated public int setDeferredAttribute(int elementNodeIndex, String attrName, String attrURI, String attrValue, boolean specified) { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentTypeImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentTypeImpl.java index b7d303855ab..abdc94054a3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentTypeImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentTypeImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementDefinitionImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementDefinitionImpl.java index 09b03c03f43..fd988ac1886 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementDefinitionImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementDefinitionImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementImpl.java index 657a635cb5a..0c977efe4ac 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementNSImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementNSImpl.java index fd54fe6fb66..a6b51ece9e5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementNSImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredElementNSImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredEntityImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredEntityImpl.java index 2b9e8cc0980..74f90b13dd1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredEntityImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredEntityImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredEntityReferenceImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredEntityReferenceImpl.java index 7f3836aa238..cb695026b92 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredEntityReferenceImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredEntityReferenceImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredNode.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredNode.java index 3dba91dd221..37abd62072b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredNode.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredNode.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredNotationImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredNotationImpl.java index 46e06f7dec6..c978fbb3f0f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredNotationImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredNotationImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredProcessingInstructionImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredProcessingInstructionImpl.java index 178cd13c56a..e8f4f0d3cac 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredProcessingInstructionImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredProcessingInstructionImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredTextImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredTextImpl.java index 37d559ab561..d2c6c2db328 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredTextImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredTextImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DocumentFragmentImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DocumentFragmentImpl.java index 64248e21d0a..54ed7066a78 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DocumentFragmentImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DocumentFragmentImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ElementDefinitionImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ElementDefinitionImpl.java index 6c56a691638..9f19c921c20 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ElementDefinitionImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ElementDefinitionImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ElementNSImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ElementNSImpl.java index 042835e7ce6..6a76152555d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ElementNSImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ElementNSImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/EntityImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/EntityImpl.java index 51d76c4b7a0..6da6d24c12b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/EntityImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/EntityImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/EntityReferenceImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/EntityReferenceImpl.java index bbc52878445..9ab58161670 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/EntityReferenceImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/EntityReferenceImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NamedNodeMapImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NamedNodeMapImpl.java index f3e0c942758..67f91f45b28 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NamedNodeMapImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NamedNodeMapImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeImpl.java index 529f5337060..d158f18170b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -763,6 +763,7 @@ public abstract class NodeImpl * @since DOM Level 3 * @deprecated */ + @Deprecated public short compareTreePosition(Node other) { // Questions of clarification for this method - to be answered by the // DOM WG. Current assumptions listed - LM diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeIteratorImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeIteratorImpl.java index 1f17d473ab8..d2b9232f38b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeIteratorImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeIteratorImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeListCache.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeListCache.java index 585c41e6364..7c6017754c3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeListCache.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeListCache.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001,2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NotationImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NotationImpl.java index a8827f41124..b37d7f6c370 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NotationImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NotationImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/PSVIDOMImplementationImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/PSVIDOMImplementationImpl.java index 07271f17d09..2fae8652ef5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/PSVIDOMImplementationImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/PSVIDOMImplementationImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/PSVIDocumentImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/PSVIDocumentImpl.java index 61d4bf921fd..23e71c73a2a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/PSVIDocumentImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/PSVIDocumentImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ProcessingInstructionImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ProcessingInstructionImpl.java index a236576f9a8..38dcb0ba85d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ProcessingInstructionImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/ProcessingInstructionImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/RangeExceptionImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/RangeExceptionImpl.java index 9f391f29b77..46e6deee4e7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/RangeExceptionImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/RangeExceptionImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.dom; import org.w3c.dom.ranges.RangeException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/RangeImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/RangeImpl.java index 31c631d1c81..adbec81ac82 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/RangeImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/RangeImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/TextImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/TextImpl.java index 367ae65c58e..19cb05dd0fc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/TextImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/TextImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/TreeWalkerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/TreeWalkerImpl.java index 20533dd3e85..5077bb6b116 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/TreeWalkerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/TreeWalkerImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/events/EventImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/events/EventImpl.java index 83a085e9abc..2950f5f5afc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/events/EventImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/events/EventImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.dom.events; import org.w3c.dom.events.Event; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/events/MutationEventImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/events/MutationEventImpl.java index 32870347596..b10e93d7f4e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/events/MutationEventImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/events/MutationEventImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/ExternalSubsetResolver.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/ExternalSubsetResolver.java index e845a7c930e..b31e104c5cf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/ExternalSubsetResolver.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/ExternalSubsetResolver.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/RevalidationHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/RevalidationHandler.java index d537d02837a..ff605b8ebb1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/RevalidationHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/RevalidationHandler.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2001, 2002 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 2002, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XML11NSDocumentScannerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XML11NSDocumentScannerImpl.java index e1e788af633..12daf8acc40 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XML11NSDocumentScannerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XML11NSDocumentScannerImpl.java @@ -1,13 +1,13 @@ /* * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. */ - /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -18,6 +18,7 @@ * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl; import java.io.IOException; @@ -135,7 +136,7 @@ public class XML11NSDocumentScannerImpl extends XML11DocumentScannerImpl { if (DEBUG_START_END_ELEMENT) System.out.println(">>> scanStartElementNS()"); // Note: namespace processing is on by default - fEntityScanner.scanQName(fElementQName, NameType.ATTRIBUTE); + fEntityScanner.scanQName(fElementQName, NameType.ELEMENTSTART); // REVISIT - [Q] Why do we need this local variable? -- mrglavas String rawname = fElementQName.rawname; if (fBindNamespaces) { @@ -345,7 +346,7 @@ public class XML11NSDocumentScannerImpl extends XML11DocumentScannerImpl { protected void scanStartElementName () throws IOException, XNIException { // Note: namespace processing is on by default - fEntityScanner.scanQName(fElementQName, NameType.ATTRIBUTE); + fEntityScanner.scanQName(fElementQName, NameType.ELEMENTSTART); // Must skip spaces here because the DTD scanner // would consume them at the end of the external subset. fSawSpace = fEntityScanner.skipSpaces(); @@ -571,7 +572,7 @@ public class XML11NSDocumentScannerImpl extends XML11DocumentScannerImpl { System.out.println(">>> scanAttribute()"); // name - fEntityScanner.scanQName(fAttributeQName, NameType.ATTRIBUTE); + fEntityScanner.scanQName(fAttributeQName, NameType.ATTRIBUTENAME); // equals fEntityScanner.skipSpaces(); diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XML11NamespaceBinder.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XML11NamespaceBinder.java index 87e66c30850..1c203d4b9c5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XML11NamespaceBinder.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XML11NamespaceBinder.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLDTDScannerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLDTDScannerImpl.java index 6e3547cdc83..e90608fff80 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLDTDScannerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLDTDScannerImpl.java @@ -1215,7 +1215,7 @@ implements XMLDTDScanner, XMLComponent, XMLEntityHandler { // definitions while (!fEntityScanner.skipChar('>', null)) { - String name = fEntityScanner.scanName(NameType.ATTRIBUTE); + String name = fEntityScanner.scanName(NameType.ATTRIBUTENAME); if (name == null) { reportFatalError("AttNameRequiredInAttDef", new Object[]{elName}); @@ -1359,7 +1359,7 @@ implements XMLDTDScanner, XMLComponent, XMLEntityHandler { fMarkUpDepth++; do { skipSeparator(false, !scanningInternalSubset()); - String aName = fEntityScanner.scanName(NameType.ATTRIBUTE); + String aName = fEntityScanner.scanName(NameType.ATTRIBUTENAME); if (aName == null) { reportFatalError("MSG_NAME_REQUIRED_IN_NOTATIONTYPE", new Object[]{elName, atName}); diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLDocumentScannerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLDocumentScannerImpl.java index 1226fe319ff..d6d73ca56a5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLDocumentScannerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLDocumentScannerImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. */ /* @@ -743,7 +743,7 @@ public class XMLDocumentScannerImpl // scan XMLDecl try { if (fEntityScanner.skipString(XMLDECL)) { - if (fEntityScanner.peekChar() == ' ') { + if (XMLChar.isSpace(fEntityScanner.peekChar())) { fMarkupDepth++; scanXMLDeclOrTextDecl(false); } else { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLEntityDescription.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLEntityDescription.java index b94e08aba5a..af3603f7966 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLEntityDescription.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLEntityDescription.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLEntityHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLEntityHandler.java index a99a749d1c2..c9921418d57 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLEntityHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLEntityHandler.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLNSDocumentScannerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLNSDocumentScannerImpl.java index c94eea8ed9e..138181db602 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLNSDocumentScannerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLNSDocumentScannerImpl.java @@ -1,13 +1,13 @@ /* * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. */ - /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -18,6 +18,7 @@ * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl; import java.io.IOException; @@ -404,7 +405,7 @@ public class XMLNSDocumentScannerImpl if (DEBUG_START_END_ELEMENT) System.out.println(this.getClass().toString() +">>> scanAttribute()"); // name - fEntityScanner.scanQName(fAttributeQName, NameType.ATTRIBUTE); + fEntityScanner.scanQName(fAttributeQName, NameType.ATTRIBUTENAME); // equals fEntityScanner.skipSpaces(); diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLNamespaceBinder.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLNamespaceBinder.java index 33a18a84444..da21add63e7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLNamespaceBinder.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLNamespaceBinder.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLStreamReaderImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLStreamReaderImpl.java index d937f53c6a0..747bd9bc4f7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLStreamReaderImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLStreamReaderImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -610,6 +610,14 @@ public class XMLStreamReaderImpl implements javax.xml.stream.XMLStreamReader { switchToXML11Scanner(); } + if (fEventType == XMLStreamConstants.CHARACTERS || + fEventType == XMLStreamConstants.ENTITY_REFERENCE || + fEventType == XMLStreamConstants.PROCESSING_INSTRUCTION || + fEventType == XMLStreamConstants.COMMENT || + fEventType == XMLStreamConstants.CDATA) { + fEntityScanner.checkNodeCount(fEntityScanner.fCurrentEntity); + } + return fEventType; } catch (IOException ex) { // if this error occured trying to resolve the external DTD subset diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11DTDProcessor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11DTDProcessor.java index 407498627bd..98f0e2f61eb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11DTDProcessor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11DTDProcessor.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11DTDValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11DTDValidator.java index a39ba0bfcd3..3dad4522134 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11DTDValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11DTDValidator.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2003 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11NSDTDValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11NSDTDValidator.java index fc6dc9148ee..50ff80b622a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11NSDTDValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XML11NSDTDValidator.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2003 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 2002, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLAttributeDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLAttributeDecl.java index a068fdc991d..67c0e9d7a92 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLAttributeDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLAttributeDecl.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLContentSpec.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLContentSpec.java index 39f51c82e12..bc2978c5624 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLContentSpec.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLContentSpec.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDDescription.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDDescription.java index 90a55affe91..48b7303ed90 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDDescription.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDDescription.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDLoader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDLoader.java index eea1b94613f..310726bbf52 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDLoader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDLoader.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2003 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDProcessor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDProcessor.java index 85bdb7f74c5..ae78586807a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDProcessor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDProcessor.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDValidatorFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDValidatorFilter.java index f05aba531d8..c689ccf3f86 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDValidatorFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLDTDValidatorFilter.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2001, 2002 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 2002, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLElementDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLElementDecl.java index 287d10d7bc3..50c05fd97bd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLElementDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLElementDecl.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLEntityDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLEntityDecl.java index 8496dc1d1a7..f1725f0a90f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLEntityDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLEntityDecl.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLNSDTDValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLNSDTDValidator.java index bf4ecf84e1d..c1e5261ad73 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLNSDTDValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLNSDTDValidator.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLNotationDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLNotationDecl.java index 7541875aca7..65e1b0f475c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLNotationDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLNotationDecl.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLSimpleType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLSimpleType.java index c757e39b938..c046243add8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLSimpleType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/XMLSimpleType.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMAny.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMAny.java index 5c47d2e74d6..6f62534cc91 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMAny.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMAny.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMBinOp.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMBinOp.java index 51df88d10aa..56b413e618e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMBinOp.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMBinOp.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMLeaf.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMLeaf.java index 0cc5dfbd3e0..dbeb99066da 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMLeaf.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMLeaf.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMStateSet.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMStateSet.java index d20a3a98c08..3332c059dd1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMStateSet.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMStateSet.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMUniOp.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMUniOp.java index 97f50c1af61..2f844bc89c9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMUniOp.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/CMUniOp.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/ContentModelValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/ContentModelValidator.java index b81f5c1a13f..4cec148d426 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/ContentModelValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/ContentModelValidator.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/DFAContentModel.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/DFAContentModel.java index 008bd6ff8fe..1b62b231135 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/DFAContentModel.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/DFAContentModel.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/MixedContentModel.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/MixedContentModel.java index 8d4cda28213..6f3c513a504 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/MixedContentModel.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/MixedContentModel.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/SimpleContentModel.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/SimpleContentModel.java index 73ae37d3a51..0243023b8bd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/SimpleContentModel.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dtd/models/SimpleContentModel.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dtd.models; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DVFactoryException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DVFactoryException.java index 149d7177ced..f621211cc33 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DVFactoryException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DVFactoryException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DatatypeException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DatatypeException.java index 363b26844f3..17efe6aa09e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DatatypeException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DatatypeException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DatatypeValidator.java index 68cd396871c..40743f8cfba 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/DatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/InvalidDatatypeFacetException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/InvalidDatatypeFacetException.java index 22be4b55937..e5af751d9c8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/InvalidDatatypeFacetException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/InvalidDatatypeFacetException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/InvalidDatatypeValueException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/InvalidDatatypeValueException.java index 648dd1ed692..7557eaef5f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/InvalidDatatypeValueException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/InvalidDatatypeValueException.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2001, 2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.dv; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/SchemaDVFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/SchemaDVFactory.java index 47646f2dad2..f81b7cf41ee 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/SchemaDVFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/SchemaDVFactory.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/ValidationContext.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/ValidationContext.java index da8d550a84a..0eebab57879 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/ValidationContext.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/ValidationContext.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/XSFacets.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/XSFacets.java index 4baeaf1f340..b207501f494 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/XSFacets.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/XSFacets.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/XSSimpleType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/XSSimpleType.java index 5e242796565..8753a08aa21 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/XSSimpleType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/XSSimpleType.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/ENTITYDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/ENTITYDatatypeValidator.java index 52f39b03f0b..b44bd6893f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/ENTITYDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/ENTITYDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/IDDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/IDDatatypeValidator.java index 54fac1ad5b3..ad806374f7d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/IDDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/IDDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/IDREFDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/IDREFDatatypeValidator.java index 4fa2a1c7c52..3c99c8b6c02 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/IDREFDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/IDREFDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/ListDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/ListDatatypeValidator.java index 28a3fd06117..3c562f5949c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/ListDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/ListDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/NMTOKENDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/NMTOKENDatatypeValidator.java index 94eb90104ca..ca9b53ffa1b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/NMTOKENDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/NMTOKENDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/NOTATIONDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/NOTATIONDatatypeValidator.java index 87d95cc1326..c10adeb0e73 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/NOTATIONDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/NOTATIONDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/StringDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/StringDatatypeValidator.java index edc5c5584c1..23397fed540 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/StringDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/StringDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11IDDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11IDDatatypeValidator.java index e429625d8f6..5323c2033f1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11IDDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11IDDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11IDREFDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11IDREFDatatypeValidator.java index 0d8bbf64753..5345ab88acb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11IDREFDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11IDREFDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11NMTOKENDatatypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11NMTOKENDatatypeValidator.java index 1a7296bd913..d670ae636be 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11NMTOKENDatatypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/dtd/XML11NMTOKENDatatypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/util/Base64.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/util/Base64.java index 1ab0752cbfa..1d7462ab692 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/util/Base64.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/util/Base64.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/util/HexBin.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/util/HexBin.java index fb477acfaa5..7f1aa344e84 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/util/HexBin.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/util/HexBin.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AbstractDateTimeDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AbstractDateTimeDV.java index 64242a5cf95..caceec47090 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AbstractDateTimeDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AbstractDateTimeDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnyAtomicDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnyAtomicDV.java index e7dbf96458a..046cdf784f9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnyAtomicDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnyAtomicDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnySimpleDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnySimpleDV.java index 0a8bf002ae0..de36cface35 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnySimpleDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnySimpleDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnyURIDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnyURIDV.java index 3458dac6d6d..740edc722fc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnyURIDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/AnyURIDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/Base64BinaryDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/Base64BinaryDV.java index 47185b1725d..ee14472995a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/Base64BinaryDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/Base64BinaryDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/BaseDVFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/BaseDVFactory.java index 715b0ee040c..84d13c4719c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/BaseDVFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/BaseDVFactory.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002, 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/BooleanDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/BooleanDV.java index 90857ef96b8..8e0cdaf992c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/BooleanDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/BooleanDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DateDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DateDV.java index d302e22fd1a..5d0b437128d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DateDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DateDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DateTimeDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DateTimeDV.java index 2a19f8cec9f..c55df7e43e6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DateTimeDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DateTimeDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DayDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DayDV.java index d0e6ce6021e..f80ceac225e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DayDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DayDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DayTimeDurationDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DayTimeDurationDV.java index 8488503acee..841e639dac1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DayTimeDurationDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DayTimeDurationDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.dv.xs; import java.math.BigDecimal; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DecimalDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DecimalDV.java index 622042b37cf..7799cfaffcf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DecimalDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DecimalDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001,2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DoubleDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DoubleDV.java index a25d6d7243e..3c50032b567 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DoubleDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DoubleDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DurationDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DurationDV.java index 9ad95cc77b4..f48c13b051d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DurationDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/DurationDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/EntityDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/EntityDV.java index 1a62ac9053e..61fce4846ee 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/EntityDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/EntityDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/FloatDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/FloatDV.java index f2478233564..d7ad5d42052 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/FloatDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/FloatDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/FullDVFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/FullDVFactory.java index d003c48f335..9df965f0d91 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/FullDVFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/FullDVFactory.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002, 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/HexBinaryDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/HexBinaryDV.java index 99bc19709dc..c9aca67647b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/HexBinaryDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/HexBinaryDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IDDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IDDV.java index 91621d437bb..eada84dec0e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IDDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IDDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IDREFDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IDREFDV.java index ff0fdfdeba6..9faf08510f3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IDREFDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IDREFDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IntegerDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IntegerDV.java index a1a0c4b5a60..b478bfaee7f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IntegerDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/IntegerDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/ListDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/ListDV.java index 07d49b0988c..e44848611c1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/ListDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/ListDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001,2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/MonthDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/MonthDV.java index 175c5ebf2d9..6ab2e5f7128 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/MonthDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/MonthDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/MonthDayDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/MonthDayDV.java index 0edc0006ad7..a73400dc324 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/MonthDayDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/MonthDayDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/PrecisionDecimalDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/PrecisionDecimalDV.java index a75f03a03ea..3f313cf8677 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/PrecisionDecimalDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/PrecisionDecimalDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.dv.xs; import com.sun.org.apache.xerces.internal.impl.dv.InvalidDatatypeValueException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/QNameDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/QNameDV.java index 347e1043aab..9fa2ce59f34 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/QNameDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/QNameDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/SchemaDVFactoryImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/SchemaDVFactoryImpl.java index 5bb8a4350ed..daa130d233e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/SchemaDVFactoryImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/SchemaDVFactoryImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/SchemaDateTimeException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/SchemaDateTimeException.java index 917ec5982b4..435bde29b2e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/SchemaDateTimeException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/SchemaDateTimeException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/StringDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/StringDV.java index 010bc1b86d5..1ced6aded25 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/StringDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/StringDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/TimeDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/TimeDV.java index 4c7bb4dd46d..460da68ec0d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/TimeDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/TimeDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/TypeValidator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/TypeValidator.java index 989902de5d5..a6061e04f85 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/TypeValidator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/TypeValidator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/UnionDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/UnionDV.java index 0a29639666e..8bf4032452d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/UnionDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/UnionDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearDV.java index 02c5058f55c..079455eb853 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearMonthDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearMonthDV.java index b9fde68ca18..58eb63745c3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearMonthDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearMonthDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearMonthDurationDV.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearMonthDurationDV.java index c11413097ec..0162940dd44 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearMonthDurationDV.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/dv/xs/YearMonthDurationDV.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.dv.xs; import java.math.BigInteger; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/ASCIIReader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/ASCIIReader.java index 0698c5806ad..5d73b8f843b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/ASCIIReader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/ASCIIReader.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/MalformedByteSequenceException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/MalformedByteSequenceException.java index d6851778173..50e51c5dbf7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/MalformedByteSequenceException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/MalformedByteSequenceException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/UCSReader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/UCSReader.java index 74db5f630af..d19e303eb48 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/UCSReader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/UCSReader.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/UTF8Reader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/UTF8Reader.java index 46242056cd9..19baa9c920b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/UTF8Reader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/io/UTF8Reader.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_de.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_de.properties index d3221c5fa92..0b8ee27b51e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_de.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_de.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/13 06:43:54 gmolloy Exp $ BadMessageKey = Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. FormatFailed = Beim Formatieren der folgenden Meldung ist ein interner Fehler aufgetreten:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_es.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_es.properties index 26f25eb9db9..cfbb9cb547d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_es.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_es.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 05:10:53 gmolloy Exp $ BadMessageKey = No se ha encontrado el mensaje de error correspondiente a la clave de mensaje. FormatFailed = Se ha producido un error interno al formatear el siguiente mensaje:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_fr.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_fr.properties index cd1aed4acdc..ef9b325fd5a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_fr.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_fr.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 02:16:52 gmolloy Exp $ BadMessageKey = Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. FormatFailed = Une erreur interne est survenue lors du formatage du message suivant :\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_it.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_it.properties index 35b5be5ea63..c000e23df50 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_it.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_it.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 08:14:02 gmolloy Exp $ BadMessageKey = Impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. FormatFailed = Si \u00E8 verificato un errore interno durante la formattazione del seguente messaggio:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_ja.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_ja.properties index 4b0b83dfa96..e2f923e6181 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_ja.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_ja.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 01:05:12 gmolloy Exp $ BadMessageKey = \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 FormatFailed = \u6B21\u306E\u30E1\u30C3\u30BB\u30FC\u30B8\u306E\u66F8\u5F0F\u8A2D\u5B9A\u4E2D\u306B\u5185\u90E8\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_ko.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_ko.properties index d5b3b15eeba..bf3c87915fc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_ko.properties /st_wptg_1.9.dev.jdk/3 2016/07/14 00:25:31 gmolloy Exp $ BadMessageKey = \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. FormatFailed = \uB2E4\uC74C \uBA54\uC2DC\uC9C0\uC758 \uD615\uC2DD\uC744 \uC9C0\uC815\uD558\uB294 \uC911 \uB0B4\uBD80 \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4.\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_pt_BR.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_pt_BR.properties index 5054b344d37..ed9e73aa53f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_pt_BR.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_pt_BR.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 07:33:06 gmolloy Exp $ BadMessageKey = N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. FormatFailed = Ocorreu um erro interno ao formatar a mensagem a seguir:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_sv.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_sv.properties index 2558ec3a5ed..e97789688fe 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_sv.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_sv.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 00:46:23 gmolloy Exp $ BadMessageKey = Hittar inte felmeddelandet som motsvarar meddelandenyckeln. FormatFailed = Ett internt fel intr\u00E4ffade vid formatering av f\u00F6ljande meddelande:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_zh_CN.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_zh_CN.properties index ccc991a6e16..c59decb1b3d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_zh_CN.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_zh_CN.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:19:32 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 FormatFailed = \u8BBE\u7F6E\u4EE5\u4E0B\u6D88\u606F\u7684\u683C\u5F0F\u65F6\u51FA\u73B0\u5185\u90E8\u9519\u8BEF:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_zh_TW.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_zh_TW.properties index 4ae403e235f..05a943d80a2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_zh_TW.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DOMMessages_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # DOM implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DOMMessages_zh_TW.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 00:30:48 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u5C0D\u61C9\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 FormatFailed = \u683C\u5F0F\u5316\u4E0B\u5217\u8A0A\u606F\u6642\u767C\u751F\u5167\u90E8\u932F\u8AA4:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_de.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_de.properties index 14baff4c0cf..1d9f1a082fa 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_de.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_de.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:16:51 gmolloy Exp $ BadMessageKey = Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. FormatFailed = Beim Formatieren der folgenden Meldung ist ein interner Fehler aufgetreten:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_es.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_es.properties index 73bfbc7af94..e9dcc900a04 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_es.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_es.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 05:10:53 gmolloy Exp $ BadMessageKey = No se ha encontrado el mensaje de error correspondiente a la clave de mensaje. FormatFailed = Se ha producido un error interno al formatear el siguiente mensaje:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_fr.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_fr.properties index e45255b69b2..231b13d8952 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_fr.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_fr.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 02:16:52 gmolloy Exp $ BadMessageKey = Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. FormatFailed = Une erreur interne est survenue lors du formatage du message suivant :\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_it.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_it.properties index e08b8e0870c..4793921f9d4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_it.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_it.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 08:14:02 gmolloy Exp $ BadMessageKey = Impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. FormatFailed = Si \u00E8 verificato un errore interno durante la formattazione del seguente messaggio:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_ja.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_ja.properties index 1cfe77062cc..84d90d0fd41 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_ja.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_ja.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 01:05:12 gmolloy Exp $ BadMessageKey = \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 FormatFailed = \u6B21\u306E\u30E1\u30C3\u30BB\u30FC\u30B8\u306E\u66F8\u5F0F\u8A2D\u5B9A\u4E2D\u306B\u5185\u90E8\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_ko.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_ko.properties index bbc91843e32..837faae29cb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_ko.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 02:40:33 gmolloy Exp $ BadMessageKey = \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. FormatFailed = \uB2E4\uC74C \uBA54\uC2DC\uC9C0\uC758 \uD615\uC2DD\uC744 \uC9C0\uC815\uD558\uB294 \uC911 \uB0B4\uBD80 \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4.\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_pt_BR.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_pt_BR.properties index 8f836ee7b0e..e617790c015 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_pt_BR.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_pt_BR.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 07:33:06 gmolloy Exp $ BadMessageKey = N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. FormatFailed = Ocorreu um erro interno ao formatar a mensagem a seguir:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_sv.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_sv.properties index 4778bdabbc6..122e0add0b7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_sv.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_sv.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 00:46:23 gmolloy Exp $ BadMessageKey = Hittar inte felmeddelandet som motsvarar meddelandenyckeln. FormatFailed = Ett internt fel intr\u00E4ffade vid formatering av f\u00F6ljande meddelande:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_zh_CN.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_zh_CN.properties index 19950952522..21a3e3c9919 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_zh_CN.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_zh_CN.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:19:32 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 FormatFailed = \u8BBE\u7F6E\u4EE5\u4E0B\u6D88\u606F\u7684\u683C\u5F0F\u65F6\u51FA\u73B0\u5185\u90E8\u9519\u8BEF:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_zh_TW.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_zh_TW.properties index 43873ec65ec..cb23f872a1b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_zh_TW.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/DatatypeMessages_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Datatype API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: DatatypeMessages_zh_TW.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/11 20:46:43 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u5C0D\u61C9\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 FormatFailed = \u683C\u5F0F\u5316\u4E0B\u5217\u8A0A\u606F\u6642\u767C\u751F\u5167\u90E8\u932F\u8AA4:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_de.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_de.properties index 51417ac6a21..d9a740adbd8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_de.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_de.properties /st_wptg_1.8.0.0.0jdk/4 2013/11/10 07:44:26 gmolloy Exp $ # Messages for message reporting BadMessageKey = Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_es.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_es.properties index 9c02b32abf9..0bac87ccbf3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_es.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_es.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 05:10:53 gmolloy Exp $ # Messages for message reporting BadMessageKey = No se ha encontrado el mensaje de error correspondiente a la clave de mensaje. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_fr.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_fr.properties index 9e12758e6bb..a48dd9437df 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_fr.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_fr.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 02:16:52 gmolloy Exp $ # Messages for message reporting BadMessageKey = Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_it.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_it.properties index 53c2ae00f51..8829cf1e019 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_it.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_it.properties /st_wptg_1.8.0.0.0jdk/3 2013/09/16 07:02:00 gmolloy Exp $ # Messages for message reporting BadMessageKey = Impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_ja.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_ja.properties index 122feead430..86120a72476 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_ja.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_ja.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 01:05:12 gmolloy Exp $ # Messages for message reporting BadMessageKey = \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_ko.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_ko.properties index 8f01010d5d1..bfdcfcb8e60 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_ko.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 02:40:33 gmolloy Exp $ # Messages for message reporting BadMessageKey = \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_pt_BR.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_pt_BR.properties index 0ec9da84643..47ba42f6d4d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_pt_BR.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_pt_BR.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 07:33:06 gmolloy Exp $ # Messages for message reporting BadMessageKey = N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_sv.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_sv.properties index 83884aeb7c8..22556779bfc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_sv.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_sv.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 00:46:23 gmolloy Exp $ # Messages for message reporting BadMessageKey = Hittar inte felmeddelandet som motsvarar meddelandenyckeln. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_zh_CN.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_zh_CN.properties index 757845f41ba..9cc5ccb25f2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_zh_CN.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_zh_CN.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:19:32 gmolloy Exp $ # Messages for message reporting BadMessageKey = \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_zh_TW.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_zh_TW.properties index 4d78213a044..f0ee4f06be3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_zh_TW.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/JAXPValidationMessages_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces JAXP Validation API implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: JAXPValidationMessages_zh_TW.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 00:30:48 gmolloy Exp $ # Messages for message reporting BadMessageKey = \u627E\u4E0D\u5230\u5C0D\u61C9\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_de.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_de.properties index 78add948a60..2b99e3461e1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_de.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_de.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:16:51 gmolloy Exp $ BadMessageKey = Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_es.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_es.properties index 60d5cfe3f74..5493f01cfc0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_es.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_es.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 05:10:53 gmolloy Exp $ BadMessageKey = No se ha encontrado el mensaje de error correspondiente a la clave de mensaje. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_fr.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_fr.properties index 97e7f3d98c1..17cecded65e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_fr.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_fr.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 02:16:52 gmolloy Exp $ BadMessageKey = Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_it.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_it.properties index 773b9a2d8d9..c779be68515 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_it.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_it.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 08:14:02 gmolloy Exp $ BadMessageKey = Impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_ja.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_ja.properties index 5301c2f2ca7..21978c587cb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_ja.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_ja.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 01:05:12 gmolloy Exp $ BadMessageKey = \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_ko.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_ko.properties index 032a96d1e5a..8661c80776d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_ko.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 02:40:33 gmolloy Exp $ BadMessageKey = \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. @@ -51,11 +49,11 @@ jaxp-secureprocessing-feature = FEATURE_SECURE_PROCESSING: \uBCF4\uC548 \uAD00\u property-not-supported = ''{0}'' \uC18D\uC131\uC740 \uC9C0\uC6D0\uB418\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4. property-not-recognized = ''{0}'' \uC18D\uC131\uC744 \uC778\uC2DD\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. property-read-only = ''{0}'' \uC18D\uC131\uC740 \uC77D\uAE30 \uC804\uC6A9\uC785\uB2C8\uB2E4. -property-not-parsing-supported = \uAD6C\uBB38 \uBD84\uC11D \uC911 ''{0}'' \uC18D\uC131\uC740 \uC9C0\uC6D0\uB418\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4. +property-not-parsing-supported = \uAD6C\uBB38\uBD84\uC11D \uC911 ''{0}'' \uC18D\uC131\uC740 \uC9C0\uC6D0\uB418\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4. dom-node-read-not-supported = DOM \uB178\uB4DC \uC18D\uC131\uC744 \uC77D\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. DOM \uD2B8\uB9AC\uAC00 \uC874\uC7AC\uD558\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4. incompatible-class = ''{0}'' \uC18D\uC131\uC5D0 \uB300\uD574 \uC9C0\uC815\uB41C \uAC12\uC758 \uB370\uC774\uD130\uD615\uC744 {1}(\uC73C)\uB85C \uBCC0\uD658\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. start-document-not-called="{0}" \uC18D\uC131\uC740 startDocument \uC774\uBCA4\uD2B8\uAC00 \uBC1C\uC0DD\uB41C \uD6C4 \uD638\uCD9C\uD574\uC57C \uD569\uB2C8\uB2E4. nullparameter="{0}"\uC5D0 \uB300\uD55C \uC774\uB984 \uB9E4\uAC1C\uBCC0\uC218\uAC00 \uB110\uC785\uB2C8\uB2E4. -errorHandlerNotSet=\uACBD\uACE0: \uAC80\uC99D\uC774 \uC124\uC815\uB418\uC5C8\uC9C0\uB9CC org.xml.sax.ErrorHandler\uAC00 \uC801\uC808\uD788 \uC124\uC815\uB418\uC9C0 \uC54A\uC558\uC2B5\uB2C8\uB2E4. \uAD6C\uBB38 \uBD84\uC11D\uAE30\uAC00 \uAE30\uBCF8 ErrorHandler\uB97C \uC0AC\uC6A9\uD558\uC5EC \uCC98\uC74C {0}\uAC1C\uC758 \uC624\uB958\uB97C \uC778\uC1C4\uD569\uB2C8\uB2E4. \uC774 \uC624\uB958\uB97C \uC218\uC815\uD558\uB824\uBA74 ''setErrorHandler'' \uBA54\uC18C\uB4DC\uB97C \uD638\uCD9C\uD558\uC2ED\uC2DC\uC624. +errorHandlerNotSet=\uACBD\uACE0: \uAC80\uC99D\uC774 \uC124\uC815\uB418\uC5C8\uC9C0\uB9CC org.xml.sax.ErrorHandler\uAC00 \uC801\uC808\uD788 \uC124\uC815\uB418\uC9C0 \uC54A\uC558\uC2B5\uB2C8\uB2E4. \uAD6C\uBB38\uBD84\uC11D\uAE30\uAC00 \uAE30\uBCF8 ErrorHandler\uB97C \uC0AC\uC6A9\uD558\uC5EC \uCC98\uC74C {0}\uAC1C\uC758 \uC624\uB958\uB97C \uC778\uC1C4\uD569\uB2C8\uB2E4. \uC774 \uC624\uB958\uB97C \uC218\uC815\uD558\uB824\uBA74 ''setErrorHandler'' \uBA54\uC18C\uB4DC\uB97C \uD638\uCD9C\uD558\uC2ED\uC2DC\uC624. errorHandlerDebugMsg=\uC624\uB958: URI = "{0}", \uD589 = "{1}", : {2} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_pt_BR.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_pt_BR.properties index 3641fecd907..6e708459485 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_pt_BR.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_pt_BR.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/12 18:01:34 gmolloy Exp $ BadMessageKey = N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_sv.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_sv.properties index b4f1f001afe..5088946e609 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_sv.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_sv.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/14 01:57:20 gmolloy Exp $ BadMessageKey = Hittar inte felmeddelandet som motsvarar meddelandenyckeln. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_zh_CN.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_zh_CN.properties index 4c425d1705d..cc07506f888 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_zh_CN.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_zh_CN.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:19:32 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_zh_TW.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_zh_TW.properties index 7ee58dcddbf..91902b973b7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_zh_TW.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/SAXMessages_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,6 @@ # SAX implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: SAXMessages_zh_TW.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 00:30:48 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u5C0D\u61C9\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XIncludeMessages_sv.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XIncludeMessages_sv.properties index c75a115c60e..39c17b93689 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XIncludeMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XIncludeMessages_sv.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -58,4 +58,4 @@ XPointerResolutionUnsuccessful = XPointer-matchningen utf\u00F6rdes inte. # Messages from erroneous set-up IncompatibleNamespaceContext = Typ av NamespaceContext \u00E4r inkompatibel med XInclude; det kr\u00E4vs en instans av XIncludeNamespaceSupport -ExpandedSystemId = Kunde inte ut\u00F6ka system-ID:t f\u00F6r inkluderad resurs +ExpandedSystemId = Kunde inte ut\u00F6ka system-id:t f\u00F6r inkluderad resurs diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter.java index 0f7ed95d5a8..8b43cd8eea3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_de.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_de.java index 24c5e41d4d7..1143ec50d59 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_de.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_de.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_es.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_es.java index 5dab448b1fb..f8736142b5c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_es.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_es.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_fr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_fr.java index 1b4974a2e8c..44e4b81e634 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_fr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_fr.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_it.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_it.java index 66d1b90951c..a51cf7ff21c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_it.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_it.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_ja.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_ja.java index 14363761574..cb937402da3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_ja.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_ja.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_ko.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_ko.java index a042bdd9afe..7c01962539d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_ko.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_ko.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_pt_BR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_pt_BR.java index 053445dc06a..1ca2c852391 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_pt_BR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_pt_BR.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_sv.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_sv.java index bb4d9531d38..154c8da8e6f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_sv.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_sv.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_zh_CN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_zh_CN.java index 13f6be55cb6..4b51f3566bf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_zh_CN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_zh_CN.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_zh_TW.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_zh_TW.java index 1965d571783..24508579774 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_zh_TW.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessageFormatter_zh_TW.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessages_ko.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessages_ko.properties index a7ab6af1571..06c2fafbe3e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLMessages_ko.properties @@ -295,7 +295,7 @@ # Implementation limits - EntityExpansionLimit=JAXP00010001: \uAD6C\uBB38 \uBD84\uC11D\uAE30\uAC00 \uC774 \uBB38\uC11C\uC5D0\uC11C "{0}"\uAC1C\uB97C \uCD08\uACFC\uD558\uB294 \uC5D4\uD2F0\uD2F0 \uD655\uC7A5\uC744 \uBC1C\uACAC\uD588\uC2B5\uB2C8\uB2E4. \uC774\uB294 JDK\uC5D0\uC11C \uC801\uC6A9\uD558\uB294 \uC81C\uD55C\uC785\uB2C8\uB2E4. + EntityExpansionLimit=JAXP00010001: \uAD6C\uBB38\uBD84\uC11D\uAE30\uAC00 \uC774 \uBB38\uC11C\uC5D0\uC11C "{0}"\uAC1C\uB97C \uCD08\uACFC\uD558\uB294 \uC5D4\uD2F0\uD2F0 \uD655\uC7A5\uC744 \uBC1C\uACAC\uD588\uC2B5\uB2C8\uB2E4. \uC774\uB294 JDK\uC5D0\uC11C \uC801\uC6A9\uD558\uB294 \uC81C\uD55C\uC785\uB2C8\uB2E4. ElementAttributeLimit=JAXP00010002: "{0}" \uC694\uC18C\uC5D0 "{1}"\uAC1C\uB97C \uCD08\uACFC\uD558\uB294 \uC18D\uC131\uC774 \uC788\uC2B5\uB2C8\uB2E4. "{1}"\uC740(\uB294) JDK\uC5D0\uC11C \uC801\uC6A9\uD558\uB294 \uC81C\uD55C\uC785\uB2C8\uB2E4. MaxEntitySizeLimit=JAXP00010003: "{0}" \uC5D4\uD2F0\uD2F0\uC758 \uAE38\uC774\uAC00 "{3}"\uC5D0\uC11C \uC124\uC815\uB41C "{2}" \uC81C\uD55C\uC744 \uCD08\uACFC\uD558\uB294 "{1}"\uC785\uB2C8\uB2E4. TotalEntitySizeLimit=JAXP00010004: \uC5D4\uD2F0\uD2F0\uC758 \uB204\uC801 \uD06C\uAE30\uAC00 "{2}"\uC5D0\uC11C \uC124\uC815\uD55C "{1}" \uC81C\uD55C\uC744 \uCD08\uACFC\uD558\uB294 "{0}"\uC785\uB2C8\uB2E4. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_de.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_de.properties index dd6e309b21a..7c864068a94 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_de.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_de.properties /st_wptg_1.9.dev.jdk/2 2016/06/08 01:51:09 gmolloy Exp $ BadMessageKey = Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. FormatFailed = Beim Formatieren der folgenden Meldung ist ein interner Fehler aufgetreten:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_es.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_es.properties index edbc9c3460c..3d2f34114f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_es.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_es.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/14 05:09:25 gmolloy Exp $ BadMessageKey = No se ha encontrado el mensaje de error correspondiente a la clave de mensaje. FormatFailed = Se ha producido un error interno al formatear el siguiente mensaje:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_fr.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_fr.properties index 5a539598eec..8c56325eaac 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_fr.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_fr.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/12 05:13:35 gmolloy Exp $ BadMessageKey = Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. FormatFailed = Une erreur interne est survenue lors du formatage du message suivant :\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_it.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_it.properties index 06c792ea58d..00ae985aef6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_it.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_it.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/12 03:53:19 gmolloy Exp $ BadMessageKey = Impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. FormatFailed = Si \u00E8 verificato un errore interno durante la formattazione del seguente messaggio:\n @@ -137,7 +135,7 @@ src-element.2.2 = src-element.2.2: poich\u00E9 ''{0}'' contiene l''attributo ''ref'', il suo contenuto deve corrispondere a (annotation?), ma \u00E8 stato trovato ''{1}''. src-element.3 = src-element.3: l''elemento "{0}" ha sia un attributo ''type'' che un elemento figlio "anonymous type". \u00C8 consentito uno solo di questi valori per un elemento. src-import.1.1 = src-import.1.1: l''attributo "{0}" dello spazio di nomi di una voce di informazioni di elemento non deve essere uguale al targetNamespace dello schema in cui esiste. - src-import.1.2 = src-import.1.2: se l''attributo dello spazio di nomi non \u00E8 presente in una voce di informazioni di elemento , lo schema che lo contiene deve avere un targetNamespace. + src-import.1.2 = src-import.1.2: se l'attributo dello spazio di nomi non \u00E8 presente in una voce di informazioni di elemento , lo schema che lo contiene deve avere un targetNamespace. src-import.2 = src-import.2: l''elemento radice del documento "{0}" deve avere lo spazio di nomi denominato ''http://www.w3.org/2001/XMLSchema'' e il nome locale ''schema''. src-import.3.1 = src-import.3.1: l''attributo "{0}" dello spazio di nomi di una voce di informazioni di elemento deve essere uguale all''attributo targetNamespace ''{1}'' del documento importato. src-import.3.2 = src-import.3.2: non esiste alcun attributo dello spazio di nomi nella voce di informazioni di elemento , pertanto il documento importato non pu\u00F2 avere alcun attributo targetNamespace. tuttavia, \u00E8 stato trovato targetNamespace ''{1}'' nel documento importato. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_ja.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_ja.properties index 63997f8fe22..cd27296e8ef 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_ja.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_ja.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/12 00:37:07 gmolloy Exp $ BadMessageKey = \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 FormatFailed = \u6B21\u306E\u30E1\u30C3\u30BB\u30FC\u30B8\u306E\u66F8\u5F0F\u8A2D\u5B9A\u4E2D\u306B\u5185\u90E8\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_ko.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_ko.properties index 52ab2b4df2c..84874334eb4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_ko.properties /st_wptg_1.9.dev.jdk/3 2016/07/14 00:25:31 gmolloy Exp $ BadMessageKey = \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. FormatFailed = \uB2E4\uC74C \uBA54\uC2DC\uC9C0\uC758 \uD615\uC2DD\uC744 \uC9C0\uC815\uD558\uB294 \uC911 \uB0B4\uBD80 \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4.\n @@ -218,7 +216,7 @@ e-props-correct.2 = e-props-correct.2: ''{0}'' \uC694\uC18C\uC758 \uAC12 \uC81C\uC57D \uC870\uAC74 \uAC12 ''{1}''\uC774(\uAC00) \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. e-props-correct.4 = e-props-correct.4: ''{0}'' \uC694\uC18C\uC758 '{'type definition'}'\uC774 substitutionHead ''{1}''\uC758 '{'type definition'}'\uC5D0\uC11C \uC801\uD569\uD558\uAC8C \uD30C\uC0DD\uB41C \uAC83\uC774 \uC544\uB2C8\uAC70\uB098 ''{1}''\uC758 '{'substitution group exclusions'}' \uC18D\uC131\uC774 \uC774 \uD30C\uC0DD\uC744 \uD5C8\uC6A9\uD558\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4. e-props-correct.5 = e-props-correct.5: \uC694\uC18C\uC758 '{'type definition'}' \uB610\uB294 '{'type definition'}'\uC758 '{'content type'}'\uC774 ID\uC774\uAC70\uB098 ID\uC5D0\uC11C \uD30C\uC0DD\uB41C \uAC83\uC774\uBBC0\uB85C '{'value constraint'}'\uB294 ''{0}'' \uC694\uC18C\uC5D0 \uC5C6\uC5B4\uC57C \uD569\uB2C8\uB2E4. - e-props-correct.6 = e-props-correct.6: ''{0}'' \uC694\uC18C\uC5D0 \uB300\uD55C \uC21C\uD658 \uB300\uCCB4 \uADF8\uB8F9\uC774 \uAC10\uC9C0\uB418\uC5C8\uC2B5\uB2C8\uB2E4.. + e-props-correct.6 = e-props-correct.6: ''{0}'' \uC694\uC18C\uC5D0 \uB300\uD55C \uC21C\uD658 \uB300\uCCB4 \uADF8\uB8F9\uC774 \uAC10\uC9C0\uB418\uC5C8\uC2B5\uB2C8\uB2E4. fractionDigits-valid-restriction = fractionDigits-valid-restriction: {2}\uC758 \uC815\uC758\uC5D0\uC11C ''fractionDigits'' \uBA74\uC5D0 \uB300\uD55C ''{0}'' \uAC12\uC774 \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. \uC774 \uAC12\uC740 \uC870\uC0C1 \uC720\uD615 \uC911 \uD558\uB098\uC5D0\uC11C ''{1}''(\uC73C)\uB85C \uC124\uC815\uB41C ''fractionDigits''\uC5D0 \uB300\uD55C \uAC12\uBCF4\uB2E4 \uC791\uAC70\uB098 \uAC19\uC544\uC57C \uD569\uB2C8\uB2E4. fractionDigits-totalDigits = fractionDigits-totalDigits: {2}\uC758 \uC815\uC758\uC5D0\uC11C ''fractionDigits'' \uBA74\uC5D0 \uB300\uD55C ''{0}'' \uAC12\uC774 \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. \uC774 \uAC12\uC740 ''totalDigits''\uC5D0 \uB300\uD55C \uAC12\uC778 ''{1}''\uBCF4\uB2E4 \uC791\uAC70\uB098 \uAC19\uC544\uC57C \uD569\uB2C8\uB2E4. length-minLength-maxLength.1.1 = length-minLength-maxLength.1.1: {0} \uC720\uD615\uC758 \uACBD\uC6B0 length ''{1}''\uC758 \uAC12\uC740 minLength ''{2}''\uC758 \uAC12\uBCF4\uB2E4 \uC791\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. @@ -314,7 +312,7 @@ FacetValueFromBase = FacetValueFromBase: ''{0}'' \uC720\uD615\uC758 \uC120\uC5B8\uC5D0\uC11C ''{2}'' \uBA74\uC758 ''{1}'' \uAC12\uC740 \uAE30\uBCF8 \uC720\uD615 ''{3}''\uC758 \uAC12 \uACF5\uBC31\uC5D0\uC11C \uC640\uC57C \uD569\uB2C8\uB2E4. FixedFacetValue = FixedFacetValue: {3}\uC758 \uC815\uC758\uC5D0\uC11C ''{0}'' \uBA74\uC5D0 \uB300\uD55C ''{1}'' \uAC12\uC774 \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. ''{0}''\uC5D0 \uB300\uD55C \uAC12\uC774 \uC870\uC0C1 \uC720\uD615 \uC911 \uD558\uB098\uC5D0\uC11C ''{2}''(\uC73C)\uB85C \uC124\uC815\uB418\uC5C8\uC73C\uBA70 '{'fixed'}' = true\uC774\uAE30 \uB54C\uBB38\uC785\uB2C8\uB2E4. InvalidRegex = InvalidRegex: \uD328\uD134 \uAC12 ''{0}''\uC740(\uB294) \uC801\uD569\uD55C \uC815\uADDC \uD45C\uD604\uC2DD\uC774 \uC544\uB2D9\uB2C8\uB2E4. ''{2}'' \uC5F4\uC5D0\uC11C ''{1}'' \uC624\uB958\uAC00 \uBCF4\uACE0\uB418\uC5C8\uC2B5\uB2C8\uB2E4. - MaxOccurLimit = \uAD6C\uBB38 \uBD84\uC11D\uAE30\uC758 \uD604\uC7AC \uAD6C\uC131\uC5D0\uC11C maxOccurs \uC18D\uC131\uAC12\uC744 {0} \uAC12\uBCF4\uB2E4 \uD06C\uAC8C \uC124\uC815\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. + MaxOccurLimit = \uAD6C\uBB38\uBD84\uC11D\uAE30\uC758 \uD604\uC7AC \uAD6C\uC131\uC5D0\uC11C maxOccurs \uC18D\uC131\uAC12\uC744 {0} \uAC12\uBCF4\uB2E4 \uD06C\uAC8C \uC124\uC815\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. PublicSystemOnNotation = PublicSystemOnNotation: \uD558\uB098 \uC774\uC0C1\uC758 ''public''\uACFC ''system''\uC774 ''notation'' \uC694\uC18C\uC5D0 \uB098\uD0C0\uB098\uC57C \uD569\uB2C8\uB2E4. SchemaLocation = SchemaLocation: schemaLocation \uAC12 = ''{0}''\uC5D0\uB294 \uC9DD\uC218 \uAC1C\uC758 URI\uAC00 \uC788\uC5B4\uC57C \uD569\uB2C8\uB2E4. TargetNamespace.1 = TargetNamespace.1: ''{0}'' \uB124\uC784\uC2A4\uD398\uC774\uC2A4\uAC00 \uD544\uC694\uD558\uC9C0\uB9CC \uC2A4\uD0A4\uB9C8 \uBB38\uC11C\uC758 \uB300\uC0C1 \uB124\uC784\uC2A4\uD398\uC774\uC2A4\uAC00 ''{1}''\uC785\uB2C8\uB2E4. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_pt_BR.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_pt_BR.properties index 0abad5e3812..ac226e02e25 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_pt_BR.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_pt_BR.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/12 18:01:34 gmolloy Exp $ BadMessageKey = N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. FormatFailed = Ocorreu um erro interno ao formatar a mensagem a seguir:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_sv.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_sv.properties index eeaf7782718..dd04e72f5ae 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_sv.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_sv.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/14 01:57:20 gmolloy Exp $ BadMessageKey = Hittar inte felmeddelandet som motsvarar meddelandenyckeln. FormatFailed = Ett internt fel intr\u00E4ffade vid formatering av f\u00F6ljande meddelande:\n @@ -111,7 +109,7 @@ cvc-totalDigits-valid = cvc-totalDigits-valid: V\u00E4rdet ''{0}'' har {1} siffror, men det totala antalet siffror \u00E4r begr\u00E4nsat till {2}. cvc-type.1 = cvc-type.1: Typdefinitionen ''{0}'' hittades inte. cvc-type.2 = cvc-type.2: Typdefinitionen kan inte vara abstrakt f\u00F6r elementet {0}. - cvc-type.3.1.1 = cvc-type.3.1.1: Elementet ''{0}'' har enkel typ och kan inte inneh\u00E5lla attribut, ut\u00F6ver s\u00E5dana vars namnrymd \u00E4r identisk med ''http://www.w3.org/2001/XMLSchema-instance'' och vars [lokala namn] har n\u00E5gotdera av ''type'', ''nil'', ''schemaLocation'' eller ''noNamespaceSchemaLocation''. Hittade dock attributet ''{1}''. + cvc-type.3.1.1 = cvc-type.3.1.1: Elementet ''{0}'' har enkel typ och f\u00E5r inte inneh\u00E5lla attribut, ut\u00F6ver s\u00E5dana vars namnrymd \u00E4r identisk med ''http://www.w3.org/2001/XMLSchema-instance'' och vars [lokala namn] har n\u00E5gotdera av ''type'', ''nil'', ''schemaLocation'' eller ''noNamespaceSchemaLocation''. Hittade dock attributet ''{1}''. cvc-type.3.1.2 = cvc-type.3.1.2: Elementet ''{0}'' har enkel typ och f\u00E5r inte inneh\u00E5lla [underordnade] med elementinformation. cvc-type.3.1.3 = cvc-type.3.1.3: V\u00E4rdet ''{1}'' i elementet ''{0}'' \u00E4r ogiltigt. @@ -282,7 +280,7 @@ rcase-RecurseUnordered.2 = rcase-RecurseUnordered.2: Det finns ingen fullst\u00E4ndigt fungerande mappning mellan partiklarna. # We're using sch-props-correct.2 instead of the old src-redefine.1 # src-redefine.1 = src-redefine.1: The component ''{0}'' is begin redefined, but its corresponding component isn't in the schema document being redefined (with namespace ''{2}''), but in a different document, with namespace ''{1}''. - sch-props-correct.2 = sch-props-correct.2: Ett schema kan inte inneh\u00E5lla tv\u00E5 globala komponenter med samma namn. Detta schema har tv\u00E5 f\u00F6rekomster av ''{0}''. + sch-props-correct.2 = sch-props-correct.2: Ett schema f\u00E5r inte inneh\u00E5lla tv\u00E5 globala komponenter med samma namn. Detta schema har tv\u00E5 f\u00F6rekomster av ''{0}''. st-props-correct.2 = st-props-correct.2: Cirkul\u00E4ra definitioner har identifierats f\u00F6r enkel typ ''{0}''. Detta inneb\u00E4r att ''{0}'' ing\u00E5r i sin egen typhierarki, vilket \u00E4r fel. st-props-correct.3 = st-props-correct.3: Ett fel intr\u00E4ffade f\u00F6r typ ''{0}''. V\u00E4rdet f\u00F6r '{'slutgiltigt'}' i '{'bastypdefinitionen'}', ''{1}'', f\u00F6rbjuder h\u00E4rledning med begr\u00E4nsning. totalDigits-valid-restriction = totalDigits-valid-restriction: I definitionen f\u00F6r {2} \u00E4r v\u00E4rdet ''{0}'' f\u00F6r ''totalDigits'' ogiltigt eftersom det m\u00E5ste vara mindre \u00E4n eller lika med v\u00E4rdet f\u00F6r ''totalDigits'' som har angetts som ''{1}'' i n\u00E5gon typ f\u00F6r \u00F6verordnad. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_zh_CN.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_zh_CN.properties index bf51b628471..d3e03337546 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_zh_CN.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_zh_CN.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/13 05:10:27 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 FormatFailed = \u8BBE\u7F6E\u4EE5\u4E0B\u6D88\u606F\u7684\u683C\u5F0F\u65F6\u51FA\u73B0\u5185\u90E8\u9519\u8BEF:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_zh_TW.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_zh_TW.properties index 747036b9576..925a97306e0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_zh_TW.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSchemaMessages_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ # This file contains error and warning messages related to XML Schema # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XMLSchemaMessages_zh_TW.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/11 20:46:43 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u5C0D\u61C9\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 FormatFailed = \u683C\u5F0F\u5316\u4E0B\u5217\u8A0A\u606F\u6642\u767C\u751F\u5167\u90E8\u932F\u8AA4:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_de.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_de.properties index a279e879bd4..3c1d9d8282c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_de.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_de.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:16:51 gmolloy Exp $ BadMessageKey = Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. FormatFailed = Beim Formatieren der folgenden Meldung ist ein interner Fehler aufgetreten:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_es.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_es.properties index a06a1613092..4e6c0c62ed3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_es.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_es.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 05:10:53 gmolloy Exp $ BadMessageKey = No se ha encontrado el mensaje de error que corresponde a la clave de mensaje. FormatFailed = Se ha producido un error interno al formatear el siguiente mensaje:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_fr.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_fr.properties index a274f4be731..535f97ecc5b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_fr.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_fr.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 02:16:52 gmolloy Exp $ BadMessageKey = Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. FormatFailed = Une erreur interne est survenue lors de la mise en forme du message suivant :\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_it.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_it.properties index 114f1f47125..2798c1a2c17 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_it.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_it.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 08:14:02 gmolloy Exp $ BadMessageKey = Impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. FormatFailed = Si \u00E8 verificato un errore interno durante la formattazione del seguente messaggio:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_ja.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_ja.properties index c604e087580..341497c9a6f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_ja.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_ja.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 01:05:12 gmolloy Exp $ BadMessageKey = \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 FormatFailed = \u6B21\u306E\u30E1\u30C3\u30BB\u30FC\u30B8\u306E\u66F8\u5F0F\u8A2D\u5B9A\u4E2D\u306B\u5185\u90E8\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_ko.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_ko.properties index 0ff73562f3d..c09651c4e99 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_ko.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 02:40:33 gmolloy Exp $ BadMessageKey = \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. FormatFailed = \uB2E4\uC74C \uBA54\uC2DC\uC9C0\uC758 \uD615\uC2DD\uC744 \uC9C0\uC815\uD558\uB294 \uC911 \uB0B4\uBD80 \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4.\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_pt_BR.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_pt_BR.properties index e842306d2bb..29991ad2fc3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_pt_BR.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_pt_BR.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 07:33:06 gmolloy Exp $ BadMessageKey = N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. FormatFailed = Ocorreu um erro interno ao formatar a mensagem a seguir:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_sv.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_sv.properties index 68ad3bf3b8e..4f39063a0e6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_sv.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_sv.properties /st_wptg_1.9.0.0.0jdk/2 2016/04/14 01:57:20 gmolloy Exp $ BadMessageKey = Hittar inte felmeddelandet som motsvarar meddelandenyckeln. FormatFailed = Ett internt fel intr\u00E4ffade vid formatering av f\u00F6ljande meddelande:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_zh_CN.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_zh_CN.properties index c9888263168..d8b2eb0bba5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_zh_CN.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_zh_CN.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:19:32 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 FormatFailed = \u8BBE\u7F6E\u4EE5\u4E0B\u6D88\u606F\u7684\u683C\u5F0F\u65F6\u51FA\u73B0\u5185\u90E8\u9519\u8BEF:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_zh_TW.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_zh_TW.properties index c6dfc1606d2..28af1b88d66 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_zh_TW.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XMLSerializerMessages_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -29,8 +29,6 @@ # # As usual with properties files, the messages are arranged in # key/value tuples. -# -# @version $Id: XMLSerializerMessages_zh_TW.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 00:30:48 gmolloy Exp $ BadMessageKey = \u627E\u4E0D\u5230\u5C0D\u61C9\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 FormatFailed = \u683C\u5F0F\u5316\u4E0B\u5217\u8A0A\u606F\u6642\u767C\u751F\u5167\u90E8\u932F\u8AA4:\n diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_de.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_de.properties index 72d3bba7381..dc787a6cd3d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_de.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_de.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:16:51 gmolloy Exp $ # Messages for message reporting BadMessageKey = Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_es.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_es.properties index baa0b0d6fd4..3495022fe75 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_es.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_es.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 05:10:53 gmolloy Exp $ # Messages for message reporting BadMessageKey = No se ha encontrado el mensaje de error que corresponde a la clave de mensaje. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_fr.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_fr.properties index 9eb7cf0d3fc..a9fe2c41407 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_fr.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_fr.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 02:16:52 gmolloy Exp $ # Messages for message reporting BadMessageKey = Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_it.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_it.properties index d59616ea2d6..549797ba81e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_it.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,15 +26,13 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_it.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 08:14:02 gmolloy Exp $ # Messages for message reporting BadMessageKey = Impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. FormatFailed = Si \u00E8 verificato un errore interno durante la formattazione del seguente messaggio:\n # XPointer Framework Error Messages -XPointerProcessingError = XPointerProcessingError: si \u00E8 verificato un errore durante l'elaborazione dell''espressione XPointer. +XPointerProcessingError = XPointerProcessingError: si \u00E8 verificato un errore durante l'elaborazione dell'espressione XPointer. InvalidXPointerToken = InvalidXPointerToken: l''espressione XPointer contiene il token non valido ''{0}''. InvalidXPointerExpression = InvalidXPointerExpression: l''espressione XPointer ''{0}'' non \u00E8 valida. MultipleShortHandPointers = MultipleShortHandPointers: l''espressione XPointer ''{0}'' non \u00E8 valida. Contiene pi\u00F9 puntatori ShortHand. @@ -47,6 +45,6 @@ InvalidSchemeDataInXPointer = InvalidSchemeDataInXPointer: l''espressione XPoint # XPointer Element Scheme Error Messages InvalidElementSchemeToken = InvalidElementSchemeToken: l''espressione XPointer dello schema element() contiene il token non valido ''{0}''. InvalidElementSchemeXPointer = InvalidElementSchemeXPointer: l''espressione XPointer ''{0}'' dello schema di elemento non \u00E8 valida. -XPointerElementSchemeProcessingError = XPointerElementSchemeProcessingError: si \u00E8 verificato un errore durante l'elaborazione dell''espressione di schema element() XPointer. +XPointerElementSchemeProcessingError = XPointerElementSchemeProcessingError: si \u00E8 verificato un errore durante l'elaborazione dell'espressione di schema element() XPointer. InvalidNCNameInElementSchemeData = InvalidNCNameInElementSchemeData: lo schema element() contiene un puntatore ShortHand ''{0}'' con NCName non valido. InvalidChildSequenceCharacter = InvalidChildSequenceCharacter: lo schema element() contiene un carattere di sequenza secondaria ''{0}'' non valido. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_ja.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_ja.properties index 26a2a3eec83..e12a67655f8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_ja.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_ja.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 01:05:12 gmolloy Exp $ # Messages for message reporting BadMessageKey = \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_ko.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_ko.properties index 3f43bbd67bd..c86ecf6264c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_ko.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 02:40:33 gmolloy Exp $ # Messages for message reporting BadMessageKey = \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_pt_BR.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_pt_BR.properties index a4076986da3..34584b802ca 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_pt_BR.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_pt_BR.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/28 07:33:06 gmolloy Exp $ # Messages for message reporting BadMessageKey = N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_sv.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_sv.properties index 8444e131b9b..0e822f523f2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_sv.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_sv.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 00:46:23 gmolloy Exp $ # Messages for message reporting BadMessageKey = Hittar inte felmeddelandet som motsvarar meddelandenyckeln. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_zh_CN.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_zh_CN.properties index d2c2dc3220f..cbbaad08e7b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_zh_CN.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_zh_CN.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/29 01:19:32 gmolloy Exp $ # Messages for message reporting BadMessageKey = \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_zh_TW.properties b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_zh_TW.properties index 6c9bf142532..5b30e236a2e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_zh_TW.properties +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/msg/XPointerMessages_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,6 @@ # This file stores localized messages for the Xerces XPointer implementation. # # The messages are arranged in key and value tuples in a ListResourceBundle. -# -# @version $Id: XPointerMessages_zh_TW.properties /st_wptg_1.8.0.0.0jdk/2 2013/05/27 00:30:48 gmolloy Exp $ # Messages for message reporting BadMessageKey = \u627E\u4E0D\u5230\u5C0D\u61C9\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/validation/EntityState.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/validation/EntityState.java index 86a921599bb..43b127db599 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/validation/EntityState.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/validation/EntityState.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/validation/ValidationManager.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/validation/ValidationManager.java index 67e9535e1e1..664f13b5094 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/validation/ValidationManager.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/validation/ValidationManager.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/SchemaNamespaceSupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/SchemaNamespaceSupport.java index 59098752d48..aca31d1e770 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/SchemaNamespaceSupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/SchemaNamespaceSupport.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/SchemaSymbols.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/SchemaSymbols.java index 2e8205c3c25..f49a1aa8595 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/SchemaSymbols.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/SchemaSymbols.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XMLSchemaException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XMLSchemaException.java index 48bc733d7fe..73a1cfdace8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XMLSchemaException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XMLSchemaException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.xs; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSAnnotationImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSAnnotationImpl.java index e6e933c0586..cc1d1fc9af3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSAnnotationImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSAnnotationImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.xs; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSAttributeGroupDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSAttributeGroupDecl.java index fda0899f9da..17466ca2139 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSAttributeGroupDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSAttributeGroupDecl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSDDescription.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSDDescription.java index 2e25ec81fe3..c7c145f3378 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSDDescription.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSDDescription.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002, 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSDeclarationPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSDeclarationPool.java index 604f50da504..6f1e6e8a171 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSDeclarationPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSDeclarationPool.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSGroupDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSGroupDecl.java index 3c51b0c5004..09af982f797 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSGroupDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSGroupDecl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSImplementationImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSImplementationImpl.java index 8cf0c4ab84c..222e0fb6c3b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSImplementationImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSImplementationImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSLoaderImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSLoaderImpl.java index 1740d758e4a..c525762ce7b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSLoaderImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSLoaderImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSMessageFormatter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSMessageFormatter.java index 236b7962373..1a5f092b7ff 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSMessageFormatter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSMessageFormatter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSModelGroupImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSModelGroupImpl.java index 8f63830c7a6..3366f5c98f9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSModelGroupImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSModelGroupImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2003-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSNotationDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSNotationDecl.java index c34f16b8f88..bf744909beb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSNotationDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSNotationDecl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSParticleDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSParticleDecl.java index cb2ba9a5066..71674fd5b61 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSParticleDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSParticleDecl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSWildcardDecl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSWildcardDecl.java index b56db22ba14..f9b181d1200 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSWildcardDecl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSWildcardDecl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/IdentityConstraint.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/IdentityConstraint.java index d62dc05102d..51c9e09f82c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/IdentityConstraint.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/IdentityConstraint.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/KeyRef.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/KeyRef.java index 4058b505cb3..42000756643 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/KeyRef.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/KeyRef.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/Selector.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/Selector.java index 283e6c1f153..6bda1ea4c97 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/Selector.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/Selector.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/UniqueOrKey.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/UniqueOrKey.java index a86c6648790..57ff9d0f74f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/UniqueOrKey.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/UniqueOrKey.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/XPathMatcher.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/XPathMatcher.java index d8789329b93..48f0cb3c8ed 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/XPathMatcher.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/identity/XPathMatcher.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/CMNodeFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/CMNodeFactory.java index db1d0b7adeb..bde742b5303 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/CMNodeFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/CMNodeFactory.java @@ -2,11 +2,12 @@ * Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 2003-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMBinOp.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMBinOp.java index be62f389c5a..a0bb375a0dc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMBinOp.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMBinOp.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMLeaf.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMLeaf.java index 9359d21e33e..a11458a6029 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMLeaf.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMLeaf.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMUniOp.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMUniOp.java index 87b05964c8d..8fcd9bcdc31 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMUniOp.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/models/XSCMUniOp.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/AttrImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/AttrImpl.java index 89c70ebc0fa..e1a330bdc6b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/AttrImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/AttrImpl.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2001, 2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 2001, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.impl.xs.opti; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultDocument.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultDocument.java index 8322e871e5f..e3cd700ab55 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultDocument.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultDocument.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultElement.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultElement.java index c4db6d8d508..ae9a1bd2b9b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultElement.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultElement.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultNode.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultNode.java index 1509663c119..d424f7c7178 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultNode.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultNode.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultText.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultText.java index 4f750b11888..fc370dcb505 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultText.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultText.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultXMLDocumentHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultXMLDocumentHandler.java index dd0ac9b33c7..84aaf912ff9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultXMLDocumentHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/DefaultXMLDocumentHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/ElementImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/ElementImpl.java index 28a6bd678b2..7b17e2b6efa 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/ElementImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/ElementImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/NamedNodeMapImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/NamedNodeMapImpl.java index d332999c4ea..df56eca250d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/NamedNodeMapImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/NamedNodeMapImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/NodeImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/NodeImpl.java index 5562c9f91a0..6b46b9da7b9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/NodeImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/NodeImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaDOM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaDOM.java index 52ed98f24d9..e37e56d5812 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaDOM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaDOM.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaDOMParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaDOMParser.java index b8e1d54959e..aa94cf2590a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaDOMParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/SchemaDOMParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/TextImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/TextImpl.java index 3476e648dd0..2af2c6d2fcf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/TextImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/opti/TextImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/SchemaContentHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/SchemaContentHandler.java index 1a7ca147680..f603ddf6d61 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/SchemaContentHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/SchemaContentHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSAnnotationInfo.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSAnnotationInfo.java index 1ec7741e199..b197eb0bf76 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSAnnotationInfo.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSAnnotationInfo.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.xs.traversers; import org.w3c.dom.Element; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSAttributeChecker.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSAttributeChecker.java index 816cdaa4757..ddd4558aaba 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSAttributeChecker.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSAttributeChecker.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractIDConstraintTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractIDConstraintTraverser.java index af38b2f73f6..aa863a5f4e7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractIDConstraintTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractIDConstraintTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractParticleTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractParticleTraverser.java index 0a0569a1fc2..8b15fece6a2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractParticleTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractParticleTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractTraverser.java index 7af4c66754d..c493ac2587a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAbstractTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAttributeGroupTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAttributeGroupTraverser.java index 14d15309ea9..5ad2deeb7d5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAttributeGroupTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAttributeGroupTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.xs.traversers; import com.sun.org.apache.xerces.internal.impl.xs.SchemaGrammar; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAttributeTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAttributeTraverser.java index 6174a7b5ec3..1988e70ba7d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAttributeTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDAttributeTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDComplexTypeTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDComplexTypeTraverser.java index b786158ac7c..0c7d663363f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDComplexTypeTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDComplexTypeTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.xs.traversers; import com.sun.org.apache.xerces.internal.impl.dv.InvalidDatatypeFacetException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDElementTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDElementTraverser.java index e0e4c464c21..9ee9159cbb9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDElementTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDElementTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDGroupTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDGroupTraverser.java index 99e2ec99319..06d51f8aa55 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDGroupTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDGroupTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.impl.xs.traversers; import com.sun.org.apache.xerces.internal.impl.xs.SchemaGrammar; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDKeyrefTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDKeyrefTraverser.java index 7d590acf55f..a70bb70a119 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDKeyrefTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDKeyrefTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDNotationTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDNotationTraverser.java index 27acd055d2f..fd562173fb4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDNotationTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDNotationTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDUniqueOrKeyTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDUniqueOrKeyTraverser.java index 2e36be5745e..c3382725541 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDUniqueOrKeyTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDUniqueOrKeyTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDWildcardTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDWildcardTraverser.java index c368b74ccfd..36a04c322a4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDWildcardTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDWildcardTraverser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDocumentInfo.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDocumentInfo.java index b941ea90236..c2ea37b7073 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDocumentInfo.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/traversers/XSDocumentInfo.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/ShortListImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/ShortListImpl.java index 9dc0641ef26..0491444b6d3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/ShortListImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/ShortListImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2003-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/SimpleLocator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/SimpleLocator.java index a38405eb056..55a4d6674a2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/SimpleLocator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/SimpleLocator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002, 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/StringListImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/StringListImpl.java index cf3d46a494e..e8df031747a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/StringListImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/StringListImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2003-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XInt.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XInt.java index 68aa63c326a..53c4950c47c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XInt.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XInt.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XIntPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XIntPool.java index 821f3996217..3d9b7aa9908 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XIntPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XIntPool.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSGrammarPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSGrammarPool.java index a3f0bc71a37..1bbcb92e453 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSGrammarPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSGrammarPool.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSNamedMap4Types.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSNamedMap4Types.java index a2c6b29df41..d44ae32f704 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSNamedMap4Types.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSNamedMap4Types.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSNamedMapImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSNamedMapImpl.java index b15f1ed47b3..8484b2f3444 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSNamedMapImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSNamedMapImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSObjectListImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSObjectListImpl.java index 7c5b4f7c40f..732cdae4bb7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSObjectListImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/util/XSObjectListImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2003-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/DefaultValidationErrorHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/DefaultValidationErrorHandler.java index 0c8d0a84db2..56b4ca2f844 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/DefaultValidationErrorHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/DefaultValidationErrorHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/JAXPConstants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/JAXPConstants.java index 5f2c563e211..0f5842d4911 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/JAXPConstants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/JAXPConstants.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/JAXPValidatorComponent.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/JAXPValidatorComponent.java index d447574d0f1..97234b99f34 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/JAXPValidatorComponent.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/JAXPValidatorComponent.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/SchemaValidatorConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/SchemaValidatorConfiguration.java index f919ec08a81..081ea6b9a26 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/SchemaValidatorConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/SchemaValidatorConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/TeeXMLDocumentFilterImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/TeeXMLDocumentFilterImpl.java index 696717a8a21..4893b4709ca 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/TeeXMLDocumentFilterImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/TeeXMLDocumentFilterImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/UnparsedEntityHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/UnparsedEntityHandler.java index 8129066eb3d..124babffa4f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/UnparsedEntityHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/UnparsedEntityHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/datatype/DatatypeFactoryImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/datatype/DatatypeFactoryImpl.java index a9baeac29ef..04f27e20020 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/datatype/DatatypeFactoryImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/datatype/DatatypeFactoryImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/AbstractXMLSchema.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/AbstractXMLSchema.java index 2d06bc0555a..620a0ec56d1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/AbstractXMLSchema.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/AbstractXMLSchema.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMDocumentHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMDocumentHandler.java index 9f514a97e62..b540b1b1360 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMDocumentHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMDocumentHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMResultAugmentor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMResultAugmentor.java index 06d75ebe055..950fbe837b9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMResultAugmentor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMResultAugmentor.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMResultBuilder.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMResultBuilder.java index f78f1f4354d..1469dace33b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMResultBuilder.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMResultBuilder.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMValidatorHelper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMValidatorHelper.java index fe006533b1d..6c5c562f844 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMValidatorHelper.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DOMValidatorHelper.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DraconianErrorHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DraconianErrorHandler.java index 171a4b596c7..721060dfe1f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DraconianErrorHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/DraconianErrorHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/EmptyXMLSchema.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/EmptyXMLSchema.java index ba50c5175b8..2a63e83e5e4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/EmptyXMLSchema.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/EmptyXMLSchema.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ErrorHandlerAdaptor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ErrorHandlerAdaptor.java index 124bcbc44c2..6b15b937af6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ErrorHandlerAdaptor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ErrorHandlerAdaptor.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xerces.internal.jaxp.validation; import com.sun.org.apache.xerces.internal.xni.parser.XMLErrorHandler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/JAXPValidationMessageFormatter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/JAXPValidationMessageFormatter.java index 8c50c4d477b..70fc95d97cc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/JAXPValidationMessageFormatter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/JAXPValidationMessageFormatter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ReadOnlyGrammarPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ReadOnlyGrammarPool.java index f177a1123d5..075f86416f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ReadOnlyGrammarPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ReadOnlyGrammarPool.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/SimpleXMLSchema.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/SimpleXMLSchema.java index 9b7b67db72f..dff20e5bd94 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/SimpleXMLSchema.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/SimpleXMLSchema.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/SoftReferenceGrammarPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/SoftReferenceGrammarPool.java index 2eeb5534f59..213b58be5d4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/SoftReferenceGrammarPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/SoftReferenceGrammarPool.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/Util.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/Util.java index 40782abb378..1f4f872eda4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/Util.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/Util.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ValidatorHelper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ValidatorHelper.java index aac3c6d1059..332cf319387 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ValidatorHelper.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/ValidatorHelper.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/WeakReferenceXMLSchema.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/WeakReferenceXMLSchema.java index 8399c9fd421..6180c8c3ba1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/WeakReferenceXMLSchema.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/WeakReferenceXMLSchema.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/WrappedSAXException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/WrappedSAXException.java index 106117c0872..ebed5682552 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/WrappedSAXException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/WrappedSAXException.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xerces.internal.jaxp.validation; import org.xml.sax.SAXException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/XSGrammarPoolContainer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/XSGrammarPoolContainer.java index 431a0f21f01..fe094fcfac1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/XSGrammarPoolContainer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/jaxp/validation/XSGrammarPoolContainer.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractDOMParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractDOMParser.java index 5e6c5773fba..68c3acd3fbb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractDOMParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractDOMParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractSAXParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractSAXParser.java index 3f6b43df132..ab289f875d8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractSAXParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractSAXParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractXMLDocumentParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractXMLDocumentParser.java index 545997c2f28..c80cec39d9f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractXMLDocumentParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/AbstractXMLDocumentParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/BasicParserConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/BasicParserConfiguration.java index c41f27d5a3f..679b0e7b820 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/BasicParserConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/BasicParserConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/CachingParserPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/CachingParserPool.java index a9f52290ce4..218c71327f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/CachingParserPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/CachingParserPool.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/DOMParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/DOMParser.java index d0f84188c5f..7d4511910b3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/DOMParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/DOMParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/DTDParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/DTDParser.java index 3c7624c6b29..c77968c900f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/DTDParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/DTDParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/IntegratedParserConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/IntegratedParserConfiguration.java index f90598c15a5..9f0c1e39d12 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/IntegratedParserConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/IntegratedParserConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/SAXParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/SAXParser.java index 811d957686e..b61d12e551a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/SAXParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/SAXParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/SecurityConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/SecurityConfiguration.java index 7eba8746e59..039043d8ecf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/SecurityConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/SecurityConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XIncludeAwareParserConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XIncludeAwareParserConfiguration.java index 9ef0b52222c..07a5498a712 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XIncludeAwareParserConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XIncludeAwareParserConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XIncludeParserConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XIncludeParserConfiguration.java index 29c18fa51d6..9c47d8eebf5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XIncludeParserConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XIncludeParserConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.parsers; import com.sun.org.apache.xerces.internal.impl.Constants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11Configurable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11Configurable.java index 7b5387a4a35..3c7d2ea6306 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11Configurable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11Configurable.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11Configuration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11Configuration.java index f56467532b6..109e4b69e46 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11Configuration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11Configuration.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -415,9 +415,15 @@ public class XML11Configuration extends ParserConfigurationSettings /** Current DTD scanner. */ protected XMLDTDScanner fCurrentDTDScanner; - /** Flag indiciating whether XML11 components have been initialized. */ + /** Flag indicating whether XML11 components have been initialized. */ private boolean f11Initialized = false; + /** Flag indicating whether the symbol table instance was specified during construction **/ + private boolean fSymbolTableProvided = false; + + /** Flag indicating if the symbol table was initialized and never used before that **/ + private boolean fSymbolTableJustInitialized = true; + // // Constructors // @@ -500,7 +506,8 @@ public class XML11Configuration extends ParserConfigurationSettings EXTERNAL_PARAMETER_ENTITIES, PARSER_SETTINGS, XMLConstants.FEATURE_SECURE_PROCESSING, - XMLConstants.USE_CATALOG + XMLConstants.USE_CATALOG, + JdkXmlUtils.RESET_SYMBOL_TABLE }; addRecognizedFeatures(recognizedFeatures); // set state for default features @@ -526,6 +533,7 @@ public class XML11Configuration extends ParserConfigurationSettings fFeatures.put(PARSER_SETTINGS, Boolean.TRUE); fFeatures.put(XMLConstants.FEATURE_SECURE_PROCESSING, Boolean.TRUE); fFeatures.put(XMLConstants.USE_CATALOG, JdkXmlUtils.USE_CATALOG_DEFAULT); + fFeatures.put(JdkXmlUtils.RESET_SYMBOL_TABLE, JdkXmlUtils.RESET_SYMBOL_TABLE_DEFAULT); // add default recognized properties final String[] recognizedProperties = @@ -566,15 +574,18 @@ public class XML11Configuration extends ParserConfigurationSettings }; addRecognizedProperties(recognizedProperties); - if (symbolTable == null) { - symbolTable = new SymbolTable(); + // Remember if symbolTable was provided from outside + fSymbolTableProvided = symbolTable != null; + if (!fSymbolTableProvided) { + fSymbolTable = new SymbolTable(); + } else { + fSymbolTable = symbolTable; } - fSymbolTable = symbolTable; fProperties.put(SYMBOL_TABLE, fSymbolTable); fGrammarPool = grammarPool; if (fGrammarPool != null) { - fProperties.put(XMLGRAMMAR_POOL, fGrammarPool); + fProperties.put(XMLGRAMMAR_POOL, fGrammarPool); } fEntityManager = new XMLEntityManager(); @@ -840,6 +851,7 @@ public class XML11Configuration extends ParserConfigurationSettings fValidationManager.reset(); fVersionDetector.reset(this); fConfigUpdated = true; + resetSymbolTable(); resetCommon(); short version = fVersionDetector.determineDocVersion(fInputSource); @@ -858,15 +870,7 @@ public class XML11Configuration extends ParserConfigurationSettings // resets and sets the pipeline. fVersionDetector.startDocumentParsing((XMLEntityHandler) fCurrentScanner, version); fInputSource = null; - } catch (XNIException ex) { - if (PRINT_EXCEPTION_STACK_TRACE) - ex.printStackTrace(); - throw ex; - } catch (IOException ex) { - if (PRINT_EXCEPTION_STACK_TRACE) - ex.printStackTrace(); - throw ex; - } catch (RuntimeException ex) { + } catch (IOException | RuntimeException ex) { if (PRINT_EXCEPTION_STACK_TRACE) ex.printStackTrace(); throw ex; @@ -879,15 +883,7 @@ public class XML11Configuration extends ParserConfigurationSettings try { return fCurrentScanner.scanDocument(complete); - } catch (XNIException ex) { - if (PRINT_EXCEPTION_STACK_TRACE) - ex.printStackTrace(); - throw ex; - } catch (IOException ex) { - if (PRINT_EXCEPTION_STACK_TRACE) - ex.printStackTrace(); - throw ex; - } catch (RuntimeException ex) { + } catch (IOException | RuntimeException ex) { if (PRINT_EXCEPTION_STACK_TRACE) ex.printStackTrace(); throw ex; @@ -1589,6 +1585,24 @@ public class XML11Configuration extends ParserConfigurationSettings } } + + /** + * Reset the symbol table if it wasn't provided during construction, + * its not the first time when parse is called after initialization + * and RESET_SYMBOL_TABLE feature is set to true + */ + private void resetSymbolTable() { + if (fFeatures.get(JdkXmlUtils.RESET_SYMBOL_TABLE) && !fSymbolTableProvided) { + if (fSymbolTableJustInitialized) { + // Skip symbol table reallocation for the first parsing process + fSymbolTableJustInitialized = false; + } else { + fSymbolTable = new SymbolTable(); + fProperties.put(SYMBOL_TABLE, fSymbolTable); + } + } + } + /** * Returns the state of a feature. This method calls getFeature() * on ParserConfigurationSettings, bypassing getFeature() on this diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11DTDConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11DTDConfiguration.java index f7591ae608e..892fb28c8ea 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11DTDConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11DTDConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11NonValidatingConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11NonValidatingConfiguration.java index 36a284239f3..8f526211db5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11NonValidatingConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XML11NonValidatingConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLDocumentParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLDocumentParser.java index eba49fbad92..80ed4b0138b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLDocumentParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLDocumentParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLGrammarCachingConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLGrammarCachingConfiguration.java index 72c055dbdf1..2b4314bc25a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLGrammarCachingConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLGrammarCachingConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLGrammarParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLGrammarParser.java index 1089493f2eb..d0e0e68fc1b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLGrammarParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLGrammarParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLParser.java index fe7801fcbb3..636b25761d6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XMLParser.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XPointerParserConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XPointerParserConfiguration.java index cacd68c68a2..2249811b14d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XPointerParserConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/parsers/XPointerParserConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.parsers; import com.sun.org.apache.xerces.internal.impl.Constants; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/AttributesProxy.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/AttributesProxy.java index 2c7b827eb17..e3a7746d3ad 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/AttributesProxy.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/AttributesProxy.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DOMEntityResolverWrapper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DOMEntityResolverWrapper.java index 8a4bbb5d852..07288981e89 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DOMEntityResolverWrapper.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DOMEntityResolverWrapper.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DOMInputSource.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DOMInputSource.java index bfa95727b0a..af3cfdb035b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DOMInputSource.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DOMInputSource.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DatatypeMessageFormatter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DatatypeMessageFormatter.java index 500769db59a..0097ec8f7b7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DatatypeMessageFormatter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DatatypeMessageFormatter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DefaultErrorHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DefaultErrorHandler.java index ca5e039981d..945c9d3f2e5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DefaultErrorHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DefaultErrorHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DraconianErrorHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DraconianErrorHandler.java index 89b38a55ab9..0850c698509 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DraconianErrorHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/DraconianErrorHandler.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xerces.internal.util; import org.xml.sax.ErrorHandler; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/EntityResolver2Wrapper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/EntityResolver2Wrapper.java index 53fdfde802a..4c4405a9796 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/EntityResolver2Wrapper.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/EntityResolver2Wrapper.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ErrorHandlerProxy.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ErrorHandlerProxy.java index 8b3ae9b075a..cc12f30d107 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ErrorHandlerProxy.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ErrorHandlerProxy.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ErrorHandlerWrapper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ErrorHandlerWrapper.java index 2455fe38a77..c8bc5e989e9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ErrorHandlerWrapper.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ErrorHandlerWrapper.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/FeatureState.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/FeatureState.java index e78b30c3773..36e56879d18 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/FeatureState.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/FeatureState.java @@ -1,4 +1,5 @@ /* + * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,14 +23,6 @@ * questions. */ -/* - * Copyright (c) 2009 by Oracle Corporation. All Rights Reserved. - */ - -/* - * $Id: FeatureState.java 3024 2011-03-01 03:46:13Z joehw $ - */ - package com.sun.org.apache.xerces.internal.util; public class FeatureState { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/IntStack.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/IntStack.java index 541d17a4915..49cf1c8c7e7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/IntStack.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/IntStack.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/LocatorProxy.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/LocatorProxy.java index 69c78a11654..759fca13cca 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/LocatorProxy.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/LocatorProxy.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/LocatorWrapper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/LocatorWrapper.java index d4445e6dc92..9a606c176f8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/LocatorWrapper.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/LocatorWrapper.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xerces.internal.util; import com.sun.org.apache.xerces.internal.xni.XMLLocator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/MessageFormatter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/MessageFormatter.java index f55ba5e35fc..7eaa9218ba5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/MessageFormatter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/MessageFormatter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/NamespaceSupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/NamespaceSupport.java index 2cd632c778d..9ba36621fba 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/NamespaceSupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/NamespaceSupport.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ParserConfigurationSettings.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ParserConfigurationSettings.java index 36ef62a6da1..7eca1d312da 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ParserConfigurationSettings.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ParserConfigurationSettings.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/PropertyState.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/PropertyState.java index 5e133cae65c..5788b64ab12 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/PropertyState.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/PropertyState.java @@ -1,4 +1,5 @@ /* + * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +23,6 @@ * questions. */ -/* - * Copyright (c) 2009 by Oracle Corporation. All Rights Reserved. - */ - -/* - * $Id: PropertyState.java 3024 2011-03-01 03:46:13Z joehw $ - */ package com.sun.org.apache.xerces.internal.util; public class PropertyState { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAX2XNI.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAX2XNI.java index b0017e67f89..11218972feb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAX2XNI.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAX2XNI.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xerces.internal.util; import com.sun.org.apache.xerces.internal.impl.xs.util.SimpleLocator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXInputSource.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXInputSource.java index cabd2d5653b..8ea1ba2d06a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXInputSource.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXInputSource.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXLocatorWrapper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXLocatorWrapper.java index 5733845c454..be1494b1a59 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXLocatorWrapper.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXLocatorWrapper.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXMessageFormatter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXMessageFormatter.java index 5c87f4ba497..a62242eaebc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXMessageFormatter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SAXMessageFormatter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.util; import com.sun.org.apache.xerces.internal.utils.SecuritySupport; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SecurityManager.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SecurityManager.java index d916f5bc516..a5df3999748 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SecurityManager.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SecurityManager.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2003 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ShadowedSymbolTable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ShadowedSymbolTable.java index 0550c505d7f..36f5c71febb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ShadowedSymbolTable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/ShadowedSymbolTable.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/Status.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/Status.java index 5fdcc5e19c1..b6d169eaa3d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/Status.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/Status.java @@ -1,4 +1,5 @@ /* + * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +23,6 @@ * questions. */ -/* - * Copyright (c) 2009 by Oracle Corporation. All Rights Reserved. - */ - -/* - * $Id: Status.java 3024 2011-03-01 03:46:13Z joehw $ - */ package com.sun.org.apache.xerces.internal.util; public enum Status { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SynchronizedSymbolTable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SynchronizedSymbolTable.java index 02086ef0f32..4eda3f33a50 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SynchronizedSymbolTable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/SynchronizedSymbolTable.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/TeeXMLDocumentFilterImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/TeeXMLDocumentFilterImpl.java index a7da70624f5..8675333bc04 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/TeeXMLDocumentFilterImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/TeeXMLDocumentFilterImpl.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xerces.internal.util; import com.sun.org.apache.xerces.internal.xni.Augmentations; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/URI.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/URI.java index a92cd20e399..b08388224d7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/URI.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/URI.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XML11Char.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XML11Char.java index 8c9e3412e7d..7335fc92f25 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XML11Char.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XML11Char.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLCatalogResolver.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLCatalogResolver.java index c488a9fa63e..56ad116a1ae 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLCatalogResolver.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLCatalogResolver.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLChar.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLChar.java index b649c34efa8..36ae45337fd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLChar.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLChar.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLDocumentFilterImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLDocumentFilterImpl.java index bde6fd2a87f..a4a347169fd 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLDocumentFilterImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLDocumentFilterImpl.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xerces.internal.util; import com.sun.org.apache.xerces.internal.xni.Augmentations; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLEntityDescriptionImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLEntityDescriptionImpl.java index 0a653a96c55..91d73e842c9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLEntityDescriptionImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLEntityDescriptionImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLErrorCode.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLErrorCode.java index 8d173afef05..0e0abcc26ea 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLErrorCode.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLErrorCode.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLGrammarPoolImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLGrammarPoolImpl.java index 277d3a3d56d..2559c510983 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLGrammarPoolImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLGrammarPoolImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLInputSourceAdaptor.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLInputSourceAdaptor.java index 7352625d893..a1a2729d117 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLInputSourceAdaptor.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLInputSourceAdaptor.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xerces.internal.util; import javax.xml.transform.Source; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLResourceIdentifierImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLResourceIdentifierImpl.java index 049d412fb68..deeeae4cb47 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLResourceIdentifierImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLResourceIdentifierImpl.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002, 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLStringBuffer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLStringBuffer.java index 17f46715aef..9e915738423 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLStringBuffer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLStringBuffer.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.util; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLSymbols.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLSymbols.java index 85f83e0346d..3fe863a2920 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLSymbols.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/util/XMLSymbols.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/ConfigurationError.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/ConfigurationError.java index 9cd86732f32..097a5d47e69 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/ConfigurationError.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/ConfigurationError.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/ObjectFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/ObjectFactory.java index f7ed5d07333..b8ee53ad3cc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/ObjectFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/utils/ObjectFactory.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/MultipleScopeNamespaceSupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/MultipleScopeNamespaceSupport.java index 27ac8eee8f4..fce1b364883 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/MultipleScopeNamespaceSupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/MultipleScopeNamespaceSupport.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xinclude; import java.util.Enumeration; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/SecuritySupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/SecuritySupport.java index fc86a3ac6df..ea00756d8d1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/SecuritySupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/SecuritySupport.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XInclude11TextReader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XInclude11TextReader.java index 7ff7ecbb7c0..4aadfad64c8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XInclude11TextReader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XInclude11TextReader.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xinclude; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeMessageFormatter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeMessageFormatter.java index 4420e29934d..8c0ac541462 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeMessageFormatter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeMessageFormatter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeNamespaceSupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeNamespaceSupport.java index 3c36d144999..d457cd4a702 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeNamespaceSupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeNamespaceSupport.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xinclude; import com.sun.org.apache.xerces.internal.xni.NamespaceContext; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeTextReader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeTextReader.java index 1ddc1b185f5..b700710dcb5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeTextReader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XIncludeTextReader.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xinclude; import java.io.BufferedInputStream; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XPointerElementHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XPointerElementHandler.java deleted file mode 100644 index cccafcfd072..00000000000 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XPointerElementHandler.java +++ /dev/null @@ -1,763 +0,0 @@ -/* - * reserved comment block - * DO NOT REMOVE OR ALTER! - */ -/* - * The Apache Software License, Version 1.1 - * - * - * Copyright (c) 2001-2003 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . - */ -package com.sun.org.apache.xerces.internal.xinclude; - - -import java.util.Enumeration; -import java.util.StringTokenizer; -import java.util.Stack; - -import com.sun.org.apache.xerces.internal.impl.Constants; -import com.sun.org.apache.xerces.internal.impl.XMLErrorReporter; -import com.sun.org.apache.xerces.internal.impl.dtd.DTDGrammar; -import com.sun.org.apache.xerces.internal.util.ParserConfigurationSettings; -import com.sun.org.apache.xerces.internal.xni.Augmentations; -import com.sun.org.apache.xerces.internal.xni.NamespaceContext; -import com.sun.org.apache.xerces.internal.xni.QName; -import com.sun.org.apache.xerces.internal.xni.XMLAttributes; -import com.sun.org.apache.xerces.internal.xni.XMLDocumentHandler; -import com.sun.org.apache.xerces.internal.xni.XMLLocator; -import com.sun.org.apache.xerces.internal.xni.XMLResourceIdentifier; -import com.sun.org.apache.xerces.internal.xni.XMLString; -import com.sun.org.apache.xerces.internal.xni.XNIException; -import com.sun.org.apache.xerces.internal.xni.grammars.XMLGrammarDescription; -import com.sun.org.apache.xerces.internal.xni.grammars.XMLGrammarPool; -import com.sun.org.apache.xerces.internal.xni.parser.XMLComponentManager; -import com.sun.org.apache.xerces.internal.xni.parser.XMLConfigurationException; -import com.sun.org.apache.xerces.internal.xni.parser.XMLDocumentSource; -import com.sun.org.apache.xerces.internal.xni.parser.XMLEntityResolver; -import com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator; -/** - * @author Arun Yadav, Sun Microsystem - */ -public class XPointerElementHandler implements XPointerSchema { - - - // recognized features and properties - - /** Property identifier: error handler. */ - protected static final String ERROR_REPORTER = - Constants.XERCES_PROPERTY_PREFIX + Constants.ERROR_REPORTER_PROPERTY; - - /** Property identifier: grammar pool . */ - protected static final String GRAMMAR_POOL = - Constants.XERCES_PROPERTY_PREFIX + Constants.XMLGRAMMAR_POOL_PROPERTY; - - /** Property identifier: grammar pool . */ - protected static final String ENTITY_RESOLVER = - Constants.XERCES_PROPERTY_PREFIX + Constants.ENTITY_RESOLVER_PROPERTY; - - protected static final String XPOINTER_SCHEMA = - Constants.XERCES_PROPERTY_PREFIX + Constants.XPOINTER_SCHEMA_PROPERTY; - - /** Recognized features. */ - private static final String[] RECOGNIZED_FEATURES = { - }; - - /** Feature defaults. */ - private static final Boolean[] FEATURE_DEFAULTS = { - }; - - /** Recognized properties. */ - - private static final String[] RECOGNIZED_PROPERTIES = - { ERROR_REPORTER, GRAMMAR_POOL, ENTITY_RESOLVER, XPOINTER_SCHEMA }; - - /** Property defaults. */ - private static final Object[] PROPERTY_DEFAULTS = { null, null, null,null }; - - // Data - - protected XMLDocumentHandler fDocumentHandler; - protected XMLDocumentSource fDocumentSource; - - protected XIncludeHandler fParentXIncludeHandler; - - protected XMLLocator fDocLocation; - protected XIncludeNamespaceSupport fNamespaceContext; - protected XMLErrorReporter fErrorReporter; - protected XMLGrammarPool fGrammarPool; - protected XMLGrammarDescription fGrammarDesc; - protected DTDGrammar fDTDGrammar; - protected XMLEntityResolver fEntityResolver; - protected ParserConfigurationSettings fSettings; - //protected String fPointerSchema; - protected StringBuffer fPointer; - private int elemCount = 0; - - - // The current element depth. - // This is used to access the appropriate level of the following stacks. - private int fDepth; - - // The depth of the first element to actually be part of the result infoset. - // This will normally be 1, but it could be larger when the top-level item - // is an include, and processing goes to the fallback. - private int fRootDepth; - - // this value must be at least 1 - private static final int INITIAL_SIZE = 8; - - - // Used to ensure that fallbacks are always children of include elements, - // and that include elements are never children of other include elements. - // An index contains true if the ancestor of the current element which resides - // at that depth was an include element. - private boolean[] fSawInclude = new boolean[INITIAL_SIZE]; - - - // Ensures that only one fallback element can be at a single depth. - // An index contains true if we have seen any fallback elements at that depth, - // and it is only reset to false when the end tag of the parent is encountered. - private boolean[] fSawFallback = new boolean[INITIAL_SIZE]; - - - // The state of the processor at each given depth. - private int[] fState = new int[INITIAL_SIZE]; - - QName foundElement = null; - boolean skip = false; - // Constructors - - public XPointerElementHandler() { - - - fDepth = 0; - fRootDepth = 0; - fSawFallback[fDepth] = false; - fSawInclude[fDepth] = false; - fSchemaName="element"; - - - } - - // START OF IMPLEMENTATION OF XMLComponent methods ////// - - public void reset(){ - elemCount =0; - fPointerToken = null; - fCurrentTokenint=0; - fCurrentTokenString=null; - fCurrentTokenType=0 ; - fElementCount =0; - fCurrentToken =0; - includeElement = false; - foundElement = null; - skip = false; - fSubResourceIdentified=false; - } - - public void reset(XMLComponentManager componentManager) - throws XNIException { - fNamespaceContext = null; - elemCount =0; - fDepth = 0; - fRootDepth = 0; - fPointerToken = null; - fCurrentTokenint=0; - fCurrentTokenString=null; - fCurrentTokenType=0 ; - foundElement = null; - includeElement = false; - skip = false; - fSubResourceIdentified=false; - - - - - try { - setErrorReporter( - (XMLErrorReporter)componentManager.getProperty(ERROR_REPORTER)); - } - catch (XMLConfigurationException e) { - fErrorReporter = null; - } - try { - fGrammarPool = - (XMLGrammarPool)componentManager.getProperty(GRAMMAR_POOL); - } - catch (XMLConfigurationException e) { - fGrammarPool = null; - } - try { - fEntityResolver = - (XMLEntityResolver)componentManager.getProperty( - ENTITY_RESOLVER); - } - catch (XMLConfigurationException e) { - fEntityResolver = null; - } - - fSettings = new ParserConfigurationSettings(); - - Enumeration xercesFeatures = Constants.getXercesFeatures(); - while (xercesFeatures.hasMoreElements()) { - String featureId = (String)xercesFeatures.nextElement(); - fSettings.addRecognizedFeatures(new String[] { featureId }); - try { - fSettings.setFeature( - featureId, - componentManager.getFeature(featureId)); - } - catch (XMLConfigurationException e) { - // componentManager doesn't support this feature, - // so we won't worry about it - } - } -/* try{ - dtdValidator = (XMLDTDValidator)componentManager.getProperty( Constants.XERCES_PROPERTY_PREFIX + Constants.DTD_VALIDATOR_PROPERTY); - }Catch(Exception ex){ - ex.printStackTrace(); - }*/ - - } // reset(XMLComponentManager) - - /** - * Returns a list of feature identifiers that are recognized by - * this component. This method may return null if no features - * are recognized by this component. - */ - public String[] getRecognizedFeatures() { - return RECOGNIZED_FEATURES; - } // getRecognizedFeatures():String[] - - /** - * Sets the state of a feature. This method is called by the component - * manager any time after reset when a feature changes state. - *

    - * Note: Components should silently ignore features - * that do not affect the operation of the component. - * - * @param featureId The feature identifier. - * @param state The state of the feature. - * - * @throws SAXNotRecognizedException The component should not throw - * this exception. - * @throws SAXNotSupportedException The component should not throw - * this exception. - */ - public void setFeature(String featureId, boolean state) - throws XMLConfigurationException { - if (fSettings != null) { - fSettings.setFeature(featureId, state); - } - - } // setFeature(String,boolean) - - /** - * Returns a list of property identifiers that are recognized by - * this component. This method may return null if no properties - * are recognized by this component. - */ - public String[] getRecognizedProperties() { - return RECOGNIZED_PROPERTIES; - } // getRecognizedProperties():String[] - - /** - * Sets the value of a property. This method is called by the component - * manager any time after reset when a property changes value. - *

    - * Note: Components should silently ignore properties - * that do not affect the operation of the component. - * - * @param propertyId The property identifier. - * @param value The value of the property. - * - * @throws SAXNotRecognizedException The component should not throw - * this exception. - * @throws SAXNotSupportedException The component should not throw - * this exception. - */ - public void setProperty(String propertyId, Object value) - throws XMLConfigurationException { - if (propertyId.equals(ERROR_REPORTER)) { - setErrorReporter((XMLErrorReporter)value); - } - if (propertyId.equals(GRAMMAR_POOL)) { - fGrammarPool = (XMLGrammarPool)value; - } - if (propertyId.equals(ENTITY_RESOLVER)) { - fEntityResolver = (XMLEntityResolver)value; - } - - } // setProperty(String,Object) - - /** - * Returns the default state for a feature, or null if this - * component does not want to report a default value for this - * feature. - * - * @param featureId The feature identifier. - * - * @since Xerces 2.2.0 - */ - public Boolean getFeatureDefault(String featureId) { - for (int i = 0; i < RECOGNIZED_FEATURES.length; i++) { - if (RECOGNIZED_FEATURES[i].equals(featureId)) { - return FEATURE_DEFAULTS[i]; - } - } - return null; - } // getFeatureDefault(String):Boolean - - /** - * Returns the default state for a property, or null if this - * component does not want to report a default value for this - * property. - * - * @param propertyId The property identifier. - * - * @since Xerces 2.2.0 - */ - public Object getPropertyDefault(String propertyId) { - for (int i = 0; i < RECOGNIZED_PROPERTIES.length; i++) { - if (RECOGNIZED_PROPERTIES[i].equals(propertyId)) { - return PROPERTY_DEFAULTS[i]; - } - } - return null; - } // getPropertyDefault(String):Object - - private void setErrorReporter(XMLErrorReporter reporter) { - fErrorReporter = reporter; - if (fErrorReporter != null) { - fErrorReporter.putMessageFormatter( - XIncludeMessageFormatter.XINCLUDE_DOMAIN, - new XIncludeMessageFormatter()); - } - } - ///////// END OF IMPLEMENTATION OF XMLComponents methods. ////////// - - - - //////// START OF IMPLEMENTATION OF XMLDOCUMENTSOURCE INTERFACE ///////// - - public void setDocumentHandler(XMLDocumentHandler handler) { - fDocumentHandler = handler; - } - - public XMLDocumentHandler getDocumentHandler() { - return fDocumentHandler; - } - - /////// END OF IMPLENTATION OF XMLDOCUMENTSOURCE INTERFACE /////////// - - - - - /////////////// Implementation of XPointerSchema Methods ////////////////////// - - String fSchemaName; - String fSchemaPointer; - boolean fSubResourceIdentified; - /** - * set the Schema Name eg element , xpointer - */ - public void setXPointerSchemaName(String schemaName){ - fSchemaName = schemaName; - } - - /** - * Return Schema Name eg element , xpointer - * - */ - public String getXpointerSchemaName(){ - return fSchemaName; - } - - /** - * Parent Contenhandler for the this contenthandler. - * // not sure about the parameter type. It can be Contenthandler instead of Object type. - */ - public void setParent(Object parent){ - fParentXIncludeHandler = (XIncludeHandler)parent; - } - - - /** - * return the Parent Contenthandler - */ - public Object getParent(){ - return fParentXIncludeHandler; - } - - /** - * Content of the XPointer Schema. Xpath to be resolved. - */ - public void setXPointerSchemaPointer(String content){ - fSchemaPointer = content; - } - - /** - * Return the XPointer Schema. - */ - public String getXPointerSchemaPointer(){ - return fSchemaPointer; - } - - public boolean isSubResourceIndentified(){ - return fSubResourceIdentified; - } - - ///////////End Implementation of XPointerSchema Methods ////////////////////// - - - - //////////// Tokens Playground /////////////////// - - Stack fPointerToken = new Stack(); - int fCurrentTokenint=0; - String fCurrentTokenString=null; - int fCurrentTokenType=0 ;// 0 Notype; 1 for integer; 2 for string. - - public void getTokens(){ - fSchemaPointer = fSchemaPointer.substring(fSchemaPointer.indexOf("(")+1, fSchemaPointer.length()); - StringTokenizer st = new StringTokenizer(fSchemaPointer, "/"); - String tempToken; - Integer integerToken =null; - Stack tempPointerToken = new Stack(); - if(fPointerToken == null){ - fPointerToken = new Stack(); - } - while(st.hasMoreTokens()){ - tempToken=st.nextToken(); - try { - integerToken = Integer.valueOf(tempToken); - tempPointerToken.push(integerToken); - }catch(NumberFormatException e){ - tempPointerToken.push(tempToken); - } - } - while(!tempPointerToken.empty()){ - fPointerToken.push(tempPointerToken.pop()); - } - }//getTokens - - - public boolean hasMoreToken(){ - if(fPointerToken.isEmpty()) - return false; - else - return true; - } - - public boolean getNextToken(){ - Object currentToken; - if (!fPointerToken.isEmpty()){ - currentToken = fPointerToken.pop(); - if(currentToken instanceof Integer){ - fCurrentTokenint = ((Integer)currentToken).intValue(); - fCurrentTokenType = 1; - } - else{ - fCurrentTokenString = ((String)currentToken).toString(); - fCurrentTokenType = 2; - } - return true; - } - else { - return false; - } - } - - private boolean isIdAttribute(XMLAttributes attributes,Augmentations augs, int index) { - Object o = augs.getItem(Constants.ID_ATTRIBUTE); - if( o instanceof Boolean ) - return ((Boolean)o).booleanValue(); - return "ID".equals(attributes.getType(index)); - } - - public boolean checkStringToken(QName element, XMLAttributes attributes){ - QName cacheQName = null; - String id =null; - String rawname =null; - QName attrName = new QName(); - String attrType = null; - String attrValue = null; - int attrCount = attributes.getLength(); - for (int i = 0; i < attrCount; i++) { - Augmentations aaugs = attributes.getAugmentations(i); - attributes.getName(i,attrName); - attrType = attributes.getType(i); - attrValue = attributes.getValue(i); - if(attrType != null && attrValue!= null && isIdAttribute(attributes,aaugs,i) && attrValue.equals(fCurrentTokenString)){ - if(hasMoreToken()){ - fCurrentTokenType = 0; - fCurrentTokenString = null; - return true; - } - else{ - foundElement = element; - includeElement = true; - fCurrentTokenType = 0; - fCurrentTokenString = null; - fSubResourceIdentified = true; - return true; - } - } - } - return false; - } - - public boolean checkIntegerToken(QName element){ - if(!skip){ - fElementCount++; - if(fCurrentTokenint == fElementCount){ - if(hasMoreToken()){ - fElementCount=0; - fCurrentTokenType = 0; - return true; - } - else{ - foundElement = element; - includeElement = true; - fCurrentTokenType = 0; - fElementCount=0; - fSubResourceIdentified =true; - return true; - } - }else{ - addQName(element); - skip = true; - return false; - } - } - return false; - } - - public void addQName(QName element){ - QName cacheQName = new QName(element); - ftempCurrentElement.push(cacheQName); - } - - /////////// END TOKEN PLAYGROUND /////////////// - - - ///// START OF IMPLEMTATION OF XMLDocumentHandler methods ////////// - - - public void startDocument(XMLLocator locator, String encoding, - NamespaceContext namespaceContext, Augmentations augs) - throws XNIException { - - getTokens(); - } - - public void doctypeDecl(String rootElement, String publicId, String systemId, - Augmentations augs)throws XNIException { - } - - public void xmlDecl(String version, String encoding, String standalone, - Augmentations augs) throws XNIException { - } - - - public void comment(XMLString text, Augmentations augs) - throws XNIException { - if (fDocumentHandler != null && includeElement) { - fDocumentHandler.comment(text, augs); - } - } - - public void processingInstruction(String target, XMLString data, - Augmentations augs) throws XNIException { - if (fDocumentHandler != null && includeElement) { - fDocumentHandler.processingInstruction(target, data, augs); - - } - } - - Stack ftempCurrentElement = new Stack(); - int fElementCount =0; - int fCurrentToken ; - boolean includeElement; - - - public void startElement(QName element, XMLAttributes attributes, - Augmentations augs)throws XNIException { - - boolean requiredToken=false; - if(fCurrentTokenType == 0) - getNextToken(); - if(fCurrentTokenType ==1) - requiredToken = checkIntegerToken(element); - else if (fCurrentTokenType ==2) - requiredToken = checkStringToken(element, attributes); - if(requiredToken && hasMoreToken()) - getNextToken(); - if(fDocumentHandler != null && includeElement){ - elemCount++; - fDocumentHandler.startElement(element, attributes, augs); - } - - } - - - public void endElement(QName element, Augmentations augs) - throws XNIException { - if(includeElement && foundElement != null ){ - if(elemCount >0 )elemCount --; - fDocumentHandler.endElement(element, augs); - if(elemCount == 0)includeElement = false; - - }else if(!ftempCurrentElement.empty()){ - QName name = (QName)ftempCurrentElement.peek(); - if(name.equals(element)){ - ftempCurrentElement.pop(); - skip = false; - } - } - } - - public void emptyElement(QName element, XMLAttributes attributes, - Augmentations augs)throws XNIException { - if(fDocumentHandler != null && includeElement){ - fDocumentHandler.emptyElement(element, attributes, augs); - } - } - - public void startGeneralEntity(String name, XMLResourceIdentifier resId, - String encoding, - Augmentations augs) - throws XNIException { - if (fDocumentHandler != null && includeElement) { - fDocumentHandler.startGeneralEntity(name, resId, encoding, augs); - } - } - - public void textDecl(String version, String encoding, Augmentations augs) - throws XNIException { - if (fDocumentHandler != null && includeElement) { - fDocumentHandler.textDecl(version, encoding, augs); - } - } - - public void endGeneralEntity(String name, Augmentations augs) - throws XNIException { - if (fDocumentHandler != null) { - fDocumentHandler.endGeneralEntity(name, augs); - } - } - - public void characters(XMLString text, Augmentations augs) - throws XNIException { - if (fDocumentHandler != null && includeElement) { - fDocumentHandler.characters(text, augs); - } - } - - public void ignorableWhitespace(XMLString text, Augmentations augs) - throws XNIException { - if (fDocumentHandler != null && includeElement) { - fDocumentHandler.ignorableWhitespace(text, augs); - } - } - - public void startCDATA(Augmentations augs) throws XNIException { - if (fDocumentHandler != null && includeElement) { - fDocumentHandler.startCDATA(augs); - } - } - - public void endCDATA(Augmentations augs) throws XNIException { - if (fDocumentHandler != null && includeElement) { - fDocumentHandler.endCDATA(augs); - } - } - - public void endDocument(Augmentations augs) throws XNIException { - } - - public void setDocumentSource(XMLDocumentSource source) { - fDocumentSource = source; - } - - public XMLDocumentSource getDocumentSource() { - return fDocumentSource; - } - - - protected void reportFatalError(String key) { - this.reportFatalError(key, null); - } - - protected void reportFatalError(String key, Object[] args) { - if (fErrorReporter != null) { - fErrorReporter.reportError( - fDocLocation, - XIncludeMessageFormatter.XINCLUDE_DOMAIN, - key, - args, - XMLErrorReporter.SEVERITY_FATAL_ERROR); - } - // we won't worry about when error reporter is null, since there should always be - // at least the default error reporter - } - - - - // used to know whether to pass declarations to the document handler - protected boolean isRootDocument() { - return this.fParentXIncludeHandler == null; - } - - -} // class XPointerElementhandler diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XPointerFramework.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XPointerFramework.java deleted file mode 100644 index abe514e24ab..00000000000 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xinclude/XPointerFramework.java +++ /dev/null @@ -1,209 +0,0 @@ -/* - * reserved comment block - * DO NOT REMOVE OR ALTER! - */ -/* - * The Apache Software License, Version 1.1 - * - * - * Copyright (c) 2001-2003 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . - */ -package com.sun.org.apache.xerces.internal.xinclude; - -import java.util.Stack; -import com.sun.org.apache.xerces.internal.xinclude.XPointerSchema; - -public class XPointerFramework{ - - /* - Todo's by next integration. - While constructing schema names and uris use a dynamic datastructure. - */ - - XPointerSchema [] fXPointerSchema; - String [] fSchemaPointerName; - String [] fSchemaPointerURI; - String fSchemaPointer; - String fCurrentSchemaPointer; - Stack fSchemaNotAvailable; - int fCountSchemaName = 0; - int schemaLength = 0; - XPointerSchema fDefaultXPointerSchema; - - public XPointerFramework(){ - this(null); - } - - public XPointerFramework(XPointerSchema [] xpointerschema){ - fXPointerSchema = xpointerschema; - fSchemaNotAvailable = new Stack(); - } - - public void reset(){ - fXPointerSchema = null; - fXPointerSchema = null; - fCountSchemaName = 0; - schemaLength = 0; - fSchemaPointerName = null; - fSchemaPointerURI = null; - fDefaultXPointerSchema = null; - fCurrentSchemaPointer = null; - } - - public void setXPointerSchema(XPointerSchema [] xpointerschema){ - fXPointerSchema = xpointerschema; - } - - public void setSchemaPointer(String schemaPointer){ - fSchemaPointer = schemaPointer; - } - - public XPointerSchema getNextXPointerSchema(){ - int i=fCountSchemaName; - if(fSchemaPointerName == null){ - getSchemaNames(); - } - if(fDefaultXPointerSchema == null){ - getDefaultSchema(); - } - if(fDefaultXPointerSchema.getXpointerSchemaName().equalsIgnoreCase(fSchemaPointerName[i])){ - fDefaultXPointerSchema.reset(); - fDefaultXPointerSchema.setXPointerSchemaPointer(fSchemaPointerURI[i]); - fCountSchemaName = ++i; - return getDefaultSchema(); - } - if(fXPointerSchema == null){ - fCountSchemaName = ++i; - return null; - } - - int fschemalength = fXPointerSchema.length; - - for(;fSchemaPointerName[i] != null; i++){ - for(int j=0; j. + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.xni; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLAttributes.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLAttributes.java index 4d4b93a3997..9ff29751d93 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLAttributes.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLAttributes.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2000-2002 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.xni; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDTDContentModelHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDTDContentModelHandler.java index 062825e4460..a8147a05635 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDTDContentModelHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDTDContentModelHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDTDHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDTDHandler.java index 73877660376..8691bdd2cab 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDTDHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDTDHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDocumentFragmentHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDocumentFragmentHandler.java index 5efbfcac8f0..09a3d9c2dce 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDocumentFragmentHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDocumentFragmentHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDocumentHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDocumentHandler.java index 18d0c1c7e07..12395d12712 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDocumentHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLDocumentHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLLocator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLLocator.java index 7ab0f869625..393d8a904e8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLLocator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLLocator.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLResourceIdentifier.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLResourceIdentifier.java index f748d62809d..66880c6da8a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLResourceIdentifier.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLResourceIdentifier.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLString.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLString.java index dd4240d8ead..f63e1d20aa6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLString.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XMLString.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XNIException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XNIException.java index 98b9d40abad..ba97277dee0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XNIException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/XNIException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/Grammar.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/Grammar.java index 95adbcd7e88..dc749289ab9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/Grammar.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/Grammar.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLDTDDescription.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLDTDDescription.java index 2b72668d2df..d34b137e47f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLDTDDescription.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLDTDDescription.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarDescription.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarDescription.java index e5c83f291a2..9a291ecead3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarDescription.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarDescription.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarLoader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarLoader.java index b8d32042d98..97e31988421 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarLoader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarLoader.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarPool.java index bd947b5c85e..f4e68377596 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLGrammarPool.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xni.grammars; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLSchemaDescription.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLSchemaDescription.java index bc38a2f68a1..88b48d50d6b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLSchemaDescription.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XMLSchemaDescription.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XSGrammar.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XSGrammar.java index 44559517d69..2da3d88ee05 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XSGrammar.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/grammars/XSGrammar.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLComponent.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLComponent.java index 68b2faad870..00c9e0329da 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLComponent.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLComponent.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLComponentManager.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLComponentManager.java index 1ea05c6babd..3d41d436f2e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLComponentManager.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLComponentManager.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLConfigurationException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLConfigurationException.java index 3f1280d1fb8..aed00c89356 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLConfigurationException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLConfigurationException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDContentModelFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDContentModelFilter.java index 77e71f005ad..19271288023 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDContentModelFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDContentModelFilter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDContentModelSource.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDContentModelSource.java index dca3bd9a19c..823d0e5108f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDContentModelSource.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDContentModelSource.java @@ -3,60 +3,20 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 2001, 2002 The Apache Software Foundation. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xerces" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, International - * Business Machines, Inc., http://www.apache.org. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.org.apache.xerces.internal.xni.parser; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDFilter.java index f30932fc4fa..d36eb0a601e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDFilter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDScanner.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDScanner.java index 189152dd217..9d6c3205f8e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDScanner.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDScanner.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDSource.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDSource.java index 1f2c312818c..848d61f581c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDSource.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDTDSource.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentFilter.java index 1eb55f4bb76..f4e8086f28b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentFilter.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentScanner.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentScanner.java index 9fa5248749d..93dd95cafdc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentScanner.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentScanner.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentSource.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentSource.java index 217b515992d..4caeddd25de 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentSource.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLDocumentSource.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLEntityResolver.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLEntityResolver.java index c39671f6ce8..9c8562a77bc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLEntityResolver.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLEntityResolver.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLErrorHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLErrorHandler.java index 47b77bab34a..2c3f0ee0b0c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLErrorHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLErrorHandler.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLInputSource.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLInputSource.java index 4a59086d5f6..54c8ed59f31 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLInputSource.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLInputSource.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2000-2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLParseException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLParseException.java index 1abb9ac041f..27e933b1782 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLParseException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLParseException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLParserConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLParserConfiguration.java index b42712ec254..57c8dd08795 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLParserConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLParserConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLPullParserConfiguration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLPullParserConfiguration.java index f3db0a3e676..2f991227417 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLPullParserConfiguration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xni/parser/XMLPullParserConfiguration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001, 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/AttributePSVI.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/AttributePSVI.java index 5b0979bf52d..d68073efc6c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/AttributePSVI.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/AttributePSVI.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ElementPSVI.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ElementPSVI.java index f3a68ac5a1d..8608e05bce7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ElementPSVI.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ElementPSVI.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ItemPSVI.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ItemPSVI.java index 8230abff87e..6fab4257cee 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ItemPSVI.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ItemPSVI.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -116,6 +115,7 @@ public interface ItemPSVI { * * @deprecated Use getSchemaValue().getNormalizedValue() instead */ + @Deprecated public String getSchemaNormalizedValue(); /** @@ -127,6 +127,7 @@ public interface ItemPSVI { * * @deprecated Use getSchemaValue().getActualValue() instead */ + @Deprecated public Object getActualNormalizedValue() throws XSException; @@ -146,6 +147,7 @@ public interface ItemPSVI { * * @deprecated Use getSchemaValue().getActualValueType() instead */ + @Deprecated public short getActualNormalizedValueType() throws XSException; @@ -182,6 +184,7 @@ public interface ItemPSVI { * * @deprecated Use getSchemaValue().getListValueTypes() instead */ + @Deprecated public ShortList getItemValueTypes() throws XSException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/LSInputList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/LSInputList.java index 6459631533b..8b26f6a8d2b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/LSInputList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/LSInputList.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/PSVIProvider.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/PSVIProvider.java index 1dca0ddc1c5..69ba27cf03d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/PSVIProvider.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/PSVIProvider.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ShortList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ShortList.java index a10e122139f..e993d6393ed 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ShortList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ShortList.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/StringList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/StringList.java index f8e34e147c8..32d26205f44 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/StringList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/StringList.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAnnotation.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAnnotation.java index d04f3313df2..2a8b378eaa8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAnnotation.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAnnotation.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeDeclaration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeDeclaration.java index 7fa9563b8a2..c6ee34ffb4d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeDeclaration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeDeclaration.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -55,6 +54,7 @@ public interface XSAttributeDeclaration extends XSObject { * * @deprecated Use getValueConstraintValue().getNormalizedValue() instead */ + @Deprecated public String getConstraintValue(); /** @@ -67,6 +67,7 @@ public interface XSAttributeDeclaration extends XSObject { * * @deprecated Use getValueConstraintValue().getActualValue() instead */ + @Deprecated public Object getActualVC() throws XSException; @@ -86,6 +87,7 @@ public interface XSAttributeDeclaration extends XSObject { * * @deprecated Use getValueConstraintValue().getActualValueType() instead */ + @Deprecated public short getActualVCType() throws XSException; @@ -104,6 +106,7 @@ public interface XSAttributeDeclaration extends XSObject { * * @deprecated Use getValueConstraintValue().getListValueTypes() instead */ + @Deprecated public ShortList getItemValueTypes() throws XSException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeGroupDefinition.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeGroupDefinition.java index 71d90b07f27..97826ca76db 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeGroupDefinition.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeGroupDefinition.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeUse.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeUse.java index 5545b028b64..8362ae67f9b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeUse.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeUse.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -48,6 +47,7 @@ public interface XSAttributeUse extends XSObject { * * @deprecated Use getValueConstraintValue().getNormalizedValue() instead */ + @Deprecated public String getConstraintValue(); /** @@ -60,6 +60,7 @@ public interface XSAttributeUse extends XSObject { * * @deprecated Use getValueConstraintValue().getActualValue() instead */ + @Deprecated public Object getActualVC() throws XSException; @@ -79,6 +80,7 @@ public interface XSAttributeUse extends XSObject { * * @deprecated Use getValueConstraintValue().getActualValueType() instead */ + @Deprecated public short getActualVCType() throws XSException; @@ -97,6 +99,7 @@ public interface XSAttributeUse extends XSObject { * * @deprecated Use getValueConstraintValue().getListValueTypes() instead */ + @Deprecated public ShortList getItemValueTypes() throws XSException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSComplexTypeDefinition.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSComplexTypeDefinition.java index 104dbb6c942..1456d57c99f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSComplexTypeDefinition.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSComplexTypeDefinition.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSConstants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSConstants.java index cbe1a469693..75e76d416b3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSConstants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSConstants.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSElementDeclaration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSElementDeclaration.java index cf2fea85b27..1f810a54f14 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSElementDeclaration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSElementDeclaration.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -56,6 +55,7 @@ public interface XSElementDeclaration extends XSTerm { * * @deprecated Use getValueConstraintValue().getNormalizedValue() instead */ + @Deprecated public String getConstraintValue(); /** @@ -68,6 +68,7 @@ public interface XSElementDeclaration extends XSTerm { * * @deprecated Use getValueConstraintValue().getActualValue() instead */ + @Deprecated public Object getActualVC() throws XSException; @@ -87,6 +88,7 @@ public interface XSElementDeclaration extends XSTerm { * * @deprecated Use getValueConstraintValue().getActualValueType() instead */ + @Deprecated public short getActualVCType() throws XSException; @@ -105,6 +107,7 @@ public interface XSElementDeclaration extends XSTerm { * * @deprecated Use getValueConstraintValue().getListValueTypes() instead */ + @Deprecated public ShortList getItemValueTypes() throws XSException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSException.java index d0918250366..b4d3a13f2b1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSException.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSIDCDefinition.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSIDCDefinition.java index c26cec7912f..cf4e91f8b6a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSIDCDefinition.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSIDCDefinition.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSImplementation.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSImplementation.java index 2d7a37f27fb..cc5c9a3b247 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSImplementation.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSImplementation.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSLoader.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSLoader.java index aabf95ffff9..ea476addb01 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSLoader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSLoader.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSModelGroup.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSModelGroup.java index 265ecf3cff3..2fc5f77f8ae 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSModelGroup.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSModelGroup.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSModelGroupDefinition.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSModelGroupDefinition.java index fb6d5949f6f..39a58c57d8e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSModelGroupDefinition.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSModelGroupDefinition.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNamedMap.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNamedMap.java index 976680bd3fd..ac63fed8c21 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNamedMap.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNamedMap.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNamespaceItemList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNamespaceItemList.java index 8a8ee992859..57275e41b20 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNamespaceItemList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNamespaceItemList.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNotationDeclaration.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNotationDeclaration.java index b1c03d26d8e..b956069c040 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNotationDeclaration.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSNotationDeclaration.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSObject.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSObject.java index 176ae7926f4..30ab34fff24 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSObject.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSObject.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSObjectList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSObjectList.java index 5e60a1ef576..7117e6640fa 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSObjectList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSObjectList.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSParticle.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSParticle.java index e6456259fcc..97a3c839d0a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSParticle.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSParticle.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSTerm.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSTerm.java index 12878392ae1..3718f333201 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSTerm.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSTerm.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSTypeDefinition.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSTypeDefinition.java index 3c4cc966598..27489f2d5b3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSTypeDefinition.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSTypeDefinition.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSWildcard.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSWildcard.java index ee68f4995bf..50529fbd100 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSWildcard.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSWildcard.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/ObjectList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/ObjectList.java index 141fb0a7b26..1ec21047e86 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/ObjectList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/ObjectList.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xs.datatypes; import java.util.List; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDateTime.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDateTime.java index d08329050d7..53e97581ea5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDateTime.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDateTime.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xs.datatypes; import javax.xml.datatype.Duration; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDecimal.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDecimal.java index 2170992f403..ba0f5a68be4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDecimal.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDecimal.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xs.datatypes; import java.math.BigDecimal; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDouble.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDouble.java index d3cb7153c57..1c136413c99 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDouble.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSDouble.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xs.datatypes; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSFloat.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSFloat.java index b7f8d6bea3c..e31128e9cf6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSFloat.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSFloat.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004,2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xerces.internal.xs.datatypes; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSQName.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSQName.java index f780a61a70a..eba64efeb68 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSQName.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/datatypes/XSQName.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/Axis.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/Axis.java index 9239715f3c2..d3c344bd065 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/Axis.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/Axis.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Axis.java,v 1.2.4.1 2005/09/15 08:14:51 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTM.java index 9182833ae89..84121c26504 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTM.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTM.java,v 1.2.4.1 2005/09/15 08:14:51 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; import javax.xml.transform.SourceLocator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMAxisIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMAxisIterator.java index f2934aeb1cd..338c5289e34 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMAxisIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMAxisIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMAxisIterator.java,v 1.2.4.1 2005/09/15 08:14:52 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMAxisTraverser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMAxisTraverser.java index e4ba08676a1..9600f9ce882 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMAxisTraverser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMAxisTraverser.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMAxisTraverser.java,v 1.2.4.1 2005/09/15 08:14:52 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMConfigurationException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMConfigurationException.java index c58397df3fd..dffbc9891a0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMConfigurationException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMConfigurationException.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMConfigurationException.java,v 1.2.4.1 2005/09/15 08:14:52 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; import javax.xml.transform.SourceLocator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMDOMException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMDOMException.java index 616fa0b5864..9ebba449e2b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMDOMException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMDOMException.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMDOMException.java,v 1.2.4.1 2005/09/15 08:14:52 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMException.java index 7711ce73f88..9e8f68ecb46 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMException.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMException.java,v 1.3 2005/09/28 13:48:50 pvedula Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMFilter.java index 331e753d47a..2d6f1df5bb7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMFilter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMFilter.java,v 1.2.4.1 2005/09/15 08:14:53 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMIterator.java index 64d01bea6be..998a0901a40 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMIterator.java,v 1.2.4.1 2005/09/15 08:14:54 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMManager.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMManager.java index d629b9fd8db..052dea8cf97 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMManager.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMManager.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMManager.java,v 1.2.4.1 2005/09/15 08:14:54 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; import com.sun.org.apache.xml.internal.res.XMLErrorResources; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMWSFilter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMWSFilter.java index 29864b01b67..a476c25b17d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMWSFilter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/DTMWSFilter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMWSFilter.java,v 1.2.4.1 2005/09/15 08:14:55 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ChunkedIntArray.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ChunkedIntArray.java index 85aebf7523d..c029dcbf606 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ChunkedIntArray.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ChunkedIntArray.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ChunkedIntArray.java,v 1.2.4.1 2005/09/15 08:14:58 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.res.XMLErrorResources; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineManager.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineManager.java index 6323b038290..2d393886c1d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineManager.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineManager.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CoroutineManager.java,v 1.2.4.1 2005/09/15 08:14:58 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import java.util.BitSet; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineParser.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineParser.java index 57c77241519..b56d0ceafc6 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineParser.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineParser.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +17,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CoroutineParser.java,v 1.2.4.1 2005/09/15 08:14:59 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.dtm.ref; @@ -47,6 +44,7 @@ import org.xml.sax.XMLReader; * coroutine protocol was not being used and was complicating design. * See {@link IncrementalSAXSource}. * */ +@Deprecated public interface CoroutineParser { /** @return the coroutine ID number for this CoroutineParser object. diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMAxisIterNodeList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMAxisIterNodeList.java index 1993bd6b9c6..3fe1fcab5f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMAxisIterNodeList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMAxisIterNodeList.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMAxisIterNodeList.java,v 1.2.4.1 2005/09/15 08:14:59 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTM; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMAxisIteratorBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMAxisIteratorBase.java index b9eecc2cb13..7555044127d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMAxisIteratorBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMAxisIteratorBase.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMAxisIteratorBase.java,v 1.2.4.1 2005/09/15 08:14:59 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTMAxisIterator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMChildIterNodeList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMChildIterNodeList.java index 3d26b53be8d..28004a6ebc8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMChildIterNodeList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMChildIterNodeList.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMChildIterNodeList.java,v 1.2.4.1 2005/09/15 08:15:00 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTM; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBase.java index 58fae690c92..ce91bc21b59 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBase.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMDefaultBase.java,v 1.3 2005/09/28 13:48:52 pvedula Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBaseIterators.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBaseIterators.java index 31c059cd126..f73a4e8de3e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBaseIterators.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBaseIterators.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMDefaultBaseIterators.java,v 1.2.4.1 2005/09/15 08:15:00 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBaseTraversers.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBaseTraversers.java index c33545482ac..bc96dd55124 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBaseTraversers.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDefaultBaseTraversers.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMDefaultBaseTraversers.java,v 1.2.4.1 2005/09/15 08:15:00 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.*; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDocumentImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDocumentImpl.java index b9bb3ace02a..999c3fc01b3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDocumentImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMDocumentImpl.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMDocumentImpl.java,v 1.2.4.1 2005/09/15 08:15:01 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import javax.xml.transform.SourceLocator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMManagerDefault.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMManagerDefault.java index 1eadf3a5950..1cb76b8923d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMManagerDefault.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMManagerDefault.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMManagerDefault.java,v 1.2.4.1 2005/09/15 08:15:02 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xalan.internal.utils.FactoryImpl; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNamedNodeMap.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNamedNodeMap.java index 8c8d1d9ae40..ef81b6e0bf5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNamedNodeMap.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNamedNodeMap.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMNamedNodeMap.java,v 1.2.4.1 2005/09/15 08:15:03 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTM; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeIterator.java index b5a7bb617de..869a478a335 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeIterator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMNodeIterator.java,v 1.2.4.1 2005/09/15 08:15:03 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTM; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeList.java index 3a933c832ff..daab88859dc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeList.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMNodeList.java,v 1.2.4.1 2005/09/15 08:15:04 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTM; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeListBase.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeListBase.java index d21f090d31a..1ae677e3ac2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeListBase.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeListBase.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMNodeListBase.java,v 1.2.4.1 2005/09/15 08:15:04 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import org.w3c.dom.Node; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeProxy.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeProxy.java index 5fdf6535a51..1b66359fb5d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeProxy.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMNodeProxy.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -20,6 +21,7 @@ /* * $Id: DTMNodeProxy.java,v */ + package com.sun.org.apache.xml.internal.dtm.ref; import java.util.Vector; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMSafeStringPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMSafeStringPool.java index e22402d675d..91ebda0e84c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMSafeStringPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMSafeStringPool.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMSafeStringPool.java,v 1.2.4.1 2005/09/15 08:15:04 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.dtm.ref; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMStringPool.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMStringPool.java index d49b62a29ce..cb8bb877dd9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMStringPool.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMStringPool.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMStringPool.java,v 1.2.4.1 2005/09/15 08:15:05 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.dtm.ref; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMTreeWalker.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMTreeWalker.java index 37c72d172d8..85e3e16bf88 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMTreeWalker.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/DTMTreeWalker.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DTMTreeWalker.java,v 1.2.4.1 2005/09/15 08:15:05 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTM; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/EmptyIterator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/EmptyIterator.java index 978ed926486..287636317fe 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/EmptyIterator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/EmptyIterator.java @@ -2,15 +2,15 @@ * reserved comment block * DO NOT REMOVE OR ALTER! */ - /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -18,9 +18,8 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: EmptyIterator.java,v 1.2.4.1 2005/09/15 08:15:05 suresh_emailid Exp $ - */ + + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTMAxisIterator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ExpandedNameTable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ExpandedNameTable.java index 8d4c7a34a22..099b1ec7ecb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ExpandedNameTable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ExpandedNameTable.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExpandedNameTable.java,v 1.2.4.1 2005/09/15 08:15:06 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; import com.sun.org.apache.xml.internal.dtm.DTM; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ExtendedType.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ExtendedType.java index 682986c8a91..2b7696ac98e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ExtendedType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/ExtendedType.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExtendedType.java,v 1.2.4.1 2005/09/15 08:15:06 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource.java index 417454f8e40..1e7efeffd65 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IncrementalSAXSource.java,v 1.2.4.1 2005/09/15 08:15:06 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.dtm.ref; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource_Filter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource_Filter.java index 2d97451a853..3d8dcfb67a7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource_Filter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource_Filter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IncrementalSAXSource_Filter.java,v 1.2.4.1 2005/09/15 08:15:07 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.dtm.ref; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource_Xerces.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource_Xerces.java index 963ccf02c5a..205a4b320c2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource_Xerces.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/IncrementalSAXSource_Xerces.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: IncrementalSAXSource_Xerces.java,v 1.2.4.1 2005/09/15 08:15:08 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.dtm.ref; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/NodeLocator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/NodeLocator.java index 2987dfd5bd9..4ac0e374e5b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/NodeLocator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/NodeLocator.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NodeLocator.java,v 1.2.4.1 2005/09/15 08:15:08 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.dtm.ref; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/dom2dtm/DOM2DTM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/dom2dtm/DOM2DTM.java index 0e871e071e4..ec91b1dd9d0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/dom2dtm/DOM2DTM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/dom2dtm/DOM2DTM.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOM2DTM.java,v 1.2.4.1 2005/09/15 08:15:10 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref.dom2dtm; import java.util.Vector; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/dom2dtm/DOM2DTMdefaultNamespaceDeclarationNode.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/dom2dtm/DOM2DTMdefaultNamespaceDeclarationNode.java index 68cafdd4a1c..a37254bf499 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/dom2dtm/DOM2DTMdefaultNamespaceDeclarationNode.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/dom2dtm/DOM2DTMdefaultNamespaceDeclarationNode.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOM2DTMdefaultNamespaceDeclarationNode.java,v 1.2.4.1 2005/09/15 08:15:11 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.dtm.ref.dom2dtm; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/sax2dtm/SAX2RTFDTM.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/sax2dtm/SAX2RTFDTM.java index c09968f8486..d8206f9e203 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/sax2dtm/SAX2RTFDTM.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/sax2dtm/SAX2RTFDTM.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SAX2RTFDTM.java,v 1.2.4.1 2005/09/15 08:15:13 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.dtm.ref.sax2dtm; import javax.xml.transform.Source; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources.java index 1c83bc50917..9b87c228a99 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ca.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ca.java index 5dcb27c62c5..b5af9d464cb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ca.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ca.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XMLErrorResources_ca.java,v 1.1.6.2 2005/09/15 07:45:37 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_cs.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_cs.java index f3e3c3ec756..d659883015b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_cs.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_cs.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XMLErrorResources_cs.java,v 1.1.6.2 2005/09/15 07:45:38 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_de.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_de.java index 3492aefc9df..5b859177598 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_de.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_de.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_en.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_en.java index 78c9b13db18..b13b612edf8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_en.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_en.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XMLErrorResources_en.java,v 1.2.4.1 2005/09/15 07:45:40 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_es.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_es.java index 471473283d8..7f1fbfe4b4d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_es.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_es.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_fr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_fr.java index 8155bf4889c..26a80d2e161 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_fr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_fr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_it.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_it.java index a86b206b956..2f14e3d3b26 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_it.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_it.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ja.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ja.java index dfa387b18de..cce9b42e61f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ja.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ja.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ko.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ko.java index 4936488bbd9..71bbc951a5b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ko.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_ko.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; @@ -209,10 +211,10 @@ public class XMLErrorResources_ko extends ListResourceBundle "Coroutine \uB9E4\uAC1C\uBCC0\uC218 \uC624\uB958({0})"}, { ER_PARSER_DOTERMINATE_ANSWERS, - "\n\uC608\uC0C1\uCE58 \uC54A\uC740 \uC624\uB958: \uAD6C\uBB38 \uBD84\uC11D\uAE30 doTerminate\uAC00 {0}\uC5D0 \uC751\uB2F5\uD569\uB2C8\uB2E4."}, + "\n\uC608\uC0C1\uCE58 \uC54A\uC740 \uC624\uB958: \uAD6C\uBB38\uBD84\uC11D\uAE30 doTerminate\uAC00 {0}\uC5D0 \uC751\uB2F5\uD569\uB2C8\uB2E4."}, { ER_NO_PARSE_CALL_WHILE_PARSING, - "\uAD6C\uBB38 \uBD84\uC11D \uC911 parse\uB97C \uD638\uCD9C\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, + "\uAD6C\uBB38\uBD84\uC11D \uC911 parse\uB97C \uD638\uCD9C\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, { ER_TYPED_ITERATOR_AXIS_NOT_IMPLEMENTED, "\uC624\uB958: {0} \uCD95\uC5D0 \uB300\uD574 \uC785\uB825\uB41C \uC774\uD130\uB808\uC774\uD130\uAC00 \uAD6C\uD604\uB418\uC9C0 \uC54A\uC558\uC2B5\uB2C8\uB2E4."}, @@ -242,13 +244,13 @@ public class XMLErrorResources_ko extends ListResourceBundle "\uB178\uB4DC\uB97C \uD578\uB4E4\uB85C \uBD84\uC11D\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, { ER_STARTPARSE_WHILE_PARSING, - "\uAD6C\uBB38 \uBD84\uC11D \uC911 startParse\uB97C \uD638\uCD9C\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, + "\uAD6C\uBB38\uBD84\uC11D \uC911 startParse\uB97C \uD638\uCD9C\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, { ER_STARTPARSE_NEEDS_SAXPARSER, "startParse\uC5D0\uB294 \uB110\uC774 \uC544\uB2CC SAXParser\uAC00 \uD544\uC694\uD569\uB2C8\uB2E4."}, { ER_COULD_NOT_INIT_PARSER, - "\uAD6C\uBB38 \uBD84\uC11D\uAE30\uB97C \uCD08\uAE30\uD654\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, + "\uAD6C\uBB38\uBD84\uC11D\uAE30\uB97C \uCD08\uAE30\uD654\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, { ER_EXCEPTION_CREATING_POOL, "\uD480\uC5D0 \uB300\uD55C \uC0C8 \uC778\uC2A4\uD134\uC2A4\uB97C \uC0DD\uC131\uD558\uB294 \uC911 \uC608\uC678\uC0AC\uD56D\uC774 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4."}, @@ -293,10 +295,10 @@ public class XMLErrorResources_ko extends ListResourceBundle "\uBD80\uBD84\uC5D0 \uBD80\uC801\uD569\uD55C \uBB38\uC790\uAC00 \uD3EC\uD568\uB418\uC5B4 \uC788\uC2B5\uB2C8\uB2E4."}, { ER_PARSER_IN_USE, - "\uAD6C\uBB38 \uBD84\uC11D\uAE30\uAC00 \uC774\uBBF8 \uC0AC\uC6A9\uB418\uACE0 \uC788\uC2B5\uB2C8\uB2E4."}, + "\uAD6C\uBB38\uBD84\uC11D\uAE30\uAC00 \uC774\uBBF8 \uC0AC\uC6A9\uB418\uACE0 \uC788\uC2B5\uB2C8\uB2E4."}, { ER_CANNOT_CHANGE_WHILE_PARSING, - "\uAD6C\uBB38 \uBD84\uC11D \uC911 {0} {1}\uC744(\uB97C) \uBCC0\uACBD\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, + "\uAD6C\uBB38\uBD84\uC11D \uC911 {0} {1}\uC744(\uB97C) \uBCC0\uACBD\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4."}, { ER_SELF_CAUSATION_NOT_PERMITTED, "\uC790\uCCB4 \uC778\uACFC \uAD00\uACC4\uB294 \uD5C8\uC6A9\uB418\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4."}, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_pt_BR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_pt_BR.java index 814b19c283f..37ef50ab4b0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_pt_BR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_pt_BR.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_sk.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_sk.java index 1e4b293c59b..5f7eb31248a 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_sk.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_sk.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XMLErrorResources_sk.java,v 1.1.6.2 2005/09/15 07:45:45 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_sv.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_sv.java index 7be3c6ccf0f..417d3543bc5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_sv.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_sv.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; @@ -230,7 +232,7 @@ public class XMLErrorResources_sv extends ListResourceBundle "Axeltravers underst\u00F6ds inte: {0}"}, { ER_NO_DTMIDS_AVAIL, - "Inga fler DTM-ID:n \u00E4r tillg\u00E4ngliga"}, + "Inga fler DTM-id:n \u00E4r tillg\u00E4ngliga"}, { ER_NOT_SUPPORTED, "Underst\u00F6ds inte: {0}"}, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_tr.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_tr.java index 58973c6af99..12a64e74b91 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_tr.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_tr.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XMLErrorResources_tr.java,v 1.1.6.2 2005/09/15 07:45:46 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_CN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_CN.java index c500135f6c1..166cf7c0858 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_CN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_CN.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_HK.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_HK.java index 1a0d14acf90..b495ca3d6ab 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_HK.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_HK.java @@ -3,61 +3,22 @@ * DO NOT REMOVE OR ALTER! */ /* - * The Apache Software License, Version 1.1 + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * + * http://www.apache.org/licenses/LICENSE-2.0 * - * Copyright (c) 1999-2003 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * Apache Software Foundation (http://www.apache.org/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "Xalan" and "Apache Software Foundation" must - * not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact apache@apache.org. - * - * 5. Products derived from this software may not be called "Apache", - * nor may "Apache" appear in their name, without prior written - * permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation and was - * originally based on software copyright (c) 1999, Lotus - * Development Corporation., http://www.lotus.com. For more - * information on the Apache Software Foundation, please see - * . + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_TW.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_TW.java index e1d1976fe1c..fee39804b4c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_TW.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLErrorResources_zh_TW.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.res; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLMessages.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLMessages.java index bb2f9bb4062..59abced5939 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLMessages.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/res/XMLMessages.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XMLMessages.java,v 1.2.4.1 2005/09/15 07:45:48 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.res; import com.sun.org.apache.xalan.internal.utils.SecuritySupport; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/BaseMarkupSerializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/BaseMarkupSerializer.java index 04870a5ca33..a9c912252b4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/BaseMarkupSerializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/BaseMarkupSerializer.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -128,6 +128,7 @@ import org.xml.sax.ext.LexicalHandler; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public abstract class BaseMarkupSerializer implements ContentHandler, DocumentHandler, LexicalHandler, DTDHandler, DeclHandler, DOMSerializer, Serializer diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializer.java index c050e25918d..ee6aaf7c9c9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializer.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -42,6 +41,7 @@ import org.w3c.dom.DocumentFragment; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public interface DOMSerializer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializerImpl.java index 6c2eaf15c53..e436baa5aa2 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializerImpl.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -76,6 +75,7 @@ import org.w3c.dom.ls.LSSerializerFilter; * @deprecated As of JDK 9, Xerces 2.9.0, replaced by * {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl} */ +@Deprecated public class DOMSerializerImpl implements LSSerializer, DOMConfiguration { // TODO: When DOM Level 3 goes to REC replace method calls using diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/ElementState.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/ElementState.java index ebe39118f82..16136dba45f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/ElementState.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/ElementState.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -36,6 +36,7 @@ import java.util.Map; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class ElementState { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/EncodingInfo.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/EncodingInfo.java index 62e4f0639ba..0fc22beb660 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/EncodingInfo.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/EncodingInfo.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -37,6 +36,7 @@ import java.nio.charset.CharsetEncoder; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class EncodingInfo { // name of encoding as registered with IANA; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Encodings.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Encodings.java index 0ed64ed9618..0aa48d2ef64 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Encodings.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Encodings.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -42,6 +42,7 @@ import java.util.concurrent.ConcurrentHashMap; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated class Encodings { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLSerializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLSerializer.java index 454084a7b00..c0656a792f4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLSerializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLSerializer.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -92,6 +92,7 @@ import org.xml.sax.SAXException; * @author Assaf Arkin * @see Serializer */ +@Deprecated public class HTMLSerializer extends BaseMarkupSerializer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLdtd.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLdtd.java index 4d2a7d3f517..68f7a89bd84 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLdtd.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLdtd.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -51,6 +51,7 @@ import java.util.Map; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public final class HTMLdtd { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/IndentPrinter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/IndentPrinter.java index e212792ec04..d30607f1a61 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/IndentPrinter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/IndentPrinter.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -39,6 +38,7 @@ import java.io.IOException; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class IndentPrinter extends Printer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/LineSeparator.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/LineSeparator.java index dc3afb18bbf..8e971607a42 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/LineSeparator.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/LineSeparator.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -32,6 +31,7 @@ package com.sun.org.apache.xml.internal.serialize; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public final class LineSeparator { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Method.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Method.java index de2bdd96609..43ff3d030fa 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Method.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Method.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -32,6 +31,7 @@ package com.sun.org.apache.xml.internal.serialize; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public final class Method { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/OutputFormat.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/OutputFormat.java index 7230c04d2a7..65305330a7b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/OutputFormat.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/OutputFormat.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -65,6 +64,7 @@ import org.w3c.dom.Node; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class OutputFormat { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Printer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Printer.java index 8a8d9b70fa7..c9b664e6fcc 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Printer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Printer.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -47,6 +46,7 @@ import java.io.IOException; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class Printer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SecuritySupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SecuritySupport.java index 02d8a01a443..f9294958150 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SecuritySupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SecuritySupport.java @@ -3,11 +3,12 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2002,2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Serializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Serializer.java index 675cc4d2e61..051686f0898 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Serializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Serializer.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -67,6 +66,7 @@ import org.xml.sax.DocumentHandler; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public interface Serializer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactory.java index 4d8ea0b264f..5ffa65b23b9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -42,6 +42,7 @@ import java.util.StringTokenizer; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public abstract class SerializerFactory { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactoryImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactoryImpl.java index 157cf1cab6d..7da1e044934 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactoryImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactoryImpl.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -41,6 +40,7 @@ import com.sun.org.apache.xerces.internal.dom.DOMMessageFormatter; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated final class SerializerFactoryImpl extends SerializerFactory { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/TextSerializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/TextSerializer.java index ec6a118c4a6..a8ff229e835 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/TextSerializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/TextSerializer.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -65,6 +64,7 @@ import org.xml.sax.SAXException; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class TextSerializer extends BaseMarkupSerializer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XHTMLSerializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XHTMLSerializer.java index 5925a250b14..cf61d267401 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XHTMLSerializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XHTMLSerializer.java @@ -1,13 +1,13 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -38,6 +38,7 @@ import java.io.Writer; * @author Assaf Arkin * @see Serializer */ +@Deprecated public class XHTMLSerializer extends HTMLSerializer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XML11Serializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XML11Serializer.java index 619e111dbe5..3f604523c8d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XML11Serializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XML11Serializer.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -84,6 +83,7 @@ import org.xml.sax.SAXException; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class XML11Serializer extends XMLSerializer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XMLSerializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XMLSerializer.java index 84184cffb24..a28ccd65233 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XMLSerializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XMLSerializer.java @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -95,6 +94,7 @@ import org.xml.sax.helpers.AttributesImpl; * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class XMLSerializer extends BaseMarkupSerializer { diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/CharInfo.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/CharInfo.java index 04e77d6bc62..c60c29bab1f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/CharInfo.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/CharInfo.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CharInfo.java,v 1.2.4.1 2005/09/15 08:15:14 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import com.sun.org.apache.xalan.internal.utils.SecuritySupport; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/DOMSerializer.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/DOMSerializer.java index e87c2c2a339..971569dbc81 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/DOMSerializer.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/DOMSerializer.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOMSerializer.java,v 1.2.4.1 2005/09/15 08:15:15 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ElemContext.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ElemContext.java index 805d7c77b3d..e4cebb5a2e1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ElemContext.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ElemContext.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ElemContext.java,v 1.2.4.1 2005/09/15 08:15:15 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ElemDesc.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ElemDesc.java index 5670952b8f8..85af27ddfbf 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ElemDesc.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ElemDesc.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ElemDesc.java,v 1.2.4.1 2005/09/15 08:15:15 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import com.sun.org.apache.xml.internal.serializer.utils.StringToIntTable; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/EncodingInfo.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/EncodingInfo.java index 60d503d0b36..fc4f11a3fca 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/EncodingInfo.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/EncodingInfo.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: EncodingInfo.java,v 1.2.4.2 2005/09/15 12:01:24 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.io.UnsupportedEncodingException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Encodings.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Encodings.java index 18e76134891..50bad3d7a59 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Encodings.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Encodings.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Encodings.java,v 1.3 2005/09/28 13:49:04 pvedula Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.io.InputStream; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ExtendedContentHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ExtendedContentHandler.java index 6deefb27b09..a1b957ed7e9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ExtendedContentHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ExtendedContentHandler.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExtendedContentHandler.java,v 1.2.4.1 2005/09/15 08:15:17 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import javax.xml.transform.SourceLocator; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ExtendedLexicalHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ExtendedLexicalHandler.java index 4983dbef301..bf3126851c8 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ExtendedLexicalHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ExtendedLexicalHandler.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ExtendedLexicalHandler.java,v 1.2.4.1 2005/09/15 08:15:18 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import org.xml.sax.SAXException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Method.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Method.java index cecacc1238f..fd1468e3c0b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Method.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Method.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Method.java,v 1.2.4.1 2005/09/15 08:15:19 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/NamespaceMappings.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/NamespaceMappings.java index 5df83c16871..f917470dd50 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/NamespaceMappings.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/NamespaceMappings.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: NamespaceMappings.java,v 1.2.4.1 2005/09/15 08:15:19 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.util.HashMap; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/OutputPropertiesFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/OutputPropertiesFactory.java index 0d91b7aeb3c..86736b95489 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/OutputPropertiesFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/OutputPropertiesFactory.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: OutputPropertiesFactory.java,v 1.2.4.1 2005/09/15 08:15:21 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import com.sun.org.apache.xalan.internal.utils.SecuritySupport; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/OutputPropertyUtils.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/OutputPropertyUtils.java index 7e4ccb99ae3..364fb9965bb 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/OutputPropertyUtils.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/OutputPropertyUtils.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: OutputPropertyUtils.java,v 1.2.4.1 2005/09/15 08:15:21 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.util.Properties; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerConstants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerConstants.java index c8a4fce96af..ad08ecec9b1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerConstants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerConstants.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SerializerConstants.java,v 1.2.4.1 2005/09/15 08:15:23 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerFactory.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerFactory.java index d4ce9cf772e..10d6d19ee31 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerFactory.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerFactory.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SerializerFactory.java,v 1.2.4.1 2005/09/15 08:15:24 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.util.Properties; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerTrace.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerTrace.java index 0710412f10a..048bba1ed17 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerTrace.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerTrace.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SerializerTrace.java,v 1.2.4.1 2005/09/15 08:15:24 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import org.xml.sax.Attributes; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerTraceWriter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerTraceWriter.java index 482faad9ab2..49de2d95db3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerTraceWriter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/SerializerTraceWriter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2003-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SerializerTraceWriter.java,v 1.2.4.1 2005/09/15 08:15:25 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToHTMLSAXHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToHTMLSAXHandler.java index 596a6418e53..41fcec8002c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToHTMLSAXHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToHTMLSAXHandler.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ToHTMLSAXHandler.java,v 1.3 2005/09/28 13:49:07 pvedula Exp $ - */ package com.sun.org.apache.xml.internal.serializer; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToHTMLStream.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToHTMLStream.java index 502a8b8debb..c9358da0678 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToHTMLStream.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToHTMLStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -717,7 +717,9 @@ public final class ToHTMLStream extends ToStream */ public final void endDocument() throws org.xml.sax.SAXException { - flushCharactersBuffer(); + if (m_doIndent) { + flushCharactersBuffer(); + } flushPending(); if (m_doIndent && !m_isprevtext) { @@ -776,9 +778,11 @@ public final class ToHTMLStream extends ToStream Attributes atts) throws SAXException { - // will add extra one if having namespace but no matter - m_childNodeNum++; - flushCharactersBuffer(); + if (m_doIndent) { + // will add extra one if having namespace but no matter + m_childNodeNum++; + flushCharactersBuffer(); + } ElemContext elemContext = m_elemContext; // clean up any pending things first @@ -839,8 +843,10 @@ public final class ToHTMLStream extends ToStream writer.write('<'); writer.write(name); - m_childNodeNumStack.push(m_childNodeNum); - m_childNodeNum = 0; + if (m_doIndent) { + m_childNodeNumStack.add(m_childNodeNum); + m_childNodeNum = 0; + } if (m_tracer != null) firePseudoAttributes(); @@ -915,7 +921,9 @@ public final class ToHTMLStream extends ToStream final String name) throws org.xml.sax.SAXException { - flushCharactersBuffer(); + if (m_doIndent) { + flushCharactersBuffer(); + } // deal with any pending issues if (m_cdataTagOpen) closeCDATA(); @@ -997,12 +1005,11 @@ public final class ToHTMLStream extends ToStream } } - m_childNodeNum = m_childNodeNumStack.pop(); - // clean up because the element has ended - if ((elemFlags & ElemDesc.WHITESPACESENSITIVE) != 0) - m_ispreserve = true; - m_isprevtext = false; - + if (m_doIndent) { + m_childNodeNum = m_childNodeNumStack.remove(m_childNodeNumStack.size() - 1); + // clean up because the element has ended + m_isprevtext = false; + } // fire off the end element event if (m_tracer != null) super.fireEndElem(name); @@ -1018,11 +1025,6 @@ public final class ToHTMLStream extends ToStream } // some more clean because the element has ended. - if (!elemContext.m_startTagOpen) - { - if (m_doIndent && !m_preserves.isEmpty()) - m_preserves.pop(); - } m_elemContext = elemContext.m_prev; // m_isRawStack.pop(); } @@ -1525,7 +1527,6 @@ public final class ToHTMLStream extends ToStream closeStartTag(); m_elemContext.m_startTagOpen = false; } - m_ispreserve = true; // With m_ispreserve just set true it looks like shouldIndent() // will always return false, so drop any possible indentation. @@ -1602,8 +1603,6 @@ public final class ToHTMLStream extends ToStream m_elemContext.m_startTagOpen = false; } - m_ispreserve = true; - if (shouldIndent()) indent(); @@ -1640,8 +1639,10 @@ public final class ToHTMLStream extends ToStream public void processingInstruction(String target, String data) throws org.xml.sax.SAXException { - m_childNodeNum++; - flushCharactersBuffer(); + if (m_doIndent) { + m_childNodeNum++; + flushCharactersBuffer(); + } // Process any pending starDocument and startElement first. flushPending(); @@ -1790,11 +1791,6 @@ public final class ToHTMLStream extends ToStream */ if (m_StringOfCDATASections != null) m_elemContext.m_isCdataSection = isCdataSection(); - if (m_doIndent) - { - m_isprevtext = false; - m_preserves.push(m_ispreserve); - } } catch(IOException e) diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToStream.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToStream.java index 994a7800d97..ae14a4922b1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToStream.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToStream.java @@ -20,34 +20,36 @@ package com.sun.org.apache.xml.internal.serializer; -import com.sun.org.apache.xalan.internal.utils.SecuritySupport; -import com.sun.org.apache.xml.internal.serializer.utils.MsgKey; -import com.sun.org.apache.xml.internal.serializer.utils.Utils; -import com.sun.org.apache.xml.internal.serializer.utils.WrappedRuntimeException; import java.io.IOException; import java.io.OutputStream; import java.io.OutputStreamWriter; import java.io.UnsupportedEncodingException; import java.io.Writer; -import java.util.ArrayDeque; import java.util.ArrayList; import java.util.Arrays; -import java.util.Deque; import java.util.EmptyStackException; import java.util.Enumeration; +import java.util.Iterator; +import java.util.List; import java.util.Properties; -import java.util.Queue; import java.util.Set; import java.util.StringTokenizer; + import javax.xml.transform.ErrorListener; import javax.xml.transform.OutputKeys; import javax.xml.transform.Transformer; import javax.xml.transform.TransformerException; + import org.w3c.dom.Node; import org.xml.sax.Attributes; import org.xml.sax.ContentHandler; import org.xml.sax.SAXException; +import com.sun.org.apache.xalan.internal.utils.SecuritySupport; +import com.sun.org.apache.xml.internal.serializer.utils.MsgKey; +import com.sun.org.apache.xml.internal.serializer.utils.Utils; +import com.sun.org.apache.xml.internal.serializer.utils.WrappedRuntimeException; + /** * This abstract class is a base class for other stream * serializers (xml, html, text ...) that write output to a stream. @@ -103,7 +105,7 @@ abstract public class ToStream extends SerializerBase { * If m_childNodeNum > 1, the text node will be indented. * */ - protected Deque m_childNodeNumStack = new ArrayDeque<>(); + protected List m_childNodeNumStack = new ArrayList<>(); protected int m_childNodeNum = 0; @@ -115,26 +117,6 @@ abstract public class ToStream extends SerializerBase { protected boolean m_ispreserveSpace = false; - /** - * Stack to keep track of whether or not we need to - * preserve whitespace. - * - * Used to push/pop values used for the field m_ispreserve, but - * m_ispreserve is only relevant if m_doIndent is true. - * If m_doIndent is false this field has no impact. - * - */ - protected BoolStack m_preserves = new BoolStack(); - - /** - * State flag to tell if preservation of whitespace - * is important. - * - * Used only in shouldIndent() but only if m_doIndent is true. - * If m_doIndent is false this flag has no impact. - * - */ - protected boolean m_ispreserve = false; /** * State flag that tells if the previous node processed @@ -1267,7 +1249,6 @@ abstract public class ToStream extends SerializerBase { closeStartTag(); m_elemContext.m_startTagOpen = false; } - m_ispreserve = true; if (shouldIndent()) indent(); @@ -1357,8 +1338,6 @@ abstract public class ToStream extends SerializerBase { m_elemContext.m_startTagOpen = false; } - m_ispreserve = true; - m_writer.write(ch, start, length); } catch (IOException e) @@ -1405,8 +1384,8 @@ abstract public class ToStream extends SerializerBase { if (length == 0 || (isInEntityRef())) return; - final boolean shouldFormat = shouldFormatOutput(); - if (m_elemContext.m_startTagOpen && !shouldFormat) + final boolean shouldNotFormat = !shouldFormatOutput(); + if (m_elemContext.m_startTagOpen) { closeStartTag(); m_elemContext.m_startTagOpen = false; @@ -1432,8 +1411,12 @@ abstract public class ToStream extends SerializerBase { if (m_disableOutputEscapingStates.peekOrFalse() || (!m_escaping)) { - charactersRaw(chars, start, length); - m_isprevtext = true; + if (shouldNotFormat) { + charactersRaw(chars, start, length); + m_isprevtext = true; + } else { + m_charactersBuffer.addRawText(chars, start, length); + } // time to fire off characters generation event if (m_tracer != null) super.fireCharEvent(chars, start, length); @@ -1441,16 +1424,16 @@ abstract public class ToStream extends SerializerBase { return; } - if (m_elemContext.m_startTagOpen && !shouldFormat) + if (m_elemContext.m_startTagOpen) { closeStartTag(); m_elemContext.m_startTagOpen = false; } - if (shouldFormat) { - m_charactersBuffer.addText(chars, start, length); - } else { + if (shouldNotFormat) { outputCharacters(chars, start, length); + } else { + m_charactersBuffer.addText(chars, start, length); } // time to fire off characters generation event @@ -1465,7 +1448,14 @@ abstract public class ToStream extends SerializerBase { * @return True if the content should be formatted. */ protected boolean shouldFormatOutput() { - return !m_ispreserveSpace && m_doIndent; + return m_doIndent && !m_ispreserveSpace; + } + + /** + * @return True if the content in current element should be formatted. + */ + public boolean getIndent() { + return shouldFormatOutput(); } /** @@ -1506,12 +1496,6 @@ abstract public class ToStream extends SerializerBase { i = lastDirty; } } - /* If there is some non-whitespace, mark that we may need - * to preserve this. This is only important if we have indentation on. - */ - if (i < end) - m_ispreserve = true; - // int lengthClean; // number of clean characters in a row // final boolean[] isAsciiClean = m_charInfo.getASCIIClean(); @@ -1577,12 +1561,7 @@ abstract public class ToStream extends SerializerBase { */ final protected void flushCharactersBuffer() throws SAXException { try { - if (shouldFormatOutput() && m_charactersBuffer.hasContent()) { - if (m_elemContext.m_startTagOpen) { - closeStartTag(); - m_elemContext.m_startTagOpen = false; - } - + if (shouldFormatOutput() && m_charactersBuffer.isAnyCharactersBuffered()) { if (m_elemContext.m_isCdataSection) { /* * due to cdata-section-elements atribute, we need this as @@ -1594,11 +1573,16 @@ abstract public class ToStream extends SerializerBase { } m_childNodeNum++; + boolean skipBeginningNewlines = false; if (shouldIndentForText()) { indent(); m_startNewLine = true; + // newline has always been added here because if this is the + // text before the first element, shouldIndent() won't + // return true. + skipBeginningNewlines = true; } - m_charactersBuffer.flush(); + m_charactersBuffer.flush(skipBeginningNewlines); } } catch (IOException e) { throw new SAXException(e); @@ -1858,8 +1842,10 @@ abstract public class ToStream extends SerializerBase { if (isInEntityRef()) return; - m_childNodeNum++; - flushCharactersBuffer(); + if (m_doIndent) { + m_childNodeNum++; + flushCharactersBuffer(); + } if (m_needToCallStartDocument) { @@ -1890,8 +1876,6 @@ abstract public class ToStream extends SerializerBase { if (namespaceURI != null) ensurePrefixIsDeclared(namespaceURI, name); - m_ispreserve = false; - if (shouldIndent() && m_startNewLine) { indent(); @@ -1912,11 +1896,13 @@ abstract public class ToStream extends SerializerBase { if (atts != null) addAttributes(atts); - m_ispreserveSpace = m_preserveSpaces.peekOrFalse(); - m_preserveSpaces.push(m_ispreserveSpace); + if (m_doIndent) { + m_ispreserveSpace = m_preserveSpaces.peekOrFalse(); + m_preserveSpaces.push(m_ispreserveSpace); - m_childNodeNumStack.push(m_childNodeNum); - m_childNodeNum = 0; + m_childNodeNumStack.add(m_childNodeNum); + m_childNodeNum = 0; + } m_elemContext = m_elemContext.push(namespaceURI,localName,name); m_isprevtext = false; @@ -2128,7 +2114,9 @@ abstract public class ToStream extends SerializerBase { if (isInEntityRef()) return; - flushCharactersBuffer(); + if (m_doIndent) { + flushCharactersBuffer(); + } // namespaces declared at the current depth are no longer valid // so get rid of them m_prefixMap.popNamespaces(m_elemContext.m_currentElemDepth, null); @@ -2175,16 +2163,13 @@ abstract public class ToStream extends SerializerBase { throw new SAXException(e); } - if (!m_elemContext.m_startTagOpen && m_doIndent) - { - m_ispreserve = m_preserves.isEmpty() ? false : m_preserves.pop(); + if (m_doIndent) { + m_ispreserveSpace = m_preserveSpaces.popAndTop(); + m_childNodeNum = m_childNodeNumStack.remove(m_childNodeNumStack.size() - 1); + + m_isprevtext = false; } - m_ispreserveSpace = m_preserveSpaces.popAndTop(); - m_childNodeNum = m_childNodeNumStack.pop(); - - m_isprevtext = false; - // fire off the end element event if (m_tracer != null) super.fireEndElem(name); @@ -2320,8 +2305,10 @@ abstract public class ToStream extends SerializerBase { int start_old = start; if (isInEntityRef()) return; - m_childNodeNum++; - flushCharactersBuffer(); + if (m_doIndent) { + m_childNodeNum++; + flushCharactersBuffer(); + } if (m_elemContext.m_startTagOpen) { closeStartTag(); @@ -2501,8 +2488,10 @@ abstract public class ToStream extends SerializerBase { */ public void startCDATA() throws org.xml.sax.SAXException { - m_childNodeNum++; - flushCharactersBuffer(); + if (m_doIndent) { + m_childNodeNum++; + flushCharactersBuffer(); + } m_cdataStartCalled = true; } @@ -2588,12 +2577,6 @@ abstract public class ToStream extends SerializerBase { */ if (m_StringOfCDATASections != null) m_elemContext.m_isCdataSection = isCdataSection(); - - if (m_doIndent) - { - m_isprevtext = false; - m_preserves.push(m_ispreserve); - } } } @@ -2943,7 +2926,9 @@ abstract public class ToStream extends SerializerBase { String value, boolean xslAttribute) { - if (m_charactersBuffer.isAnyCharactersBuffered()) { + if (!m_charactersBuffer.isAnyCharactersBuffered()) { + return doAddAttributeAlways(uri, localName, rawName, type, value, xslAttribute); + } else { /* * If stylesheet includes xsl:copy-of an attribute node, XSLTC will * fire an addAttribute event. When a text node is handling in @@ -2954,8 +2939,6 @@ abstract public class ToStream extends SerializerBase { * */ return m_attributes.getIndex(rawName) < 0; - } else { - return doAddAttributeAlways(uri, localName, rawName, type, value, xslAttribute); } } @@ -3086,7 +3069,7 @@ abstract public class ToStream extends SerializerBase { } } - if (rawName.equals("xml:space")) { + if (m_doIndent && rawName.equals("xml:space")) { if (value.equals("preserve")) { m_ispreserveSpace = true; if (m_preserveSpaces.size() > 0) @@ -3227,8 +3210,6 @@ abstract public class ToStream extends SerializerBase { // Leave m_format alone for now - Brian M. // this.m_format = null; this.m_inDoctype = false; - this.m_ispreserve = false; - this.m_preserves.clear(); this.m_ispreserveSpace = false; this.m_preserveSpaces.clear(); this.m_childNodeNum = 0; @@ -3411,6 +3392,7 @@ abstract public class ToStream extends SerializerBase { } } + /** * This inner class is used to buffer the text nodes and the entity * reference nodes if indentation is on. There is only one CharacterBuffer @@ -3425,20 +3407,21 @@ abstract public class ToStream extends SerializerBase { */ private abstract class GenericCharacters { /** - * @return True if having any character other than whitespace or - * line feed. + * @return True if all characters in this Text are newlines. */ - abstract boolean hasContent(); - - abstract void flush() throws SAXException; + abstract boolean flush(boolean skipBeginningNewlines) throws SAXException; /** - * Converts this GenericCharacters to a new character array. + * Converts this GenericCharacters to a new character array. This + * method is used to handle cdata-section-elements attribute in + * xsl:output. Therefore it doesn't need to consider + * skipBeginningNewlines because the text will be involved with CDATA + * tag. */ abstract char[] toChars(); } - private Queue bufferedCharacters = new ArrayDeque<>(); + private List bufferedCharacters = new ArrayList<>(); /** * Append a text node to the buffer. @@ -3451,27 +3434,21 @@ abstract public class ToStream extends SerializerBase { text = Arrays.copyOfRange(chars, start, start + length); } - boolean hasContent() { - for (int i = 0; i < text.length; i++) { - if (!isWhiteSpace(text[i])) { + boolean flush(boolean skipBeginningNewlines) throws SAXException { + int start = 0; + while (skipBeginningNewlines && text[start] == '\n') { + start++; + if (start == text.length) { return true; } } + outputCharacters(text, start, text.length - start); return false; } - void flush() throws SAXException { - outputCharacters(text, 0, text.length); - } - char[] toChars() { return text; } - - boolean isWhiteSpace(char ch) { - return ch == ' ' || ch == '\t' || ch == '\n' || ch == '\r'; - } - }); } @@ -3480,12 +3457,22 @@ abstract public class ToStream extends SerializerBase { */ public void addEntityReference(String entityName) { bufferedCharacters.add(new GenericCharacters() { - boolean hasContent() { - return true; - } - - void flush() throws SAXException { - outputEntityReference(entityName); + boolean flush(boolean skipBeginningNewlines) throws SAXException { + if (m_elemContext.m_startTagOpen) + { + closeStartTag(); + m_elemContext.m_startTagOpen = false; + } + if (m_cdataTagOpen) + closeCDATA(); + char[] cs = toChars(); + try { + m_writer.write(cs, 0, cs.length); + m_isprevtext = true; + } catch (IOException e) { + throw new SAXException(e); + } + return false; } char[] toChars() { @@ -3495,35 +3482,69 @@ abstract public class ToStream extends SerializerBase { } /** - * @return True if any GenericCharacters is already buffered. + * Append a raw text to the buffer. Used to handle raw characters event. */ - public boolean isAnyCharactersBuffered() { - return !bufferedCharacters.isEmpty(); + public void addRawText(final char chars[], final int start, final int length) { + bufferedCharacters.add(new GenericCharacters() { + char[] text; + + { + text = Arrays.copyOfRange(chars, start, start + length); + } + + boolean flush(boolean skipBeginningNewlines) throws SAXException { + try { + int start = 0; + while (skipBeginningNewlines && text[start] == '\n') { + start++; + if (start == text.length) { + return true; + } + } + m_writer.write(text, start, text.length - start); + m_isprevtext = true; + } catch (IOException e) { + throw new SAXException(e); + } + return false; + } + + char[] toChars() { + return text; + } + }); } /** - * @return True if any buffered GenericCharacters has content. + * @return True if any GenericCharacters are buffered. */ - public boolean hasContent() { - return bufferedCharacters.stream().anyMatch(GenericCharacters::hasContent); + public boolean isAnyCharactersBuffered() { + return bufferedCharacters.size() > 0; } /** * Flush all buffered GenericCharacters. */ - public void flush() throws SAXException { - GenericCharacters element; - while ((element = bufferedCharacters.poll()) != null) - element.flush(); + public void flush(boolean skipBeginningNewlines) throws SAXException { + Iterator itr = bufferedCharacters.iterator(); + + boolean continueSkipBeginningNewlines = skipBeginningNewlines; + while (itr.hasNext()) { + GenericCharacters element = itr.next(); + continueSkipBeginningNewlines = element.flush(continueSkipBeginningNewlines); + itr.remove(); + } } /** * Converts all buffered GenericCharacters to a new character array. */ public char[] toChars() { - return bufferedCharacters.stream().map(GenericCharacters::toChars) - .collect(StringBuilder::new, StringBuilder::append, StringBuilder::append).toString() - .toCharArray(); + StringBuilder sb = new StringBuilder(); + for (GenericCharacters element : bufferedCharacters) { + sb.append(element.toChars()); + } + return sb.toString().toCharArray(); } /** @@ -3534,6 +3555,7 @@ abstract public class ToStream extends SerializerBase { } } + // Implement DTDHandler /** * If this method is called, the serializer is used as a diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToTextSAXHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToTextSAXHandler.java index f76c55227da..2aa6c440577 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToTextSAXHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToTextSAXHandler.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ToTextSAXHandler.java,v 1.3 2005/09/28 13:49:08 pvedula Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToTextStream.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToTextStream.java index 9e39b89f7ab..f4d7823c296 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToTextStream.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToTextStream.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ToTextStream.java,v 1.2.4.1 2005/09/21 10:35:34 pvedula Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToXMLSAXHandler.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToXMLSAXHandler.java index 7b165e4116f..d0551594d43 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToXMLSAXHandler.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToXMLSAXHandler.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2001-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: ToXMLSAXHandler.java,v 1.3 2005/09/28 13:49:08 pvedula Exp $ - */ package com.sun.org.apache.xml.internal.serializer; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToXMLStream.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToXMLStream.java index 681737ebc88..adc85a365e5 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToXMLStream.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/ToXMLStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -88,8 +88,6 @@ public final class ToXMLStream extends ToStream setOmitXMLDeclaration(xmlListener.getOmitXMLDeclaration()); - m_ispreserve = xmlListener.m_ispreserve; - m_preserves = xmlListener.m_preserves; m_ispreserveSpace = xmlListener.m_ispreserveSpace; m_preserveSpaces = xmlListener.m_preserveSpaces; m_childNodeNum = xmlListener.m_childNodeNum; @@ -201,7 +199,9 @@ public final class ToXMLStream extends ToStream */ public void endDocument() throws org.xml.sax.SAXException { - flushCharactersBuffer(); + if (m_doIndent) { + flushCharactersBuffer(); + } flushPending(); if (m_doIndent && !m_isprevtext) { @@ -235,11 +235,6 @@ public final class ToXMLStream extends ToStream */ public void startPreserving() throws org.xml.sax.SAXException { - - // Not sure this is really what we want. -sb - m_preserves.push(true); - - m_ispreserve = true; } /** @@ -251,9 +246,6 @@ public final class ToXMLStream extends ToStream */ public void endPreserving() throws org.xml.sax.SAXException { - - // Not sure this is really what we want. -sb - m_ispreserve = m_preserves.isEmpty() ? false : m_preserves.pop(); } /** @@ -273,8 +265,10 @@ public final class ToXMLStream extends ToStream if (isInEntityRef()) return; - m_childNodeNum++; - flushCharactersBuffer(); + if (m_doIndent) { + m_childNodeNum++; + flushCharactersBuffer(); + } flushPending(); if (target.equals(Result.PI_DISABLE_OUTPUT_ESCAPING)) diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TransformStateSetter.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TransformStateSetter.java index cb8d4e57b1b..37bc0e5302b 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TransformStateSetter.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TransformStateSetter.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: TransformStateSetter.java,v 1.2.4.1 2005/09/15 08:15:29 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import javax.xml.transform.Transformer; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TreeWalker.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TreeWalker.java index e11e8e1b321..ea8512643d0 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TreeWalker.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TreeWalker.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -17,13 +17,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.serializer; -import com.sun.org.apache.xalan.internal.utils.SecuritySupport; -import java.io.File; - -import com.sun.org.apache.xml.internal.serializer.utils.AttList; -import com.sun.org.apache.xml.internal.serializer.utils.DOM2Helper; +import com.sun.org.apache.xml.internal.utils.AttList; +import com.sun.org.apache.xml.internal.utils.DOM2Helper; +import javax.xml.transform.Result; import org.w3c.dom.Comment; import org.w3c.dom.Element; import org.w3c.dom.EntityReference; @@ -31,7 +30,6 @@ import org.w3c.dom.NamedNodeMap; import org.w3c.dom.Node; import org.w3c.dom.ProcessingInstruction; import org.w3c.dom.Text; - import org.xml.sax.ContentHandler; import org.xml.sax.Locator; import org.xml.sax.ext.LexicalHandler; @@ -58,12 +56,6 @@ public final class TreeWalker */ final private SerializationHandler m_Serializer; - // ARGHH!! JAXP Uses Xerces without setting the namespace processing to ON! - // DOM2Helper m_dh = new DOM2Helper(); - - /** DomHelper for this TreeWalker */ - final protected DOM2Helper m_dh; - /** Locator object for this TreeWalker */ final private LocatorImpl m_locator = new LocatorImpl(); @@ -78,7 +70,7 @@ public final class TreeWalker } public TreeWalker(ContentHandler ch) { - this(ch,null); + this(ch, null); } /** * Constructor. @@ -99,8 +91,6 @@ public final class TreeWalker if (systemId != null) { m_locator.setSystemId(systemId); } - - m_dh = new DOM2Helper(); } /** @@ -209,7 +199,7 @@ public final class TreeWalker this.m_contentHandler.endDocument(); } - /** Flag indicating whether following text to be processed is raw text */ + // Flag indicating whether following text to be processed is raw text boolean nextIsRaw = false; /** @@ -313,7 +303,6 @@ public final class TreeWalker final int colon = attrName.indexOf(':'); final String prefix; - // System.out.println("TreeWalker#startNode: attr["+i+"] = "+attrName+", "+attr.getNodeValue()); if (attrName.equals("xmlns") || attrName.startsWith("xmlns:")) { // Use "" instead of null, as Xerces likes "" for the @@ -335,13 +324,13 @@ public final class TreeWalker } } - String ns = m_dh.getNamespaceOfNode(node); + String ns = DOM2Helper.getNamespaceOfNode(node); if(null == ns) ns = ""; this.m_contentHandler.startElement(ns, - m_dh.getLocalNameOfNode(node), + DOM2Helper.getLocalNameOfNode(node), node.getNodeName(), - new AttList(atts, m_dh)); + new AttList(atts)); break; case Node.PROCESSING_INSTRUCTION_NODE : { @@ -389,9 +378,9 @@ public final class TreeWalker { nextIsRaw = false; - m_contentHandler.processingInstruction(javax.xml.transform.Result.PI_DISABLE_OUTPUT_ESCAPING, ""); + m_contentHandler.processingInstruction(Result.PI_DISABLE_OUTPUT_ESCAPING, ""); dispatachChars(node); - m_contentHandler.processingInstruction(javax.xml.transform.Result.PI_ENABLE_OUTPUT_ESCAPING, ""); + m_contentHandler.processingInstruction(Result.PI_ENABLE_OUTPUT_ESCAPING, ""); } else { @@ -436,12 +425,12 @@ public final class TreeWalker break; case Node.ELEMENT_NODE : - String ns = m_dh.getNamespaceOfNode(node); + String ns = DOM2Helper.getNamespaceOfNode(node); if(null == ns) ns = ""; this.m_contentHandler.endElement(ns, - m_dh.getLocalNameOfNode(node), - node.getNodeName()); + DOM2Helper.getLocalNameOfNode(node), + node.getNodeName()); if (m_Serializer == null) { // Don't bother with endPrefixMapping calls if the ContentHandler is a diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Version.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Version.java index dfdde0ceac6..fed129f29a9 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Version.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/Version.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Version.java,v 1.2 2005/09/28 13:49:09 pvedula Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/WriterChain.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/WriterChain.java index bf5d466892c..addfbde3c50 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/WriterChain.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/WriterChain.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: WriterChain.java,v 1.1.4.1 2005/09/08 10:58:44 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/WriterToASCI.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/WriterToASCI.java index cfbbd9ca719..1abadb92ed4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/WriterToASCI.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/WriterToASCI.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: WriterToASCI.java,v 1.2.4.1 2005/09/15 08:15:31 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOM3SerializerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOM3SerializerImpl.java index 0d4509c2a97..4fe5c93c302 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOM3SerializerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOM3SerializerImpl.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOM3TreeWalker.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOM3TreeWalker.java index 68864ca7800..400741e330f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOM3TreeWalker.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOM3TreeWalker.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -1024,7 +1024,8 @@ final class DOM3TreeWalker { return; } - if (bDispatch) { + if (bDispatch + && (!fSerializer.getIndent() || !node.getData().replace('\n', ' ').trim().isEmpty())) { dispatachChars(node); } } diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMConstants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMConstants.java index 07f19b29d1f..c50cdf66c8d 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMConstants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMConstants.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -15,9 +19,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: $ - */ package com.sun.org.apache.xml.internal.serializer.dom3; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMErrorHandlerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMErrorHandlerImpl.java index e1b577ffaa9..e74896adc48 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMErrorHandlerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMErrorHandlerImpl.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -15,9 +19,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: $ - */ package com.sun.org.apache.xml.internal.serializer.dom3; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMErrorImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMErrorImpl.java index a143f65491e..9566b3f4f85 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMErrorImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMErrorImpl.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -15,9 +19,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: $ - */ package com.sun.org.apache.xml.internal.serializer.dom3; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMLocatorImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMLocatorImpl.java index f0e87c340f4..e5b0124dd64 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMLocatorImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMLocatorImpl.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -15,9 +19,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: $ - */ package com.sun.org.apache.xml.internal.serializer.dom3; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMOutputImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMOutputImpl.java index d6c0a5d59a8..6b4682e5eac 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMOutputImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMOutputImpl.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -15,9 +19,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: $ - */ package com.sun.org.apache.xml.internal.serializer.dom3; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMStringListImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMStringListImpl.java index 11eac2aa2e8..7ebee3ca4b3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMStringListImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/DOMStringListImpl.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -15,9 +19,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: $ - */ + package com.sun.org.apache.xml.internal.serializer.dom3; import java.util.Vector; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/LSSerializerImpl.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/LSSerializerImpl.java index bf6e5e1867f..897ef03ef7e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/LSSerializerImpl.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/LSSerializerImpl.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -15,9 +19,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: $ - */ package com.sun.org.apache.xml.internal.serializer.dom3; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/NamespaceSupport.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/NamespaceSupport.java index 611b984f05a..f7edf05bef3 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/NamespaceSupport.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/dom3/NamespaceSupport.java @@ -1,3 +1,7 @@ +/* + * reserved comment block + * DO NOT REMOVE OR ALTER! + */ /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file @@ -15,9 +19,6 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: $ - */ package com.sun.org.apache.xml.internal.serializer.dom3; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/AttList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/AttList.java deleted file mode 100644 index 94b4422c1ca..00000000000 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/AttList.java +++ /dev/null @@ -1,265 +0,0 @@ -/* - * reserved comment block - * DO NOT REMOVE OR ALTER! - */ -/* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -/* - * $Id: AttList.java,v 1.1.4.1 2005/09/08 11:03:08 suresh_emailid Exp $ - */ -package com.sun.org.apache.xml.internal.serializer.utils; - -import org.w3c.dom.Attr; -import org.w3c.dom.NamedNodeMap; -import org.w3c.dom.Node; - -import org.xml.sax.Attributes; - -/** - * Wraps a DOM attribute list in a SAX Attributes. - * - * This class is a copy of the one in com.sun.org.apache.xml.internal.utils. - * It exists to cut the serializers dependancy on that package. - * A minor changes from that package are: - * DOMHelper reference changed to DOM2Helper, class is not "public" - * - * This class is not a public API, it is only public because it is - * used in com.sun.org.apache.xml.internal.serializer. - * - * @xsl.usage internal - */ -public final class AttList implements Attributes -{ - - /** List of attribute nodes */ - NamedNodeMap m_attrs; - - /** Index of last attribute node */ - int m_lastIndex; - - // ARGHH!! JAXP Uses Xerces without setting the namespace processing to ON! - // DOM2Helper m_dh = new DOM2Helper(); - - /** Local reference to DOMHelper */ - DOM2Helper m_dh; - -// /** -// * Constructor AttList -// * -// * -// * @param attrs List of attributes this will contain -// */ -// public AttList(NamedNodeMap attrs) -// { -// -// m_attrs = attrs; -// m_lastIndex = m_attrs.getLength() - 1; -// m_dh = new DOM2Helper(); -// } - - /** - * Constructor AttList - * - * - * @param attrs List of attributes this will contain - * @param dh DOMHelper - */ - public AttList(NamedNodeMap attrs, DOM2Helper dh) - { - - m_attrs = attrs; - m_lastIndex = m_attrs.getLength() - 1; - m_dh = dh; - } - - /** - * Get the number of attribute nodes in the list - * - * - * @return number of attribute nodes - */ - public int getLength() - { - return m_attrs.getLength(); - } - - /** - * Look up an attribute's Namespace URI by index. - * - * @param index The attribute index (zero-based). - * @return The Namespace URI, or the empty string if none - * is available, or null if the index is out of - * range. - */ - public String getURI(int index) - { - String ns = m_dh.getNamespaceOfNode(((Attr) m_attrs.item(index))); - if(null == ns) - ns = ""; - return ns; - } - - /** - * Look up an attribute's local name by index. - * - * @param index The attribute index (zero-based). - * @return The local name, or the empty string if Namespace - * processing is not being performed, or null - * if the index is out of range. - */ - public String getLocalName(int index) - { - return m_dh.getLocalNameOfNode(((Attr) m_attrs.item(index))); - } - - /** - * Look up an attribute's qualified name by index. - * - * - * @param i The attribute index (zero-based). - * - * @return The attribute's qualified name - */ - public String getQName(int i) - { - return ((Attr) m_attrs.item(i)).getName(); - } - - /** - * Get the attribute's node type by index - * - * - * @param i The attribute index (zero-based) - * - * @return the attribute's node type - */ - public String getType(int i) - { - return "CDATA"; // for the moment - } - - /** - * Get the attribute's node value by index - * - * - * @param i The attribute index (zero-based) - * - * @return the attribute's node value - */ - public String getValue(int i) - { - return ((Attr) m_attrs.item(i)).getValue(); - } - - /** - * Get the attribute's node type by name - * - * - * @param name Attribute name - * - * @return the attribute's node type - */ - public String getType(String name) - { - return "CDATA"; // for the moment - } - - /** - * Look up an attribute's type by Namespace name. - * - * @param uri The Namespace URI, or the empty String if the - * name has no Namespace URI. - * @param localName The local name of the attribute. - * @return The attribute type as a string, or null if the - * attribute is not in the list or if Namespace - * processing is not being performed. - */ - public String getType(String uri, String localName) - { - return "CDATA"; // for the moment - } - - /** - * Look up an attribute's value by name. - * - * - * @param name The attribute node's name - * - * @return The attribute node's value - */ - public String getValue(String name) - { - Attr attr = ((Attr) m_attrs.getNamedItem(name)); - return (null != attr) - ? attr.getValue() : null; - } - - /** - * Look up an attribute's value by Namespace name. - * - * @param uri The Namespace URI, or the empty String if the - * name has no Namespace URI. - * @param localName The local name of the attribute. - * @return The attribute value as a string, or null if the - * attribute is not in the list. - */ - public String getValue(String uri, String localName) - { - Node a=m_attrs.getNamedItemNS(uri,localName); - return (a==null) ? null : a.getNodeValue(); - } - - /** - * Look up the index of an attribute by Namespace name. - * - * @param uri The Namespace URI, or the empty string if - * the name has no Namespace URI. - * @param localPart The attribute's local name. - * @return The index of the attribute, or -1 if it does not - * appear in the list. - */ - public int getIndex(String uri, String localPart) - { - for(int i=m_attrs.getLength()-1;i>=0;--i) - { - Node a=m_attrs.item(i); - String u=a.getNamespaceURI(); - if( (u==null ? uri==null : u.equals(uri)) - && - a.getLocalName().equals(localPart) ) - return i; - } - return -1; - } - - /** - * Look up the index of an attribute by raw XML 1.0 name. - * - * @param qName The qualified (prefixed) name. - * @return The index of the attribute, or -1 if it does not - * appear in the list. - */ - public int getIndex(String qName) - { - for(int i=m_attrs.getLength()-1;i>=0;--i) - { - Node a=m_attrs.item(i); - if(a.getNodeName().equals(qName) ) - return i; - } - return -1; - } -} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/BoolStack.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/BoolStack.java index d20d4d5e553..985d613c252 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/BoolStack.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/BoolStack.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: BoolStack.java,v 1.1.4.1 2005/09/08 11:03:08 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer.utils; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/DOM2Helper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/DOM2Helper.java deleted file mode 100644 index 73959030b2b..00000000000 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/DOM2Helper.java +++ /dev/null @@ -1,136 +0,0 @@ -/* - * reserved comment block - * DO NOT REMOVE OR ALTER! - */ -/* - * Copyright 2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -/* - * $Id: DOM2Helper.java,v 1.1.4.1 2005/09/08 11:03:09 suresh_emailid Exp $ - */ -package com.sun.org.apache.xml.internal.serializer.utils; - -import java.io.IOException; - -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.ParserConfigurationException; -import javax.xml.transform.TransformerException; - -import org.w3c.dom.Attr; -import org.w3c.dom.Document; -import org.w3c.dom.Element; -import org.w3c.dom.Node; - -import org.xml.sax.InputSource; - -/** - * This class provides a DOM level 2 "helper", which provides services currently - * not provided be the DOM standard. - * - * This class is a copy of the one in com.sun.org.apache.xml.internal.utils. - * It exists to cut the serializers dependancy on that package. - * - * The differences from the original class are: - * it doesn't extend DOMHelper, not depricated, - * dropped method isNodeAfter(Node node1, Node node2) - * dropped method parse(InputSource) - * dropped method supportSAX() - * dropped method setDocument(doc) - * dropped method checkNode(Node) - * dropped method getDocument() - * dropped method getElementByID(String id, Document doc) - * dropped method getParentOfNode(Node node) - * dropped field Document m_doc; - * made class non-public - * - * This class is not a public API, it is only public because it is - * used in com.sun.org.apache.xml.internal.serializer. - * - * @xsl.usage internal - */ -public final class DOM2Helper -{ - - /** - * Construct an instance. - */ - public DOM2Helper(){} - - /** - * Returns the local name of the given node, as defined by the - * XML Namespaces specification. This is prepared to handle documents - * built using DOM Level 1 methods by falling back upon explicitly - * parsing the node name. - * - * @param n Node to be examined - * - * @return String containing the local name, or null if the node - * was not assigned a Namespace. - */ - public String getLocalNameOfNode(Node n) - { - - String name = n.getLocalName(); - - return (null == name) ? getLocalNameOfNodeFallback(n) : name; - } - - /** - * Returns the local name of the given node. If the node's name begins - * with a namespace prefix, this is the part after the colon; otherwise - * it's the full node name. - * - * This method is copied from com.sun.org.apache.xml.internal.utils.DOMHelper - * - * @param n the node to be examined. - * - * @return String containing the Local Name - */ - private String getLocalNameOfNodeFallback(Node n) - { - - String qname = n.getNodeName(); - int index = qname.indexOf(':'); - - return (index < 0) ? qname : qname.substring(index + 1); - } - - /** - * Returns the Namespace Name (Namespace URI) for the given node. - * In a Level 2 DOM, you can ask the node itself. Note, however, that - * doing so conflicts with our decision in getLocalNameOfNode not - * to trust the that the DOM was indeed created using the Level 2 - * methods. If Level 1 methods were used, these two functions will - * disagree with each other. - *

    - * TODO: Reconcile with getLocalNameOfNode. - * - * @param n Node to be examined - * - * @return String containing the Namespace URI bound to this DOM node - * at the time the Node was created. - */ - public String getNamespaceOfNode(Node n) - { - return n.getNamespaceURI(); - } - - /** Field m_useDOM2getNamespaceURI is a compile-time flag which - * gates some of the parser options used to build a DOM -- but - * that code is commented out at this time and nobody else - * references it, so I've commented this out as well. */ - //private boolean m_useDOM2getNamespaceURI = false; -} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/Messages.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/Messages.java index 84f4c9840bb..2ecedaf735f 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/Messages.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/Messages.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Messages.java,v 1.1.4.1 2005/09/08 11:03:10 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer.utils; import com.sun.org.apache.xalan.internal.utils.SecuritySupport; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/SerializerMessages_en.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/SerializerMessages_en.java index 3789a17b547..b3c020ad3f1 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/SerializerMessages_en.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/SerializerMessages_en.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SerializerMessages_en.java,v 1.1.4.1 2005/09/08 11:03:13 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer.utils; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/StringToIntTable.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/StringToIntTable.java index 04140ffd6f9..47f157240a7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/StringToIntTable.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/StringToIntTable.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: StringToIntTable.java,v 1.1.4.1 2005/09/08 11:03:19 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer.utils; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/SystemIDResolver.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/SystemIDResolver.java index e5c38eb1081..f2c198c9f09 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/SystemIDResolver.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/SystemIDResolver.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: SystemIDResolver.java,v 1.1.4.1 2005/09/08 11:03:20 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer.utils; import java.io.File; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/URI.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/URI.java index 4d5375a59c8..320ad7f7067 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/URI.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/URI.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: URI.java,v 1.1.4.1 2005/09/08 11:03:20 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer.utils; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/WrappedRuntimeException.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/WrappedRuntimeException.java index 758e30f4869..48ea8e24825 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/WrappedRuntimeException.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/WrappedRuntimeException.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: WrappedRuntimeException.java,v 1.1.4.1 2005/09/08 11:03:21 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.serializer.utils; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/AttList.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/AttList.java index 8437ffd635d..546feb59d4e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/AttList.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/AttList.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +17,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: AttList.java,v 1.2.4.1 2005/09/15 08:15:35 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.utils; import org.w3c.dom.Attr; @@ -41,26 +39,9 @@ public class AttList implements Attributes /** Index of last attribute node */ int m_lastIndex; - // ARGHH!! JAXP Uses Xerces without setting the namespace processing to ON! + // JAXP Uses Xerces without setting the namespace processing to ON! // DOM2Helper m_dh = new DOM2Helper(); - /** Local reference to DOMHelper */ - DOMHelper m_dh; - -// /** -// * Constructor AttList -// * -// * -// * @param attrs List of attributes this will contain -// */ -// public AttList(NamedNodeMap attrs) -// { -// -// m_attrs = attrs; -// m_lastIndex = m_attrs.getLength() - 1; -// m_dh = new DOM2Helper(); -// } - /** * Constructor AttList * @@ -68,12 +49,10 @@ public class AttList implements Attributes * @param attrs List of attributes this will contain * @param dh DOMHelper */ - public AttList(NamedNodeMap attrs, DOMHelper dh) + public AttList(NamedNodeMap attrs) { - m_attrs = attrs; m_lastIndex = m_attrs.getLength() - 1; - m_dh = dh; } /** @@ -97,7 +76,7 @@ public class AttList implements Attributes */ public String getURI(int index) { - String ns = m_dh.getNamespaceOfNode(((Attr) m_attrs.item(index))); + String ns = DOM2Helper.getNamespaceOfNode(((Attr) m_attrs.item(index))); if(null == ns) ns = ""; return ns; @@ -113,7 +92,7 @@ public class AttList implements Attributes */ public String getLocalName(int index) { - return m_dh.getLocalNameOfNode(((Attr) m_attrs.item(index))); + return DOM2Helper.getLocalNameOfNode(((Attr) m_attrs.item(index))); } /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/BoolStack.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/BoolStack.java index b47dc5c95c5..ac54b7e9079 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/BoolStack.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/BoolStack.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: BoolStack.java,v 1.2.4.1 2005/09/15 08:15:35 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.utils; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/CharKey.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/CharKey.java index 64c940607b5..f6f2dd4d073 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/CharKey.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/CharKey.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: CharKey.java,v 1.3 2005/09/28 13:49:18 pvedula Exp $ - */ + package com.sun.org.apache.xml.internal.utils; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/Constants.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/Constants.java index c027234cc0e..b90ad86ae83 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/Constants.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/Constants.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: Constants.java,v 1.2.4.1 2005/09/15 08:15:37 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.utils; /** diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOM2Helper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOM2Helper.java index c23f08eec16..80024c9a42c 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOM2Helper.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOM2Helper.java @@ -1,15 +1,15 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,300 +17,327 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOM2Helper.java,v 1.2.4.1 2005/09/15 08:15:37 suresh_emailid Exp $ - */ package com.sun.org.apache.xml.internal.utils; -import java.io.IOException; - -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.ParserConfigurationException; -import javax.xml.transform.TransformerException; - +import com.sun.org.apache.xml.internal.dtm.ref.DTMNodeProxy; import org.w3c.dom.Attr; -import org.w3c.dom.Document; -import org.w3c.dom.Element; +import org.w3c.dom.NamedNodeMap; import org.w3c.dom.Node; -import org.xml.sax.InputSource; /** - * @deprecated Since the introduction of the DTM, this class will be removed. - * This class provides a DOM level 2 "helper", which provides services currently - * not provided be the DOM standard. + * This class provides a DOM level 2 "helper", which provides several services. + * + * The original class extended DOMHelper that was deprecated and then removed. */ -public class DOM2Helper extends DOMHelper -{ +public final class DOM2Helper { - /** - * Construct an instance. - */ - public DOM2Helper(){} - - /** - * Check node to see if it was created by a DOM implementation - * that this helper is intended to support. This is currently - * disabled, and assumes all nodes are acceptable rather than checking - * that they implement com.sun.org.apache.xerces.internal.dom.NodeImpl. - * - * @param node The node to be tested. - * - * @throws TransformerException if the node is not one which this - * DOM2Helper can support. If we return without throwing the exception, - * the node is compatable. - * @xsl.usage internal - */ - public void checkNode(Node node) throws TransformerException - { - - // if(!(node instanceof com.sun.org.apache.xerces.internal.dom.NodeImpl)) - // throw new TransformerException(XSLMessages.createXPATHMessage(XPATHErrorResources.ER_XERCES_CANNOT_HANDLE_NODES, new Object[]{((Object)node).getClass()})); //"DOM2Helper can not handle nodes of type" - //+((Object)node).getClass()); - } - - /** - * Returns true if the DOM implementation handled by this helper - * supports the SAX ContentHandler interface. - * - * @return true (since Xerces does). - */ - public boolean supportsSAX() - { - return true; - } - - /** Field m_doc: Document Node for the document this helper is currently - * accessing or building - * @see #setDocument - * @see #getDocument - * */ - private Document m_doc; - - /** - * Specify which document this helper is currently operating on. - * - * @param doc The DOM Document node for this document. - * @see #getDocument - */ - public void setDocument(Document doc) - { - m_doc = doc; - } - - /** - * Query which document this helper is currently operating on. - * - * @return The DOM Document node for this document. - * @see #setDocument - */ - public Document getDocument() - { - return m_doc; - } - - /** - * Parse an XML document. - * - *

    Right now the Xerces DOMParser class is used. This needs - * fixing, either via jaxp, or via some other, standard method.

    - * - *

    The application can use this method to instruct the SAX parser - * to begin parsing an XML document from any valid input - * source (a character stream, a byte stream, or a URI).

    - * - *

    Applications may not invoke this method while a parse is in - * progress (they should create a new Parser instead for each - * additional XML document). Once a parse is complete, an - * application may reuse the same Parser object, possibly with a - * different input source.

    - * - * @param source The input source for the top-level of the - * XML document. - * - * @throws TransformerException if any checked exception is thrown. - * @xsl.usage internal - */ - public void parse(InputSource source) throws TransformerException - { - - try - { - - // I guess I should use JAXP factory here... when it's legal. - // com.sun.org.apache.xerces.internal.parsers.DOMParser parser - // = new com.sun.org.apache.xerces.internal.parsers.DOMParser(); - DocumentBuilderFactory builderFactory = - DocumentBuilderFactory.newInstance(); - - builderFactory.setNamespaceAware(true); - builderFactory.setValidating(true); - - DocumentBuilder parser = builderFactory.newDocumentBuilder(); - - /* - // domParser.setFeature("http://apache.org/xml/features/dom/create-entity-ref-nodes", getShouldExpandEntityRefs()? false : true); - if(m_useDOM2getNamespaceURI) - { - parser.setFeature("http://apache.org/xml/features/dom/defer-node-expansion", true); - parser.setFeature("http://xml.org/sax/features/namespaces", true); - } - else - { - parser.setFeature("http://apache.org/xml/features/dom/defer-node-expansion", false); - } - - parser.setFeature("http://apache.org/xml/features/allow-java-encodings", true); - */ - - parser.setErrorHandler( - new com.sun.org.apache.xml.internal.utils.DefaultErrorHandler()); - - // if(null != m_entityResolver) - // { - // System.out.println("Setting the entity resolver."); - // parser.setEntityResolver(m_entityResolver); - // } - setDocument(parser.parse(source)); - } - catch (org.xml.sax.SAXException se) - { - throw new TransformerException(se); - } - catch (ParserConfigurationException pce) - { - throw new TransformerException(pce); - } - catch (IOException ioe) - { - throw new TransformerException(ioe); + /** + * Construct an instance. + */ + private DOM2Helper() { } - // setDocument(((com.sun.org.apache.xerces.internal.parsers.DOMParser)parser).getDocument()); - } + /** + * Returns the local name of the given node, as defined by the XML + * Namespaces specification. This is prepared to handle documents built + * using DOM Level 1 methods by falling back upon explicitly parsing the + * node name. + * + * @param n Node to be examined + * + * @return String containing the local name, or null if the node was not + * assigned a Namespace. + */ + public static String getLocalNameOfNode(Node n) { - /** - * Given an XML ID, return the element. This requires assistance from the - * DOM and parser, and is meaningful only in the context of a DTD - * or schema which declares attributes as being of type ID. This - * information may or may not be available in all parsers, may or - * may not be available for specific documents, and may or may not - * be available when validation is not turned on. - * - * @param id The ID to search for, as a String. - * @param doc The document to search within, as a DOM Document node. - * @return DOM Element node with an attribute of type ID whose value - * uniquely matches the requested id string, or null if there isn't - * such an element or if the DOM can't answer the question for other - * reasons. - */ - public Element getElementByID(String id, Document doc) - { - return doc.getElementById(id); - } + String name = n.getLocalName(); - /** - * Figure out whether node2 should be considered as being later - * in the document than node1, in Document Order as defined - * by the XPath model. This may not agree with the ordering defined - * by other XML applications. - *

    - * There are some cases where ordering isn't defined, and neither are - * the results of this function -- though we'll generally return true. - *

    - * TODO: Make sure this does the right thing with attribute nodes!!! - * - * @param node1 DOM Node to perform position comparison on. - * @param node2 DOM Node to perform position comparison on . - * - * @return false if node2 comes before node1, otherwise return true. - * You can think of this as - * (node1.documentOrderPosition <= node2.documentOrderPosition). - */ - public static boolean isNodeAfter(Node node1, Node node2) - { - - // Assume first that the nodes are DTM nodes, since discovering node - // order is massivly faster for the DTM. - if(node1 instanceof DOMOrder && node2 instanceof DOMOrder) - { - int index1 = ((DOMOrder) node1).getUid(); - int index2 = ((DOMOrder) node2).getUid(); - - return index1 <= index2; + return (null == name) ? getLocalNameOfNodeFallback(n) : name; } - else - { - // isNodeAfter will return true if node is after countedNode - // in document order. The base isNodeAfter is sloooow (relatively). - return DOMHelper.isNodeAfter(node1, node2); + /** + * Returns the local name of the given node. If the node's name begins with + * a namespace prefix, this is the part after the colon; otherwise it's the + * full node name. + * + * This method is copied from + * com.sun.org.apache.xml.internal.utils.DOMHelper + * + * @param n the node to be examined. + * + * @return String containing the Local Name + */ + private static String getLocalNameOfNodeFallback(Node n) { + + String qname = n.getNodeName(); + int index = qname.indexOf(':'); + + return (index < 0) ? qname : qname.substring(index + 1); } - } - /** - * Get the XPath-model parent of a node. This version takes advantage - * of the DOM Level 2 Attr.ownerElement() method; the base version we - * would otherwise inherit is prepared to fall back on exhaustively - * walking the document to find an Attr's parent. - * - * @param node Node to be examined - * - * @return the DOM parent of the input node, if there is one, or the - * ownerElement if the input node is an Attr, or null if the node is - * a Document, a DocumentFragment, or an orphan. - */ - public static Node getParentOfNode(Node node) - { - Node parent=node.getParentNode(); - if(parent==null && (Node.ATTRIBUTE_NODE == node.getNodeType()) ) - parent=((Attr) node).getOwnerElement(); - return parent; - } + /** + * Returns the Namespace Name (Namespace URI) for the given node. In a Level + * 2 DOM, you can ask the node itself. Note, however, that doing so + * conflicts with our decision in getLocalNameOfNode not to trust the that + * the DOM was indeed created using the Level 2 methods. If Level 1 methods + * were used, these two functions will disagree with each other. + *

    + * TODO: Reconcile with getLocalNameOfNode. + * + * @param n Node to be examined + * + * @return String containing the Namespace URI bound to this DOM node at the + * time the Node was created. + */ + public static String getNamespaceOfNode(Node n) { + return n.getNamespaceURI(); + } - /** - * Returns the local name of the given node, as defined by the - * XML Namespaces specification. This is prepared to handle documents - * built using DOM Level 1 methods by falling back upon explicitly - * parsing the node name. - * - * @param n Node to be examined - * - * @return String containing the local name, or null if the node - * was not assigned a Namespace. - */ - public String getLocalNameOfNode(Node n) - { + /** + * Figure out whether node2 should be considered as being later in the + * document than node1, in Document Order as defined by the XPath model. + * This may not agree with the ordering defined by other XML applications. + *

    + * There are some cases where ordering isn't defined, and neither are the + * results of this function -- though we'll generally return true. + * + * @param node1 DOM Node to perform position comparison on. + * @param node2 DOM Node to perform position comparison on . + * + * @return false if node2 comes before node1, otherwise return true. You can + * think of this as + * {@code (node1.documentOrderPosition <= node2.documentOrderPosition)}. + */ + public static boolean isNodeAfter(Node node1, Node node2) { + if (node1 == node2 || isNodeTheSame(node1, node2)) { + return true; + } - String name = n.getLocalName(); + // Default return value, if there is no defined ordering + boolean isNodeAfter = true; - return (null == name) ? super.getLocalNameOfNode(n) : name; - } + Node parent1 = getParentOfNode(node1); + Node parent2 = getParentOfNode(node2); - /** - * Returns the Namespace Name (Namespace URI) for the given node. - * In a Level 2 DOM, you can ask the node itself. Note, however, that - * doing so conflicts with our decision in getLocalNameOfNode not - * to trust the that the DOM was indeed created using the Level 2 - * methods. If Level 1 methods were used, these two functions will - * disagree with each other. - *

    - * TODO: Reconcile with getLocalNameOfNode. - * - * @param n Node to be examined - * - * @return String containing the Namespace URI bound to this DOM node - * at the time the Node was created. - */ - public String getNamespaceOfNode(Node n) - { - return n.getNamespaceURI(); - } + // Optimize for most common case + if (parent1 == parent2 || isNodeTheSame(parent1, parent2)) // then we know they are siblings + { + if (null != parent1) { + isNodeAfter = isNodeAfterSibling(parent1, node1, node2); + } + } else { + // General strategy: Figure out the lengths of the two + // ancestor chains, reconcile the lengths, and look for + // the lowest common ancestor. If that ancestor is one of + // the nodes being compared, it comes before the other. + // Otherwise perform a sibling compare. + // + // NOTE: If no common ancestor is found, ordering is undefined + // and we return the default value of isNodeAfter. + // Count parents in each ancestor chain + int nParents1 = 2, nParents2 = 2; // include node & parent obtained above - /** Field m_useDOM2getNamespaceURI is a compile-time flag which - * gates some of the parser options used to build a DOM -- but - * that code is commented out at this time and nobody else - * references it, so I've commented this out as well. */ - //private boolean m_useDOM2getNamespaceURI = false; + while (parent1 != null) { + nParents1++; + + parent1 = getParentOfNode(parent1); + } + + while (parent2 != null) { + nParents2++; + + parent2 = getParentOfNode(parent2); + } + + // Initially assume scan for common ancestor starts with + // the input nodes. + Node startNode1 = node1, startNode2 = node2; + + // If one ancestor chain is longer, adjust its start point + // so we're comparing at the same depths + if (nParents1 < nParents2) { + // Adjust startNode2 to depth of startNode1 + int adjust = nParents2 - nParents1; + + for (int i = 0; i < adjust; i++) { + startNode2 = getParentOfNode(startNode2); + } + } else if (nParents1 > nParents2) { + // adjust startNode1 to depth of startNode2 + int adjust = nParents1 - nParents2; + + for (int i = 0; i < adjust; i++) { + startNode1 = getParentOfNode(startNode1); + } + } + + Node prevChild1 = null, prevChild2 = null; // so we can "back up" + + // Loop up the ancestor chain looking for common parent + while (null != startNode1) { + if (startNode1 == startNode2 || isNodeTheSame(startNode1, startNode2)) // common parent? + { + if (null == prevChild1) // first time in loop? + { + + // Edge condition: one is the ancestor of the other. + isNodeAfter = (nParents1 < nParents2) ? true : false; + + break; // from while loop + } else { + // Compare ancestors below lowest-common as siblings + isNodeAfter = isNodeAfterSibling(startNode1, prevChild1, + prevChild2); + + break; // from while loop + } + } // end if(startNode1 == startNode2) + + // Move up one level and try again + prevChild1 = startNode1; + startNode1 = getParentOfNode(startNode1); + prevChild2 = startNode2; + startNode2 = getParentOfNode(startNode2); + } // end while(parents exist to examine) + } // end big else (not immediate siblings) + + return isNodeAfter; + } // end isNodeAfter(Node node1, Node node2) + + /** + * Use DTMNodeProxy to determine whether two nodes are the same. + * + * @param node1 The first DOM node to compare. + * @param node2 The second DOM node to compare. + * @return true if the two nodes are the same. + */ + public static boolean isNodeTheSame(Node node1, Node node2) { + if (node1 instanceof DTMNodeProxy && node2 instanceof DTMNodeProxy) { + return ((DTMNodeProxy) node1).equals((DTMNodeProxy) node2); + } else { + return (node1 == node2); + } + } + + /** + * Get the XPath-model parent of a node. This version takes advantage of the + * DOM Level 2 Attr.ownerElement() method; the base version we would + * otherwise inherit is prepared to fall back on exhaustively walking the + * document to find an Attr's parent. + * + * @param node Node to be examined + * + * @return the DOM parent of the input node, if there is one, or the + * ownerElement if the input node is an Attr, or null if the node is a + * Document, a DocumentFragment, or an orphan. + */ + public static Node getParentOfNode(Node node) { + Node parent = node.getParentNode(); + if (parent == null && (Node.ATTRIBUTE_NODE == node.getNodeType())) { + parent = ((Attr) node).getOwnerElement(); + } + return parent; + } + + /** + * Figure out if child2 is after child1 in document order. + *

    + * Warning: Some aspects of "document order" are not well defined. For + * example, the order of attributes is considered meaningless in XML, and + * the order reported by our model will be consistent for a given invocation + * but may not match that of either the source file or the serialized + * output. + * + * @param parent Must be the parent of both child1 and child2. + * @param child1 Must be the child of parent and not equal to child2. + * @param child2 Must be the child of parent and not equal to child1. + * @return true if child 2 is after child1 in document order. + */ + private static boolean isNodeAfterSibling(Node parent, Node child1, + Node child2) { + + boolean isNodeAfterSibling = false; + short child1type = child1.getNodeType(); + short child2type = child2.getNodeType(); + + if ((Node.ATTRIBUTE_NODE != child1type) + && (Node.ATTRIBUTE_NODE == child2type)) { + + // always sort attributes before non-attributes. + isNodeAfterSibling = false; + } else if ((Node.ATTRIBUTE_NODE == child1type) + && (Node.ATTRIBUTE_NODE != child2type)) { + + // always sort attributes before non-attributes. + isNodeAfterSibling = true; + } else if (Node.ATTRIBUTE_NODE == child1type) { + NamedNodeMap children = parent.getAttributes(); + int nNodes = children.getLength(); + boolean found1 = false, found2 = false; + + // Count from the start until we find one or the other. + for (int i = 0; i < nNodes; i++) { + Node child = children.item(i); + + if (child1 == child || isNodeTheSame(child1, child)) { + if (found2) { + isNodeAfterSibling = false; + + break; + } + + found1 = true; + } else if (child2 == child || isNodeTheSame(child2, child)) { + if (found1) { + isNodeAfterSibling = true; + + break; + } + + found2 = true; + } + } + } else { + // TODO: Check performance of alternate solution: + // There are two choices here: Count from the start of + // the document until we find one or the other, or count + // from one until we find or fail to find the other. + // Either can wind up scanning all the siblings in the worst + // case, which on a wide document can be a lot of work but + // is more typically is a short list. + // Scanning from the start involves two tests per iteration, + // but it isn't clear that scanning from the middle doesn't + // yield more iterations on average. + // We should run some testcases. + Node child = parent.getFirstChild(); + boolean found1 = false, found2 = false; + + while (null != child) { + + // Node child = children.item(i); + if (child1 == child || isNodeTheSame(child1, child)) { + if (found2) { + isNodeAfterSibling = false; + + break; + } + + found1 = true; + } else if (child2 == child || isNodeTheSame(child2, child)) { + if (found1) { + isNodeAfterSibling = true; + + break; + } + + found2 = true; + } + + child = child.getNextSibling(); + } + } + + return isNodeAfterSibling; + } // end isNodeAfterSibling(Node parent, Node child1, Node child2) } diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMBuilder.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMBuilder.java index 9dadac99b45..adf503d79ad 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMBuilder.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMBuilder.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: DOMBuilder.java,v 1.2.4.1 2005/09/15 08:15:39 suresh_emailid Exp $ - */ + package com.sun.org.apache.xml.internal.utils; import java.util.Stack; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMHelper.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMHelper.java deleted file mode 100644 index 416c200b8c1..00000000000 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMHelper.java +++ /dev/null @@ -1,1330 +0,0 @@ -/* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. - */ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -/* - * $Id: DOMHelper.java,v 1.2.4.1 2005/09/15 08:15:40 suresh_emailid Exp $ - */ -package com.sun.org.apache.xml.internal.utils; - -import com.sun.org.apache.xml.internal.dtm.ref.DTMNodeProxy; -import com.sun.org.apache.xml.internal.res.XMLErrorResources; -import com.sun.org.apache.xml.internal.res.XMLMessages; -import java.util.HashMap; -import java.util.Map; -import java.util.Vector; -import javax.xml.XMLConstants; -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.ParserConfigurationException; -import org.w3c.dom.Attr; -import org.w3c.dom.DOMImplementation; -import org.w3c.dom.Document; -import org.w3c.dom.DocumentType; -import org.w3c.dom.Element; -import org.w3c.dom.Entity; -import org.w3c.dom.NamedNodeMap; -import org.w3c.dom.Node; -import org.w3c.dom.Text; - -/** - * @deprecated Since the introduction of the DTM, this class will be removed. - * This class provides a front-end to DOM implementations, providing - * a number of utility functions that either aren't yet standardized - * by the DOM spec or that are defined in optional DOM modules and - * hence may not be present in all DOMs. - */ -public class DOMHelper -{ - - /** - * DOM Level 1 did not have a standard mechanism for creating a new - * Document object. This function provides a DOM-implementation-independent - * abstraction for that for that concept. It's typically used when - * outputting a new DOM as the result of an operation. - *

    - * TODO: This isn't directly compatable with DOM Level 2. - * The Level 2 createDocument call also creates the root - * element, and thus requires that you know what that element will be - * before creating the Document. We should think about whether we want - * to change this code, and the callers, so we can use the DOM's own - * method. (It's also possible that DOM Level 3 may relax this - * sequence, but you may give up some intelligence in the DOM by - * doing so; the intent was that knowing the document type and root - * element might let the DOM automatically switch to a specialized - * subclass for particular kinds of documents.) - * - * @param isSecureProcessing state of the secure processing feature. - * @return The newly created DOM Document object, with no children, or - * null if we can't find a DOM implementation that permits creating - * new empty Documents. - */ - public static Document createDocument(boolean isSecureProcessing) - { - - try - { - - // Use an implementation of the JAVA API for XML Parsing 1.0 to - // create a DOM Document node to contain the result. - DocumentBuilderFactory dfactory = DocumentBuilderFactory.newInstance(); - - dfactory.setNamespaceAware(true); - dfactory.setValidating(true); - - if (isSecureProcessing) - { - try - { - dfactory.setFeature(XMLConstants.FEATURE_SECURE_PROCESSING, true); - } - catch (ParserConfigurationException pce) {} - } - - DocumentBuilder docBuilder = dfactory.newDocumentBuilder(); - Document outNode = docBuilder.newDocument(); - - return outNode; - } - catch (ParserConfigurationException pce) - { - throw new RuntimeException( - XMLMessages.createXMLMessage( - XMLErrorResources.ER_CREATEDOCUMENT_NOT_SUPPORTED, null)); //"createDocument() not supported in XPathContext!"); - - // return null; - } - } - - /** - * DOM Level 1 did not have a standard mechanism for creating a new - * Document object. This function provides a DOM-implementation-independent - * abstraction for that for that concept. It's typically used when - * outputting a new DOM as the result of an operation. - * - * @return The newly created DOM Document object, with no children, or - * null if we can't find a DOM implementation that permits creating - * new empty Documents. - */ - public static Document createDocument() - { - return createDocument(false); - } - - /** - * Tells, through the combination of the default-space attribute - * on xsl:stylesheet, xsl:strip-space, xsl:preserve-space, and the - * xml:space attribute, whether or not extra whitespace should be stripped - * from the node. Literal elements from template elements should - * not be tested with this function. - * @param textNode A text node from the source tree. - * @return true if the text node should be stripped of extra whitespace. - * - * @throws javax.xml.transform.TransformerException - * @xsl.usage advanced - */ - public boolean shouldStripSourceNode(Node textNode) - throws javax.xml.transform.TransformerException - { - - // return (null == m_envSupport) ? false : m_envSupport.shouldStripSourceNode(textNode); - return false; - } - - /** - * Supports the XPath function GenerateID by returning a unique - * identifier string for any given DOM Node. - *

    - * Warning: The base implementation uses the Node object's hashCode(), - * which is NOT guaranteed to be unique. If that method hasn't been - * overridden in this DOM ipmlementation, most Java implementions will - * derive it from the object's address and should be OK... but if - * your DOM uses a different definition of hashCode (eg hashing the - * contents of the subtree), or if your DOM may have multiple objects - * that represent a single Node in the data structure (eg via proxying), - * you may need to find another way to assign a unique identifier. - *

    - * Also, be aware that if nodes are destroyed and recreated, there is - * an open issue regarding whether an ID may be reused. Currently - * we're assuming that the input document is stable for the duration - * of the XPath/XSLT operation, so this shouldn't arise in this context. - *

    - * (DOM Level 3 is investigating providing a unique node "key", but - * that won't help Level 1 and Level 2 implementations.) - * - * @param node whose identifier you want to obtain - * - * @return a string which should be different for every Node object. - */ - public String getUniqueID(Node node) - { - return "N" + Integer.toHexString(node.hashCode()).toUpperCase(); - } - - /** - * Figure out whether node2 should be considered as being later - * in the document than node1, in Document Order as defined - * by the XPath model. This may not agree with the ordering defined - * by other XML applications. - *

    - * There are some cases where ordering isn't defined, and neither are - * the results of this function -- though we'll generally return true. - * - * TODO: Make sure this does the right thing with attribute nodes!!! - * - * @param node1 DOM Node to perform position comparison on. - * @param node2 DOM Node to perform position comparison on . - * - * @return false if node2 comes before node1, otherwise return true. - * You can think of this as - * (node1.documentOrderPosition <= node2.documentOrderPosition). - */ - public static boolean isNodeAfter(Node node1, Node node2) - { - if (node1 == node2 || isNodeTheSame(node1, node2)) - return true; - - // Default return value, if there is no defined ordering - boolean isNodeAfter = true; - - Node parent1 = getParentOfNode(node1); - Node parent2 = getParentOfNode(node2); - - // Optimize for most common case - if (parent1 == parent2 || isNodeTheSame(parent1, parent2)) // then we know they are siblings - { - if (null != parent1) - isNodeAfter = isNodeAfterSibling(parent1, node1, node2); - else - { - // If both parents are null, ordering is not defined. - // We're returning a value in lieu of throwing an exception. - // Not a case we expect to arise in XPath, but beware if you - // try to reuse this method. - - // We can just fall through in this case, which allows us - // to hit the debugging code at the end of the function. - //return isNodeAfter; - } - } - else - { - - // General strategy: Figure out the lengths of the two - // ancestor chains, reconcile the lengths, and look for - // the lowest common ancestor. If that ancestor is one of - // the nodes being compared, it comes before the other. - // Otherwise perform a sibling compare. - // - // NOTE: If no common ancestor is found, ordering is undefined - // and we return the default value of isNodeAfter. - - // Count parents in each ancestor chain - int nParents1 = 2, nParents2 = 2; // include node & parent obtained above - - while (parent1 != null) - { - nParents1++; - - parent1 = getParentOfNode(parent1); - } - - while (parent2 != null) - { - nParents2++; - - parent2 = getParentOfNode(parent2); - } - - // Initially assume scan for common ancestor starts with - // the input nodes. - Node startNode1 = node1, startNode2 = node2; - - // If one ancestor chain is longer, adjust its start point - // so we're comparing at the same depths - if (nParents1 < nParents2) - { - // Adjust startNode2 to depth of startNode1 - int adjust = nParents2 - nParents1; - - for (int i = 0; i < adjust; i++) - { - startNode2 = getParentOfNode(startNode2); - } - } - else if (nParents1 > nParents2) - { - // adjust startNode1 to depth of startNode2 - int adjust = nParents1 - nParents2; - - for (int i = 0; i < adjust; i++) - { - startNode1 = getParentOfNode(startNode1); - } - } - - Node prevChild1 = null, prevChild2 = null; // so we can "back up" - - // Loop up the ancestor chain looking for common parent - while (null != startNode1) - { - if (startNode1 == startNode2 || isNodeTheSame(startNode1, startNode2)) // common parent? - { - if (null == prevChild1) // first time in loop? - { - - // Edge condition: one is the ancestor of the other. - isNodeAfter = (nParents1 < nParents2) ? true : false; - - break; // from while loop - } - else - { - // Compare ancestors below lowest-common as siblings - isNodeAfter = isNodeAfterSibling(startNode1, prevChild1, - prevChild2); - - break; // from while loop - } - } // end if(startNode1 == startNode2) - - // Move up one level and try again - prevChild1 = startNode1; - startNode1 = getParentOfNode(startNode1); - prevChild2 = startNode2; - startNode2 = getParentOfNode(startNode2); - } // end while(parents exist to examine) - } // end big else (not immediate siblings) - - // WARNING: The following diagnostic won't report the early - // "same node" case. Fix if/when needed. - - /* -- please do not remove... very useful for diagnostics -- - System.out.println("node1 = "+node1.getNodeName()+"("+node1.getNodeType()+")"+ - ", node2 = "+node2.getNodeName() - +"("+node2.getNodeType()+")"+ - ", isNodeAfter = "+isNodeAfter); */ - return isNodeAfter; - } // end isNodeAfter(Node node1, Node node2) - - /** - * Use DTMNodeProxy to determine whether two nodes are the same. - * - * @param node1 The first DOM node to compare. - * @param node2 The second DOM node to compare. - * @return true if the two nodes are the same. - */ - public static boolean isNodeTheSame(Node node1, Node node2) - { - if (node1 instanceof DTMNodeProxy && node2 instanceof DTMNodeProxy) - return ((DTMNodeProxy)node1).equals((DTMNodeProxy)node2); - else - return (node1 == node2); - } - - /** - * Figure out if child2 is after child1 in document order. - *

    - * Warning: Some aspects of "document order" are not well defined. - * For example, the order of attributes is considered - * meaningless in XML, and the order reported by our model will - * be consistant for a given invocation but may not - * match that of either the source file or the serialized output. - * - * @param parent Must be the parent of both child1 and child2. - * @param child1 Must be the child of parent and not equal to child2. - * @param child2 Must be the child of parent and not equal to child1. - * @return true if child 2 is after child1 in document order. - */ - private static boolean isNodeAfterSibling(Node parent, Node child1, - Node child2) - { - - boolean isNodeAfterSibling = false; - short child1type = child1.getNodeType(); - short child2type = child2.getNodeType(); - - if ((Node.ATTRIBUTE_NODE != child1type) - && (Node.ATTRIBUTE_NODE == child2type)) - { - - // always sort attributes before non-attributes. - isNodeAfterSibling = false; - } - else if ((Node.ATTRIBUTE_NODE == child1type) - && (Node.ATTRIBUTE_NODE != child2type)) - { - - // always sort attributes before non-attributes. - isNodeAfterSibling = true; - } - else if (Node.ATTRIBUTE_NODE == child1type) - { - NamedNodeMap children = parent.getAttributes(); - int nNodes = children.getLength(); - boolean found1 = false, found2 = false; - - // Count from the start until we find one or the other. - for (int i = 0; i < nNodes; i++) - { - Node child = children.item(i); - - if (child1 == child || isNodeTheSame(child1, child)) - { - if (found2) - { - isNodeAfterSibling = false; - - break; - } - - found1 = true; - } - else if (child2 == child || isNodeTheSame(child2, child)) - { - if (found1) - { - isNodeAfterSibling = true; - - break; - } - - found2 = true; - } - } - } - else - { - // TODO: Check performance of alternate solution: - // There are two choices here: Count from the start of - // the document until we find one or the other, or count - // from one until we find or fail to find the other. - // Either can wind up scanning all the siblings in the worst - // case, which on a wide document can be a lot of work but - // is more typically is a short list. - // Scanning from the start involves two tests per iteration, - // but it isn't clear that scanning from the middle doesn't - // yield more iterations on average. - // We should run some testcases. - Node child = parent.getFirstChild(); - boolean found1 = false, found2 = false; - - while (null != child) - { - - // Node child = children.item(i); - if (child1 == child || isNodeTheSame(child1, child)) - { - if (found2) - { - isNodeAfterSibling = false; - - break; - } - - found1 = true; - } - else if (child2 == child || isNodeTheSame(child2, child)) - { - if (found1) - { - isNodeAfterSibling = true; - - break; - } - - found2 = true; - } - - child = child.getNextSibling(); - } - } - - return isNodeAfterSibling; - } // end isNodeAfterSibling(Node parent, Node child1, Node child2) - - //========================================================== - // SECTION: Namespace resolution - //========================================================== - - /** - * Get the depth level of this node in the tree (equals 1 for - * a parentless node). - * - * @param n Node to be examined. - * @return the number of ancestors, plus one - * @xsl.usage internal - */ - public short getLevel(Node n) - { - - short level = 1; - - while (null != (n = getParentOfNode(n))) - { - level++; - } - - return level; - } - - /** - * Given an XML Namespace prefix and a context in which the prefix - * is to be evaluated, return the Namespace Name this prefix was - * bound to. Note that DOM Level 3 is expected to provide a version of - * this which deals with the DOM's "early binding" behavior. - * - * Default handling: - * - * @param prefix String containing namespace prefix to be resolved, - * without the ':' which separates it from the localname when used - * in a Node Name. The empty sting signifies the default namespace - * at this point in the document. - * @param namespaceContext Element which provides context for resolution. - * (We could extend this to work for other nodes by first seeking their - * nearest Element ancestor.) - * - * @return a String containing the Namespace URI which this prefix - * represents in the specified context. - */ - public String getNamespaceForPrefix(String prefix, Element namespaceContext) - { - - int type; - Node parent = namespaceContext; - String namespace = null; - - if (prefix.equals("xml")) - { - namespace = QName.S_XMLNAMESPACEURI; // Hardcoded, per Namespace spec - } - else if(prefix.equals("xmlns")) - { - // Hardcoded in the DOM spec, expected to be adopted by - // Namespace spec. NOTE: Namespace declarations _must_ use - // the xmlns: prefix; other prefixes declared as belonging - // to this namespace will not be recognized and should - // probably be rejected by parsers as erroneous declarations. - namespace = "http://www.w3.org/2000/xmlns/"; - } - else - { - // Attribute name for this prefix's declaration - String declname=(prefix=="") - ? "xmlns" - : "xmlns:"+prefix; - - // Scan until we run out of Elements or have resolved the namespace - while ((null != parent) && (null == namespace) - && (((type = parent.getNodeType()) == Node.ELEMENT_NODE) - || (type == Node.ENTITY_REFERENCE_NODE))) - { - if (type == Node.ELEMENT_NODE) - { - - // Look for the appropriate Namespace Declaration attribute, - // either "xmlns:prefix" or (if prefix is "") "xmlns". - // TODO: This does not handle "implicit declarations" - // which may be created when the DOM is edited. DOM Level - // 3 will define how those should be interpreted. But - // this issue won't arise in freshly-parsed DOMs. - - // NOTE: declname is set earlier, outside the loop. - Attr attr=((Element)parent).getAttributeNode(declname); - if(attr!=null) - { - namespace = attr.getNodeValue(); - break; - } - } - - parent = getParentOfNode(parent); - } - } - - return namespace; - } - - /** - * An experiment for the moment. - */ - Map m_NSInfos = new HashMap<>(); - - /** Object to put into the m_NSInfos table that tells that a node has not been - * processed, but has xmlns namespace decls. */ - protected static final NSInfo m_NSInfoUnProcWithXMLNS = new NSInfo(false, - true); - - /** Object to put into the m_NSInfos table that tells that a node has not been - * processed, but has no xmlns namespace decls. */ - protected static final NSInfo m_NSInfoUnProcWithoutXMLNS = new NSInfo(false, - false); - - /** Object to put into the m_NSInfos table that tells that a node has not been - * processed, and has no xmlns namespace decls, and has no ancestor decls. */ - protected static final NSInfo m_NSInfoUnProcNoAncestorXMLNS = - new NSInfo(false, false, NSInfo.ANCESTORNOXMLNS); - - /** Object to put into the m_NSInfos table that tells that a node has been - * processed, and has xmlns namespace decls. */ - protected static final NSInfo m_NSInfoNullWithXMLNS = new NSInfo(true, - true); - - /** Object to put into the m_NSInfos table that tells that a node has been - * processed, and has no xmlns namespace decls. */ - protected static final NSInfo m_NSInfoNullWithoutXMLNS = new NSInfo(true, - false); - - /** Object to put into the m_NSInfos table that tells that a node has been - * processed, and has no xmlns namespace decls. and has no ancestor decls. */ - protected static final NSInfo m_NSInfoNullNoAncestorXMLNS = - new NSInfo(true, false, NSInfo.ANCESTORNOXMLNS); - - /** Vector of node (odd indexes) and NSInfos (even indexes) that tell if - * the given node is a candidate for ancestor namespace processing. */ - protected Vector m_candidateNoAncestorXMLNS = new Vector(); - - /** - * Returns the namespace of the given node. Differs from simply getting - * the node's prefix and using getNamespaceForPrefix in that it attempts - * to cache some of the data in NSINFO objects, to avoid repeated lookup. - * TODO: Should we consider moving that logic into getNamespaceForPrefix? - * - * @param n Node to be examined. - * - * @return String containing the Namespace Name (uri) for this node. - * Note that this is undefined for any nodes other than Elements and - * Attributes. - */ - public String getNamespaceOfNode(Node n) - { - - String namespaceOfPrefix; - boolean hasProcessedNS; - NSInfo nsInfo; - short ntype = n.getNodeType(); - - if (Node.ATTRIBUTE_NODE != ntype) - { - nsInfo = m_NSInfos.get(n); - hasProcessedNS = (nsInfo == null) ? false : nsInfo.m_hasProcessedNS; - } - else - { - hasProcessedNS = false; - nsInfo = null; - } - - if (hasProcessedNS) - { - namespaceOfPrefix = nsInfo.m_namespace; - } - else - { - namespaceOfPrefix = null; - - String nodeName = n.getNodeName(); - int indexOfNSSep = nodeName.indexOf(':'); - String prefix; - - if (Node.ATTRIBUTE_NODE == ntype) - { - if (indexOfNSSep > 0) - { - prefix = nodeName.substring(0, indexOfNSSep); - } - else - { - - // Attributes don't use the default namespace, so if - // there isn't a prefix, we're done. - return namespaceOfPrefix; - } - } - else - { - prefix = (indexOfNSSep >= 0) - ? nodeName.substring(0, indexOfNSSep) : ""; - } - - boolean ancestorsHaveXMLNS = false; - boolean nHasXMLNS = false; - - if (prefix.equals("xml")) - { - namespaceOfPrefix = QName.S_XMLNAMESPACEURI; - } - else - { - int parentType; - Node parent = n; - - while ((null != parent) && (null == namespaceOfPrefix)) - { - if ((null != nsInfo) - && (nsInfo.m_ancestorHasXMLNSAttrs - == NSInfo.ANCESTORNOXMLNS)) - { - break; - } - - parentType = parent.getNodeType(); - - if ((null == nsInfo) || nsInfo.m_hasXMLNSAttrs) - { - boolean elementHasXMLNS = false; - - if (parentType == Node.ELEMENT_NODE) - { - NamedNodeMap nnm = parent.getAttributes(); - - for (int i = 0; i < nnm.getLength(); i++) - { - Node attr = nnm.item(i); - String aname = attr.getNodeName(); - - if (aname.charAt(0) == 'x') - { - boolean isPrefix = aname.startsWith("xmlns:"); - - if (aname.equals("xmlns") || isPrefix) - { - if (n == parent) - nHasXMLNS = true; - - elementHasXMLNS = true; - ancestorsHaveXMLNS = true; - - String p = isPrefix ? aname.substring(6) : ""; - - if (p.equals(prefix)) - { - namespaceOfPrefix = attr.getNodeValue(); - - break; - } - } - } - } - } - - if ((Node.ATTRIBUTE_NODE != parentType) && (null == nsInfo) - && (n != parent)) - { - nsInfo = elementHasXMLNS - ? m_NSInfoUnProcWithXMLNS : m_NSInfoUnProcWithoutXMLNS; - - m_NSInfos.put(parent, nsInfo); - } - } - - if (Node.ATTRIBUTE_NODE == parentType) - { - parent = getParentOfNode(parent); - } - else - { - m_candidateNoAncestorXMLNS.addElement(parent); - m_candidateNoAncestorXMLNS.addElement(nsInfo); - - parent = parent.getParentNode(); - } - - if (null != parent) - { - nsInfo = m_NSInfos.get(parent); - } - } - - int nCandidates = m_candidateNoAncestorXMLNS.size(); - - if (nCandidates > 0) - { - if ((false == ancestorsHaveXMLNS) && (null == parent)) - { - for (int i = 0; i < nCandidates; i += 2) - { - Object candidateInfo = m_candidateNoAncestorXMLNS.elementAt(i - + 1); - - if (candidateInfo == m_NSInfoUnProcWithoutXMLNS) - { - m_NSInfos.put((Node)m_candidateNoAncestorXMLNS.elementAt(i), - m_NSInfoUnProcNoAncestorXMLNS); - } - else if (candidateInfo == m_NSInfoNullWithoutXMLNS) - { - m_NSInfos.put((Node)m_candidateNoAncestorXMLNS.elementAt(i), - m_NSInfoNullNoAncestorXMLNS); - } - } - } - - m_candidateNoAncestorXMLNS.removeAllElements(); - } - } - - if (Node.ATTRIBUTE_NODE != ntype) - { - if (null == namespaceOfPrefix) - { - if (ancestorsHaveXMLNS) - { - if (nHasXMLNS) - m_NSInfos.put(n, m_NSInfoNullWithXMLNS); - else - m_NSInfos.put(n, m_NSInfoNullWithoutXMLNS); - } - else - { - m_NSInfos.put(n, m_NSInfoNullNoAncestorXMLNS); - } - } - else - { - m_NSInfos.put(n, new NSInfo(namespaceOfPrefix, nHasXMLNS)); - } - } - } - - return namespaceOfPrefix; - } - - /** - * Returns the local name of the given node. If the node's name begins - * with a namespace prefix, this is the part after the colon; otherwise - * it's the full node name. - * - * @param n the node to be examined. - * - * @return String containing the Local Name - */ - public String getLocalNameOfNode(Node n) - { - - String qname = n.getNodeName(); - int index = qname.indexOf(':'); - - return (index < 0) ? qname : qname.substring(index + 1); - } - - /** - * Returns the element name with the namespace prefix (if any) replaced - * by the Namespace URI it was bound to. This is not a standard - * representation of a node name, but it allows convenient - * single-string comparison of the "universal" names of two nodes. - * - * @param elem Element to be examined. - * - * @return String in the form "namespaceURI:localname" if the node - * belongs to a namespace, or simply "localname" if it doesn't. - * @see #getExpandedAttributeName - */ - public String getExpandedElementName(Element elem) - { - - String namespace = getNamespaceOfNode(elem); - - return (null != namespace) - ? namespace + ":" + getLocalNameOfNode(elem) - : getLocalNameOfNode(elem); - } - - /** - * Returns the attribute name with the namespace prefix (if any) replaced - * by the Namespace URI it was bound to. This is not a standard - * representation of a node name, but it allows convenient - * single-string comparison of the "universal" names of two nodes. - * - * @param attr Attr to be examined - * - * @return String in the form "namespaceURI:localname" if the node - * belongs to a namespace, or simply "localname" if it doesn't. - * @see #getExpandedElementName - */ - public String getExpandedAttributeName(Attr attr) - { - - String namespace = getNamespaceOfNode(attr); - - return (null != namespace) - ? namespace + ":" + getLocalNameOfNode(attr) - : getLocalNameOfNode(attr); - } - - //========================================================== - // SECTION: DOM Helper Functions - //========================================================== - - /** - * Tell if the node is ignorable whitespace. Note that this can - * be determined only in the context of a DTD or other Schema, - * and that DOM Level 2 has nostandardized DOM API which can - * return that information. - * @deprecated - * - * @param node Node to be examined - * - * @return CURRENTLY HARDCODED TO FALSE, but should return true if - * and only if the node is of type Text, contains only whitespace, - * and does not appear as part of the #PCDATA content of an element. - * (Note that determining this last may require allowing for - * Entity References.) - */ - public boolean isIgnorableWhitespace(Text node) - { - - boolean isIgnorable = false; // return value - - // TODO: I can probably do something to figure out if this - // space is ignorable from just the information in - // the DOM tree. - // -- You need to be able to distinguish whitespace - // that is #PCDATA from whitespace that isn't. That requires - // DTD support, which won't be standardized until DOM Level 3. - return isIgnorable; - } - - /** - * Get the first unparented node in the ancestor chain. - * @deprecated - * - * @param node Starting node, to specify which chain to chase - * - * @return the topmost ancestor. - */ - public Node getRoot(Node node) - { - - Node root = null; - - while (node != null) - { - root = node; - node = getParentOfNode(node); - } - - return root; - } - - /** - * Get the root node of the document tree, regardless of - * whether or not the node passed in is a document node. - *

    - * TODO: This doesn't handle DocumentFragments or "orphaned" subtrees - * -- it's currently returning ownerDocument even when the tree is - * not actually part of the main Document tree. We should either - * rewrite the description to say that it finds the Document node, - * or change the code to walk up the ancestor chain. - - * - * @param n Node to be examined - * - * @return the Document node. Note that this is not the correct answer - * if n was (or was a child of) a DocumentFragment or an orphaned node, - * as can arise if the DOM has been edited rather than being generated - * by a parser. - */ - public Node getRootNode(Node n) - { - int nt = n.getNodeType(); - return ( (Node.DOCUMENT_NODE == nt) || (Node.DOCUMENT_FRAGMENT_NODE == nt) ) - ? n : n.getOwnerDocument(); - } - - /** - * Test whether the given node is a namespace decl node. In DOM Level 2 - * this can be done in a namespace-aware manner, but in Level 1 DOMs - * it has to be done by testing the node name. - * - * @param n Node to be examined. - * - * @return boolean -- true iff the node is an Attr whose name is - * "xmlns" or has the "xmlns:" prefix. - */ - public boolean isNamespaceNode(Node n) - { - - if (Node.ATTRIBUTE_NODE == n.getNodeType()) - { - String attrName = n.getNodeName(); - - return (attrName.startsWith("xmlns:") || attrName.equals("xmlns")); - } - - return false; - } - - /** - * Obtain the XPath-model parent of a DOM node -- ownerElement for Attrs, - * parent for other nodes. - *

    - * Background: The DOM believes that you must be your Parent's - * Child, and thus Attrs don't have parents. XPath said that Attrs - * do have their owning Element as their parent. This function - * bridges the difference, either by using the DOM Level 2 ownerElement - * function or by using a "silly and expensive function" in Level 1 - * DOMs. - *

    - * (There's some discussion of future DOMs generalizing ownerElement - * into ownerNode and making it work on all types of nodes. This - * still wouldn't help the users of Level 1 or Level 2 DOMs) - *

    - * - * @param node Node whose XPath parent we want to obtain - * - * @return the parent of the node, or the ownerElement if it's an - * Attr node, or null if the node is an orphan. - * - * @throws RuntimeException if the Document has no root element. - * This can't arise if the Document was created - * via the DOM Level 2 factory methods, but is possible if other - * mechanisms were used to obtain it - */ - public static Node getParentOfNode(Node node) throws RuntimeException - { - Node parent; - short nodeType = node.getNodeType(); - - if (Node.ATTRIBUTE_NODE == nodeType) - { - Document doc = node.getOwnerDocument(); - /* - TBD: - if(null == doc) - { - throw new RuntimeException(XSLMessages.createXPATHMessage(XPATHErrorResources.ER_CHILD_HAS_NO_OWNER_DOCUMENT, null));//"Attribute child does not have an owner document!"); - } - */ - - // Given how expensive the tree walk may be, we should first ask - // whether this DOM can answer the question for us. The additional - // test does slow down Level 1 DOMs slightly. DOMHelper2, which - // is currently specialized for Xerces, assumes it can use the - // Level 2 solution. We might want to have an intermediate stage, - // which would assume DOM Level 2 but not assume Xerces. - // - // (Shouldn't have to check whether impl is null in a compliant DOM, - // but let's be paranoid for a moment...) - DOMImplementation impl=doc.getImplementation(); - if(impl!=null && impl.hasFeature("Core","2.0")) - { - parent=((Attr)node).getOwnerElement(); - return parent; - } - - // DOM Level 1 solution, as fallback. Hugely expensive. - - Element rootElem = doc.getDocumentElement(); - - if (null == rootElem) - { - throw new RuntimeException( - XMLMessages.createXMLMessage( - XMLErrorResources.ER_CHILD_HAS_NO_OWNER_DOCUMENT_ELEMENT, - null)); //"Attribute child does not have an owner document element!"); - } - - parent = locateAttrParent(rootElem, node); - - } - else - { - parent = node.getParentNode(); - - // if((Node.DOCUMENT_NODE != nodeType) && (null == parent)) - // { - // throw new RuntimeException("Child does not have parent!"); - // } - } - - return parent; - } - - /** - * Given an ID, return the element. This can work only if the document - * is interpreted in the context of a DTD or Schema, since otherwise - * we don't know which attributes are or aren't IDs. - *

    - * Note that DOM Level 1 had no ability to retrieve this information. - * DOM Level 2 introduced it but does not promise that it will be - * supported in all DOMs; those which can't support it will always - * return null. - *

    - * TODO: getElementByID is currently unimplemented. Support DOM Level 2? - * - * @param id The unique identifier to be searched for. - * @param doc The document to search within. - * @return CURRENTLY HARDCODED TO NULL, but it should be: - * The node which has this unique identifier, or null if there - * is no such node or this DOM can't reliably recognize it. - */ - public Element getElementByID(String id, Document doc) - { - return null; - } - - /** - * The getUnparsedEntityURI function returns the URI of the unparsed - * entity with the specified name in the same document as the context - * node (see [3.3 Unparsed Entities]). It returns the empty string if - * there is no such entity. - *

    - * XML processors may choose to use the System Identifier (if one - * is provided) to resolve the entity, rather than the URI in the - * Public Identifier. The details are dependent on the processor, and - * we would have to support some form of plug-in resolver to handle - * this properly. Currently, we simply return the System Identifier if - * present, and hope that it a usable URI or that our caller can - * map it to one. - * TODO: Resolve Public Identifiers... or consider changing function name. - *

    - * If we find a relative URI - * reference, XML expects it to be resolved in terms of the base URI - * of the document. The DOM doesn't do that for us, and it isn't - * entirely clear whether that should be done here; currently that's - * pushed up to a higher levelof our application. (Note that DOM Level - * 1 didn't store the document's base URI.) - * TODO: Consider resolving Relative URIs. - *

    - * (The DOM's statement that "An XML processor may choose to - * completely expand entities before the structure model is passed - * to the DOM" refers only to parsed entities, not unparsed, and hence - * doesn't affect this function.) - * - * @param name A string containing the Entity Name of the unparsed - * entity. - * @param doc Document node for the document to be searched. - * - * @return String containing the URI of the Unparsed Entity, or an - * empty string if no such entity exists. - */ - public String getUnparsedEntityURI(String name, Document doc) - { - - String url = ""; - DocumentType doctype = doc.getDoctype(); - - if (null != doctype) - { - NamedNodeMap entities = doctype.getEntities(); - if(null == entities) - return url; - Entity entity = (Entity) entities.getNamedItem(name); - if(null == entity) - return url; - - String notationName = entity.getNotationName(); - - if (null != notationName) // then it's unparsed - { - // The draft says: "The XSLT processor may use the public - // identifier to generate a URI for the entity instead of the URI - // specified in the system identifier. If the XSLT processor does - // not use the public identifier to generate the URI, it must use - // the system identifier; if the system identifier is a relative - // URI, it must be resolved into an absolute URI using the URI of - // the resource containing the entity declaration as the base - // URI [RFC2396]." - // So I'm falling a bit short here. - url = entity.getSystemId(); - - if (null == url) - { - url = entity.getPublicId(); - } - else - { - // This should be resolved to an absolute URL, but that's hard - // to do from here. - } - } - } - - return url; - } - - /** - * Support for getParentOfNode; walks a DOM tree until it finds - * the Element which owns the Attr. This is hugely expensive, and - * if at all possible you should use the DOM Level 2 Attr.ownerElement() - * method instead. - *

    - * The DOM Level 1 developers expected that folks would keep track - * of the last Element they'd seen and could recover the info from - * that source. Obviously that doesn't work very well if the only - * information you've been presented with is the Attr. The DOM Level 2 - * getOwnerElement() method fixes that, but only for Level 2 and - * later DOMs. - * - * @param elem Element whose subtree is to be searched for this Attr - * @param attr Attr whose owner is to be located. - * - * @return the first Element whose attribute list includes the provided - * attr. In modern DOMs, this will also be the only such Element. (Early - * DOMs had some hope that Attrs might be sharable, but this idea has - * been abandoned.) - */ - private static Node locateAttrParent(Element elem, Node attr) - { - - Node parent = null; - - // This should only be called for Level 1 DOMs, so we don't have to - // worry about namespace issues. In later levels, it's possible - // for a DOM to have two Attrs with the same NodeName but - // different namespaces, and we'd need to get getAttributeNodeNS... - // but later levels also have Attr.getOwnerElement. - Attr check=elem.getAttributeNode(attr.getNodeName()); - if(check==attr) - parent = elem; - - if (null == parent) - { - for (Node node = elem.getFirstChild(); null != node; - node = node.getNextSibling()) - { - if (Node.ELEMENT_NODE == node.getNodeType()) - { - parent = locateAttrParent((Element) node, attr); - - if (null != parent) - break; - } - } - } - - return parent; - } - - /** - * The factory object used for creating nodes - * in the result tree. - */ - protected Document m_DOMFactory = null; - - /** - * Store the factory object required to create DOM nodes - * in the result tree. In fact, that's just the result tree's - * Document node... - * - * @param domFactory The DOM Document Node within whose context - * the result tree will be built. - */ - public void setDOMFactory(Document domFactory) - { - this.m_DOMFactory = domFactory; - } - - /** - * Retrieve the factory object required to create DOM nodes - * in the result tree. - * - * @return The result tree's DOM Document Node. - */ - public Document getDOMFactory() - { - - if (null == this.m_DOMFactory) - { - this.m_DOMFactory = createDocument(); - } - - return this.m_DOMFactory; - } - - /** - * Get the textual contents of the node. See - * getNodeData(Node,FastStringBuffer) for discussion of how - * whitespace nodes are handled. - * - * @param node DOM Node to be examined - * @return String containing a concatenation of all the - * textual content within that node. - * @see #getNodeData(Node,FastStringBuffer) - * - */ - public static String getNodeData(Node node) - { - - FastStringBuffer buf = StringBufferPool.get(); - String s; - - try - { - getNodeData(node, buf); - - s = (buf.length() > 0) ? buf.toString() : ""; - } - finally - { - StringBufferPool.free(buf); - } - - return s; - } - - /** - * Retrieve the text content of a DOM subtree, appending it into a - * user-supplied FastStringBuffer object. Note that attributes are - * not considered part of the content of an element. - *

    - * There are open questions regarding whitespace stripping. - * Currently we make no special effort in that regard, since the standard - * DOM doesn't yet provide DTD-based information to distinguish - * whitespace-in-element-context from genuine #PCDATA. Note that we - * should probably also consider xml:space if/when we address this. - * DOM Level 3 may solve the problem for us. - * - * @param node Node whose subtree is to be walked, gathering the - * contents of all Text or CDATASection nodes. - * @param buf FastStringBuffer into which the contents of the text - * nodes are to be concatenated. - */ - public static void getNodeData(Node node, FastStringBuffer buf) - { - - switch (node.getNodeType()) - { - case Node.DOCUMENT_FRAGMENT_NODE : - case Node.DOCUMENT_NODE : - case Node.ELEMENT_NODE : - { - for (Node child = node.getFirstChild(); null != child; - child = child.getNextSibling()) - { - getNodeData(child, buf); - } - } - break; - case Node.TEXT_NODE : - case Node.CDATA_SECTION_NODE : - buf.append(node.getNodeValue()); - break; - case Node.ATTRIBUTE_NODE : - buf.append(node.getNodeValue()); - break; - case Node.PROCESSING_INSTRUCTION_NODE : - // warning(XPATHErrorResources.WG_PARSING_AND_PREPARING); - break; - default : - // ignore - break; - } - } -} diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMOrder.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMOrder.java deleted file mode 100644 index ca74f77d60a..00000000000 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMOrder.java +++ /dev/null @@ -1,43 +0,0 @@ -/* - * reserved comment block - * DO NOT REMOVE OR ALTER! - */ -/* - * Copyright 1999-2004 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -/* - * $Id: DOMOrder.java,v 1.2.4.1 2005/09/15 08:15:41 suresh_emailid Exp $ - */ -package com.sun.org.apache.xml.internal.utils; - -/** - * @deprecated Since the introduction of the DTM, this class will be removed. - * Nodes that implement this index can return a document order index. - * Eventually, this will be replaced by DOM 3 methods. - * (compareDocumentOrder and/or compareTreePosition.) - */ -public interface DOMOrder -{ - - /** - * Get the UID (document order index). - * - * @return integer whose relative value corresponds to document order - * -- that is, if node1.getUid()1" }, { "zero", "0" }, diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_pt_BR.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_pt_BR.java index 259d5a92de3..3b5c79c4d81 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_pt_BR.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_pt_BR.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xpath.internal.res; import java.util.ListResourceBundle; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_sv.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_sv.java index 880336d0b28..d78fb2c4093 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_sv.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_sv.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xpath.internal.res; import java.util.ListResourceBundle; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_zh_CN.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_zh_CN.java index 6cdaea4f9b2..29e45603345 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_zh_CN.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_zh_CN.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xpath.internal.res; import java.util.ListResourceBundle; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_zh_TW.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_zh_TW.java index 531eb0250ba..de1464500c7 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_zh_TW.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHErrorResources_zh_TW.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,6 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xpath.internal.res; import java.util.ListResourceBundle; diff --git a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHMessages.java b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHMessages.java index 1d0fe6ff49c..cdc4268d47e 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHMessages.java +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/res/XPATHMessages.java @@ -3,13 +3,14 @@ * DO NOT REMOVE OR ALTER! */ /* - * Copyright 1999-2004 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 + * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -17,9 +18,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -/* - * $Id: XPATHMessages.java,v 1.2.4.1 2005/09/01 14:57:34 pvedula Exp $ - */ + package com.sun.org.apache.xpath.internal.res; import com.sun.org.apache.bcel.internal.util.SecuritySupport; diff --git a/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/Entity.java b/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/Entity.java index a11218436a9..69508b50384 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/Entity.java +++ b/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/Entity.java @@ -1,13 +1,13 @@ /* * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved. */ - /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -18,6 +18,7 @@ * limitations under the License. */ + package com.sun.xml.internal.stream; import java.io.InputStream; diff --git a/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/XMLEntityReader.java b/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/XMLEntityReader.java index 521c0098b41..9d7d671b8ca 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/XMLEntityReader.java +++ b/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/XMLEntityReader.java @@ -1,13 +1,13 @@ /* * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. */ - /* - * Copyright 2005 The Apache Software Foundation. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * @@ -18,6 +18,7 @@ * limitations under the License. */ + package com.sun.xml.internal.stream; import java.io.IOException; diff --git a/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/dtd/nonvalidating/XMLSimpleType.java b/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/dtd/nonvalidating/XMLSimpleType.java index 31ae534390e..6d0763ef3a4 100644 --- a/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/dtd/nonvalidating/XMLSimpleType.java +++ b/jaxp/src/java.xml/share/classes/com/sun/xml/internal/stream/dtd/nonvalidating/XMLSimpleType.java @@ -1,32 +1,21 @@ /* * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * by Oracle in the LICENSE file that accompanied this code. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - * - * THIS FILE WAS MODIFIED BY SUN MICROSYSTEMS, INC. */ - /* - * Copyright 2005 The Apache Software Foundation. + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package com.sun.xml.internal.stream.dtd.nonvalidating; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogFeatures.java b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogFeatures.java index 01d0b533055..5fca3130cf6 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogFeatures.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogFeatures.java @@ -34,9 +34,9 @@ import jdk.xml.internal.SecuritySupport; * The CatalogFeatures holds a collection of features and properties. *

    * - *

    Catalog Features

    * - *
    + *
    + * * * * @@ -44,7 +44,7 @@ import jdk.xml.internal.SecuritySupport; * * * - * + * * * * @@ -55,7 +55,7 @@ import jdk.xml.internal.SecuritySupport; * * * - * + * * @@ -71,7 +71,7 @@ import jdk.xml.internal.SecuritySupport; * * * - * + * * * @@ -89,7 +89,7 @@ import jdk.xml.internal.SecuritySupport; * * * - * + * * @@ -107,7 +107,7 @@ import jdk.xml.internal.SecuritySupport; * * * - * + * * * @@ -241,9 +241,10 @@ import jdk.xml.internal.SecuritySupport; * supports a resolver. The following table lists all such processes. * *

    - *

    Processes with Catalog Support

    + *

    Processes with Catalog Support

    * - *
    Catalog Features
    FeatureProperty NameSystem Property [1]jaxp.properties [1]Value [2]Value [2]Action
    FILESFILESA semicolon-delimited list of URIs to locate the catalog files. * The URIs must be absolute and have a URL protocol handler for the URI scheme. *
    PREFERPREFERIndicates the preference between the public and system * identifiers. The default value is public [3].javax.xml.catalog.prefer
    DEFERDEFERIndicates that the alternative catalogs including those * specified in delegate entries or nextCatalog are not read until they are * needed. The default value is true.
    RESOLVERESOLVEDetermines the action if there is no matching entry found after * all of the specified catalogs are exhausted. The default is strict.javax.xml.catalog.resolve [4]
    + *
    + * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogImpl.java b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogImpl.java index cbf77e5c9c0..db0f2b7f1f8 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogImpl.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogImpl.java @@ -88,6 +88,7 @@ class CatalogImpl extends GroupEntry implements Catalog { /** * Construct a Catalog with specified URI. * + * @param f the features object * @param uris the uri(s) to one or more catalogs * @throws CatalogException If an error happens while parsing the specified * catalog file. @@ -100,6 +101,7 @@ class CatalogImpl extends GroupEntry implements Catalog { * Construct a Catalog with specified URI. * * @param parent The parent catalog + * @param f the features object * @param uris the uri(s) to one or more catalogs * @throws CatalogException If an error happens while parsing the specified * catalog file. @@ -137,7 +139,7 @@ class CatalogImpl extends GroupEntry implements Catalog { for (String temp : catalogFile) { uri = URI.create(temp); start++; - if (verifyCatalogFile(uri)) { + if (verifyCatalogFile(null, uri)) { systemId = temp; try { baseURI = new URL(systemId); @@ -169,12 +171,14 @@ class CatalogImpl extends GroupEntry implements Catalog { parse(systemId); } + setCatalog(this); + //save this catalog before loading the next loadedCatalogs.put(systemId, this); //Load delegate and alternative catalogs if defer is false. if (!isDeferred()) { - loadDelegateCatalogs(); + loadDelegateCatalogs(this); loadNextCatalogs(); } } @@ -365,14 +369,16 @@ class CatalogImpl extends GroupEntry implements Catalog { //Check those specified in nextCatalogs if (nextCatalogs != null) { while (c == null && nextCatalogIndex < nextCatalogs.size()) { - c = getCatalog(nextCatalogs.get(nextCatalogIndex++).getCatalogURI()); + c = getCatalog(catalog, + nextCatalogs.get(nextCatalogIndex++).getCatalogURI()); } } //Check the input list if (c == null && inputFiles != null) { while (c == null && inputFilesIndex < inputFiles.size()) { - c = getCatalog(URI.create(inputFiles.get(inputFilesIndex++))); + c = getCatalog(null, + URI.create(inputFiles.get(inputFilesIndex++))); } } @@ -408,14 +414,14 @@ class CatalogImpl extends GroupEntry implements Catalog { //loads catalogs specified in nextCatalogs if (nextCatalogs != null) { nextCatalogs.stream().forEach((next) -> { - getCatalog(next.getCatalogURI()); + getCatalog(this, next.getCatalogURI()); }); } //loads catalogs from the input list if (inputFiles != null) { inputFiles.stream().forEach((uri) -> { - getCatalog(URI.create(uri)); + getCatalog(null, URI.create(uri)); }); } } @@ -423,17 +429,19 @@ class CatalogImpl extends GroupEntry implements Catalog { /** * Returns a Catalog object by the specified path. * - * @param path the path to a catalog + * @param parent the parent catalog for the alternative catalogs to be loaded. + * It will be null if the ones to be loaded are from the input list. + * @param uri the path to a catalog * @return a Catalog object */ - Catalog getCatalog(URI uri) { + Catalog getCatalog(CatalogImpl parent, URI uri) { if (uri == null) { return null; } CatalogImpl c = null; - if (verifyCatalogFile(uri)) { + if (verifyCatalogFile(parent, uri)) { c = getLoadedCatalog(uri.toASCIIString()); if (c == null) { c = new CatalogImpl(this, features, uri); @@ -459,6 +467,6 @@ class CatalogImpl extends GroupEntry implements Catalog { * @return a count of all loaded catalogs */ int loadedCatalogCount() { - return loadedCatalogs.size() + delegateCatalogs.size(); + return loadedCatalogs.size(); } } diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages.properties index a1133ca9da5..cd6b2d3f909 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,25 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = The error message corresponding to the message key can not be found. -FormatFailed = An internal error occurred while formatting the following message:\n +# General errors +BadMessageKey = JAXP09000001: The error message corresponding to the message key can not be found. +FormatFailed = JAXP09000002: An internal error occurred while formatting the following message:\n +OtherError = JAXP09000003: Unexpected error. -#invalid catalog file -InvalidCatalog = The document element of a catalog must be catalog. -InvalidEntryType = The entry type ''{0}'' is not valid. -CircularReference = Circular reference is not allowed: ''{0}''. +# Implementation restriction +CircularReference = JAXP09010001: Circular reference is not allowed: ''{0}''. + +# Input or configuration errors +InvalidCatalog = JAXP09020001: The document element of a catalog must be catalog. +InvalidEntryType = JAXP09020002: The entry type ''{0}'' is not valid. +UriNotAbsolute = JAXP09020003: The specified URI ''{0}'' is not absolute. +UriNotValidUrl = JAXP09020004: The specified URI ''{0}'' is not a valid URL. +InvalidArgument = JAXP09020005: The specified argument ''{0}'' (case sensitive) for ''{1}'' is not valid. +NullArgument = JAXP09020006: The argument ''{0}'' can not be null. +InvalidPath = JAXP09020007: The path ''{0}'' is invalid. + + +# Parsing errors +ParserConf = JAXP09030001: Unexpected error while configuring a SAX parser. +ParsingFailed = JAXP09030002: Failed to parse the catalog file. +NoCatalogFound = JAXP09030003: No Catalog is specified. + + +# Resolving errors +NoMatchFound = JAXP09040001: No match found for publicId ''{0}'' and systemId ''{1}''. +NoMatchURIFound = JAXP09040002: No match found for href ''{0}'' and base ''{1}''. +FailedCreatingURI = JAXP09040003: Can not construct URI using href ''{0}'' and base ''{1}''. -#errors -UriNotAbsolute = The specified URI ''{0}'' is not absolute. -UriNotValidUrl = The specified URI ''{0}'' is not a valid URL. -InvalidArgument = The specified argument ''{0}'' (case sensitive) for ''{1}'' is not valid. -NullArgument = The argument ''{0}'' can not be null. -InvalidPath = The path ''{0}'' is invalid. -ParserConf = Unexpected error while configuring a SAX parser. -ParsingFailed = Failed to parse the catalog file. -NoCatalogFound = No Catalog is specified. -NoMatchFound = No match found for publicId ''{0}'' and systemId ''{1}''. -NoMatchURIFound = No match found for href ''{0}'' and base ''{1}''. -FailedCreatingURI = Can not construct URI using href ''{0}'' and base ''{1}''. -OtherError = Unexpected error. \ No newline at end of file diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_de.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_de.properties index dc5e23ea133..8cd117e3489 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_de.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_de.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. -FormatFailed = Beim Formatieren der folgenden Meldung ist ein interner Fehler aufgetreten:\n +# General errors +BadMessageKey = JAXP09000001: Die zum Meldungsschl\u00FCssel geh\u00F6rige Fehlermeldung kann nicht gefunden werden. +FormatFailed = JAXP09000002: Beim Formatieren der folgenden Meldung ist ein interner Fehler aufgetreten:\n +OtherError = JAXP09000003: Unerwarteter Fehler. -#invalid catalog file -InvalidCatalog = Das Dokumentelement eines Katalogs muss ein Katalog sein. -InvalidEntryType = Der Eintragstyp "{0}" ist ung\u00FCltig. -CircularReference = Zirkelbezug ist nicht zul\u00E4ssig: "{0}". +# Implementation restriction +CircularReference = JAXP09010001: Zirkelbezug ist nicht zul\u00E4ssig: "{0}". + +# Input or configuration errors +InvalidCatalog = JAXP09020001: Das Dokumentelement eines Katalogs muss ein Katalog sein. +InvalidEntryType = JAXP09020002: Der Eintragstyp "{0}" ist nicht g\u00FCltig. +UriNotAbsolute = JAXP09020003: Die angegebene URI "{0}" ist nicht absolut. +UriNotValidUrl = JAXP09020004: Die angegebene URI "{0}" ist keine g\u00FCltige URL. +InvalidArgument = JAXP09020005: Das angegebene Argument "{0}" (unter Beachtung der Gro\u00DF-/Kleinschreibung) f\u00FCr "{1}" ist nicht g\u00FCltig. +NullArgument = JAXP09020006: Das Argument "{0}" darf nicht null sein. +InvalidPath = JAXP09020007: Der Pfad "{0}" ist ung\u00FCltig. + + +# Parsing errors +ParserConf = JAXP09030001: Unerwarteter Fehler bei der Konfiguration eines SAX-Parsers. +ParsingFailed = JAXP09030002: Die Katalogdatei konnte nicht geparst werden. +NoCatalogFound = JAXP09030003: Kein Katalog angegeben. + + +# Resolving errors +NoMatchFound = JAXP09040001: Keine \u00DCbereinstimmung f\u00FCr publicId "{0}" und systemId "{1}" gefunden. +NoMatchURIFound = JAXP09040002: Keine \u00DCbereinstimmung f\u00FCr href "{0}" und base "{1}" gefunden. +FailedCreatingURI = JAXP09040003: URI kann nicht mit href "{0}" und base "{1}" erstellt werden. -#errors -InvalidArgument = Das angegebene Argument "{0}" (unter Beachtung der Gro\u00DF-/Kleinschreibung) f\u00FCr "{1}" ist nicht g\u00FCltig. -NullArgument = Das Argument "{0}" darf nicht null sein. -InvalidPath = Der Pfad "{0}" ist ung\u00FCltig. -ParserConf = Unerwarteter Fehler bei der Konfiguration eines SAX-Parsers. -ParsingFailed = Die Katalogdatei konnte nicht geparst werden. -NoCatalogFound = Kein Katalog angegeben. -NoMatchFound = Keine \u00DCbereinstimmung f\u00FCr publicId "{0}" und systemId "{1}" gefunden. -NoMatchURIFound = Keine \u00DCbereinstimmung f\u00FCr href "{0}" und base "{1}" gefunden. -FailedCreatingURI = URI kann nicht mit href "{0}" und base "{1}" erstellt werden. -OtherError = Unerwarteter Fehler. diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_es.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_es.properties index fa364803cf0..cd535d6aa6c 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_es.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_es.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = No se ha encontrado el mensaje de error que corresponde a la clave de mensaje. -FormatFailed = Se ha producido un error interno al formatear el siguiente mensaje:\n +# General errors +BadMessageKey = JAXP09000001: No se ha encontrado el mensaje de error que corresponde a la clave de mensaje. +FormatFailed = JAXP09000002: Se ha producido un error interno al formatear el siguiente mensaje:\n +OtherError = JAXP09000003: Error inesperado. -#invalid catalog file -InvalidCatalog = El elemento de documento de un cat\u00E1logo debe ser un cat\u00E1logo. -InvalidEntryType = El tipo de entrada ''{0}'' no es v\u00E1lido. -CircularReference = No est\u00E1 permitida la referencia circular: ''{0}''. +# Implementation restriction +CircularReference = JAXP09010001: No est\u00E1 permitida la referencia circular: ''{0}''. + +# Input or configuration errors +InvalidCatalog = JAXP09020001: El elemento de documento de un cat\u00E1logo debe ser un cat\u00E1logo. +InvalidEntryType = JAXP09020002: El tipo de entrada ''{0}'' no es v\u00E1lido. +UriNotAbsolute = JAXP09020003: El URI especificado ''{0}'' no es absoluto. +UriNotValidUrl = JAXP09020004: El URI especificado ''{0}'' no es una URL v\u00E1lida. +InvalidArgument = JAXP09020005: El argumento especificado ''{0}'' (sensible a may\u00FAsculas y min\u00FAsculas) para ''{1}'' no es v\u00E1lido. +NullArgument = JAXP09020006: El argumento ''{0}'' no puede ser nulo. +InvalidPath = JAXP09020007: La ruta ''{0}'' no es v\u00E1lida. + + +# Parsing errors +ParserConf = JAXP09030001: Error inesperado al configurar el analizador SAX. +ParsingFailed = JAXP09030002: Fallo al analizar el archivo de cat\u00E1logo. +NoCatalogFound = JAXP09030003: No se ha especificado ning\u00FAn cat\u00E1logo. + + +# Resolving errors +NoMatchFound = JAXP09040001: No se ha encontrado ninguna coincidencia para publicId ''{0}'' y systemId ''{1}''. +NoMatchURIFound = JAXP09040002: No se ha encontrado ninguna coincidencia para href ''{0}'' y base ''{1}''. +FailedCreatingURI = JAXP09040003: No se puede crear el URI con href ''{0}'' y base ''{1}''. -#errors -InvalidArgument = El argumento especificado ''{0}'' (sensible a may\u00FAsculas y min\u00FAsculas) para ''{1}'' no es v\u00E1lido. -NullArgument = El argumento ''{0}'' no puede ser nulo. -InvalidPath = La ruta ''{0}'' no es v\u00E1lida. -ParserConf = Error inesperado al configurar el analizador SAX. -ParsingFailed = Fallo al analizar el archivo de cat\u00E1logo. -NoCatalogFound = No se ha especificado ning\u00FAn cat\u00E1logo. -NoMatchFound = No se ha encontrado ninguna coincidencia para publicId ''{0}'' y systemId ''{1}''. -NoMatchURIFound = No se ha encontrado ninguna coincidencia para href ''{0}'' y base ''{1}''. -FailedCreatingURI = No se puede crear el URI con href ''{0}'' y base ''{1}''. -OtherError = Error inesperado. diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_fr.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_fr.properties index 3cddf0ddc67..ceb50f651d5 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_fr.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_fr.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. -FormatFailed = Une erreur interne est survenue lors du formatage du message suivant :\n +# General errors +BadMessageKey = JAXP09000001 : Le message d'erreur correspondant \u00E0 la cl\u00E9 de message est introuvable. +FormatFailed = JAXP09000002 : Une erreur interne est survenue lors du formatage du message suivant :\n +OtherError = JAXP09000003 : Erreur inattendue. -#invalid catalog file -InvalidCatalog = L'\u00E9l\u00E9ment de document d'un catalogue doit \u00EAtre un catalogue. -InvalidEntryType = Le type d''entr\u00E9e ''{0}'' n''est pas valide. -CircularReference = La r\u00E9f\u00E9rence circulaire n''est pas autoris\u00E9e : ''{0}''. +# Implementation restriction +CircularReference = JAXP09010001 : La r\u00E9f\u00E9rence circulaire n''est pas autoris\u00E9e : ''{0}''. + +# Input or configuration errors +InvalidCatalog = JAXP09020001 : L'\u00E9l\u00E9ment de document d'un catalogue doit \u00EAtre un catalogue. +InvalidEntryType = JAXP09020002 : Le type d''entr\u00E9e ''{0}'' n''est pas valide. +UriNotAbsolute = JAXP09020003 : L''URI indiqu\u00E9 ''{0}'' n''est pas absolu. +UriNotValidUrl = JAXP09020004 : L''URI indiqu\u00E9 ''{0}'' n''est pas une URL valide. +InvalidArgument = JAXP09020005 : L''argument indiqu\u00E9 ''{0}'' (respect maj./min.) pour ''{1}'' n''est pas valide. +NullArgument = JAXP09020006 : L''argument ''{0}'' ne peut pas \u00EAtre NULL. +InvalidPath = JAXP09020007 : Le chemin ''{0}'' n''est pas valide. + + +# Parsing errors +ParserConf = JAXP09030001 : Erreur inattendue lors de la configuration d'un analyseur SAX. +ParsingFailed = JAXP09030002 : Echec de l'analyse du fichier de catalogue. +NoCatalogFound = JAXP09030003 : Aucun catalogue n'est indiqu\u00E9. + + +# Resolving errors +NoMatchFound = JAXP09040001 : Aucune correspondance trouv\u00E9e pour publicId ''{0}'' et systemId ''{1}''. +NoMatchURIFound = JAXP09040002 : Aucune correspondance trouv\u00E9e pour l''\u00E9l\u00E9ment href ''{0}'' et la base ''{1}''. +FailedCreatingURI = JAXP09040003 : Impossible de construire l''URI \u00E0 l''aide de l''\u00E9l\u00E9ment href ''{0}'' et de la base ''{1}''. -#errors -InvalidArgument = L''argument indiqu\u00E9 ''{0}'' (respect maj./min.) pour ''{1}'' n''est pas valide. -NullArgument = L''argument ''{0}'' ne peut pas \u00EAtre NULL. -InvalidPath = Le chemin ''{0}'' n''est pas valide. -ParserConf = Erreur inattendue lors de la configuration d'un analyseur SAX. -ParsingFailed = Echec de l'analyse du fichier de catalogue. -NoCatalogFound = Aucun catalogue n'est indiqu\u00E9. -NoMatchFound = Aucune correspondance trouv\u00E9e pour publicId ''{0}'' et systemId ''{1}''. -NoMatchURIFound = Aucune correspondance trouv\u00E9e pour l''\u00E9l\u00E9ment href ''{0}'' et la base ''{1}''. -FailedCreatingURI = Impossible de construire l''URI \u00E0 l''aide de l''\u00E9l\u00E9ment href ''{0}'' et de la base ''{1}''. -OtherError = Erreur inattendue. diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_it.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_it.properties index 05bb803d2bc..b6417ba07a7 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_it.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_it.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = Impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. -FormatFailed = Si \u00E8 verificato un errore interno durante la formattazione del seguente messaggio:\n +# General errors +BadMessageKey = JAXP09000001: impossibile trovare il messaggio di errore corrispondente alla chiave di messaggio. +FormatFailed = JAXP09000002: si \u00E8 verificato un errore interno durante la formattazione del seguente messaggio:\n +OtherError = JAXP09000003: errore imprevisto. -#invalid catalog file -InvalidCatalog = L'elemento documento di un catalogo deve essere un catalogo. -InvalidEntryType = Il tipo di voce ''{0}'' non \u00E8 valido. -CircularReference = La dipendenza circolare non \u00E8 consentita: ''{0}''. +# Implementation restriction +CircularReference = JAXP09010001: il riferimento circolare non \u00E8 consentito: ''{0}''. + +# Input or configuration errors +InvalidCatalog = JAXP09020001: l'elemento documento di un catalogo deve essere un catalogo. +InvalidEntryType = JAXP09020002: il tipo di voce ''{0}'' non \u00E8 valido. +UriNotAbsolute = JAXP09020003: l''URI specificato ''{0}'' non \u00E8 assoluto. +UriNotValidUrl = JAXP09020004: l''URI specificato ''{0}'' non \u00E8 valido. +InvalidArgument = JAXP09020005: l''argomento specificato ''{0}'' (con distinzione tra maiuscole e minuscole) per ''{1}'' non \u00E8 valido. +NullArgument = JAXP09020006: l''argomento ''{0}'' non pu\u00F2 essere nullo. +InvalidPath = JAXP09020007: il percorso ''{0}'' non \u00E8 valido. + + +# Parsing errors +ParserConf = JAXP09030001: errore imprevisto durante la configurazione di un parser SAX. +ParsingFailed = JAXP09030002: analisi del file catalogo non riuscita. +NoCatalogFound = JAXP09030003: nessun catalogo specificato. + + +# Resolving errors +NoMatchFound = JAXP09040001: nessuna corrispondenza trovata per publicId ''{0}'' e systemId ''{1}''. +NoMatchURIFound = JAXP09040002: nessuna corrispondenza trovata per href ''{0}'' e base ''{1}''. +FailedCreatingURI = JAXP09040003: impossibile creare l''URI utilizzando href ''{0}'' e base ''{1}''. -#errors -InvalidArgument = L''argomento specificato ''{0}'' (con distinzione tra maiuscole e minuscole) per ''{1}'' non \u00E8 valido. -NullArgument = L''argomento ''{0}'' non pu\u00F2 essere nullo. -InvalidPath = Il percorso ''{0}'' non \u00E8 valido. -ParserConf = Errore imprevisto durante la configurazione di un parser SAX. -ParsingFailed = Analisi del file catalogo non riuscita. -NoCatalogFound = Nessun catalogo specificato. -NoMatchFound = Nessuna corrispondenza trovata per publicId ''{0}'' e systemId ''{1}''. -NoMatchURIFound = Nessuna corrispondenza trovata per href ''{0}'' e base ''{1}''. -FailedCreatingURI = Impossibile creare l''URI utilizzando href ''{0}'' e base ''{1}''. -OtherError = Errore imprevisto. diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_ja.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_ja.properties index d58bc2283c9..f806d287ea6 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_ja.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_ja.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 -FormatFailed = \u6B21\u306E\u30E1\u30C3\u30BB\u30FC\u30B8\u306E\u66F8\u5F0F\u8A2D\u5B9A\u4E2D\u306B\u5185\u90E8\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F:\n +# General errors +BadMessageKey = JAXP09000001: \u30E1\u30C3\u30BB\u30FC\u30B8\u30FB\u30AD\u30FC\u306B\u5BFE\u5FDC\u3059\u308B\u30A8\u30E9\u30FC\u30FB\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 +FormatFailed = JAXP09000002: \u6B21\u306E\u30E1\u30C3\u30BB\u30FC\u30B8\u306E\u30D5\u30A9\u30FC\u30DE\u30C3\u30C8\u4E2D\u306B\u5185\u90E8\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F:\n +OtherError = JAXP09000003: \u4E88\u671F\u3057\u306A\u3044\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002 -#invalid catalog file -InvalidCatalog = \u30AB\u30BF\u30ED\u30B0\u306E\u30C9\u30AD\u30E5\u30E1\u30F3\u30C8\u8981\u7D20\u306Fcatalog\u306B\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -InvalidEntryType = \u30A8\u30F3\u30C8\u30EA\u30FB\u30BF\u30A4\u30D7''{0}''\u306F\u6709\u52B9\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u3002 -CircularReference = \u5FAA\u74B0\u53C2\u7167\u306F\u8A31\u53EF\u3055\u308C\u307E\u305B\u3093: ''{0}''\u3002 +# Implementation restriction +CircularReference = JAXP09010001: \u5FAA\u74B0\u53C2\u7167\u306F\u8A31\u53EF\u3055\u308C\u307E\u305B\u3093: ''{0}''\u3002 + +# Input or configuration errors +InvalidCatalog = JAXP09020001: \u30AB\u30BF\u30ED\u30B0\u306E\u30C9\u30AD\u30E5\u30E1\u30F3\u30C8\u8981\u7D20\u306Fcatalog\u306B\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 +InvalidEntryType = JAXP09020002: \u30A8\u30F3\u30C8\u30EA\u30FB\u30BF\u30A4\u30D7''{0}''\u306F\u6709\u52B9\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u3002 +UriNotAbsolute = JAXP09020003: \u6307\u5B9A\u3055\u308C\u305FURI ''{0}''\u304C\u7D76\u5BFEURI\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u3002 +UriNotValidUrl = JAXP09020004: \u6307\u5B9A\u3057\u305FURI ''{0}''\u306F\u6709\u52B9\u306AURL\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u3002 +InvalidArgument = JAXP09020005: ''{1}''\u306B\u6307\u5B9A\u3055\u308C\u305F\u5F15\u6570''{0}'' (\u5927/\u5C0F\u6587\u5B57\u3092\u533A\u5225)\u306F\u6709\u52B9\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u3002 +NullArgument = JAXP09020006: \u5F15\u6570''{0}''\u306Fnull\u306B\u3067\u304D\u307E\u305B\u3093\u3002 +InvalidPath = JAXP09020007: \u30D1\u30B9''{0}''\u306F\u7121\u52B9\u3067\u3059\u3002 + + +# Parsing errors +ParserConf = JAXP09030001: SAX\u30D1\u30FC\u30B5\u30FC\u306E\u69CB\u6210\u4E2D\u306B\u4E88\u671F\u3057\u306A\u3044\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002 +ParsingFailed = JAXP09030002: \u30AB\u30BF\u30ED\u30B0\u30FB\u30D5\u30A1\u30A4\u30EB\u306E\u89E3\u6790\u306B\u5931\u6557\u3057\u307E\u3057\u305F\u3002 +NoCatalogFound = JAXP09030003: \u30AB\u30BF\u30ED\u30B0\u304C\u6307\u5B9A\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002 + + +# Resolving errors +NoMatchFound = JAXP09040001: publicId ''{0}''\u304A\u3088\u3073systemId ''{1}''\u306B\u4E00\u81F4\u3059\u308B\u3082\u306E\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 +NoMatchURIFound = JAXP09040002: href ''{0}''\u304A\u3088\u3073base ''{1}''\u306B\u4E00\u81F4\u3059\u308B\u3082\u306E\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 +FailedCreatingURI = JAXP09040003: href ''{0}''\u304A\u3088\u3073base ''{1}''\u3092\u4F7F\u7528\u3057\u3066URI\u3092\u751F\u6210\u3067\u304D\u307E\u305B\u3093\u3002 -#errors -InvalidArgument = ''{1}''\u306B\u6307\u5B9A\u3055\u308C\u305F\u5F15\u6570''{0}'' (\u5927/\u5C0F\u6587\u5B57\u3092\u533A\u5225)\u306F\u6709\u52B9\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u3002 -NullArgument = \u5F15\u6570''{0}''\u306Fnull\u306B\u3067\u304D\u307E\u305B\u3093\u3002 -InvalidPath = \u30D1\u30B9''{0}''\u306F\u7121\u52B9\u3067\u3059\u3002 -ParserConf = SAX\u30D1\u30FC\u30B5\u30FC\u306E\u69CB\u6210\u4E2D\u306B\u4E88\u671F\u3057\u306A\u3044\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002 -ParsingFailed = \u30AB\u30BF\u30ED\u30B0\u30FB\u30D5\u30A1\u30A4\u30EB\u306E\u89E3\u6790\u306B\u5931\u6557\u3057\u307E\u3057\u305F\u3002 -NoCatalogFound = \u30AB\u30BF\u30ED\u30B0\u304C\u6307\u5B9A\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002 -NoMatchFound = publicId ''{0}''\u304A\u3088\u3073systemId ''{1}''\u306B\u4E00\u81F4\u3059\u308B\u3082\u306E\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 -NoMatchURIFound = href ''{0}''\u304A\u3088\u3073base ''{1}''\u306B\u4E00\u81F4\u3059\u308B\u3082\u306E\u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093\u3002 -FailedCreatingURI = href ''{0}''\u304A\u3088\u3073base ''{1}''\u3092\u4F7F\u7528\u3057\u3066URI\u3092\u751F\u6210\u3067\u304D\u307E\u305B\u3093\u3002 -OtherError = \u4E88\u671F\u3057\u306A\u3044\u30A8\u30E9\u30FC\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002 diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_ko.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_ko.properties index 03334135cc4..c3645fb8791 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_ko.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_ko.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. -FormatFailed = \uB2E4\uC74C \uBA54\uC2DC\uC9C0\uC758 \uD615\uC2DD\uC744 \uC9C0\uC815\uD558\uB294 \uC911 \uB0B4\uBD80 \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4.\n +# General errors +BadMessageKey = JAXP09000001: \uBA54\uC2DC\uC9C0 \uD0A4\uC5D0 \uD574\uB2F9\uD558\uB294 \uC624\uB958 \uBA54\uC2DC\uC9C0\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. +FormatFailed = JAXP09000002: \uB2E4\uC74C \uBA54\uC2DC\uC9C0\uC758 \uD615\uC2DD\uC744 \uC9C0\uC815\uD558\uB294 \uC911 \uB0B4\uBD80 \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4.\n +OtherError = JAXP09000003: \uC608\uC0C1\uCE58 \uC54A\uC740 \uC624\uB958\uC785\uB2C8\uB2E4. -#invalid catalog file -InvalidCatalog = \uCE74\uD0C8\uB85C\uADF8\uC758 \uBB38\uC11C \uC694\uC18C\uB294 \uCE74\uD0C8\uB85C\uADF8\uC5EC\uC57C \uD569\uB2C8\uB2E4. -InvalidEntryType = \uD56D\uBAA9 \uC720\uD615 ''{0}''\uC774(\uAC00) \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. -CircularReference = \uC21C\uD658 \uCC38\uC870\uAC00 \uD5C8\uC6A9\uB418\uC9C0 \uC54A\uC74C: ''{0}''. +# Implementation restriction +CircularReference = JAXP09010001: \uC21C\uD658 \uCC38\uC870\uAC00 \uD5C8\uC6A9\uB418\uC9C0 \uC54A\uC74C: ''{0}''. + +# Input or configuration errors +InvalidCatalog = JAXP09020001: Catalog\uC758 \uBB38\uC11C \uC694\uC18C\uB294 \uCE74\uD0C8\uB85C\uADF8\uC5EC\uC57C \uD569\uB2C8\uB2E4. +InvalidEntryType = JAXP09020002: \uD56D\uBAA9 \uC720\uD615 ''{0}''\uC774(\uAC00) \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. +UriNotAbsolute = JAXP09020003: \uC9C0\uC815\uB41C URI ''{0}''\uC774(\uAC00) \uC808\uB300 \uACBD\uB85C\uAC00 \uC544\uB2D9\uB2C8\uB2E4. +UriNotValidUrl = JAXP09020004: \uC9C0\uC815\uB41C URI ''{0}''\uC774(\uAC00) \uBD80\uC801\uD569\uD55C URL\uC785\uB2C8\uB2E4. +InvalidArgument = JAXP09020005: ''{1}''\uC5D0 \uB300\uD574 \uC9C0\uC815\uB41C \uC778\uC218 ''{0}''(\uB300\uC18C\uBB38\uC790 \uAD6C\uBD84)\uC774(\uAC00) \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. +NullArgument = JAXP09020006: ''{0}'' \uC778\uC218\uB294 \uB110\uC77C \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. +InvalidPath = JAXP09020007: ''{0}'' \uACBD\uB85C\uAC00 \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. + + +# Parsing errors +ParserConf = JAXP09030001: SAX \uAD6C\uBB38\uBD84\uC11D\uAE30\uB97C \uAD6C\uC131\uD558\uB294 \uC911 \uC608\uC0C1\uCE58 \uC54A\uC740 \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4. +ParsingFailed = JAXP09030002: Catalog \uD30C\uC77C\uC758 \uAD6C\uBB38\uBD84\uC11D\uC744 \uC2E4\uD328\uD588\uC2B5\uB2C8\uB2E4. +NoCatalogFound = JAXP09030003: \uC9C0\uC815\uB41C catalog\uAC00 \uC5C6\uC2B5\uB2C8\uB2E4. + + +# Resolving errors +NoMatchFound = JAXP09040001: publicId ''{0}'', systemId ''{1}''\uC5D0 \uB300\uD55C \uC77C\uCE58 \uD56D\uBAA9\uC744 \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. +NoMatchURIFound = JAXP09040002: href ''{0}'', base ''{1}''\uC5D0 \uB300\uD55C \uC77C\uCE58 \uD56D\uBAA9\uC744 \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. +FailedCreatingURI = JAXP09040003: href ''{0}'', base ''{1}''\uC744(\uB97C) \uC0AC\uC6A9\uD558\uC5EC URI\uB97C \uAD6C\uC131\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. -#errors -InvalidArgument = ''{1}''\uC5D0 \uB300\uD574 \uC9C0\uC815\uB41C \uC778\uC218 ''{0}''(\uB300\uC18C\uBB38\uC790 \uAD6C\uBD84)\uC774(\uAC00) \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. -NullArgument = ''{0}'' \uC778\uC218\uB294 \uB110\uC77C \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. -InvalidPath = ''{0}'' \uACBD\uB85C\uAC00 \uBD80\uC801\uD569\uD569\uB2C8\uB2E4. -ParserConf = SAX \uAD6C\uBB38 \uBD84\uC11D\uAE30\uB97C \uAD6C\uC131\uD558\uB294 \uC911 \uC608\uC0C1\uCE58 \uC54A\uC740 \uC624\uB958\uAC00 \uBC1C\uC0DD\uD588\uC2B5\uB2C8\uB2E4. -ParsingFailed = \uCE74\uD0C8\uB85C\uADF8 \uD30C\uC77C\uC758 \uAD6C\uBB38 \uBD84\uC11D\uC744 \uC2E4\uD328\uD588\uC2B5\uB2C8\uB2E4. -NoCatalogFound = \uC9C0\uC815\uB41C \uCE74\uD0C8\uB85C\uADF8\uAC00 \uC5C6\uC2B5\uB2C8\uB2E4. -NoMatchFound = publicId ''{0}'', systemId ''{1}''\uC5D0 \uB300\uD55C \uC77C\uCE58 \uD56D\uBAA9\uC744 \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. -NoMatchURIFound = href ''{0}'', base ''{1}''\uC5D0 \uB300\uD55C \uC77C\uCE58 \uD56D\uBAA9\uC744 \uCC3E\uC744 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. -FailedCreatingURI = href ''{0}'', base ''{1}''\uC744(\uB97C) \uC0AC\uC6A9\uD558\uC5EC URI\uB97C \uAD6C\uC131\uD560 \uC218 \uC5C6\uC2B5\uB2C8\uB2E4. -OtherError = \uC608\uC0C1\uCE58 \uC54A\uC740 \uC624\uB958\uC785\uB2C8\uB2E4. diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_pt_BR.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_pt_BR.properties index 18434b91fea..d87155085ce 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_pt_BR.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_pt_BR.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. -FormatFailed = Ocorreu um erro interno ao formatar a mensagem a seguir:\n +# General errors +BadMessageKey = JAXP09000001: N\u00E3o foi poss\u00EDvel encontrar a mensagem de erro correspondente \u00E0 chave da mensagem. +FormatFailed = JAXP09000002: Ocorreu um erro interno ao formatar a mensagem a seguir:\n +OtherError = JAXP09000003: Erro inesperado. -#invalid catalog file -InvalidCatalog = O elemento de documento de um cat\u00E1logo deve ser o cat\u00E1logo. -InvalidEntryType = O tipo de entrada "{0}" n\u00E3o \u00E9 v\u00E1lido. -CircularReference = A refer\u00EAncia circular n\u00E3o \u00E9 permitida: ''{0}''. +# Implementation restriction +CircularReference = JAXP09010001: A refer\u00EAncia circular n\u00E3o \u00E9 permitida: ''{0}''. + +# Input or configuration errors +InvalidCatalog = JAXP09020001: O elemento de documento de um cat\u00E1logo deve ser o cat\u00E1logo. +InvalidEntryType = JAXP09020002: O tipo de entrada "{0}" n\u00E3o \u00E9 v\u00E1lido. +UriNotAbsolute = JAXP09020003: O URI especificado ''{0}'' n\u00E3o \u00E9 absoluto. +UriNotValidUrl = JAXP09020004: O URI especificado ''{0}'' n\u00E3o \u00E9 um URL v\u00E1lido. +InvalidArgument = JAXP09020005: O argumento especificado ''{0}'' (distingue mai\u00FAsculas de min\u00FAsculas) para ''{1}'' n\u00E3o \u00E9 v\u00E1lido. +NullArgument = JAXP09020006: O argumento ''{0}'' n\u00E3o pode ser nulo. +InvalidPath = JAXP09020007: O caminho ''{0}'' \u00E9 inv\u00E1lido. + + +# Parsing errors +ParserConf = JAXP09030001: Erro inesperado ao configurar um parser SAX. +ParsingFailed = JAXP09030002: Falha ao fazer parsing do arquivo de cat\u00E1logo. +NoCatalogFound = JAXP09030003: Nenhum Cat\u00E1logo foi especificado. + + +# Resolving errors +NoMatchFound = JAXP09040001: Nenhuma correspond\u00EAncia foi encontrada para publicId ''{0}'' e systemId ''{1}''. +NoMatchURIFound = JAXP09040002: Nenhuma correspond\u00EAncia foi encontrada para href ''{0}'' e base ''{1}''. +FailedCreatingURI = JAXP09040003: N\u00E3o \u00E9 poss\u00EDvel construir o URI usando href ''{0}'' e base ''{1}''. -#errors -InvalidArgument = O argumento especificado ''{0}'' (distingue mai\u00FAsculas de min\u00FAsculas) para ''{1}'' n\u00E3o \u00E9 v\u00E1lido. -NullArgument = O argumento ''{0}'' n\u00E3o pode ser nulo. -InvalidPath = O caminho ''{0}'' \u00E9 inv\u00E1lido. -ParserConf = Erro inesperado ao configurar um parser SAX. -ParsingFailed = Falha ao fazer parsing do arquivo de cat\u00E1logo. -NoCatalogFound = Nenhum arquivo do Cat\u00E1logo foi especificado. -NoMatchFound = Nenhuma correspond\u00EAncia foi encontrada para publicId ''{0}'' e systemId ''{1}''. -NoMatchURIFound = Nenhuma correspond\u00EAncia foi encontrada para href ''{0}'' e base ''{1}''. -FailedCreatingURI = N\u00E3o \u00E9 poss\u00EDvel construir o URI usando href ''{0}'' e base ''{1}''. -OtherError = Erro inesperado. diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_sv.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_sv.properties index 6f52f5e5125..afd29faa1ee 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_sv.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_sv.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = Hittar inte felmeddelandet som motsvarar meddelandenyckeln. -FormatFailed = Ett internt fel intr\u00E4ffade vid formatering av f\u00F6ljande meddelande:\n +# General errors +BadMessageKey = JAXP09000001: Det felmeddelande som motsvarar meddelandenyckeln kan inte hittas. +FormatFailed = JAXP09000002: Ett internt fel intr\u00E4ffade vid formatering av f\u00F6ljande meddelande:\n +OtherError = JAXP09000003: Ov\u00E4ntat fel. -#invalid catalog file -InvalidCatalog = Dokumentelementet f\u00F6r en katalog m\u00E5ste vara "catalog". -InvalidEntryType = Posttypen ''{0}'' \u00E4r inte giltig. -CircularReference = Cirkul\u00E4r referens \u00E4r inte till\u00E5ten: ''{0}''. +# Implementation restriction +CircularReference = JAXP09010001: Cirkul\u00E4r referens \u00E4r inte till\u00E5ten: ''{0}''. + +# Input or configuration errors +InvalidCatalog = JAXP09020001: Dokumentelementet f\u00F6r en katalog m\u00E5ste vara "catalog". +InvalidEntryType = JAXP09020002: Posttypen ''{0}'' \u00E4r inte giltig. +UriNotAbsolute = JAXP09020003: Den angivna URI:n, ''{0}'', \u00E4r inte absolut. +UriNotValidUrl = JAXP09020004: Den angivna URI:n, ''{0}'', \u00E4r inte en giltig URL. +InvalidArgument = JAXP09020005: Det angivna argumentet, ''{0}'' (skiftl\u00E4gesk\u00E4nsligt), f\u00F6r ''{1}'' \u00E4r inte giltigt. +NullArgument = JAXP09020006: Argumentet ''{0}'' kan inte vara null. +InvalidPath = JAXP09020007: S\u00F6kv\u00E4gen ''{0}'' \u00E4r ogiltig. + + +# Parsing errors +ParserConf = JAXP09030001: Ov\u00E4ntat fel vid konfiguration av en SAX-parser. +ParsingFailed = JAXP09030002: Kunde inte tolka katalogfilen. +NoCatalogFound = JAXP09030003: Ingen katalog har angetts. + + +# Resolving errors +NoMatchFound = JAXP09040001: Ingen matchning hittades f\u00F6r publicId = ''{0}'' och systemId = ''{1}''. +NoMatchURIFound = JAXP09040002: Ingen matchning hittades f\u00F6r href = ''{0}'' och bas = ''{1}''. +FailedCreatingURI = JAXP09040003: Kan inte skapa URI med href = ''{0}'' och bas = ''{1}''. -#errors -InvalidArgument = Det angivna argumentet, ''{0}'' (skiftl\u00E4gesk\u00E4nsligt), f\u00F6r ''{1}'' \u00E4r inte giltigt. -NullArgument = Argumentet ''{0}'' kan inte vara null. -InvalidPath = S\u00F6kv\u00E4gen ''{0}'' \u00E4r ogiltig. -ParserConf = Ov\u00E4ntat fel vid konfiguration av en SAX-parser. -ParsingFailed = Kunde inte tolka katalogfilen. -NoCatalogFound = Ingen katalog har angetts. -NoMatchFound = Ingen matchning hittades f\u00F6r publicId = ''{0}'' och systemId = ''{1}''. -NoMatchURIFound = Ingen matchning hittades f\u00F6r href = ''{0}'' och bas = ''{1}''. -FailedCreatingURI = Kan inte skapa URI med href = ''{0}'' och bas = ''{1}''. -OtherError = Ov\u00E4ntat fel. diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_zh_CN.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_zh_CN.properties index c91492239d0..09b9122d4ba 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_zh_CN.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_zh_CN.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 -FormatFailed = \u8BBE\u7F6E\u4EE5\u4E0B\u6D88\u606F\u7684\u683C\u5F0F\u65F6\u51FA\u73B0\u5185\u90E8\u9519\u8BEF:\n +# General errors +BadMessageKey = JAXP09000001: \u627E\u4E0D\u5230\u4E0E\u6D88\u606F\u5173\u952E\u5B57\u5BF9\u5E94\u7684\u9519\u8BEF\u6D88\u606F\u3002 +FormatFailed = JAXP09000002: \u8BBE\u7F6E\u4EE5\u4E0B\u6D88\u606F\u7684\u683C\u5F0F\u65F6\u51FA\u73B0\u5185\u90E8\u9519\u8BEF:\n +OtherError = JAXP09000003: \u610F\u5916\u9519\u8BEF\u3002 -#invalid catalog file -InvalidCatalog = \u76EE\u5F55\u7684\u6587\u6863\u5143\u7D20\u5FC5\u987B\u662F\u76EE\u5F55\u3002 -InvalidEntryType = \u6761\u76EE\u7C7B\u578B ''{0}'' \u65E0\u6548\u3002 -CircularReference = \u4E0D\u5141\u8BB8\u5FAA\u73AF\u5F15\u7528: ''{0}''\u3002 +# Implementation restriction +CircularReference = JAXP09010001: \u4E0D\u5141\u8BB8\u5FAA\u73AF\u5F15\u7528: ''{0}''\u3002 + +# Input or configuration errors +InvalidCatalog = JAXP09020001: catalog \u7684\u6587\u6863\u5143\u7D20\u5FC5\u987B\u662F catalog\u3002 +InvalidEntryType = JAXP09020002: \u6761\u76EE\u7C7B\u578B ''{0}'' \u65E0\u6548\u3002 +UriNotAbsolute = JAXP09020003: \u6307\u5B9A\u7684 URI ''{0}'' \u4E0D\u662F\u7EDD\u5BF9\u7684\u3002 +UriNotValidUrl = JAXP09020004: \u6307\u5B9A\u7684 URI ''{0}'' \u4E0D\u662F\u6709\u6548\u7684 URL\u3002 +InvalidArgument = JAXP09020005: \u4E3A ''{1}'' \u6307\u5B9A\u7684\u53C2\u6570 ''{0}'' (\u533A\u5206\u5927\u5C0F\u5199) \u65E0\u6548\u3002 +NullArgument = JAXP09020006: \u53C2\u6570 ''{0}'' \u4E0D\u80FD\u4E3A\u7A7A\u503C\u3002 +InvalidPath = JAXP09020007: \u8DEF\u5F84 ''{0}'' \u65E0\u6548\u3002 + + +# Parsing errors +ParserConf = JAXP09030001: \u914D\u7F6E SAX \u89E3\u6790\u5668\u65F6\u51FA\u73B0\u610F\u5916\u9519\u8BEF\u3002 +ParsingFailed = JAXP09030002: \u65E0\u6CD5\u5BF9 catalog \u6587\u4EF6\u8FDB\u884C\u89E3\u6790\u3002 +NoCatalogFound = JAXP09030003: \u672A\u6307\u5B9A catalog\u3002 + + +# Resolving errors +NoMatchFound = JAXP09040001: \u5BF9\u4E8E publicId ''{0}'' \u548C systemId ''{1}'', \u672A\u627E\u5230\u5339\u914D\u9879\u3002 +NoMatchURIFound = JAXP09040002: \u5BF9\u4E8E href ''{0}'' \u548C base ''{1}'', \u672A\u627E\u5230\u5339\u914D\u9879\u3002 +FailedCreatingURI = JAXP09040003: \u65E0\u6CD5\u4F7F\u7528 href ''{0}'' \u548C base ''{1}'' \u6784\u9020 URI\u3002 -#errors -InvalidArgument = \u4E3A ''{1}'' \u6307\u5B9A\u7684\u53C2\u6570 ''{0}'' (\u533A\u5206\u5927\u5C0F\u5199) \u65E0\u6548\u3002 -NullArgument = \u53C2\u6570 ''{0}'' \u4E0D\u80FD\u4E3A\u7A7A\u503C\u3002 -InvalidPath = \u8DEF\u5F84 ''{0}'' \u65E0\u6548\u3002 -ParserConf = \u914D\u7F6E SAX \u89E3\u6790\u5668\u65F6\u51FA\u73B0\u610F\u5916\u9519\u8BEF\u3002 -ParsingFailed = \u65E0\u6CD5\u5BF9\u76EE\u5F55\u6587\u4EF6\u8FDB\u884C\u89E3\u6790\u3002 -NoCatalogFound = \u672A\u6307\u5B9A\u76EE\u5F55\u3002 -NoMatchFound = \u5BF9\u4E8E publicId ''{0}'' \u548C systemId ''{1}'', \u672A\u627E\u5230\u5339\u914D\u9879\u3002 -NoMatchURIFound = \u5BF9\u4E8E href ''{0}'' \u548C base ''{1}'', \u672A\u627E\u5230\u5339\u914D\u9879\u3002 -FailedCreatingURI = \u65E0\u6CD5\u4F7F\u7528 href ''{0}'' \u548C base ''{1}'' \u6784\u9020 URI\u3002 -OtherError = \u610F\u5916\u9519\u8BEF\u3002 diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_zh_TW.properties b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_zh_TW.properties index 49ea45d1c70..8181d04b3d6 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_zh_TW.properties +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/CatalogMessages_zh_TW.properties @@ -1,4 +1,4 @@ -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,32 @@ # or visit www.oracle.com if you need additional information or have any # questions. -# Messages for message reporting -BadMessageKey = \u627E\u4E0D\u5230\u5C0D\u61C9\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 -FormatFailed = \u683C\u5F0F\u5316\u4E0B\u5217\u8A0A\u606F\u6642\u767C\u751F\u5167\u90E8\u932F\u8AA4:\n +# General errors +BadMessageKey = JAXP09000001: \u627E\u4E0D\u5230\u76F8\u5C0D\u61C9\u65BC\u6B64\u8A0A\u606F\u7D22\u5F15\u9375\u7684\u932F\u8AA4\u8A0A\u606F\u3002 +FormatFailed = JAXP09000002: \u683C\u5F0F\u5316\u4E0B\u5217\u8A0A\u606F\u6642\u767C\u751F\u5167\u90E8\u932F\u8AA4:\n +OtherError = JAXP09000003: \u672A\u9810\u671F\u7684\u932F\u8AA4\u3002 -#invalid catalog file -InvalidCatalog = \u76EE\u9304\u7684\u6587\u4EF6\u5143\u7D20\u5FC5\u9808\u662F\u76EE\u9304\u3002 -InvalidEntryType = \u9805\u76EE\u985E\u578B ''{0}'' \u7121\u6548\u3002 -CircularReference = \u4E0D\u5141\u8A31\u5FAA\u74B0\u53C3\u7167: ''{0}''\u3002 +# Implementation restriction +CircularReference = JAXP09010001: \u4E0D\u5141\u8A31\u5FAA\u74B0\u53C3\u7167: ''{0}''\u3002 + +# Input or configuration errors +InvalidCatalog = JAXP09020001: Catalog \u7684\u6587\u4EF6\u5143\u7D20\u5FC5\u9808\u662F Catalog\u3002 +InvalidEntryType = JAXP09020002: \u9805\u76EE\u985E\u578B ''{0}'' \u7121\u6548\u3002 +UriNotAbsolute = JAXP09020003: \u6307\u5B9A\u7684 URI ''{0}'' \u4E0D\u662F\u7D55\u5C0D\u8DEF\u5F91\u3002 +UriNotValidUrl = JAXP09020004: \u6307\u5B9A\u7684 URI ''{0}'' \u4E0D\u662F\u6709\u6548\u7684 URL\u3002 +InvalidArgument = JAXP09020005: \u70BA ''{1}'' \u6307\u5B9A\u7684\u5F15\u6578 ''{0}'' (\u6709\u5927\u5C0F\u5BEB\u4E4B\u5206) \u7121\u6548\u3002 +NullArgument = JAXP09020006: \u5F15\u6578''{0}'' \u4E0D\u53EF\u70BA\u7A7A\u503C\u3002 +InvalidPath = JAXP09020007: \u8DEF\u5F91 ''{0}'' \u7121\u6548\u3002 + + +# Parsing errors +ParserConf = JAXP09030001: \u8A2D\u5B9A SAX \u5256\u6790\u5668\u6642\u767C\u751F\u672A\u9810\u671F\u7684\u932F\u8AA4\u3002 +ParsingFailed = JAXP09030002: \u7121\u6CD5\u5256\u6790 Catalog \u6A94\u6848\u3002 +NoCatalogFound = JAXP09030003: \u672A\u6307\u5B9A Catalog\u3002 + + +# Resolving errors +NoMatchFound = JAXP09040001: \u627E\u4E0D\u5230\u7B26\u5408 publicId ''{0}'' \u548C systemId ''{1}'' \u7684\u9805\u76EE\u3002 +NoMatchURIFound = JAXP09040002: \u627E\u4E0D\u5230\u7B26\u5408 href ''{0}'' \u548C\u57FA\u790E ''{1}'' \u7684\u9805\u76EE\u3002 +FailedCreatingURI = JAXP09040003: \u7121\u6CD5\u4F7F\u7528 href ''{0}'' \u548C\u57FA\u790E ''{1}'' \u5EFA\u69CB URI\u3002 -#errors -InvalidArgument = ''{1}'' \u7684\u6307\u5B9A\u5F15\u6578 ''{0}'' (\u6709\u5927\u5C0F\u5BEB\u4E4B\u5206) \u7121\u6548\u3002 -NullArgument = \u5F15\u6578''{0}'' \u4E0D\u53EF\u70BA\u7A7A\u503C\u3002 -InvalidPath = \u8DEF\u5F91 ''{0}'' \u7121\u6548\u3002 -ParserConf = \u8A2D\u5B9A SAX \u5256\u6790\u5668\u6642\u767C\u751F\u672A\u9810\u671F\u7684\u932F\u8AA4\u3002 -ParsingFailed = \u7121\u6CD5\u5256\u6790\u76EE\u9304\u6A94\u6848\u3002 -NoCatalogFound = \u672A\u6307\u5B9A\u4EFB\u4F55\u76EE\u9304\u3002 -NoMatchFound = \u627E\u4E0D\u5230\u76F8\u7B26\u7684 publicId ''{0}'' \u548C systemId ''{1}''\u3002 -NoMatchURIFound = \u627E\u4E0D\u5230\u76F8\u7B26\u7684 href ''{0}'' \u548C\u57FA\u790E ''{1}''\u3002 -FailedCreatingURI = \u7121\u6CD5\u4F7F\u7528 href ''{0}'' \u548C\u57FA\u790E ''{1}'' \u5EFA\u69CB URI\u3002 -OtherError = \u672A\u9810\u671F\u7684\u932F\u8AA4\u3002 diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/GroupEntry.java b/jaxp/src/java.xml/share/classes/javax/xml/catalog/GroupEntry.java index b0dd80c733f..3f52a7bd8f6 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/GroupEntry.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/GroupEntry.java @@ -135,7 +135,8 @@ class GroupEntry extends BaseEntry { /** * Constructs a GroupEntry * - * @param type The type of the entry + * @param type the type of the entry + * @param parent the parent Catalog */ public GroupEntry(CatalogEntryType type, CatalogImpl parent) { super(type); @@ -165,9 +166,9 @@ class GroupEntry extends BaseEntry { } /** * Constructs a group entry. - * @param catalog The catalog this GroupEntry belongs - * @param base The baseURI attribute - * @param attributes The attributes + * @param catalog the catalog this GroupEntry belongs to + * @param base the baseURI attribute + * @param attributes the attributes */ public GroupEntry(CatalogImpl catalog, String base, String... attributes) { super(CatalogEntryType.GROUP, base); @@ -175,6 +176,15 @@ class GroupEntry extends BaseEntry { this.catalog = catalog; } + /** + * Sets the catalog for this GroupEntry. + * + * @param catalog the catalog this GroupEntry belongs to + */ + void setCatalog(CatalogImpl catalog) { + this.catalog = catalog; + } + /** * Adds an entry. * @@ -382,10 +392,9 @@ class GroupEntry extends BaseEntry { /** * Matches delegatePublic or delegateSystem against the specified id * - * @param isSystem The flag to indicate whether the delegate is system or - * public - * @param id The system or public id to be matched - * @return The URI string if a mapping is found, or null otherwise. + * @param type the type of the Catalog entry + * @param id the system or public id to be matched + * @return the URI string if a mapping is found, or null otherwise. */ private String matchDelegate(CatalogEntryType type, String id) { String match = null; @@ -412,7 +421,7 @@ class GroupEntry extends BaseEntry { //Check delegate Catalogs if (catalogId != null) { - Catalog delegateCatalog = loadCatalog(catalogId); + Catalog delegateCatalog = loadDelegateCatalog(catalog, catalogId); if (delegateCatalog != null) { if (type == CatalogEntryType.DELEGATESYSTEM) { @@ -430,30 +439,34 @@ class GroupEntry extends BaseEntry { /** * Loads all delegate catalogs. + * + * @param parent the parent catalog of the delegate catalogs */ - void loadDelegateCatalogs() { + void loadDelegateCatalogs(CatalogImpl parent) { entries.stream() .filter((entry) -> (entry.type == CatalogEntryType.DELEGATESYSTEM || entry.type == CatalogEntryType.DELEGATEPUBLIC || entry.type == CatalogEntryType.DELEGATEURI)) .map((entry) -> (AltCatalog)entry) .forEach((altCatalog) -> { - loadCatalog(altCatalog.getCatalogURI()); + loadDelegateCatalog(parent, altCatalog.getCatalogURI()); }); } /** * Loads a delegate catalog by the catalogId specified. - * @param catalogId the catalog Id + * + * @param parent the parent catalog of the delegate catalog + * @param catalogURI the URI to the catalog */ - Catalog loadCatalog(URI catalogURI) { + Catalog loadDelegateCatalog(CatalogImpl parent, URI catalogURI) { CatalogImpl delegateCatalog = null; if (catalogURI != null) { String catalogId = catalogURI.toASCIIString(); - delegateCatalog = getLoadedCatalog(catalogId); - if (delegateCatalog == null) { - if (verifyCatalogFile(catalogURI)) { - delegateCatalog = new CatalogImpl(catalog, features, catalogURI); + if (verifyCatalogFile(parent, catalogURI)) { + delegateCatalog = getLoadedCatalog(catalogId); + if (delegateCatalog == null) { + delegateCatalog = new CatalogImpl(parent, features, catalogURI); delegateCatalog.load(); delegateCatalogs.put(catalogId, delegateCatalog); } @@ -473,7 +486,7 @@ class GroupEntry extends BaseEntry { CatalogImpl getLoadedCatalog(String catalogId) { CatalogImpl c = null; - //checl delegate Catalogs + //check delegate Catalogs c = delegateCatalogs.get(catalogId); if (c == null) { //check other loaded Catalogs @@ -492,11 +505,12 @@ class GroupEntry extends BaseEntry { * Verifies that the catalog represented by the catalogId has not been * searched or is not circularly referenced. * - * @param catalogId The URI to a catalog + * @param parent the parent of the catalog to be loaded + * @param catalogURI the URI to the catalog * @throws CatalogException if circular reference is found. * @return true if the catalogId passed verification, false otherwise */ - final boolean verifyCatalogFile(URI catalogURI) { + final boolean verifyCatalogFile(CatalogImpl parent, URI catalogURI) { if (catalogURI == null) { return false; } @@ -508,7 +522,7 @@ class GroupEntry extends BaseEntry { } String catalogId = catalogURI.toASCIIString(); - if (catalogsSearched.contains(catalogId) || isCircular(catalogId)) { + if (catalogsSearched.contains(catalogId) || isCircular(parent, catalogId)) { CatalogMessages.reportRunTimeError(CatalogMessages.ERR_CIRCULAR_REFERENCE, new Object[]{CatalogMessages.sanitize(catalogId)}); } @@ -518,10 +532,13 @@ class GroupEntry extends BaseEntry { /** * Checks whether the catalog is circularly referenced + * + * @param parent the parent of the catalog to be loaded * @param systemId the system identifier of the catalog to be loaded * @return true if is circular, false otherwise */ - boolean isCircular(String systemId) { + boolean isCircular(CatalogImpl parent, String systemId) { + // first, check the parent of the catalog to be loaded if (parent == null) { return false; } @@ -530,6 +547,7 @@ class GroupEntry extends BaseEntry { return true; } - return parent.isCircular(systemId); + // next, check parent's parent + return parent.isCircular(parent.parent, systemId); } } diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/catalog/package-info.java new file mode 100644 index 00000000000..b727bca77ef --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/catalog/package-info.java @@ -0,0 +1,71 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * + * Provides the classes for implementing + * + * XML Catalogs OASIS Standard V1.1, 7 October 2005. + * + *

    + * The Catalog API defines a standard solution for resolving external resources + * referenced by XML documents. It is fully supported by the XML Processors + * allowing application developers to configure a catalog through an XML processor + * or system property or the jaxp.properties file to take advantage of the feature. + *

    + * The XML Catalog API defines the following interfaces: + *

      + *
    • {@link Catalog} -- The {@link Catalog} interface represents an entity + * catalog as defined by the Catalog standard. A {@link Catalog} object + * is immutable. Once created, it can be used to find matches in a + * {@code system}, {@code public} or {@code uri} entry. + * A custom resolver implementation may find it useful for locating local + * resources through a catalog. + *
    • + *
    • {@link CatalogFeatures} -- The {@link CatalogFeatures} class holds all + * of the features and properties the Catalog API supports, including + * {@code javax.xml.catalog.files}, {@code javax.xml.catalog.defer}, + * {@code javax.xml.catalog.prefer}, and {@code javax.xml.catalog.resolve}. + *
    • + *
    • {@link CatalogManager} -- The {@link CatalogManager} class manages the + * creation of XML catalogs and catalog resolvers. + *
    • + *
    • {@link CatalogResolver} -- The {@link CatalogResolver} class is a + * {@code Catalog} resolver that implements {@link org.xml.sax.EntityResolver}, + * {@link javax.xml.stream.XMLResolver}, {@link org.w3c.dom.ls.LSResourceResolver}, + * and {@link javax.xml.transform.URIResolver}, and resolves external + * references using catalogs. + *
    • + *
    + *

    + * Unless otherwise noted, passing a null argument to + * a constructor or method in any class or interface in this package will + * cause a {@code NullPointerException} to be thrown. + * + * @since 9 + * + */ + +package javax.xml.catalog; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/catalog/package.html b/jaxp/src/java.xml/share/classes/javax/xml/catalog/package.html deleted file mode 100644 index 8e6e42836bf..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/catalog/package.html +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - - - Provides the classes for implementing - - XML Catalogs OASIS Standard V1.1, 7 October 2005. - -

    - Unless otherwise noted, passing a null argument to - a constructor or method in any class or interface in this package will - cause a NullPointerException to be thrown. -

    - -@since 9 - - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/datatype/DatatypeFactory.java b/jaxp/src/java.xml/share/classes/javax/xml/datatype/DatatypeFactory.java index a53f93df2ee..ebd600eb196 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/datatype/DatatypeFactory.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/datatype/DatatypeFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -774,15 +774,11 @@ public abstract class DatatypeFactory { /** * Create an {@code XMLGregorianCalendar} from a {@link GregorianCalendar}. * - *
    Processes with Catalog Support
    Process
    + *
    + * * * - * - * - * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/datatype/Duration.java b/jaxp/src/java.xml/share/classes/javax/xml/datatype/Duration.java index 90f016edfed..1caf4508a48 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/datatype/Duration.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/datatype/Duration.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -120,26 +120,22 @@ public abstract class Duration { * maps to. Type is computed based on fields that are set, * i.e. {@link #isSet(DatatypeConstants.Field field)} == {@code true}. * - *
    Field by Field Conversion from + * {@link GregorianCalendar} to an {@link XMLGregorianCalendar}
    - * Field by Field Conversion from - * {@link GregorianCalendar} to an {@link XMLGregorianCalendar} - *
    {@code java.util.GregorianCalendar} field{@code javax.xml.datatype.XMLGregorianCalendar} field
    + *
    + * * * - * + * + * + * + * + * + * + * * * * * - * - * - * - * - * - * - * - * - * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/datatype/XMLGregorianCalendar.java b/jaxp/src/java.xml/share/classes/javax/xml/datatype/XMLGregorianCalendar.java index 82ea2e17329..cc25c17a3e4 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/datatype/XMLGregorianCalendar.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/datatype/XMLGregorianCalendar.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -53,25 +53,21 @@ import java.util.GregorianCalendar; * W3C XML Schema 1.0 Part 2, Appendix D, * ISO 8601 Date and Time Formats. * - * - *
    Required fields for XML Schema 1.0 Date/Time Datatypes.
    + * (timezone is optional for all date/time datatypes)
    - * Required fields for XML Schema 1.0 Date/Time Datatypes.
    - * (timezone is optional for all date/time datatypes) - *
    Datatypeyearmonthdayhourminutesecond
    Datatypeyearmonthdayhourminutesecond
    {@link DatatypeConstants#DURATION}XX
    + * + *
    + * * * - * - * - * - * - * * * * * + * + * * - * + * * @@ -89,12 +85,12 @@ import java.util.GregorianCalendar; * * * - * + * * * * * - * + * * * * * - * + * * * * * - * + * * * * * - * + * * * * - * + * * *
    Date/Time Datatype Field Mapping Between XML Schema 1.0 and Java Representation
    - * Date/Time Datatype Field Mapping Between XML Schema 1.0 and Java Representation - *
    XML Schema 1.0
    * datatype
    * field
    Related
    XMLGregorianCalendar
    Accessor(s)
    Value Range
    yearyear {@link #getYear()} + {@link #getEon()} or
    * {@link #getEonAndYear} *
    monthmonth {@link #getMonth()} 1 to 12 or {@link DatatypeConstants#FIELD_UNDEFINED}
    dayday {@link #getDay()} Independent of month, max range is 1 to 31 or {@link DatatypeConstants#FIELD_UNDEFINED}.
    * The normative value constraint stated relative to month @@ -102,7 +98,7 @@ import java.util.GregorianCalendar; *
    hourhour{@link #getHour()} * 0 to 23 or {@link DatatypeConstants#FIELD_UNDEFINED}. @@ -114,12 +110,12 @@ import java.util.GregorianCalendar; *
    minuteminute {@link #getMinute()} 0 to 59 or {@link DatatypeConstants#FIELD_UNDEFINED}
    secondsecond * {@link #getSecond()} + {@link #getMillisecond()}/1000 or
    * {@link #getSecond()} + {@link #getFractionalSecond()} @@ -135,7 +131,7 @@ import java.util.GregorianCalendar; *
    timezonetimezone {@link #getTimezone()} Number of minutes or {@link DatatypeConstants#FIELD_UNDEFINED}. * Value range from -14 hours (-14 * 60 minutes) to 14 hours (14 * 60 minutes). @@ -748,26 +744,22 @@ public abstract class XMLGregorianCalendar * Return the name of the XML Schema date/time type that this instance * maps to. Type is computed based on fields that are set. * - * + *
    + * * * - * + * + * + * + * + * + * + * * * * * - * - * - * - * - * - * - * - * - * * * * @@ -911,21 +903,17 @@ public abstract class XMLGregorianCalendar * instance, see * {@link #toGregorianCalendar(TimeZone, Locale, XMLGregorianCalendar)}. * - *
    Required fields for XML Schema 1.0 Date/Time Datatypes.
    + * (timezone is optional for all date/time datatypes)
    - * Required fields for XML Schema 1.0 Date/Time Datatypes.
    - * (timezone is optional for all date/time datatypes) - *
    Datatypeyearmonthdayhourminutesecond
    Datatypeyearmonthdayhourminutesecond
    {@link DatatypeConstants#DATETIME}XX
    + *
    + * * * - * + * + * * * * * - * - * - * - * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/datatype/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/datatype/package-info.java new file mode 100644 index 00000000000..9f943d7f653 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/datatype/package-info.java @@ -0,0 +1,172 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * + *

    + * Defines XML/Java Type Mappings. + * + *

    + * This API provides XML/Java type mappings. + * + *

    + * The following XML standards apply: + * + *

    + * + *
    + * + *
    Field by Field Conversion from this class to + * {@code java.util.GregorianCalendar}
    - * Field by Field Conversion from this class to - * {@code java.util.GregorianCalendar} - * {@code java.util.GregorianCalendar} field{@code javax.xml.datatype.XMLGregorianCalendar} field
    {@code java.util.GregorianCalendar} field{@code javax.xml.datatype.XMLGregorianCalendar} field
    {@code ERA}{@link #getEonAndYear()}{@code .signum() < 0 ? GregorianCalendar.BC : GregorianCalendar.AD}
    + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
    W3C XML Schema/Java Type Mappings
    W3C XML Schema Data TypeJava Data Type
    xs:date{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:dateTime{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:duration{@link javax.xml.datatype.Duration}
    xs:gDay{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:gMonth {@link javax.xml.datatype.XMLGregorianCalendar}
    xs:gMonthDay{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:gYear{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:gYearMonth{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:time{@link javax.xml.datatype.XMLGregorianCalendar}
    + * + *
    + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
    XQuery and XPath/Java Type Mappings
    XQuery 1.0 and XPath 2.0 Data ModelJava Data Type
    xdt:dayTimeDuration{@link javax.xml.datatype.Duration}
    xdt:yearMonthDuration{@link javax.xml.datatype.Duration}
    + * + *
    + * + *

    + * W3C XML Schema data types that have a "natural" mapping to Java types are defined by + * JSR 31: Java™ Architecture for XML Binding (JAXB) Specification, Binding XML Schema to Java Representations. + * JAXB defined mappings for XML Schema built-in data types include: + * + *

      + *
    • xs:anySimpleType
    • + *
    • xs:base64Binary
    • + *
    • xs:boolean
    • + *
    • xs:byte
    • + *
    • xs:decimal
    • + *
    • xs:double
    • + *
    • xs:float
    • + *
    • xs:hexBinary
    • + *
    • xs:int
    • + *
    • xs:integer
    • + *
    • xs:long
    • + *
    • xs:QName
    • + *
    • xs:short
    • + *
    • xs:string
    • + *
    • xs:unsignedByte
    • + *
    • xs:unsignedInt
    • + *
    • xs:unsignedShort
    • + *
    + * + *
    + * + * + * + *
    + * @since 1.5 + */ + +package javax.xml.datatype; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/datatype/package.html b/jaxp/src/java.xml/share/classes/javax/xml/datatype/package.html deleted file mode 100644 index de065acc664..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/datatype/package.html +++ /dev/null @@ -1,169 +0,0 @@ - - - - - - - - javax.xml.xpath - - - - - - - - - - -

    XML/Java Type Mappings.

    - -

    javax.xml.datatypeAPI provides XML/Java type mappings.

    - -

    The following XML standards apply:

    - - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    W3C XML Schema Data TypeJava Data Type
    xs:date{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:dateTime{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:duration{@link javax.xml.datatype.Duration}
    xs:gDay{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:gMonth {@link javax.xml.datatype.XMLGregorianCalendar}
    xs:gMonthDay{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:gYear{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:gYearMonth{@link javax.xml.datatype.XMLGregorianCalendar}
    xs:time{@link javax.xml.datatype.XMLGregorianCalendar}
    - -
    - - - - - - - - - - - - - - - - - - - - -
    XQuery 1.0 and XPath 2.0 Data ModelJava Data Type
    xdt:dayTimeDuration{@link javax.xml.datatype.Duration}
    xdt:yearMonthDuration{@link javax.xml.datatype.Duration}
    - -
    - -

    - W3C XML Schema data types that have a "natural" mapping to Java types are defined by - JSR 31: Java™ Architecture for XML Binding (JAXB) Specification, Binding XML Schema to Java Representations. - JAXB defined mappings for XML Schema built-in data types include: -

    -
      -
    • xs:anySimpleType
    • -
    • xs:base64Binary
    • -
    • xs:boolean
    • -
    • xs:byte
    • -
    • xs:decimal
    • -
    • xs:double
    • -
    • xs:float
    • -
    • xs:hexBinary
    • -
    • xs:int
    • -
    • xs:integer
    • -
    • xs:long
    • -
    • xs:QName
    • -
    • xs:short
    • -
    • xs:string
    • -
    • xs:unsignedByte
    • -
    • xs:unsignedInt
    • -
    • xs:unsignedShort
    • -
    - -
    - - - - -
    - - - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/namespace/NamespaceContext.java b/jaxp/src/java.xml/share/classes/javax/xml/namespace/NamespaceContext.java index 09e46e7dfbf..1ad999acb14 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/namespace/NamespaceContext.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/namespace/NamespaceContext.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -88,17 +88,12 @@ public interface NamespaceContext { * table describes the returned Namespace URI value for all * possible prefix values: * - * + *
    + * * * - * - * - * - * - * + * + * * * * @@ -158,15 +153,10 @@ public interface NamespaceContext { * table describes the returned prefix value for all Namespace URI * values: * - *
    Return value for specified prefixes
    - * {@code getNamespaceURI(prefix)} - * return value for specified prefixes - *
    prefix parameterNamespace URI return valueprefix parameterNamespace URI return value
    + *
    + * * * - * - * - * * * * @@ -230,14 +220,10 @@ public interface NamespaceContext { * table describes the returned prefixes value for all Namespace * URI values: * - *
    Return value for specified Namespace URIs
    - * {@code getPrefix(namespaceURI)} return value for - * specified Namespace URIs - *
    Namespace URI parameterprefix value returned
    + *
    + * * * - * - * - * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/namespace/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/namespace/package-info.java new file mode 100644 index 00000000000..bc34407349e --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/namespace/package-info.java @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * + *

    + * Defines XML Namespace processing. + * + *

    + * The following XML standards apply: + * + *

    + * + * @since 1.5 + */ + +package javax.xml.namespace; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/namespace/package.html b/jaxp/src/java.xml/share/classes/javax/xml/namespace/package.html deleted file mode 100644 index b5b02ede5be..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/namespace/package.html +++ /dev/null @@ -1,54 +0,0 @@ - - - - - - - - - javax.xml.namespace - - - - - - - -

    XML Namespace processing.

    - -

    The following XML standards apply:

    - - - - diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/doclet/taglet/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/package-info.java similarity index 75% rename from langtools/src/jdk.javadoc/share/classes/jdk/javadoc/doclet/taglet/package-info.java rename to jaxp/src/java.xml/share/classes/javax/xml/package-info.java index 066f5e61472..b267667bb79 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/doclet/taglet/package-info.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/package-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,14 +24,11 @@ */ /** - * The Taglet API provides a way to declare custom tags that can be - * used by the standard doclet. * - *

    - * Note: The declarations in this package supersede those - * in the older package {@code com.sun.tools.doclets}. - *

    + * Defines constants for XML processing. + * + * @since 1.5 * - * @since 9 */ -package jdk.javadoc.doclet.taglet; + +package javax.xml; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/parsers/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/parsers/package-info.java new file mode 100644 index 00000000000..251b97d7595 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/parsers/package-info.java @@ -0,0 +1,36 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + *

    + * Provides the classes for processing XML documents with a SAX (Simple API for XML) + * parser or a DOM (Document Object Model) Document builder. The JAXP Plugability + * layer allows an application programmer to specify an implementation and + * configure where to locate it. + * + * @since 1.4 + */ + +package javax.xml.parsers; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/parsers/package.html b/jaxp/src/java.xml/share/classes/javax/xml/parsers/package.html deleted file mode 100644 index 52092114cd4..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/parsers/package.html +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - javax.xml.parsers - - - - - -

    - Provides classes allowing the processing of XML documents. Two types - of plugable parsers are supported: -

    -
      -
    • SAX (Simple API for XML)
    • -
    • DOM (Document Object Model)
    • -
    - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/FactoryFinder.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/FactoryFinder.java index 2496e208705..c5b05ffe8ff 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/stream/FactoryFinder.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/FactoryFinder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -270,7 +270,7 @@ class FactoryFinder { "Failed to read factoryId '" + factoryId + "'", se); } - // Try read $java.home/lib/stax.properties followed by + // Try read $java.home/conf/stax.properties followed by // $java.home/conf/jaxp.properties if former not present String configFile = null; try { @@ -278,7 +278,7 @@ class FactoryFinder { synchronized (cacheProps) { if (firstTime) { configFile = ss.getSystemProperty("java.home") + File.separator + - "lib" + File.separator + "stax.properties"; + "conf" + File.separator + "stax.properties"; final File fStax = new File(configFile); firstTime = false; if (ss.doesFileExist(fStax)) { diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLEventFactory.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLEventFactory.java index 9428a2ef0c4..82389cba0d2 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLEventFactory.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLEventFactory.java @@ -155,7 +155,7 @@ public abstract class XMLEventFactory { * #newFactory(java.lang.String, java.lang.ClassLoader)} * method defines no changes in behavior. */ - @Deprecated(since="7") + @Deprecated(since="1.7") public static XMLEventFactory newInstance(String factoryId, ClassLoader classLoader) throws FactoryConfigurationError { diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLEventWriter.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLEventWriter.java index e94feaec309..0df399bb5d0 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLEventWriter.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLEventWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -64,21 +64,17 @@ public interface XMLEventWriter extends XMLEventConsumer { * Add an event to the output stream * Adding a START_ELEMENT will open a new namespace scope that * will be closed when the corresponding END_ELEMENT is written. - *
    Return value for specified Namespace URIs
    {@code - * getPrefixes(namespaceURI)} return value for - * specified Namespace URIs
    Namespace URI parameterprefixes value returned
    + *
    + * * * - * - * - * - * - * * * * * * + * + * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLInputFactory.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLInputFactory.java index 717dee5a9a9..4a25f8fc33e 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLInputFactory.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLInputFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,22 +36,18 @@ import javax.xml.transform.Source; * Each property varies in the level of support required by each implementation. * The level of support required is described in the 'Required' column. * - *
    Required and optional fields for events added to the writer
    - * Required and optional fields for events added to the writer - *
    Event TypeRequired FieldsOptional FieldsRequired Behavior
    START_ELEMENT QName name
    + *
    + * * * - * - * - * - * - * * * * * * * + * + * * * * @@ -222,7 +218,7 @@ public abstract class XMLInputFactory { * java.util.ServiceConfigurationError service configuration error} or if * the implementation is not available or cannot be instantiated. */ - @Deprecated(since="7") + @Deprecated(since="1.7") public static XMLInputFactory newFactory() throws FactoryConfigurationError { @@ -244,7 +240,7 @@ public abstract class XMLInputFactory { * #newFactory(java.lang.String, java.lang.ClassLoader)} method * defines no changes in behavior. */ - @Deprecated(since="7") + @Deprecated(since="1.7") public static XMLInputFactory newInstance(String factoryId, ClassLoader classLoader) throws FactoryConfigurationError { diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLOutputFactory.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLOutputFactory.java index 50b6ba79c0a..0203273256c 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLOutputFactory.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLOutputFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,22 +36,18 @@ import javax.xml.transform.Result; * Each property varies in the level of support required by each implementation. * The level of support required is described in the 'Required' column. * - *
    Configuration Parameters
    - * Configuration parameters - *
    Property NameBehaviorReturn typeDefault ValueRequired
    javax.xml.stream.isValidatingTurns on/off implementation specific DTD validationBooleanFalseNo
    javax.xml.stream.isNamespaceAwareTurns on/off namespace processing for XML 1.0 supportBooleanTrueTrue (required) / False (optional)
    javax.xml.stream.isCoalescingRequires the processor to coalesce adjacent character dataBooleanFalseYes
    + *
    + * * * - * - * - * - * - * * * * * * * + * + * * * @@ -222,7 +218,7 @@ public abstract class XMLOutputFactory { * Use the new method {@link #newFactory(java.lang.String, * java.lang.ClassLoader)} instead. */ - @Deprecated(since="7") + @Deprecated(since="1.7") public static XMLInputFactory newInstance(String factoryId, ClassLoader classLoader) throws FactoryConfigurationError { diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLStreamReader.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLStreamReader.java index 23322b995db..06c44f9b532 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLStreamReader.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLStreamReader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -71,19 +71,15 @@ import javax.xml.namespace.QName; * If a method is called in an invalid state the method will throw a * java.lang.IllegalStateException. * - *
    Configuration Parameters
    - * Configuration parameters - *
    Property NameBehaviorReturn typeDefault ValueRequired
    javax.xml.stream.isRepairingNamespacesdefaults prefixes * on the output sideBooleanFalseYes
    + *
    + * * * - * - * - * - * - * * * * + * + * * * *
    Valid methods for each state
    - * Valid methods for each state - *
    Event TypeValid Methods
    All States getProperty(), hasNext(), require(), close(), diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLStreamWriter.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLStreamWriter.java index 6fc1722c9a0..1f0a3c34577 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLStreamWriter.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/XMLStreamWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -38,12 +38,10 @@ import javax.xml.namespace.NamespaceContext; * Each NAMESPACE * and ATTRIBUTE must be individually written. * - * + *
    + * * - * - * - * - * + * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/events/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/events/package-info.java new file mode 100644 index 00000000000..dd3b4da5b8e --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/events/package-info.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Defines event interfaces for the Streaming API for XML (StAX). + * + * @since 1.6 + */ + +package javax.xml.stream.events; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/package-info.java new file mode 100644 index 00000000000..9abed31ca51 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/package-info.java @@ -0,0 +1,51 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + *

    + * Defines interfaces and classes for the Streaming API for XML (StAX). + * + *

    + * StAX provides two basic functions: the cursor API allowing users to + * read and write XML efficiently, and the event iterator API promoting + * ease of use that is event based, easy to extend and pipeline. + * The event iterator API is intended to layer on top of the cursor API. + * + *

    + * The cursor API defines two interfaces: {@link XMLStreamReader} + * and {@link XMLStreamWriter}, while the event iterator API defines: + * {@link XMLEventReader} and {@link XMLEventWriter}. + * + *

    + * StAX supports plugability with {@link XMLInputFactory} and + * {@link XMLOutputFactory} that define how an implementation is + * located through a process as described in the {@link newFactory} + * method. + * + * + * @since 1.6 + */ + +package javax.xml.stream; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/stream/util/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/stream/util/package-info.java new file mode 100644 index 00000000000..074f9e0c208 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/stream/util/package-info.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides utility classes for the Streaming API for XML (StAX). + * + * @since 1.6 + */ + +package javax.xml.stream.util; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/dom/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/transform/dom/package-info.java new file mode 100644 index 00000000000..6a121ce46c1 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/transform/dom/package-info.java @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides DOM specific transformation classes. + *

    + * The {@link javax.xml.transform.dom.DOMSource} class allows the + * client of the implementation of this API to specify a DOM + * {@link org.w3c.dom.Node} as the source of the input tree. The model of + * how the Transformer deals with the DOM tree in terms of mismatches with the + * XSLT data model or + * other data models is beyond the scope of this document. Any of the nodes + * derived from {@link org.w3c.dom.Node} are legal input. + *

    + * The {@link javax.xml.transform.dom.DOMResult} class allows + * a {@link org.w3c.dom.Node} to be specified to which result DOM nodes will + * be appended. If an output node is not specified, the transformer will use + * {@link javax.xml.parsers.DocumentBuilder#newDocument} to create an + * output {@link org.w3c.dom.Document} node. If a node is specified, it + * should be one of the following: {@link org.w3c.dom.Document}, + * {@link org.w3c.dom.Element}, or + * {@link org.w3c.dom.DocumentFragment}. Specification of any other node + * type is implementation dependent and undefined by this API. If the result is a + * {@link org.w3c.dom.Document}, the output of the transformation must have + * a single element root to set as the document element. + *

    + * The {@link javax.xml.transform.dom.DOMLocator} node may be passed + * to {@link javax.xml.transform.TransformerException} objects, and + * retrieved by trying to cast the result of the + * {@link javax.xml.transform.TransformerException#getLocator()} method. + * The implementation has no responsibility to use a DOMLocator instead of a + * {@link javax.xml.transform.SourceLocator} (though line numbers and the + * like do not make much sense for a DOM), so the result of getLocator must always + * be tested with an instanceof. + * + * @since 1.5 + */ + +package javax.xml.transform.dom; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/dom/package.html b/jaxp/src/java.xml/share/classes/javax/xml/transform/dom/package.html deleted file mode 100644 index 09cb8123d50..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/transform/dom/package.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - - - - - - javax.xml.transform.dom - - - - - -

    This package implements DOM-specific transformation APIs.

    -

    The {@link javax.xml.transform.dom.DOMSource} class allows the -client of the implementation of this API to specify a DOM -{@link org.w3c.dom.Node} as the source of the input tree. The model of -how the Transformer deals with the DOM tree in terms of mismatches with the -XSLT data model or -other data models is beyond the scope of this document. Any of the nodes -derived from {@link org.w3c.dom.Node} are legal input.

    -

    The {@link javax.xml.transform.dom.DOMResult} class allows -a {@link org.w3c.dom.Node} to be specified to which result DOM nodes will -be appended. If an output node is not specified, the transformer will use -{@link javax.xml.parsers.DocumentBuilder#newDocument} to create an -output {@link org.w3c.dom.Document} node. If a node is specified, it -should be one of the following: {@link org.w3c.dom.Document}, -{@link org.w3c.dom.Element}, or -{@link org.w3c.dom.DocumentFragment}. Specification of any other node -type is implementation dependent and undefined by this API. If the result is a -{@link org.w3c.dom.Document}, the output of the transformation must have -a single element root to set as the document element.

    -

    The {@link javax.xml.transform.dom.DOMLocator} node may be passed -to {@link javax.xml.transform.TransformerException} objects, and -retrieved by trying to cast the result of the -{@link javax.xml.transform.TransformerException#getLocator()} method. -The implementation has no responsibility to use a DOMLocator instead of a -{@link javax.xml.transform.SourceLocator} (though line numbers and the -like do not make much sense for a DOM), so the result of getLocator must always -be tested with an instanceof.

    - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/transform/package-info.java new file mode 100644 index 00000000000..2afa0406642 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/transform/package-info.java @@ -0,0 +1,216 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Defines the generic APIs for processing transformation instructions, + * and performing a transformation from source to result. These interfaces have no + * dependencies on SAX or the DOM standard, and try to make as few assumptions as + * possible about the details of the source and result of a transformation. It + * achieves this by defining {@link javax.xml.transform.Source} and + * {@link javax.xml.transform.Result} interfaces. + * + *

    + * To provide concrete classes for the user, the API defines specializations + * of the interfaces found at the root level. These interfaces are found in + * {@link javax.xml.transform.sax}, {@link javax.xml.transform.dom}, + * {@link javax.xml.transform.stax}, and {@link javax.xml.transform.stream}. + * + * + *

    Creating Objects

    + * + *

    + * The API allows a concrete {@link javax.xml.transform.TransformerFactory} + * object to be created from the static function + * {@link javax.xml.transform.TransformerFactory#newInstance}. + * + * + *

    Specification of Inputs and Outputs

    + * + *

    + * This API defines two interface objects called {@link javax.xml.transform.Source} + * and {@link javax.xml.transform.Result}. In order to pass Source and Result + * objects to the interfaces, concrete classes must be used. The following concrete + * representations are defined for each of these objects: + * {@link javax.xml.transform.stream.StreamSource} and + * {@link javax.xml.transform.stream.StreamResult}, + * {@link javax.xml.transform.stax.StAXSource} and + * {@link javax.xml.transform.stax.StAXResult}, and + * {@link javax.xml.transform.sax.SAXSource} and + * {@link javax.xml.transform.sax.SAXResult}, and + * {@link javax.xml.transform.dom.DOMSource} and + * {@link javax.xml.transform.dom.DOMResult}. Each of these objects defines a + * FEATURE string (which is in the form of a URL), which can be passed into + * {@link javax.xml.transform.TransformerFactory#getFeature} to see if the given + * type of Source or Result object is supported. For instance, to test if a + * DOMSource and a StreamResult is supported, you can apply the following test. + * + *

    + * 
    + * TransformerFactory tfactory = TransformerFactory.newInstance();
    + * if (tfactory.getFeature(DOMSource.FEATURE) &&
    + *     tfactory.getFeature(StreamResult.FEATURE)) {
    + *     ...
    + * }
    + * 
    + * 
    + * + * + *

    + * Qualified Name Representation + *

    + * + *

    + * Namespaces present something + * of a problem area when dealing with XML objects. Qualified Names appear in XML + * markup as prefixed names. But the prefixes themselves do not hold identity. + * Rather, it is the URIs that they contextually map to that hold the identity. + * Therefore, when passing a Qualified Name like "xyz:foo" among Java programs, + * one must provide a means to map "xyz" to a namespace. + * + *

    + * One solution has been to create a "QName" object that holds the namespace URI, + * as well as the prefix and local name, but this is not always an optimal solution, + * as when, for example, you want to use unique strings as keys in a dictionary + * object. Not having a string representation also makes it difficult to specify + * a namespaced identity outside the context of an XML document. + * + *

    + * In order to pass namespaced values to transformations, for instance when setting + * a property or a parameter on a {@link javax.xml.transform.Transformer} object, + * this specification defines that a String "qname" object parameter be passed as + * two-part string, the namespace URI enclosed in curly braces ({}), followed by + * the local name. If the qname has a null URI, then the String object only + * contains the local name. An application can safely check for a non-null URI by + * testing to see if the first character of the name is a '{' character. + * + *

    + * For example, if a URI and local name were obtained from an element defined with + * <xyz:foo xmlns:xyz="http://xyz.foo.com/yada/baz.html"/>, then the + * Qualified Name would be "{http://xyz.foo.com/yada/baz.html}foo". Note that the + * prefix is lost. + * + * + *

    Result Tree Serialization

    + * + *

    + * Serialization of the result tree to a stream can be controlled with the + * {@link javax.xml.transform.Transformer#setOutputProperties} and the + * {@link javax.xml.transform.Transformer#setOutputProperty} methods. + * These properties only apply to stream results, they have no effect when + * the result is a DOM tree or SAX event stream. + * + *

    + * Strings that match the XSLT + * specification for xsl:output attributes can be referenced from the + * {@link javax.xml.transform.OutputKeys} class. Other strings can be + * specified as well. + * If the transformer does not recognize an output key, a + * {@link java.lang.IllegalArgumentException} is thrown, unless the key name + * is namespace qualified. Output key names + * that are namespace qualified are always allowed, although they may be + * ignored by some implementations. + * + *

    + * If all that is desired is the simple identity transformation of a + * source to a result, then {@link javax.xml.transform.TransformerFactory} + * provides a + * {@link javax.xml.transform.TransformerFactory#newTransformer()} method + * with no arguments. This method creates a Transformer that effectively copies + * the source to the result. This method may be used to create a DOM from SAX + * events or to create an XML or HTML stream from a DOM or SAX events. + * + *

    Exceptions and Error Reporting

    + * + *

    + * The transformation API throw three types of specialized exceptions. A + * {@link javax.xml.transform.TransformerFactoryConfigurationError} is parallel to + * the {@link javax.xml.parsers.FactoryConfigurationError}, and is thrown + * when a configuration problem with the TransformerFactory exists. This error + * will typically be thrown when the transformation factory class specified with + * the "javax.xml.transform.TransformerFactory" system property cannot be found or + * instantiated. + * + *

    + * A {@link javax.xml.transform.TransformerConfigurationException} + * may be thrown if for any reason a Transformer can not be created. A + * TransformerConfigurationException may be thrown if there is a syntax error in + * the transformation instructions, for example when + * {@link javax.xml.transform.TransformerFactory#newTransformer} is + * called. + * + *

    + * {@link javax.xml.transform.TransformerException} is a general + * exception that occurs during the course of a transformation. A transformer + * exception may wrap another exception, and if any of the + * {@link javax.xml.transform.TransformerException#printStackTrace()} + * methods are called on it, it will produce a list of stack dumps, starting from + * the most recent. The transformer exception also provides a + * {@link javax.xml.transform.SourceLocator} object which indicates where + * in the source tree or transformation instructions the error occurred. + * {@link javax.xml.transform.TransformerException#getMessageAndLocation()} + * may be called to get an error message with location info, and + * {@link javax.xml.transform.TransformerException#getLocationAsString()} + * may be called to get just the location string. + * + *

    + * Transformation warnings and errors are sent to an + * {@link javax.xml.transform.ErrorListener}, at which point the application may + * decide to report the error or warning, and may decide to throw an + * Exception for a non-fatal error. The ErrorListener + * may be set via {@link javax.xml.transform.TransformerFactory#setErrorListener} + * for reporting errors that have to do with syntax errors in the transformation + * instructions, or via {@link javax.xml.transform.Transformer#setErrorListener} + * to report errors that occur during the transformation. The ErrorListener + * on both objects will always be valid and non-null, whether set by + * the application or a default implementation provided by the processor. + * The default implementation provided by the processor will report all warnings + * and errors to System.err and does not throw any Exceptions. + * Applications are strongly encouraged to register and use + * ErrorListeners that insure proper behavior for warnings and + * errors. + * + * + *

    Resolution of URIs within a transformation

    + * + *

    + * The API provides a way for URIs referenced from within the stylesheet + * instructions or within the transformation to be resolved by the calling + * application. This can be done by creating a class that implements the + * {@link javax.xml.transform.URIResolver} interface, with its one method, + * {@link javax.xml.transform.URIResolver#resolve}, and use this class to + * set the URI resolution for the transformation instructions or transformation + * with {@link javax.xml.transform.TransformerFactory#setURIResolver} or + * {@link javax.xml.transform.Transformer#setURIResolver}. The + * URIResolver.resolve method takes two String arguments, the URI + * found in the stylesheet instructions or built as part of the transformation + * process, and the base URI against which the first argument will be made absolute + * if the absolute URI is required. + * The returned {@link javax.xml.transform.Source} object must be usable by + * the transformer, as specified in its implemented features. + * + * @since 1.5 + */ + +package javax.xml.transform; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/package.html b/jaxp/src/java.xml/share/classes/javax/xml/transform/package.html deleted file mode 100644 index 45c2d78faf4..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/transform/package.html +++ /dev/null @@ -1,233 +0,0 @@ - - - - - - - - - javax.xml.transform - - - - - - -

    This package defines the generic APIs for processing transformation -instructions, and performing a transformation from source to result. These -interfaces have no dependencies on SAX or the DOM standard, and try to make as -few assumptions as possible about the details of the source and result of a -transformation. It achieves this by defining -{@link javax.xml.transform.Source} and -{@link javax.xml.transform.Result} interfaces. -

    - -

    To define concrete classes for the user, the API defines specializations -of the interfaces found at the root level. These interfaces are found in -{@link javax.xml.transform.sax}, {@link javax.xml.transform.dom}, -and {@link javax.xml.transform.stream}. -

    - - -

    Creating Objects

    - -

    The API allows a concrete -{@link javax.xml.transform.TransformerFactory} object to be created from -the static function -{@link javax.xml.transform.TransformerFactory#newInstance}. -

    - - -

    Specification of Inputs and Outputs

    - -

    This API defines two interface objects called -{@link javax.xml.transform.Source} and -{@link javax.xml.transform.Result}. In order to pass Source and Result -objects to the interfaces, concrete classes must be used. -Three concrete representations are defined for each of these -objects: -{@link javax.xml.transform.stream.StreamSource} and -{@link javax.xml.transform.stream.StreamResult}, -{@link javax.xml.transform.sax.SAXSource} and -{@link javax.xml.transform.sax.SAXResult}, and -{@link javax.xml.transform.dom.DOMSource} and -{@link javax.xml.transform.dom.DOMResult}. Each of these objects defines -a FEATURE string (which is i the form of a URL), which can be passed into -{@link javax.xml.transform.TransformerFactory#getFeature} to see if the -given type of Source or Result object is supported. For instance, to test if a -DOMSource and a StreamResult is supported, you can apply the following -test. -

    - -
    -
    -TransformerFactory tfactory = TransformerFactory.newInstance();
    -if (tfactory.getFeature(DOMSource.FEATURE) && tfactory.getFeature(StreamResult.FEATURE)) {
    -...
    -}
    -
    -
    - - -

    -Qualified Name Representation -

    - -

    Namespaces -present something of a problem area when dealing with XML objects. Qualified -Names appear in XML markup as prefixed names. But the prefixes themselves do -not hold identity. Rather, it is the URIs that they contextually map to that -hold the identity. Therefore, when passing a Qualified Name like "xyz:foo" -among Java programs, one must provide a means to map "xyz" to a namespace. -

    - -

    One solution has been to create a "QName" object that holds the -namespace URI, as well as the prefix and local name, but this is not always an -optimal solution, as when, for example, you want to use unique strings as keys -in a dictionary object. Not having a string representation also makes it -difficult to specify a namespaced identity outside the context of an XML -document. -

    - -

    In order to pass namespaced values to transformations, -for -instance when setting a property or a parameter on a -{@link javax.xml.transform.Transformer} object, -this specification defines that a -String "qname" object parameter be passed as two-part string, the namespace URI -enclosed in curly braces ({}), followed by the local name. If the qname has a -null URI, then the String object only contains the local name. An application -can safely check for a non-null URI by testing to see if the first character of -the name is a '{' character. -

    - -

    For example, if a URI and local name were obtained from an element -defined with <xyz:foo xmlns:xyz="http://xyz.foo.com/yada/baz.html"/>, -then the Qualified Name would be "{http://xyz.foo.com/yada/baz.html}foo". -Note that the prefix is lost. -

    - - -

    Result Tree Serialization

    - -

    Serialization of the result tree to a stream can be controlled with -the {@link javax.xml.transform.Transformer#setOutputProperties} and the -{@link javax.xml.transform.Transformer#setOutputProperty} methods. -These properties only apply to stream results, they have no effect when -the result is a DOM tree or SAX event stream.

    - -

    Strings that match the XSLT -specification for xsl:output attributes can be referenced from the -{@link javax.xml.transform.OutputKeys} class. Other strings can be -specified as well. -If the transformer does not recognize an output key, a -{@link java.lang.IllegalArgumentException} is thrown, unless the -key name is namespace qualified. Output key names -that are namespace qualified are always allowed, although they may be -ignored by some implementations.

    - -

    If all that is desired is the simple identity transformation of a -source to a result, then {@link javax.xml.transform.TransformerFactory} -provides a -{@link javax.xml.transform.TransformerFactory#newTransformer()} method -with no arguments. This method creates a Transformer that effectively copies -the source to the result. This method may be used to create a DOM from SAX -events or to create an XML or HTML stream from a DOM or SAX events.

    - -

    Exceptions and Error Reporting

    - -

    The transformation API throw three types of specialized exceptions. A -{@link javax.xml.transform.TransformerFactoryConfigurationError} is parallel to -the {@link javax.xml.parsers.FactoryConfigurationError}, and is thrown -when a configuration problem with the TransformerFactory exists. This error -will typically be thrown when the transformation factory class specified with -the "javax.xml.transform.TransformerFactory" system property cannot be found or -instantiated.

    - -

    A {@link javax.xml.transform.TransformerConfigurationException} -may be thrown if for any reason a Transformer can not be created. A -TransformerConfigurationException may be thrown if there is a syntax error in -the transformation instructions, for example when -{@link javax.xml.transform.TransformerFactory#newTransformer} is -called.

    - -

    {@link javax.xml.transform.TransformerException} is a general -exception that occurs during the course of a transformation. A transformer -exception may wrap another exception, and if any of the -{@link javax.xml.transform.TransformerException#printStackTrace()} -methods are called on it, it will produce a list of stack dumps, starting from -the most recent. The transformer exception also provides a -{@link javax.xml.transform.SourceLocator} object which indicates where -in the source tree or transformation instructions the error occurred. -{@link javax.xml.transform.TransformerException#getMessageAndLocation()} -may be called to get an error message with location info, and -{@link javax.xml.transform.TransformerException#getLocationAsString()} -may be called to get just the location string.

    - -

    Transformation warnings and errors are sent to an -{@link javax.xml.transform.ErrorListener}, at which point the -application may decide to report the error or warning, and may decide to throw -an Exception for a non-fatal error. The ErrorListener may be set via -{@link javax.xml.transform.TransformerFactory#setErrorListener} for -reporting errors that have to do with syntax errors in the transformation -instructions, or via -{@link javax.xml.transform.Transformer#setErrorListener} to report -errors that occur during the transformation. The ErrorListener on both objects -will always be valid and non-null, whether set by the application or a default -implementation provided by the processor. -The default implementation provided by the processor will report all warnings and errors to System.err -and does not throw any Exceptions. -Applications are strongly encouraged to register and use -ErrorListeners that insure proper behavior for warnings and -errors. -

    - - -

    Resolution of URIs within a transformation

    - -

    The API provides a way for URIs referenced from within the stylesheet -instructions or within the transformation to be resolved by the calling -application. This can be done by creating a class that implements the -{@link javax.xml.transform.URIResolver} interface, with its one method, -{@link javax.xml.transform.URIResolver#resolve}, and use this class to -set the URI resolution for the transformation instructions or transformation -with {@link javax.xml.transform.TransformerFactory#setURIResolver} or -{@link javax.xml.transform.Transformer#setURIResolver}. The -URIResolver.resolve method takes two String arguments, the URI found in the -stylesheet instructions or built as part of the transformation process, and the -base URI -against which the first argument will be made absolute if the -absolute URI is required. -The returned {@link javax.xml.transform.Source} object must be usable by -the transformer, as specified in its implemented features.

    - - - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/sax/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/transform/sax/package-info.java new file mode 100644 index 00000000000..04b3e266fa0 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/transform/sax/package-info.java @@ -0,0 +1,88 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides SAX specific transformation classes. + * + *

    + * The {@link javax.xml.transform.sax.SAXSource} class allows the + * setting of an {@link org.xml.sax.XMLReader} to be used for pulling + * parse events, and an {@link org.xml.sax.InputSource} that may be used to + * specify the SAX source. + *

    + * The {@link javax.xml.transform.sax.SAXResult} class allows the + * setting of a {@link org.xml.sax.ContentHandler} to be the receiver of + * SAX2 events from the transformation. + *

    + * The {@link javax.xml.transform.sax.SAXTransformerFactory} extends + * {@link javax.xml.transform.TransformerFactory} to provide factory + * methods for creating {@link javax.xml.transform.sax.TemplatesHandler}, + * {@link javax.xml.transform.sax.TransformerHandler}, and + * {@link org.xml.sax.XMLReader} instances. + *

    + * To obtain a {@link javax.xml.transform.sax.SAXTransformerFactory}, + * the caller must cast the {@link javax.xml.transform.TransformerFactory} + * instance returned from + * {@link javax.xml.transform.TransformerFactory#newInstance}. + * + *

    + * The {@link javax.xml.transform.sax.TransformerHandler} interface + * allows a transformation to be created from SAX2 parse events, which is a "push" + * model rather than the "pull" model that normally occurs for a transformation. + * Normal parse events are received through the + * {@link org.xml.sax.ContentHandler} interface, lexical events such as + * startCDATA and endCDATA are received through the + * {@link org.xml.sax.ext.LexicalHandler} interface, and events that signal + * the start or end of disabling output escaping are received via + * {@link org.xml.sax.ContentHandler#processingInstruction}, with the + * target parameter being + * {@link javax.xml.transform.Result#PI_DISABLE_OUTPUT_ESCAPING} and + * {@link javax.xml.transform.Result#PI_ENABLE_OUTPUT_ESCAPING}. If + * parameters, output properties, or other features need to be set on the + * Transformer handler, a {@link javax.xml.transform.Transformer} reference + * will need to be obtained from + * {@link javax.xml.transform.sax.TransformerHandler#getTransformer}, and + * the methods invoked from that reference. + * + *

    + * The {@link javax.xml.transform.sax.TemplatesHandler} interface + * allows the creation of {@link javax.xml.transform.Templates} objects + * from SAX2 parse events. Once the {@link org.xml.sax.ContentHandler} + * events are complete, the Templates object may be obtained from + * {@link javax.xml.transform.sax.TemplatesHandler#getTemplates}. Note that + * {@link javax.xml.transform.sax.TemplatesHandler#setSystemId} should + * normally be called in order to establish a base system ID from which relative + * URLs may be resolved. + *

    + * The {@link javax.xml.transform.sax.SAXTransformerFactory#newXMLFilter} + * method allows the creation of a {@link org.xml.sax.XMLFilter}, which + * encapsulates the SAX2 notion of a "pull" transformation. The resulting + * {@code XMLFilters} can be chained together so that a series of transformations + * can happen with one's output becoming another's input. + * + * @since 1.5 + */ + +package javax.xml.transform.sax; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/sax/package.html b/jaxp/src/java.xml/share/classes/javax/xml/transform/sax/package.html deleted file mode 100644 index 97dce462bdb..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/transform/sax/package.html +++ /dev/null @@ -1,104 +0,0 @@ - - - - - - - - - javax.xml.transform.sax - - - - - - -

    This package implements SAX2-specific transformation APIs. It provides - classes which allow input from {@link org.xml.sax.ContentHandler} - events, and also classes that produce org.xml.sax.ContentHandler events. It - also provides methods to set the input source as an - {@link org.xml.sax.XMLReader}, or to use a - {@link org.xml.sax.InputSource} as the source. It also allows the - creation of a {@link org.xml.sax.XMLFilter}, which enables - transformations to "pull" from other transformations, and lets the transformer - to be used polymorphically as an {@link org.xml.sax.XMLReader}.

    -

    The {@link javax.xml.transform.sax.SAXSource} class allows the - setting of an {@link org.xml.sax.XMLReader} to be used for "pulling" - parse events, and an {@link org.xml.sax.InputSource} that may be used to - specify the SAX source.

    -

    The {@link javax.xml.transform.sax.SAXResult} class allows the - setting of a {@link org.xml.sax.ContentHandler} to be the receiver of - SAX2 events from the transformation. -

    The {@link javax.xml.transform.sax.SAXTransformerFactory} extends - {@link javax.xml.transform.TransformerFactory} to provide factory - methods for creating {@link javax.xml.transform.sax.TemplatesHandler}, - {@link javax.xml.transform.sax.TransformerHandler}, and - {@link org.xml.sax.XMLReader} instances.

    -

    To obtain a {@link javax.xml.transform.sax.SAXTransformerFactory}, - the caller must cast the {@link javax.xml.transform.TransformerFactory} - instance returned from - {@link javax.xml.transform.TransformerFactory#newInstance}. - -

    The {@link javax.xml.transform.sax.TransformerHandler} interface - allows a transformation to be created from SAX2 parse events, which is a "push" - model rather than the "pull" model that normally occurs for a transformation. - Normal parse events are received through the - {@link org.xml.sax.ContentHandler} interface, lexical events such as - startCDATA and endCDATA are received through the - {@link org.xml.sax.ext.LexicalHandler} interface, and events that signal - the start or end of disabling output escaping are received via - {@link org.xml.sax.ContentHandler#processingInstruction}, with the - target parameter being - {@link javax.xml.transform.Result#PI_DISABLE_OUTPUT_ESCAPING} and - {@link javax.xml.transform.Result#PI_ENABLE_OUTPUT_ESCAPING}. If - parameters, output properties, or other features need to be set on the - Transformer handler, a {@link javax.xml.transform.Transformer} reference - will need to be obtained from - {@link javax.xml.transform.sax.TransformerHandler#getTransformer}, and - the methods invoked from that reference. - -

    The {@link javax.xml.transform.sax.TemplatesHandler} interface - allows the creation of {@link javax.xml.transform.Templates} objects - from SAX2 parse events. Once the {@link org.xml.sax.ContentHandler} - events are complete, the Templates object may be obtained from - {@link javax.xml.transform.sax.TemplatesHandler#getTemplates}. Note that - {@link javax.xml.transform.sax.TemplatesHandler#setSystemId} should - normally be called in order to establish a base system ID from which relative - URLs may be resolved. -

    The - {@link javax.xml.transform.sax.SAXTransformerFactory#newXMLFilter} - method allows the creation of a {@link org.xml.sax.XMLFilter}, which - encapsulates the SAX2 notion of a "pull" transformation. The following - illustrates several transformations chained together. Each filter points to a - parent {@link org.xml.sax.XMLReader}, and the final transformation is - caused by invoking {@link org.xml.sax.XMLReader#parse} on the final - reader in the chain.

    - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/stax/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/transform/stax/package-info.java new file mode 100644 index 00000000000..a17343f9985 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/transform/stax/package-info.java @@ -0,0 +1,45 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides StAX specific transformation classes. + * + *

    + * The {@link javax.xml.transform.stax.StAXSource} class encapsulates a + * {@link javax.xml.stream.XMLStreamReader} or {@link javax.xml.stream.XMLEventReader} + * and can be used as an input where a {@link javax.xml.transform.Source} + * object is accepted. + * + *

    + * The {@link javax.xml.transform.stax.StAXResult} class encapsulates a + * {@link javax.xml.stream.XMLStreamWriter} or {@link javax.xml.stream.XMLEventWriter} + * and can be used as an output where a {@link javax.xml.transform.Result} + * object is accepted. + * + * + * @since 1.6 + */ + +package javax.xml.transform.stax; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/stax/package.html b/jaxp/src/java.xml/share/classes/javax/xml/transform/stax/package.html deleted file mode 100644 index abdd5ecd846..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/transform/stax/package.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - - - - - javax.xml.transform.stax - - - - - - -

    - Provides for StAX-specific transformation APIs. - TODO: better description(s). -

    - -

    Package Specification

    - - -

    Related Documentation

    - -

    For overviews, tutorials, examples, guides, and tool documentation, please see:

    - - - -
      -
    • @see XMLStreamReader
    • -
    • @see XMLEventReader
    • -
    - - @since 1.6 - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/stream/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/transform/stream/package-info.java new file mode 100644 index 00000000000..9534e621efb --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/transform/stream/package-info.java @@ -0,0 +1,56 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides stream and URI specific transformation classes. + * + *

    + * The {@link javax.xml.transform.stream.StreamSource} class + * provides methods for specifying {@link java.io.InputStream} input, + * {@link java.io.Reader} input, and URL input in the form of strings. Even + * if an input stream or reader is specified as the source, + * {@link javax.xml.transform.stream.StreamSource#setSystemId} should still + * be called, so that the transformer can know from where it should resolve + * relative URIs. The public identifier is always optional: if the application + * writer includes one, it will be provided as part of the + * {@link javax.xml.transform.SourceLocator} information. + *

    + * The {@link javax.xml.transform.stream.StreamResult} class + * provides methods for specifying {@link java.io.OutputStream}, + * {@link java.io.Writer}, or an output system ID, as the output of the + * transformation result. + *

    + * Normally streams should be used rather than readers or writers, for + * both the Source and Result, since readers and writers already have the encoding + * established to and from the internal Unicode format. However, there are times + * when it is useful to write to a character stream, such as when using a + * StringWriter in order to write to a String, or in the case of reading source + * XML from a StringReader. + * + * + * @since 1.5 + */ + +package javax.xml.transform.stream; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/transform/stream/package.html b/jaxp/src/java.xml/share/classes/javax/xml/transform/stream/package.html deleted file mode 100644 index ea52ecb692e..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/transform/stream/package.html +++ /dev/null @@ -1,64 +0,0 @@ - - - - - - - - - javax.xml.transform.stream - - - - - -

    This package implements stream- and URI- specific transformation APIs. -

    -

    The {@link javax.xml.transform.stream.StreamSource} class - provides methods for specifying {@link java.io.InputStream} input, - {@link java.io.Reader} input, and URL input in the form of strings. Even - if an input stream or reader is specified as the source, - {@link javax.xml.transform.stream.StreamSource#setSystemId} should still - be called, so that the transformer can know from where it should resolve - relative URIs. The public identifier is always optional: if the application - writer includes one, it will be provided as part of the - {@link javax.xml.transform.SourceLocator} information.

    -

    The {@link javax.xml.transform.stream.StreamResult} class - provides methods for specifying {@link java.io.OutputStream}, - {@link java.io.Writer}, or an output system ID, as the output of the - transformation result.

    -

    Normally streams should be used rather than readers or writers, for - both the Source and Result, since readers and writers already have the encoding - established to and from the internal Unicode format. However, there are times - when it is useful to write to a character stream, such as when using a - StringWriter in order to write to a String, or in the case of reading source - XML from a StringReader.

    - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/validation/SchemaFactory.java b/jaxp/src/java.xml/share/classes/javax/xml/validation/SchemaFactory.java index 2bcc73e1be1..aafa5cd844b 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/validation/SchemaFactory.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/validation/SchemaFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -58,7 +58,7 @@ import org.xml.sax.SAXParseException; * may not attempt to recursively invoke the {@code newSchema} method, * even from the same thread. * - *

    Schema Language

    + *

    Schema Language

    *

    * This spec uses a namespace URI to designate a schema language. * The following table shows the values defined by this specification. @@ -84,7 +84,8 @@ import org.xml.sax.SAXParseException; * validation implemented on this interface necessarily deviate from * the XML DTD semantics as defined in the XML 1.0. * - *

    XML Namespaces, {@code javax.xml.stream.isRepairingNamespaces} and write method behaviour
    XML Namespaces, {@code javax.xml.stream.isRepairingNamespaces} and write method behaviour
    Method {@code isRepairingNamespaces} == true{@code isRepairingNamespaces} == false
    + *
    + * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/validation/SchemaFactoryLoader.java b/jaxp/src/java.xml/share/classes/javax/xml/validation/SchemaFactoryLoader.java index f617d99ae51..051d496415b 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/validation/SchemaFactoryLoader.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/validation/SchemaFactoryLoader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -60,7 +60,7 @@ public abstract class SchemaFactoryLoader { * the list of available schema languages. * * @throws NullPointerException - * If the schemaLanguage parameter is null. + * If the schemaLanguage parameter is null. * * @return null if the callee fails to create one. */ diff --git a/jaxp/src/java.xml/share/classes/javax/xml/validation/Validator.java b/jaxp/src/java.xml/share/classes/javax/xml/validation/Validator.java index bd746b40e84..b71319c8023 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/validation/Validator.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/validation/Validator.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -131,12 +131,10 @@ public abstract class Validator { *

    This method places the following restrictions on the types of * the {@link Source}/{@link Result} accepted. * - *

    URIs for Supported Schema languages
    value
    + *
    + * * * - * - * - * * * * @@ -144,7 +142,7 @@ public abstract class Validator { * * * - * + * * * * diff --git a/jaxp/src/java.xml/share/classes/javax/xml/validation/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/validation/package-info.java new file mode 100644 index 00000000000..b4fb61b26ae --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/validation/package-info.java @@ -0,0 +1,133 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + *

    + * Provides an API for validation of XML documents. Validation is the + * process of verifying that an XML document is an instance of a specified XML + * schema. An XML schema defines the content model (also called a + * grammar or vocabulary) that its instance documents will + * represent. + * + *

    + * There are a number of popular technologies available for creating an XML schema. + * Some of the most popular ones include: + * + *

      + *
    • Document Type Definition (DTD) + * - XML's built-in schema language. + *
    • + *
    • W3C XML Schema (WXS) - + * an object-oriented XML schema language. WXS also provides a type system + * for constraining the character data of an XML document. WXS is maintained + * by the World Wide Web Consortium (W3C) + * and is a W3C Recommendation (that is, a ratified W3C standard specification). + *
    • + *
    • RELAX NG (RNG) - + * a pattern-based, user-friendly XML schema language. RNG schemas may + * also use types to constrain XML character data. RNG is maintained by + * the Organization for the Advancement + * of Structured Information Standards (OASIS) and is both an OASIS + * and an ISO (International Organization + * for Standardization) standard. + *
    • + *
    • Schematron - + * a rules-based XML schema language. Whereas DTD, WXS, and RNG are designed + * to express the structure of a content model, Schematron is designed to + * enforce individual rules that are difficult or impossible to express + * with other schema languages. Schematron is intended to supplement a + * schema written in structural schema language such as the aforementioned. + * Schematron is in the process of becoming an ISO standard. + *
    • + *
    + *

    + * While JAXP supports validation as a feature of an XML parser, represented by + * either a {@link javax.xml.parsers.SAXParser} or {@link javax.xml.parsers.DocumentBuilder} + * instance, the {@code Validation} API is preferred. + * + *

    + * The JAXP validation API decouples the validation of an instance document from + * the parsing of an XML document. This is advantageous for several reasons, + * some of which are: + * + *

      + *
    • Support for additional schema langauges. + * The JAXP parser implementations support only a subset of the available + * XML schema languages. The Validation API provides a standard mechanism + * through which applications may take of advantage of specialization + * validation libraries which support additional schema languages. + *
    • + *
    • Easy runtime coupling of an XML instance and schema. + * Specifying the location of a schema to use for validation with JAXP + * parsers can be confusing. The Validation API makes this process simple + * (see example below). + *
    • + *
    + *

    + * Usage example. The following example + * demonstrates validating an XML document with the Validation API + * (for readability, some exception handling is not shown): + * + *

    + *
    + *     // parse an XML document into a DOM tree
    + *     DocumentBuilder parser = DocumentBuilderFactory.newInstance().newDocumentBuilder();
    + *     Document document = parser.parse(new File("instance.xml"));
    + *
    + *     // create a SchemaFactory capable of understanding WXS schemas
    + *     SchemaFactory factory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
    + *
    + *     // load a WXS schema, represented by a Schema instance
    + *     Source schemaFile = new StreamSource(new File("mySchema.xsd"));
    + *     Schema schema = factory.newSchema(schemaFile);
    + *
    + *     // create a Validator instance, which can be used to validate an instance document
    + *     Validator validator = schema.newValidator();
    + *
    + *     // validate the DOM tree
    + *     try {
    + *         validator.validate(new DOMSource(document));
    + *     } catch (SAXException e) {
    + *         // instance document is invalid!
    + *     }
    + * 
    + *

    + * The JAXP parsing API has been integrated with the Validation API. Applications + * may create a {@link javax.xml.validation.Schema} with the validation API + * and associate it with a {@link javax.xml.parsers.DocumentBuilderFactory} or + * a {@link javax.xml.parsers.SAXParserFactory} instance by using the + * {@link javax.xml.parsers.DocumentBuilderFactory#setSchema(Schema)} and + * {@link javax.xml.parsers.SAXParserFactory#setSchema(Schema)} methods. + * You should not both set a schema and call setValidating(true) + * on a parser factory. The former technique will cause parsers to use the new + * validation API; the latter will cause parsers to use their own internal validation + * facilities. Turning on both of these options simultaneously will cause + * either redundant behavior or error conditions. + * + * + * @since 1.5 + */ + +package javax.xml.validation; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/validation/package.html b/jaxp/src/java.xml/share/classes/javax/xml/validation/package.html deleted file mode 100644 index 2dd06b3175e..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/validation/package.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - - - - javax.xml.validation - - - - - -

    - This package provides an API for validation of XML documents. Validation is the process of verifying - that an XML document is an instance of a specified XML schema. An XML schema defines the - content model (also called a grammar or vocabulary) that its instance documents - will represent. -

    -

    - There are a number of popular technologies available for creating an XML schema. Some of the most - popular include: -

    -
      -
    • Document Type Definition (DTD) - XML's built-in schema language.
    • -
    • W3C XML Schema (WXS) - an object-oriented XML schema - language. WXS also provides a type system for constraining the character data of an XML document. - WXS is maintained by the World Wide Web Consortium (W3C) and is a W3C - Recommendation (that is, a ratified W3C standard specification).
    • -
    • RELAX NG (RNG) - a pattern-based, - user-friendly XML schema language. RNG schemas may also use types to constrain XML character data. - RNG is maintained by the Organization for the Advancement of - Structured Information Standards (OASIS) and is both an OASIS and an - ISO (International Organization for Standardization) standard.
    • -
    • Schematron - a rules-based XML schema - language. Whereas DTD, WXS, and RNG are designed to express the structure of a content model, - Schematron is designed to enforce individual rules that are difficult or impossible to express - with other schema languages. Schematron is intended to supplement a schema written in - structural schema language such as the aforementioned. Schematron is in the process - of becoming an ISO standard.
    • -
    -

    - Previous versions of JAXP supported validation as a feature of an XML parser, represented by - either a {@link javax.xml.parsers.SAXParser} or {@link javax.xml.parsers.DocumentBuilder} instance. -

    -

    - The JAXP validation API decouples the validation of an instance document from the parsing of an - XML document. This is advantageous for several reasons, some of which are: -

    -
      -
    • Support for additional schema langauges. As of JDK 1.5, the two most - popular JAXP parser implementations, Crimson and Xerces, only support a subset of the available - XML schema languages. The Validation API provides a standard mechanism through which applications - may take of advantage of specialization validation libraries which support additional schema - languages.
    • -
    • Easy runtime coupling of an XML instance and schema. Specifying the location - of a schema to use for validation with JAXP parsers can be confusing. The Validation API makes this - process simple (see example below).
    • -
    -

    - Usage example. The following example demonstrates validating - an XML document with the Validation API (for readability, some exception handling is not shown): -

    -
    -            
    -    // parse an XML document into a DOM tree
    -    DocumentBuilder parser = DocumentBuilderFactory.newInstance().newDocumentBuilder();
    -    Document document = parser.parse(new File("instance.xml"));
    -
    -    // create a SchemaFactory capable of understanding WXS schemas
    -    SchemaFactory factory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
    -
    -    // load a WXS schema, represented by a Schema instance
    -    Source schemaFile = new StreamSource(new File("mySchema.xsd"));
    -    Schema schema = factory.newSchema(schemaFile);
    -
    -    // create a Validator instance, which can be used to validate an instance document
    -    Validator validator = schema.newValidator();
    -
    -    // validate the DOM tree
    -    try {
    -        validator.validate(new DOMSource(document));
    -    } catch (SAXException e) {
    -        // instance document is invalid!
    -    }
    -
    -

    - The JAXP parsing API has been integrated with the Validation API. Applications may create a {@link javax.xml.validation.Schema} with the validation API - and associate it with a {@link javax.xml.parsers.DocumentBuilderFactory} or a {@link javax.xml.parsers.SAXParserFactory} instance - by using the {@link javax.xml.parsers.DocumentBuilderFactory#setSchema(Schema)} and {@link javax.xml.parsers.SAXParserFactory#setSchema(Schema)} - methods. You should not both set a schema and call setValidating(true) on a parser factory. The former technique - will cause parsers to use the new validation API; the latter will cause parsers to use their own internal validation - facilities. Turning on both of these options simultaneously will cause either redundant behavior or error conditions. -

    - - diff --git a/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPath.java b/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPath.java index d7c0a44bf95..8270231254c 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPath.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPath.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,14 +31,18 @@ import org.xml.sax.InputSource; /** * {@code XPath} provides access to the XPath evaluation environment and expressions. + * The XPath evaluation is affected by the factors described in the following table. * - * - *
    {@code Source} / {@code Result} Accepted
    {@code Source} / {@code Result} Accepted
    {@link javax.xml.transform.stream.StreamSource}{@link javax.xml.transform.sax.SAXSource}{@link javax.xml.transform.stax.StAXSource}
    {@code null}OK
    + * + *
    + * * * - * + * + * * * + * * * * * + * *
    Evaluation of XPath Expressions
    Evaluation of XPath Expressions.FactorBehavior
    context @@ -84,6 +88,7 @@ import org.xml.sax.InputSource; * Conversion to the return type follows XPath conversion rules. *
    * *

    An XPath object is not thread-safe and not reentrant. diff --git a/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPathExpression.java b/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPathExpression.java index 697745e92d5..b6616685231 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPathExpression.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPathExpression.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,14 +30,18 @@ import org.xml.sax.InputSource; /** * {@code XPathExpression} provides access to compiled XPath expressions. + * The XPath evaluation is affected by the factors described in the following table. * - * - * + * + *
    + * * * - * + * + * * * + * * * *
    Evaluation of XPath Expressions
    Evaluation of XPath Expressions.FactorBehavior
    context diff --git a/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPathFactoryFinder.java b/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPathFactoryFinder.java index 97c923e15d1..9db2556ea54 100644 --- a/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPathFactoryFinder.java +++ b/jaxp/src/java.xml/share/classes/javax/xml/xpath/XPathFactoryFinder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -176,9 +176,9 @@ class XPathFactoryFinder { String javah = ss.getSystemProperty( "java.home" ); String configFile = javah + File.separator + - "lib" + File.separator + "jaxp.properties"; + "conf" + File.separator + "jaxp.properties"; - // try to read from $java.home/lib/jaxp.properties + // try to read from $java.home/conf/jaxp.properties try { if(firstTime){ synchronized(cacheProps){ @@ -193,7 +193,7 @@ class XPathFactoryFinder { } } final String factoryClassName = cacheProps.getProperty(propertyName); - debugPrintln(()->"found " + factoryClassName + " in $java.home/jaxp.properties"); + debugPrintln(()->"found " + factoryClassName + " in $java.home/conf/jaxp.properties"); if (factoryClassName != null) { xpathFactory = createInstance(factoryClassName, true); diff --git a/jaxp/src/java.xml/share/classes/javax/xml/xpath/package-info.java b/jaxp/src/java.xml/share/classes/javax/xml/xpath/package-info.java new file mode 100644 index 00000000000..b700c969b63 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/javax/xml/xpath/package-info.java @@ -0,0 +1,401 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * + * Provides an object-model neutral API for the + * evaluation of XPath expressions and access to the evaluation + * environment. + * + *

    + * The XPath API supports + * XML Path Language (XPath) Version 1.0 + * + *


    + * + * + *

    + * + *

    1. XPath Overview

    + * + *

    + * The XPath language provides a simple, concise syntax for selecting + * nodes from an XML document. XPath also provides rules for converting a + * node in an XML document object model (DOM) tree to a boolean, double, + * or string value. XPath is a W3C-defined language and an official W3C + * recommendation; the W3C hosts the XML Path Language (XPath) Version + * 1.0 specification. + * + * + *

    + * XPath started in life in 1999 as a supplement to the XSLT and + * XPointer languages, but has more recently become popular as a + * stand-alone language, as a single XPath expression can be used to + * replace many lines of DOM API code. + * + * + * + *

    2. XPath Expressions

    + * + *

    + * An XPath expression is composed of a location + * path and one or more optional predicates. Expressions + * may also include XPath variables. + * + * + *

    + * The following is an example of a simple XPath expression: + * + *

    + *
    + *     /foo/bar
    + * 
    + *
    + * + *

    + * This example would select the <bar> element in + * an XML document such as the following: + * + *

    + *
    + *     <foo>
    + *         <bar/>
    + *     </foo>
    + * 
    + *
    + * + *

    The expression /foo/bar is an example of a location + * path. While XPath location paths resemble Unix-style file system + * paths, an important distinction is that XPath expressions return + * all nodes that match the expression. Thus, all three + * <bar> elements in the following document would be + * selected by the /foo/bar expression: + * + *

    + *
    + *     <foo>
    + *         <bar/>
    + *         <bar/>
    + *         <bar/>
    + *     </foo>
    + * 
    + *
    + * + *

    + * A special location path operator, //, selects nodes at + * any depth in an XML document. The following example selects all + * <bar> elements regardless of their location in a + * document: + * + *

    + *
    + *     //bar
    + * 
    + *
    + * + *

    + * A wildcard operator, *, causes all element nodes to be selected. + * The following example selects all children elements of a + * <foo> element: + * + *

    + *
    + *     /foo/*
    + * 
    + *
    + * + *

    + * In addition to element nodes, XPath location paths may also address + * attribute nodes, text nodes, comment nodes, and processing instruction + * nodes. The following table gives examples of location paths for each + * of these node types: + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
    Examples of Location Path
    Location PathDescription
    + * /foo/bar/@id + * + * Selects the attribute id of the <bar> element + *
    /foo/bar/text() + * + * Selects the text nodes of the <bar> element. No + * distinction is made between escaped and non-escaped character data. + *
    /foo/bar/comment() + * + * Selects all comment nodes contained in the <bar> element. + *
    /foo/bar/processing-instruction() + * + * Selects all processing-instruction nodes contained in the + * <bar> element. + *
    + * + *

    + * Predicates allow for refining the nodes selected by an XPath + * location path. Predicates are of the form + * [expression]. The following example selects all + * <foo> elements that contain an include + * attribute with the value of true: + * + *

    + *
    + *     //foo[@include='true']
    + * 
    + *
    + * + *

    + * Predicates may be appended to each other to further refine an + * expression, such as: + * + *

    + *
    + *     //foo[@include='true'][@mode='bar']
    + * 
    + *
    + * + * + *

    3. XPath Data Types

    + * + *

    + * While XPath expressions select nodes in the XML document, the XPath + * API allows the selected nodes to be coalesced into one of the + * following data types: + * + *

      + *
    • Boolean
    • + *
    • Number
    • + *
    • String
    • + *
    + * + * + *

    3.1 QName types

    + * The XPath API defines the following {@link javax.xml.namespace.QName} types to + * represent return types of an XPath evaluation: + *
      + *
    • {@link javax.xml.xpath.XPathConstants#NODESET}
    • + *
    • {@link javax.xml.xpath.XPathConstants#NODE}
    • + *
    • {@link javax.xml.xpath.XPathConstants#STRING}
    • + *
    • {@link javax.xml.xpath.XPathConstants#BOOLEAN}
    • + *
    • {@link javax.xml.xpath.XPathConstants#NUMBER}
    • + *
    + * + *

    + * The return type is specified by a {@link javax.xml.namespace.QName} parameter + * in method call used to evaluate the expression, which is either a call to + * XPathExpression.evalute(...) or XPath.evaluate(...) + * methods. + * + *

    + * When a Boolean return type is requested, + * Boolean.TRUE is returned if one or more nodes were + * selected; otherwise, Boolean.FALSE is returned. + * + *

    + * The String return type is a convenience for retrieving + * the character data from a text node, attribute node, comment node, or + * processing-instruction node. When used on an element node, the value + * of the child text nodes is returned. + * + *

    + * The Number return type attempts to coalesce the text + * of a node to a double data type. + * + * + *

    3.2 Class types

    + * In addition to the QName types, the XPath API supports the use of Class types + * through the XPathExpression.evaluteExpression(...) or + * XPath.evaluateExpression(...) methods. + * + * The XPath data types are mapped to Class types as follows: + *
      + *
    • Boolean -- Boolean.class
    • + *
    • Number -- Number.class
    • + *
    • String -- String.class
    • + *
    • Nodeset -- XPathNodes.class
    • + *
    • Node -- Node.class
    • + *
    + * + *

    + * Of the subtypes of Number, only Double, Integer and Long are supported. + * + * + *

    3.3 Enum types

    + * Enum types are defined in {@link javax.xml.xpath.XPathEvaluationResult.XPathResultType} + * that provide mappings between the QName and Class types above. The result of + * evaluating an expression using the XPathExpression.evaluteExpression(...) + * or XPath.evaluateExpression(...) methods will be of one of these types. + * + * + *

    4. XPath Context

    + * + *

    + * XPath location paths may be relative to a particular node in the + * document, known as the context. A context consists of: + *

      + *
    • a node (the context node)
    • + *
    • a pair of non-zero positive integers (the context position and the context size)
    • + *
    • a set of variable bindings
    • + *
    • a function library
    • + *
    • the set of namespace declarations in scope for the expression
    • + *
    + * + *

    + * It is an XML document tree represented as a hierarchy of nodes, a + * {@link org.w3c.dom.Node} for example, in the JDK implementation. + * + * + *

    5. Using the XPath API

    + * + * Consider the following XML document: + *
    + *
    + * <widgets>
    + * <widget>
    + * <manufacturer/>
    + * <dimensions/>
    + * </widget>
    + * </widgets>
    + * 
    + *
    + * + *

    + * The <widget> element can be selected with the following process: + * + *

    + *
    + *     // parse the XML as a W3C Document
    + *     DocumentBuilder builder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
    + *     Document document = builder.parse(new File("/widgets.xml"));
    + *
    + *     //Get an XPath object and evaluate the expression
    + *     XPath xpath = XPathFactory.newInstance().newXPath();
    + *     String expression = "/widgets/widget";
    + *     Node widgetNode = (Node) xpath.evaluate(expression, document, XPathConstants.NODE);
    + *
    + *     //or using the evaluateExpression method
    + *     Node widgetNode = xpath.evaluateExpression(expression, document, Node.class);
    + * 
    + *
    + * + *

    + * With a reference to the <widget> element, a + * relative XPath expression can be written to select the + * <manufacturer> child element: + * + *

    + *
    + *     XPath xpath = XPathFactory.newInstance().newXPath();
    + *     String expression = "manufacturer";
    + *     Node manufacturerNode = (Node) xpath.evaluate(expression, widgetNode, XPathConstants.NODE);
    + *
    + *     //or using the evaluateExpression method
    + *     Node manufacturerNode = xpath.evaluateExpression(expression, widgetNode, Node.class);
    + * 
    + *
    + * + *

    + * In the above example, the XML file is read into a DOM Document before being passed + * to the XPath API. The following code demonstrates the use of InputSource to + * leave it to the XPath implementation to process it: + * + *

    + *
    + *     XPath xpath = XPathFactory.newInstance().newXPath();
    + *     String expression = "/widgets/widget";
    + *     InputSource inputSource = new InputSource("widgets.xml");
    + *     NodeList nodes = (NodeList) xpath.evaluate(expression, inputSource, XPathConstants.NODESET);
    + *
    + *     //or using the evaluateExpression method
    + *     XPathNodes nodes = xpath.evaluate(expression, inputSource, XPathNodes.class);
    + * 
    + *
    + * + *

    + * In the above cases, the type of the expected results are known. In case where + * the result type is unknown or any type, the {@link javax.xml.xpath.XPathEvaluationResult} + * may be used to determine the return type. The following code demonstrates the usage: + *

    + *
    + *     XPathEvaluationResult<?> result = xpath.evaluateExpression(expression, document);
    + *     switch (result.type()) {
    + *         case NODESET:
    + *             XPathNodes nodes = (XPathNodes)result.value();
    + *             ...
    + *             break;
    + *     }
    + * 
    + *
    + * + *

    + * The XPath 1.0 Number data type is defined as a double. However, the XPath + * specification also provides functions that returns Integer type. To facilitate + * such operations, the XPath API allows Integer and Long to be used in + * {@code evaluateExpression} method such as the following code: + *

    + *
    + *     int count = xpath.evaluate("count(/widgets/widget)", document, Integer.class);
    + * 
    + *
    + * + * @since 1.5 + * + */ + +package javax.xml.xpath; diff --git a/jaxp/src/java.xml/share/classes/javax/xml/xpath/package.html b/jaxp/src/java.xml/share/classes/javax/xml/xpath/package.html deleted file mode 100644 index 585160a726e..00000000000 --- a/jaxp/src/java.xml/share/classes/javax/xml/xpath/package.html +++ /dev/null @@ -1,377 +0,0 @@ - - - - - - - -This package provides an object-model neutral API for the -evaluation of XPath expressions and access to the evaluation -environment. - -

    -The XPath API supports - XML Path Language (XPath) Version 1.0 - -


    - - -

    - -

    1. XPath Overview

    - -

    The XPath language provides a simple, concise syntax for selecting -nodes from an XML document. XPath also provides rules for converting a -node in an XML document object model (DOM) tree to a boolean, double, -or string value. XPath is a W3C-defined language and an official W3C -recommendation; the W3C hosts the XML Path Language (XPath) Version -1.0 specification. -

    - -

    XPath started in life in 1999 as a supplement to the XSLT and -XPointer languages, but has more recently become popular as a -stand-alone language, as a single XPath expression can be used to -replace many lines of DOM API code. -

    - - -

    2. XPath Expressions

    - -

    An XPath expression is composed of a location -path and one or more optional predicates. Expressions -may also include XPath variables. -

    - -

    The following is an example of a simple XPath expression:

    - -
    -
    -/foo/bar
    -
    -
    - -

    This example would select the <bar> element in -an XML document such as the following:

    - -
    -
    -<foo>
    -    <bar/>
    -</foo>
    -
    -
    - -

    The expression /foo/bar is an example of a location -path. While XPath location paths resemble Unix-style file system -paths, an important distinction is that XPath expressions return -all nodes that match the expression. Thus, all three -<bar> elements in the following document would be -selected by the /foo/bar expression:

    - -
    -
    -<foo>
    -    <bar/>
    -    <bar/>
    -    <bar/>
    -</foo>
    -
    -
    - -

    A special location path operator, //, selects nodes at -any depth in an XML document. The following example selects all -<bar> elements regardless of their location in a -document:

    - -
    -
    -//bar
    -
    -
    - -

    A wildcard operator, *, causes all element nodes to be selected. -The following example selects all children elements of a -<foo> element: - -

    -
    -/foo/*
    -
    -
    - -

    In addition to element nodes, XPath location paths may also address -attribute nodes, text nodes, comment nodes, and processing instruction -nodes. The following table gives examples of location paths for each -of these node types:

    - - - - - - - - - - - - - - - - - - - - - - -
    Location PathDescription
    -/foo/bar/@id -Selects the attribute id of the <bar> element -
    /foo/bar/text() -Selects the text nodes of the <bar> element. No -distinction is made between escaped and non-escaped character data. -
    /foo/bar/comment() -Selects all comment nodes contained in the <bar> element. -
    /foo/bar/processing-instruction() -Selects all processing-instruction nodes contained in the -<bar> element. -
    - -

    Predicates allow for refining the nodes selected by an XPath -location path. Predicates are of the form -[expression]. The following example selects all -<foo> elements that contain an include -attribute with the value of true:

    - -
    -
    -//foo[@include='true']
    -
    -
    - -

    Predicates may be appended to each other to further refine an -expression, such as:

    - -
    -
    -//foo[@include='true'][@mode='bar']
    -
    -
    - - -

    3. XPath Data Types

    - -

    While XPath expressions select nodes in the XML document, the XPath -API allows the selected nodes to be coalesced into one of the -following data types:

    - -
      -
    • Boolean
    • -
    • Number
    • -
    • String
    • -
    - - -

    3.1 QName types

    -The XPath API defines the following {@link javax.xml.namespace.QName} types to -represent return types of an XPath evaluation: -
      -
    • {@link javax.xml.xpath.XPathConstants#NODESET}
    • -
    • {@link javax.xml.xpath.XPathConstants#NODE}
    • -
    • {@link javax.xml.xpath.XPathConstants#STRING}
    • -
    • {@link javax.xml.xpath.XPathConstants#BOOLEAN}
    • -
    • {@link javax.xml.xpath.XPathConstants#NUMBER}
    • -
    - -

    The return type is specified by a {@link javax.xml.namespace.QName} parameter -in method call used to evaluate the expression, which is either a call to -XPathExpression.evalute(...) or XPath.evaluate(...) -methods. - -

    When a Boolean return type is requested, -Boolean.TRUE is returned if one or more nodes were -selected; otherwise, Boolean.FALSE is returned. - -

    The String return type is a convenience for retrieving -the character data from a text node, attribute node, comment node, or -processing-instruction node. When used on an element node, the value -of the child text nodes is returned. - -

    The Number return type attempts to coalesce the text -of a node to a double data type. - - -

    3.2 Class types

    -In addition to the QName types, the XPath API supports the use of Class types -through the XPathExpression.evaluteExpression(...) or -XPath.evaluateExpression(...) methods. - -The XPath data types are mapped to Class types as follows: -
      -
    • Boolean -- Boolean.class
    • -
    • Number -- Number.class
    • -
    • String -- String.class
    • -
    • Nodeset -- XPathNodes.class
    • -
    • Node -- Node.class
    • -
    - -

    -Of the subtypes of Number, only Double, Integer and Long are supported. - - -

    3.3 Enum types

    -Enum types are defined in {@link javax.xml.xpath.XPathEvaluationResult.XPathResultType} -that provide mappings between the QName and Class types above. The result of -evaluating an expression using the XPathExpression.evaluteExpression(...) -or XPath.evaluateExpression(...) methods will be of one of these types. - - -

    4. XPath Context

    - -

    XPath location paths may be relative to a particular node in the -document, known as the context. A context consists of: -

      -
    • a node (the context node)
    • -
    • a pair of non-zero positive integers (the context position and the context size)
    • -
    • a set of variable bindings
    • -
    • a function library
    • -
    • the set of namespace declarations in scope for the expression
    • -
    - -

    -It is an XML document tree represented as a hierarchy of nodes, a -{@link org.w3c.dom.Node} for example, in the JDK implementation. - - -

    5. Using the XPath API

    - -Consider the following XML document: -
    -
    -<widgets>
    -<widget>
    -<manufacturer/>
    -<dimensions/>
    -</widget>
    -</widgets>
    -
    -
    - -

    -The <widget> element can be selected with the following process: - -

    -
    -// parse the XML as a W3C Document
    -DocumentBuilder builder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
    -Document document = builder.parse(new File("/widgets.xml"));
    -
    -//Get an XPath object and evaluate the expression
    -XPath xpath = XPathFactory.newInstance().newXPath();
    -String expression = "/widgets/widget";
    -Node widgetNode = (Node) xpath.evaluate(expression, document, XPathConstants.NODE);
    -
    -//or using the evaluateExpression method
    -Node widgetNode = xpath.evaluateExpression(expression, document, Node.class);
    -
    -
    - -

    With a reference to the <widget> element, a -relative XPath expression can be written to select the -<manufacturer> child element:

    - -
    -
    -XPath xpath = XPathFactory.newInstance().newXPath();
    -String expression = "manufacturer";
    -Node manufacturerNode = (Node) xpath.evaluate(expression, widgetNode, XPathConstants.NODE);
    -
    -//or using the evaluateExpression method
    -Node manufacturerNode = xpath.evaluateExpression(expression, widgetNode, Node.class);
    -
    -
    - -

    -In the above example, the XML file is read into a DOM Document before being passed -to the XPath API. The following code demonstrates the use of InputSource to -leave it to the XPath implementation to process it: - -

    -
    -XPath xpath = XPathFactory.newInstance().newXPath();
    -String expression = "/widgets/widget";
    -InputSource inputSource = new InputSource("widgets.xml");
    -NodeList nodes = (NodeList) xpath.evaluate(expression, inputSource, XPathConstants.NODESET);
    -
    -//or using the evaluateExpression method
    -XPathNodes nodes = xpath.evaluate(expression, inputSource, XPathNodes.class);
    -
    -
    - -

    -In the above cases, the type of the expected results are known. In case where -the result type is unknown or any type, the {@link javax.xml.xpath.XPathEvaluationResult} -may be used to determine the return type. The following code demonstrates the usage: -

    -
    -XPathEvaluationResult<?> result = xpath.evaluateExpression(expression, document);
    -switch (result.type()) {
    -    case NODESET:
    -        XPathNodes nodes = (XPathNodes)result.value();
    -        ...
    -        break;
    -}
    -
    -
    - -

    -The XPath 1.0 Number data type is defined as a double. However, the XPath -specification also provides functions that returns Integer type. To facilitate -such operations, the XPath API allows Integer and Long to be used in -{@code evaluateExpression} method such as the following code: -

    -
    -int count = xpath.evaluate("count(/widgets/widget)", document, Integer.class);
    -
    -
    - -@since 1.5 - - - diff --git a/jaxp/src/java.xml/share/classes/jdk/xml/internal/JdkXmlFeatures.java b/jaxp/src/java.xml/share/classes/jdk/xml/internal/JdkXmlFeatures.java index 240c386bf56..79e78865415 100644 --- a/jaxp/src/java.xml/share/classes/jdk/xml/internal/JdkXmlFeatures.java +++ b/jaxp/src/java.xml/share/classes/jdk/xml/internal/JdkXmlFeatures.java @@ -27,6 +27,7 @@ package jdk.xml.internal; import javax.xml.XMLConstants; import static jdk.xml.internal.JdkXmlUtils.SP_USE_CATALOG; +import static jdk.xml.internal.JdkXmlUtils.RESET_SYMBOL_TABLE; /** * This class manages JDK's XML Features. Previously added features and properties @@ -61,7 +62,13 @@ public class JdkXmlFeatures { * The {@link javax.xml.XMLConstants.USE_CATALOG} feature. * FSP: USE_CATALOG is not enforced by FSP. */ - USE_CATALOG(PROPERTY_USE_CATALOG, SP_USE_CATALOG, true, false, true, false); + USE_CATALOG(PROPERTY_USE_CATALOG, SP_USE_CATALOG, true, false, true, false), + + /** + * Feature resetSymbolTable + * FSP: RESET_SYMBOL_TABLE_FEATURE is not enforced by FSP. + */ + RESET_SYMBOL_TABLE_FEATURE(RESET_SYMBOL_TABLE, RESET_SYMBOL_TABLE, false, false, true, false); private final String name; private final String nameSP; diff --git a/jaxp/src/java.xml/share/classes/jdk/xml/internal/JdkXmlUtils.java b/jaxp/src/java.xml/share/classes/jdk/xml/internal/JdkXmlUtils.java index 7611ceb2b75..dfc973161d0 100644 --- a/jaxp/src/java.xml/share/classes/jdk/xml/internal/JdkXmlUtils.java +++ b/jaxp/src/java.xml/share/classes/jdk/xml/internal/JdkXmlUtils.java @@ -51,6 +51,12 @@ public class JdkXmlUtils { public final static String CATALOG_PREFER = CatalogFeatures.Feature.PREFER.getPropertyName(); public final static String CATALOG_RESOLVE = CatalogFeatures.Feature.RESOLVE.getPropertyName(); + /** + * Reset SymbolTable feature + * System property name is identical to feature name + */ + public final static String RESET_SYMBOL_TABLE = "jdk.xml.resetSymbolTable"; + /** * Values for a feature */ @@ -63,6 +69,13 @@ public class JdkXmlUtils { public static final boolean USE_CATALOG_DEFAULT = SecuritySupport.getJAXPSystemProperty(Boolean.class, SP_USE_CATALOG, "true"); + /** + * Default value of RESET_SYMBOL_TABLE. This will read the System property + */ + public static final boolean RESET_SYMBOL_TABLE_DEFAULT + = SecuritySupport.getJAXPSystemProperty(Boolean.class, RESET_SYMBOL_TABLE, "false"); + + /** * JDK features (will be consolidated in the next major feature revamp */ diff --git a/jaxp/src/java.xml/share/classes/module-info.java b/jaxp/src/java.xml/share/classes/module-info.java index d9259677564..af2e5d6daf8 100644 --- a/jaxp/src/java.xml/share/classes/module-info.java +++ b/jaxp/src/java.xml/share/classes/module-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,9 @@ /** * Defines the Java API for XML Processing (JAXP), the Streaming API for XML (StAX), * the Simple API for XML (SAX), and the W3C Document Object Model (DOM) API. + * + * @moduleGraph + * @since 9 */ module java.xml { exports javax.xml; @@ -53,12 +56,6 @@ module java.xml { exports org.xml.sax; exports org.xml.sax.ext; exports org.xml.sax.helpers; - exports com.sun.org.apache.xerces.internal.dom to - java.xml.ws; - exports com.sun.org.apache.xerces.internal.jaxp to - java.xml.ws; - exports com.sun.org.apache.xerces.internal.util to - java.xml.ws; exports com.sun.org.apache.xml.internal.dtm to java.xml.crypto; exports com.sun.org.apache.xml.internal.utils to diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/Attr.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/Attr.java index 8db99e9a6a1..7b125dedb8e 100644 --- a/jaxp/src/java.xml/share/classes/org/w3c/dom/Attr.java +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/Attr.java @@ -111,7 +111,9 @@ package org.w3c.dom; *

    The following table gives some examples of the relations between the * attribute value in the original document (parsed attribute), the value as * exposed in the DOM, and the serialization of the value: - * + *
    + * + * * * * * * + * + * * * @@ -126,7 +130,7 @@ package org.w3c.dom; *
    "x&#178;=5"
    * * * * * + * *
    Examples of the Original, Normalized and Serialized Values
    ExamplesParsed @@ -119,6 +121,8 @@ package org.w3c.dom; * Initial Attr.valueSerialized attribute value
    * Character reference - *
    "x\u00b2=5"
    + *
    "x²=5"
    *
    *
    "x&#178;=5"
    @@ -180,6 +184,7 @@ package org.w3c.dom; *
    Dependent on Implementation and Load OptionsDependent on Implementation and Load/Save Options
    *

    See also the Document Object Model (DOM) Level 3 Core Specification. */ diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/Document.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/Document.java index ab2d6e4f17e..c489fade718 100644 --- a/jaxp/src/java.xml/share/classes/org/w3c/dom/Document.java +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/Document.java @@ -353,37 +353,42 @@ public interface Document extends Node { * instantiate. * @return A new Element object with the following * attributes: - * + *
    + * + * * * * * + * + * * - * - * + * * * - * - * + * * * - * - * + * * * - * - * + * * * - * - * + * * + * *
    Attributes of the {@code Element} object
    AttributeValue
    Node.nodeName + * Node.nodeName * qualifiedName
    Node.namespaceURI + * Node.namespaceURI * namespaceURI
    Node.prefixprefix, extracted + * Node.prefixprefix, extracted * from qualifiedName, or null if there is * no prefix
    Node.localNamelocal name, extracted from + * Node.localNamelocal name, extracted from * qualifiedName
    Element.tagName + * Element.tagName * qualifiedName
    * @exception DOMException * INVALID_CHARACTER_ERR: Raised if the specified @@ -417,43 +422,48 @@ public interface Document extends Node { * @param qualifiedName The qualified name of the attribute to * instantiate. * @return A new Attr object with the following attributes: - * + *
    + * + * * * * * + * + * * - * - * + * + * * * - * - * + * * * - * - * * * - * - * + * * * - * - * + * * * - * - * + * * + * *
    Attributes of the {@code Attr} object
    * AttributeValue
    Node.nodeNamequalifiedNameNode.nodeNamequalifiedName
    + * * Node.namespaceURInamespaceURInamespaceURI
    + * * Node.prefixprefix, extracted from + * prefix, extracted from * qualifiedName, or null if there is no * prefix
    Node.localNamelocal name, extracted from + * Node.localNamelocal name, extracted from * qualifiedName
    Attr.name + * Attr.name * qualifiedName
    Node.nodeValuethe empty + * Node.nodeValuethe empty * string
    * @exception DOMException * INVALID_CHARACTER_ERR: Raised if the specified diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/Node.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/Node.java index a62ad94d91e..79cbada7935 100644 --- a/jaxp/src/java.xml/share/classes/org/w3c/dom/Node.java +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/Node.java @@ -61,104 +61,109 @@ package org.w3c.dom; *

    The values of nodeName, * nodeValue, and attributes vary according to the * node type as follows: - * + *
    + * + * * * * * * * + * + * * - * - * - * + * - * + * * * - * - * + * - * - * + * * * - * - * + * - * - * + * * * - * - * + * - * - * + * + * * * - * - * - * + * - * + * * * - * - * + * - * - * + * + * * * - * - * - * - * + * + * * * - * - * - * - * + * + * + * * * - * - * - * + * + * - * + * * * - * - * - * + * + * - * + * * * - * - * + * - * - * + * * * - * - * + * - * - * + * * + * *
    Interface table
    InterfacenodeNamenodeValueattributes
    + * * Attrsame as Attr.namesame as + * same as Attr.namesame as * Attr.valuenullnull
    CDATASection + * CDATASection * "#cdata-section"same as CharacterData.data, the + * same as CharacterData.data, the * content of the CDATA Sectionnullnull
    Comment + * Comment * "#comment"same as CharacterData.data, the + * same as CharacterData.data, the * content of the commentnullnull
    Document + * Document * "#document"nullnullnullnull
    + * * DocumentFragment"#document-fragment" + * "#document-fragment" * nullnullnull
    DocumentTypesame as + * DocumentTypesame as * DocumentType.namenullnullnullnull
    + * * Elementsame as Element.tagNamenull + * same as Element.tagNamenull * NamedNodeMap
    Entityentity namenull + * Entityentity namenull * null
    EntityReferencename of entity referenced + * EntityReferencename of entity referenced * nullnullnull
    Notationnotation name + * Notationnotation name * nullnullnull
    ProcessingInstructionsame + * ProcessingInstructionsame * as ProcessingInstruction.targetsame as + * same as * ProcessingInstruction.datanullnull
    Text + * Text * "#text"same as CharacterData.data, the content + * same as CharacterData.data, the content * of the text nodenullnull
    *

    See also the Document Object Model (DOM) Level 3 Core Specification. */ @@ -687,30 +692,35 @@ public interface Node { * textual content. *
    The string returned is made of the text content of this node * depending on its type, as defined below: - * + *
    + * + * * * * * + * + * * - * - * * * - * - * + * * * - * - * + * * + * *
    Node/Content table
    Node typeContent
    + * * ELEMENT_NODE, ATTRIBUTE_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, * DOCUMENT_FRAGMENT_NODEconcatenation of the textContent + * concatenation of the textContent * attribute value of every child node, excluding COMMENT_NODE and * PROCESSING_INSTRUCTION_NODE nodes. This is the empty string if the * node has no children.
    TEXT_NODE, CDATA_SECTION_NODE, COMMENT_NODE, + * TEXT_NODE, CDATA_SECTION_NODE, COMMENT_NODE, * PROCESSING_INSTRUCTION_NODEnodeValuenodeValue
    DOCUMENT_NODE, + * DOCUMENT_NODE, * DOCUMENT_TYPE_NODE, NOTATION_NODEnullnull
    * @exception DOMException * DOMSTRING_SIZE_ERR: Raised when it would return more characters than @@ -737,30 +747,35 @@ public interface Node { * textual content. *
    The string returned is made of the text content of this node * depending on its type, as defined below: - * + *
    + * + * * * * * + * + * * - * - * * * - * - * + * * * - * - * + * * + * *
    Node/Content table
    Node typeContent
    + * * ELEMENT_NODE, ATTRIBUTE_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, * DOCUMENT_FRAGMENT_NODEconcatenation of the textContent + * concatenation of the textContent * attribute value of every child node, excluding COMMENT_NODE and * PROCESSING_INSTRUCTION_NODE nodes. This is the empty string if the * node has no children.
    TEXT_NODE, CDATA_SECTION_NODE, COMMENT_NODE, + * TEXT_NODE, CDATA_SECTION_NODE, COMMENT_NODE, * PROCESSING_INSTRUCTION_NODEnodeValuenodeValue
    DOCUMENT_NODE, + * DOCUMENT_NODE, * DOCUMENT_TYPE_NODE, NOTATION_NODEnullnull
    * @exception DOMException * NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly. diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/bootstrap/package-info.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/bootstrap/package-info.java new file mode 100644 index 00000000000..e05d14562af --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/bootstrap/package-info.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides a factory for obtaining instances of DOMImplementation. + * + * @since 1.5 + */ + +package org.w3c.dom.bootstrap; diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/events/package-info.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/events/package-info.java new file mode 100644 index 00000000000..2792c7c3d3e --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/events/package-info.java @@ -0,0 +1,42 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + *

    + * Provides interfaces for DOM Level 2 Events. Refer to the + * + * Document Object Model (DOM) Level 2 Events Specification + * , the DOM Events module builds on + * + * DOM Level 2 Core Specification and + * + * DOM Level 2 Views Specification + * that gives to programs and scripts a generic event system. + * + * + * @since 1.5 + */ + +package org.w3c.dom.events; diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/ls/package-info.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/ls/package-info.java new file mode 100644 index 00000000000..b1369d3ccc8 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/ls/package-info.java @@ -0,0 +1,39 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + *

    + * Provides interfaces for DOM Level 3 Load and Save. Refer to the + * + * Document Object Model (DOM) Level 3 Load and Save Specification, + * the Load and Save interface allows programs and scripts to dynamically + * load the content of an XML document into a DOM document and serialize a DOM + * document into an XML document. + * + * + * @since 1.5 + */ + +package org.w3c.dom.ls; diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/package-info.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/package-info.java new file mode 100644 index 00000000000..e092bbebe40 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/package-info.java @@ -0,0 +1,38 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +/** + * Provides the interfaces for the Document Object Model (DOM). Supports the + * + * Document Object Model (DOM) Level 2 Core Specification, + * + * Document Object Model (DOM) Level 3 Core Specification, + * and + * Document Object Model (DOM) Level 3 Load and Save Specification. + * + * + * @since 1.4 + */ + +package org.w3c.dom; diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/package.html b/jaxp/src/java.xml/share/classes/org/w3c/dom/package.html deleted file mode 100644 index 673366bf326..00000000000 --- a/jaxp/src/java.xml/share/classes/org/w3c/dom/package.html +++ /dev/null @@ -1,13 +0,0 @@ - - -org.w3c.dom package - - -Provides the interfaces for the Document Object Model (DOM). Supports the -Document Object Model (DOM) Level 2 Core Specification, -Document Object Model (DOM) Level 3 Core Specification, -and Document Object Model (DOM) Level 3 Load and Save Specification. - -@since 1.4 - - diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/ranges/package-info.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/ranges/package-info.java new file mode 100644 index 00000000000..ff5d00dfe7c --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/ranges/package-info.java @@ -0,0 +1,37 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +/** + *

    + * Provides interfaces for DOM Level 2 Range. Refer to the + * + * Document Object Model (DOM) Level 2 Traversal and Range Specification, + * the Range module defines specialized interfaces for identifying + * and manipulating a range in a document. + * + * + * @since 1.5 + */ + +package org.w3c.dom.ranges; diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/ranges/package.html b/jaxp/src/java.xml/share/classes/org/w3c/dom/ranges/package.html deleted file mode 100644 index 83a1a986ae5..00000000000 --- a/jaxp/src/java.xml/share/classes/org/w3c/dom/ranges/package.html +++ /dev/null @@ -1,111 +0,0 @@ - - - W3C IPR SOFTWARE NOTICE - - -

    - Document Object Model Level 2 Traversal and Range is a - platform and language-neutral interfaces that allow programs - and scripts to dynamically traverse and identify a range of - content in a document. The Document Object Model Level 2 - Traversal and Range build on the Document Object Model Level 2 - Core. -

    -

    - The DOM Level 2 Traversal and Range specification is composed - of two modules. The two modules contain specialized interfaces - dedicated to traversing the document structure and identifying - and manipulating a range in a document. -

    -

    - W3C IPR SOFTWARE NOTICE -

    -

    - Copyright © 2000 World Wide Web - Consortium, (Massachusetts - Institute of Technology, Institut - National de Recherche en Informatique et en Automatique, Keio University). All Rights - Reserved. -

    -

    - The DOM bindings are published under the W3C Software Copyright Notice - and License. The software license requires "Notice of any changes or - modifications to the W3C files, including the date changes were made." - Consequently, modified versions of the DOM bindings must document that - they do not conform to the W3C standard; in the case of the IDL binding, - the pragma prefix can no longer be 'w3c.org'; in the case of the Java - binding, the package names can no longer be in the 'org.w3c' package. -

    -

    - Note: The original version of the W3C Software Copyright Notice - and License could be found at http://www.w3.org/Consortium/Legal/copyright-software-19980720 -

    -

    - Copyright © 1994-2000 World Wide Web - Consortium, (Massachusetts - Institute of Technology, Institut - National de Recherche en Informatique et en Automatique, Keio University). All Rights - Reserved. http://www.w3.org/Consortium/Legal/ -

    -

    - This W3C work (including software, documents, or other related items) is - being provided by the copyright holders under the following license. By - obtaining, using and/or copying this work, you (the licensee) agree that - you have read, understood, and will comply with the following terms and - conditions: -

    -

    - Permission to use, copy, and modify this software and its documentation, - with or without modification,  for any purpose and without fee or - royalty is hereby granted, provided that you include the following on ALL - copies of the software and documentation or portions thereof, including - modifications, that you make: -

    -
      -
    1. - The full text of this NOTICE in a location viewable to users of the - redistributed or derivative work. -
    2. -
    3. - Any pre-existing intellectual property disclaimers, notices, or terms - and conditions. If none exist, a short notice of the following form - (hypertext is preferred, text is permitted) should be used within the - body of any redistributed or derivative code: "Copyright © - [$date-of-software] World Wide Web - Consortium, (Massachusetts - Institute of Technology, Institut - National de Recherche en Informatique et en Automatique, Keio University). All Rights - Reserved. http://www.w3.org/Consortium/Legal/" -
    4. -
    5. - Notice of any changes or modifications to the W3C files, including the - date changes were made. (We recommend you provide URIs to the location - from which the code is derived.) -
    6. -
    -

    - THIS SOFTWARE AND DOCUMENTATION IS PROVIDED "AS IS," AND COPYRIGHT - HOLDERS MAKE NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, - INCLUDING BUT NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS - FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE OR - DOCUMENTATION WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS, - TRADEMARKS OR OTHER RIGHTS. -

    -

    - COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR - CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR - DOCUMENTATION. -

    -

    - The name and trademarks of copyright holders may NOT be used in - advertising or publicity pertaining to the software without specific, - written prior permission. Title to copyright in this software and any - associated documentation will at all times remain with copyright - holders. -

    - - diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/traversal/package-info.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/traversal/package-info.java new file mode 100644 index 00000000000..c532be864e7 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/traversal/package-info.java @@ -0,0 +1,36 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +/** + *

    + * Provides interfaces for DOM Level 2 Traversal. Refer to the + * + * Document Object Model (DOM) Level 2 Traversal and Range Specification, + * the Traversal module contains specialized interfaces dedicated to + * traversing the document structure. + * + * @since 1.5 + */ + +package org.w3c.dom.traversal; diff --git a/jaxp/src/java.xml/share/classes/org/w3c/dom/views/package-info.java b/jaxp/src/java.xml/share/classes/org/w3c/dom/views/package-info.java new file mode 100644 index 00000000000..a2b59efb1c4 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/w3c/dom/views/package-info.java @@ -0,0 +1,37 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides interfaces for DOM Level 2 Views. Refer to the + * + * Document Object Model (DOM) Level 2 Views Specification, + * the Views module allows programs and scripts to dynamically access and update + * the content of a representation of a document. + * + * + * @since 1.8 + */ + +package org.w3c.dom.views; diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/AttributeList.java b/jaxp/src/java.xml/share/classes/org/xml/sax/AttributeList.java index f79d5067c31..4a8c0b8394f 100644 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/AttributeList.java +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/AttributeList.java @@ -93,7 +93,7 @@ package org.xml.sax; * @see org.xml.sax.DocumentHandler#startElement startElement * @see org.xml.sax.helpers.AttributeListImpl AttributeListImpl */ -@Deprecated(since="5") +@Deprecated(since="1.5") public interface AttributeList { diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/DocumentHandler.java b/jaxp/src/java.xml/share/classes/org/xml/sax/DocumentHandler.java index 91cdac156ca..ef1093daeb3 100644 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/DocumentHandler.java +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/DocumentHandler.java @@ -68,7 +68,7 @@ package org.xml.sax; * @see org.xml.sax.Locator * @see org.xml.sax.HandlerBase */ -@Deprecated(since="5") +@Deprecated(since="1.5") public interface DocumentHandler { diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/HandlerBase.java b/jaxp/src/java.xml/share/classes/org/xml/sax/HandlerBase.java index cbbcf029aa0..05aed518445 100644 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/HandlerBase.java +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/HandlerBase.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -66,6 +66,7 @@ package org.xml.sax; * @see org.xml.sax.DocumentHandler * @see org.xml.sax.ErrorHandler */ +@Deprecated(since="1.5") public class HandlerBase implements EntityResolver, DTDHandler, DocumentHandler, ErrorHandler { diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/Parser.java b/jaxp/src/java.xml/share/classes/org/xml/sax/Parser.java index fef6e44843b..5da78c5164e 100644 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/Parser.java +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/Parser.java @@ -73,7 +73,7 @@ import java.util.Locale; * @see org.xml.sax.HandlerBase * @see org.xml.sax.InputSource */ -@Deprecated(since="5") +@Deprecated(since="1.5") public interface Parser { diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/ext/package-info.java b/jaxp/src/java.xml/share/classes/org/xml/sax/ext/package-info.java new file mode 100644 index 00000000000..a583af72e2d --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/ext/package-info.java @@ -0,0 +1,72 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides interfaces to SAX2 facilities that + * conformant SAX drivers won't necessarily support. + * + *

    + * See http://www.saxproject.org + * for more information about SAX. + * + *

    + * This package is independent of the SAX2 core, though the functionality + * exposed generally needs to be implemented within a parser core. + * That independence has several consequences: + * + *

      + * + *
    • SAX2 drivers are not required to recognize these handlers. + *
    • + * + *
    • You cannot assume that the class files will be present in every SAX2 + * installation.
    • + * + *
    • This package may be updated independently of SAX2 (i.e. new + * handlers and classes may be added without updating SAX2 itself).
    • + * + *
    • The new handlers are not implemented by the SAX2 + * org.xml.sax.helpers.DefaultHandler or + * org.xml.sax.helpers.XMLFilterImpl classes. + * You can subclass these if you need such behavior, or + * use the helper classes found here.
    • + * + *
    • The handlers need to be registered differently than core SAX2 + * handlers.
    • + * + *
    + * + *

    This package, SAX2-ext, is a standardized extension to SAX2. It is + * designed both to allow SAX parsers to pass certain types of information + * to applications, and to serve as a simple model for other SAX2 parser + * extension packages. Not all such extension packages should need to + * be recognized directly by parsers, however. + * As an example, most validation systems can be cleanly layered on top + * of parsers supporting the standardized SAX2 interfaces. + * + * @since 1.4 + */ + +package org.xml.sax.ext; diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/ext/package.html b/jaxp/src/java.xml/share/classes/org/xml/sax/ext/package.html deleted file mode 100644 index 74d63a5fba3..00000000000 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/ext/package.html +++ /dev/null @@ -1,46 +0,0 @@ - - - - -

    -This package contains interfaces to SAX2 facilities that -conformant SAX drivers won't necessarily support. - -

    See http://www.saxproject.org -for more information about SAX.

    - -

    This package is independent of the SAX2 core, though the functionality -exposed generally needs to be implemented within a parser core. -That independence has several consequences:

    - -
      - -
    • SAX2 drivers are not required to recognize these handlers. -
    • - -
    • You cannot assume that the class files will be present in every SAX2 -installation.
    • - -
    • This package may be updated independently of SAX2 (i.e. new -handlers and classes may be added without updating SAX2 itself).
    • - -
    • The new handlers are not implemented by the SAX2 -org.xml.sax.helpers.DefaultHandler or -org.xml.sax.helpers.XMLFilterImpl classes. -You can subclass these if you need such behavior, or -use the helper classes found here.
    • - -
    • The handlers need to be registered differently than core SAX2 -handlers.
    • - -
    - -

    This package, SAX2-ext, is a standardized extension to SAX2. It is -designed both to allow SAX parsers to pass certain types of information -to applications, and to serve as a simple model for other SAX2 parser -extension packages. Not all such extension packages should need to -be recognized directly by parsers, however. -As an example, most validation systems can be cleanly layered on top -of parsers supporting the standardized SAX2 interfaces.

    - - diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/AttributeListImpl.java b/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/AttributeListImpl.java index 41d9310f6e5..ad14c16a4b7 100644 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/AttributeListImpl.java +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/AttributeListImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -87,6 +87,7 @@ import java.util.Vector; * @see org.xml.sax.AttributeList * @see org.xml.sax.DocumentHandler#startElement */ +@Deprecated(since="1.5") public class AttributeListImpl implements AttributeList { diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/ParserFactory.java b/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/ParserFactory.java index 6e658867220..d3a30e87cb9 100644 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/ParserFactory.java +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/ParserFactory.java @@ -64,7 +64,7 @@ package org.xml.sax.helpers; * @version 2.0.1 (sax2r2) */ @SuppressWarnings( "deprecation" ) -@Deprecated(since="5") +@Deprecated(since="1.5") public class ParserFactory { private static SecuritySupport ss = new SecuritySupport(); diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/package-info.java b/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/package-info.java new file mode 100644 index 00000000000..6c1cbff3865 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/package-info.java @@ -0,0 +1,38 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * + * Provides helper classes, including + * support for bootstrapping SAX-based applications. + * + *

    + * See http://www.saxproject.org + * for more information about SAX. + * + * @since 1.4 + */ + +package org.xml.sax.helpers; diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/package.html b/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/package.html deleted file mode 100644 index 001f0e277aa..00000000000 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/helpers/package.html +++ /dev/null @@ -1,11 +0,0 @@ - - - - -

    This package contains "helper" classes, including -support for bootstrapping SAX-based applications. - -

    See http://www.saxproject.org -for more information about SAX.

    - - diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/package-info.java b/jaxp/src/java.xml/share/classes/org/xml/sax/package-info.java new file mode 100644 index 00000000000..419f3e7ab50 --- /dev/null +++ b/jaxp/src/java.xml/share/classes/org/xml/sax/package-info.java @@ -0,0 +1,327 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides the core SAX APIs. + * Some SAX1 APIs are deprecated to encourage integration of + * namespace-awareness into designs of new applications + * and into maintenance of existing infrastructure. + * + *

    + * See http://www.saxproject.org + * for more information about SAX. + * + * + *

    SAX2 Standard Feature Flags

    + * + *

    + * One of the essential characteristics of SAX2 is that it added + * feature flags which can be used to examine and perhaps modify + * parser modes, in particular modes such as validation. + * Since features are identified by (absolute) URIs, anyone + * can define such features. + * Currently defined standard feature URIs have the prefix + * http://xml.org/sax/features/ before an identifier such as + * validation. Turn features on or off using + * setFeature. Those standard identifiers are: + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
    Feature IDAccessDefaultDescription
    external-general-entitiesread/writeunspecified Reports whether this parser processes external + * general entities; always true if validating. + *
    external-parameter-entitiesread/writeunspecified Reports whether this parser processes external + * parameter entities; always true if validating. + *
    is-standalone(parsing) read-only, (not parsing) nonenot applicable May be examined only during a parse, after the + * startDocument() callback has been completed; read-only. + * The value is true if the document specified standalone="yes" in + * its XML declaration, and otherwise is false. + *
    lexical-handler/parameter-entitiesread/writeunspecified A value of "true" indicates that the LexicalHandler will report + * the beginning and end of parameter entities. + *
    namespacesread/writetrue A value of "true" indicates namespace URIs and unprefixed local names + * for element and attribute names will be available. + *
    namespace-prefixesread/writefalse A value of "true" indicates that XML qualified names (with prefixes) and + * attributes (including xmlns* attributes) will be available. + *
    resolve-dtd-urisread/writetrue A value of "true" indicates that system IDs in declarations will + * be absolutized (relative to their base URIs) before reporting. + * (That is the default behavior for all SAX2 XML parsers.) + * A value of "false" indicates those IDs will not be absolutized; + * parsers will provide the base URI from + * Locator.getSystemId(). + * This applies to system IDs passed in
      + *
    • DTDHandler.notationDecl(), + *
    • DTDHandler.unparsedEntityDecl(), and + *
    • DeclHandler.externalEntityDecl(). + *
    + * It does not apply to EntityResolver.resolveEntity(), + * which is not used to report declarations, or to + * LexicalHandler.startDTD(), which already provides + * the non-absolutized URI. + *
    string-interningread/writeunspecified Has a value of "true" if all XML names (for elements, prefixes, + * attributes, entities, notations, and local names), + * as well as Namespace URIs, will have been interned + * using java.lang.String.intern. This supports fast + * testing of equality/inequality against string constants, + * rather than forcing slower calls to String.equals(). + *
    unicode-normalization-checkingread/writefalse Controls whether the parser reports Unicode normalization + * errors as described in section 2.13 and Appendix B of the + * XML 1.1 Recommendation. If true, Unicode normalization + * errors are reported using the ErrorHandler.error() callback. + * Such errors are not fatal in themselves (though, obviously, + * other Unicode-related encoding errors may be). + *
    use-attributes2read-onlynot applicable Returns "true" if the Attributes objects passed by + * this parser in ContentHandler.startElement() + * implement the org.xml.sax.ext.Attributes2 interface. + * That interface exposes additional DTD-related information, + * such as whether the attribute was specified in the + * source text rather than defaulted. + *
    use-locator2read-onlynot applicable Returns "true" if the Locator objects passed by + * this parser in ContentHandler.setDocumentLocator() + * implement the org.xml.sax.ext.Locator2 interface. + * That interface exposes additional entity information, + * such as the character encoding and XML version used. + *
    use-entity-resolver2read/writetrue Returns "true" if, when setEntityResolver is given + * an object implementing the org.xml.sax.ext.EntityResolver2 interface, + * those new methods will be used. + * Returns "false" to indicate that those methods will not be used. + *
    validationread/writeunspecified Controls whether the parser is reporting all validity + * errors; if true, all external entities will be read. + *
    xmlns-urisread/writefalse Controls whether, when the namespace-prefixes feature + * is set, the parser treats namespace declaration attributes as + * being in the http://www.w3.org/2000/xmlns/ namespace. + * By default, SAX2 conforms to the original "Namespaces in XML" + * Recommendation, which explicitly states that such attributes are + * not in any namespace. + * Setting this optional flag to "true" makes the SAX2 events conform to + * a later backwards-incompatible revision of that recommendation, + * placing those attributes in a namespace. + *
    xml-1.1read-onlynot applicable Returns "true" if the parser supports both XML 1.1 and XML 1.0. + * Returns "false" if the parser supports only XML 1.0. + *
    + * + *

    + * Support for the default values of the + * namespaces and namespace-prefixes + * properties is required. + * Support for any other feature flags is entirely optional. + * + * + *

    + * For default values not specified by SAX2, + * each XMLReader implementation specifies its default, + * or may choose not to expose the feature flag. + * Unless otherwise specified here, + * implementations may support changing current values + * of these standard feature flags, but not while parsing. + * + * + *

    SAX2 Standard Handler and Property IDs

    + * + *

    + * For parser interface characteristics that are described + * as objects, a separate namespace is defined. The + * objects in this namespace are again identified by URI, and + * the standard property URIs have the prefix + * http://xml.org/sax/properties/ before an identifier such as + * lexical-handler or + * dom-node. Manage those properties using + * setProperty(). Those identifiers are: + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
    Property IDDescription
    declaration-handler Used to see most DTD declarations except those treated + * as lexical ("document element name is ...") or which are + * mandatory for all SAX parsers (DTDHandler). + * The Object must implement org.xml.sax.ext.DeclHandler. + *
    document-xml-version May be examined only during a parse, after the startDocument() + * callback has been completed; read-only. This property is a + * literal string describing the actual XML version of the document, + * such as "1.0" or "1.1". + *
    dom-node For "DOM Walker" style parsers, which ignore their + * parser.parse() parameters, this is used to + * specify the DOM (sub)tree being walked by the parser. + * The Object must implement the + * org.w3c.dom.Node interface. + *
    lexical-handler Used to see some syntax events that are essential in some + * applications: comments, CDATA delimiters, selected general + * entity inclusions, and the start and end of the DTD + * (and declaration of document element name). + * The Object must implement org.xml.sax.ext.LexicalHandler. + *
    xml-string Readable only during a parser callback, this exposes a TBS + * chunk of characters responsible for the current event. + *
    + * + *

    + * All of these standard properties are optional. + * XMLReader implementations are not required to support them. + * + * + * @since 1.4 + */ + +package org.xml.sax; diff --git a/jaxp/src/java.xml/share/classes/org/xml/sax/package.html b/jaxp/src/java.xml/share/classes/org/xml/sax/package.html deleted file mode 100644 index 2af5e4cd47d..00000000000 --- a/jaxp/src/java.xml/share/classes/org/xml/sax/package.html +++ /dev/null @@ -1,297 +0,0 @@ - - - - -

    This package provides the core SAX APIs. -Some SAX1 APIs are deprecated to encourage integration of -namespace-awareness into designs of new applications -and into maintenance of existing infrastructure.

    - -

    See http://www.saxproject.org -for more information about SAX.

    - - -

    SAX2 Standard Feature Flags

    - -

    One of the essential characteristics of SAX2 is that it added -feature flags which can be used to examine and perhaps modify -parser modes, in particular modes such as validation. -Since features are identified by (absolute) URIs, anyone -can define such features. -Currently defined standard feature URIs have the prefix -http://xml.org/sax/features/ before an identifier such as -validation. Turn features on or off using -setFeature. Those standard identifiers are:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Feature IDAccessDefaultDescription
    external-general-entitiesread/writeunspecified Reports whether this parser processes external - general entities; always true if validating. -
    external-parameter-entitiesread/writeunspecified Reports whether this parser processes external - parameter entities; always true if validating. -
    is-standalone(parsing) read-only, (not parsing) nonenot applicable May be examined only during a parse, after the - startDocument() callback has been completed; read-only. - The value is true if the document specified standalone="yes" in - its XML declaration, and otherwise is false. -
    lexical-handler/parameter-entitiesread/writeunspecified A value of "true" indicates that the LexicalHandler will report - the beginning and end of parameter entities. -
    namespacesread/writetrue A value of "true" indicates namespace URIs and unprefixed local names - for element and attribute names will be available. -
    namespace-prefixesread/writefalse A value of "true" indicates that XML qualified names (with prefixes) and - attributes (including xmlns* attributes) will be available. -
    resolve-dtd-urisread/writetrue A value of "true" indicates that system IDs in declarations will - be absolutized (relative to their base URIs) before reporting. - (That is the default behavior for all SAX2 XML parsers.) - A value of "false" indicates those IDs will not be absolutized; - parsers will provide the base URI from - Locator.getSystemId(). - This applies to system IDs passed in
      -
    • DTDHandler.notationDecl(), -
    • DTDHandler.unparsedEntityDecl(), and -
    • DeclHandler.externalEntityDecl(). -
    - It does not apply to EntityResolver.resolveEntity(), - which is not used to report declarations, or to - LexicalHandler.startDTD(), which already provides - the non-absolutized URI. -
    string-interningread/writeunspecified Has a value of "true" if all XML names (for elements, prefixes, - attributes, entities, notations, and local names), - as well as Namespace URIs, will have been interned - using java.lang.String.intern. This supports fast - testing of equality/inequality against string constants, - rather than forcing slower calls to String.equals(). -
    unicode-normalization-checkingread/writefalse Controls whether the parser reports Unicode normalization - errors as described in section 2.13 and Appendix B of the - XML 1.1 Recommendation. If true, Unicode normalization - errors are reported using the ErrorHandler.error() callback. - Such errors are not fatal in themselves (though, obviously, - other Unicode-related encoding errors may be). -
    use-attributes2read-onlynot applicable Returns "true" if the Attributes objects passed by - this parser in ContentHandler.startElement() - implement the org.xml.sax.ext.Attributes2 interface. - That interface exposes additional DTD-related information, - such as whether the attribute was specified in the - source text rather than defaulted. -
    use-locator2read-onlynot applicable Returns "true" if the Locator objects passed by - this parser in ContentHandler.setDocumentLocator() - implement the org.xml.sax.ext.Locator2 interface. - That interface exposes additional entity information, - such as the character encoding and XML version used. -
    use-entity-resolver2read/writetrue Returns "true" if, when setEntityResolver is given - an object implementing the org.xml.sax.ext.EntityResolver2 interface, - those new methods will be used. - Returns "false" to indicate that those methods will not be used. -
    validationread/writeunspecified Controls whether the parser is reporting all validity - errors; if true, all external entities will be read. -
    xmlns-urisread/writefalse Controls whether, when the namespace-prefixes feature - is set, the parser treats namespace declaration attributes as - being in the http://www.w3.org/2000/xmlns/ namespace. - By default, SAX2 conforms to the original "Namespaces in XML" - Recommendation, which explicitly states that such attributes are - not in any namespace. - Setting this optional flag to "true" makes the SAX2 events conform to - a later backwards-incompatible revision of that recommendation, - placing those attributes in a namespace. -
    xml-1.1read-onlynot applicable Returns "true" if the parser supports both XML 1.1 and XML 1.0. - Returns "false" if the parser supports only XML 1.0. -
    - -

    Support for the default values of the -namespaces and namespace-prefixes -properties is required. -Support for any other feature flags is entirely optional. -

    - -

    For default values not specified by SAX2, -each XMLReader implementation specifies its default, -or may choose not to expose the feature flag. -Unless otherwise specified here, -implementations may support changing current values -of these standard feature flags, but not while parsing. -

    - -

    SAX2 Standard Handler and Property IDs

    - -

    For parser interface characteristics that are described -as objects, a separate namespace is defined. The -objects in this namespace are again identified by URI, and -the standard property URIs have the prefix -http://xml.org/sax/properties/ before an identifier such as -lexical-handler or -dom-node. Manage those properties using -setProperty(). Those identifiers are:

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Property IDDescription
    declaration-handler Used to see most DTD declarations except those treated - as lexical ("document element name is ...") or which are - mandatory for all SAX parsers (DTDHandler). - The Object must implement org.xml.sax.ext.DeclHandler. -
    document-xml-version May be examined only during a parse, after the startDocument() - callback has been completed; read-only. This property is a - literal string describing the actual XML version of the document, - such as "1.0" or "1.1". -
    dom-node For "DOM Walker" style parsers, which ignore their - parser.parse() parameters, this is used to - specify the DOM (sub)tree being walked by the parser. - The Object must implement the - org.w3c.dom.Node interface. -
    lexical-handler Used to see some syntax events that are essential in some - applications: comments, CDATA delimiters, selected general - entity inclusions, and the start and end of the DTD - (and declaration of document element name). - The Object must implement org.xml.sax.ext.LexicalHandler. -
    xml-string Readable only during a parser callback, this exposes a TBS - chunk of characters responsible for the current event.
    - -

    All of these standard properties are optional; -XMLReader implementations need not support them. -

    - - diff --git a/jaxp/src/java.xml/share/legal/bcel.md b/jaxp/src/java.xml/share/legal/bcel.md index 3ac4532e1f6..8c6a3cf0e40 100644 --- a/jaxp/src/java.xml/share/legal/bcel.md +++ b/jaxp/src/java.xml/share/legal/bcel.md @@ -1,6 +1,6 @@ -## Apache Byte Code Engineering Library v5.2 +## Apache Byte Code Engineering Library (BCEL) v5.2 -### Notice +### Apache BCEL Notice
     
         =========================================================================
    diff --git a/jaxp/src/java.xml/share/legal/dom.md b/jaxp/src/java.xml/share/legal/dom.md
    index de63edd485c..b0fb1ae76d4 100644
    --- a/jaxp/src/java.xml/share/legal/dom.md
    +++ b/jaxp/src/java.xml/share/legal/dom.md
    @@ -1,6 +1,6 @@
    -## DOM Level 3 core specification, v1.0
    +## DOM Level 3 Core Specification v1.0
     
    -## W3C License
    +### W3C License
     
     
     W3C SOFTWARE NOTICE AND LICENSE
    diff --git a/jaxp/src/java.xml/share/legal/xalan.md b/jaxp/src/java.xml/share/legal/xalan.md
    index 5c1749b3721..94b293164df 100644
    --- a/jaxp/src/java.xml/share/legal/xalan.md
    +++ b/jaxp/src/java.xml/share/legal/xalan.md
    @@ -1,6 +1,6 @@
     ## Apache Xalan v2.7.1
     
    -### Notice
    +### Apache Xalan Notice
     
     
         ======================================================================================
    diff --git a/jaxp/src/java.xml/share/legal/xerces.md b/jaxp/src/java.xml/share/legal/xerces.md
    index 438419b13c9..ff0167bc835 100644
    --- a/jaxp/src/java.xml/share/legal/xerces.md
    +++ b/jaxp/src/java.xml/share/legal/xerces.md
    @@ -1,7 +1,7 @@
     ## Apache Xerces v2.11.0
     
    -### Notice
    -
    +### Apache Xerces Notice
    +
         =========================================================================
         == NOTICE file corresponding to section 4(d) of the Apache License, ==
         == Version 2.0, in this case for the Apache Xerces Java distribution. ==
    @@ -17,6 +17,7 @@
         - voluntary contributions made by Paul Eng on behalf of the
         Apache Software Foundation that were originally developed at iClick, Inc.,
         software copyright (c) 1999.
    +
    ### Apache 2.0 License
    diff --git a/jaxp/src/java.xml/share/legal/xmlresolver.md b/jaxp/src/java.xml/share/legal/xmlresolver.md
    index cf18bb439b3..696f8d3e148 100644
    --- a/jaxp/src/java.xml/share/legal/xmlresolver.md
    +++ b/jaxp/src/java.xml/share/legal/xmlresolver.md
    @@ -1,6 +1,6 @@
     ## Apache XML Resolver Library v1.2
     
    -### Notice
    +### Apache XML Resolver Notice
     
     
     Apache XML Commons Resolver
    diff --git a/jaxp/src/jdk.xml.dom/share/classes/module-info.java b/jaxp/src/jdk.xml.dom/share/classes/module-info.java
    index 6828629b489..24b90c723f5 100644
    --- a/jaxp/src/jdk.xml.dom/share/classes/module-info.java
    +++ b/jaxp/src/jdk.xml.dom/share/classes/module-info.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -23,6 +23,13 @@
      * questions.
      */
     
    +/**
    + * Defines the subset of the W3C Document Object Model (DOM) API that is not part
    + * of the Java SE API.
    + *
    + * @moduleGraph
    + * @since 9
    + */
     module jdk.xml.dom {
         requires transitive java.xml;
         exports org.w3c.dom.css;
    diff --git a/jaxp/test/TEST.ROOT b/jaxp/test/TEST.ROOT
    index 5f7295efea1..8ad82b29422 100644
    --- a/jaxp/test/TEST.ROOT
    +++ b/jaxp/test/TEST.ROOT
    @@ -23,7 +23,14 @@ modules=java.xml
     groups=TEST.groups
     
     # Minimum jtreg version
    -requiredVersion=4.2 b04
    +requiredVersion=4.2 b07
    +
    +# Path to libraries in the topmost test directory. This is needed so @library
    +# does not need ../../ notation to reach them
    +external.lib.roots = ../../
     
     # Use new module options
     useNewOptions=true
    +
    +# Use --patch-module instead of -Xmodule:
    +useNewPatchModule=true
    diff --git a/jaxp/test/javax/xml/jaxp/functional/catalog/DeferFeatureTest.java b/jaxp/test/javax/xml/jaxp/functional/catalog/DeferFeatureTest.java
    index f9e25de8bd6..2ee5dafa901 100644
    --- a/jaxp/test/javax/xml/jaxp/functional/catalog/DeferFeatureTest.java
    +++ b/jaxp/test/javax/xml/jaxp/functional/catalog/DeferFeatureTest.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -27,14 +27,16 @@ import static catalog.CatalogTestUtils.DEFER_FALSE;
     import static catalog.CatalogTestUtils.DEFER_TRUE;
     import static catalog.CatalogTestUtils.getCatalogPath;
     import static javax.xml.catalog.CatalogFeatures.Feature.DEFER;
    -import static javax.xml.catalog.CatalogManager.catalog;
     import static jaxp.library.JAXPTestUtilities.runWithAllPerm;
     import static jaxp.library.JAXPTestUtilities.tryRunWithAllPerm;
     
     import java.lang.reflect.Method;
     
     import javax.xml.catalog.Catalog;
    +import javax.xml.catalog.CatalogException;
     import javax.xml.catalog.CatalogFeatures;
    +import javax.xml.catalog.CatalogManager;
    +import javax.xml.catalog.CatalogResolver;
     
     import org.testng.Assert;
     import org.testng.annotations.DataProvider;
    @@ -43,7 +45,7 @@ import org.testng.annotations.Test;
     
     /*
      * @test
    - * @bug 8077931
    + * @bug 8077931 8176405
      * @library /javax/xml/jaxp/libs
      * @modules java.xml/javax.xml.catalog:open
      * @run testng/othervm -DrunSecMngr=true catalog.DeferFeatureTest
    @@ -61,6 +63,18 @@ public class DeferFeatureTest {
             Assert.assertEquals(loadedCatalogCount(catalog), catalogCount);
         }
     
    +    @Test(dataProvider = "testDeferFeatureByResolve")
    +    public void testDeferFeatureByResolve(Catalog catalog, int catalogCount)
    +            throws Exception {
    +        CatalogResolver cr = createResolver(catalog);
    +        // trigger loading alternative catalogs
    +        try {
    +            cr.resolveEntity("-//REMOTE//DTD ALICE DOCALICE", "http://remote/dtd/alice/");
    +        } catch (CatalogException ce) {}
    +
    +        Assert.assertEquals(loadedCatalogCount(catalog), catalogCount);
    +    }
    +
         @DataProvider(name = "catalog-countOfLoadedCatalogFile")
         public Object[][] data() {
             return new Object[][]{
    @@ -73,12 +87,23 @@ public class DeferFeatureTest {
                 {createCatalog(createDeferFeature(DEFER_FALSE)), 4}};
         }
     
    +    @DataProvider(name = "testDeferFeatureByResolve")
    +    public Object[][] getData() {
    +        return new Object[][]{
    +            {createCatalog(createDeferFeature(DEFER_TRUE)), 4}
    +        };
    +    }
    +
         private CatalogFeatures createDeferFeature(String defer) {
             return CatalogFeatures.builder().with(DEFER, defer).build();
         }
     
         private Catalog createCatalog(CatalogFeatures feature) {
    -        return catalog(feature, getCatalogPath("deferFeature.xml"));
    +        return CatalogManager.catalog(feature, getCatalogPath("deferFeature.xml"));
    +    }
    +
    +    private CatalogResolver createResolver(Catalog catalog) {
    +        return CatalogManager.catalogResolver(catalog);
         }
     
         private int loadedCatalogCount(Catalog catalog) throws Exception {
    diff --git a/jaxp/test/javax/xml/jaxp/functional/org/w3c/dom/ptests/NodeTest.java b/jaxp/test/javax/xml/jaxp/functional/org/w3c/dom/ptests/NodeTest.java
    index bb4d6b3574a..264ad06a95f 100644
    --- a/jaxp/test/javax/xml/jaxp/functional/org/w3c/dom/ptests/NodeTest.java
    +++ b/jaxp/test/javax/xml/jaxp/functional/org/w3c/dom/ptests/NodeTest.java
    @@ -22,6 +22,7 @@
      */
     package org.w3c.dom.ptests;
     
    +import static jaxp.library.JAXPTestUtilities.USER_DIR;
     import static jaxp.library.JAXPTestUtilities.compareWithGold;
     import static jaxp.library.JAXPTestUtilities.tryRunWithTmpPermission;
     import static org.testng.Assert.assertEquals;
    @@ -157,7 +158,7 @@ public class NodeTest {
             Element element = (Element) document.getElementsByTagName("sender").item(0);
             parentElement.insertBefore(createTestDocumentFragment(document), element);
     
    -        String outputfile = "InsertBefore.out";
    +        String outputfile = USER_DIR + "InsertBefore.out";
             String goldfile = GOLDEN_DIR + "InsertBeforeGF.out";
             tryRunWithTmpPermission(() -> outputXml(document, outputfile), new PropertyPermission("user.dir", "read"));
             assertTrue(compareWithGold(goldfile, outputfile));
    @@ -175,7 +176,7 @@ public class NodeTest {
             Element element = (Element) document.getElementsByTagName("sender").item(0);
             parentElement.replaceChild(createTestDocumentFragment(document), element);
     
    -        String outputfile = "ReplaceChild3.out";
    +        String outputfile = USER_DIR + "ReplaceChild3.out";
             String goldfile = GOLDEN_DIR + "ReplaceChild3GF.out";
             tryRunWithTmpPermission(() -> outputXml(document, outputfile), new PropertyPermission("user.dir", "read"));
             assertTrue(compareWithGold(goldfile, outputfile));
    diff --git a/jaxp/test/javax/xml/jaxp/functional/test/astro/DocumentLSTest.java b/jaxp/test/javax/xml/jaxp/functional/test/astro/DocumentLSTest.java
    index acfe988c13a..673674b9e65 100644
    --- a/jaxp/test/javax/xml/jaxp/functional/test/astro/DocumentLSTest.java
    +++ b/jaxp/test/javax/xml/jaxp/functional/test/astro/DocumentLSTest.java
    @@ -22,6 +22,7 @@
      */
     package test.astro;
     
    +import static jaxp.library.JAXPTestUtilities.USER_DIR;
     import static jaxp.library.JAXPTestUtilities.filenameToURL;
     import static org.testng.Assert.assertEquals;
     import static org.testng.Assert.assertNotNull;
    @@ -130,7 +131,7 @@ public class DocumentLSTest {
             impl = (DOMImplementationLS) db.getDOMImplementation();
             LSSerializer domSerializer = impl.createLSSerializer();
             MyDOMOutput mydomoutput = new MyDOMOutput();
    -        try (OutputStream os = new FileOutputStream("test.out")) {
    +        try (OutputStream os = new FileOutputStream(USER_DIR + "test.out")) {
                 mydomoutput.setByteStream(os);
                 mydomoutput.setEncoding("UTF-8");
                 assertTrue(domSerializer.write(doc, mydomoutput));
    diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Asserts.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Asserts.java
    deleted file mode 100644
    index 594b12e3ede..00000000000
    --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Asserts.java
    +++ /dev/null
    @@ -1,566 +0,0 @@
    -/*
    - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
    - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    - *
    - * This code is free software; you can redistribute it and/or modify it
    - * under the terms of the GNU General Public License version 2 only, as
    - * published by the Free Software Foundation.
    - *
    - * This code is distributed in the hope that it will be useful, but WITHOUT
    - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    - * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    - * version 2 for more details (a copy is included in the LICENSE file that
    - * accompanied this code).
    - *
    - * You should have received a copy of the GNU General Public License version
    - * 2 along with this work; if not, write to the Free Software Foundation,
    - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    - *
    - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    - * or visit www.oracle.com if you need additional information or have any
    - * questions.
    - */
    -
    -package jdk.testlibrary;
    -
    -import java.util.Objects;
    -
    -/**
    - * Asserts that can be used for verifying assumptions in tests.
    - *
    - * An assertion will throw a {@link RuntimeException} if the assertion isn't true.
    - * All the asserts can be imported into a test by using a static import:
    - *
    - * 
    - * {@code
    - * import static jdk.testlibrary.Asserts.*;
    - * }
    - *
    - * Always provide a message describing the assumption if the line number of the
    - * failing assertion isn't enough to understand why the assumption failed. For
    - * example, if the assertion is in a loop or in a method that is called
    - * multiple times, then the line number won't provide enough context to
    - * understand the failure.
    - * 
    - * - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib} - */ -@Deprecated -public class Asserts { - - /** - * Shorthand for {@link #assertLessThan(Comparable, Comparable)}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertLessThan(Comparable, Comparable) - */ - public static > void assertLT(T lhs, T rhs) { - assertLessThan(lhs, rhs); - } - - /** - * Shorthand for {@link #assertLessThan(Comparable, Comparable, String)}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @see #assertLessThan(Comparable, Comparable, String) - */ - public static > void assertLT(T lhs, T rhs, String msg) { - assertLessThan(lhs, rhs, msg); - } - - /** - * Calls {@link #assertLessThan(Comparable, Comparable, String)} with a default message. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertLessThan(Comparable, Comparable, String) - */ - public static > void assertLessThan(T lhs, T rhs) { - assertLessThan(lhs, rhs, null); - } - - /** - * Asserts that {@code lhs} is less than {@code rhs}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static >void assertLessThan(T lhs, T rhs, String msg) { - if (!(compare(lhs, rhs, msg) < 0)) { - msg = Objects.toString(msg, "assertLessThan") - + ": expected that " + Objects.toString(lhs) - + " < " + Objects.toString(rhs); - fail(msg); - } - } - - /** - * Shorthand for {@link #assertLessThanOrEqual(Comparable, Comparable)}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertLessThanOrEqual(Comparable, Comparable) - */ - public static > void assertLTE(T lhs, T rhs) { - assertLessThanOrEqual(lhs, rhs); - } - - /** - * Shorthand for {@link #assertLessThanOrEqual(Comparable, Comparable, String)}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @see #assertLessThanOrEqual(Comparable, Comparable, String) - */ - public static > void assertLTE(T lhs, T rhs, String msg) { - assertLessThanOrEqual(lhs, rhs, msg); - } - - /** - * Calls {@link #assertLessThanOrEqual(Comparable, Comparable, String)} with a default message. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertLessThanOrEqual(Comparable, Comparable, String) - */ - public static > void assertLessThanOrEqual(T lhs, T rhs) { - assertLessThanOrEqual(lhs, rhs, null); - } - - /** - * Asserts that {@code lhs} is less than or equal to {@code rhs}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static > void assertLessThanOrEqual(T lhs, T rhs, String msg) { - if (!(compare(lhs, rhs, msg) <= 0)) { - msg = Objects.toString(msg, "assertLessThanOrEqual") - + ": expected that " + Objects.toString(lhs) - + " <= " + Objects.toString(rhs); - fail(msg); - } - } - - /** - * Shorthand for {@link #assertEquals(Object, Object)}. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertEquals(Object, Object) - */ - public static void assertEQ(Object lhs, Object rhs) { - assertEquals(lhs, rhs); - } - - /** - * Shorthand for {@link #assertEquals(Object, Object, String)}. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @see #assertEquals(Object, Object, String) - */ - public static void assertEQ(Object lhs, Object rhs, String msg) { - assertEquals(lhs, rhs, msg); - } - - /** - * Calls {@link #assertEquals(java.lang.Object, java.lang.Object, java.lang.String)} with a default message. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertEquals(Object, Object, String) - */ - public static void assertEquals(Object lhs, Object rhs) { - assertEquals(lhs, rhs, null); - } - - /** - * Asserts that {@code lhs} is equal to {@code rhs}. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static void assertEquals(Object lhs, Object rhs, String msg) { - if ((lhs != rhs) && ((lhs == null) || !(lhs.equals(rhs)))) { - msg = Objects.toString(msg, "assertEquals") - + ": expected " + Objects.toString(lhs) - + " to equal " + Objects.toString(rhs); - fail(msg); - } - } - - /** - * Calls {@link #assertSame(java.lang.Object, java.lang.Object, java.lang.String)} with a default message. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertSame(Object, Object, String) - */ - public static void assertSame(Object lhs, Object rhs) { - assertSame(lhs, rhs, null); - } - - /** - * Asserts that {@code lhs} is the same as {@code rhs}. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static void assertSame(Object lhs, Object rhs, String msg) { - if (lhs != rhs) { - msg = Objects.toString(msg, "assertSame") - + ": expected " + Objects.toString(lhs) - + " to equal " + Objects.toString(rhs); - fail(msg); - } - } - - /** - * Shorthand for {@link #assertGreaterThanOrEqual(Comparable, Comparable)}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertGreaterThanOrEqual(Comparable, Comparable) - */ - public static > void assertGTE(T lhs, T rhs) { - assertGreaterThanOrEqual(lhs, rhs); - } - - /** - * Shorthand for {@link #assertGreaterThanOrEqual(Comparable, Comparable, String)}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @see #assertGreaterThanOrEqual(Comparable, Comparable, String) - */ - public static > void assertGTE(T lhs, T rhs, String msg) { - assertGreaterThanOrEqual(lhs, rhs, msg); - } - - /** - * Calls {@link #assertGreaterThanOrEqual(Comparable, Comparable, String)} with a default message. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertGreaterThanOrEqual(Comparable, Comparable, String) - */ - public static > void assertGreaterThanOrEqual(T lhs, T rhs) { - assertGreaterThanOrEqual(lhs, rhs, null); - } - - /** - * Asserts that {@code lhs} is greater than or equal to {@code rhs}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static > void assertGreaterThanOrEqual(T lhs, T rhs, String msg) { - if (!(compare(lhs, rhs, msg) >= 0)) { - msg = Objects.toString(msg, "assertGreaterThanOrEqual") - + ": expected " + Objects.toString(lhs) - + " >= " + Objects.toString(rhs); - fail(msg); - } - } - - /** - * Shorthand for {@link #assertGreaterThan(Comparable, Comparable)}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertGreaterThan(Comparable, Comparable) - */ - public static > void assertGT(T lhs, T rhs) { - assertGreaterThan(lhs, rhs); - } - - /** - * Shorthand for {@link #assertGreaterThan(Comparable, Comparable, String)}. - * - * @param a type - * @param lhs the left hand value - * @param rhs the right hand value - * @param msg A description of the assumption; {@code null} for a default message. - * @see #assertGreaterThan(Comparable, Comparable, String) - */ - public static > void assertGT(T lhs, T rhs, String msg) { - assertGreaterThan(lhs, rhs, msg); - } - - /** - * Calls {@link #assertGreaterThan(Comparable, Comparable, String)} with a default message. - * - * @param a type - * @param lhs the left hand value - * @param rhs the right hand value - * @see #assertGreaterThan(Comparable, Comparable, String) - */ - public static > void assertGreaterThan(T lhs, T rhs) { - assertGreaterThan(lhs, rhs, null); - } - - /** - * Asserts that {@code lhs} is greater than {@code rhs}. - * - * @param a type - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static > void assertGreaterThan(T lhs, T rhs, String msg) { - if (!(compare(lhs, rhs, msg) > 0)) { - msg = Objects.toString(msg, "assertGreaterThan") - + ": expected " + Objects.toString(lhs) - + " > " + Objects.toString(rhs); - fail(msg); - } - } - - /** - * Shorthand for {@link #assertNotEquals(Object, Object)}. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertNotEquals(Object, Object) - */ - public static void assertNE(Object lhs, Object rhs) { - assertNotEquals(lhs, rhs); - } - - /** - * Shorthand for {@link #assertNotEquals(Object, Object, String)}. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @see #assertNotEquals(Object, Object, String) - */ - public static void assertNE(Object lhs, Object rhs, String msg) { - assertNotEquals(lhs, rhs, msg); - } - - /** - * Calls {@link #assertNotEquals(Object, Object, String)} with a default message. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @see #assertNotEquals(Object, Object, String) - */ - public static void assertNotEquals(Object lhs, Object rhs) { - assertNotEquals(lhs, rhs, null); - } - - /** - * Asserts that {@code lhs} is not equal to {@code rhs}. - * - * @param lhs The left hand side of the comparison. - * @param rhs The right hand side of the comparison. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static void assertNotEquals(Object lhs, Object rhs, String msg) { - if ((lhs == rhs) || (lhs != null && lhs.equals(rhs))) { - msg = Objects.toString(msg, "assertNotEquals") - + ": expected " + Objects.toString(lhs) - + " to not equal " + Objects.toString(rhs); - fail(msg); - } - } - - /** - * Calls {@link #assertNull(Object, String)} with a default message. - * - * @param o The reference assumed to be null. - * @see #assertNull(Object, String) - */ - public static void assertNull(Object o) { - assertNull(o, null); - } - - /** - * Asserts that {@code o} is null. - * - * @param o The reference assumed to be null. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static void assertNull(Object o, String msg) { - assertEquals(o, null, msg); - } - - /** - * Calls {@link #assertNotNull(Object, String)} with a default message. - * - * @param o The reference assumed not to be null, - * @see #assertNotNull(Object, String) - */ - public static void assertNotNull(Object o) { - assertNotNull(o, null); - } - - /** - * Asserts that {@code o} is not null. - * - * @param o The reference assumed not to be null, - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static void assertNotNull(Object o, String msg) { - assertNotEquals(o, null, msg); - } - - /** - * Calls {@link #assertFalse(boolean, String)} with a default message. - * - * @param value The value assumed to be false. - * @see #assertFalse(boolean, String) - */ - public static void assertFalse(boolean value) { - assertFalse(value, null); - } - - /** - * Asserts that {@code value} is {@code false}. - * - * @param value The value assumed to be false. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static void assertFalse(boolean value, String msg) { - if (value) { - msg = Objects.toString(msg, "assertFalse") - + ": expected false, was true"; - fail(msg); - } - } - - /** - * Calls {@link #assertTrue(boolean, String)} with a default message. - * - * @param value The value assumed to be true. - * @see #assertTrue(boolean, String) - */ - public static void assertTrue(boolean value) { - assertTrue(value, null); - } - - /** - * Asserts that {@code value} is {@code true}. - * - * @param value The value assumed to be true. - * @param msg A description of the assumption; {@code null} for a default message. - * @throws RuntimeException if the assertion is not true. - */ - public static void assertTrue(boolean value, String msg) { - if (!value) { - msg = Objects.toString(msg, "assertTrue") - + ": expected true, was false"; - fail(msg); - } - } - - private static > int compare(T lhs, T rhs, String msg) { - if (lhs == null || rhs == null) { - fail(lhs, rhs, msg + ": values must be non-null:", ","); - } - return lhs.compareTo(rhs); - } - - /** - * Returns a string formatted with a message and expected and actual values. - * @param lhs the actual value - * @param rhs the expected value - * @param message the actual value - * @param relation the asserted relationship between lhs and rhs - * @return a formatted string - */ - public static String format(Object lhs, Object rhs, String message, String relation) { - StringBuilder sb = new StringBuilder(80); - if (message != null) { - sb.append(message); - sb.append(' '); - } - sb.append("<"); - sb.append(Objects.toString(lhs)); - sb.append("> "); - sb.append(Objects.toString(relation, ",")); - sb.append(" <"); - sb.append(Objects.toString(rhs)); - sb.append(">"); - return sb.toString(); - } - - /** - * Fail reports a failure with message fail. - * - * @throws RuntimeException always - */ - public static void fail() { - fail("fail"); - } - - /** - * Fail reports a failure with a message. - * @param message for the failure - * @throws RuntimeException always - */ - public static void fail(String message) { - throw new RuntimeException(message); - } - - /** - * Fail reports a failure with a formatted message. - * - * @param lhs the actual value - * @param rhs the expected value - * @param message to be format before the expected and actual values - * @param relation the asserted relationship between lhs and rhs - * @throws RuntimeException always - */ - public static void fail(Object lhs, Object rhs, String message, String relation) { - throw new RuntimeException(format(lhs, rhs, message, relation)); - } - - /** - * Fail reports a failure with a message and a cause. - * @param message to be format before the expected and actual values - * @param cause the exception that caused this failure - * @throws RuntimeException always - */ - public static void fail(String message, Throwable cause) { - throw new RuntimeException(message, cause); - } - -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/CompilerUtils.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/CompilerUtils.java deleted file mode 100644 index afabfd7cc52..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/CompilerUtils.java +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import javax.tools.JavaCompiler; -import javax.tools.StandardJavaFileManager; -import javax.tools.StandardLocation; -import javax.tools.ToolProvider; -import java.io.IOException; -import java.nio.file.Files; -import java.nio.file.Path; -import java.util.Arrays; -import java.util.Collections; -import java.util.List; -import java.util.stream.Collectors; - -/** - * This class consists exclusively of static utility methods for invoking the - * java compiler. - */ - -public final class CompilerUtils { - private CompilerUtils() { } - - /** - * Compile all the java sources in {@code /**} to - * {@code /**}. The destination directory will be created if - * it doesn't exist. - * - * All warnings/errors emitted by the compiler are output to System.out/err. - * - * @return true if the compilation is successful - * - * @throws IOException if there is an I/O error scanning the source tree or - * creating the destination directory - */ - public static boolean compile(Path source, Path destination, String ... options) - throws IOException - { - JavaCompiler compiler = ToolProvider.getSystemJavaCompiler(); - StandardJavaFileManager jfm = compiler.getStandardFileManager(null, null, null); - - List sources - = Files.find(source, Integer.MAX_VALUE, - (file, attrs) -> (file.toString().endsWith(".java"))) - .collect(Collectors.toList()); - - Files.createDirectories(destination); - jfm.setLocation(StandardLocation.CLASS_PATH, Collections.EMPTY_LIST); - jfm.setLocationFromPaths(StandardLocation.CLASS_OUTPUT, - Arrays.asList(destination)); - - List opts = Arrays.asList(options); - JavaCompiler.CompilationTask task - = compiler.getTask(null, jfm, null, opts, null, - jfm.getJavaFileObjectsFromPaths(sources)); - - return task.call(); - } -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/JDKToolFinder.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/JDKToolFinder.java deleted file mode 100644 index c4815229eb7..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/JDKToolFinder.java +++ /dev/null @@ -1,111 +0,0 @@ -/* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import java.io.FileNotFoundException; -import java.nio.file.Path; -import java.nio.file.Paths; - -/** - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib} - */ -@Deprecated -public final class JDKToolFinder { - - private JDKToolFinder() { - } - - /** - * Returns the full path to an executable in jdk/bin based on System - * property {@code test.jdk} or {@code compile.jdk} (both are set by the jtreg test suite) - * - * @return Full path to an executable in jdk/bin - */ - public static String getJDKTool(String tool) { - - // First try to find the executable in test.jdk - try { - return getTool(tool, "test.jdk"); - } catch (FileNotFoundException e) { - - } - - // Now see if it's available in compile.jdk - try { - return getTool(tool, "compile.jdk"); - } catch (FileNotFoundException e) { - throw new RuntimeException("Failed to find " + tool + - ", looked in test.jdk (" + System.getProperty("test.jdk") + - ") and compile.jdk (" + System.getProperty("compile.jdk") + ")"); - } - } - - /** - * Returns the full path to an executable in jdk/bin based on System - * property {@code compile.jdk} - * - * @return Full path to an executable in jdk/bin - */ - public static String getCompileJDKTool(String tool) { - try { - return getTool(tool, "compile.jdk"); - } catch (FileNotFoundException e) { - throw new RuntimeException(e); - } - } - - /** - * Returns the full path to an executable in jdk/bin based on System - * property {@code test.jdk} - * - * @return Full path to an executable in jdk/bin - */ - public static String getTestJDKTool(String tool) { - try { - return getTool(tool, "test.jdk"); - } catch (FileNotFoundException e) { - throw new RuntimeException(e); - } - } - - private static String getTool(String tool, String property) throws FileNotFoundException { - String jdkPath = System.getProperty(property); - - if (jdkPath == null) { - throw new RuntimeException( - "System property '" + property + "' not set. This property is normally set by jtreg. " - + "When running test separately, set this property using '-D" + property + "=/path/to/jdk'."); - } - - Path toolName = Paths.get("bin", tool + (Platform.isWindows() ? ".exe" : "")); - - Path jdkTool = Paths.get(jdkPath, toolName.toString()); - if (!jdkTool.toFile().exists()) { - throw new FileNotFoundException("Could not find file " + jdkTool.toAbsolutePath()); - } - - return jdkTool.toAbsolutePath().toString(); - } -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/JDKToolLauncher.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/JDKToolLauncher.java deleted file mode 100644 index 777e8cf5336..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/JDKToolLauncher.java +++ /dev/null @@ -1,136 +0,0 @@ -/* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -/** - * A utility for constructing command lines for starting JDK tool processes. - * - * The JDKToolLauncher can in particular be combined with a - * java.lang.ProcessBuilder to easily run a JDK tool. For example, the following - * code run {@code jmap -heap} against a process with GC logging turned on for - * the {@code jmap} process: - * - *
    - * {@code
    - * JDKToolLauncher jmap = JDKToolLauncher.create("jmap")
    - *                                       .addVMArg("-Xlog:gc*=debug")
    - *                                       .addToolArg("-heap")
    - *                                       .addToolArg(pid);
    - * ProcessBuilder pb = new ProcessBuilder(jmap.getCommand());
    - * Process p = pb.start();
    - * }
    - * 
    - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib} - */ -@Deprecated -public class JDKToolLauncher { - private final String executable; - private final List vmArgs = new ArrayList(); - private final List toolArgs = new ArrayList(); - - private JDKToolLauncher(String tool, boolean useCompilerJDK) { - if (useCompilerJDK) { - executable = JDKToolFinder.getJDKTool(tool); - } else { - executable = JDKToolFinder.getTestJDKTool(tool); - } - vmArgs.addAll(Arrays.asList(ProcessTools.getPlatformSpecificVMArgs())); - } - - /** - * Creates a new JDKToolLauncher for the specified tool. Using tools path - * from the compiler JDK. - * - * @param tool - * The name of the tool - * @return A new JDKToolLauncher - */ - public static JDKToolLauncher create(String tool) { - return new JDKToolLauncher(tool, true); - } - - /** - * Creates a new JDKToolLauncher for the specified tool in the Tested JDK. - * - * @param tool - * The name of the tool - * - * @return A new JDKToolLauncher - */ - public static JDKToolLauncher createUsingTestJDK(String tool) { - return new JDKToolLauncher(tool, false); - } - - /** - * Adds an argument to the JVM running the tool. - * - * The JVM arguments are passed to the underlying JVM running the tool. - * Arguments will automatically be prepended with "-J". - * - * Any platform specific arguments required for running the tool are - * automatically added. - * - * - * @param arg - * The argument to VM running the tool - * @return The JDKToolLauncher instance - */ - public JDKToolLauncher addVMArg(String arg) { - vmArgs.add(arg); - return this; - } - - /** - * Adds an argument to the tool. - * - * @param arg - * The argument to the tool - * @return The JDKToolLauncher instance - */ - public JDKToolLauncher addToolArg(String arg) { - toolArgs.add(arg); - return this; - } - - /** - * Returns the command that can be used for running the tool. - * - * @return An array whose elements are the arguments of the command. - */ - public String[] getCommand() { - List command = new ArrayList(); - command.add(executable); - // Add -J in front of all vmArgs - for (String arg : vmArgs) { - command.add("-J" + arg); - } - command.addAll(toolArgs); - return command.toArray(new String[command.size()]); - } -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/OutputAnalyzer.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/OutputAnalyzer.java deleted file mode 100644 index 839c3228294..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/OutputAnalyzer.java +++ /dev/null @@ -1,576 +0,0 @@ -/* - * Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import static jdk.testlibrary.Asserts.*; - -import java.io.IOException; -import java.io.PrintStream; -import java.util.ArrayList; -import java.util.List; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -/** - * Utility class for verifying output and exit value from a {@code Process}. - * - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib/process} - * - */ -@Deprecated -public final class OutputAnalyzer { - private final OutputBuffer output; - private final String stdout; - private final String stderr; - private final int exitValue; // useless now. output contains exit value. - - /** - * Create an OutputAnalyzer, a utility class for verifying output and exit - * value from a Process. - *

    - * OutputAnalyzer should never be instantiated directly - - * use {@linkplain ProcessTools#executeProcess(ProcessBuilder)} instead - * - * @param process - * Process to analyze - * @throws IOException - * If an I/O error occurs. - */ - OutputAnalyzer(Process process) throws IOException { - output = new OutputBuffer(process); - exitValue = -1; - this.stdout = null; - this.stderr = null; - } - - /** - * Create an OutputAnalyzer, a utility class for verifying output. - * - * @param buf - * String buffer to analyze - */ - OutputAnalyzer(String buf) { - this(buf, buf); - } - - /** - * Create an OutputAnalyzer, a utility class for verifying output - * - * @param stdout - * stdout buffer to analyze - * @param stderr - * stderr buffer to analyze - */ - OutputAnalyzer(String stdout, String stderr) { - this.output = null; - this.stdout = stdout; - this.stderr = stderr; - exitValue = -1; - } - - /** - * Verify that the stdout and stderr contents of output buffer contains the - * string - * - * @param expectedString - * String that buffer should contain - * @throws RuntimeException - * If the string was not found - */ - public OutputAnalyzer shouldContain(String expectedString) { - if (!getStdout().contains(expectedString) - && !getStderr().contains(expectedString)) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + expectedString - + "' missing from stdout/stderr \n"); - } - return this; - } - - /** - * Verify that the stdout contents of output buffer contains the string - * - * @param expectedString - * String that buffer should contain - * @throws RuntimeException - * If the string was not found - */ - public OutputAnalyzer stdoutShouldContain(String expectedString) { - if (!getStdout().contains(expectedString)) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + expectedString - + "' missing from stdout \n"); - } - return this; - } - - /** - * Verify that the stderr contents of output buffer contains the string - * - * @param expectedString - * String that buffer should contain - * @throws RuntimeException - * If the string was not found - */ - public OutputAnalyzer stderrShouldContain(String expectedString) { - if (!getStderr().contains(expectedString)) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + expectedString - + "' missing from stderr \n"); - } - return this; - } - - /** - * Verify that the stdout and stderr contents of output buffer does not - * contain the string - * - * @param notExpectedString - * String that the buffer should not contain - * @throws RuntimeException - * If the string was found - */ - public OutputAnalyzer shouldNotContain(String notExpectedString) { - if (getStdout().contains(notExpectedString)) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + notExpectedString - + "' found in stdout \n"); - } - if (getStderr().contains(notExpectedString)) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + notExpectedString - + "' found in stderr \n"); - } - return this; - } - - /** - * Verify that the stdout contents of output buffer does not contain the - * string - * - * @param notExpectedString - * String that the buffer should not contain - * @throws RuntimeException - * If the string was found - */ - public OutputAnalyzer stdoutShouldNotContain(String notExpectedString) { - if (getStdout().contains(notExpectedString)) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + notExpectedString - + "' found in stdout \n"); - } - return this; - } - - /** - * Verify that the stderr contents of output buffer does not contain the - * string - * - * @param notExpectedString - * String that the buffer should not contain - * @throws RuntimeException - * If the string was found - */ - public OutputAnalyzer stderrShouldNotContain(String notExpectedString) { - if (getStderr().contains(notExpectedString)) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + notExpectedString - + "' found in stderr \n"); - } - return this; - } - - /** - * Verify that the stdout and stderr contents of output buffer matches the - * pattern - * - * @param pattern - * @throws RuntimeException - * If the pattern was not found - */ - public OutputAnalyzer shouldMatch(String pattern) { - Matcher stdoutMatcher = Pattern.compile(pattern, Pattern.MULTILINE) - .matcher(getStdout()); - Matcher stderrMatcher = Pattern.compile(pattern, Pattern.MULTILINE) - .matcher(getStderr()); - if (!stdoutMatcher.find() && !stderrMatcher.find()) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + pattern - + "' missing from stdout/stderr \n"); - } - return this; - } - - /** - * Verify that the stdout contents of output buffer matches the pattern - * - * @param pattern - * @throws RuntimeException - * If the pattern was not found - */ - public OutputAnalyzer stdoutShouldMatch(String pattern) { - Matcher matcher = Pattern.compile(pattern, Pattern.MULTILINE).matcher( - getStdout()); - if (!matcher.find()) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + pattern - + "' missing from stdout \n"); - } - return this; - } - - /** - * Verify that the stderr contents of output buffer matches the pattern - * - * @param pattern - * @throws RuntimeException - * If the pattern was not found - */ - public OutputAnalyzer stderrShouldMatch(String pattern) { - Matcher matcher = Pattern.compile(pattern, Pattern.MULTILINE).matcher( - getStderr()); - if (!matcher.find()) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + pattern - + "' missing from stderr \n"); - } - return this; - } - - /** - * Verify that the stdout and stderr contents of output buffer does not - * match the pattern - * - * @param pattern - * @throws RuntimeException - * If the pattern was found - */ - public OutputAnalyzer shouldNotMatch(String pattern) { - Matcher matcher = Pattern.compile(pattern, Pattern.MULTILINE).matcher( - getStdout()); - if (matcher.find()) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + pattern + "' found in stdout: '" - + matcher.group() + "' \n"); - } - matcher = Pattern.compile(pattern, Pattern.MULTILINE).matcher(getStderr()); - if (matcher.find()) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + pattern + "' found in stderr: '" - + matcher.group() + "' \n"); - } - return this; - } - - /** - * Verify that the stdout contents of output buffer does not match the - * pattern - * - * @param pattern - * @throws RuntimeException - * If the pattern was found - */ - public OutputAnalyzer stdoutShouldNotMatch(String pattern) { - Matcher matcher = Pattern.compile(pattern, Pattern.MULTILINE).matcher( - getStdout()); - if (matcher.find()) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + pattern + "' found in stdout \n"); - } - return this; - } - - /** - * Verify that the stderr contents of output buffer does not match the - * pattern - * - * @param pattern - * @throws RuntimeException - * If the pattern was found - */ - public OutputAnalyzer stderrShouldNotMatch(String pattern) { - Matcher matcher = Pattern.compile(pattern, Pattern.MULTILINE).matcher( - getStderr()); - if (matcher.find()) { - reportDiagnosticSummary(); - throw new RuntimeException("'" + pattern + "' found in stderr \n"); - } - return this; - } - - /** - * Get the captured group of the first string matching the pattern. stderr - * is searched before stdout. - * - * @param pattern - * The multi-line pattern to match - * @param group - * The group to capture - * @return The matched string or null if no match was found - */ - public String firstMatch(String pattern, int group) { - Matcher stderrMatcher = Pattern.compile(pattern, Pattern.MULTILINE) - .matcher(getStderr()); - Matcher stdoutMatcher = Pattern.compile(pattern, Pattern.MULTILINE) - .matcher(getStdout()); - if (stderrMatcher.find()) { - return stderrMatcher.group(group); - } - if (stdoutMatcher.find()) { - return stdoutMatcher.group(group); - } - return null; - } - - /** - * Get the first string matching the pattern. stderr is searched before - * stdout. - * - * @param pattern - * The multi-line pattern to match - * @return The matched string or null if no match was found - */ - public String firstMatch(String pattern) { - return firstMatch(pattern, 0); - } - - /** - * Verify the exit value of the process - * - * @param expectedExitValue - * Expected exit value from process - * @throws RuntimeException - * If the exit value from the process did not match the expected - * value - */ - public OutputAnalyzer shouldHaveExitValue(int expectedExitValue) { - if (getExitValue() != expectedExitValue) { - reportDiagnosticSummary(); - throw new RuntimeException("Expected to get exit value of [" - + expectedExitValue + "]\n"); - } - return this; - } - - /** - * Report summary that will help to diagnose the problem Currently includes: - * - standard input produced by the process under test - standard output - - * exit code Note: the command line is printed by the ProcessTools - */ - private OutputAnalyzer reportDiagnosticSummary() { - String msg = " stdout: [" + getStdout() + "];\n" + " stderr: [" + getStderr() - + "]\n" + " exitValue = " + getExitValue() + "\n"; - - System.err.println(msg); - return this; - } - - /** - * Get the contents of the output buffer (stdout and stderr) - * - * @return Content of the output buffer - */ - public String getOutput() { - return getStdout() + getStderr(); - } - - /** - * Get the contents of the stdout buffer - * - * @return Content of the stdout buffer - */ - public String getStdout() { - return output == null ? stdout : output.getStdout(); - } - - /** - * Get the contents of the stderr buffer - * - * @return Content of the stderr buffer - */ - public String getStderr() { - return output == null ? stderr : output.getStderr(); - } - - /** - * Get the process exit value - * - * @return Process exit value - */ - public int getExitValue() { - return output == null ? exitValue : output.getExitValue(); - } - - - /** - * Print the stdout buffer to the given {@code PrintStream}. - * - * @return this OutputAnalyzer - */ - public OutputAnalyzer outputTo(PrintStream out) { - out.println(getStdout()); - return this; - } - - /** - * Print the stderr buffer to the given {@code PrintStream}. - * - * @return this OutputAnalyzer - */ - public OutputAnalyzer errorTo(PrintStream out) { - out.println(getStderr()); - return this; - } - - - /** - * Get the contents of the output buffer (stdout and stderr) as list of strings. - * Output will be split by system property 'line.separator'. - * - * @return Contents of the output buffer as list of strings - */ - public List asLines() { - return asLines(getOutput()); - } - - private List asLines(String buffer) { - List l = new ArrayList<>(); - String[] a = buffer.split(Utils.NEW_LINE); - for (String string : a) { - l.add(string); - } - return l; - } - - /** - * Check if there is a line matching {@code pattern} and return its index - * - * @param pattern Matching pattern - * @return Index of first matching line - */ - private int indexOf(List lines, String pattern) { - for (int i = 0; i < lines.size(); i++) { - if (lines.get(i).matches(pattern)) { - return i; - } - } - return -1; - } - - /** - * @see #shouldMatchByLine(String, String, String) - */ - public int shouldMatchByLine(String pattern) { - return shouldMatchByLine(null, null, pattern); - } - - /** - * @see #stdoutShouldMatchByLine(String, String, String) - */ - public int stdoutShouldMatchByLine(String pattern) { - return stdoutShouldMatchByLine(null, null, pattern); - } - - /** - * @see #shouldMatchByLine(String, String, String) - */ - public int shouldMatchByLineFrom(String from, String pattern) { - return shouldMatchByLine(from, null, pattern); - } - - /** - * @see #shouldMatchByLine(String, String, String) - */ - public int shouldMatchByLineTo(String to, String pattern) { - return shouldMatchByLine(null, to, pattern); - } - - /** - * Verify that the stdout and stderr contents of output buffer match the - * {@code pattern} line by line. The whole output could be matched or - * just a subset of it. - * - * @param from - * The line from where output will be matched. - * Set {@code from} to null for matching from the first line. - * @param to - * The line until where output will be matched. - * Set {@code to} to null for matching until the last line. - * @param pattern - * Matching pattern - * @return Count of lines which match the {@code pattern} - */ - public int shouldMatchByLine(String from, String to, String pattern) { - return shouldMatchByLine(getOutput(), from, to, pattern); - } - - /** - * Verify that the stdout contents of output buffer matches the - * {@code pattern} line by line. The whole stdout could be matched or - * just a subset of it. - * - * @param from - * The line from where stdout will be matched. - * Set {@code from} to null for matching from the first line. - * @param to - * The line until where stdout will be matched. - * Set {@code to} to null for matching until the last line. - * @param pattern - * Matching pattern - * @return Count of lines which match the {@code pattern} - */ - public int stdoutShouldMatchByLine(String from, String to, String pattern) { - return shouldMatchByLine(getStdout(), from, to, pattern); - } - - private int shouldMatchByLine(String buffer, String from, String to, String pattern) { - List lines = asLines(buffer); - - int fromIndex = 0; - if (from != null) { - fromIndex = indexOf(lines, from); - assertGreaterThan(fromIndex, -1, - "The line/pattern '" + from + "' from where the output should match can not be found"); - } - - int toIndex = lines.size(); - if (to != null) { - toIndex = indexOf(lines, to); - assertGreaterThan(toIndex, -1, - "The line/pattern '" + to + "' until where the output should match can not be found"); - } - - List subList = lines.subList(fromIndex, toIndex); - int matchedCount = 0; - for (String line : subList) { - assertTrue(line.matches(pattern), - "The line '" + line + "' does not match pattern '" + pattern + "'"); - matchedCount++; - } - - return matchedCount; - } - -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/OutputBuffer.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/OutputBuffer.java deleted file mode 100644 index c8a5d7aab12..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/OutputBuffer.java +++ /dev/null @@ -1,113 +0,0 @@ -/* - * Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import java.io.ByteArrayOutputStream; -import java.util.concurrent.CancellationException; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.Future; - -/** - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib/process} - */ -@Deprecated -class OutputBuffer { - private static class OutputBufferException extends RuntimeException { - private static final long serialVersionUID = 8528687792643129571L; - - public OutputBufferException(Throwable cause) { - super(cause); - } - } - - private final Process p; - private final Future outTask; - private final Future errTask; - private final ByteArrayOutputStream stderrBuffer = new ByteArrayOutputStream(); - private final ByteArrayOutputStream stdoutBuffer = new ByteArrayOutputStream(); - - /** - * Create an OutputBuffer, a class for storing and managing stdout and - * stderr results separately - * - * @param stdout - * stdout result - * @param stderr - * stderr result - */ - OutputBuffer(Process p) { - this.p = p; - StreamPumper outPumper = new StreamPumper(p.getInputStream(), - stdoutBuffer); - StreamPumper errPumper = new StreamPumper(p.getErrorStream(), - stderrBuffer); - - outTask = outPumper.process(); - errTask = errPumper.process(); - } - - /** - * Returns the stdout result - * - * @return stdout result - */ - public String getStdout() { - try { - outTask.get(); - return stdoutBuffer.toString(); - } catch (InterruptedException e) { - Thread.currentThread().interrupt(); - throw new OutputBufferException(e); - } catch (ExecutionException | CancellationException e) { - throw new OutputBufferException(e); - } - } - - /** - * Returns the stderr result - * - * @return stderr result - */ - public String getStderr() { - try { - errTask.get(); - return stderrBuffer.toString(); - } catch (InterruptedException e) { - Thread.currentThread().interrupt(); - throw new OutputBufferException(e); - } catch (ExecutionException | CancellationException e) { - throw new OutputBufferException(e); - } - } - - public int getExitValue() { - try { - return p.waitFor(); - } catch (InterruptedException e) { - Thread.currentThread().interrupt(); - throw new OutputBufferException(e); - } - } -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Platform.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Platform.java deleted file mode 100644 index 523e6e6a074..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Platform.java +++ /dev/null @@ -1,213 +0,0 @@ -/* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; -import java.util.regex.Pattern; -import java.io.RandomAccessFile; -import java.io.FileNotFoundException; -import java.io.IOException; - -/** - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib} - */ -@Deprecated -public class Platform { - private static final String osName = System.getProperty("os.name"); - private static final String dataModel = System.getProperty("sun.arch.data.model"); - private static final String vmVersion = System.getProperty("java.vm.version"); - private static final String jdkDebug = System.getProperty("jdk.debug"); - private static final String osArch = System.getProperty("os.arch"); - private static final String vmName = System.getProperty("java.vm.name"); - private static final String userName = System.getProperty("user.name"); - private static final String compiler = System.getProperty("sun.management.compiler"); - - public static boolean isClient() { - return vmName.endsWith(" Client VM"); - } - - public static boolean isServer() { - return vmName.endsWith(" Server VM"); - } - - public static boolean isGraal() { - return vmName.endsWith(" Graal VM"); - } - - public static boolean isMinimal() { - return vmName.endsWith(" Minimal VM"); - } - - public static boolean isEmbedded() { - return vmName.contains("Embedded"); - } - - public static boolean isTieredSupported() { - return compiler.contains("Tiered Compilers"); - } - - - public static boolean is32bit() { - return dataModel.equals("32"); - } - - public static boolean is64bit() { - return dataModel.equals("64"); - } - - public static boolean isAix() { - return isOs("aix"); - } - - public static boolean isLinux() { - return isOs("linux"); - } - - public static boolean isOSX() { - return isOs("mac"); - } - - public static boolean isSolaris() { - return isOs("sunos"); - } - - public static boolean isWindows() { - return isOs("win"); - } - - private static boolean isOs(String osname) { - return osName.toLowerCase().startsWith(osname.toLowerCase()); - } - - public static String getOsName() { - return osName; - } - - public static boolean isDebugBuild() { - return (jdkDebug.toLowerCase().contains("debug")); - } - - public static String getVMVersion() { - return vmVersion; - } - - // Returns true for sparc and sparcv9. - public static boolean isSparc() { - return isArch("sparc.*"); - } - - public static boolean isARM() { - return isArch("arm.*"); - } - - public static boolean isPPC() { - return isArch("ppc.*"); - } - - public static boolean isX86() { - // On Linux it's 'i386', Windows 'x86' without '_64' suffix. - return isArch("(i386)|(x86(?!_64))"); - } - - public static boolean isX64() { - // On OSX it's 'x86_64' and on other (Linux, Windows and Solaris) platforms it's 'amd64' - return isArch("(amd64)|(x86_64)"); - } - - private static boolean isArch(String archnameRE) { - return Pattern.compile(archnameRE, Pattern.CASE_INSENSITIVE) - .matcher(osArch) - .matches(); - } - - public static String getOsArch() { - return osArch; - } - - /** - * Return a boolean for whether we expect to be able to attach - * the SA to our own processes on this system. - */ - public static boolean shouldSAAttach() - throws IOException { - - if (isAix()) { - return false; // SA not implemented. - } else if (isLinux()) { - return canPtraceAttachLinux(); - } else if (isOSX()) { - return canAttachOSX(); - } else { - // Other platforms expected to work: - return true; - } - } - - /** - * On Linux, first check the SELinux boolean "deny_ptrace" and return false - * as we expect to be denied if that is "1". - */ - public static boolean canPtraceAttachLinux() - throws IOException { - - // SELinux deny_ptrace: - try(RandomAccessFile file = new RandomAccessFile("/sys/fs/selinux/booleans/deny_ptrace", "r")) { - if (file.readByte() != '0') { - return false; - } - } - catch(FileNotFoundException ex) { - // Ignored - } - - // YAMA enhanced security ptrace_scope: - // 0 - a process can PTRACE_ATTACH to any other process running under the same uid - // 1 - restricted ptrace: a process must be a children of the inferior or user is root - // 2 - only processes with CAP_SYS_PTRACE may use ptrace or user is root - // 3 - no attach: no processes may use ptrace with PTRACE_ATTACH - - try(RandomAccessFile file = new RandomAccessFile("/proc/sys/kernel/yama/ptrace_scope", "r")) { - byte yama_scope = file.readByte(); - if (yama_scope == '3') { - return false; - } - - if (!userName.equals("root") && yama_scope != '0') { - return false; - } - } - catch(FileNotFoundException ex) { - // Ignored - } - - // Otherwise expect to be permitted: - return true; - } - - /** - * On OSX, expect permission to attach only if we are root. - */ - public static boolean canAttachOSX() { - return userName.equals("root"); - } -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/ProcessTools.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/ProcessTools.java deleted file mode 100644 index 35cffc1c994..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/ProcessTools.java +++ /dev/null @@ -1,579 +0,0 @@ -/* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import java.io.IOException; -import java.io.InputStream; -import java.io.OutputStream; -import java.io.PrintStream; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collections; -import java.util.concurrent.CountDownLatch; -import java.util.Map; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.Future; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.TimeoutException; -import java.util.function.Predicate; -import java.util.function.Consumer; -import java.util.stream.Collectors; - - -/** - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib/process} - */ -@Deprecated -public final class ProcessTools { - private static final class LineForwarder extends StreamPumper.LinePump { - private final PrintStream ps; - private final String prefix; - LineForwarder(String prefix, PrintStream os) { - this.ps = os; - this.prefix = prefix; - } - @Override - protected void processLine(String line) { - ps.println("[" + prefix + "] " + line); - } - } - - private ProcessTools() { - } - - /** - *

    Starts a process from its builder.

    - * The default redirects of STDOUT and STDERR are started - * @param name The process name - * @param processBuilder The process builder - * @return Returns the initialized process - * @throws IOException - */ - public static Process startProcess(String name, - ProcessBuilder processBuilder) - throws IOException { - return startProcess(name, processBuilder, (Consumer)null); - } - - /** - *

    Starts a process from its builder.

    - * The default redirects of STDOUT and STDERR are started - *

    It is possible to monitor the in-streams via the provided {@code consumer} - * @param name The process name - * @param consumer {@linkplain Consumer} instance to process the in-streams - * @param processBuilder The process builder - * @return Returns the initialized process - * @throws IOException - */ - @SuppressWarnings("overloads") - public static Process startProcess(String name, - ProcessBuilder processBuilder, - Consumer consumer) - throws IOException { - try { - return startProcess(name, processBuilder, consumer, null, -1, TimeUnit.NANOSECONDS); - } catch (InterruptedException | TimeoutException e) { - // will never happen - throw new RuntimeException(e); - } - } - - /** - *

    Starts a process from its builder.

    - * The default redirects of STDOUT and STDERR are started - *

    - * It is possible to wait for the process to get to a warmed-up state - * via {@linkplain Predicate} condition on the STDOUT - *

    - * @param name The process name - * @param processBuilder The process builder - * @param linePredicate The {@linkplain Predicate} to use on the STDOUT - * Used to determine the moment the target app is - * properly warmed-up. - * It can be null - in that case the warmup is skipped. - * @param timeout The timeout for the warmup waiting; -1 = no wait; 0 = wait forever - * @param unit The timeout {@linkplain TimeUnit} - * @return Returns the initialized {@linkplain Process} - * @throws IOException - * @throws InterruptedException - * @throws TimeoutException - */ - public static Process startProcess(String name, - ProcessBuilder processBuilder, - final Predicate linePredicate, - long timeout, - TimeUnit unit) - throws IOException, InterruptedException, TimeoutException { - return startProcess(name, processBuilder, null, linePredicate, timeout, unit); - } - - /** - *

    Starts a process from its builder.

    - * The default redirects of STDOUT and STDERR are started - *

    - * It is possible to wait for the process to get to a warmed-up state - * via {@linkplain Predicate} condition on the STDOUT and monitor the - * in-streams via the provided {@linkplain Consumer} - *

    - * @param name The process name - * @param processBuilder The process builder - * @param lineConsumer The {@linkplain Consumer} the lines will be forwarded to - * @param linePredicate The {@linkplain Predicate} to use on the STDOUT - * Used to determine the moment the target app is - * properly warmed-up. - * It can be null - in that case the warmup is skipped. - * @param timeout The timeout for the warmup waiting; -1 = no wait; 0 = wait forever - * @param unit The timeout {@linkplain TimeUnit} - * @return Returns the initialized {@linkplain Process} - * @throws IOException - * @throws InterruptedException - * @throws TimeoutException - */ - public static Process startProcess(String name, - ProcessBuilder processBuilder, - final Consumer lineConsumer, - final Predicate linePredicate, - long timeout, - TimeUnit unit) - throws IOException, InterruptedException, TimeoutException { - System.out.println("["+name+"]:" + processBuilder.command().stream().collect(Collectors.joining(" "))); - Process p = processBuilder.start(); - StreamPumper stdout = new StreamPumper(p.getInputStream()); - StreamPumper stderr = new StreamPumper(p.getErrorStream()); - - stdout.addPump(new LineForwarder(name, System.out)); - stderr.addPump(new LineForwarder(name, System.err)); - if (lineConsumer != null) { - StreamPumper.LinePump pump = new StreamPumper.LinePump() { - @Override - protected void processLine(String line) { - lineConsumer.accept(line); - } - }; - stdout.addPump(pump); - stderr.addPump(pump); - } - - - CountDownLatch latch = new CountDownLatch(1); - if (linePredicate != null) { - StreamPumper.LinePump pump = new StreamPumper.LinePump() { - @Override - protected void processLine(String line) { - if (latch.getCount() > 0 && linePredicate.test(line)) { - latch.countDown(); - } - } - }; - stdout.addPump(pump); - stderr.addPump(pump); - } else { - latch.countDown(); - } - final Future stdoutTask = stdout.process(); - final Future stderrTask = stderr.process(); - - try { - if (timeout > -1) { - if (timeout == 0) { - latch.await(); - } else { - if (!latch.await(Utils.adjustTimeout(timeout), unit)) { - throw new TimeoutException(); - } - } - } - } catch (TimeoutException | InterruptedException e) { - System.err.println("Failed to start a process (thread dump follows)"); - for(Map.Entry s : Thread.getAllStackTraces().entrySet()) { - printStack(s.getKey(), s.getValue()); - } - - if (p.isAlive()) { - p.destroyForcibly(); - } - - stdoutTask.cancel(true); - stderrTask.cancel(true); - throw e; - } - - return new ProcessImpl(p, stdoutTask, stderrTask); - } - - /** - *

    Starts a process from its builder.

    - * The default redirects of STDOUT and STDERR are started - *

    - * It is possible to wait for the process to get to a warmed-up state - * via {@linkplain Predicate} condition on the STDOUT. The warm-up will - * wait indefinitely. - *

    - * @param name The process name - * @param processBuilder The process builder - * @param linePredicate The {@linkplain Predicate} to use on the STDOUT - * Used to determine the moment the target app is - * properly warmed-up. - * It can be null - in that case the warmup is skipped. - * @return Returns the initialized {@linkplain Process} - * @throws IOException - * @throws InterruptedException - * @throws TimeoutException - */ - @SuppressWarnings("overloads") - public static Process startProcess(String name, - ProcessBuilder processBuilder, - final Predicate linePredicate) - throws IOException, InterruptedException, TimeoutException { - return startProcess(name, processBuilder, linePredicate, 0, TimeUnit.SECONDS); - } - - /** - * Get the process id of the current running Java process - * - * @return Process id - */ - public static long getProcessId() { - return ProcessHandle.current().getPid(); - } - - /** - * Get platform specific VM arguments (e.g. -d64 on 64bit Solaris) - * - * @return String[] with platform specific arguments, empty if there are - * none - */ - public static String[] getPlatformSpecificVMArgs() { - String osName = System.getProperty("os.name"); - String dataModel = System.getProperty("sun.arch.data.model"); - - if (osName.equals("SunOS") && dataModel.equals("64")) { - return new String[] { "-d64" }; - } - - return new String[] {}; - } - - /** - * Create ProcessBuilder using the java launcher from the jdk to be tested, - * and with any platform specific arguments prepended. - * - * @param command Arguments to pass to the java command. - * @return The ProcessBuilder instance representing the java command. - */ - public static ProcessBuilder createJavaProcessBuilder(String... command) - throws Exception { - return createJavaProcessBuilder(false, command); - } - - /** - * Create ProcessBuilder using the java launcher from the jdk to be tested, - * and with any platform specific arguments prepended. - * - * @param addTestVmAndJavaOptions If true, adds test.vm.opts and test.java.opts - * to the java arguments. - * @param command Arguments to pass to the java command. - * @return The ProcessBuilder instance representing the java command. - */ - public static ProcessBuilder createJavaProcessBuilder(boolean addTestVmAndJavaOptions, String... command) throws Exception { - String javapath = JDKToolFinder.getJDKTool("java"); - - ArrayList args = new ArrayList<>(); - args.add(javapath); - Collections.addAll(args, getPlatformSpecificVMArgs()); - - if (addTestVmAndJavaOptions) { - // -cp is needed to make sure the same classpath is used whether the test is - // run in AgentVM mode or OtherVM mode. It was added to the hotspot version - // of this API as part of 8077608. However, for the jdk version it is only - // added when addTestVmAndJavaOptions is true in order to minimize - // disruption to existing JDK tests, which have yet to be tested with -cp - // being added. At some point -cp should always be added to be consistent - // with what the hotspot version does. - args.add("-cp"); - args.add(System.getProperty("java.class.path")); - Collections.addAll(args, Utils.getTestJavaOpts()); - } - - Collections.addAll(args, command); - - // Reporting - StringBuilder cmdLine = new StringBuilder(); - for (String cmd : args) - cmdLine.append(cmd).append(' '); - System.out.println("Command line: [" + cmdLine.toString() + "]"); - - return new ProcessBuilder(args.toArray(new String[args.size()])); - } - - private static void printStack(Thread t, StackTraceElement[] stack) { - System.out.println("\t" + t + - " stack: (length = " + stack.length + ")"); - if (t != null) { - for (StackTraceElement stack1 : stack) { - System.out.println("\t" + stack1); - } - System.out.println(); - } - } - - /** - * Executes a test java process, waits for it to finish and returns the process output. - * The default options from jtreg, test.vm.opts and test.java.opts, are added. - * The java from the test.jdk is used to execute the command. - * - * The command line will be like: - * {test.jdk}/bin/java {test.vm.opts} {test.java.opts} cmds - * - * The java process will have exited before this method returns. - * - * @param cmds User specifed arguments. - * @return The output from the process. - */ - public static OutputAnalyzer executeTestJava(String... options) throws Exception { - ProcessBuilder pb = createJavaProcessBuilder(Utils.addTestJavaOpts(options)); - return executeProcess(pb); - } - - /** - * @deprecated Use executeTestJava instead - */ - public static OutputAnalyzer executeTestJvm(String... options) throws Exception { - return executeTestJava(options); - } - - /** - * Executes a process, waits for it to finish and returns the process output. - * The process will have exited before this method returns. - * @param pb The ProcessBuilder to execute. - * @return The {@linkplain OutputAnalyzer} instance wrapping the process. - */ - public static OutputAnalyzer executeProcess(ProcessBuilder pb) throws Exception { - return executeProcess(pb, null); - } - - /** - * Executes a process, pipe some text into its STDIN, waits for it - * to finish and returns the process output. The process will have exited - * before this method returns. - * @param pb The ProcessBuilder to execute. - * @param input The text to pipe into STDIN. Can be null. - * @return The {@linkplain OutputAnalyzer} instance wrapping the process. - */ - public static OutputAnalyzer executeProcess(ProcessBuilder pb, String input) - throws Exception { - OutputAnalyzer output = null; - Process p = null; - boolean failed = false; - try { - p = pb.start(); - if (input != null) { - try (OutputStream os = p.getOutputStream(); - PrintStream ps = new PrintStream(os)) { - ps.print(input); - ps.flush(); - } - } - output = new OutputAnalyzer(p); - p.waitFor(); - - return output; - } catch (Throwable t) { - if (p != null) { - p.destroyForcibly().waitFor(); - } - - failed = true; - System.out.println("executeProcess() failed: " + t); - throw t; - } finally { - if (failed) { - System.err.println(getProcessLog(pb, output)); - } - } - } - - /** - * Executes a process, waits for it to finish and returns the process output. - * - * The process will have exited before this method returns. - * - * @param cmds The command line to execute. - * @return The output from the process. - */ - public static OutputAnalyzer executeProcess(String... cmds) throws Throwable { - return executeProcess(new ProcessBuilder(cmds)); - } - - /** - * Used to log command line, stdout, stderr and exit code from an executed process. - * @param pb The executed process. - * @param output The output from the process. - */ - public static String getProcessLog(ProcessBuilder pb, OutputAnalyzer output) { - String stderr = output == null ? "null" : output.getStderr(); - String stdout = output == null ? "null" : output.getStdout(); - String exitValue = output == null ? "null": Integer.toString(output.getExitValue()); - StringBuilder logMsg = new StringBuilder(); - final String nl = System.getProperty("line.separator"); - logMsg.append("--- ProcessLog ---" + nl); - logMsg.append("cmd: " + getCommandLine(pb) + nl); - logMsg.append("exitvalue: " + exitValue + nl); - logMsg.append("stderr: " + stderr + nl); - logMsg.append("stdout: " + stdout + nl); - - return logMsg.toString(); - } - - /** - * @return The full command line for the ProcessBuilder. - */ - public static String getCommandLine(ProcessBuilder pb) { - if (pb == null) { - return "null"; - } - StringBuilder cmd = new StringBuilder(); - for (String s : pb.command()) { - cmd.append(s).append(" "); - } - return cmd.toString().trim(); - } - - /** - * Executes a process, waits for it to finish, prints the process output - * to stdout, and returns the process output. - * - * The process will have exited before this method returns. - * - * @param cmds The command line to execute. - * @return The {@linkplain OutputAnalyzer} instance wrapping the process. - */ - public static OutputAnalyzer executeCommand(String... cmds) - throws Throwable { - String cmdLine = Arrays.stream(cmds).collect(Collectors.joining(" ")); - System.out.println("Command line: [" + cmdLine + "]"); - OutputAnalyzer analyzer = ProcessTools.executeProcess(cmds); - System.out.println(analyzer.getOutput()); - return analyzer; - } - - /** - * Executes a process, waits for it to finish, prints the process output - * to stdout and returns the process output. - * - * The process will have exited before this method returns. - * - * @param pb The ProcessBuilder to execute. - * @return The {@linkplain OutputAnalyzer} instance wrapping the process. - */ - public static OutputAnalyzer executeCommand(ProcessBuilder pb) - throws Throwable { - String cmdLine = pb.command().stream().collect(Collectors.joining(" ")); - System.out.println("Command line: [" + cmdLine + "]"); - OutputAnalyzer analyzer = ProcessTools.executeProcess(pb); - System.out.println(analyzer.getOutput()); - return analyzer; - } - - private static class ProcessImpl extends Process { - - private final Process p; - private final Future stdoutTask; - private final Future stderrTask; - - public ProcessImpl(Process p, Future stdoutTask, Future stderrTask) { - this.p = p; - this.stdoutTask = stdoutTask; - this.stderrTask = stderrTask; - } - - @Override - public OutputStream getOutputStream() { - return p.getOutputStream(); - } - - @Override - public InputStream getInputStream() { - return p.getInputStream(); - } - - @Override - public InputStream getErrorStream() { - return p.getErrorStream(); - } - - @Override - public int waitFor() throws InterruptedException { - int rslt = p.waitFor(); - waitForStreams(); - return rslt; - } - - @Override - public int exitValue() { - return p.exitValue(); - } - - @Override - public void destroy() { - p.destroy(); - } - - @Override - public long getPid() { - return p.getPid(); - } - - @Override - public boolean isAlive() { - return p.isAlive(); - } - - @Override - public Process destroyForcibly() { - return p.destroyForcibly(); - } - - @Override - public boolean waitFor(long timeout, TimeUnit unit) throws InterruptedException { - boolean rslt = p.waitFor(timeout, unit); - if (rslt) { - waitForStreams(); - } - return rslt; - } - - private void waitForStreams() throws InterruptedException { - try { - stdoutTask.get(); - } catch (ExecutionException e) { - } - try { - stderrTask.get(); - } catch (ExecutionException e) { - } - } - } -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/README.txt b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/README.txt deleted file mode 100644 index c4fd572cd04..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/README.txt +++ /dev/null @@ -1 +0,0 @@ -These files are copies of the corresponding files in test/lib/testlibrary/ from jdk repo. diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/StreamPumper.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/StreamPumper.java deleted file mode 100644 index 2f3c205db3c..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/StreamPumper.java +++ /dev/null @@ -1,204 +0,0 @@ -/* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import java.io.BufferedInputStream; -import java.io.ByteArrayOutputStream; -import java.io.OutputStream; -import java.io.InputStream; -import java.io.IOException; -import java.util.HashSet; -import java.util.Set; -import java.util.concurrent.Future; -import java.util.concurrent.FutureTask; -import java.util.concurrent.atomic.AtomicBoolean; - -/** - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib/process} - */ -@Deprecated -public final class StreamPumper implements Runnable { - - private static final int BUF_SIZE = 256; - - /** - * Pump will be called by the StreamPumper to process the incoming data - */ - abstract public static class Pump { - abstract void register(StreamPumper d); - } - - /** - * OutputStream -> Pump adapter - */ - final public static class StreamPump extends Pump { - private final OutputStream out; - public StreamPump(OutputStream out) { - this.out = out; - } - - @Override - void register(StreamPumper sp) { - sp.addOutputStream(out); - } - } - - /** - * Used to process the incoming data line-by-line - */ - abstract public static class LinePump extends Pump { - @Override - final void register(StreamPumper sp) { - sp.addLineProcessor(this); - } - - abstract protected void processLine(String line); - } - - private final InputStream in; - private final Set outStreams = new HashSet<>(); - private final Set linePumps = new HashSet<>(); - - private final AtomicBoolean processing = new AtomicBoolean(false); - private final FutureTask processingTask = new FutureTask<>(this, null); - - public StreamPumper(InputStream in) { - this.in = in; - } - - /** - * Create a StreamPumper that reads from in and writes to out. - * - * @param in - * The stream to read from. - * @param out - * The stream to write to. - */ - public StreamPumper(InputStream in, OutputStream out) { - this(in); - this.addOutputStream(out); - } - - /** - * Implements Thread.run(). Continuously read from {@code in} and write to - * {@code out} until {@code in} has reached end of stream. Abort on - * interruption. Abort on IOExceptions. - */ - @Override - public void run() { - try (BufferedInputStream is = new BufferedInputStream(in)) { - ByteArrayOutputStream lineBos = new ByteArrayOutputStream(); - byte[] buf = new byte[BUF_SIZE]; - int len = 0; - int linelen = 0; - - while ((len = is.read(buf)) > 0 && !Thread.interrupted()) { - for(OutputStream out : outStreams) { - out.write(buf, 0, len); - } - if (!linePumps.isEmpty()) { - int i = 0; - int lastcrlf = -1; - while (i < len) { - if (buf[i] == '\n' || buf[i] == '\r') { - int bufLinelen = i - lastcrlf - 1; - if (bufLinelen > 0) { - lineBos.write(buf, lastcrlf + 1, bufLinelen); - } - linelen += bufLinelen; - - if (linelen > 0) { - lineBos.flush(); - final String line = lineBos.toString(); - linePumps.stream().forEach((lp) -> { - lp.processLine(line); - }); - lineBos.reset(); - linelen = 0; - } - lastcrlf = i; - } - - i++; - } - if (lastcrlf == -1) { - lineBos.write(buf, 0, len); - linelen += len; - } else if (lastcrlf < len - 1) { - lineBos.write(buf, lastcrlf + 1, len - lastcrlf - 1); - linelen += len - lastcrlf - 1; - } - } - } - - } catch (IOException e) { - e.printStackTrace(); - } finally { - for(OutputStream out : outStreams) { - try { - out.flush(); - } catch (IOException e) {} - } - try { - in.close(); - } catch (IOException e) {} - } - } - - final void addOutputStream(OutputStream out) { - outStreams.add(out); - } - - final void addLineProcessor(LinePump lp) { - linePumps.add(lp); - } - - final public StreamPumper addPump(Pump ... pump) { - if (processing.get()) { - throw new IllegalStateException("Can not modify pumper while " + - "processing is in progress"); - } - for(Pump p : pump) { - p.register(this); - } - return this; - } - - final public Future process() { - if (!processing.compareAndSet(false, true)) { - throw new IllegalStateException("Can not re-run the processing"); - } - Thread t = new Thread(new Runnable() { - @Override - public void run() { - processingTask.run(); - } - }); - t.setDaemon(true); - t.start(); - - return processingTask; - } -} diff --git a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Utils.java b/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Utils.java deleted file mode 100644 index c76339107c8..00000000000 --- a/jaxp/test/javax/xml/jaxp/libs/jdk/testlibrary/Utils.java +++ /dev/null @@ -1,365 +0,0 @@ -/* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import static jdk.testlibrary.Asserts.assertTrue; - -import java.io.IOException; -import java.net.InetAddress; -import java.net.ServerSocket; -import java.net.UnknownHostException; -import java.util.ArrayList; -import java.util.List; -import java.util.Arrays; -import java.util.Collections; -import java.util.regex.Pattern; -import java.util.regex.Matcher; -import java.util.concurrent.TimeUnit; -import java.util.function.BooleanSupplier; -import java.util.function.Function; - -/** - * Common library for various test helper functions. - * - * @deprecated This class is deprecated. Use the one from - * {@code /test/lib/share/classes/jdk/test/lib} - */ -@Deprecated -public final class Utils { - - /** - * Returns the sequence used by operating system to separate lines. - */ - public static final String NEW_LINE = System.getProperty("line.separator"); - - /** - * Returns the value of 'test.vm.opts'system property. - */ - public static final String VM_OPTIONS = System.getProperty("test.vm.opts", "").trim(); - - /** - * Returns the value of 'test.java.opts'system property. - */ - public static final String JAVA_OPTIONS = System.getProperty("test.java.opts", "").trim(); - - /** - * Returns the value of 'test.timeout.factor' system property - * converted to {@code double}. - */ - public static final double TIMEOUT_FACTOR; - static { - String toFactor = System.getProperty("test.timeout.factor", "1.0"); - TIMEOUT_FACTOR = Double.parseDouble(toFactor); - } - - /** - * Returns the value of JTREG default test timeout in milliseconds - * converted to {@code long}. - */ - public static final long DEFAULT_TEST_TIMEOUT = TimeUnit.SECONDS.toMillis(120); - - private Utils() { - // Private constructor to prevent class instantiation - } - - /** - * Returns the list of VM options. - * - * @return List of VM options - */ - public static List getVmOptions() { - return Arrays.asList(safeSplitString(VM_OPTIONS)); - } - - /** - * Returns the list of VM options with -J prefix. - * - * @return The list of VM options with -J prefix - */ - public static List getForwardVmOptions() { - String[] opts = safeSplitString(VM_OPTIONS); - for (int i = 0; i < opts.length; i++) { - opts[i] = "-J" + opts[i]; - } - return Arrays.asList(opts); - } - - /** - * Returns the default JTReg arguments for a jvm running a test. - * This is the combination of JTReg arguments test.vm.opts and test.java.opts. - * @return An array of options, or an empty array if no opptions. - */ - public static String[] getTestJavaOpts() { - List opts = new ArrayList(); - Collections.addAll(opts, safeSplitString(VM_OPTIONS)); - Collections.addAll(opts, safeSplitString(JAVA_OPTIONS)); - return opts.toArray(new String[0]); - } - - /** - * Combines given arguments with default JTReg arguments for a jvm running a test. - * This is the combination of JTReg arguments test.vm.opts and test.java.opts - * @return The combination of JTReg test java options and user args. - */ - public static String[] addTestJavaOpts(String... userArgs) { - List opts = new ArrayList(); - Collections.addAll(opts, getTestJavaOpts()); - Collections.addAll(opts, userArgs); - return opts.toArray(new String[0]); - } - - /** - * Removes any options specifying which GC to use, for example "-XX:+UseG1GC". - * Removes any options matching: -XX:(+/-)Use*GC - * Used when a test need to set its own GC version. Then any - * GC specified by the framework must first be removed. - * @return A copy of given opts with all GC options removed. - */ - private static final Pattern useGcPattern = Pattern.compile( - "(?:\\-XX\\:[\\+\\-]Use.+GC)" - + "|(?:\\-Xconcgc)"); - public static List removeGcOpts(List opts) { - List optsWithoutGC = new ArrayList(); - for (String opt : opts) { - if (useGcPattern.matcher(opt).matches()) { - System.out.println("removeGcOpts: removed " + opt); - } else { - optsWithoutGC.add(opt); - } - } - return optsWithoutGC; - } - - /** - * Splits a string by white space. - * Works like String.split(), but returns an empty array - * if the string is null or empty. - */ - private static String[] safeSplitString(String s) { - if (s == null || s.trim().isEmpty()) { - return new String[] {}; - } - return s.trim().split("\\s+"); - } - - /** - * @return The full command line for the ProcessBuilder. - */ - public static String getCommandLine(ProcessBuilder pb) { - StringBuilder cmd = new StringBuilder(); - for (String s : pb.command()) { - cmd.append(s).append(" "); - } - return cmd.toString(); - } - - /** - * Returns the free port on the local host. - * The function will spin until a valid port number is found. - * - * @return The port number - * @throws InterruptedException if any thread has interrupted the current thread - * @throws IOException if an I/O error occurs when opening the socket - */ - public static int getFreePort() throws InterruptedException, IOException { - int port = -1; - - while (port <= 0) { - Thread.sleep(100); - - ServerSocket serverSocket = null; - try { - serverSocket = new ServerSocket(0); - port = serverSocket.getLocalPort(); - } finally { - serverSocket.close(); - } - } - - return port; - } - - /** - * Returns the name of the local host. - * - * @return The host name - * @throws UnknownHostException if IP address of a host could not be determined - */ - public static String getHostname() throws UnknownHostException { - InetAddress inetAddress = InetAddress.getLocalHost(); - String hostName = inetAddress.getHostName(); - - assertTrue((hostName != null && !hostName.isEmpty()), - "Cannot get hostname"); - - return hostName; - } - - /** - * Uses "jcmd -l" to search for a jvm pid. This function will wait - * forever (until jtreg timeout) for the pid to be found. - * @param key Regular expression to search for - * @return The found pid. - */ - public static int waitForJvmPid(String key) throws Throwable { - final long iterationSleepMillis = 250; - System.out.println("waitForJvmPid: Waiting for key '" + key + "'"); - System.out.flush(); - while (true) { - int pid = tryFindJvmPid(key); - if (pid >= 0) { - return pid; - } - Thread.sleep(iterationSleepMillis); - } - } - - /** - * Searches for a jvm pid in the output from "jcmd -l". - * - * Example output from jcmd is: - * 12498 sun.tools.jcmd.JCmd -l - * 12254 /tmp/jdk8/tl/jdk/JTwork/classes/com/sun/tools/attach/Application.jar - * - * @param key A regular expression to search for. - * @return The found pid, or -1 if Enot found. - * @throws Exception If multiple matching jvms are found. - */ - public static int tryFindJvmPid(String key) throws Throwable { - OutputAnalyzer output = null; - try { - JDKToolLauncher jcmdLauncher = JDKToolLauncher.create("jcmd"); - jcmdLauncher.addToolArg("-l"); - output = ProcessTools.executeProcess(jcmdLauncher.getCommand()); - output.shouldHaveExitValue(0); - - // Search for a line starting with numbers (pid), follwed by the key. - Pattern pattern = Pattern.compile("([0-9]+)\\s.*(" + key + ").*\\r?\\n"); - Matcher matcher = pattern.matcher(output.getStdout()); - - int pid = -1; - if (matcher.find()) { - pid = Integer.parseInt(matcher.group(1)); - System.out.println("findJvmPid.pid: " + pid); - if (matcher.find()) { - throw new Exception("Found multiple JVM pids for key: " + key); - } - } - return pid; - } catch (Throwable t) { - System.out.println(String.format("Utils.findJvmPid(%s) failed: %s", key, t)); - throw t; - } - } - - /** - * Adjusts the provided timeout value for the TIMEOUT_FACTOR - * @param tOut the timeout value to be adjusted - * @return The timeout value adjusted for the value of "test.timeout.factor" - * system property - */ - public static long adjustTimeout(long tOut) { - return Math.round(tOut * Utils.TIMEOUT_FACTOR); - } - - /** - * Wait for condition to be true - * - * @param condition, a condition to wait for - */ - public static final void waitForCondition(BooleanSupplier condition) { - waitForCondition(condition, -1L, 100L); - } - - /** - * Wait until timeout for condition to be true - * - * @param condition, a condition to wait for - * @param timeout a time in milliseconds to wait for condition to be true - * specifying -1 will wait forever - * @return condition value, to determine if wait was successfull - */ - public static final boolean waitForCondition(BooleanSupplier condition, - long timeout) { - return waitForCondition(condition, timeout, 100L); - } - - /** - * Wait until timeout for condition to be true for specified time - * - * @param condition, a condition to wait for - * @param timeout a time in milliseconds to wait for condition to be true, - * specifying -1 will wait forever - * @param sleepTime a time to sleep value in milliseconds - * @return condition value, to determine if wait was successfull - */ - public static final boolean waitForCondition(BooleanSupplier condition, - long timeout, long sleepTime) { - long startTime = System.currentTimeMillis(); - while (!(condition.getAsBoolean() || (timeout != -1L - && ((System.currentTimeMillis() - startTime) > timeout)))) { - try { - Thread.sleep(sleepTime); - } catch (InterruptedException e) { - Thread.currentThread().interrupt(); - throw new Error(e); - } - } - return condition.getAsBoolean(); - } - - /** - * Interface same as java.lang.Runnable but with - * method {@code run()} able to throw any Throwable. - */ - public static interface ThrowingRunnable { - void run() throws Throwable; - } - - /** - * Filters out an exception that may be thrown by the given - * test according to the given filter. - * - * @param test - method that is invoked and checked for exception. - * @param filter - function that checks if the thrown exception matches - * criteria given in the filter's implementation. - * @return - exception that matches the filter if it has been thrown or - * {@code null} otherwise. - * @throws Throwable - if test has thrown an exception that does not - * match the filter. - */ - public static Throwable filterException(ThrowingRunnable test, - Function filter) throws Throwable { - try { - test.run(); - } catch (Throwable t) { - if (filter.apply(t)) { - return t; - } else { - throw t; - } - } - return null; - } -} diff --git a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/BasicModularXMLParserTest.java b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/BasicModularXMLParserTest.java index 72fd20c1d74..9b6faaa0a6f 100644 --- a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/BasicModularXMLParserTest.java +++ b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/BasicModularXMLParserTest.java @@ -27,16 +27,15 @@ import java.io.File; import java.nio.file.Path; import java.nio.file.Paths; -import static jdk.testlibrary.ProcessTools.executeTestJava; -import jdk.testlibrary.CompilerUtils; +import static jdk.test.lib.process.ProcessTools.executeTestJava; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; /* * @test - * @library /javax/xml/jaxp/libs - * @build jdk.testlibrary.* + * @library /test/lib * @run testng BasicModularXMLParserTest * @bug 8078820 8156119 * @summary Tests JAXP lib can instantiate the following interfaces diff --git a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/DefaultFactoryWrapperTest.java b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/DefaultFactoryWrapperTest.java index 0e16d9b5db3..18e4e76cee8 100644 --- a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/DefaultFactoryWrapperTest.java +++ b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/DefaultFactoryWrapperTest.java @@ -27,8 +27,6 @@ import static org.testng.Assert.assertSame; import java.io.StringReader; import java.io.StringWriter; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import javax.xml.datatype.DatatypeFactory; import javax.xml.parsers.DocumentBuilderFactory; @@ -52,7 +50,7 @@ import org.testng.annotations.Test; * @summary test customized provider wraps the built-in system-default implementation of JAXP factories */ public class DefaultFactoryWrapperTest { - private static final Module XML_MODULE = Layer.boot().findModule("java.xml").get(); + private static final Module XML_MODULE = ModuleLayer.boot().findModule("java.xml").get(); private static final String PROVIDER_PACKAGE = "xwp"; diff --git a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/LayerModularXMLParserTest.java b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/LayerModularXMLParserTest.java index 74f051ac04d..291ccc73444 100644 --- a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/LayerModularXMLParserTest.java +++ b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/LayerModularXMLParserTest.java @@ -29,9 +29,7 @@ import java.lang.String; import java.lang.System; import java.lang.module.Configuration; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; import java.lang.reflect.Method; -import java.lang.reflect.Module; import java.nio.file.Paths; import java.nio.file.Path; import java.util.Collections; @@ -42,12 +40,11 @@ import java.util.Set; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; -import jdk.testlibrary.CompilerUtils; +import jdk.test.lib.compiler.CompilerUtils; /* * @test - * @library /javax/xml/jaxp/libs - * @build jdk.testlibrary.* + * @library /test/lib * @run testng LayerModularXMLParserTest * @bug 8078820 8156119 * @summary Tests JAXP lib works with layer and TCCL @@ -95,23 +92,23 @@ public class LayerModularXMLParserTest { */ public void testOneLayer() throws Exception { ModuleFinder finder1 = ModuleFinder.of(MOD_DIR1); - Configuration cf1 = Layer.boot().configuration() - .resolveRequiresAndUses(finder1, ModuleFinder.of(), Set.of("test")); + Configuration cf1 = ModuleLayer.boot().configuration() + .resolveAndBind(finder1, ModuleFinder.of(), Set.of("test")); ClassLoader scl = ClassLoader.getSystemClassLoader(); - Layer layer1 = Layer.boot().defineModulesWithManyLoaders(cf1, scl); + ModuleLayer layer1 = ModuleLayer.boot().defineModulesWithManyLoaders(cf1, scl); ClassLoader cl1 = layer1.findLoader("test"); Method m = cl1.loadClass("test.XMLFactoryHelper").getMethod("instantiateXMLService", String.class); for (String service : services1) { Object o = m.invoke(null, service); - Layer providerLayer = o.getClass().getModule().getLayer(); + ModuleLayer providerLayer = o.getClass().getModule().getLayer(); assertSame(providerLayer, layer1); } for (String service : services2) { Object o = m.invoke(null, service); - Layer providerLayer = o.getClass().getModule().getLayer(); - assertSame(providerLayer, Layer.boot()); + ModuleLayer providerLayer = o.getClass().getModule().getLayer(); + assertSame(providerLayer, ModuleLayer.boot()); } } @@ -125,26 +122,26 @@ public class LayerModularXMLParserTest { */ public void testTwoLayer() throws Exception { ModuleFinder finder1 = ModuleFinder.of(MOD_DIR1); - Configuration cf1 = Layer.boot().configuration() - .resolveRequiresAndUses(finder1, ModuleFinder.of(), Set.of("test")); + Configuration cf1 = ModuleLayer.boot().configuration() + .resolveAndBind(finder1, ModuleFinder.of(), Set.of("test")); ClassLoader scl = ClassLoader.getSystemClassLoader(); - Layer layer1 = Layer.boot().defineModulesWithManyLoaders(cf1, scl); + ModuleLayer layer1 = ModuleLayer.boot().defineModulesWithManyLoaders(cf1, scl); ModuleFinder finder2 = ModuleFinder.of(MOD_DIR2); - Configuration cf2 = cf1.resolveRequiresAndUses(finder2, ModuleFinder.of(), Set.of("test")); - Layer layer2 = layer1.defineModulesWithOneLoader(cf2, layer1.findLoader("test")); + Configuration cf2 = cf1.resolveAndBind(finder2, ModuleFinder.of(), Set.of("test")); + ModuleLayer layer2 = layer1.defineModulesWithOneLoader(cf2, layer1.findLoader("test")); ClassLoader cl2 = layer2.findLoader("test"); Method m = cl2.loadClass("test.XMLFactoryHelper").getMethod("instantiateXMLService", String.class); for (String service : services1) { Object o = m.invoke(null, service); - Layer providerLayer = o.getClass().getModule().getLayer(); + ModuleLayer providerLayer = o.getClass().getModule().getLayer(); assertSame(providerLayer, layer1); } for (String service : services2) { Object o = m.invoke(null, service); - Layer providerLayer = o.getClass().getModule().getLayer(); + ModuleLayer providerLayer = o.getClass().getModule().getLayer(); assertSame(providerLayer, layer2); } @@ -159,26 +156,26 @@ public class LayerModularXMLParserTest { */ public void testTwoLayerWithDuplicate() throws Exception { ModuleFinder finder1 = ModuleFinder.of(MOD_DIR1, MOD_DIR2); - Configuration cf1 = Layer.boot().configuration() - .resolveRequiresAndUses(finder1, ModuleFinder.of(), Set.of("test")); + Configuration cf1 = ModuleLayer.boot().configuration() + .resolveAndBind(finder1, ModuleFinder.of(), Set.of("test")); ClassLoader scl = ClassLoader.getSystemClassLoader(); - Layer layer1 = Layer.boot().defineModulesWithManyLoaders(cf1, scl); + ModuleLayer layer1 = ModuleLayer.boot().defineModulesWithManyLoaders(cf1, scl); ModuleFinder finder2 = ModuleFinder.of(MOD_DIR2); - Configuration cf2 = cf1.resolveRequiresAndUses(finder2, ModuleFinder.of(), Set.of("test")); - Layer layer2 = layer1.defineModulesWithOneLoader(cf2, layer1.findLoader("test")); + Configuration cf2 = cf1.resolveAndBind(finder2, ModuleFinder.of(), Set.of("test")); + ModuleLayer layer2 = layer1.defineModulesWithOneLoader(cf2, layer1.findLoader("test")); ClassLoader cl2 = layer2.findLoader("test"); Method m = cl2.loadClass("test.XMLFactoryHelper").getMethod("instantiateXMLService", String.class); for (String service : services1) { Object o = m.invoke(null, service); - Layer providerLayer = o.getClass().getModule().getLayer(); + ModuleLayer providerLayer = o.getClass().getModule().getLayer(); assertSame(providerLayer, layer1); } for (String service : services2) { Object o = m.invoke(null, service); - Layer providerLayer = o.getClass().getModule().getLayer(); + ModuleLayer providerLayer = o.getClass().getModule().getLayer(); assertSame(providerLayer, layer2); } diff --git a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/XMLReaderFactoryTest.java b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/XMLReaderFactoryTest.java index ef3507fe9d1..6771d44c456 100644 --- a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/XMLReaderFactoryTest.java +++ b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/XMLReaderFactoryTest.java @@ -31,7 +31,7 @@ import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; -import jdk.testlibrary.CompilerUtils; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.Assert; import org.testng.annotations.BeforeTest; @@ -41,8 +41,7 @@ import org.xml.sax.helpers.XMLReaderFactory; /* * @test - * @library /javax/xml/jaxp/libs - * @build jdk.testlibrary.* + * @library /test/lib * @run testng XMLReaderFactoryTest * @bug 8152912 8015099 8156119 * @summary Tests XMLReaderFactory can work as ServiceLoader compliant, as well as backward compatible diff --git a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/src/unnamed/Main.java b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/src/unnamed/Main.java index 35d210369b2..971b5f350bf 100644 --- a/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/src/unnamed/Main.java +++ b/jaxp/test/javax/xml/jaxp/module/ServiceProviderTest/src/unnamed/Main.java @@ -24,8 +24,6 @@ import static javax.xml.XMLConstants.W3C_XML_SCHEMA_NS_URI; import java.lang.module.ModuleDescriptor.Provides; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.Arrays; import java.util.HashSet; import java.util.Set; @@ -38,7 +36,7 @@ public class Main { * @param args, the names of provider modules, which have been loaded */ public static void main(String[] args) throws Exception { - Module xml = Layer.boot().findModule("java.xml").get(); + Module xml = ModuleLayer.boot().findModule("java.xml").get(); Set allServices = new HashSet<>(Arrays.asList(expectedAllServices)); if (!allServices.equals(xml.getDescriptor().uses())) @@ -46,7 +44,7 @@ public class Main { + xml.getDescriptor().uses()); long violationCount = Stream.of(args) - .map(xmlProviderName -> Layer.boot().findModule(xmlProviderName).get()) + .map(xmlProviderName -> ModuleLayer.boot().findModule(xmlProviderName).get()) .mapToLong( // services provided by the implementation in provider module provider -> provider.getDescriptor().provides().stream() diff --git a/jaxp/test/javax/xml/jaxp/unittest/catalog/CatalogTest.java b/jaxp/test/javax/xml/jaxp/unittest/catalog/CatalogTest.java index 937de0ba0e1..9972328e102 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/catalog/CatalogTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/catalog/CatalogTest.java @@ -87,35 +87,6 @@ public class CatalogTest extends CatalogSupportBase { super.setUp(); } - /* - * @bug 8162431 - * Verifies that circular references are caught and - * CatalogException is thrown. - */ - @Test(dataProvider = "getFeatures", expectedExceptions = CatalogException.class) - public void testCircularRef(CatalogFeatures cf, String xml) throws Exception { - CatalogResolver catalogResolver = CatalogManager.catalogResolver( - cf, - getClass().getResource(xml).toURI()); - catalogResolver.resolve("anyuri", ""); - } - - /* - DataProvider: used to verify circular reference - Data columns: CatalogFeatures, catalog - */ - @DataProvider(name = "getFeatures") - public Object[][] getFeatures() { - String self = "catalogReferCircle-itself.xml"; - String left = "catalogReferCircle-left.xml"; - return new Object[][]{ - {CatalogFeatures.builder().with(CatalogFeatures.Feature.DEFER, "false").build(), self}, - {CatalogFeatures.defaults(), self}, - {CatalogFeatures.builder().with(CatalogFeatures.Feature.DEFER, "false").build(), left}, - {CatalogFeatures.defaults(), left} - }; - } - /* * @bug 8163232 * Verifies that the CatalogResolver supports the following XML Resolvers: @@ -437,7 +408,10 @@ public class CatalogTest extends CatalogSupportBase { public void resolveWithPrefer(String prefer, String cfile, String publicId, String systemId, String expected) throws Exception { URI catalogFile = getClass().getResource(cfile).toURI(); - CatalogFeatures f = CatalogFeatures.builder().with(CatalogFeatures.Feature.PREFER, prefer).with(CatalogFeatures.Feature.RESOLVE, "ignore").build(); + CatalogFeatures f = CatalogFeatures.builder() + .with(CatalogFeatures.Feature.PREFER, prefer) + .with(CatalogFeatures.Feature.RESOLVE, "ignore") + .build(); CatalogResolver catalogResolver = CatalogManager.catalogResolver(f, catalogFile); String result = catalogResolver.resolveEntity(publicId, systemId).getSystemId(); Assert.assertEquals(expected, result); @@ -452,7 +426,9 @@ public class CatalogTest extends CatalogSupportBase { @Test(dataProvider = "invalidAltCatalogs", expectedExceptions = CatalogException.class) public void testDeferAltCatalogs(String file) throws Exception { URI catalogFile = getClass().getResource(file).toURI(); - CatalogFeatures features = CatalogFeatures.builder().with(CatalogFeatures.Feature.DEFER, "true").build(); + CatalogFeatures features = CatalogFeatures.builder(). + with(CatalogFeatures.Feature.DEFER, "true") + .build(); /* Since the defer attribute is set to false in the specified catalog file, the parent catalog will try to load the alt catalog, which will fail @@ -471,11 +447,17 @@ public class CatalogTest extends CatalogSupportBase { URI catalogFile = getClass().getResource("JDK8146237_catalog.xml").toURI(); try { - CatalogFeatures features = CatalogFeatures.builder().with(CatalogFeatures.Feature.PREFER, "system").build(); + CatalogFeatures features = CatalogFeatures.builder() + .with(CatalogFeatures.Feature.PREFER, "system") + .build(); Catalog catalog = CatalogManager.catalog(features, catalogFile); CatalogResolver catalogResolver = CatalogManager.catalogResolver(catalog); - String actualSystemId = catalogResolver.resolveEntity("-//FOO//DTD XML Dummy V0.0//EN", "http://www.oracle.com/alt1sys.dtd").getSystemId(); - Assert.assertTrue(actualSystemId.contains("dummy.dtd"), "Resulting id should contain dummy.dtd, indicating a match by publicId"); + String actualSystemId = catalogResolver.resolveEntity( + "-//FOO//DTD XML Dummy V0.0//EN", + "http://www.oracle.com/alt1sys.dtd") + .getSystemId(); + Assert.assertTrue(actualSystemId.contains("dummy.dtd"), + "Resulting id should contain dummy.dtd, indicating a match by publicId"); } catch (Exception e) { Assert.fail(e.getMessage()); @@ -572,20 +554,21 @@ public class CatalogTest extends CatalogSupportBase { */ @Test public void testInvalidCatalog() throws Exception { + String expectedMsgId = "JAXP09040001"; URI catalog = getClass().getResource("catalog_invalid.xml").toURI(); - String test = "testInvalidCatalog"; try { - CatalogResolver resolver = CatalogManager.catalogResolver(CatalogFeatures.defaults(), catalog); - String actualSystemId = resolver.resolveEntity(null, "http://remote/xml/dtd/sys/alice/docAlice.dtd").getSystemId(); + CatalogResolver resolver = CatalogManager.catalogResolver( + CatalogFeatures.defaults(), catalog); + String actualSystemId = resolver.resolveEntity( + null, + "http://remote/xml/dtd/sys/alice/docAlice.dtd") + .getSystemId(); } catch (Exception e) { String msg = e.getMessage(); if (msg != null) { - if (msg.contains("No match found for publicId")) { - Assert.assertEquals(msg, "No match found for publicId 'null' and systemId 'http://remote/xml/dtd/sys/alice/docAlice.dtd'."); - System.out.println(test + ": expected [No match found for publicId 'null' and systemId 'http://remote/xml/dtd/sys/alice/docAlice.dtd'.]"); - System.out.println("actual [" + msg + "]"); - } + Assert.assertTrue(msg.contains(expectedMsgId), + "Message shall contain the corrent message ID " + expectedMsgId); } } } @@ -607,7 +590,10 @@ public class CatalogTest extends CatalogSupportBase { String test = "testInvalidCatalog"; try { CatalogResolver resolver = CatalogManager.catalogResolver(f); - String actualSystemId = resolver.resolveEntity(null, "http://remote/xml/dtd/sys/alice/docAlice.dtd").getSystemId(); + String actualSystemId = resolver.resolveEntity( + null, + "http://remote/xml/dtd/sys/alice/docAlice.dtd") + .getSystemId(); System.out.println("testIgnoreInvalidCatalog: expected [null]"); System.out.println("testIgnoreInvalidCatalog: expected [null]"); System.out.println("actual [" + actualSystemId + "]"); @@ -628,7 +614,11 @@ public class CatalogTest extends CatalogSupportBase { @DataProvider(name = "resolveUri") public Object[][] getDataForUriResolver() { return new Object[][]{ - {"uri.xml", "urn:publicid:-:Acme,+Inc.:DTD+Book+Version+1.0", null, "http://local/base/dtd/book.dtd", "Uri in publicId namespace is incorrectly unwrapped"}, + {"uri.xml", + "urn:publicid:-:Acme,+Inc.:DTD+Book+Version+1.0", + null, + "http://local/base/dtd/book.dtd", + "Uri in publicId namespace is incorrectly unwrapped"}, }; } @@ -654,7 +644,13 @@ public class CatalogTest extends CatalogSupportBase { public Object[][] getDataForMatchingBothIds() { String expected = "http://www.groupxmlbase.com/dtds/rewrite.dtd"; return new Object[][]{ - {"rewriteSystem_id.xml", "system", "http://www.sys00test.com/rewrite.dtd", "PUB-404", expected, expected, "Relative rewriteSystem with xml:base at group level failed"}, + {"rewriteSystem_id.xml", + "system", + "http://www.sys00test.com/rewrite.dtd", + "PUB-404", + expected, + expected, + "Relative rewriteSystem with xml:base at group level failed"}, }; } diff --git a/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-itself.xml b/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-itself.xml deleted file mode 100644 index c3cfaa66443..00000000000 --- a/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-itself.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-left.xml b/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-left.xml deleted file mode 100644 index 852b1a56ac3..00000000000 --- a/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-left.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-right.xml b/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-right.xml deleted file mode 100644 index 0c556a4b123..00000000000 --- a/jaxp/test/javax/xml/jaxp/unittest/catalog/catalogReferCircle-right.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/PrettyPrintTest.java b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/PrettyPrintTest.java index be54c6c2e05..da4ff787589 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/PrettyPrintTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/PrettyPrintTest.java @@ -60,7 +60,7 @@ import org.xml.sax.SAXException; /* * @test - * @bug 6439439 8087303 + * @bug 6439439 8087303 8174025 * @library /javax/xml/jaxp/libs /javax/xml/jaxp/unittest * @run testng/othervm -DrunSecMngr=true common.prettyprint.PrettyPrintTest * @run testng/othervm common.prettyprint.PrettyPrintTest @@ -69,29 +69,30 @@ import org.xml.sax.SAXException; @Listeners({jaxp.library.FilePolicy.class}) public class PrettyPrintTest { /* - * test CDATA, elements only, text and element, whitespace and element, - * xml:space property and nested xml:space property, mixed node types. + * test CDATA, elements only, text and element, xml:space property, mixed + * node types. */ @DataProvider(name = "xml-data") public Object[][] xmlData() throws Exception { return new Object[][] { - { read("xmltest1.xml"), read("xmltest1.out") }, - { read("xmltest2.xml"), read("xmltest2.out") }, - { read("xmltest3.xml"), read("xmltest3.out") }, - { read("xmltest4.xml"), read("xmltest4.out") }, - { read("xmltest5.xml"), read("xmltest5.out") }, - { read("xmltest6.xml"), read("xmltest6.out") }, - { read("xmltest7.xml"), read("xmltest7.out") }, - { read("xmltest8.xml"), read("xmltest8.out") } }; + { "xmltest1.xml", "xmltest1.out" }, + { "xmltest2.xml", "xmltest2.out" }, + { "xmltest3.xml", "xmltest3.out" }, + { "xmltest4.xml", "xmltest4.out" }, + { "xmltest6.xml", "xmltest6.out" }, + { "xmltest8.xml", "xmltest8.out" } }; } /* * @bug 8087303 - * Test the whitespace text nodes are serialized with pretty-print by LSSerializer and transformer correctly + * Test the xml document are serialized with pretty-print by + * LSSerializer and transformer correctly * */ @Test(dataProvider = "xml-data") - public void testXMLPrettyPrint(String source, String expected) throws Exception { + public void testXMLPrettyPrint(String sourceFile, String expectedFile) throws Exception { + String source = read(sourceFile); + String expected = read(expectedFile); // test it's no change if no pretty-print String result = serializerWrite(toXmlDocument(source), false); assertTrue(toXmlDocument(source).isEqualNode(toXmlDocument(result)), "The actual is: " + result); @@ -104,40 +105,116 @@ public class PrettyPrintTest { assertEquals(transform(toXmlDocument(source), true).replaceAll("\r\n", "\n"), expected); } + /* - * test pure text content, and sequent Text nodes. + * @bug 8087303 + * Test a single text node is serialized with pretty-print by + * LSSerializer and transformer correctly + * */ - @DataProvider(name = "xml-node-data") - public Object[][] xmlNodeData() throws Exception { - return new Object[][] { - { newTextNode(read("nodetest1.txt")), read("nodetest1.out") }, - { createDocWithSequentTextNodes(), read("nodetest2.out") } }; + @Test + public void testSingleTextNode() throws Exception { + Node xml = newTextNode(read("nodetest1.txt")); + String expected = read("nodetest1.out"); + assertEquals(serializerWrite(xml, true), expected); + assertEquals(transform(xml, true).replaceAll("\r\n", "\n"), expected); } /* * @bug 8087303 - * Test the whitespace text nodes are serialized with pretty-print by LSSerializer and transformer correctly, - * doesn't compare with the source because the test data is Node object + * Test the transformer shall keep all whitespace text node in + * sequent text nodes * */ - @Test(dataProvider = "xml-node-data") - public void testXMLNodePrettyPrint(Node xml, String expected) throws Exception { - assertEquals(serializerWrite(xml, true), expected); + @Test + public void testSequentTextNodesWithTransformer() throws Exception { + Node xml = createDocWithSequentTextNodes(); + String expected = read("nodetest2.out"); assertEquals(transform(xml, true).replaceAll("\r\n", "\n"), expected); } + /* + * @bug 8087303 + * Test LSSerializer shall eliminate the whitespace text node + * in sequent text nodes + * + */ + @Test + public void testSequentTextNodesWithLSSerializer() throws Exception { + Node xml = createDocWithSequentTextNodes(); + String expected = read("nodetest2ls.out"); + assertEquals(serializerWrite(xml, true), expected); + } + + + /* + * test whitespace and element, nested xml:space property. + */ + @DataProvider(name = "xml-data-whitespace-ls") + public Object[][] whitespaceLS() throws Exception { + return new Object[][] { + { "xmltest5.xml", "xmltest5ls.out" }, + { "xmltest7.xml", "xmltest7ls.out" } }; + } + + /* + * @bug 8087303 + * Test LSSerializer shall eliminate the whitespace text node + * unless xml:space="preserve" + * + */ + @Test(dataProvider = "xml-data-whitespace-ls") + public void testWhitespaceWithLSSerializer(String sourceFile, String expectedFile) throws Exception { + String source = read(sourceFile); + String expected = read(expectedFile); + // test it's no change if no pretty-print + String result = serializerWrite(toXmlDocument(source), false); + assertTrue(toXmlDocument(source).isEqualNode(toXmlDocument(result)), "The actual is: " + result); + // test pretty-print + assertEquals(serializerWrite(toXmlDocument(source), true), expected); + } + + /* + * test whitespace and element, nested xml:space property. + */ + @DataProvider(name = "xml-data-whitespace-xslt") + public Object[][] whitespaceXSLT() throws Exception { + return new Object[][] { + { "xmltest5.xml", "xmltest5xslt.out" }, + { "xmltest7.xml", "xmltest7xslt.out" } }; + } + + /* + * @bug 8087303 + * Test the transformer shall format the output but keep all + * whitespace text node even if xml:space="preserve" + * + */ + @Test(dataProvider = "xml-data-whitespace-xslt") + public void testWhitespaceWithTransformer(String sourceFile, String expectedFile) throws Exception { + String source = read(sourceFile); + String expected = read(expectedFile); + // test it's no change if no pretty-print + String result = transform(toXmlDocument(source), false); + assertTrue(toXmlDocument(source).isEqualNode(toXmlDocument(result)), "The actual is: " + result); + // test pretty-print + assertEquals(transform(toXmlDocument(source), true).replaceAll("\r\n", "\n"), expected); + } + /* * test block element, inline element, text, and mixed elements. */ @DataProvider(name = "html-data") public Object[][] htmlData() throws Exception { return new Object[][] { - { read("htmltest1.xml"), read("htmltest1.out") }, - { read("htmltest2.xml"), read("htmltest2.out") }, - { read("htmltest3.xml"), read("htmltest3.out") }, - { read("htmltest4.xml"), read("htmltest4.out") }, - { read("htmltest5.xml"), read("htmltest5.out") }, - { read("htmltest6.xml"), read("htmltest6.out") } }; + { "htmltest1.xml", "htmltest1.out" }, + { "htmltest2.xml", "htmltest2.out" }, + { "htmltest3.xml", "htmltest3.out" }, + { "htmltest4.xml", "htmltest4.out" }, + { "htmltest5.xml", "htmltest5.out" }, + { "htmltest6.xml", "htmltest6.out" }, + /* @bug 8174025, test whitespace between inline elements */ + { "htmltest7.xml", "htmltest7.out" } }; } /* @@ -146,7 +223,9 @@ public class PrettyPrintTest { * */ @Test(dataProvider = "html-data") - public void testTransformToHTML(String source, String expected) throws Exception { + public void testTransformToHTML(String sourceFile, String expectedFile) throws Exception { + String source = read(sourceFile); + String expected = read(expectedFile); // test it's no change if no pretty-print StringWriter writer = new StringWriter(); getTransformer(true, false).transform(new StreamSource(new StringReader(source)), new StreamResult(writer)); @@ -158,6 +237,27 @@ public class PrettyPrintTest { assertEquals(writer.toString().replaceAll("\r\n", "\n"), expected); } + /* + * @bug 8174025 + * Test the serializer can handle correctly. + * + */ + @Test + public void testDisableOutputEscaping() throws Exception { + final String xsl ="generate-catalog.xsl"; + final String xml ="simple-entity-resolver-config.xml"; + final String expectedOutput ="simple-entity-resolver-config-transformed.xml"; + TransformerFactory factory = TransformerFactory.newInstance(); + Transformer transformer = factory.newTemplates(new StreamSource(new StringReader(read(xsl)))).newTransformer(); + + String key = "schemaBase"; + String value = "schemas"; + transformer.setParameter(key, value); + StringWriter writer = new StringWriter(); + transformer.transform(new StreamSource(new StringReader(read(xml))), new StreamResult(writer)); + assertEquals(writer.toString().replaceAll("\r\n", "\n"), read(expectedOutput)); + } + @Test public void testLSSerializerFormatPrettyPrint() { @@ -298,6 +398,9 @@ public class PrettyPrintTest { Document doc = db.newDocument(); Node root = doc.createElement("root"); doc.appendChild(root); + root.appendChild(doc.createTextNode("\n")); + root.appendChild(doc.createTextNode("\n")); + root.appendChild(doc.createTextNode("\n")); root.appendChild(doc.createTextNode(" ")); root.appendChild(doc.createTextNode("t")); root.appendChild(doc.createTextNode("\n")); diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/generate-catalog.xsl b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/generate-catalog.xsl new file mode 100644 index 00000000000..e1b8e75171a --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/generate-catalog.xsl @@ -0,0 +1,23 @@ + + + + + + + + + + + + + <system systemId=" + + " uri=" + + " /> + + + + \ No newline at end of file diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest1.xml b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest1.xml index 50460626a7b..c0959b46dc8 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest1.xml +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest1.xml @@ -1 +1 @@ -Java Tutorials and Examples 1 en-us \ No newline at end of file +Java Tutorials and Examples 1en-us \ No newline at end of file diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest7.out b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest7.out new file mode 100644 index 00000000000..2ce8445a6dc --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest7.out @@ -0,0 +1,7 @@ + + +

    + this is a whitespace inline element test +

    + + diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest7.xml b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest7.xml new file mode 100644 index 00000000000..f1480607ef8 --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/htmltest7.xml @@ -0,0 +1 @@ +

    this is a whitespace inline element test

    \ No newline at end of file diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/nodetest2.out b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/nodetest2.out index a0d94368a3d..8a7d8fb0d18 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/nodetest2.out +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/nodetest2.out @@ -1,19 +1,30 @@ t t - + + t - - - + + + + + + t + t + t + + + + + diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/nodetest2ls.out b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/nodetest2ls.out new file mode 100644 index 00000000000..92e2d1f41e0 --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/nodetest2ls.out @@ -0,0 +1,18 @@ + + tt + + t + + + + + t + + t + + t + + + + + diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/simple-entity-resolver-config-transformed.xml b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/simple-entity-resolver-config-transformed.xml new file mode 100644 index 00000000000..238b5e2a2ac --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/simple-entity-resolver-config-transformed.xml @@ -0,0 +1,3 @@ + + + diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/simple-entity-resolver-config.xml b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/simple-entity-resolver-config.xml new file mode 100644 index 00000000000..9156728e13d --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/simple-entity-resolver-config.xml @@ -0,0 +1,20 @@ + + + + + Example 1 Schema Type library 10.0 + >-//Oracle//Example 1 Schema Type library 10.0//EN + http://www.example.test/oracle/schema/example1.xsd + META-INF/example1.xsd + + + Example 2 Schema Type library 10.0 + >-//Oracle//Example 2 Schema Type library 10.0//EN + http://www.example.test/oracle/schema/example2.xsd + META-INF/example2.xsd + + \ No newline at end of file diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest5.out b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest5ls.out similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest5.out rename to jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest5ls.out diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest5xslt.out b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest5xslt.out new file mode 100644 index 00000000000..4178e8ea9c2 --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest5xslt.out @@ -0,0 +1,15 @@ + + + + Java Tutorials and Examples 1 + + en-us + + + + + + + + + diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest7.out b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest7ls.out similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest7.out rename to jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest7ls.out diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest7xslt.out b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest7xslt.out new file mode 100644 index 00000000000..06296cddd1d --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest7xslt.out @@ -0,0 +1,17 @@ + + Java + + 5 + + + + + + + + + + + + + diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest8.out b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest8.out index 621263fbe19..b62fff27a78 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest8.out +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest8.out @@ -1,25 +1,20 @@ - - t + t - -t + t - - t + t - - t + t t - - t + t diff --git a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest8.xml b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest8.xml index e9c1c477d3a..6b9c54af8ed 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest8.xml +++ b/jaxp/test/javax/xml/jaxp/unittest/common/prettyprint/xmltest8.xml @@ -2,14 +2,7 @@ t t - t - - - t - - t - + t + tt t - - -
    +
    diff --git a/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSSerializerTest.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSSerializerTest.java index 9068969b318..50c79a962a6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSSerializerTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSSerializerTest.java @@ -279,11 +279,11 @@ public class LSSerializerTest { "\n" + " &name1;Jo Smith\n" + " b &name2;Jo Smith &name1;Jo Smith b\n" + - " &name;Jo Smith \n" + + " &name;Jo Smith \n" + " &ele1;d\n" + - " &ele2;eee \n" + + " &ele2;eee \n" + " <att>\n" + - " &ele; g\n" + + " &ele; g\n" + " &ele2;\n" + "\n"); @@ -301,7 +301,7 @@ public class LSSerializerTest { "\n" + " &name;Jo Smith\n" + " b &name;Jo Smith &name;Jo Smith b\n" + - " &name;Jo Smith \n" + + " &name;Jo Smith \n" + " \n" + " \n" + " text\n" + diff --git a/jaxp/test/javax/xml/jaxp/unittest/parsers/BaseParsingTest.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/BaseParsingTest.java new file mode 100644 index 00000000000..2d15fda1b0e --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/BaseParsingTest.java @@ -0,0 +1,158 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +package parsers; + +import java.io.StringReader; +import javax.xml.parsers.DocumentBuilder; +import javax.xml.parsers.DocumentBuilderFactory; +import javax.xml.stream.XMLInputFactory; +import javax.xml.stream.XMLStreamReader; +import org.testng.annotations.DataProvider; +import org.testng.annotations.Listeners; +import org.testng.annotations.Test; +import org.xml.sax.InputSource; + +/** + * @test + * @bug 8169450 + * @library /javax/xml/jaxp/libs /javax/xml/jaxp/unittest + * @run testng/othervm -DrunSecMngr=true parsers.BaseParsingTest + * @run testng/othervm parsers.BaseParsingTest + * @summary Tests that verify base parsing + */ +@Listeners({jaxp.library.BasePolicy.class}) +public class BaseParsingTest { + + @DataProvider(name = "xmlDeclarations") + public static Object[][] xmlDeclarations() { + return new Object[][]{ + {"t"}, + {"t"}, + {"t"}, + {"\n" + + "\n" + + " t\n" + + ""}, + {"\n" + + "\n" + + " t\n" + + ""}, + {"\n" + + "\n" + + " t\n" + + ""}, + {"\n" + + "\n" + + " t\n" + + ""}, + {"t"}, + {"t"}, + {"t"}, + {"\n" + + "\n" + + " t\n" + + ""}, + {"\n" + + "\n" + + " t\n" + + ""}, + {"\n" + + "\n" + + " t\n" + + ""}, + {"\n" + + "\n" + + " t\n" + + ""} + }; + } + + /** + * @bug 8169450 + * Verifies that the parser successfully parses the declarations provided in + * xmlDeclarations. Exception would otherwise be thrown as reported in 8169450. + * + * XML Declaration according to https://www.w3.org/TR/REC-xml/#NT-XMLDecl + * [23] XMLDecl ::= '' + * [24] VersionInfo ::= S 'version' Eq ("'" VersionNum "'" | '"' VersionNum '"') + * [25] Eq ::= S? '=' S? [26] VersionNum ::= '1.' [0-9]+ + * + * @param xml the test xml + * @throws Exception if the parser fails to parse the xml + */ + @Test(dataProvider = "xmlDeclarations") + public void test(String xml) throws Exception { + XMLInputFactory xif = XMLInputFactory.newDefaultFactory(); + XMLStreamReader xsr = xif.createXMLStreamReader(new StringReader(xml)); + while (xsr.hasNext()) { + xsr.next(); + } + } + + /** + * @bug 8169450 + * This particular issue does not appear in DOM parsing since the spaces are + * normalized during version detection. This test case then serves as a guard + * against such an issue from occuring in the version detection. + * + * @param xml the test xml + * @throws Exception if the parser fails to parse the xml + */ + @Test(dataProvider = "xmlDeclarations") + public void testWithDOM(String xml) throws Exception { + DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); + dbf.setValidating(true); + DocumentBuilder db = dbf.newDocumentBuilder(); + db.parse(new InputSource(new StringReader(xml))); + } +} diff --git a/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6341770.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6341770.java index 942e7ffaed8..1bf27aa09a0 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6341770.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6341770.java @@ -23,6 +23,7 @@ package parsers; +import static jaxp.library.JAXPTestUtilities.USER_DIR; import static jaxp.library.JAXPTestUtilities.tryRunWithTmpPermission; import java.io.File; @@ -61,7 +62,7 @@ public class Bug6341770 { return; } try { - File dir = new File(ALPHA); + File dir = new File(USER_DIR + ALPHA); dir.delete(); dir.mkdir(); File main = new File(dir, "main.xml"); diff --git a/jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778Test.java b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778Test.java index 4bd69f09765..be6dbc986f8 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778Test.java @@ -23,6 +23,7 @@ package sax; +import static jaxp.library.JAXPTestUtilities.USER_DIR; import static jaxp.library.JAXPTestUtilities.getSystemProperty; import static jaxp.library.JAXPTestUtilities.tryRunWithTmpPermission; @@ -69,7 +70,7 @@ public class Bug7057778Test { @Test public void testParse() { File src = new File(getClass().getResource(xml).getFile()); - File dst = new File(xml1); + File dst = new File(USER_DIR + xml1); try { copyFile(src, dst); SAXParserFactory spf = SAXParserFactory.newInstance(); diff --git a/jaxp/test/javax/xml/jaxp/unittest/sax/SymbolTableResetTest.java b/jaxp/test/javax/xml/jaxp/unittest/sax/SymbolTableResetTest.java new file mode 100644 index 00000000000..b56eb7ec9a9 --- /dev/null +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/SymbolTableResetTest.java @@ -0,0 +1,137 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package sax; + +import static jaxp.library.JAXPTestUtilities.runWithAllPerm; + +import java.io.StringReader; + +import javax.xml.parsers.SAXParser; +import javax.xml.parsers.SAXParserFactory; + +import org.testng.Assert; +import org.testng.annotations.Listeners; +import org.testng.annotations.Test; +import org.xml.sax.InputSource; +import org.xml.sax.helpers.DefaultHandler; + +/* + * @test + * @bug 8173390 8176168 + * @library /javax/xml/jaxp/libs /javax/xml/jaxp/unittest + * @run testng/othervm -Djdk.xml.resetSymbolTable=false sax.SymbolTableResetTest + * @run testng/othervm -Djdk.xml.resetSymbolTable=true sax.SymbolTableResetTest + * @run testng/othervm -Djdk.xml.resetSymbolTable=false -DrunSecMngr=true sax.SymbolTableResetTest + * @run testng/othervm -Djdk.xml.resetSymbolTable=true -DrunSecMngr=true sax.SymbolTableResetTest + * @summary Test that SAXParser reallocates symbol table during + * subsequent parse operations + */ +@Listeners({jaxp.library.BasePolicy.class}) +public class SymbolTableResetTest { + + /* + * Test verifies the following use cases when the parser feature is not set: + * a) Reset symbol table is requested via the system property + * b) Reset symbol table is not requested via the system property + * and therefore the default value should be used - reset + * operation should not occur. + */ + @Test + public void testNoFeatureSet() throws Exception { + parseAndCheckReset(false, false); + } + + + /* + * Test that when symbol table reset is requested through parser + * feature it is not affected by the system property value + */ + @Test + public void testResetEnabled() throws Exception { + parseAndCheckReset(true, true); + } + + /* + * Test that when symbol table reset is disabled through parser + * feature it is not affected by the system property value + */ + @Test + public void testResetDisabled() throws Exception { + parseAndCheckReset(true, false); + } + + /* + * Test mimics the SAXParser usage in SAAJ-RI that reuses the + * parsers from the internal pool. To avoid memory leaks, symbol + * table associated with the parser should be reallocated during each + * parse() operation. + */ + private void parseAndCheckReset(boolean setFeature, boolean value) throws Exception { + // Expected result based on system property and feature + boolean resetExpected = setFeature && value; + // Indicates if system property is set + boolean spSet = runWithAllPerm(() -> System.getProperty(RESET_FEATURE)) != null; + // Dummy xml input for parser + String input = "Test"; + + // Check if system property is set only when feature setting is not requested + // and estimate if reset of symbol table is expected + if (!setFeature && spSet) { + resetExpected = runWithAllPerm(() -> Boolean.getBoolean(RESET_FEATURE)); + } + + // Create SAXParser and set feature if it is requested + SAXParserFactory spf = SAXParserFactory.newInstance(); + if (setFeature) { + spf.setFeature(RESET_FEATURE, value); + } + SAXParser p = spf.newSAXParser(); + + // First parse iteration + p.parse(new InputSource(new StringReader(input)), new DefaultHandler()); + // Get first symbol table reference + Object symTable1 = p.getProperty(SYMBOL_TABLE_PROPERTY); + + // reset parser + p.reset(); + + // Second parse iteration + p.parse(new InputSource(new StringReader(input)), new DefaultHandler()); + // Get second symbol table reference + Object symTable2 = p.getProperty(SYMBOL_TABLE_PROPERTY); + + // Check symbol table references after two subsequent parse operations + if (resetExpected) { + Assert.assertNotSame(symTable1, symTable2, "Symbol table references"); + } else { + Assert.assertSame(symTable1, symTable2, "Symbol table references"); + } + } + + // Reset symbol table feature + private static final String RESET_FEATURE = "jdk.xml.resetSymbolTable"; + + // Symbol table property + private static final String SYMBOL_TABLE_PROPERTY = "http://apache.org/xml/properties/internal/symbol-table"; +} diff --git a/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6688002Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6688002Test.java index 1c4ac758575..1d1f728009d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6688002Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6688002Test.java @@ -23,6 +23,8 @@ package stream; +import static jaxp.library.JAXPTestUtilities.USER_DIR; + import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.InputStream; @@ -67,15 +69,15 @@ public class Bug6688002Test { } public class MyRunnable implements Runnable { - final int no; + final String no; MyRunnable(int no) { - this.no = no; + this.no = String.valueOf(no); } public void run() { try { - FileOutputStream fos = new FileOutputStream("" + no); + FileOutputStream fos = new FileOutputStream(USER_DIR + no); XMLStreamWriter w = getWriter(fos); // System.out.println("Writer="+w+" Thread="+Thread.currentThread()); w.writeStartDocument(); @@ -89,7 +91,7 @@ public class Bug6688002Test { w.close(); fos.close(); - FileInputStream fis = new FileInputStream("" + no); + FileInputStream fis = new FileInputStream(USER_DIR + no); XMLStreamReader r = getReader(fis); while (r.hasNext()) { r.next(); diff --git a/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.java index 3bd3ca25296..28b871afcd9 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.java @@ -23,6 +23,8 @@ package stream.XMLEventWriterTest; +import static jaxp.library.JAXPTestUtilities.USER_DIR; + import java.io.ByteArrayOutputStream; import java.io.File; import java.io.FileInputStream; @@ -58,7 +60,7 @@ public class ReaderToWriterTest { private static final XMLOutputFactory XML_OUTPUT_FACTORY = XMLOutputFactory.newInstance(); private static final String INPUT_FILE = "W2JDLR4002TestService.wsdl.data"; - private static final String OUTPUT_FILE = "Encoded.wsdl"; + private static final String OUTPUT_FILE = USER_DIR + "Encoded.wsdl"; /** * Unit test for writing namespaces when namespaceURI == null. @@ -126,7 +128,7 @@ public class ReaderToWriterTest { try { InputStream in = getClass().getResourceAsStream("ReaderToWriterTest.wsdl"); - OutputStream out = new FileOutputStream("ReaderToWriterTest-out.xml"); + OutputStream out = new FileOutputStream(USER_DIR + "ReaderToWriterTest-out.xml"); XMLEventReader reader = XML_INPUT_FACTORY.createXMLEventReader(in); XMLEventWriter writer = XML_OUTPUT_FACTORY.createXMLEventWriter(out, "UTF-8"); diff --git a/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/WriterTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/WriterTest.java index 7e681e343c4..abb9957a256 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/WriterTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/WriterTest.java @@ -23,6 +23,8 @@ package stream.XMLStreamWriterTest; +import static jaxp.library.JAXPTestUtilities.USER_DIR; + import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.IOException; @@ -84,7 +86,7 @@ public class WriterTest { System.out.println("Test StreamWriter with out any namespace functionality"); try { - String outputFile = files[0] + ".out"; + String outputFile = USER_DIR + files[0] + ".out"; System.out.println("Writing output to " + outputFile); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -98,7 +100,7 @@ public class WriterTest { xtw.flush(); xtw.close(); - Assert.assertTrue(checkResults(files[0] + ".out", files[0] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[0] + ".org")); } catch (Exception ex) { Assert.fail("testOne Failed " + ex); @@ -113,7 +115,7 @@ public class WriterTest { System.out.println("Test StreamWriter's Namespace Context"); try { - String outputFile = files[1] + ".out"; + String outputFile = USER_DIR + files[1] + ".out"; System.out.println("Writing output to " + outputFile); xtw = outputFactory.createXMLStreamWriter(System.out); @@ -157,7 +159,7 @@ public class WriterTest { System.out.println("Test StreamWriter for proper element sequence."); try { - String outputFile = files[2] + ".out"; + String outputFile = USER_DIR + files[2] + ".out"; System.out.println("Writing output to " + outputFile); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -172,7 +174,7 @@ public class WriterTest { xtw.flush(); xtw.close(); - Assert.assertTrue(checkResults(files[2] + ".out", files[2] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[2] + ".org")); } catch (Exception ex) { Assert.fail("testThree Failed " + ex); @@ -188,7 +190,7 @@ public class WriterTest { try { - String outputFile = files[3] + ".out"; + String outputFile = USER_DIR + files[3] + ".out"; System.out.println("Writing output to " + outputFile); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -205,7 +207,7 @@ public class WriterTest { xtw.flush(); xtw.close(); - Assert.assertTrue(checkResults(files[3] + ".out", files[3] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[3] + ".org")); } catch (Exception ex) { Assert.fail("testFour Failed " + ex); @@ -221,7 +223,7 @@ public class WriterTest { try { - String outputFile = files[4] + ".out"; + String outputFile = USER_DIR + files[4] + ".out"; System.out.println("Writing output to " + outputFile); xtw = outputFactory.createXMLStreamWriter(System.out); @@ -265,7 +267,7 @@ public class WriterTest { xtw.writeEndDocument(); xtw.flush(); xtw.close(); - Assert.assertTrue(checkResults(files[4] + ".out", files[4] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[4] + ".org")); System.out.println("Done"); } catch (Exception ex) { Assert.fail("testFive Failed " + ex); @@ -281,7 +283,7 @@ public class WriterTest { try { - String outputFile = files[5] + ".out"; + String outputFile = USER_DIR + files[5] + ".out"; System.out.println("Writing output to " + outputFile); xtw = outputFactory.createXMLStreamWriter(System.out); @@ -325,7 +327,7 @@ public class WriterTest { xtw.writeEndDocument(); xtw.flush(); xtw.close(); - Assert.assertTrue(checkResults(files[5] + ".out", files[5] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[5] + ".org")); System.out.println("Done"); } catch (Exception ex) { Assert.fail("testSix Failed " + ex); @@ -341,7 +343,7 @@ public class WriterTest { try { - String outputFile = files[6] + ".out"; + String outputFile = USER_DIR + files[6] + ".out"; System.out.println("Writing output to " + outputFile); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -374,7 +376,7 @@ public class WriterTest { xtw.writeEndDocument(); xtw.flush(); xtw.close(); - Assert.assertTrue(checkResults(files[6] + ".out", files[6] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[6] + ".org")); System.out.println("Done"); } catch (Exception ex) { Assert.fail("testSeven Failed " + ex); @@ -390,7 +392,7 @@ public class WriterTest { try { - String outputFile = files[7] + ".out"; + String outputFile = USER_DIR + files[7] + ".out"; System.out.println("Writing output to " + outputFile); outputFactory.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, new Boolean(true)); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -424,7 +426,7 @@ public class WriterTest { xtw.flush(); xtw.close(); // check against testSeven.xml.org - Assert.assertTrue(checkResults(files[7] + ".out", files[7] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[7] + ".org")); System.out.println("Done"); } catch (Exception ex) { ex.printStackTrace(); @@ -442,7 +444,7 @@ public class WriterTest { try { - String outputFile = files[8] + ".out"; + String outputFile = USER_DIR + files[8] + ".out"; System.out.println("Writing output to " + outputFile); outputFactory.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, new Boolean(true)); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -476,7 +478,7 @@ public class WriterTest { xtw.flush(); xtw.close(); // check against testSeven.xml.org - Assert.assertTrue(checkResults(files[8] + ".out", files[7] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[7] + ".org")); System.out.println("Done"); } catch (Exception ex) { Assert.fail("testNine Failed " + ex); @@ -491,7 +493,7 @@ public class WriterTest { System.out.println("Test StreamWriter supplied with no namespace information and" + "isRepairingNamespace is set to true."); try { - String outputFile = files[9] + ".out"; + String outputFile = USER_DIR + files[9] + ".out"; System.out.println("Writing output to " + outputFile); outputFactory.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, new Boolean(true)); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -542,7 +544,7 @@ public class WriterTest { System.out.println("Test StreamWriter supplied with namespace information passed through startElement and" + "isRepairingNamespace is set to true."); try { - String outputFile = files[10] + ".out"; + String outputFile = USER_DIR + files[10] + ".out"; System.out.println("Writing output to " + outputFile); outputFactory.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, new Boolean(true)); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -576,7 +578,7 @@ public class WriterTest { xtw.flush(); xtw.close(); // check against testSeven.xml.org - Assert.assertTrue(checkResults(files[10] + ".out", files[7] + ".org")); + Assert.assertTrue(checkResults(outputFile, files[7] + ".org")); System.out.println("Done"); } catch (Exception ex) { Assert.fail("testEleven Failed " + ex); @@ -592,7 +594,7 @@ public class WriterTest { try { - String outputFile = files[11] + ".out"; + String outputFile = USER_DIR + files[11] + ".out"; System.out.println("Writing output to " + outputFile); outputFactory.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, new Boolean(true)); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -643,7 +645,7 @@ public class WriterTest { try { - String outputFile = files[12] + ".out"; + String outputFile = USER_DIR + files[12] + ".out"; System.out.println("Writing output to " + outputFile); outputFactory.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, new Boolean(true)); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); @@ -695,7 +697,7 @@ public class WriterTest { try { - String outputFile = files[14] + ".out"; + String outputFile = USER_DIR + files[14] + ".out"; System.out.println("Writing output to " + outputFile); outputFactory.setProperty(XMLOutputFactory.IS_REPAIRING_NAMESPACES, new Boolean(true)); xtw = outputFactory.createXMLStreamWriter(new FileOutputStream(outputFile), ENCODING); diff --git a/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341Test.java index 2b2a1e94506..1e4266d65e7 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341Test.java @@ -23,6 +23,8 @@ package transform; +import static jaxp.library.JAXPTestUtilities.USER_DIR; + import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStream; @@ -55,7 +57,7 @@ public class Bug4693341Test { // save dtd file to current working directory to avoid writing into source repository public void copyDTDtoWorkDir() throws IOException { try (FileInputStream dtdres = new FileInputStream(getClass().getResource("Bug4693341.dtd").getPath()); - FileOutputStream dtdwork = new FileOutputStream("Bug4693341.dtd");) { + FileOutputStream dtdwork = new FileOutputStream(USER_DIR + "Bug4693341.dtd");) { int n; byte[] buffer = new byte[1024]; while((n = dtdres.read(buffer)) > -1) { @@ -71,7 +73,7 @@ public class Bug4693341Test { copyDTDtoWorkDir(); - File outf = new File("Bug4693341.out"); + File outf = new File(USER_DIR + "Bug4693341.out"); StreamResult result = new StreamResult(new FileOutputStream(outf)); String in = getClass().getResource("Bug4693341.xml").getPath(); diff --git a/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4892774.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4892774.java index cb92eb762ed..0419c1cf8bc 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4892774.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4892774.java @@ -23,6 +23,8 @@ package transform; +import static jaxp.library.JAXPTestUtilities.USER_DIR; + import java.io.File; import javax.xml.transform.Source; @@ -58,7 +60,7 @@ public class Bug4892774 { private final String XML_FILE = "catalog.xml"; private final String XML10_FILE = "catalog_10.xml"; // 1.0 version document - private final String TEMP_FILE = "tmp.xml"; + private final String TEMP_FILE = USER_DIR + "tmp.xml"; private final String EXPECTED_VERSION = "1.1"; static private Transformer idTransform = null; diff --git a/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6216226Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6216226Test.java index 7031585a864..9ba16dbc9c1 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6216226Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6216226Test.java @@ -23,6 +23,7 @@ package transform; +import static jaxp.library.JAXPTestUtilities.USER_DIR; import static jaxp.library.JAXPTestUtilities.runWithTmpPermission; import java.io.File; @@ -52,7 +53,7 @@ public class Bug6216226Test { @Test public final void test() { try { - File test = new File("bug6216226.txt"); + File test = new File(USER_DIR + "bug6216226.txt"); TransformerFactory tf = TransformerFactory.newInstance(); Transformer xformer = tf.newTransformer(); StringReader st = new StringReader(""); diff --git a/jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697Test.java index db8d8721d2e..fe65ee0e7a9 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697Test.java @@ -23,6 +23,8 @@ package transform; +import static jaxp.library.JAXPTestUtilities.USER_DIR; + import java.io.FileOutputStream; import javax.xml.transform.Result; @@ -65,7 +67,7 @@ public class CR6935697Test { Transformer xformer = template.newTransformer(); // Prepare the input and output files Source source = new StreamSource(getClass().getResourceAsStream(inFilename)); - Result result = new StreamResult(new FileOutputStream(outFilename)); + Result result = new StreamResult(new FileOutputStream(USER_DIR + outFilename)); // Apply the xsl file to the source file and write the result to the // output file xformer.transform(source, result); diff --git a/jaxp/test/javax/xml/jaxp/unittest/transform/XSLTFunctionsTest.java b/jaxp/test/javax/xml/jaxp/unittest/transform/XSLTFunctionsTest.java index 87360daf486..3f99410869b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/transform/XSLTFunctionsTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/XSLTFunctionsTest.java @@ -23,6 +23,7 @@ package transform; +import java.io.FilePermission; import java.io.IOException; import java.io.StringReader; import java.io.StringWriter; @@ -46,6 +47,7 @@ import static org.testng.Assert.assertEquals; import static jaxp.library.JAXPTestUtilities.runWithAllPerm; import static jaxp.library.JAXPTestUtilities.clearSystemProperty; import static jaxp.library.JAXPTestUtilities.setSystemProperty; +import static jaxp.library.JAXPTestUtilities.tryRunWithTmpPermission; import static jaxp.library.JAXPTestUtilities.getSystemProperty; /* @@ -77,7 +79,9 @@ public class XSLTFunctionsTest { Transformer t = tf.newTransformer(new StreamSource(new StringReader(xsl))); //Transform the xml - t.transform(new StreamSource(new StringReader(xml)), new StreamResult(new StringWriter())); + tryRunWithTmpPermission( + () -> t.transform(new StreamSource(new StringReader(xml)), new StreamResult(new StringWriter())), + new FilePermission(output, "write"), new FilePermission(redirect, "write")); // Verifies that the output is redirected successfully String userDir = getSystemProperty("user.dir"); diff --git a/jaxp/test/javax/xml/jaxp/unittest/transform/util/TransformerUtil.java b/jaxp/test/javax/xml/jaxp/unittest/transform/util/TransformerUtil.java index 61d7bfe09db..3294aeb93ae 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/transform/util/TransformerUtil.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/util/TransformerUtil.java @@ -23,6 +23,8 @@ package transform.util; +import static jaxp.library.JAXPTestUtilities.USER_DIR; + import java.io.InputStream; import javax.xml.parsers.DocumentBuilder; @@ -34,7 +36,7 @@ public abstract class TransformerUtil { protected String type; - protected final String TEMP_FILE = "tmp.xml"; + protected final String TEMP_FILE = USER_DIR + "tmp.xml"; public abstract Source prepareSource(InputStream is) throws Exception; diff --git a/jaxp/test/javax/xml/jaxp/unittest/validation/CR6708840Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/CR6708840Test.java index d3a0f1ef40c..71f55a4f3c4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/validation/CR6708840Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/CR6708840Test.java @@ -23,6 +23,8 @@ package validation; +import static jaxp.library.JAXPTestUtilities.USER_DIR; + import java.io.File; import java.io.FileWriter; @@ -122,7 +124,7 @@ public class CR6708840Test { Validator schemaValidator = schemaGrammar.newValidator(); Source staxSrc = new StAXSource(staxReader); - File resultFile = new File("gMonths.result.xml"); + File resultFile = new File(USER_DIR + "gMonths.result.xml"); if (resultFile.exists()) { resultFile.delete(); } diff --git a/jaxp/test/javax/xml/jaxp/unittest/validation/ValidatorTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/ValidatorTest.java index 40ca0cc8d3a..22317b325bb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/validation/ValidatorTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/ValidatorTest.java @@ -23,6 +23,7 @@ package validation; +import static jaxp.library.JAXPTestUtilities.USER_DIR; import static jaxp.library.JAXPTestUtilities.runWithTmpPermission; import java.io.File; @@ -61,7 +62,7 @@ public class ValidatorTest { File resultFile = null; try { - resultFile = new File("stax.result"); + resultFile = new File(USER_DIR + "stax.result"); if (resultFile.exists()) { resultFile.delete(); } @@ -88,7 +89,7 @@ public class ValidatorTest { File resultFile = null; try { - resultFile = new File("stax.result"); + resultFile = new File(USER_DIR + "stax.result"); if (resultFile.exists()) { resultFile.delete(); } @@ -117,7 +118,7 @@ public class ValidatorTest { // test valid gMonths File resultFile = null; try { - resultFile = new File("gMonths.result.xml"); + resultFile = new File(USER_DIR + "gMonths.result.xml"); if (resultFile.exists()) { resultFile.delete(); } @@ -144,7 +145,7 @@ public class ValidatorTest { // test invalid gMonths File invalidResultFile = null; try { - invalidResultFile = new File("gMonths-invalid.result.xml"); + invalidResultFile = new File(USER_DIR + "gMonths-invalid.result.xml"); if (invalidResultFile.exists()) { invalidResultFile.delete(); } diff --git a/jaxws/.hgtags b/jaxws/.hgtags index b130a70170d..2b6bb02bcf0 100644 --- a/jaxws/.hgtags +++ b/jaxws/.hgtags @@ -399,5 +399,35 @@ c8c9c334743caf8155c9809b6b4ac315d3a66476 jdk-9+148 c48b4d4768b1c2b8fe5d1a844ca13732e5dfbe2a jdk-9+151 6f8fb1cf7e5f61c40dcc3654f9a623c505f6de1f jdk-9+152 7a532a9a227137155b905341d4b99939db51220e jdk-9+153 +34af95c7dbff74f3448fcdb7d745524e8a1cc88a jdk-10+0 34af95c7dbff74f3448fcdb7d745524e8a1cc88a jdk-9+154 9b9918656c97724fd89c04a8547043bbd37f5935 jdk-9+155 +7c829eba781409b4fe15392639289af1553dcf63 jdk-9+156 +6afc1d9b8c41457cc8ebe2e1a27b8fd6d887c1fb jdk-10+1 +b7e70e1e0154e1d2c69f814e03a8800ef8634fe0 jdk-9+157 +e53b322357382209fb553b9a1541ccfd12cbcb6c jdk-9+158 +0ea34706c7fa5cd71accd493eb4f54262e4a5f4e jdk-9+159 +6bff08fd5d217549aec10a20007378e52099be6c jdk-9+160 +7d5352c54fc802b3301d8433b6b2b2a92b616630 jdk-9+161 +b8aebe5292f23689f97cb8e66a9f327834dd43e6 jdk-9+162 +3890f96e8995be8c84f330d1f65269b03ac36b24 jdk-9+163 +1a52de2da827459e866fd736f9e9c62eb2ecd6bb jdk-9+164 +a987401bac0d528475e57732c9d5d93f4405804c jdk-9+165 +b1f30c27367bd286fa4eb8a767335e917a5b5b82 jdk-9+166 +06b9f0de66d3a17a10af380c950619c63b62d4cd jdk-10+2 +2e2c78f1713b2c6b760b870946d2b4341a1522e3 jdk-10+3 +ac7e572a6a6ba5bbd7e6aa94a289f88cc86256a4 jdk-10+4 +879aad463c21065254918629e6dfd7d7bf98adb2 jdk-10+5 +85e15cdc75aaaea8a1bb00563af7889869d3e602 jdk-10+6 +1c610f1b4097c64cdd722a7fb59f5a4d9cc15ca9 jdk-9+167 +2746716dcc5a8c28ccf41df0c8fb620b1a1e7098 jdk-9+168 +912cf69806d518c5af7fba30b340c4cb5458dd22 jdk-9+169 +e75d3abe579a7b39b762fc0a1a337c49eb072d82 jdk-9+170 +b0efae7df1dfa14926058baebaf999e4268c955c jdk-10+7 +e705867d9989d00e4357f66f18b302c95e13b5e7 jdk-10+8 +2fe03e35bed54238bcaeeb298b011df240e3711d jdk-10+9 +139e7c786ee4885efe53eb650b72c7b5a2d3b964 jdk-9+171 +3ccd9f37faa601866db5edb827363e797f5a2493 jdk-10+10 +8c615099f3e3ca137325be34bf566b767d9e3c64 jdk-9+172 +2d22d6732a73e615b9e13d6bc93bf026db3bc231 jdk-10+11 +2bd967aa452c1e0e87a6173bef6fbb96ef1c521b jdk-9+173 diff --git a/jaxws/.jcheck/conf b/jaxws/.jcheck/conf index 5c6f62dc12c..b2581358014 100644 --- a/jaxws/.jcheck/conf +++ b/jaxws/.jcheck/conf @@ -1 +1 @@ -project=jdk9 +project=jdk10 diff --git a/jaxws/README b/jaxws/README deleted file mode 100644 index 4d65125b34c..00000000000 --- a/jaxws/README +++ /dev/null @@ -1,19 +0,0 @@ -README: - - This file should be located at the top of the Mercurial repository. - - See http://openjdk.java.net/ for more information about the OpenJDK. - - See ../README-builds.html for complete details on build machine requirements. - -Simple Build Instructions: - This repository can be loaded as a NetBeans project, built with ant, or - built with GNU make, e.g. - ant - -OR- - cd make && gnumake - - The built files that will be imported into the jdk build will be in the - "dist" directory. - Help information is available by running "ant -projecthelp" or "make help". - diff --git a/jaxws/src/java.activation/share/classes/META-INF/mimetypes.default b/jaxws/src/java.activation/share/classes/META-INF/mimetypes.default index 0c22eb2efb8..1b4056b194f 100644 --- a/jaxws/src/java.activation/share/classes/META-INF/mimetypes.default +++ b/jaxws/src/java.activation/share/classes/META-INF/mimetypes.default @@ -7,6 +7,7 @@ image/gif gif GIF image/ief ief image/jpeg jpeg jpg jpe JPG image/tiff tiff tif +image/png png PNG image/x-xwindowdump xwd application/postscript ai eps ps application/rtf rtf diff --git a/jaxws/src/java.activation/share/classes/module-info.java b/jaxws/src/java.activation/share/classes/module-info.java index 00d40e18550..8132ff67295 100644 --- a/jaxws/src/java.activation/share/classes/module-info.java +++ b/jaxws/src/java.activation/share/classes/module-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,11 @@ /** * Defines the JavaBeans Activation Framework (JAF) API. + * + * @moduleGraph + * @since 9 */ +@Deprecated(since="9", forRemoval=true) module java.activation { requires transitive java.datatransfer; requires java.logging; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/Localizable.java b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/Localizable.java index 2f4da84f319..0406d5b4c6b 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/Localizable.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/Localizable.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -54,9 +54,7 @@ public interface Localizable { public Object[] getArguments(); public String getResourceBundleName(); - public default ResourceBundle getResourceBundle(Locale locale) { - return null; - } + public ResourceBundle getResourceBundle(Locale locale); /** * Special constant that represents a message that diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/LocalizableMessage.java b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/LocalizableMessage.java index 1d7ace5146c..747110e350f 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/LocalizableMessage.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/LocalizableMessage.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,6 +31,7 @@ import java.util.Arrays; import java.util.Locale; import java.util.ResourceBundle; + /** * @author WS Development Team */ @@ -42,13 +43,9 @@ public final class LocalizableMessage implements Localizable { private final String _key; private final Object[] _args; + @Deprecated public LocalizableMessage(String bundlename, String key, Object... args) { - _bundlename = bundlename; - _rbSupplier = null; - _key = key; - if(args==null) - args = new Object[0]; - _args = args; + this(bundlename, null, key, args); } public LocalizableMessage(String bundlename, ResourceBundleSupplier rbSupplier, @@ -61,15 +58,17 @@ public final class LocalizableMessage implements Localizable { _args = args; } - + @Override public String getKey() { return _key; } + @Override public Object[] getArguments() { return Arrays.copyOf(_args, _args.length); } + @Override public String getResourceBundleName() { return _bundlename; } diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/LocalizableMessageFactory.java b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/LocalizableMessageFactory.java index bf8a28b76f3..e4d5a126962 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/LocalizableMessageFactory.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/LocalizableMessageFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,6 +36,7 @@ public class LocalizableMessageFactory { private final String _bundlename; private final ResourceBundleSupplier _rbSupplier; + @Deprecated public LocalizableMessageFactory(String bundlename) { _bundlename = bundlename; _rbSupplier = null; @@ -58,4 +59,5 @@ public class LocalizableMessageFactory { */ ResourceBundle getResourceBundle(Locale locale); } + } diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/Localizer.java b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/Localizer.java index 2f78673eab0..a0436beafa1 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/Localizer.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/Localizer.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,6 @@ package com.sun.istack.internal.localization; -import com.sun.istack.internal.localization.LocalizableMessageFactory.ResourceBundleSupplier; import java.text.MessageFormat; import java.util.HashMap; import java.util.Locale; @@ -41,7 +40,7 @@ import java.util.ResourceBundle; public class Localizer { private final Locale _locale; - private final HashMap _resourceBundles; + private final HashMap _resourceBundles; public Localizer() { this(Locale.getDefault()); @@ -49,7 +48,7 @@ public class Localizer { public Localizer(Locale l) { _locale = l; - _resourceBundles = new HashMap(); + _resourceBundles = new HashMap<>(); } public Locale getLocale() { diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/NullLocalizable.java b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/NullLocalizable.java index e0fb44621f4..f9f0b7abe09 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/NullLocalizable.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/istack/internal/localization/NullLocalizable.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,9 @@ package com.sun.istack.internal.localization; +import java.util.Locale; +import java.util.ResourceBundle; + /** * {@link Localizable} that wraps a non-localizable string. * @@ -39,13 +42,20 @@ public final class NullLocalizable implements Localizable { this.msg = msg; } + @Override public String getKey() { return Localizable.NOT_LOCALIZABLE; } + @Override public Object[] getArguments() { return new Object[]{msg}; } + @Override public String getResourceBundleName() { return ""; } + @Override + public ResourceBundle getResourceBundle(Locale locale) { + return null; + } } diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/api/JAXBRIContext.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/api/JAXBRIContext.java index a27f0825fe8..fcf907d88ee 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/api/JAXBRIContext.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/api/JAXBRIContext.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -533,4 +533,14 @@ public abstract class JAXBRIContext extends JAXBContext { * @since 2.2.6 */ public static final String DISABLE_XML_SECURITY = "com.sun.xml.internal.bind.disableXmlSecurity"; + + /** + * If true and element namespace is not specified, namespace of parent element will be used. + * The default value is false. + * + * Boolean + * @since 2.3.0 + */ + public static final String BACKUP_WITH_PARENT_NAMESPACE = "com.sun.xml.internal.bind.backupWithParentNamespace"; + } diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/ContextFactory.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/ContextFactory.java index a18f79e1d58..73fe277419f 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/ContextFactory.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/ContextFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -112,6 +112,8 @@ public class ContextFactory { "is not active. Using JAXB's implementation"); } + Boolean backupWithParentNamespace = getPropertyValue(properties, JAXBRIContext.BACKUP_WITH_PARENT_NAMESPACE, Boolean.class); + RuntimeAnnotationReader ar = getPropertyValue(properties,JAXBRIContext.ANNOTATION_READER,RuntimeAnnotationReader.class); Collection tr = getPropertyValue(properties, JAXBRIContext.TYPE_REFERENCES, Collection.class); @@ -144,6 +146,7 @@ public class ContextFactory { builder.setSupressAccessorWarnings(supressAccessorWarnings); builder.setImprovedXsiTypeHandling(improvedXsiTypeHandling); builder.setDisableSecurityProcessing(disablesecurityProcessing); + builder.setBackupWithParentNamespace(backupWithParentNamespace); return builder.build(); } diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/bytecode/package-info.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/bytecode/package-info.java new file mode 100644 index 00000000000..848316f6c53 --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/bytecode/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Code that deals with low level byte code manipulation. + */ +package com.sun.xml.internal.bind.v2.bytecode; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/bytecode/package.html b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/bytecode/package.html deleted file mode 100644 index 092f6f3e5d2..00000000000 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/bytecode/package.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - Code that deals with low level byte code manipulation. - - diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/annotation/package-info.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/annotation/package-info.java new file mode 100644 index 00000000000..40328931c18 --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/annotation/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Abstraction around reading annotations, to support internal/external annotations. + */ +package com.sun.xml.internal.bind.v2.model.annotation; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/annotation/package.html b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/annotation/package.html deleted file mode 100644 index acc9be725ab..00000000000 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/annotation/package.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - Abstraction around reading annotations, to support internal/external annotations. - diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/ErrorHandler.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/ErrorHandler.java index 5b97093d3fd..c584056f611 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/ErrorHandler.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/ErrorHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,24 +29,25 @@ import com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationException; /** * listen to static errors found during building a JAXB model from a set of classes. - * Implemented by the client of {@link com.sun.xml.internal.bind.v2.model.impl.ModelBuilder}. + * Implemented by the client of {@link com.sun.xml.internal.bind.v2.model.impl.ModelBuilderI}. * *

    * All the static errors have to be reported while constructing a - * model, not when a model is used (IOW, until the {@link com.sun.xml.internal.bind.v2.model.impl.ModelBuilder#link} completes. - * Internally, {@link com.sun.xml.internal.bind.v2.model.impl.ModelBuilder} wraps an {@link ErrorHandler} and all the model + * model, not when a model is used (IOW, until the {@link com.sun.xml.internal.bind.v2.model.impl.ModelBuilderI} completes. + * Internally, {@link com.sun.xml.internal.bind.v2.model.impl.ModelBuilderI} wraps an {@link ErrorHandler} and all the model * components should report errors through it. * *

    * {@link IllegalAnnotationException} is a checked exception to remind * the model classes to report it rather than to throw it. * - * @see com.sun.xml.internal.bind.v2.model.impl.ModelBuilder + * @see com.sun.xml.internal.bind.v2.model.impl.ModelBuilderI * @author Kohsuke Kawaguchi */ public interface ErrorHandler { /** * Receives a notification for an error in the annotated code. + * @param e */ void error( IllegalAnnotationException e ); } diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/PropertyKind.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/PropertyKind.java index c3406b7da6f..83caf8f4f04 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/PropertyKind.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/PropertyKind.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -57,7 +57,7 @@ public enum PropertyKind { public final boolean isOrdered; /** - * {@link com.sun.xml.internal.bind.v2.runtime.property.PropertyFactory} benefits from having index numbers assigned to + * {@code com.sun.xml.internal.bind.v2.runtime.property.PropertyFactory} benefits from having index numbers assigned to * {@link #ELEMENT}, {@link #REFERENCE}, and {@link #MAP} in this order. */ public final int propertyIndex; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/RegistryInfo.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/RegistryInfo.java index 794c3396d25..9bfe5e04209 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/RegistryInfo.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/core/RegistryInfo.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,18 +34,22 @@ import javax.xml.bind.annotation.XmlRegistry; * *

    * This interface is only meant to be used as a return type from - * {@link com.sun.xml.internal.bind.v2.model.impl.ModelBuilder}. + * {@link com.sun.xml.internal.bind.v2.model.impl.ModelBuilderI}. * * @author Kohsuke Kawaguchi + * @param + * @param */ public interface RegistryInfo { /** * Returns all the references to other types in this registry. + * @return */ Set> getReferences(); /** * Returns the class with {@link XmlRegistry}. + * @return */ C getClazz(); } diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/impl/package-info.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/impl/package-info.java new file mode 100644 index 00000000000..68abc10902c --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/impl/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Implementation of the com.sun.xml.internal.bind.j2s.model package. + */ +package com.sun.xml.internal.bind.v2.model.impl; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/impl/package.html b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/impl/package.html deleted file mode 100644 index e37eebd2ac4..00000000000 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/impl/package.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - -Implementation of the com.sun.xml.internal.bind.j2s.model package. - - diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/nav/package-info.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/nav/package-info.java new file mode 100644 index 00000000000..ea3b945f33c --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/nav/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Abstraction around the reflection library, to support various reflection models (such as java.lang.reflect and Annotation Processing). + */ +package com.sun.xml.internal.bind.v2.model.nav; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/nav/package.html b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/nav/package.html deleted file mode 100644 index 319f86c97b9..00000000000 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/model/nav/package.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - Abstraction around the reflection library, to support various reflection models (such as java.lang.reflect and Annotation Processing). - diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/JAXBContextImpl.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/JAXBContextImpl.java index 3c918598348..5a03996782a 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/JAXBContextImpl.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/JAXBContextImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -241,6 +241,16 @@ public final class JAXBContextImpl extends JAXBRIContext { private Set xmlNsSet = null; + /** + * If true, despite the specification, unmarshall child element with parent namespace, if child namespace is not specified. + * The default value is null for System {code}com.sun.xml.internal.bind.backupWithParentNamespace{code} property to be used, + * and false is assumed if it's not set either. + * + * Boolean + * @since 2.3.0 + */ + public Boolean backupWithParentNamespace = null; + /** * Returns declared XmlNs annotations (from package-level annotation XmlSchema * @@ -263,6 +273,7 @@ public final class JAXBContextImpl extends JAXBRIContext { this.supressAccessorWarnings = builder.supressAccessorWarnings; this.improvedXsiTypeHandling = builder.improvedXsiTypeHandling; this.disableSecurityProcessing = builder.disableSecurityProcessing; + this.backupWithParentNamespace = builder.backupWithParentNamespace; Collection typeRefs = builder.typeRefs; @@ -1024,6 +1035,7 @@ public final class JAXBContextImpl extends JAXBRIContext { private boolean allNillable; private boolean improvedXsiTypeHandling = true; private boolean disableSecurityProcessing = true; + private Boolean backupWithParentNamespace = null; // null for System property to be used public JAXBContextBuilder() {}; @@ -1039,6 +1051,7 @@ public final class JAXBContextImpl extends JAXBRIContext { this.xmlAccessorFactorySupport = baseImpl.xmlAccessorFactorySupport; this.allNillable = baseImpl.allNillable; this.disableSecurityProcessing = baseImpl.disableSecurityProcessing; + this.backupWithParentNamespace = baseImpl.backupWithParentNamespace; } public JAXBContextBuilder setRetainPropertyInfo(boolean val) { @@ -1101,6 +1114,11 @@ public final class JAXBContextImpl extends JAXBRIContext { return this; } + public JAXBContextBuilder setBackupWithParentNamespace(Boolean backupWithParentNamespace) { + this.backupWithParentNamespace = backupWithParentNamespace; + return this; + } + public JAXBContextImpl build() throws JAXBException { // fool-proof diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/package-info.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/package-info.java new file mode 100644 index 00000000000..3ae977b9d19 --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Code that implements JAXBContext, Unmarshaller, and Marshaller. + */ +package com.sun.xml.internal.bind.v2.runtime; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/package.html b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/package.html deleted file mode 100644 index 2c45e53176e..00000000000 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/package.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - -Code that implements JAXBContext, Unmarshaller, and Marshaller. - - diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/AccessorInjector.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/AccessorInjector.java index 1be59952231..d2154319c48 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/AccessorInjector.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/AccessorInjector.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -39,7 +39,7 @@ class AccessorInjector { private static final Logger logger = Util.getClassLogger(); - protected static final boolean noOptimize = Runtime.version().major() >= 9 || + protected static final boolean noOptimize = Util.getSystemProperty(ClassTailor.class.getName()+".noOptimize")!=null; static { diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/Injector.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/Injector.java index 17c99557d9f..9e00016d7e9 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/Injector.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/Injector.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -40,6 +40,11 @@ import java.util.logging.Logger; import com.sun.xml.internal.bind.Util; import com.sun.xml.internal.bind.v2.runtime.reflect.Accessor; +import java.lang.reflect.Field; +import java.security.CodeSource; +import java.security.PrivilegedActionException; +import java.security.PrivilegedExceptionAction; +import java.security.ProtectionDomain; /** * A {@link ClassLoader} used to "inject" optimized accessor classes @@ -131,7 +136,7 @@ final class Injector { /** * Injected classes keyed by their names. */ - private final Map classes = new HashMap(); + private final Map classes = new HashMap<>(); private final ReentrantReadWriteLock rwl = new ReentrantReadWriteLock(); private final Lock r = rwl.readLock(); private final Lock w = rwl.writeLock(); @@ -141,26 +146,59 @@ final class Injector { * False otherwise, which happens if this classloader can't see {@link Accessor}. */ private final boolean loadable; - private static final Method defineClass; - private static final Method resolveClass; - private static final Method findLoadedClass; + private static Method defineClass; + private static Method resolveClass; + private static Method findLoadedClass; + private static Object U; static { - Method[] m = AccessController.doPrivileged( - new PrivilegedAction() { - @Override - public Method[] run() { - return new Method[]{ - getMethod(ClassLoader.class, "defineClass", String.class, byte[].class, Integer.TYPE, Integer.TYPE), - getMethod(ClassLoader.class, "resolveClass", Class.class), - getMethod(ClassLoader.class, "findLoadedClass", String.class) - }; - } + try { + Method[] m = AccessController.doPrivileged( + new PrivilegedAction() { + @Override + public Method[] run() { + return new Method[]{ + getMethod(ClassLoader.class, "defineClass", String.class, byte[].class, Integer.TYPE, Integer.TYPE), + getMethod(ClassLoader.class, "resolveClass", Class.class), + getMethod(ClassLoader.class, "findLoadedClass", String.class) + }; } - ); - defineClass = m[0]; - resolveClass = m[1]; - findLoadedClass = m[2]; + } + ); + defineClass = m[0]; + resolveClass = m[1]; + findLoadedClass = m[2]; + } catch (Throwable t) { + try { + U = AccessController.doPrivileged(new PrivilegedExceptionAction() { + @Override + public Object run() throws Exception { + Class u = Class.forName("sun.misc.Unsafe"); + Field theUnsafe = u.getDeclaredField("theUnsafe"); + theUnsafe.setAccessible(true); + return theUnsafe.get(null); + } + }); + defineClass = AccessController.doPrivileged(new PrivilegedExceptionAction() { + @Override + public Method run() throws Exception { + try { + return U.getClass().getMethod("defineClass", + new Class[]{String.class, + byte[].class, + Integer.TYPE, + Integer.TYPE, + ClassLoader.class, + ProtectionDomain.class}); + } catch (NoSuchMethodException | SecurityException ex) { + throw ex; + } + } + }); + } catch (SecurityException | PrivilegedActionException ex) { + Logger.getLogger(Injector.class.getName()).log(Level.SEVERE, null, ex); + } + } } private static Method getMethod(final Class c, final String methodname, final Class... params) { @@ -210,13 +248,11 @@ final class Injector { rlocked = false; //find loaded class from classloader - if (c == null) { + if (c == null && findLoadedClass != null) { try { c = (Class) findLoadedClass.invoke(parent, className.replace('/', '.')); - } catch (IllegalArgumentException e) { - logger.log(Level.FINE, "Unable to find " + className, e); - } catch (IllegalAccessException e) { + } catch (IllegalArgumentException | IllegalAccessException e) { logger.log(Level.FINE, "Unable to find " + className, e); } catch (InvocationTargetException e) { Throwable t = e.getTargetException(); @@ -253,9 +289,13 @@ final class Injector { // we need to inject a class into the try { - c = (Class) defineClass.invoke(parent, className.replace('/', '.'), image, 0, image.length); - resolveClass.invoke(parent, c); - } catch (IllegalAccessException e) { + if (resolveClass != null) { + c = (Class) defineClass.invoke(parent, className.replace('/', '.'), image, 0, image.length); + resolveClass.invoke(parent, c); + } else { + c = (Class) defineClass.invoke(U, className.replace('/', '.'), image, 0, image.length, parent, Injector.class.getProtectionDomain()); + } + } catch (IllegalAccessException e) { logger.log(Level.FINE, "Unable to inject " + className, e); return null; } catch (InvocationTargetException e) { diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/package-info.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/package-info.java new file mode 100644 index 00000000000..70ae20ccdd9 --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/package-info.java @@ -0,0 +1,36 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Hosts optimized + * {@link com.sun.xml.internal.bind.v2.runtime.reflect.Accessor}, + * {@link com.sun.xml.internal.bind.v2.runtime.reflect.TransducedAccessor}, and {@link com.sun.xml.internal.bind.v2.runtime.Transducer}. + * + *

    How it works

    + *

    + * Most of the classes in this package are "templates." At run-time, A template class file is slightly modified to match + * the target Java Bean, then it will be loaded into the VM. + */ +package com.sun.xml.internal.bind.v2.runtime.reflect.opt; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/package.html b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/package.html deleted file mode 100644 index 9039ffafb01..00000000000 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/opt/package.html +++ /dev/null @@ -1,39 +0,0 @@ - - - - - -Hosts optimized -{@link com.sun.xml.internal.bind.v2.runtime.reflect.Accessor}, -{@link com.sun.xml.internal.bind.v2.runtime.reflect.TransducedAccessor}, and -{@link com.sun.xml.internal.bind.v2.runtime.Transducer}. - -

    How it works

    -

    - Most of the classes in this package are "templates." At run-time, - A template class file is slightly modified to match the target Java Bean, - then it will be loaded into the VM. - diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/package-info.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/package-info.java new file mode 100644 index 00000000000..35dfd4abe9d --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Abstraction around accessing data of actual objects. + */ +package com.sun.xml.internal.bind.v2.runtime.reflect; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/package.html b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/package.html deleted file mode 100644 index 36c5c915cf8..00000000000 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/reflect/package.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - Abstraction around accessing data of actual objects. - diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/LocatorEx.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/LocatorEx.java index d1e67292e4e..8ae68be34c0 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/LocatorEx.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/LocatorEx.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,7 +33,7 @@ import org.xml.sax.Locator; import org.w3c.dom.Node; /** - * Object that returns the current location that the {@link com.sun.xml.internal.bind.v2.runtime.unmarshaller.XmlVisitor} + * Object that returns the current location that the {@code com.sun.xml.internal.bind.v2.runtime.unmarshaller.XmlVisitor} * is parsing. * * @author Kohsuke Kawaguchi @@ -41,6 +41,7 @@ import org.w3c.dom.Node; public interface LocatorEx extends Locator { /** * Gets the current location in a {@link ValidationEventLocator} object. + * @return */ ValidationEventLocator getLocation(); diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/StructureLoader.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/StructureLoader.java index 9becb9dd086..8141e4e5178 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/StructureLoader.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/StructureLoader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,9 @@ import java.util.Map; import javax.xml.namespace.QName; +import com.sun.xml.internal.bind.Util; import com.sun.xml.internal.bind.api.AccessorException; +import com.sun.xml.internal.bind.api.JAXBRIContext; import com.sun.xml.internal.bind.v2.WellKnownNamespace; import com.sun.xml.internal.bind.v2.runtime.ClassBeanInfoImpl; import com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl; @@ -231,11 +233,26 @@ public final class StructureLoader extends Loader { @Override public void childElement(UnmarshallingContext.State state, TagName arg) throws SAXException { ChildLoader child = childUnmarshallers.get(arg.uri,arg.local); - if (child == null) { - child = catchAll; - if (child==null) { - super.childElement(state,arg); - return; + if(child == null) { + Boolean backupWithParentNamespace = ((JAXBContextImpl) state.getContext().getJAXBContext()).backupWithParentNamespace; + backupWithParentNamespace = backupWithParentNamespace != null + ? backupWithParentNamespace + : Boolean.parseBoolean(Util.getSystemProperty(JAXBRIContext.BACKUP_WITH_PARENT_NAMESPACE)); + if ((beanInfo != null) && (beanInfo.getTypeNames() != null) && backupWithParentNamespace) { + Iterator typeNamesIt = beanInfo.getTypeNames().iterator(); + QName parentQName = null; + if ((typeNamesIt != null) && (typeNamesIt.hasNext()) && (catchAll == null)) { + parentQName = (QName) typeNamesIt.next(); + String parentUri = parentQName.getNamespaceURI(); + child = childUnmarshallers.get(parentUri, arg.local); + } + } + if (child == null) { + child = catchAll; + if(child==null) { + super.childElement(state,arg); + return; + } } } diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/schemagen/xmlschema/package-info.java b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/schemagen/xmlschema/package-info.java index fbe7ff55cb5..f7b434e49d8 100644 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/schemagen/xmlschema/package-info.java +++ b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/schemagen/xmlschema/package-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,5 +23,8 @@ * questions. */ +/** + * XML Schema writer generated by TXW. + */ @com.sun.xml.internal.txw2.annotation.XmlNamespace("http://www.w3.org/2001/XMLSchema") package com.sun.xml.internal.bind.v2.schemagen.xmlschema; diff --git a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/schemagen/xmlschema/package.html b/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/schemagen/xmlschema/package.html deleted file mode 100644 index cce3c1b8ebf..00000000000 --- a/jaxws/src/java.xml.bind/share/classes/com/sun/xml/internal/bind/v2/schemagen/xmlschema/package.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - -XML Schema writer generated by TXW. - - diff --git a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/ContextFinder.java b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/ContextFinder.java index d31a1cbe0d7..d59b0e40471 100644 --- a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/ContextFinder.java +++ b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/ContextFinder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -158,7 +158,7 @@ class ContextFinder { Class spFactory = ServiceLoaderUtil.safeLoadClass(className, PLATFORM_DEFAULT_FACTORY_CLASS, classLoader); return newInstance(contextPath, spFactory, classLoader, properties); } catch (ClassNotFoundException x) { - throw new JAXBException(Messages.format(Messages.PROVIDER_NOT_FOUND, className), x); + throw new JAXBException(Messages.format(Messages.DEFAULT_PROVIDER_NOT_FOUND), x); } catch (RuntimeException | JAXBException x) { // avoid wrapping RuntimeException to JAXBException, @@ -228,7 +228,7 @@ class ContextFinder { } } - private static Object instantiateProviderIfNecessary(Class implClass) throws JAXBException { + private static Object instantiateProviderIfNecessary(final Class implClass) throws JAXBException { try { if (JAXBContextFactory.class.isAssignableFrom(implClass)) { return AccessController.doPrivileged(new PrivilegedExceptionAction() { @@ -254,7 +254,7 @@ class ContextFinder { try { spi = ServiceLoaderUtil.safeLoadClass(className, PLATFORM_DEFAULT_FACTORY_CLASS, getContextClassLoader()); } catch (ClassNotFoundException e) { - throw new JAXBException(e); + throw new JAXBException(Messages.format(Messages.DEFAULT_PROVIDER_NOT_FOUND), e); } if (logger.isLoggable(Level.FINE)) { @@ -525,6 +525,7 @@ class ContextFinder { } else { return (ClassLoader) java.security.AccessController.doPrivileged( new java.security.PrivilegedAction() { + @Override public java.lang.Object run() { return Thread.currentThread().getContextClassLoader(); } @@ -539,6 +540,7 @@ class ContextFinder { } else { return (ClassLoader) java.security.AccessController.doPrivileged( new java.security.PrivilegedAction() { + @Override public java.lang.Object run() { return c.getClassLoader(); } @@ -552,6 +554,7 @@ class ContextFinder { } else { return (ClassLoader) java.security.AccessController.doPrivileged( new java.security.PrivilegedAction() { + @Override public java.lang.Object run() { return ClassLoader.getSystemClassLoader(); } diff --git a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/Messages.java b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/Messages.java index a1ebb81f4ab..79ede4ff185 100644 --- a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/Messages.java +++ b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/Messages.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -65,6 +65,9 @@ class Messages static final String PROVIDER_NOT_FOUND = // 1 arg "ContextFinder.ProviderNotFound"; + static final String DEFAULT_PROVIDER_NOT_FOUND = // 0 args + "ContextFinder.DefaultProviderNotFound"; + static final String COULD_NOT_INSTANTIATE = // 2 args "ContextFinder.CouldNotInstantiate"; diff --git a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/Messages.properties b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/Messages.properties index e6a930d67d4..548001abfe7 100644 --- a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/Messages.properties +++ b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/Messages.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,9 @@ ContextFinder.ProviderNotFound = \ Provider {0} not found +ContextFinder.DefaultProviderNotFound = \ + Implementation of JAXB-API has not been found on module path or classpath. + ContextFinder.CouldNotInstantiate = \ Provider {0} could not be instantiated: {1} diff --git a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/annotation/adapters/package-info.java b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/annotation/adapters/package-info.java new file mode 100644 index 00000000000..d52ab7fa2bd --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/annotation/adapters/package-info.java @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * {@link javax.xml.bind.annotation.adapters.XmlAdapter} and its spec-defined + * sub-classes to allow arbitrary Java classes to be used with JAXB. + *

    + *

    Package Specification

    + *

    + *

    + *

    + *

    Related Documentation

    + *

    + * For overviews, tutorials, examples, guides, and tool documentation, + * please see: + *

    + * + * @see JAXB Website + */ +package javax.xml.bind.annotation.adapters; diff --git a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/helpers/package-info.java b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/helpers/package-info.java new file mode 100644 index 00000000000..c5c0bec28f1 --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/helpers/package-info.java @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * JAXB Provider Use Only: Provides partial default implementations for + * some of the javax.xml.bind interfaces. + *

    + *

    + * JAXB Providers can extend these classes and implement the abstract + * methods. + *

    + *

    Package Specification

    + *

    + *

    + *

    + *

    Related Documentation

    + *

    + * For overviews, tutorials, examples, guides, and tool documentation, + * please see: + *

    + * + * @see JAXB Website + */ +package javax.xml.bind.helpers; diff --git a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/package-info.java b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/package-info.java new file mode 100644 index 00000000000..aa6ff577e52 --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/package-info.java @@ -0,0 +1,51 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides a runtime binding framework for client applications including + * unmarshalling, marshalling, and validation capabilities. + *

    + *

    + * JAXBContext is the client-entry point to the runtime binding + * framework. + *

    + *

    + *

    Package Specification

    + *

    + *

    + *

    + *

    Related Documentation

    + *

    + * For overviews, tutorials, examples, guides, and tool documentation, + * please see: + *

    + * + * @see JAXB Website + */ +package javax.xml.bind; diff --git a/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/util/package-info.java b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/util/package-info.java new file mode 100644 index 00000000000..229d4343fc2 --- /dev/null +++ b/jaxws/src/java.xml.bind/share/classes/javax/xml/bind/util/package-info.java @@ -0,0 +1,45 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Useful client utility classes. + *

    + *

    Package Specification

    + *

    + *

    + *

    + *

    Related Documentation

    + *

    + * For overviews, tutorials, examples, guides, and tool documentation, + * please see: + *

    + * + * @see JAXB Website + */ +package javax.xml.bind.util; diff --git a/jaxws/src/java.xml.bind/share/classes/module-info.java b/jaxws/src/java.xml.bind/share/classes/module-info.java index 1a6abaf0bf0..c871b6f0d47 100644 --- a/jaxws/src/java.xml.bind/share/classes/module-info.java +++ b/jaxws/src/java.xml.bind/share/classes/module-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,13 +25,18 @@ /** * Defines the Java Architecture for XML Binding (JAXB) API. + * + * @moduleGraph + * @since 9 */ +@Deprecated(since="9", forRemoval=true) module java.xml.bind { requires transitive java.activation; requires transitive java.xml; requires java.compiler; requires java.desktop; requires java.logging; + requires jdk.unsupported; uses javax.xml.bind.JAXBContextFactory; diff --git a/jaxws/src/java.xml.ws.annotation/share/classes/module-info.java b/jaxws/src/java.xml.ws.annotation/share/classes/module-info.java index 58a625918fe..6a16a31f6f6 100644 --- a/jaxws/src/java.xml.ws.annotation/share/classes/module-info.java +++ b/jaxws/src/java.xml.ws.annotation/share/classes/module-info.java @@ -26,7 +26,11 @@ /** * Defines a subset of the Common Annotations API to support programs running * on the Java SE Platform. + * + * @moduleGraph + * @since 9 */ +@Deprecated(since="9", forRemoval=true) module java.xml.ws.annotation { exports javax.annotation; } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/LazyEnvelopeSource.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/LazyEnvelopeSource.java index 151ae98e1fe..9136b3eb128 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/LazyEnvelopeSource.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/LazyEnvelopeSource.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -39,8 +39,7 @@ import javax.xml.stream.XMLStreamWriter; public interface LazyEnvelopeSource extends javax.xml.transform.Source { /** * Retrieve payload qname without materializing its contents - * @return - * @throws SOAPException + * @return payload QName */ public QName getPayloadQName(); public XMLStreamReader readToBodyStarTag() throws XMLStreamException; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/SOAPExceptionImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/SOAPExceptionImpl.java index 7adf460cbb6..2d98512528e 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/SOAPExceptionImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/SOAPExceptionImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -86,6 +86,7 @@ public class SOAPExceptionImpl extends SOAPException { /** * Constructs a SOAPExceptionImpl object initialized * with the given Throwable object. + * @param cause cause */ public SOAPExceptionImpl(Throwable cause) { super (cause.toString()); @@ -106,6 +107,7 @@ public class SOAPExceptionImpl extends SOAPException { * message of the embedded Throwable object, * if there is one */ + @Override public String getMessage() { String message = super.getMessage (); if (message == null && cause != null) { @@ -124,6 +126,7 @@ public class SOAPExceptionImpl extends SOAPException { * if there is none */ + @Override public Throwable getCause() { return cause; } @@ -157,6 +160,7 @@ public class SOAPExceptionImpl extends SOAPException { * method has already been called on this SOAPExceptionImpl * object */ + @Override public synchronized Throwable initCause(Throwable cause) { if(this.cause != null) { @@ -170,6 +174,7 @@ public class SOAPExceptionImpl extends SOAPException { return this; } + @Override public void printStackTrace() { super.printStackTrace(); if (cause != null) { @@ -178,6 +183,7 @@ public class SOAPExceptionImpl extends SOAPException { } } + @Override public void printStackTrace(PrintStream s) { super.printStackTrace(s); if (cause != null) { @@ -186,6 +192,7 @@ public class SOAPExceptionImpl extends SOAPException { } } + @Override public void printStackTrace(PrintWriter s) { super.printStackTrace(s); if (cause != null) { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/client/p2p/HttpSOAPConnection.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/client/p2p/HttpSOAPConnection.java index 4ff655a0051..a032c589dfe 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/client/p2p/HttpSOAPConnection.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/client/p2p/HttpSOAPConnection.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -512,9 +512,13 @@ class HttpSOAPConnection extends SOAPConnection { : httpConnection.getInputStream()); // If no reply message is returned, // content-Length header field value is expected to be zero. - // InputStream#available() can't be used here - it just says no data *YET*! + // java SE 6 documentation says : + // available() : an estimate of the number of bytes that can be read + //(or skipped over) from this input stream without blocking + //or 0 when it reaches the end of the input stream. if ((httpIn == null ) - || (httpConnection.getContentLength() == 0)) { + || (httpConnection.getContentLength() == 0) + || (httpIn.available() == 0)) { response = null; log.warning("SAAJ0014.p2p.content.zero"); } else { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/MultipartDataSource.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/MultipartDataSource.java index ee23205714b..f21f3d02398 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/MultipartDataSource.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/MultipartDataSource.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -69,7 +69,7 @@ public interface MultipartDataSource extends DataSource { * @return the MimeBodyPart * @exception IndexOutOfBoundsException if the given index * is out of range. - * @exception MessagingException + * @exception MessagingException thrown in case of error */ public MimeBodyPart getBodyPart(int index) throws MessagingException; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/BMMimeMultipart.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/BMMimeMultipart.java index 34066fc32ac..96a7702e580 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/BMMimeMultipart.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/BMMimeMultipart.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -115,6 +115,8 @@ public class BMMimeMultipart extends MimeMultipart { * contentType field.

    * * MimeBodyParts may be added later. + * + * @param subtype subtype. */ public BMMimeMultipart(String subtype) { super(subtype); @@ -142,7 +144,9 @@ public class BMMimeMultipart extends MimeMultipart { * skips the 'preamble' and reads bytes till the terminating * boundary and creates MimeBodyParts for each part of the stream. * - * @param ds DataSource, can be a MultipartDataSource + * @param ds DataSource, can be a MultipartDataSource. + * @param ct content type. + * @exception MessagingException in case of error. */ public BMMimeMultipart(DataSource ds, ContentType ct) throws MessagingException { @@ -197,6 +201,7 @@ public class BMMimeMultipart extends MimeMultipart { * * @since JavaMail 1.2 */ + @Override protected void parse() throws MessagingException { if (parsed) return; @@ -694,6 +699,7 @@ public class BMMimeMultipart extends MimeMultipart { * separated by a boundary. */ + @Override public void writeTo(OutputStream os) throws IOException, MessagingException { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/ContentDisposition.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/ContentDisposition.java index 448cb04777c..eab91196564 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/ContentDisposition.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/ContentDisposition.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -100,6 +100,7 @@ public class ContentDisposition { /** * Return the specified parameter value. Returns null * if this parameter is absent. + * @param name parameter name. * @return parameter value * @since JavaMail 1.2 */ @@ -123,7 +124,7 @@ public class ContentDisposition { /** * Set the primary type. Overrides existing primary type. - * @param primaryType primary type + * @param disposition disposition value * @since JavaMail 1.2 */ public void setDisposition(String disposition) { @@ -162,6 +163,7 @@ public class ContentDisposition { * @return RFC2045 style string * @since JavaMail 1.2 */ + @Override public String toString() { if (disposition == null) return null; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/ContentType.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/ContentType.java index 4cbbae3e33d..1fc677d68d9 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/ContentType.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/ContentType.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -136,6 +136,7 @@ public final class ContentType { /** * Return the specified parameter value. Returns null * if this parameter is absent. + * @param name parameter name * @return parameter value */ public String getParameter(String name) { @@ -200,6 +201,7 @@ public final class ContentType { * * @return RFC2045 style string */ + @Override public String toString() { if (primaryType == null || subType == null) // need both return null; @@ -218,7 +220,7 @@ public final class ContentType { /** * Match with the specified ContentType object. This method * compares only the primaryType and - * subType . The parameters of both operands + * primaryType . The parameters of both operands * are ignored.

    * * For example, this method will return true when @@ -232,6 +234,8 @@ public final class ContentType { * and "text/*" * * @param cType to compare this against + * @return true if primaryType and subType + * match specified content type. */ public boolean match(ContentType cType) { // Match primaryType @@ -266,6 +270,10 @@ public final class ContentType { * For example, this method will return true when * comparing the ContentType for "text/plain" * with "text/*" + * + * @param s content type + * @return true if primaryType and subType + * match specified content type. */ public boolean match(String s) { try { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/HeaderTokenizer.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/HeaderTokenizer.java index 4620bb0d484..0d9ee4ed3a5 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/HeaderTokenizer.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/HeaderTokenizer.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -95,14 +95,15 @@ public class HeaderTokenizer { * one of the following: *

      *
    • ATOM A sequence of ASCII characters - * delimited by either SPACE, CTL, "(", <"> or the - * specified SPECIALS + * delimited by either SPACE, CTL, "(", <"> or the + * specified SPECIALS
    • *
    • QUOTEDSTRING A sequence of ASCII characters - * within quotes + * within quotes
    • *
    • COMMENT A sequence of ASCII characters - * within "(" and ")". - *
    • EOF End of header + * within "(" and ")".
    • + *
    • EOF End of header
    • *
    + * @return type */ public int getType() { return type; @@ -176,6 +177,7 @@ public class HeaderTokenizer { * Constructor. The RFC822 defined delimiters - RFC822 - are * used to delimit ATOMS. Also comments are skipped and not * returned as tokens + * @param header The header that is tokenized. */ public HeaderTokenizer(String header) { this(header, RFC822); @@ -317,7 +319,7 @@ public class HeaderTokenizer { currentPos++; // re-position currentPos char ch[] = new char[1]; ch[0] = c; - return new Token((int)c, new String(ch)); + return new Token(c, new String(ch)); } // Check for ATOM diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/InternetHeaders.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/InternetHeaders.java index bf39ee7540b..84616c89b96 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/InternetHeaders.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/InternetHeaders.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -48,13 +48,12 @@ import java.util.NoSuchElementException; * until the blank line that indicates end of header. The input stream * is positioned at the start of the body. The lines are stored * within the object and can be extracted as either Strings or - * {@link Header} objects.

    - *

    + * {@link Header} objects. + *

    * This class is mostly intended for service providers. MimeMessage - * and MimeBody use this class for holding their headers.

    - *

    - *


    A note on RFC822 and MIME headers

    - *

    + * and MimeBody use this class for holding their headers. + *


    A note on RFC822 and MIME headers + *

    * RFC822 and MIME header fields must contain only * US-ASCII characters. If a header contains non US-ASCII characters, * it must be encoded as per the rules in RFC 2047. The MimeUtility @@ -65,7 +64,7 @@ import java.util.NoSuchElementException; * header fields must be folded (wrapped) before being sent if they * exceed the line length limitation for the transport (1000 bytes for * SMTP). Received headers may have been folded. The application is - * responsible for folding and unfolding headers as appropriate.

    + * responsible for folding and unfolding headers as appropriate. * * @author John Mani * @author Bill Shannon @@ -90,12 +89,13 @@ public final class InternetHeaders { * Read and parse the given RFC822 message stream till the * blank line separating the header from the body. The input * stream is left positioned at the start of the body. The - * header lines are stored internally.

    - *

    + * header lines are stored internally. + *

    * For efficiency, wrap a BufferedInputStream around the actual * input stream and pass it as the parameter. * * @param is RFC822 input stream + * @exception MessagingException in case of error */ public InternetHeaders(InputStream is) throws MessagingException { load(is); @@ -104,13 +104,14 @@ public final class InternetHeaders { /** * Read and parse the given RFC822 message stream till the * blank line separating the header from the body. Store the - * header lines inside this InternetHeaders object.

    - *

    + * header lines inside this InternetHeaders object. + *

    * Note that the header lines are added into this InternetHeaders * object, so any existing headers in this object will not be * affected. * * @param is RFC822 input stream + * @exception MessagingException in case of error */ public void load(InputStream is) throws MessagingException { // Read header lines until a blank line. It is valid @@ -208,9 +209,9 @@ public final class InternetHeaders { /** * Change the first header line that matches name * to have value, adding a new header if no existing header - * matches. Remove all matching headers but the first.

    - *

    - * Note that RFC822 headers can only contain US-ASCII characters + * matches. Remove all matching headers but the first. + *

    + * Note that RFC822 headers can only contain US-ASCII characters. * * @param name header name * @param value header value @@ -242,8 +243,7 @@ public final class InternetHeaders { } /** - * Add a header with the specified name and value to the header list.

    - *

    + * Add a header with the specified name and value to the header list. * Note that RFC822 headers can only contain US-ASCII characters. * * @param name header name @@ -285,15 +285,15 @@ public final class InternetHeaders { * * @return Header objects */ - public List getAllHeaders() { + public FinalArrayList getAllHeaders() { return headers; // conceptually it should be read-only, but for performance reason I'm not wrapping it here } /** * Add an RFC822 header line to the header store. * If the line starts with a space or tab (a continuation line), - * add it to the last header line in the list.

    - *

    + * add it to the last header line in the list. + *

    * Note that RFC822 headers can only contain US-ASCII characters * * @param line raw RFC822 header line @@ -316,15 +316,19 @@ public final class InternetHeaders { /** * Return all the header lines as a collection + * + * @return list of header lines. */ public List getAllHeaderLines() { if(headerValueView==null) headerValueView = new AbstractList() { - public String get(int index) { + @Override + public String get(int index) { return headers.get(index).line; } - public int size() { + @Override + public int size() { return headers.size(); } }; @@ -368,6 +372,7 @@ class hdr implements Header { /* * Return the "name" part of the header line. */ + @Override public String getName() { return name; } @@ -375,6 +380,7 @@ class hdr implements Header { /* * Return the "value" part of the header line. */ + @Override public String getValue() { int i = line.indexOf(':'); if (i < 0) diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeBodyPart.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeBodyPart.java index 6642dfa19ce..8aa7fe3f864 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeBodyPart.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeBodyPart.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,7 +32,6 @@ package com.sun.xml.internal.messaging.saaj.packaging.mime.internet; -import com.sun.xml.internal.messaging.saaj.packaging.mime.Header; import com.sun.xml.internal.messaging.saaj.packaging.mime.MessagingException; import com.sun.xml.internal.messaging.saaj.packaging.mime.util.OutputUtil; import com.sun.xml.internal.messaging.saaj.util.ByteOutputStream; @@ -52,12 +51,12 @@ import com.sun.xml.internal.org.jvnet.mimepull.MIMEPart; /** * This class represents a MIME body part. * MimeBodyParts are contained in MimeMultipart - * objects.

    - * + * objects. + *

    * MimeBodyPart uses the InternetHeaders class to parse - * and store the headers of that body part.

    + * and store the headers of that body part. * - *


    A note on RFC 822 and MIME headers

    + *


    A note on RFC 822 and MIME headers * * RFC 822 header fields must contain only * US-ASCII characters. MIME allows non ASCII characters to be present @@ -70,7 +69,7 @@ import com.sun.xml.internal.org.jvnet.mimepull.MIMEPart; * header fields must be folded (wrapped) before being sent if they * exceed the line length limitation for the transport (1000 bytes for * SMTP). Received headers may have been folded. The application is - * responsible for folding and unfolding headers as appropriate.

    + * responsible for folding and unfolding headers as appropriate. * * @author John Mani * @author Bill Shannon @@ -179,6 +178,8 @@ public final class MimeBodyPart { * the delimiter strings. * * @param is the body part Input Stream + * + * @exception MessagingException in case of error */ public MimeBodyPart(InputStream is) throws MessagingException { if (!(is instanceof ByteArrayInputStream) && @@ -216,6 +217,7 @@ public final class MimeBodyPart { * * @param headers The header of this part * @param content bytes representing the body of this part. + * @param len content length. */ public MimeBodyPart(InternetHeaders headers, byte[] content, int len) { this.headers = headers; @@ -242,6 +244,7 @@ public final class MimeBodyPart { /** * Return the containing MimeMultipart object, * or null if not known. + * @return parent part. */ public MimeMultipart getParent() { return parent; @@ -253,6 +256,7 @@ public final class MimeBodyPart { * addBodyPart method. parent may be * null if the MimeBodyPart is being removed * from its containing MimeMultipart. + * @param parent parent part * @since JavaMail 1.1 */ public void setParent(MimeMultipart parent) { @@ -351,6 +355,9 @@ public final class MimeBodyPart { * If the subType of mimeType is the * special character '*', then the subtype is ignored during the * comparison. + * + * @param mimeType string + * @return true if it is valid mime type */ public boolean isMimeType(String mimeType) { boolean result; @@ -375,6 +382,9 @@ public final class MimeBodyPart { * This implementation uses getHeader(name) * to obtain the requisite header field. * + * @return content disposition + * @exception MessagingException in case of error + * * @see #headers */ public String getDisposition() throws MessagingException { @@ -392,6 +402,9 @@ public final class MimeBodyPart { * If the disposition is null, any existing "Content-Disposition" * header field is removed. * + * @param disposition value + * + * @exception MessagingException in case of error * @exception IllegalStateException if this body part is * obtained from a READ_ONLY folder. */ @@ -423,6 +436,9 @@ public final class MimeBodyPart { * This implementation uses getHeader(name) * to obtain the requisite header field. * + * @return encoding + * @exception MessagingException in case of error + * * @see #headers */ public String getEncoding() throws MessagingException { @@ -465,6 +481,8 @@ public final class MimeBodyPart { * * This implementation uses getHeader(name) * to obtain the requisite header field. + * + * @return conent id */ public String getContentID() { return getHeader("Content-ID", null); @@ -475,6 +493,7 @@ public final class MimeBodyPart { * If the cid parameter is null, any existing * "Content-ID" is removed. * + * @param cid content id * @exception IllegalStateException if this body part is * obtained from a READ_ONLY folder. * @since JavaMail 1.3 @@ -493,6 +512,8 @@ public final class MimeBodyPart { * * This implementation uses getHeader(name) * to obtain the requisite header field. + * + * @return content MD5 sum */ public String getContentMD5() { return getHeader("Content-MD5", null); @@ -501,6 +522,8 @@ public final class MimeBodyPart { /** * Set the "Content-MD5" header field of this body part. * + * @param md5 content md5 sum + * * @exception IllegalStateException if this body part is * obtained from a READ_ONLY folder. */ @@ -516,6 +539,9 @@ public final class MimeBodyPart { * * This implementation uses getHeader(name) * to obtain the requisite header field. + * + * @return array of language tags + * @exception MessagingException in case of error */ public String[] getContentLanguage() throws MessagingException { String s = getHeader("Content-Language", null); @@ -663,6 +689,7 @@ public final class MimeBodyPart { * Returns null if both are absent. * * @return filename + * @exception MessagingException in case of error */ public String getFileName() throws MessagingException { String filename = null; @@ -692,6 +719,9 @@ public final class MimeBodyPart { * Sets the "filename" parameter of the "Content-Disposition" * header field of this body part. * + * @param filename filename + * + * @exception MessagingException in case of error * @exception IllegalStateException if this body part is * obtained from a READ_ONLY folder. */ @@ -769,9 +799,14 @@ public final class MimeBodyPart { * This implementation simply calls the getContentStream * method. * + * @return input stream + * + * @exception MessagingException in case of error + * * @see #getInputStream * @see #getContentStream * @since JavaMail 1.2 + * */ public InputStream getRawInputStream() throws MessagingException { return getContentStream(); @@ -782,24 +817,30 @@ public final class MimeBodyPart { * * The implementation provided here works just like the * the implementation in MimeMessage. + * + * @return data handler */ public DataHandler getDataHandler() { if (mimePart != null) { //return an inputstream return new DataHandler(new DataSource() { + @Override public InputStream getInputStream() throws IOException { return mimePart.read(); } + @Override public OutputStream getOutputStream() throws IOException { throw new UnsupportedOperationException("getOutputStream cannot be supported : You have enabled LazyAttachments Option"); } + @Override public String getContentType() { return mimePart.getContentType(); } + @Override public String getName() { return "MIMEPart Wrapped DataSource"; } @@ -890,6 +931,8 @@ public final class MimeBodyPart { * If the charset is already known, use the * setText() version that takes the charset parameter. * + * @param text string + * * @see #setText(String text, String charset) */ public void setText(String text) { @@ -902,6 +945,9 @@ public final class MimeBodyPart { * charset. The given Unicode string will be charset-encoded * using the specified charset. The charset is also used to set * the "charset" parameter. + * + * @param text string + * @param charset character set */ public void setText(String text, String charset) { if (charset == null) { @@ -932,7 +978,9 @@ public final class MimeBodyPart { /** * Output the body part as an RFC 822 format stream. * - * @exception MessagingException + * @param os output stream + * + * @exception MessagingException in case of error * @exception IOException if an error occurs writing to the * stream or if an error is generated * by the javax.activation layer. @@ -1033,6 +1081,8 @@ public final class MimeBodyPart { /** * Remove all headers with this name. + * + * @param name header name */ public void removeHeader(String name) { headers.removeHeader(name); @@ -1041,14 +1091,18 @@ public final class MimeBodyPart { /** * Return all the headers from this Message as an Enumeration of * Header objects. + * + * @return all headers */ - public List getAllHeaders() { + public FinalArrayList getAllHeaders() { return headers.getAllHeaders(); } /** * Add a header line to this body part + * + * @param line header line to add */ public void addHeaderLine(String line) { headers.addHeaderLine(line); @@ -1075,6 +1129,8 @@ public final class MimeBodyPart { *
    * In both cases this method is typically called by the * Message.saveChanges method. + * + * @exception MessagingException in case of error. */ protected void updateHeaders() throws MessagingException { DataHandler dh = getDataHandler(); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeMultipart.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeMultipart.java index c9bc1170f0f..6c5bf210d13 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeMultipart.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeMultipart.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -133,6 +133,7 @@ public class MimeMultipart { * contentType field.

    * * MimeBodyParts may be added later. + * @param subtype subtype. */ public MimeMultipart(String subtype) { //super(); @@ -163,6 +164,8 @@ public class MimeMultipart { * This must be the same information as {@link DataSource#getContentType()}. * All the callers of this method seem to have this object handy, so * for performance reason this method accepts it. Can be null. + * + * @exception MessagingException in case of error */ public MimeMultipart(DataSource ds, ContentType ct) throws MessagingException { // 'ds' was not a MultipartDataSource, we have @@ -189,7 +192,8 @@ public class MimeMultipart { /** * Return the number of enclosed MimeBodyPart objects. * - * @return number of parts + * @return number of parts. + * @throws MessagingException in case of error. */ public int getCount() throws MessagingException { parse(); @@ -202,8 +206,8 @@ public class MimeMultipart { /** * Get the specified MimeBodyPart. BodyParts are numbered starting at 0. * - * @param index the index of the desired MimeBodyPart - * @return the MimeBodyPart + * @param index the index of the desired MimeBodyPart. + * @return the MimeBodyPart. * @exception MessagingException if no such MimeBodyPart exists */ public MimeBodyPart getBodyPart(int index) @@ -221,6 +225,7 @@ public class MimeMultipart { * * @param CID the ContentID of the desired part * @return the MimeBodyPart + * @exception MessagingException if no such MimeBodyPart exists. */ public MimeBodyPart getBodyPart(String CID) throws MessagingException { @@ -256,6 +261,8 @@ public class MimeMultipart { * expensive for a specific MimeMultipart subclass, then it * might itself want to track whether its internal state actually * did change, and do the header updating only if necessary. + * + * @exception MessagingException in case of error. */ protected void updateHeaders() throws MessagingException { for (int i = 0; i < parts.size(); i++) @@ -265,6 +272,11 @@ public class MimeMultipart { /** * Iterates through all the parts and outputs each Mime part * separated by a boundary. + * + * @param os output stream. + * + * @exception IOException if an I/O Error occurs. + * @exception MessagingException in case of error. */ public void writeTo(OutputStream os) throws IOException, MessagingException { @@ -291,6 +303,8 @@ public class MimeMultipart { * method is called by all other methods that need data for * the body parts, to make sure the data has been parsed. * + * @exception MessagingException in case of error. + * * @since JavaMail 1.2 */ protected void parse() throws MessagingException { @@ -490,8 +504,9 @@ public class MimeMultipart { * necessary. This implementation simply constructs and returns * an InternetHeaders object. * - * @param is the InputStream to read the headers from - * @exception MessagingException + * @param is the InputStream to read the headers from. + * @return headers. + * @exception MessagingException in case of error. * @since JavaMail 1.2 */ protected InternetHeaders createInternetHeaders(InputStream is) @@ -506,8 +521,10 @@ public class MimeMultipart { * necessary. This implementation simply constructs and returns * a MimeBodyPart object. * - * @param headers the headers for the body part - * @param content the content of the body part + * @param headers the headers for the body part. + * @param content the content of the body part. + * @param len the content length. + * @return MimeBodyPart * @since JavaMail 1.2 */ protected MimeBodyPart createMimeBodyPart(InternetHeaders headers, byte[] content, int len) { @@ -521,8 +538,9 @@ public class MimeMultipart { * necessary. This implementation simply constructs and returns * a MimeBodyPart object. * - * @param is InputStream containing the body part - * @exception MessagingException + * @param is InputStream containing the body part. + * @return MimeBodyPart. + * @exception MessagingException in case of error. * @since JavaMail 1.2 */ protected MimeBodyPart createMimeBodyPart(InputStream is) throws MessagingException { @@ -543,8 +561,8 @@ public class MimeMultipart { * a specific multipart subtype. * * @param mp MimeMultipart datasource + * @exception MessagingException in case of error. */ - protected void setMultipartDataSource(MultipartDataSource mp) throws MessagingException { contentType = new ContentType(mp.getContentType()); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimePartDataSource.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimePartDataSource.java index 8d08e39e1eb..eb7b46c5656 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimePartDataSource.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimePartDataSource.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -50,6 +50,8 @@ public final class MimePartDataSource implements DataSource { /** * Constructor, that constructs a DataSource from a MimeBodyPart. + * + * @param part body part */ public MimePartDataSource(MimeBodyPart part) { this.part = part; @@ -68,6 +70,7 @@ public final class MimePartDataSource implements DataSource { * * @return decoded input stream */ + @Override public InputStream getInputStream() throws IOException { try { @@ -88,7 +91,8 @@ public final class MimePartDataSource implements DataSource { * * This implementation throws the UnknownServiceException. */ - public OutputStream getOutputStream() throws IOException { + @Override + public OutputStream getOutputStream() throws IOException { throw new UnknownServiceException(); } @@ -98,6 +102,7 @@ public final class MimePartDataSource implements DataSource { * This implementation just invokes the getContentType * method on the MimeBodyPart. */ + @Override public String getContentType() { return part.getContentType(); } @@ -107,7 +112,8 @@ public final class MimePartDataSource implements DataSource { * * This implementation just returns an empty string. */ - public String getName() { + @Override + public String getName() { try { return part.getFileName(); } catch (MessagingException mex) { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeUtility.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeUtility.java index 45f6cea11c1..87bdd6e6f5f 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeUtility.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/MimeUtility.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -65,11 +65,11 @@ import com.sun.xml.internal.messaging.saaj.util.SAAJUtil; *

    * Note that to get the actual bytes of a mail-safe String (say, * for sending over SMTP), one must do - *

    + * 
      *
      *      byte[] bytes = string.getBytes("iso-8859-1");
      *
    - * 

    + *

    * * The setHeader and addHeader methods * on MimeMessage and MimeBodyPart assume that the given header values @@ -222,6 +222,10 @@ public class MimeUtility { * DataHandler uses a thread, a pair of pipe streams, * and the writeTo method to produce the data.

    * + * @param dh data handler + * + * @return encoding + * * @since JavaMail 1.2 */ public static String getEncoding(DataHandler dh) { @@ -294,6 +298,7 @@ public class MimeUtility { * @param is input stream * @param encoding the encoding of the stream. * @return decoded input stream. + * @exception MessagingException in case of error */ public static InputStream decode(InputStream is, String encoding) throws MessagingException { @@ -323,6 +328,7 @@ public class MimeUtility { * @param encoding the encoding of the stream. * @return output stream that applies the * specified encoding. + * @exception MessagingException in case of error */ public static OutputStream encode(OutputStream os, String encoding) throws MessagingException { @@ -358,6 +364,7 @@ public class MimeUtility { * with uuencode) * @return output stream that applies the * specified encoding. + * @exception MessagingException in case of error * @since JavaMail 1.2 */ public static OutputStream encode(OutputStream os, String encoding, @@ -397,7 +404,7 @@ public class MimeUtility { * "unstructured" RFC 822 headers.

    * * Example of usage: - *

    +     * 
          *
          *  MimeBodyPart part = ...
          *  String rawvalue = "FooBar Mailer, Japanese version 1.1"
    @@ -411,7 +418,7 @@ public class MimeUtility {
          *   // setHeader() failure
          *  }
          *
    -     * 

    + *

    * * @param text unicode string * @return Unicode string containing only US-ASCII characters @@ -446,6 +453,7 @@ public class MimeUtility { * encoded are in the ASCII charset, otherwise "B" encoding * is used. * @return Unicode string containing only US-ASCII characters + * @exception UnsupportedEncodingException in case of unsupported encoding */ public static String encodeText(String text, String charset, String encoding) @@ -464,7 +472,7 @@ public class MimeUtility { * returned as-is

    * * Example of usage: - *

    +     * 
          *
          *  MimeBodyPart part = ...
          *  String rawvalue = null;
    @@ -479,9 +487,10 @@ public class MimeUtility {
          *
          *  return value;
          *
    -     * 

    + *

    * * @param etext the possibly encoded value + * @return decoded text * @exception UnsupportedEncodingException if the charset * conversion failed. */ @@ -568,7 +577,7 @@ public class MimeUtility { * The InternetAddress class, for example, uses this to encode * it's 'phrase' component. * - * @param text unicode string + * @param word unicode string * @return Array of Unicode strings containing only US-ASCII * characters. * @exception UnsupportedEncodingException if the encoding fails @@ -590,7 +599,7 @@ public class MimeUtility { * The resulting bytes are then returned as a Unicode string * containing only ASCII characters.

    * - * @param text unicode string + * @param word unicode string * @param charset the MIME charset * @param encoding the encoding to be used. Currently supported * values are "B" and "Q". If this parameter is null, then @@ -720,6 +729,7 @@ public class MimeUtility { * fails, an UnsupportedEncodingException is thrown.

    * * @param eword the possibly encoded value + * @return deocoded word * @exception ParseException if the string is not an * encoded-word as per RFC 2047. * @exception UnsupportedEncodingException if the charset @@ -847,8 +857,8 @@ public class MimeUtility { * @param word word to be quoted * @param specials the set of special characters * @return the possibly quoted word - * @see javax.mail.internet.HeaderTokenizer#MIME - * @see javax.mail.internet.HeaderTokenizer#RFC822 + * @see com.sun.xml.internal.messaging.saaj.packaging.mime.internet.HeaderTokenizer#MIME + * @see com.sun.xml.internal.messaging.saaj.packaging.mime.internet.HeaderTokenizer#RFC822 */ public static String quote(String word, String specials) { int len = word.length(); @@ -1111,7 +1121,8 @@ public class MimeUtility { } catch (SecurityException sex) { class NullInputStream extends InputStream { - public int read() { + @Override + public int read() { return 0; } } @@ -1277,7 +1288,7 @@ public class MimeUtility { int l = s.length(); for (int i = 0; i < l; i++) { - if (nonascii((int)s.charAt(i))) // non-ascii + if (nonascii(s.charAt(i))) // non-ascii non_ascii++; else ascii++; @@ -1444,14 +1455,17 @@ class AsciiOutputStream extends OutputStream { checkEOL = encodeEolStrict && breakOnNonAscii; } + @Override public void write(int b) throws IOException { check(b); } + @Override public void write(byte b[]) throws IOException { write(b, 0, b.length); } + @Override public void write(byte b[], int off, int len) throws IOException { len += off; for (int i = off; i < len ; i++) diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/SharedInputStream.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/SharedInputStream.java index c650b6b39cc..4619c4dcd87 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/SharedInputStream.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/internet/SharedInputStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -73,6 +73,9 @@ public interface SharedInputStream { /** * Writes the specified region to another {@link OutputStream}. + * @param start the starting position + * @param end the ending position + 1 + * @param out output stream */ public void writeTo(long start,long end, OutputStream out); } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/ASCIIUtility.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/ASCIIUtility.java index 48a56e8068c..a85fc85dc67 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/ASCIIUtility.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/ASCIIUtility.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -43,9 +43,17 @@ public class ASCIIUtility { /** * Convert the bytes within the specified range of the given byte * array into a signed integer in the given radix . The range extends - * from start till, but not including end.

    + * from start till, but not including end. + * + * Based on java.lang.Integer.parseInt(). + * + * @param b bytes to convert to integer. + * @param start start of the range. + * @param end end of the range (not including). + * @param radix radix. + * + * @return integer. * - * Based on java.lang.Integer.parseInt() */ public static int parseInt(byte[] b, int start, int end, int radix) throws NumberFormatException { @@ -110,7 +118,14 @@ public class ASCIIUtility { /** * Convert the bytes within the specified range of the given byte * array into a String. The range extends from start - * till, but not including end.

    + * till, but not including end. + * + * @param b bytes to convert to integer. + * @param start start of the range. + * @param end end of the range (not including). + * + * @return integer. + * */ public static String toString(byte[] b, int start, int end) { int size = end - start; @@ -122,6 +137,15 @@ public class ASCIIUtility { return new String(theChars); } + /** + * Encodes specified String into a sequence of bytes using the platform's + * default charset, storing the result into a new byte array. + * + * @param s string to encode into byte array. + * + * @return byte array. + * + */ public static byte[] getBytes(String s) { char [] chars= s.toCharArray(); int size = chars.length; @@ -133,6 +157,13 @@ public class ASCIIUtility { } /** + * Converts input stream to array. + * + * @param is stream to convert to array. + * + * @return byte array. + * + * @throws IOException if an I/O error occurs. * * @deprecated * this is an expensive operation that require an additional @@ -140,6 +171,7 @@ public class ASCIIUtility { * Unless you absolutely need the exact size array, don't use this. * Use {@link ByteOutputStream} and {@link ByteOutputStream#write(InputStream)}. */ + @Deprecated public static byte[] getBytes(InputStream is) throws IOException { ByteOutputStream bos = null; try { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BASE64DecoderStream.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BASE64DecoderStream.java index 31f3e3695a6..972ccd2dba0 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BASE64DecoderStream.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BASE64DecoderStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -70,6 +70,7 @@ public class BASE64DecoderStream extends FilterInputStream { * @exception IOException if an I/O error occurs. * @see java.io.FilterInputStream#in */ + @Override public int read() throws IOException { if (index >= bufsize) { decode(); // Fills up buffer @@ -94,6 +95,7 @@ public class BASE64DecoderStream extends FilterInputStream { * the stream has been reached. * @exception IOException if an I/O error occurs. */ + @Override public int read(byte[] buf, int off, int len) throws IOException { int i, c; for (i = 0; i < len; i++) { @@ -112,6 +114,7 @@ public class BASE64DecoderStream extends FilterInputStream { * Tests if this input stream supports marks. Currently this class * does not support marks */ + @Override public boolean markSupported() { return false; // Maybe later .. } @@ -122,6 +125,7 @@ public class BASE64DecoderStream extends FilterInputStream { * a close approximation in case the original encoded stream * contains embedded CRLFs; since the CRLFs are discarded, not decoded */ + @Override public int available() throws IOException { // This is only an estimate, since in.available() // might include CRLFs too .. @@ -200,6 +204,10 @@ public class BASE64DecoderStream extends FilterInputStream { * in the IMAP AUTHENTICATE protocol, but not to decode the * entire content of a MIME part. * + * @param inbuf byte array to decode + * + * @return decoded byte array + * * NOTE: inbuf may only contain valid base64 characters. * Whitespace is not ignored. */ diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BASE64EncoderStream.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BASE64EncoderStream.java index d1c3350146b..843a334f933 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BASE64EncoderStream.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BASE64EncoderStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -80,6 +80,7 @@ public class BASE64EncoderStream extends FilterOutputStream { * @param len the number of bytes to write. * @exception IOException if an I/O error occurs. */ + @Override public void write(byte[] b, int off, int len) throws IOException { for (int i = 0; i < len; i++) write(b[off + i]); @@ -90,6 +91,7 @@ public class BASE64EncoderStream extends FilterOutputStream { * @param b the data to be written. * @exception IOException if an I/O error occurs. */ + @Override public void write(byte[] b) throws IOException { write(b, 0, b.length); } @@ -99,6 +101,7 @@ public class BASE64EncoderStream extends FilterOutputStream { * @param c the byte. * @exception IOException if an I/O error occurs. */ + @Override public void write(int c) throws IOException { buffer[bufsize++] = (byte)c; if (bufsize == 3) { // Encoding unit = 3 bytes @@ -112,6 +115,7 @@ public class BASE64EncoderStream extends FilterOutputStream { * to be encoded out to the stream. * @exception IOException if an I/O error occurs. */ + @Override public void flush() throws IOException { if (bufsize > 0) { // If there's unencoded characters in the buffer .. encode(); // .. encode them @@ -124,6 +128,7 @@ public class BASE64EncoderStream extends FilterOutputStream { * Forces any buffered output bytes to be encoded out to the stream * and closes this output stream */ + @Override public void close() throws IOException { flush(); out.close(); @@ -186,6 +191,10 @@ public class BASE64EncoderStream extends FilterOutputStream { * This method is suitable for short strings, such as those * in the IMAP AUTHENTICATE protocol, but not to encode the * entire content of a MIME part. + * + * @param inbuf byte array to encode. + * + * @return encoded byte array. */ public static byte[] encode(byte[] inbuf) { if (inbuf.length == 0) diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BEncoderStream.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BEncoderStream.java index ec13f9e106d..a2a23d697b5 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BEncoderStream.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/BEncoderStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -55,6 +55,10 @@ public class BEncoderStream extends BASE64EncoderStream { /** * Returns the length of the encoded version of this byte array. + * + * @param b byte array. + * + * @return length of the byte array. */ public static int encodedLength(byte[] b) { return ((b.length + 2)/3) * 4; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/LineInputStream.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/LineInputStream.java index 50390f56d2f..1d0533f5f43 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/LineInputStream.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/LineInputStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -64,6 +64,10 @@ public final class LineInputStream extends FilterInputStream { * * This class is similar to the deprecated * DataInputStream.readLine() + * + * @return line. + * + * @throws IOException if an I/O error occurs. */ public String readLine() throws IOException { InputStream in = this.in; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/OutputUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/OutputUtil.java index 92bd21eaa19..88239e07c19 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/OutputUtil.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/OutputUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -54,6 +54,11 @@ public abstract class OutputUtil { /** * Writes a string as ASCII string. + * + * @param s string. + * @param out output stream. + * + * @throws IOException if an I/O error occurs. */ public static void writeAsAscii(String s,OutputStream out) throws IOException { int len = s.length(); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/QEncoderStream.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/QEncoderStream.java index 2cf6e31e7c5..272806bd591 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/QEncoderStream.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/QEncoderStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -69,6 +69,7 @@ public class QEncoderStream extends QPEncoderStream { * @param c the byte. * @exception IOException if an I/O error occurs. */ + @Override public void write(int c) throws IOException { c = c & 0xff; // Turn off the MSB. if (c == ' ') @@ -82,6 +83,11 @@ public class QEncoderStream extends QPEncoderStream { /** * Returns the length of the encoded version of this byte array. + * + * @param b byte array. + * @param encodingWord whether use word or text specials. + * + * @return length. */ public static int encodedLength(byte[] b, boolean encodingWord) { int len = 0; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/UUEncoderStream.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/UUEncoderStream.java index 9cd0216291d..49d9ec7a6e8 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/UUEncoderStream.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/packaging/mime/util/UUEncoderStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -83,23 +83,29 @@ public class UUEncoderStream extends FilterOutputStream { /** * Set up the buffer name and permission mode. * This method has any effect only if it is invoked before - * you start writing into the output stream + * you start writing into the output stream. + * + * @param name name to set for the buffer. + * @param mode permission mode. */ public void setNameMode(String name, int mode) { this.name = name; this.mode = mode; } + @Override public void write(byte[] b, int off, int len) throws IOException { for (int i = 0; i < len; i++) write(b[off + i]); } + @Override public void write(byte[] data) throws IOException { write(data, 0, data.length); } - public void write(int c) throws IOException { + @Override + public void write(int c) throws IOException { /* buffer up characters till we get a line's worth, then encode * and write them out. Max number of characters allowed per * line is 45. @@ -112,6 +118,7 @@ public class UUEncoderStream extends FilterOutputStream { } } + @Override public void flush() throws IOException { if (bufsize > 0) { // If there's unencoded characters in the buffer writePrefix(); @@ -121,6 +128,7 @@ public class UUEncoderStream extends FilterOutputStream { out.flush(); } + @Override public void close() throws IOException { flush(); out.close(); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/Envelope.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/Envelope.java index 607e8c36c68..50ed0edaf98 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/Envelope.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/Envelope.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -41,16 +41,25 @@ import javax.xml.transform.Source; public interface Envelope extends SOAPEnvelope { /** * Get the content as a JAXP Source. + * + * @return source */ Source getContent(); /** * Output the content. + * + * @param out output stream. + * @exception IOException in case of an I/O error. */ void output(OutputStream out) throws IOException; /** * Output the content. + * + * @param out output stream + * @param isFastInfoset true if it is fast infoset. + * @exception IOException in case of an I/O error. */ void output(OutputStream out, boolean isFastInfoset) throws IOException; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/FastInfosetDataContentHandler.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/FastInfosetDataContentHandler.java index e7223cca00e..4c8fb5a78f4 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/FastInfosetDataContentHandler.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/FastInfosetDataContentHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,9 +47,10 @@ public class FastInfosetDataContentHandler implements DataContentHandler { } /** - * return the DataFlavors for this DataContentHandler + * Return the DataFlavors for this DataContentHandler * @return The DataFlavors. */ + @Override public DataFlavor[] getTransferDataFlavors() { // throws Exception; DataFlavor flavors[] = new DataFlavor[1]; flavors[0] = new ActivationDataFlavor( @@ -59,11 +60,13 @@ public class FastInfosetDataContentHandler implements DataContentHandler { } /** - * return the Transfer Data of type DataFlavor from InputStream - * @param df The DataFlavor. - * @param ins The InputStream corresponding to the data. + * Return the Transfer Data of type DataFlavor from InputStream + * @param flavor The DataFlavor. + * @param dataSource DataSource. * @return The constructed Object. + * @exception IOException in case of an I/O error */ + @Override public Object getTransferData(DataFlavor flavor, DataSource dataSource) throws IOException { @@ -81,6 +84,7 @@ public class FastInfosetDataContentHandler implements DataContentHandler { return null; } + @Override public Object getContent(DataSource dataSource) throws IOException { try { return FastInfosetReflection.FastInfosetSource_new( @@ -92,10 +96,11 @@ public class FastInfosetDataContentHandler implements DataContentHandler { } /** - * construct an object from a byte stream + * Construct an object from a byte stream * (similar semantically to previous method, we are deciding * which one to support) */ + @Override public void writeTo(Object obj, String mimeType, OutputStream os) throws IOException { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/GifDataContentHandler.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/GifDataContentHandler.java index 2ac41fcbe77..48ddb7a7d6e 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/GifDataContentHandler.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/GifDataContentHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -52,6 +52,7 @@ public class GifDataContentHandler extends Component implements DataContentHandl * * @return The DataFlavors */ + @Override public DataFlavor[] getTransferDataFlavors() { // throws Exception; return new DataFlavor[] { getDF()}; } @@ -60,9 +61,11 @@ public class GifDataContentHandler extends Component implements DataContentHandl * Return the Transfer Data of type DataFlavor from InputStream. * * @param df The DataFlavor - * @param ins The InputStream corresponding to the data + * @param ds The DataSource * @return String object + * @exception IOException in case of an I/O error */ + @Override public Object getTransferData(DataFlavor df, DataSource ds) throws IOException { // use myDF.equals to be sure to get ActivationDataFlavor.equals, @@ -73,6 +76,7 @@ public class GifDataContentHandler extends Component implements DataContentHandl return null; } + @Override public Object getContent(DataSource ds) throws IOException { InputStream is = ds.getInputStream(); int pos = 0; @@ -98,7 +102,11 @@ public class GifDataContentHandler extends Component implements DataContentHandl /** * Write the object to the output stream, using the specified MIME type. + * @param obj object to write + * @param type requested MIME type of the resulting byte stream + * @param os OutputStream */ + @Override public void writeTo(Object obj, String type, OutputStream os) throws IOException { if (obj != null && !(obj instanceof Image)) diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ImageDataContentHandler.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ImageDataContentHandler.java index b66cbbdfa6c..8f063f155c9 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ImageDataContentHandler.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ImageDataContentHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -67,8 +67,9 @@ public class ImageDataContentHandler extends Component * * @return The DataFlavors. */ + @Override public DataFlavor[] getTransferDataFlavors() { - return (DataFlavor[]) Arrays.copyOf(flavor, flavor.length); + return Arrays.copyOf(flavor, flavor.length); } /** @@ -80,6 +81,7 @@ public class ImageDataContentHandler extends Component * @param ds The DataSource representing the data to be converted. * @return The constructed Object. */ + @Override public Object getTransferData(DataFlavor df, DataSource ds) throws IOException { for (int i=0; i < flavor.length; i++) { @@ -98,6 +100,7 @@ public class ImageDataContentHandler extends Component * @param ds The DataSource representing the data to be converted. * @return The constructed Object. */ + @Override public Object getContent(DataSource ds) throws IOException { return ImageIO.read(new BufferedInputStream(ds.getInputStream())); } @@ -107,11 +110,11 @@ public class ImageDataContentHandler extends Component * and write it to the output stream. * * @param obj The object to be converted. - * @param mimeType The requested MIME type of the resulting byte stream. + * @param type The requested MIME type of the resulting byte stream. * @param os The output stream into which to write the converted * byte stream. */ - + @Override public void writeTo(Object obj, String type, OutputStream os) throws IOException { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/JpegDataContentHandler.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/JpegDataContentHandler.java index 083c1de6bf7..83cfbe55b48 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/JpegDataContentHandler.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/JpegDataContentHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,9 +47,10 @@ public class JpegDataContentHandler public static final String STR_SRC = "java.awt.Image"; /** - * return the DataFlavors for this DataContentHandler + * Return the DataFlavors for this DataContentHandler * @return The DataFlavors. */ + @Override public DataFlavor[] getTransferDataFlavors() { // throws Exception; DataFlavor flavors[] = new DataFlavor[1]; @@ -67,11 +68,12 @@ public class JpegDataContentHandler } /** - * return the Transfer Data of type DataFlavor from InputStream - * @param df The DataFlavor. - * @param ins The InputStream corresponding to the data. + * Return the Transfer Data of type DataFlavor from InputStream + * @param df The DataFlavor + * @param ds The DataSource * @return The constructed Object. */ + @Override public Object getTransferData(DataFlavor df, DataSource ds) { // this is sort of hacky, but will work for the @@ -98,6 +100,7 @@ public class JpegDataContentHandler /** * */ + @Override public Object getContent(DataSource ds) { // throws Exception; InputStream inputStream = null; BufferedImage jpegLoadImage = null; @@ -109,14 +112,18 @@ public class JpegDataContentHandler } catch (Exception e) { } - return (Image) jpegLoadImage; + return jpegLoadImage; } /** - * construct an object from a byte stream + * Construct an object from a byte stream * (similar semantically to previous method, we are deciding * which one to support) + * @param obj object to write + * @param mimeType requested MIME type of the resulting byte stream + * @param os OutputStream */ + @Override public void writeTo(Object obj, String mimeType, OutputStream os) throws IOException { if (!mimeType.equals("image/jpeg")) diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/LazyEnvelope.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/LazyEnvelope.java index 1f83ca5cfde..5cf8b7addb7 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/LazyEnvelope.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/LazyEnvelope.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -38,24 +38,24 @@ public interface LazyEnvelope extends Envelope { /** * Retrieve payload qname without materializing its contents - * @return - * @throws SOAPException + * @return QName + * @throws SOAPException in case of an error */ public QName getPayloadQName() throws SOAPException; /** * Retrieve payload attribute value without materializing its contents - * @param localName - * @return - * @throws SOAPException + * @param localName local name + * @return payload attribute value + * @throws SOAPException in case of an error */ public String getPayloadAttributeValue(String localName) throws SOAPException; /** * Retrieve payload attribute value without materializing its contents - * @param qName - * @return - * @throws SOAPException + * @param qName QName + * @return payload attribute value + * @throws SOAPException in case of an error */ public String getPayloadAttributeValue(QName qName) throws SOAPException; } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/MessageImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/MessageImpl.java index c760f4a8502..a7df70323a4 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/MessageImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/MessageImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -95,7 +95,7 @@ public abstract class MessageImpl /** * True if this part is encoded using Fast Infoset. - * MIME -> application/fastinfoset + * MIME -> application/fastinfoset */ protected boolean isFastInfoset = false; @@ -202,6 +202,9 @@ public abstract class MessageImpl /** * Construct a new message. This will be invoked before message * sends. + * + * @param isFastInfoset whether it is fast infoset + * @param acceptFastInfoset whether to accept fast infoset */ protected MessageImpl(boolean isFastInfoset, boolean acceptFastInfoset) { this.isFastInfoset = isFastInfoset; @@ -214,6 +217,8 @@ public abstract class MessageImpl /** * Shallow copy. + * + * @param msg SoapMessage */ protected MessageImpl(SOAPMessage msg) { if (!(msg instanceof MessageImpl)) { @@ -233,14 +238,17 @@ public abstract class MessageImpl /** * @param stat * the mask value obtained from {@link #identifyContentType(ContentType)} + * @return true if SOAP 1.1 Content */ protected static boolean isSoap1_1Content(int stat) { return (stat & SOAP1_1_FLAG) != 0; } /** + * Check whether it is SOAP 1.2 content. * @param stat * the mask value obtained from {@link #identifyContentType(ContentType)} + * @return true if it is SOAP 1.2 content */ protected static boolean isSoap1_2Content(int stat) { return (stat & SOAP1_2_FLAG) != 0; @@ -298,6 +306,9 @@ public abstract class MessageImpl * Construct a message from an input stream. When messages are * received, there's two parts -- the transport headers and the * message content in a transport specific stream. + * @param headers MimeHeaders + * @param in InputStream + * @exception SOAPExceptionImpl in case of I/O error */ protected MessageImpl(MimeHeaders headers, final InputStream in) throws SOAPExceptionImpl { @@ -332,6 +343,7 @@ public abstract class MessageImpl * received, there's two parts -- the transport headers and the * message content in a transport specific stream. * + * @param headers headers * @param contentType * The parsed content type header from the headers variable. * This is redundant parameter, but it avoids reparsing this header again. @@ -339,6 +351,8 @@ public abstract class MessageImpl * The result of {@link #identifyContentType(ContentType)} over * the contentType parameter. This redundant parameter, but it avoids * recomputing this information again. + * @param in input stream + * @exception SOAPExceptionImpl in case of an error */ protected MessageImpl(MimeHeaders headers, final ContentType contentType, int stat, final InputStream in) throws SOAPExceptionImpl { init(headers, stat, contentType, in); @@ -425,18 +439,22 @@ public abstract class MessageImpl } else if ((stat & MIME_MULTIPART_FLAG) != 0) { final InputStream finalIn = in; DataSource ds = new DataSource() { + @Override public InputStream getInputStream() { return finalIn; } + @Override public OutputStream getOutputStream() { return null; } + @Override public String getContentType() { return contentType.toString(); } + @Override public String getName() { return ""; } @@ -591,10 +609,12 @@ public abstract class MessageImpl return Boolean.valueOf(lazyParsingProp.toString()); } } + @Override public Object getProperty(String property) { - return (String) properties.get(property); + return properties.get(property); } + @Override public void setProperty(String property, Object value) { verify(property, value); properties.put(property, value); @@ -722,6 +742,7 @@ public abstract class MessageImpl return "text/xml"; } + @Override public MimeHeaders getMimeHeaders() { return this.headers; } @@ -805,10 +826,12 @@ public abstract class MessageImpl saved = false; } + @Override public boolean saveRequired() { return saved != true; } + @Override public String getContentDescription() { String[] values = headers.getHeader("Content-Description"); if (values != null && values.length > 0) @@ -816,13 +839,16 @@ public abstract class MessageImpl return null; } + @Override public void setContentDescription(String description) { headers.setHeader("Content-Description", description); needsSave(); } + @Override public abstract SOAPPart getSOAPPart(); + @Override public void removeAllAttachments() { try { initializeAllAttachments(); @@ -836,6 +862,7 @@ public abstract class MessageImpl } } + @Override public int countAttachments() { try { initializeAllAttachments(); @@ -847,6 +874,7 @@ public abstract class MessageImpl return 0; } + @Override public void addAttachmentPart(AttachmentPart attachment) { try { initializeAllAttachments(); @@ -864,6 +892,7 @@ public abstract class MessageImpl static private final Iterator nullIter = Collections.EMPTY_LIST.iterator(); + @Override public Iterator getAttachments() { try { initializeAllAttachments(); @@ -897,12 +926,14 @@ public abstract class MessageImpl private MimeHeaders headers; private AttachmentPart nextAttachment; + @Override public boolean hasNext() { if (nextAttachment == null) nextAttachment = nextMatch(); return nextAttachment != null; } + @Override public AttachmentPart next() { if (nextAttachment != null) { AttachmentPart ret = nextAttachment; @@ -925,11 +956,13 @@ public abstract class MessageImpl return null; } + @Override public void remove() { iter.remove(); } } + @Override public Iterator getAttachments(MimeHeaders headers) { try { initializeAllAttachments(); @@ -942,6 +975,7 @@ public abstract class MessageImpl return new MimeMatchingIterator(headers); } + @Override public void removeAttachments(MimeHeaders headers) { try { initializeAllAttachments(); @@ -966,10 +1000,12 @@ public abstract class MessageImpl // needsSave(); } + @Override public AttachmentPart createAttachmentPart() { return new AttachmentPartImpl(); } + @Override public AttachmentPart getAttachment(SOAPElement element) throws SOAPException { try { @@ -1187,6 +1223,7 @@ public abstract class MessageImpl } } + @Override public void saveChanges() throws SOAPException { // suck in all the data from the attachments and have it @@ -1340,6 +1377,7 @@ public abstract class MessageImpl } + @Override public void writeTo(OutputStream out) throws SOAPException, IOException { if (saveRequired()){ this.optimizeAttachmentProcessing = true; @@ -1397,6 +1435,7 @@ public abstract class MessageImpl needsSave(); } + @Override public SOAPBody getSOAPBody() throws SOAPException { SOAPBody body = getSOAPPart().getEnvelope().getBody(); /*if (body == null) { @@ -1405,6 +1444,7 @@ public abstract class MessageImpl return body; } + @Override public SOAPHeader getSOAPHeader() throws SOAPException { SOAPHeader hdr = getSOAPPart().getEnvelope().getHeader(); /*if (hdr == null) { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/MultipartDataContentHandler.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/MultipartDataContentHandler.java index fd31cd9533f..cc7696e5ee9 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/MultipartDataContentHandler.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/MultipartDataContentHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -43,6 +43,7 @@ public class MultipartDataContentHandler implements DataContentHandler { * * @return The DataFlavors */ + @Override public DataFlavor[] getTransferDataFlavors() { // throws Exception; return new DataFlavor[] { myDF }; } @@ -51,9 +52,10 @@ public class MultipartDataContentHandler implements DataContentHandler { * Return the Transfer Data of type DataFlavor from InputStream. * * @param df The DataFlavor - * @param ins The InputStream corresponding to the data + * @param ds The DataSource * @return String object */ + @Override public Object getTransferData(DataFlavor df, DataSource ds) { // use myDF.equals to be sure to get ActivationDataFlavor.equals, // which properly ignores Content-Type parameters in comparison @@ -65,7 +67,11 @@ public class MultipartDataContentHandler implements DataContentHandler { /** * Return the content. + * + * @param ds The DataSource + * @return content */ + @Override public Object getContent(DataSource ds) { try { return new MimeMultipart( @@ -78,6 +84,7 @@ public class MultipartDataContentHandler implements DataContentHandler { /** * Write the object to the output stream, using the specific MIME type. */ + @Override public void writeTo(Object obj, String mimeType, OutputStream os) throws IOException { if (obj instanceof MimeMultipart) { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPDocumentImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPDocumentImpl.java index 7dac69841a9..417cd9a9cc9 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPDocumentImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPDocumentImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,16 +29,42 @@ */ package com.sun.xml.internal.messaging.saaj.soap; -import java.util.logging.Logger; - -import com.sun.org.apache.xerces.internal.dom.DocumentImpl; -import org.w3c.dom.*; - -import com.sun.xml.internal.messaging.saaj.soap.impl.*; +import com.sun.xml.internal.messaging.saaj.soap.impl.CDATAImpl; +import com.sun.xml.internal.messaging.saaj.soap.impl.ElementFactory; +import com.sun.xml.internal.messaging.saaj.soap.impl.ElementImpl; +import com.sun.xml.internal.messaging.saaj.soap.impl.SOAPCommentImpl; +import com.sun.xml.internal.messaging.saaj.soap.impl.SOAPTextImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; +import com.sun.xml.internal.messaging.saaj.util.SAAJUtil; +import org.w3c.dom.Attr; +import org.w3c.dom.CDATASection; +import org.w3c.dom.Comment; +import org.w3c.dom.DOMConfiguration; +import org.w3c.dom.DOMException; +import org.w3c.dom.DOMImplementation; +import org.w3c.dom.Document; +import org.w3c.dom.DocumentFragment; +import org.w3c.dom.DocumentType; +import org.w3c.dom.Element; +import org.w3c.dom.EntityReference; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; +import org.w3c.dom.ProcessingInstruction; +import org.w3c.dom.UserDataHandler; -public class SOAPDocumentImpl extends DocumentImpl implements SOAPDocument { +import javax.xml.parsers.DocumentBuilder; +import javax.xml.parsers.DocumentBuilderFactory; +import javax.xml.parsers.ParserConfigurationException; +import javax.xml.soap.SOAPElement; +import javax.xml.soap.SOAPException; +import java.text.MessageFormat; +import java.util.HashMap; +import java.util.Map; +import java.util.logging.Logger; + +public class SOAPDocumentImpl implements SOAPDocument, javax.xml.soap.Node, Document { private static final String XMLNS = "xmlns".intern(); protected static final Logger log = @@ -47,8 +73,24 @@ public class SOAPDocumentImpl extends DocumentImpl implements SOAPDocument { SOAPPartImpl enclosingSOAPPart; + private Document document; + + private Map domToSoap = new HashMap<>(); + public SOAPDocumentImpl(SOAPPartImpl enclosingDocument) { + document = createDocument(); this.enclosingSOAPPart = enclosingDocument; + register(this); + } + + private Document createDocument() { + DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance("com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl", SAAJUtil.getSystemClassLoader()); + try { + final DocumentBuilder documentBuilder = docFactory.newDocumentBuilder(); + return documentBuilder.newDocument(); + } catch (ParserConfigurationException e) { + throw new RuntimeException("Error creating xml document", e); + } } // public SOAPDocumentImpl(boolean grammarAccess) { @@ -81,7 +123,7 @@ public class SOAPDocumentImpl extends DocumentImpl implements SOAPDocument { } public DOMImplementation getImplementation() { - return super.getImplementation(); + return document.getImplementation(); } public Element getDocumentElement() { @@ -91,7 +133,7 @@ public class SOAPDocumentImpl extends DocumentImpl implements SOAPDocument { } protected Element doGetDocumentElement() { - return super.getDocumentElement(); + return document.getDocumentElement(); } public Element createElement(String tagName) throws DOMException { @@ -103,7 +145,7 @@ public class SOAPDocumentImpl extends DocumentImpl implements SOAPDocument { } public DocumentFragment createDocumentFragment() { - return new SOAPDocumentFragment(this); + return document.createDocumentFragment(); } public org.w3c.dom.Text createTextNode(String data) { @@ -139,7 +181,7 @@ public class SOAPDocumentImpl extends DocumentImpl implements SOAPDocument { } } - return super.createAttribute(name); + return document.createAttribute(name); } public EntityReference createEntityReference(String name) @@ -149,12 +191,15 @@ public class SOAPDocumentImpl extends DocumentImpl implements SOAPDocument { } public NodeList getElementsByTagName(String tagname) { - return super.getElementsByTagName(tagname); + return document.getElementsByTagName(tagname); } public org.w3c.dom.Node importNode(Node importedNode, boolean deep) throws DOMException { - return super.importNode(importedNode, deep); + final Node node = document.importNode(getDomNode(importedNode), deep); + return node instanceof Element ? + ElementFactory.createElement(this, (Element) node) + : node; } public Element createElementNS(String namespaceURI, String qualifiedName) @@ -168,26 +213,386 @@ public class SOAPDocumentImpl extends DocumentImpl implements SOAPDocument { public Attr createAttributeNS(String namespaceURI, String qualifiedName) throws DOMException { - return super.createAttributeNS(namespaceURI, qualifiedName); + return document.createAttributeNS(namespaceURI, qualifiedName); } public NodeList getElementsByTagNameNS( String namespaceURI, String localName) { - return super.getElementsByTagNameNS(namespaceURI, localName); + return document.getElementsByTagNameNS(namespaceURI, localName); } public Element getElementById(String elementId) { - return super.getElementById(elementId); + return document.getElementById(elementId); } + @Override + public String getInputEncoding() { + return document.getInputEncoding(); + } + + @Override + public String getXmlEncoding() { + return document.getXmlEncoding(); + } + + @Override + public boolean getXmlStandalone() { + return document.getXmlStandalone(); + } + + @Override + public void setXmlStandalone(boolean xmlStandalone) throws DOMException { + document.setXmlStandalone(xmlStandalone); + } + + @Override + public String getXmlVersion() { + return document.getXmlVersion(); + } + + @Override + public void setXmlVersion(String xmlVersion) throws DOMException { + document.setXmlVersion(xmlVersion); + } + + @Override + public boolean getStrictErrorChecking() { + return document.getStrictErrorChecking(); + } + + @Override + public void setStrictErrorChecking(boolean strictErrorChecking) { + document.setStrictErrorChecking(strictErrorChecking); + } + + @Override + public String getDocumentURI() { + return document.getDocumentURI(); + } + + @Override + public void setDocumentURI(String documentURI) { + document.setDocumentURI(documentURI); + } + + @Override + public Node adoptNode(Node source) throws DOMException { + return document.adoptNode(source); + } + + @Override + public DOMConfiguration getDomConfig() { + return document.getDomConfig(); + } + + @Override + public void normalizeDocument() { + document.normalizeDocument(); + } + + @Override + public Node renameNode(Node n, String namespaceURI, String qualifiedName) throws DOMException { + return document.renameNode(n, namespaceURI, qualifiedName); + } + + @Override + public String getNodeName() { + return document.getNodeName(); + } + + @Override + public String getNodeValue() throws DOMException { + return document.getNodeValue(); + } + + @Override + public void setNodeValue(String nodeValue) throws DOMException { + document.setNodeValue(nodeValue); + } + + @Override + public short getNodeType() { + return document.getNodeType(); + } + + @Override + public Node getParentNode() { + return document.getParentNode(); + } + + @Override + public NodeList getChildNodes() { + return document.getChildNodes(); + } + + @Override + public Node getFirstChild() { + return document.getFirstChild(); + } + + @Override + public Node getLastChild() { + return document.getLastChild(); + } + + @Override + public Node getPreviousSibling() { + return document.getPreviousSibling(); + } + + @Override + public Node getNextSibling() { + return document.getNextSibling(); + } + + @Override + public NamedNodeMap getAttributes() { + return document.getAttributes(); + } + + @Override + public Document getOwnerDocument() { + return document.getOwnerDocument(); + } + + @Override + public Node insertBefore(Node newChild, Node refChild) throws DOMException { + return document.insertBefore(getDomNode(newChild), getDomNode(refChild)); + } + + @Override + public Node replaceChild(Node newChild, Node oldChild) throws DOMException { + return document.replaceChild(getDomNode(newChild), getDomNode(oldChild)); + } + + @Override + public Node removeChild(Node oldChild) throws DOMException { + return document.removeChild(getDomNode(oldChild)); + } + + @Override + public Node appendChild(Node newChild) throws DOMException { + return document.appendChild(getDomNode(newChild)); + } + + @Override + public boolean hasChildNodes() { + return document.hasChildNodes(); + } + + @Override public Node cloneNode(boolean deep) { - SOAPPartImpl newSoapPart = getSOAPPart().doCloneNode(); - super.cloneNode(newSoapPart.getDocument(), deep); - return newSoapPart; + return document.cloneNode(deep); } - public void cloneNode(SOAPDocumentImpl newdoc, boolean deep) { - super.cloneNode(newdoc, deep); + @Override + public void normalize() { + document.normalize(); + } + + @Override + public boolean isSupported(String feature, String version) { + return document.isSupported(feature, version); + } + + @Override + public String getNamespaceURI() { + return document.getNamespaceURI(); + } + + @Override + public String getPrefix() { + return document.getPrefix(); + } + + @Override + public void setPrefix(String prefix) throws DOMException { + document.setPrefix(prefix); + } + + @Override + public String getLocalName() { + return document.getLocalName(); + } + + @Override + public boolean hasAttributes() { + return document.hasAttributes(); + } + + @Override + public String getBaseURI() { + return document.getBaseURI(); + } + + @Override + public short compareDocumentPosition(Node other) throws DOMException { + return document.compareDocumentPosition(other); + } + + @Override + public String getTextContent() throws DOMException { + return document.getTextContent(); + } + + @Override + public void setTextContent(String textContent) throws DOMException { + document.setTextContent(textContent); + } + + @Override + public boolean isSameNode(Node other) { + return document.isSameNode(other); + } + + @Override + public String lookupPrefix(String namespaceURI) { + return document.lookupPrefix(namespaceURI); + } + + @Override + public boolean isDefaultNamespace(String namespaceURI) { + return document.isDefaultNamespace(namespaceURI); + } + + @Override + public String lookupNamespaceURI(String prefix) { + return document.lookupNamespaceURI(prefix); + } + + @Override + public boolean isEqualNode(Node arg) { + return document.isEqualNode(arg); + } + + @Override + public Object getFeature(String feature, String version) { + return document.getFeature(feature, version); + } + + @Override + public Object setUserData(String key, Object data, UserDataHandler handler) { + return document.setUserData(key, data, handler); + } + + @Override + public Object getUserData(String key) { + return document.getUserData(key); + } + + public Document getDomDocument() { + return document; + } + + /** + * Insert a mapping information for {@link org.w3c.dom.Node} - {@link javax.xml.soap.Node}. + * + * In SAAJ, elements in DOM are expected to be interfaces of SAAJ, on the other hand in JDKs Xerces, + * they are casted to internal impl classes. After removal of SAAJ dependency + * to JDKs internal classes elements in DOM can never be both of them. + * + * @param node SAAJ wrapper node for w3c DOM node + */ + public void register(javax.xml.soap.Node node) { + final Node domElement = getDomNode(node); + if (domToSoap.containsKey(domElement)) { + throw new IllegalStateException("Element " + domElement.getNodeName() + + " is already registered"); + } + domToSoap.put(domElement, node); + } + + /** + * Find a soap wrapper for w3c dom node. + * + * @param node w3c dom node nullable + * @return soap wrapper for w3c dom node + * + * @throws + */ + public javax.xml.soap.Node find(Node node) { + return find(node, true); + } + + private javax.xml.soap.Node find(Node node, boolean required) { + if (node == null) { + return null; + } + if (node instanceof javax.xml.soap.Node) { + return (javax.xml.soap.Node) node; + } + final javax.xml.soap.Node found = domToSoap.get(node); + if (found == null && required) { + throw new IllegalArgumentException(MessageFormat.format("Cannot find SOAP wrapper for element {0}", node)); + } + return found; + } + + /** + * If corresponding soap wrapper exists for w3c dom node it is returned, + * if not passed dom element is returned. + * + * @param node w3c dom node + * @return soap wrapper or passed w3c dom node if not found + */ + public Node findIfPresent(Node node) { + final javax.xml.soap.Node found = find(node, false); + return found != null ? found : node; + } + + /** + * Extracts w3c dom node from corresponding soap wrapper. + * + * @param node soap or dom nullable + * @return dom node + */ + public Node getDomNode(Node node) { + if (node instanceof SOAPDocumentImpl) { + return ((SOAPDocumentImpl)node).getDomElement(); + } else if (node instanceof ElementImpl) { + return ((ElementImpl) node).getDomElement(); + } else if (node instanceof SOAPTextImpl) { + return ((SOAPTextImpl)node).getDomElement(); + } else if (node instanceof SOAPCommentImpl) { + return ((SOAPCommentImpl)node).getDomElement(); + } else if (node instanceof CDATAImpl) { + return ((CDATAImpl) node).getDomElement(); + } + return node; + } + + public Document getDomElement() { + return document; + } + + @Override + public String getValue() { + throw new UnsupportedOperationException(); + } + + @Override + public void setValue(String value) { + throw new UnsupportedOperationException(); + } + + @Override + public void setParentElement(SOAPElement parent) throws SOAPException { + throw new UnsupportedOperationException(); + } + + @Override + public SOAPElement getParentElement() { + throw new UnsupportedOperationException(); + } + + @Override + public void detachNode() { + throw new UnsupportedOperationException(); + } + + @Override + public void recycleNode() { + throw new UnsupportedOperationException(); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPPartImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPPartImpl.java index 19cc1b4ec30..49abddb9f94 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPPartImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPPartImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,29 +25,56 @@ package com.sun.xml.internal.messaging.saaj.soap; -import java.io.*; -import java.util.Iterator; -import java.util.logging.Logger; -import java.util.logging.Level; - -import javax.activation.DataHandler; -import javax.activation.DataSource; -import javax.xml.soap.*; -import javax.xml.transform.Source; -import javax.xml.transform.stream.StreamSource; - -import org.w3c.dom.*; - -import com.sun.xml.internal.messaging.saaj.packaging.mime.internet.MimeBodyPart; - import com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl; +import com.sun.xml.internal.messaging.saaj.packaging.mime.internet.MimeBodyPart; import com.sun.xml.internal.messaging.saaj.soap.impl.ElementImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.EnvelopeImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; -import com.sun.xml.internal.messaging.saaj.util.*; +import com.sun.xml.internal.messaging.saaj.util.ByteInputStream; +import com.sun.xml.internal.messaging.saaj.util.ByteOutputStream; +import com.sun.xml.internal.messaging.saaj.util.FastInfosetReflection; +import com.sun.xml.internal.messaging.saaj.util.JAXMStreamSource; +import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; +import com.sun.xml.internal.messaging.saaj.util.MimeHeadersUtil; +import com.sun.xml.internal.messaging.saaj.util.SAAJUtil; +import com.sun.xml.internal.messaging.saaj.util.XMLDeclarationParser; +import org.w3c.dom.Attr; +import org.w3c.dom.CDATASection; +import org.w3c.dom.Comment; +import org.w3c.dom.DOMConfiguration; +import org.w3c.dom.DOMException; +import org.w3c.dom.DOMImplementation; +import org.w3c.dom.Document; +import org.w3c.dom.DocumentFragment; +import org.w3c.dom.DocumentType; +import org.w3c.dom.Element; +import org.w3c.dom.EntityReference; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.NodeList; +import org.w3c.dom.ProcessingInstruction; +import org.w3c.dom.UserDataHandler; +import javax.activation.DataHandler; +import javax.activation.DataSource; +import javax.xml.soap.MimeHeaders; +import javax.xml.soap.SOAPElement; +import javax.xml.soap.SOAPEnvelope; +import javax.xml.soap.SOAPException; +import javax.xml.soap.SOAPPart; +import javax.xml.transform.Source; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.sax.SAXSource; +import javax.xml.transform.stream.StreamSource; +import java.io.IOException; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.io.OutputStream; +import java.io.PushbackReader; +import java.io.Reader; +import java.io.UnsupportedEncodingException; +import java.util.Iterator; +import java.util.logging.Level; +import java.util.logging.Logger; /** * SOAPPartImpl is the first attachment. This contains the XML/SOAP document. @@ -128,20 +155,21 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { envelope = createEnvelopeFromSource(); } else { envelope = createEmptyEnvelope(null); - document.insertBefore(envelope, null); + document.insertBefore(((EnvelopeImpl) envelope).getDomElement(), null); } return envelope; } protected void lookForEnvelope() throws SOAPException { Element envelopeChildElement = document.doGetDocumentElement(); - if (envelopeChildElement == null || envelopeChildElement instanceof Envelope) { - envelope = (EnvelopeImpl) envelopeChildElement; - } else if (!(envelopeChildElement instanceof ElementImpl)) { + org.w3c.dom.Node soapEnvelope = document.findIfPresent(envelopeChildElement); + if (soapEnvelope == null || soapEnvelope instanceof Envelope) { + envelope = (EnvelopeImpl) soapEnvelope; + } else if (document.find(envelopeChildElement) == null) { log.severe("SAAJ0512.soap.incorrect.factory.used"); throw new SOAPExceptionImpl("Unable to create envelope: incorrect factory used during tree construction"); } else { - ElementImpl soapElement = (ElementImpl) envelopeChildElement; + ElementImpl soapElement = (ElementImpl) document.find(envelopeChildElement); if (soapElement.getLocalName().equalsIgnoreCase("Envelope")) { String prefix = soapElement.getPrefix(); String uri = (prefix == null) ? soapElement.getNamespaceURI() : soapElement.getNamespaceURI(prefix); @@ -498,7 +526,7 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public NamedNodeMap getAttributes() { - return document.getAttributes(); + return document.getDomDocument().getAttributes(); } public NodeList getChildNodes() { @@ -517,11 +545,11 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public String getLocalName() { - return document.getLocalName(); + return document.getDomDocument().getLocalName(); } public String getNamespaceURI() { - return document.getNamespaceURI(); + return document.getDomDocument().getNamespaceURI(); } public org.w3c.dom.Node getNextSibling() { @@ -530,11 +558,11 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public String getNodeName() { - return document.getNodeName(); + return document.getDomDocument().getNodeName(); } public short getNodeType() { - return document.getNodeType(); + return document.getDomDocument().getNodeType(); } public String getNodeValue() throws DOMException { @@ -542,23 +570,23 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public Document getOwnerDocument() { - return document.getOwnerDocument(); + return document.getDomDocument().getOwnerDocument(); } public org.w3c.dom.Node getParentNode() { - return document.getParentNode(); + return document.getDomDocument().getParentNode(); } public String getPrefix() { - return document.getPrefix(); + return document.getDomDocument().getPrefix(); } public org.w3c.dom.Node getPreviousSibling() { - return document.getPreviousSibling(); + return document.getDomDocument().getPreviousSibling(); } public boolean hasAttributes() { - return document.hasAttributes(); + return document.getDomDocument().hasAttributes(); } public boolean hasChildNodes() { @@ -575,7 +603,7 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public boolean isSupported(String arg0, String arg1) { - return document.isSupported(arg0, arg1); + return document.getDomDocument().isSupported(arg0, arg1); } public void normalize() { @@ -686,7 +714,7 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public DOMConfiguration getDomConfig() { - return document.getDomConfig(); + return document.getDomDocument().getDomConfig(); } public org.w3c.dom.Node adoptNode(org.w3c.dom.Node source) throws DOMException { @@ -699,7 +727,7 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public String getDocumentURI() { - return document.getDocumentURI(); + return document.getDomDocument().getDocumentURI(); } public void setStrictErrorChecking(boolean strictErrorChecking) { @@ -707,15 +735,15 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public String getInputEncoding() { - return document.getInputEncoding(); + return document.getDomDocument().getInputEncoding(); } public String getXmlEncoding() { - return document.getXmlEncoding(); + return document.getDomDocument().getXmlEncoding(); } public boolean getXmlStandalone() { - return document.getXmlStandalone(); + return document.getDomDocument().getXmlStandalone(); } public void setXmlStandalone(boolean xmlStandalone) throws DOMException { @@ -723,7 +751,7 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public String getXmlVersion() { - return document.getXmlVersion(); + return document.getDomDocument().getXmlVersion(); } public void setXmlVersion(String xmlVersion) throws DOMException { @@ -731,12 +759,12 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public boolean getStrictErrorChecking() { - return document.getStrictErrorChecking(); + return document.getDomDocument().getStrictErrorChecking(); } // DOM L3 methods from org.w3c.dom.Node public String getBaseURI() { - return document.getBaseURI(); + return document.getDomDocument().getBaseURI(); } public short compareDocumentPosition(org.w3c.dom.Node other) @@ -758,7 +786,7 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public String lookupPrefix(String namespaceURI) { - return document.lookupPrefix(namespaceURI); + return document.getDomDocument().lookupPrefix(namespaceURI); } public boolean isDefaultNamespace(String namespaceURI) { @@ -770,7 +798,7 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public boolean isEqualNode(org.w3c.dom.Node arg) { - return document.isEqualNode(arg); + return document.getDomDocument().isEqualNode(arg); } public Object getFeature(String feature, @@ -785,7 +813,7 @@ public abstract class SOAPPartImpl extends SOAPPart implements SOAPDocument { } public Object getUserData(String key) { - return document.getUserData(key); + return document.getDomDocument().getUserData(key); } public void recycleNode() { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPVersionMismatchException.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPVersionMismatchException.java index 96fcb591336..d4bd32cd9ef 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPVersionMismatchException.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/SOAPVersionMismatchException.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -63,6 +63,9 @@ public class SOAPVersionMismatchException extends SOAPExceptionImpl { /** * Constructs a SOAPExceptionImpl object initialized * with the given Throwable object. + * + * @param cause a Throwable object that is to + * be embedded in this SOAPExceptionImpl object */ public SOAPVersionMismatchException(Throwable cause) { super(cause); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/StringDataContentHandler.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/StringDataContentHandler.java index 1ee09435fb7..491f9eac303 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/StringDataContentHandler.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/StringDataContentHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,7 +33,7 @@ import com.sun.xml.internal.messaging.saaj.packaging.mime.internet.MimeUtility; import com.sun.xml.internal.messaging.saaj.packaging.mime.internet.ContentType; /** - * JAF data content handler for text/plain --> String + * JAF data content handler for text/plain --> String * */ public class StringDataContentHandler implements DataContentHandler { @@ -51,6 +51,7 @@ public class StringDataContentHandler implements DataContentHandler { * * @return The DataFlavors */ + @Override public DataFlavor[] getTransferDataFlavors() { return new DataFlavor[] { getDF() }; } @@ -62,6 +63,7 @@ public class StringDataContentHandler implements DataContentHandler { * @param ds The DataSource corresponding to the data * @return String object */ + @Override public Object getTransferData(DataFlavor df, DataSource ds) throws IOException { // use myDF.equals to be sure to get ActivationDataFlavor.equals, @@ -72,6 +74,7 @@ public class StringDataContentHandler implements DataContentHandler { return null; } + @Override public Object getContent(DataSource ds) throws IOException { String enc = null; InputStreamReader is = null; @@ -120,6 +123,7 @@ public class StringDataContentHandler implements DataContentHandler { /** * Write the object to the output stream, using the specified MIME type. */ + @Override public void writeTo(Object obj, String type, OutputStream os) throws IOException { if (!(obj instanceof String)) diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/XmlDataContentHandler.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/XmlDataContentHandler.java index dc5e06dca5b..5dea4672a3d 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/XmlDataContentHandler.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/XmlDataContentHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -56,6 +56,7 @@ public class XmlDataContentHandler implements DataContentHandler { * return the DataFlavors for this DataContentHandler * @return The DataFlavors. */ + @Override public DataFlavor[] getTransferDataFlavors() { // throws Exception; DataFlavor flavors[] = new DataFlavor[2]; @@ -69,10 +70,11 @@ public class XmlDataContentHandler implements DataContentHandler { /** * return the Transfer Data of type DataFlavor from InputStream - * @param df The DataFlavor. - * @param ins The InputStream corresponding to the data. + * @param flavor The DataFlavor. + * @param dataSource The DataSource. * @return The constructed Object. */ + @Override public Object getTransferData(DataFlavor flavor, DataSource dataSource) throws IOException { if (flavor.getMimeType().startsWith("text/xml") || @@ -87,6 +89,7 @@ public class XmlDataContentHandler implements DataContentHandler { /** * */ + @Override public Object getContent(DataSource dataSource) throws IOException { return new StreamSource(dataSource.getInputStream()); } @@ -96,6 +99,7 @@ public class XmlDataContentHandler implements DataContentHandler { * (similar semantically to previous method, we are deciding * which one to support) */ + @Override public void writeTo(Object obj, String mimeType, OutputStream os) throws IOException { if (!mimeType.startsWith("text/xml") && !mimeType.startsWith("application/xml")) diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/BodyImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/BodyImpl.java index 8da4d8a59f8..4993bf71e7e 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/BodyImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/BodyImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,6 +36,7 @@ import javax.xml.stream.XMLStreamReader; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; +import com.sun.xml.internal.messaging.saaj.util.SAAJUtil; import org.w3c.dom.*; import org.w3c.dom.Node; @@ -60,6 +61,10 @@ public abstract class BodyImpl extends ElementImpl implements SOAPBody { super(ownerDoc, bodyName); } + public BodyImpl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected abstract NameImpl getFaultName(String name); protected abstract boolean isFault(SOAPElement child); protected abstract SOAPBodyElement createBodyElement(Name name); @@ -155,7 +160,7 @@ public abstract class BodyImpl extends ElementImpl implements SOAPBody { if (hasFault()) { if (fault == null) { //initialize fault member - fault = (SOAPFault) getFirstChildElement(); + fault = (SOAPFault) getSoapDocument().find(getFirstChildElement()); } return fault; } @@ -259,11 +264,12 @@ public abstract class BodyImpl extends ElementImpl implements SOAPBody { } protected SOAPElement convertToSoapElement(Element element) { - if ((element instanceof SOAPBodyElement) && + final Node soapNode = getSoapDocument().findIfPresent(element); + if ((soapNode instanceof SOAPBodyElement) && //this check is required because ElementImpl currently // implements SOAPBodyElement - !(element.getClass().equals(ElementImpl.class))) { - return (SOAPElement) element; + !(soapNode.getClass().equals(ElementImpl.class))) { + return (SOAPElement) soapNode; } else { return replaceElementWithSOAPElement( element, @@ -314,7 +320,7 @@ public abstract class BodyImpl extends ElementImpl implements SOAPBody { Document document = null; try { - DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); + DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance("com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl", SAAJUtil.getSystemClassLoader()); factory.setNamespaceAware(true); DocumentBuilder builder = factory.newDocumentBuilder(); document = builder.newDocument(); @@ -440,7 +446,7 @@ public abstract class BodyImpl extends ElementImpl implements SOAPBody { //not lazy -Just get first child element and return its attribute Element elem = getFirstChildElement(); if (elem != null) { - return elem.getAttribute(localName); + return elem.getAttribute(getLocalName()); } } return null; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/CDATAImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/CDATAImpl.java index c64e3f80772..b406caf111e 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/CDATAImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/CDATAImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,10 +32,17 @@ import javax.xml.soap.SOAPException; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; +import com.sun.xml.internal.messaging.saaj.util.SAAJUtil; +import org.w3c.dom.CDATASection; +import org.w3c.dom.DOMException; +import org.w3c.dom.Document; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; +import org.w3c.dom.Text; +import org.w3c.dom.UserDataHandler; -public class CDATAImpl - extends com.sun.org.apache.xerces.internal.dom.CDATASectionImpl - implements javax.xml.soap.Text { +public class CDATAImpl implements CDATASection, javax.xml.soap.Text { protected static final Logger log = Logger.getLogger(LogDomainConstants.SOAP_IMPL_DOMAIN, @@ -44,8 +51,256 @@ public class CDATAImpl static final String cdataUC = " 0); + //this is because of BugfixTest#testCR7020991, after removal internal dependencies + //SOAPDocumentImpl#createAttribute is not called anymore from xerces parent + if (isQualifiedName) { + String nsUri = null; + String prefix = name.substring(0, name.indexOf(":")); + //cannot do anything to resolve the URI if prefix is not + //XMLNS. + if (XMLNS.equals(prefix)) { + nsUri = ElementImpl.XMLNS_URI; + setAttributeNS(nsUri, name, value); + return; + } + } + element.setAttribute(name, value); + } + + @Override + public void removeAttribute(String name) throws DOMException { + element.removeAttribute(name); + } + + @Override + public Attr getAttributeNode(String name) { + return element.getAttributeNode(name); + } + + @Override + public Attr setAttributeNode(Attr newAttr) throws DOMException { + return element.setAttributeNode(newAttr); + } + + @Override + public Attr removeAttributeNode(Attr oldAttr) throws DOMException { + return element.removeAttributeNode(oldAttr); + } + + @Override + public NodeList getElementsByTagName(String name) { + return new NodeListImpl(getSoapDocument(), element.getElementsByTagName(name)); + } + + @Override + public String getAttributeNS(String namespaceURI, String localName) throws DOMException { + return element.getAttributeNS(namespaceURI, localName); + } + protected static final Logger log = Logger.getLogger(LogDomainConstants.SOAP_IMPL_DOMAIN, "com.sun.xml.internal.messaging.saaj.soap.impl.LocalStrings"); @@ -72,22 +133,27 @@ public class ElementImpl */ public final static String XML_URI = "http://www.w3.org/XML/1998/namespace".intern(); + private final static String XMLNS = "xmlns".intern(); + public ElementImpl(SOAPDocumentImpl ownerDoc, Name name) { - super( - ownerDoc, - name.getURI(), - name.getQualifiedName(), - name.getLocalName()); + this.soapDocument = ownerDoc; + this.element = ownerDoc.getDomDocument().createElementNS(name.getURI(), name.getQualifiedName()); elementQName = NameImpl.convertToQName(name); + getSoapDocument().register(this); } public ElementImpl(SOAPDocumentImpl ownerDoc, QName name) { - super( - ownerDoc, - name.getNamespaceURI(), - getQualifiedName(name), - name.getLocalPart()); + this.soapDocument = ownerDoc; + this.element = ownerDoc.getDomDocument().createElementNS(name.getNamespaceURI(), getQualifiedName(name)); elementQName = name; + getSoapDocument().register(this); + } + + public ElementImpl(SOAPDocumentImpl ownerDoc, Element domElement) { + this.element = domElement; + this.soapDocument = ownerDoc; + this.elementQName = new QName(domElement.getNamespaceURI(), domElement.getLocalName()); + getSoapDocument().register(this); } public ElementImpl( @@ -95,9 +161,11 @@ public class ElementImpl String uri, String qualifiedName) { - super(ownerDoc, uri, qualifiedName); + this.soapDocument = ownerDoc; + this.element = ownerDoc.getDomDocument().createElementNS(uri, qualifiedName); elementQName = new QName(uri, getLocalPart(qualifiedName), getPrefix(qualifiedName)); + getSoapDocument().register(this); } public void ensureNamespaceIsDeclared(String prefix, String uri) { @@ -111,11 +179,132 @@ public class ElementImpl } public Document getOwnerDocument() { - Document doc = super.getOwnerDocument(); - if (doc instanceof SOAPDocument) - return ((SOAPDocument) doc).getDocument(); - else - return doc; + return soapDocument; + } + + @Override + public Node insertBefore(Node newChild, Node refChild) throws DOMException { + return element.insertBefore(getSoapDocument().getDomNode(newChild), getSoapDocument().getDomNode(refChild)); + } + + @Override + public Node replaceChild(Node newChild, Node oldChild) throws DOMException { + return element.replaceChild(getSoapDocument().getDomNode(newChild), getSoapDocument().getDomNode(oldChild)); + } + + @Override + public Node removeChild(Node oldChild) throws DOMException { + return element.removeChild(getSoapDocument().getDomNode(oldChild)); + } + + @Override + public Node appendChild(Node newChild) throws DOMException { + return element.appendChild(getSoapDocument().getDomNode(newChild)); + } + + @Override + public boolean hasChildNodes() { + return element.hasChildNodes(); + } + + @Override + public Node cloneNode(boolean deep) { + return element.cloneNode(deep); + } + + @Override + public void normalize() { + element.normalize(); + } + + @Override + public boolean isSupported(String feature, String version) { + return element.isSupported(feature, version); + } + + @Override + public String getNamespaceURI() { + return element.getNamespaceURI(); + } + + @Override + public String getPrefix() { + return element.getPrefix(); + } + + @Override + public void setPrefix(String prefix) throws DOMException { + element.setPrefix(prefix); + } + + @Override + public String getLocalName() { + return element.getLocalName(); + } + + @Override + public boolean hasAttributes() { + return element.hasAttributes(); + } + + @Override + public String getBaseURI() { + return element.getBaseURI(); + } + + @Override + public short compareDocumentPosition(Node other) throws DOMException { + return element.compareDocumentPosition(other); + } + + @Override + public String getTextContent() throws DOMException { + return element.getTextContent(); + } + + @Override + public void setTextContent(String textContent) throws DOMException { + element.setTextContent(textContent); + } + + @Override + public boolean isSameNode(Node other) { + return element.isSameNode(other); + } + + @Override + public String lookupPrefix(String namespaceURI) { + return element.lookupPrefix(namespaceURI); + } + + @Override + public boolean isDefaultNamespace(String namespaceURI) { + return element.isDefaultNamespace(namespaceURI); + } + + @Override + public String lookupNamespaceURI(String prefix) { + return element.lookupNamespaceURI(prefix); + } + + @Override + public boolean isEqualNode(Node arg) { + return element.isEqualNode(arg); + } + + @Override + public Object getFeature(String feature, String version) { + return element.getFeature(feature, version); + } + + @Override + public Object setUserData(String key, Object data, UserDataHandler handler) { + return element.setUserData(key, data, handler); + } + + @Override + public Object getUserData(String key) { + return element.getUserData(key); } public SOAPElement addChildElement(Name name) throws SOAPException { @@ -353,13 +542,16 @@ public class ElementImpl // preserve the encodingStyle attr as it may get lost in the import String encodingStyle = element.getEncodingStyle(); - ElementImpl importedElement = (ElementImpl) importElement(element); + final Element domElement = ((ElementImpl) element).getDomElement(); + final Element importedElement = importElement(domElement); addNode(importedElement); - if (encodingStyle != null) - importedElement.setEncodingStyle(encodingStyle); + final SOAPElement converted = convertToSoapElement(importedElement); - return convertToSoapElement(importedElement); + if (encodingStyle != null) + converted.setEncodingStyle(encodingStyle); + + return converted; } protected Element importElement(Element element) { @@ -374,7 +566,7 @@ public class ElementImpl protected SOAPElement addElement(Name name) throws SOAPException { SOAPElement newElement = createElement(name); - addNode(newElement); + addNode(((ElementImpl) newElement).getDomElement()); return newElement; } @@ -411,7 +603,7 @@ public class ElementImpl } protected void addNode(org.w3c.dom.Node newElement) throws SOAPException { - insertBefore(newElement, null); + insertBefore(getSoapDocument().getDomNode(newElement), null); if (getOwnerDocument() instanceof DocumentFragment) return; @@ -431,7 +623,7 @@ public class ElementImpl Node child = getFirstChild(); while (child != null) { if (child instanceof Element) { - return ((Element) child); + return (Element) getSoapDocument().find(child); } child = child.getNextSibling(); } @@ -441,10 +633,12 @@ public class ElementImpl protected SOAPElement findChild(NameImpl name) { Node eachChild = getFirstChild(); while (eachChild != null) { - if (eachChild instanceof SOAPElement) { - SOAPElement eachChildSoap = (SOAPElement) eachChild; - if (eachChildSoap.getElementName().equals(name)) { - return eachChildSoap; + if (eachChild instanceof Element) { + SOAPElement eachChildSoap = (SOAPElement) getSoapDocument().find(eachChild); + if (eachChildSoap != null) { + if (eachChildSoap.getElementName().equals(name)) { + return eachChildSoap; + } } } eachChild = eachChild.getNextSibling(); @@ -474,14 +668,14 @@ public class ElementImpl protected SOAPElement addCDATA(String text) throws SOAPException { org.w3c.dom.Text cdata = - (org.w3c.dom.Text) getOwnerDocument().createCDATASection(text); + getOwnerDocument().createCDATASection(text); addNode(cdata); return this; } protected SOAPElement addText(String text) throws SOAPException { org.w3c.dom.Text textNode = - (org.w3c.dom.Text) getOwnerDocument().createTextNode(text); + getOwnerDocument().createTextNode(text); addNode(textNode); return this; } @@ -684,8 +878,9 @@ public class ElementImpl } protected SOAPElement convertToSoapElement(Element element) { - if (element instanceof SOAPElement) { - return (SOAPElement) element; + final Node soapNode = getSoapDocument().findIfPresent(element); + if (soapNode instanceof SOAPElement) { + return (SOAPElement) soapNode; } else { return replaceElementWithSOAPElement( element, @@ -693,7 +888,7 @@ public class ElementImpl } } - protected static SOAPElement replaceElementWithSOAPElement( + protected SOAPElement replaceElementWithSOAPElement( Element element, ElementImpl copy) { @@ -709,7 +904,7 @@ public class ElementImpl copy.insertBefore(nextChild, null); } - Node parent = element.getParentNode(); + Node parent = getSoapDocument().find(element.getParentNode()); if (parent != null) { parent.replaceChild(copy, element); } // XXX else throw an exception? @@ -727,8 +922,8 @@ public class ElementImpl if (next == null) { while (eachNode.hasNext()) { Node node = eachNode.next(); - if (node instanceof SOAPElement) { - next = node; + if (node instanceof Element) { + next = getSoapDocument().findIfPresent(node); break; } } @@ -899,14 +1094,14 @@ public class ElementImpl protected javax.xml.soap.Node getValueNode() { Iterator i = getChildElements(); while (i.hasNext()) { - javax.xml.soap.Node n = (javax.xml.soap.Node) i.next(); + Node n = i.next(); if (n.getNodeType() == org.w3c.dom.Node.TEXT_NODE || n.getNodeType() == org.w3c.dom.Node.CDATA_SECTION_NODE) { // TODO: Hack to fix text node split into multiple lines. normalize(); // Should remove the normalization step when this gets fixed in // DOM/Xerces. - return (javax.xml.soap.Node) n; + return getSoapDocument().find(n); } } return null; @@ -948,7 +1143,7 @@ public class ElementImpl if (parentNode instanceof SOAPDocument) { return null; } - return (SOAPElement) parentNode; + return (SOAPElement) getSoapDocument().find(parentNode); } protected String getSOAPNamespace() { @@ -975,7 +1170,7 @@ public class ElementImpl public void detachNode() { Node parent = getParentNode(); if (parent != null) { - parent.removeChild(this); + parent.removeChild(element); } encodingStyleAttribute.clearNameAndValue(); // Fix for CR: 6474641 @@ -1136,17 +1331,18 @@ public class ElementImpl return attribute == null ? null : attribute.getValue(); } - protected static Iterator getChildElementsFrom(final Element element) { + protected Iterator getChildElementsFrom(final Element element) { return new Iterator() { Node next = element.getFirstChild(); Node nextNext = null; Node last = null; + Node soapElement = getSoapDocument().findIfPresent(element); public boolean hasNext() { if (next != null) { return true; } - if (next == null && nextNext != null) { + if (nextNext != null) { next = nextNext; } @@ -1158,15 +1354,15 @@ public class ElementImpl last = next; next = null; - if ((element instanceof ElementImpl) - && (last instanceof Element)) { + if ((soapElement instanceof ElementImpl) + && (last instanceof Element)) { last = - ((ElementImpl) element).convertToSoapElement( - (Element) last); + ((ElementImpl) soapElement).convertToSoapElement( + (Element) last); } nextNext = last.getNextSibling(); - return last; + return getSoapDocument().findIfPresent(last); } throw new NoSuchElementException(); } @@ -1251,7 +1447,7 @@ public class ElementImpl // SOAPConstants.URI_NS_SOAP_1_2_ENVELOPE.equals(value))) // return; - super.setAttributeNS(namespaceURI,qualifiedName,value); + element.setAttributeNS(namespaceURI,qualifiedName,value); //String tmpLocalName = this.getLocalName(); String tmpURI = this.getNamespaceURI(); boolean isIDNS = false; @@ -1270,4 +1466,116 @@ public class ElementImpl } + @Override + public void removeAttributeNS(String namespaceURI, String localName) throws DOMException { + element.removeAttributeNS(namespaceURI, localName); + } + + @Override + public Attr getAttributeNodeNS(String namespaceURI, String localName) throws DOMException { + return element.getAttributeNodeNS(namespaceURI, localName); + } + + @Override + public Attr setAttributeNodeNS(Attr newAttr) throws DOMException { + return element.setAttributeNodeNS(newAttr); + } + + @Override + public NodeList getElementsByTagNameNS(String namespaceURI, String localName) throws DOMException { + return new NodeListImpl(getSoapDocument(), element.getElementsByTagNameNS(namespaceURI, localName)); + } + + @Override + public boolean hasAttribute(String name) { + return element.hasAttribute(name); + } + + @Override + public boolean hasAttributeNS(String namespaceURI, String localName) throws DOMException { + return element.hasAttributeNS(namespaceURI, localName); + } + + @Override + public TypeInfo getSchemaTypeInfo() { + return element.getSchemaTypeInfo(); + } + + @Override + public void setIdAttribute(String name, boolean isId) throws DOMException { + element.setIdAttribute(name, isId); + } + + @Override + public void setIdAttributeNS(String namespaceURI, String localName, boolean isId) throws DOMException { + element.setIdAttributeNS(namespaceURI, localName, isId); + } + + @Override + public void setIdAttributeNode(Attr idAttr, boolean isId) throws DOMException { + element.setIdAttributeNode(idAttr, isId); + } + + @Override + public String getNodeName() { + return element.getNodeName(); + } + + @Override + public String getNodeValue() throws DOMException { + return element.getNodeValue(); + } + + @Override + public void setNodeValue(String nodeValue) throws DOMException { + element.setNodeValue(nodeValue); + } + + @Override + public short getNodeType() { + return element.getNodeType(); + } + + @Override + public Node getParentNode() { + return getSoapDocument().find(element.getParentNode()); + } + + @Override + public NodeList getChildNodes() { + return new NodeListImpl(getSoapDocument(), element.getChildNodes()); + } + + @Override + public Node getFirstChild() { + return getSoapDocument().findIfPresent(element.getFirstChild()); + } + + @Override + public Node getLastChild() { + return getSoapDocument().findIfPresent(element.getLastChild()); + } + + @Override + public Node getPreviousSibling() { + return getSoapDocument().findIfPresent(element.getPreviousSibling()); + } + + @Override + public Node getNextSibling() { + return getSoapDocument().findIfPresent(element.getNextSibling()); + } + + @Override + public NamedNodeMap getAttributes() { + return element.getAttributes(); + } + + public Element getDomElement() { + return element; + } + + public SOAPDocumentImpl getSoapDocument() { + return soapDocument; + } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/EnvelopeImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/EnvelopeImpl.java index d73ba5b0cea..faaa3d8f61a 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/EnvelopeImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/EnvelopeImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -52,6 +52,7 @@ import com.sun.xml.internal.messaging.saaj.util.transform.EfficientStreamingTran import com.sun.xml.internal.org.jvnet.staxex.util.DOMStreamReader; import com.sun.xml.internal.org.jvnet.staxex.util.XMLStreamReaderToXMLStreamWriter; +import org.w3c.dom.Element; /** * Our implementation of the SOAP envelope. @@ -92,6 +93,10 @@ public abstract class EnvelopeImpl extends ElementImpl implements LazyEnvelope { addBody(); } + public EnvelopeImpl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected abstract NameImpl getHeaderName(String prefix); protected abstract NameImpl getBodyName(String prefix); @@ -122,7 +127,7 @@ public abstract class EnvelopeImpl extends ElementImpl implements LazyEnvelope { } header = (HeaderImpl) createElement(headerName); - insertBefore(header, firstChild); + insertBefore(header.getDomElement(), firstChild); header.ensureNamespaceIsDeclared(headerName.getPrefix(), headerName.getURI()); return header; @@ -161,7 +166,7 @@ public abstract class EnvelopeImpl extends ElementImpl implements LazyEnvelope { if (body == null) { NameImpl bodyName = getBodyName(prefix); body = (BodyImpl) createElement(bodyName); - insertBefore(body, null); + insertBefore(body.getDomElement(), null); body.ensureNamespaceIsDeclared(bodyName.getPrefix(), bodyName.getURI()); } else { log.severe("SAAJ0122.impl.body.already.exists"); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/FaultElementImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/FaultElementImpl.java index 2cf604af0cc..447039ed8e6 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/FaultElementImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/FaultElementImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,6 +34,7 @@ import javax.xml.soap.SOAPFaultElement; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; +import org.w3c.dom.Element; public abstract class FaultElementImpl extends ElementImpl @@ -47,6 +48,10 @@ public abstract class FaultElementImpl super(ownerDoc, qname); } + public FaultElementImpl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected abstract boolean isStandardFaultElement(); public SOAPElement setElementQName(QName newName) throws SOAPException { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/FaultImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/FaultImpl.java index 218ce0a7f5c..86fdfcf3314 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/FaultImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/FaultImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,6 +31,7 @@ import java.util.logging.Level; import javax.xml.namespace.QName; import javax.xml.soap.*; +import com.sun.xml.internal.messaging.saaj.util.SAAJUtil; import org.w3c.dom.Element; import com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl; @@ -53,6 +54,9 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { super(ownerDoc, name); } + public FaultImpl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } protected abstract NameImpl getDetailName(); protected abstract NameImpl getFaultCodeName(); @@ -83,6 +87,7 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { (SOAPFaultElement) findAndConvertChildElement(getFaultStringName()); } + @Override public void setFaultCode(String faultCode) throws SOAPException { setFaultCode( NameImpl.getLocalNameFromTagName(faultCode), @@ -131,6 +136,7 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { } } + @Override public void setFaultCode(Name faultCodeQName) throws SOAPException { setFaultCode( faultCodeQName.getLocalName(), @@ -138,6 +144,7 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { faultCodeQName.getURI()); } + @Override public void setFaultCode(QName faultCodeQName) throws SOAPException { setFaultCode( faultCodeQName.getLocalPart(), @@ -165,6 +172,7 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { detail = (Detail) findAndConvertChildElement(detailName); } + @Override public Detail getDetail() { if (detail == null) initializeDetail(); @@ -175,6 +183,7 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { return detail; } + @Override public Detail addDetail() throws SOAPException { if (detail == null) initializeDetail(); @@ -188,12 +197,15 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { } } + @Override public boolean hasDetail() { return (getDetail() != null); } + @Override public abstract void setFaultActor(String faultActor) throws SOAPException; + @Override public String getFaultActor() { if (this.faultActorElement == null) findFaultActorElement(); @@ -203,6 +215,7 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { return null; } + @Override public SOAPElement setElementQName(QName newName) throws SOAPException { log.log( @@ -213,11 +226,13 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { "Cannot change name for " + elementQName.getLocalPart() + " to " + newName.getLocalPart()); } + @Override protected SOAPElement convertToSoapElement(Element element) { - if (element instanceof SOAPFaultElement) { - return (SOAPElement) element; - } else if (element instanceof SOAPElement) { - SOAPElement soapElement = (SOAPElement) element; + final org.w3c.dom.Node soapNode = getSoapDocument().findIfPresent(element); + if (soapNode instanceof SOAPFaultElement) { + return (SOAPElement) soapNode; + } else if (soapNode instanceof SOAPElement) { + SOAPElement soapElement = (SOAPElement) soapNode; if (getDetailName().equals(soapElement.getElementName())) { return replaceElementWithSOAPElement(element, createDetail()); } else { @@ -233,12 +248,12 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { Name elementName = NameImpl.copyElementName(element); ElementImpl newElement; if (getDetailName().equals(elementName)) { - newElement = (ElementImpl) createDetail(); + newElement = createDetail(); } else { String localName = elementName.getLocalName(); if (isStandardFaultElement(localName)) newElement = - (ElementImpl) createSOAPFaultElement(elementName); + createSOAPFaultElement(elementName); else newElement = (ElementImpl) createElement(elementName); } @@ -284,6 +299,7 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { } } + @Override protected SOAPElement addElement(Name name) throws SOAPException { if (getDetailName().equals(name)) { return addDetail(); @@ -297,6 +313,7 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { return super.addElement(name); } + @Override protected SOAPElement addElement(QName name) throws SOAPException { return addElement(NameImpl.convertToName(name)); } @@ -311,6 +328,8 @@ public abstract class FaultImpl extends ElementImpl implements SOAPFault { /** * Convert an xml:lang attribute value into a Locale object + * @param xmlLang xml:lang attribute value + * @return Locale */ protected static Locale xmlLangToLocale(String xmlLang) { if (xmlLang == null) { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/HeaderImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/HeaderImpl.java index a9e4adb086d..0d9f7ad8ae4 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/HeaderImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/HeaderImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,6 +31,7 @@ import java.util.logging.Level; import javax.xml.namespace.QName; import javax.xml.soap.*; +import com.sun.xml.internal.messaging.saaj.util.SAAJUtil; import org.w3c.dom.Element; import com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl; @@ -45,6 +46,10 @@ public abstract class HeaderImpl extends ElementImpl implements SOAPHeader { super(ownerDoc, name); } + public HeaderImpl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected abstract SOAPHeaderElement createHeaderElement(Name name) throws SOAPException; protected abstract SOAPHeaderElement createHeaderElement(QName name) @@ -276,8 +281,9 @@ public abstract class HeaderImpl extends ElementImpl implements SOAPHeader { } protected SOAPElement convertToSoapElement(Element element) { - if (element instanceof SOAPHeaderElement) { - return (SOAPElement) element; + final org.w3c.dom.Node soapNode = getSoapDocument().findIfPresent(element); + if (soapNode instanceof SOAPHeaderElement) { + return (SOAPElement) soapNode; } else { SOAPHeaderElement headerElement; try { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/NodeListImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/NodeListImpl.java new file mode 100644 index 00000000000..141265ac20f --- /dev/null +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/NodeListImpl.java @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package com.sun.xml.internal.messaging.saaj.soap.impl; + +import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; + +import java.util.Objects; + +/** + * Node list wrapper, finding SOAP elements automatically when possible. + * + * @author Roman Grigoriadi + */ +public class NodeListImpl implements NodeList { + + private final SOAPDocumentImpl soapDocument; + + private final NodeList nodeList; + + public NodeListImpl(SOAPDocumentImpl soapDocument, NodeList nodeList) { + Objects.requireNonNull(soapDocument); + Objects.requireNonNull(soapDocument); + this.soapDocument = soapDocument; + this.nodeList = nodeList; + } + + @Override + public Node item(int index) { + return soapDocument.findIfPresent(nodeList.item(index)); + } + + @Override + public int getLength() { + return nodeList.getLength(); + } +} diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/SOAPCommentImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/SOAPCommentImpl.java index c306beb74f9..85fbb14aacd 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/SOAPCommentImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/SOAPCommentImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,14 +31,20 @@ import java.util.logging.Logger; import javax.xml.soap.SOAPElement; import javax.xml.soap.SOAPException; +import com.sun.xml.internal.messaging.saaj.util.SAAJUtil; +import org.w3c.dom.Comment; import org.w3c.dom.DOMException; +import org.w3c.dom.Document; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; import org.w3c.dom.Text; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; +import org.w3c.dom.UserDataHandler; public class SOAPCommentImpl - extends com.sun.org.apache.xerces.internal.dom.CommentImpl implements javax.xml.soap.Text, org.w3c.dom.Comment { protected static final Logger log = @@ -47,8 +53,236 @@ public class SOAPCommentImpl protected static ResourceBundle rb = log.getResourceBundle(); + @Override + public String getData() throws DOMException { + return comment.getData(); + } + + @Override + public void setData(String data) throws DOMException { + comment.setData(data); + } + + @Override + public int getLength() { + return comment.getLength(); + } + + @Override + public String substringData(int offset, int count) throws DOMException { + return comment.substringData(offset, count); + } + + @Override + public void appendData(String arg) throws DOMException { + comment.appendData(arg); + } + + @Override + public void insertData(int offset, String arg) throws DOMException { + comment.insertData(offset, arg); + } + + @Override + public void deleteData(int offset, int count) throws DOMException { + comment.deleteData(offset, count); + } + + @Override + public void replaceData(int offset, int count, String arg) throws DOMException { + comment.replaceData(offset, count, arg); + } + + @Override + public String getNodeName() { + return comment.getNodeName(); + } + + @Override + public String getNodeValue() throws DOMException { + return comment.getNodeValue(); + } + + @Override + public void setNodeValue(String nodeValue) throws DOMException { + comment.setNodeValue(nodeValue); + } + + @Override + public short getNodeType() { + return comment.getNodeType(); + } + + @Override + public Node getParentNode() { + return comment.getParentNode(); + } + + @Override + public NodeList getChildNodes() { + return comment.getChildNodes(); + } + + @Override + public Node getFirstChild() { + return comment.getFirstChild(); + } + + @Override + public Node getLastChild() { + return comment.getLastChild(); + } + + @Override + public Node getPreviousSibling() { + return comment.getPreviousSibling(); + } + + @Override + public Node getNextSibling() { + return comment.getNextSibling(); + } + + @Override + public NamedNodeMap getAttributes() { + return comment.getAttributes(); + } + + @Override + public Document getOwnerDocument() { + return comment.getOwnerDocument(); + } + + @Override + public Node insertBefore(Node newChild, Node refChild) throws DOMException { + return comment.insertBefore(newChild, refChild); + } + + @Override + public Node replaceChild(Node newChild, Node oldChild) throws DOMException { + return comment.replaceChild(newChild, oldChild); + } + + @Override + public Node removeChild(Node oldChild) throws DOMException { + return comment.removeChild(oldChild); + } + + @Override + public Node appendChild(Node newChild) throws DOMException { + return comment.appendChild(newChild); + } + + @Override + public boolean hasChildNodes() { + return comment.hasChildNodes(); + } + + @Override + public Node cloneNode(boolean deep) { + return comment.cloneNode(deep); + } + + @Override + public void normalize() { + comment.normalize(); + } + + @Override + public boolean isSupported(String feature, String version) { + return comment.isSupported(feature, version); + } + + @Override + public String getNamespaceURI() { + return comment.getNamespaceURI(); + } + + @Override + public String getPrefix() { + return comment.getPrefix(); + } + + @Override + public void setPrefix(String prefix) throws DOMException { + comment.setPrefix(prefix); + } + + @Override + public String getLocalName() { + return comment.getLocalName(); + } + + @Override + public boolean hasAttributes() { + return comment.hasAttributes(); + } + + @Override + public String getBaseURI() { + return comment.getBaseURI(); + } + + @Override + public short compareDocumentPosition(Node other) throws DOMException { + return comment.compareDocumentPosition(other); + } + + @Override + public String getTextContent() throws DOMException { + return comment.getTextContent(); + } + + @Override + public void setTextContent(String textContent) throws DOMException { + comment.setTextContent(textContent); + } + + @Override + public boolean isSameNode(Node other) { + return comment.isSameNode(other); + } + + @Override + public String lookupPrefix(String namespaceURI) { + return comment.lookupPrefix(namespaceURI); + } + + @Override + public boolean isDefaultNamespace(String namespaceURI) { + return comment.isDefaultNamespace(namespaceURI); + } + + @Override + public String lookupNamespaceURI(String prefix) { + return comment.lookupNamespaceURI(prefix); + } + + @Override + public boolean isEqualNode(Node arg) { + return comment.isEqualNode(arg); + } + + @Override + public Object getFeature(String feature, String version) { + return comment.getFeature(feature, version); + } + + @Override + public Object setUserData(String key, Object data, UserDataHandler handler) { + return comment.setUserData(key, data, handler); + } + + @Override + public Object getUserData(String key) { + return comment.getUserData(key); + } + + private Comment comment; + public SOAPCommentImpl(SOAPDocumentImpl ownerDoc, String text) { - super(ownerDoc, text); + comment = ownerDoc.getDomDocument().createComment(text); + ownerDoc.register(this); } public String getValue() { @@ -111,4 +345,7 @@ public class SOAPCommentImpl throw new UnsupportedOperationException("Not Supported"); } + public Comment getDomElement() { + return comment; + } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/SOAPTextImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/SOAPTextImpl.java index c088928ba90..076cacb202d 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/SOAPTextImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/SOAPTextImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,17 +32,271 @@ import javax.xml.soap.SOAPException; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; +import org.w3c.dom.DOMException; +import org.w3c.dom.Document; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; +import org.w3c.dom.Text; +import org.w3c.dom.UserDataHandler; public class SOAPTextImpl - extends com.sun.org.apache.xerces.internal.dom.TextImpl implements javax.xml.soap.Text, org.w3c.dom.Text { + @Override + public Text splitText(int offset) throws DOMException { + return textNode.splitText(offset); + } + + @Override + public boolean isElementContentWhitespace() { + return textNode.isElementContentWhitespace(); + } + + @Override + public String getWholeText() { + return textNode.getWholeText(); + } + + @Override + public Text replaceWholeText(String content) throws DOMException { + return textNode.replaceWholeText(content); + } + + @Override + public String getData() throws DOMException { + return textNode.getData(); + } + + @Override + public void setData(String data) throws DOMException { + textNode.setData(data); + } + + @Override + public int getLength() { + return textNode.getLength(); + } + + @Override + public String substringData(int offset, int count) throws DOMException { + return textNode.substringData(offset, count); + } + + @Override + public void appendData(String arg) throws DOMException { + textNode.appendData(arg); + } + + @Override + public void insertData(int offset, String arg) throws DOMException { + textNode.insertData(offset, arg); + } + + @Override + public void deleteData(int offset, int count) throws DOMException { + textNode.deleteData(offset, count); + } + + @Override + public void replaceData(int offset, int count, String arg) throws DOMException { + textNode.replaceData(offset, count, arg); + } + + @Override + public String getNodeName() { + return textNode.getNodeName(); + } + + @Override + public String getNodeValue() throws DOMException { + return textNode.getNodeValue(); + } + + @Override + public void setNodeValue(String nodeValue) throws DOMException { + textNode.setNodeValue(nodeValue); + } + + @Override + public short getNodeType() { + return textNode.getNodeType(); + } + + @Override + public Node getParentNode() { + return textNode.getParentNode(); + } + + @Override + public NodeList getChildNodes() { + return textNode.getChildNodes(); + } + + @Override + public Node getFirstChild() { + return textNode.getFirstChild(); + } + + @Override + public Node getLastChild() { + return textNode.getLastChild(); + } + + @Override + public Node getPreviousSibling() { + return textNode.getPreviousSibling(); + } + + @Override + public Node getNextSibling() { + return textNode.getNextSibling(); + } + + @Override + public NamedNodeMap getAttributes() { + return textNode.getAttributes(); + } + + @Override + public Document getOwnerDocument() { + return textNode.getOwnerDocument(); + } + + @Override + public Node insertBefore(Node newChild, Node refChild) throws DOMException { + return textNode.insertBefore(newChild, refChild); + } + + @Override + public Node replaceChild(Node newChild, Node oldChild) throws DOMException { + return textNode.replaceChild(newChild, oldChild); + } + + @Override + public Node removeChild(Node oldChild) throws DOMException { + return textNode.removeChild(oldChild); + } + + @Override + public Node appendChild(Node newChild) throws DOMException { + return textNode.appendChild(newChild); + } + + @Override + public boolean hasChildNodes() { + return textNode.hasChildNodes(); + } + + @Override + public Node cloneNode(boolean deep) { + return textNode.cloneNode(deep); + } + + @Override + public void normalize() { + textNode.normalize(); + } + + @Override + public boolean isSupported(String feature, String version) { + return textNode.isSupported(feature, version); + } + + @Override + public String getNamespaceURI() { + return textNode.getNamespaceURI(); + } + + @Override + public String getPrefix() { + return textNode.getPrefix(); + } + + @Override + public void setPrefix(String prefix) throws DOMException { + textNode.setPrefix(prefix); + } + + @Override + public String getLocalName() { + return textNode.getLocalName(); + } + + @Override + public boolean hasAttributes() { + return textNode.hasAttributes(); + } + + @Override + public String getBaseURI() { + return textNode.getBaseURI(); + } + + @Override + public short compareDocumentPosition(Node other) throws DOMException { + return textNode.compareDocumentPosition(other); + } + + @Override + public String getTextContent() throws DOMException { + return textNode.getTextContent(); + } + + @Override + public void setTextContent(String textContent) throws DOMException { + textNode.setTextContent(textContent); + } + + @Override + public boolean isSameNode(Node other) { + return textNode.isSameNode(other); + } + + @Override + public String lookupPrefix(String namespaceURI) { + return textNode.lookupPrefix(namespaceURI); + } + + @Override + public boolean isDefaultNamespace(String namespaceURI) { + return textNode.isDefaultNamespace(namespaceURI); + } + + @Override + public String lookupNamespaceURI(String prefix) { + return textNode.lookupNamespaceURI(prefix); + } + + @Override + public boolean isEqualNode(Node arg) { + return textNode.isEqualNode(arg); + } + + @Override + public Object getFeature(String feature, String version) { + return textNode.getFeature(feature, version); + } + + @Override + public Object setUserData(String key, Object data, UserDataHandler handler) { + return textNode.setUserData(key, data, handler); + } + + @Override + public Object getUserData(String key) { + return textNode.getUserData(key); + } + protected static final Logger log = Logger.getLogger(LogDomainConstants.SOAP_IMPL_DOMAIN, "com.sun.xml.internal.messaging.saaj.soap.impl.LocalStrings"); + private Text textNode; + public SOAPTextImpl(SOAPDocumentImpl ownerDoc, String text) { - super(ownerDoc, text); + textNode = ownerDoc.getDomDocument().createTextNode(text); + ownerDoc.register(this); } public String getValue() { @@ -70,7 +324,7 @@ public class SOAPTextImpl public void detachNode() { org.w3c.dom.Node parent = getParentNode(); if (parent != null) { - parent.removeChild(this); + parent.removeChild(getDomElement()); } } @@ -88,4 +342,8 @@ public class SOAPTextImpl } return txt.startsWith(""); } + + public Text getDomElement() { + return textNode; + } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/name/NameImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/name/NameImpl.java index 52399329148..86af99025eb 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/name/NameImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/name/NameImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -218,6 +218,7 @@ public class NameImpl implements Name { return prefix + ":" + localName; } + @Override public boolean equals(Object obj) { if (!(obj instanceof Name)) { return false; @@ -236,6 +237,7 @@ public class NameImpl implements Name { return true; } + @Override public int hashCode() { return localName.hashCode(); } @@ -245,6 +247,7 @@ public class NameImpl implements Name { * * @return a string for the local name. */ + @Override public String getLocalName() { return localName; } @@ -256,6 +259,7 @@ public class NameImpl implements Name { * * @return the prefix as a string. */ + @Override public String getPrefix() { return prefix; } @@ -265,6 +269,7 @@ public class NameImpl implements Name { * * @return the uri as a string. */ + @Override public String getURI() { return uri; } @@ -272,6 +277,7 @@ public class NameImpl implements Name { /** * Returns a String version of the name suitable for use in an XML document. */ + @Override public String getQualifiedName() { if (qualifiedName == null) { if (prefix != null && prefix.length() > 0) { @@ -285,6 +291,9 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.1 Envelope. + * + * @param prefix prefix + * @return Envelope Name */ public static NameImpl createEnvelope1_1Name(String prefix) { return new Envelope1_1Name(prefix); @@ -292,6 +301,9 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.2 Envelope. + * + * @param prefix prefix + * @return Envelope Name */ public static NameImpl createEnvelope1_2Name(String prefix) { return new Envelope1_2Name(prefix); @@ -299,6 +311,9 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.1 Header. + * + * @param prefix prefix + * @return Header Name */ public static NameImpl createHeader1_1Name(String prefix) { return new Header1_1Name(prefix); @@ -306,6 +321,9 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.2 Header. + * + * @param prefix prefix + * @return Header Name */ public static NameImpl createHeader1_2Name(String prefix) { return new Header1_2Name(prefix); @@ -313,6 +331,9 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.1 Body. + * + * @param prefix prefix + * @return Body Name */ public static NameImpl createBody1_1Name(String prefix) { return new Body1_1Name(prefix); @@ -320,6 +341,9 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.2 Body. + * + * @param prefix prefix + * @return Body Name */ public static NameImpl createBody1_2Name(String prefix) { return new Body1_2Name(prefix); @@ -327,20 +351,29 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.1 Fault. + * + * @param prefix prefix + * @return Fault Name */ public static NameImpl createFault1_1Name(String prefix) { return new Fault1_1Name(prefix); } /** - * Create a name object for a SOAP1.2 NotUnderstood element. - */ + * Create a name object for a SOAP1.2 NotUnderstood element. + * + * @param prefix prefix + * @return NotUnderstood Name + */ public static NameImpl createNotUnderstood1_2Name(String prefix) { return new NotUnderstood1_2Name(prefix); } /** * Create a name object for a SOAP1.2 Upgrade element. + * + * @param prefix prefix + * @return Upgrade Name */ public static NameImpl createUpgrade1_2Name(String prefix) { return new Upgrade1_2Name(prefix); @@ -348,6 +381,9 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.2 SupportedEnvelope Upgrade element. + * + * @param prefix prefix + * @return Supported Envelope Name */ public static NameImpl createSupportedEnvelope1_2Name(String prefix) { return new SupportedEnvelope1_2Name(prefix); @@ -358,6 +394,8 @@ public class NameImpl implements Name { * Fault, Reason or Detail. * * @param localName Local Name of element + * @param prefix prefix + * @return Fault Name */ public static NameImpl createFault1_2Name( String localName, @@ -369,6 +407,8 @@ public class NameImpl implements Name { * Create a name object for a SOAP1.2 Fault/Code or Subcode. * * @param localName Either "Code" or "Subcode" + * @param prefix prefix + * @return CodeSubcode Name */ public static NameImpl createCodeSubcode1_2Name( String prefix, @@ -378,6 +418,8 @@ public class NameImpl implements Name { /** * Create a name object for a SOAP1.1 Fault Detail. + * + * @return Detail Name */ public static NameImpl createDetail1_1Name() { return new Detail1_1Name(); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Body1_1Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Body1_1Impl.java index 12fb6d02a4e..453abec8d51 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Body1_1Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Body1_1Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -38,12 +38,17 @@ import com.sun.xml.internal.messaging.saaj.soap.SOAPDocument; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.BodyImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; +import org.w3c.dom.Element; public class Body1_1Impl extends BodyImpl { public Body1_1Impl(SOAPDocumentImpl ownerDocument, String prefix) { super(ownerDocument, NameImpl.createBody1_1Name(prefix)); } + public Body1_1Impl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + public SOAPFault addSOAP12Fault(QName faultCode, String faultReason, Locale locale) { // log message here throw new UnsupportedOperationException("Not supported in SOAP 1.1"); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Detail1_1Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Detail1_1Impl.java index 480ca25f8d2..acd4612488f 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Detail1_1Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Detail1_1Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,6 +36,7 @@ import javax.xml.soap.Name; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.DetailImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; +import org.w3c.dom.Element; public class Detail1_1Impl extends DetailImpl { @@ -45,6 +46,11 @@ public class Detail1_1Impl extends DetailImpl { public Detail1_1Impl(SOAPDocumentImpl ownerDoc) { super(ownerDoc, NameImpl.createDetail1_1Name()); } + + public Detail1_1Impl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected DetailEntry createDetailEntry(Name name) { return new DetailEntry1_1Impl( (SOAPDocumentImpl) getOwnerDocument(), diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Envelope1_1Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Envelope1_1Impl.java index c517fab54f2..de55d8fa86c 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Envelope1_1Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Envelope1_1Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,6 +34,7 @@ import javax.xml.soap.SOAPException; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.EnvelopeImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; +import org.w3c.dom.Element; public class Envelope1_1Impl extends EnvelopeImpl { @@ -52,6 +53,11 @@ public class Envelope1_1Impl extends EnvelopeImpl { createHeader, createBody); } + + public Envelope1_1Impl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected NameImpl getBodyName(String prefix) { return NameImpl.createBody1_1Name(prefix); } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Fault1_1Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Fault1_1Impl.java index 00b8fb65618..58c00c4823e 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Fault1_1Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Fault1_1Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -46,6 +46,7 @@ import com.sun.xml.internal.messaging.saaj.soap.impl.*; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; import com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl; +import org.w3c.dom.Element; public class Fault1_1Impl extends FaultImpl { @@ -59,6 +60,10 @@ public class Fault1_1Impl extends FaultImpl { super(ownerDocument, NameImpl.createFault1_1Name(prefix)); } + public Fault1_1Impl(Element domElement, SOAPDocumentImpl ownerDoc) { + super(ownerDoc, domElement); + } + protected NameImpl getDetailName() { return NameImpl.createDetail1_1Name(); } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Header1_1Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Header1_1Impl.java index a30911edbda..75b76d513f5 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Header1_1Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_1/Header1_1Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -40,6 +40,7 @@ import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.HeaderImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; +import org.w3c.dom.Element; public class Header1_1Impl extends HeaderImpl { @@ -51,6 +52,10 @@ public class Header1_1Impl extends HeaderImpl { super(ownerDocument, NameImpl.createHeader1_1Name(prefix)); } + public Header1_1Impl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected NameImpl getNotUnderstoodName() { log.log( Level.SEVERE, diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Body1_2Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Body1_2Impl.java index abef584186d..1e57365b01c 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Body1_2Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Body1_2Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,6 +34,7 @@ import java.util.logging.Logger; import javax.xml.namespace.QName; import javax.xml.soap.*; +import org.w3c.dom.Element; import org.w3c.dom.Node; import com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl; @@ -52,6 +53,10 @@ public class Body1_2Impl extends BodyImpl { super(ownerDocument, NameImpl.createBody1_2Name(prefix)); } + public Body1_2Impl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected NameImpl getFaultName(String name) { return NameImpl.createFault1_2Name(name, null); } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Detail1_2Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Detail1_2Impl.java index 32fb78ddfe4..455d6e4ee9d 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Detail1_2Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Detail1_2Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -39,6 +39,7 @@ import com.sun.xml.internal.messaging.saaj.soap.SOAPDocument; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.DetailImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; +import org.w3c.dom.Element; public class Detail1_2Impl extends DetailImpl { @@ -54,6 +55,10 @@ public class Detail1_2Impl extends DetailImpl { super(ownerDocument, NameImpl.createSOAP12Name("Detail")); } + public Detail1_2Impl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected DetailEntry createDetailEntry(Name name) { return new DetailEntry1_2Impl( ((SOAPDocument) getOwnerDocument()).getDocument(), diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Envelope1_2Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Envelope1_2Impl.java index 53840bccead..075a848b91b 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Envelope1_2Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Envelope1_2Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -39,6 +39,7 @@ import com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl; import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.EnvelopeImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; +import org.w3c.dom.Element; public class Envelope1_2Impl extends EnvelopeImpl { @@ -50,6 +51,10 @@ public class Envelope1_2Impl extends EnvelopeImpl { super(ownerDoc, NameImpl.createEnvelope1_2Name(prefix)); } + public Envelope1_2Impl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + public Envelope1_2Impl( SOAPDocumentImpl ownerDoc, String prefix, diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Fault1_2Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Fault1_2Impl.java index 6d655f1ee12..3f206c13031 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Fault1_2Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Fault1_2Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,6 +42,7 @@ import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.*; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; +import org.w3c.dom.Element; public class Fault1_2Impl extends FaultImpl { @@ -68,6 +69,10 @@ public class Fault1_2Impl extends FaultImpl { super(ownerDocument, NameImpl.createFault1_2Name(null, prefix)); } + public Fault1_2Impl(Element domElement, SOAPDocumentImpl ownerDoc) { + super(ownerDoc, domElement); + } + protected NameImpl getDetailName() { return NameImpl.createSOAP12Name("Detail", getPrefix()); } @@ -521,7 +526,7 @@ public class Fault1_2Impl extends FaultImpl { } } if (element instanceof Detail1_2Impl) { - ElementImpl importedElement = (ElementImpl) importElement(element); + Element importedElement = importElement(element); addNode(importedElement); return convertToSoapElement(importedElement); } else diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Header1_2Impl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Header1_2Impl.java index e860c511885..ee9eeaac427 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Header1_2Impl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/ver1_2/Header1_2Impl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -41,6 +41,7 @@ import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; import com.sun.xml.internal.messaging.saaj.soap.impl.HeaderImpl; import com.sun.xml.internal.messaging.saaj.soap.name.NameImpl; import com.sun.xml.internal.messaging.saaj.util.LogDomainConstants; +import org.w3c.dom.Element; public class Header1_2Impl extends HeaderImpl { @@ -54,6 +55,10 @@ public class Header1_2Impl extends HeaderImpl { super(ownerDocument, NameImpl.createHeader1_2Name(prefix)); } + public Header1_2Impl(SOAPDocumentImpl ownerDoc, Element domElement) { + super(ownerDoc, domElement); + } + protected NameImpl getNotUnderstoodName() { return NameImpl.createNotUnderstood1_2Name(null); } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/Base64.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/Base64.java index 30243489e5c..6e8aa0bd5f5 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/Base64.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/Base64.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,7 +37,6 @@ package com.sun.xml.internal.messaging.saaj.util; * This class is used by XML Schema binary format validation * * @author Jeffrey Rodriguez - * @version */ public final class Base64 { @@ -173,7 +172,7 @@ public final class Base64 { /** * Decodes Base64 data into octects * - * @param binaryData Byte array containing Base64 data + * @param base64Data Byte array containing Base64 data * @return Array containind decoded data. */ public byte[] decode( byte[] base64Data ) { diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ByteOutputStream.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ByteOutputStream.java index c00da8308f6..5763bd78396 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ByteOutputStream.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ByteOutputStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,6 +42,7 @@ import java.io.ByteArrayInputStream; *

  • doesn't do synchronization *
  • allows access to the raw buffer *
  • almost no parameter check + * */ public final class ByteOutputStream extends OutputStream { /** @@ -64,6 +65,9 @@ public final class ByteOutputStream extends OutputStream { /** * Copies all the bytes from this input into this buffer. + * + * @param in input stream. + * @exception IOException in case of an I/O error. */ public void write(InputStream in) throws IOException { if (in instanceof ByteArrayInputStream) { @@ -84,6 +88,7 @@ public final class ByteOutputStream extends OutputStream { } } + @Override public void write(int b) { ensureCapacity(1); buf[count] = (byte) b; @@ -102,18 +107,22 @@ public final class ByteOutputStream extends OutputStream { } } + @Override public void write(byte[] b, int off, int len) { ensureCapacity(len); System.arraycopy(b, off, buf, count, len); count += len; } + @Override public void write(byte[] b) { write(b, 0, b.length); } /** * Writes a string as ASCII string. + * + * @param s string to write. */ public void writeAsAscii(String s) { int len = s.length(); @@ -138,9 +147,12 @@ public final class ByteOutputStream extends OutputStream { * Evil buffer reallocation method. * Don't use it unless you absolutely have to. * + * @return byte array + * * @deprecated * because this is evil! */ + @Deprecated public byte toByteArray()[] { byte[] newbuf = new byte[count]; System.arraycopy(buf, 0, newbuf, 0, count); @@ -162,10 +174,12 @@ public final class ByteOutputStream extends OutputStream { * @return String translated from the buffer's contents. * @since JDK1.1 */ + @Override public String toString() { return new String(buf, 0, count); } + @Override public void close() { } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/JaxmURI.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/JaxmURI.java index 4d9178876b2..131f1f5e5c1 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/JaxmURI.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/JaxmURI.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -39,8 +39,9 @@ import java.io.Serializable; * string and fragment) that may constitute a URI. *

    * Parsing of a URI specification is done according to the URI -* syntax described in RFC 2396. -* Every URI consists of a scheme, followed by a colon (':'), followed by a scheme-specific +* syntax described in +* RFC 2396. Every URI consists +* of a scheme, followed by a colon (':'), followed by a scheme-specific * part. For URIs that follow the "generic URI" syntax, the scheme- * specific part begins with two slashes ("//") and may be followed * by an authority segment (comprised of user information, host, and @@ -60,8 +61,6 @@ import java.io.Serializable; * default port for a specific scheme). Rather, it only knows the * grammar and basic set of operations that can be applied to a URI. * -* @version -* **********************************************************************/ public class JaxmURI implements Serializable { @@ -1106,6 +1105,7 @@ import java.io.Serializable; * @return true if p_test is a URI with all values equal to this * URI, false otherwise */ + @Override public boolean equals(Object p_test) { if (p_test instanceof JaxmURI) { JaxmURI testURI = (JaxmURI) p_test; @@ -1134,6 +1134,7 @@ import java.io.Serializable; return false; } + @Override public int hashCode() { // No members safe to use, just default to a constant. return 153214; @@ -1144,6 +1145,7 @@ import java.io.Serializable; * * @return the URI string specification */ + @Override public String toString() { StringBuilder uriSpecString = new StringBuilder(); @@ -1173,6 +1175,8 @@ import java.io.Serializable; * A scheme is conformant if it starts with an alphanumeric, and * contains only alphanumerics, '+','-' and '.'. * + * @param p_scheme scheme name + * * @return true if the scheme is conformant, false otherwise */ public static boolean isConformantSchemeName(String p_scheme) { @@ -1202,7 +1206,9 @@ import java.io.Serializable; * IPv4 address consists of four decimal digit groups separated by a * '.'. A hostname consists of domain labels (each of which must * begin and end with an alphanumeric but may contain '-') separated - & by a '.'. See RFC 2396 Section 3.2.2. + * by a '.'. See RFC 2396 Section 3.2.2. + * + * @param p_address address * * @return true if the string is a syntactically valid IPv4 address * or hostname diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ParseUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ParseUtil.java index 5d3c2d4e0db..032abd18430 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ParseUtil.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ParseUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -40,6 +40,10 @@ public class ParseUtil { * Returns a new String constructed from the specified String by replacing * the URL escape sequences and UTF8 encoding with the characters they * represent. + * + * @param s string + * + * @return decoded string */ public static String decode(String s) { StringBuilder sb = new StringBuilder(); diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ParserPool.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ParserPool.java index b9c503c9f7f..9cfa57e00ee 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ParserPool.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/ParserPool.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -45,8 +45,11 @@ public class ParserPool { public ParserPool(int capacity) { queue = new ArrayBlockingQueue(capacity); - //factory = SAXParserFactory.newInstance(); - factory = new com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl(); + factory = SAXParserFactory.newInstance("com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl", SAAJUtil.getSystemClassLoader()); + try { + factory.setFeature("jdk.xml.resetSymbolTable", true); + } catch(SAXException | ParserConfigurationException e) { + } factory.setNamespaceAware(true); for (int i = 0; i < capacity; i++) { try { @@ -79,30 +82,7 @@ public class ParserPool { public void returnParser(SAXParser saxParser) { saxParser.reset(); - resetSaxParser(saxParser); put(saxParser); } - - /** - * SAAJ Issue 46 :https://saaj.dev.java.net/issues/show_bug.cgi?id=46 - * Xerces does not provide a way to reset the SymbolTable - * So we are trying to reset it using the proprietary code below. - * Temporary Until the bug : https://jaxp.dev.java.net/issues/show_bug.cgi?id=59 - * is fixed. - * @param parser the parser from the pool whose Symbol Table needs to be reset. - */ - private void resetSaxParser(SAXParser parser) { - try { - //Object obj = parser.getProperty("http://apache.org/xml/properties/internal/symbol-table"); - com.sun.org.apache.xerces.internal.util.SymbolTable table = new com.sun.org.apache.xerces.internal.util.SymbolTable(); - parser.setProperty("http://apache.org/xml/properties/internal/symbol-table", table); - //obj = parser.getProperty("http://apache.org/xml/properties/internal/symbol-table"); - } catch (SAXNotRecognizedException ex) { - //nothing to do - } catch (SAXNotSupportedException ex) { - //nothing to do - } - } - } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/SAAJUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/SAAJUtil.java index 7f9cdc40a98..eafc1863f80 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/SAAJUtil.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/SAAJUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,8 @@ package com.sun.xml.internal.messaging.saaj.util; import java.security.AccessControlException; +import java.security.AccessController; +import java.security.PrivilegedAction; /** * @@ -48,4 +50,13 @@ public final class SAAJUtil { return null; } } + + public static ClassLoader getSystemClassLoader() { + return AccessController.doPrivileged(new PrivilegedAction() { + @Override + public ClassLoader run() { + return ClassLoader.getSystemClassLoader(); + } + }); + } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/transform/EfficientStreamingTransformer.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/transform/EfficientStreamingTransformer.java index e11fb63f15d..94f4f3d67cf 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/transform/EfficientStreamingTransformer.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/util/transform/EfficientStreamingTransformer.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -107,11 +107,13 @@ public class EfficientStreamingTransformer } } + @Override public void clearParameters() { if (m_realTransformer != null) m_realTransformer.clearParameters(); } + @Override public javax.xml.transform.ErrorListener getErrorListener() { try { materialize(); @@ -122,6 +124,7 @@ public class EfficientStreamingTransformer return null; } + @Override public java.util.Properties getOutputProperties() { try { materialize(); @@ -132,6 +135,7 @@ public class EfficientStreamingTransformer return null; } + @Override public String getOutputProperty(String str) throws java.lang.IllegalArgumentException { try { @@ -143,6 +147,7 @@ public class EfficientStreamingTransformer return null; } + @Override public Object getParameter(String str) { try { materialize(); @@ -153,6 +158,7 @@ public class EfficientStreamingTransformer return null; } + @Override public javax.xml.transform.URIResolver getURIResolver() { try { materialize(); @@ -163,6 +169,7 @@ public class EfficientStreamingTransformer return null; } + @Override public void setErrorListener( javax.xml.transform.ErrorListener errorListener) throws java.lang.IllegalArgumentException { @@ -174,6 +181,7 @@ public class EfficientStreamingTransformer } } + @Override public void setOutputProperties(java.util.Properties properties) throws java.lang.IllegalArgumentException { try { @@ -184,6 +192,7 @@ public class EfficientStreamingTransformer } } + @Override public void setOutputProperty(String str, String str1) throws java.lang.IllegalArgumentException { try { @@ -194,6 +203,7 @@ public class EfficientStreamingTransformer } } + @Override public void setParameter(String str, Object obj) { try { materialize(); @@ -203,6 +213,7 @@ public class EfficientStreamingTransformer } } + @Override public void setURIResolver(javax.xml.transform.URIResolver uRIResolver) { try { materialize(); @@ -272,6 +283,7 @@ public class EfficientStreamingTransformer //------------------------------------------------------------------------ + @Override public void transform( javax.xml.transform.Source source, javax.xml.transform.Result result) @@ -409,6 +421,8 @@ public class EfficientStreamingTransformer * Return Transformer instance for this thread, allocating a new one if * necessary. Note that this method does not clear global parameters, * properties or any other data set on a previously used transformer. + * + * @return Transformer instance */ public static Transformer newTransformer() { //CR : 6813167 diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/addressing/EPRSDDocumentFilter.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/addressing/EPRSDDocumentFilter.java index e1f39b91ea9..6321da30dcb 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/addressing/EPRSDDocumentFilter.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/addressing/EPRSDDocumentFilter.java @@ -26,6 +26,7 @@ package com.sun.xml.internal.ws.addressing; import com.sun.xml.internal.ws.api.server.*; +import com.sun.xml.internal.ws.api.server.Module; import com.sun.xml.internal.ws.api.addressing.WSEndpointReference; import com.sun.xml.internal.ws.api.addressing.AddressingVersion; import com.sun.xml.internal.ws.api.streaming.XMLStreamReaderFactory; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/message/saaj/SAAJMessageHeaders.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/message/saaj/SAAJMessageHeaders.java index 220dd8ea343..80f7d3bb6ea 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/message/saaj/SAAJMessageHeaders.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/message/saaj/SAAJMessageHeaders.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -40,6 +40,8 @@ import javax.xml.soap.SOAPHeader; import javax.xml.soap.SOAPHeaderElement; import javax.xml.soap.SOAPMessage; +import com.sun.xml.internal.messaging.saaj.soap.SOAPDocumentImpl; +import com.sun.xml.internal.messaging.saaj.soap.impl.HeaderImpl; import com.sun.xml.internal.ws.api.SOAPVersion; import com.sun.xml.internal.ws.api.WSBinding; import com.sun.xml.internal.ws.api.message.Header; @@ -234,11 +236,12 @@ public class SAAJMessageHeaders implements MessageHeaders { if (soapHeader == null) { return null; } + SOAPDocumentImpl soapDocument = ((HeaderImpl)soapHeader).getSoapDocument(); SOAPHeaderElement headerElem = find(nsUri, localName); if (headerElem == null) { return null; } - headerElem = (SOAPHeaderElement) soapHeader.removeChild(headerElem); + headerElem = (SOAPHeaderElement) soapDocument.find(soapHeader.removeChild(headerElem)); //it might have been a nonSAAJHeader - remove from that map removeNonSAAJHeader(headerElem); @@ -330,7 +333,7 @@ public class SAAJMessageHeaders implements MessageHeaders { private void addNonSAAJHeader(SOAPHeaderElement headerElem, Header header) { if (nonSAAJHeaders == null) { - nonSAAJHeaders = new HashMap(); + nonSAAJHeaders = new HashMap<>(); } nonSAAJHeaders.put(headerElem, header); } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/pipe/ThreadHelper.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/pipe/ThreadHelper.java index 25e0462c3bb..12fbb26e8bd 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/pipe/ThreadHelper.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/pipe/ThreadHelper.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -68,9 +68,7 @@ final class ThreadHelper { Class cls = Class.forName(SAFE_THREAD_NAME); Constructor ctr = cls.getConstructor(Runnable.class); return new SunMiscThreadFactory(ctr); - } catch (ClassNotFoundException ignored) { - } catch (NoSuchMethodException ignored) { - } + } catch (ClassNotFoundException | NoSuchMethodException ignored) {} return new LegacyThreadFactory(); } } @@ -90,7 +88,9 @@ final class ThreadHelper { try { return ctr.newInstance(null, r, "toBeReplaced", 0, false); } catch (ReflectiveOperationException x) { - throw new InternalError(x); + InternalError ie = new InternalError(x.getMessage()); + ie.initCause(ie); + throw ie; } } } @@ -99,7 +99,7 @@ final class ThreadHelper { private static class SunMiscThreadFactory implements ThreadFactory { final Constructor ctr; SunMiscThreadFactory(Constructor ctr) { this.ctr = ctr; } - @Override public Thread newThread(Runnable r) { + @Override public Thread newThread(final Runnable r) { return AccessController.doPrivileged( new PrivilegedAction() { @Override diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/server/MethodUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/server/MethodUtil.java index c8497055678..b976434a7bd 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/server/MethodUtil.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/server/MethodUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ import java.util.logging.Level; import java.util.logging.Logger; /** - * Utility class to invoke sun.reflect.misc.MethodUtil.invoke() if available. If not (other then Oracle JDK) fallbacks + * Utility class to invoke com.sun.xml.internal.ws.util.MethodUtil.invoke() if available. If not (other then Oracle JDK) fallbacks * to java.lang,reflect.Method.invoke() * * Be careful, copy of this class exists in several packages, iny modification must be done to other copies too! @@ -39,43 +39,17 @@ import java.util.logging.Logger; class MethodUtil { private static final Logger LOGGER = Logger.getLogger(MethodUtil.class.getName()); - private static final Method INVOKE_METHOD; - - static { - Method method; - try { - Class clazz = Class.forName("sun.reflect.misc.MethodUtil"); - method = clazz.getMethod("invoke", Method.class, Object.class, Object[].class); - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Class sun.reflect.misc.MethodUtil found; it will be used to invoke methods."); - } - } catch (Throwable t) { - method = null; - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Class sun.reflect.misc.MethodUtil not found, probably non-Oracle JVM"); - } - } - INVOKE_METHOD = method; - } static Object invoke(Object target, Method method, Object[] args) throws IllegalAccessException, InvocationTargetException { - if (INVOKE_METHOD != null) { - // sun.reflect.misc.MethodUtil.invoke(method, owner, args) - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Invoking method using sun.reflect.misc.MethodUtil"); - } - try { - return INVOKE_METHOD.invoke(null, method, target, args); - } catch (InvocationTargetException ite) { - // unwrap invocation exception added by reflection code ... - throw unwrapException(ite); - } - } else { - // other then Oracle JDK ... - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Invoking method directly, probably non-Oracle JVM"); - } - return method.invoke(target, args); + // com.sun.xml.internal.ws.util.MethodUtil.invoke(method, owner, args) + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.log(Level.FINE, "Invoking method using com.sun.xml.internal.ws.util.MethodUtil"); + } + try { + return com.sun.xml.internal.ws.util.MethodUtil.invoke(method, target, args); + } catch (InvocationTargetException ite) { + // unwrap invocation exception added by reflection code ... + throw unwrapException(ite); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/server/SDDocumentSource.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/server/SDDocumentSource.java index 0c774aa0308..3ba900a13da 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/server/SDDocumentSource.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/server/SDDocumentSource.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,9 +26,9 @@ package com.sun.xml.internal.ws.api.server; import com.sun.xml.internal.stream.buffer.XMLStreamBuffer; +import com.sun.xml.internal.ws.api.streaming.XMLStreamReaderFactory; import com.sun.xml.internal.ws.server.ServerRtException; import com.sun.xml.internal.ws.streaming.TidyXMLStreamReader; -import com.sun.xml.internal.ws.api.streaming.XMLStreamReaderFactory; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamException; @@ -42,7 +42,7 @@ import java.net.URL; * SPI that provides the source of {@link SDDocument}. * *

    - * This abstract class could be implemented by appliations, or one of the + * This abstract class could be implemented by applications, or one of the * {@link #create} methods can be used. * * @author Kohsuke Kawaguchi @@ -85,28 +85,38 @@ public abstract class SDDocumentSource { /** * System ID of this document. + * @return */ public abstract URL getSystemId(); + public static SDDocumentSource create(final Class implClass, final String url) { + return create(url, implClass); + } + /** * Creates {@link SDDocumentSource} from an URL. + * @param url + * @return */ public static SDDocumentSource create(final URL url) { return new SDDocumentSource() { private final URL systemId = url; + @Override public XMLStreamReader read(XMLInputFactory xif) throws IOException, XMLStreamException { InputStream is = url.openStream(); return new TidyXMLStreamReader( xif.createXMLStreamReader(systemId.toExternalForm(),is), is); } + @Override public XMLStreamReader read() throws IOException, XMLStreamException { InputStream is = url.openStream(); return new TidyXMLStreamReader( XMLStreamReaderFactory.create(systemId.toExternalForm(),is,false), is); } + @Override public URL getSystemId() { return systemId; } @@ -120,19 +130,22 @@ public abstract class SDDocumentSource { * @param resolvingClass class used to read resource * @param path resource path */ - public static SDDocumentSource create(final Class resolvingClass, final String path) { + private static SDDocumentSource create(final String path, final Class resolvingClass) { return new SDDocumentSource() { + @Override public XMLStreamReader read(XMLInputFactory xif) throws IOException, XMLStreamException { InputStream is = inputStream(); return new TidyXMLStreamReader(xif.createXMLStreamReader(path,is), is); } + @Override public XMLStreamReader read() throws IOException, XMLStreamException { InputStream is = inputStream(); return new TidyXMLStreamReader(XMLStreamReaderFactory.create(path,is,false), is); } + @Override public URL getSystemId() { try { return new URL("file://" + path); @@ -142,12 +155,10 @@ public abstract class SDDocumentSource { } private InputStream inputStream() throws IOException { - java.lang.reflect.Module module = resolvingClass.getModule(); - if (module != null) { - InputStream stream = module.getResourceAsStream(path); - if (stream != null) { - return stream; - } + java.lang.Module module = resolvingClass.getModule(); + InputStream stream = module.getResourceAsStream(path); + if (stream != null) { + return stream; } throw new ServerRtException("cannot.load.wsdl", path); } @@ -157,17 +168,23 @@ public abstract class SDDocumentSource { /** * Creates a {@link SDDocumentSource} from {@link XMLStreamBuffer}. + * @param systemId + * @param xsb + * @return */ public static SDDocumentSource create(final URL systemId, final XMLStreamBuffer xsb) { return new SDDocumentSource() { + @Override public XMLStreamReader read(XMLInputFactory xif) throws XMLStreamException { return xsb.readAsXMLStreamReader(); } + @Override public XMLStreamReader read() throws XMLStreamException { return xsb.readAsXMLStreamReader(); } + @Override public URL getSystemId() { return systemId; } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/streaming/ContextClassloaderLocal.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/streaming/ContextClassloaderLocal.java index d62cb623a86..6c76e261341 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/streaming/ContextClassloaderLocal.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/streaming/ContextClassloaderLocal.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,10 +25,10 @@ package com.sun.xml.internal.ws.api.streaming; +import com.sun.xml.internal.ws.resources.ContextClassloaderLocalMessages; + import java.security.AccessController; import java.security.PrivilegedAction; -import java.text.MessageFormat; -import java.util.ResourceBundle; import java.util.WeakHashMap; /** @@ -36,9 +36,7 @@ import java.util.WeakHashMap; */ abstract class ContextClassloaderLocal { - private static final String FAILED_TO_CREATE_NEW_INSTANCE = "FAILED_TO_CREATE_NEW_INSTANCE"; - - private WeakHashMap CACHE = new WeakHashMap(); + private WeakHashMap CACHE = new WeakHashMap<>(); public V get() throws Error { ClassLoader tccl = getContextClassLoader(); @@ -60,26 +58,21 @@ abstract class ContextClassloaderLocal { try { return initialValue(); } catch (Exception e) { - throw new Error(format(FAILED_TO_CREATE_NEW_INSTANCE, getClass().getName()), e); + throw new Error(ContextClassloaderLocalMessages.FAILED_TO_CREATE_NEW_INSTANCE(getClass().getName()), e); } } - private static String format(String property, Object... args) { - String text = ResourceBundle.getBundle(ContextClassloaderLocal.class.getName()).getString(property); - return MessageFormat.format(text, args); - } - private static ClassLoader getContextClassLoader() { - return (ClassLoader) - AccessController.doPrivileged(new PrivilegedAction() { - public Object run() { - ClassLoader cl = null; - try { - cl = Thread.currentThread().getContextClassLoader(); - } catch (SecurityException ex) { - } - return cl; - } - }); + return AccessController.doPrivileged(new PrivilegedAction() { + @Override + public ClassLoader run() { + ClassLoader cl = null; + try { + cl = Thread.currentThread().getContextClassLoader(); + } catch (SecurityException ex) { + } + return cl; + } + }); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/binding/BindingImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/binding/BindingImpl.java index 927fad4d4b0..536e388a4e8 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/binding/BindingImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/binding/BindingImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -75,7 +75,7 @@ public abstract class BindingImpl implements WSBinding { //This is reset when ever Binding.setHandlerChain() or SOAPBinding.setRoles() is called. private HandlerConfiguration handlerConfig; private final Set addedHeaders = new HashSet(); - private final Set knownHeaders = new HashSet(); + private final Set knownHeaders = Collections.synchronizedSet(new HashSet()); private final Set unmodKnownHeaders = Collections.unmodifiableSet(knownHeaders); private final BindingID bindingId; // Features that are set(enabled/disabled) on the binding diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/binding/SOAPBindingImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/binding/SOAPBindingImpl.java index 292ed73c135..f61114eb632 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/binding/SOAPBindingImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/binding/SOAPBindingImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,6 +42,8 @@ import javax.xml.ws.handler.Handler; import javax.xml.ws.soap.MTOMFeature; import javax.xml.ws.soap.SOAPBinding; import java.util.*; +import java.util.concurrent.locks.Lock; +import java.util.concurrent.locks.ReentrantLock; /** * @author WS Development Team @@ -57,6 +59,7 @@ public final class SOAPBindingImpl extends BindingImpl implements SOAPBinding { private Set portKnownHeaders = Collections.emptySet(); private Set bindingUnderstoodHeaders = new HashSet(); + private final Lock lock = new ReentrantLock(); /** * Use {@link BindingImpl#create(BindingID)} to create this. @@ -95,7 +98,13 @@ public final class SOAPBindingImpl extends BindingImpl implements SOAPBinding { * @param headers SOAP header names */ public void setPortKnownHeaders(@NotNull Set headers) { - this.portKnownHeaders = headers; + + try{ + lock.lock(); + this.portKnownHeaders = headers; + } finally { + lock.unlock(); + } } /** diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/client/sei/MethodUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/client/sei/MethodUtil.java index f0daea51faf..9194ce4ddd0 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/client/sei/MethodUtil.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/client/sei/MethodUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ import java.util.logging.Level; import java.util.logging.Logger; /** - * Utility class to invoke sun.reflect.misc.MethodUtil.invoke() if available. If not (other then Oracle JDK) fallbacks + * Utility class to invoke com.sun.xml.internal.ws.util.MethodUtil.invoke() if available. If not (other then Oracle JDK) fallbacks * to java.lang,reflect.Method.invoke() *

    * Be careful, copy of this class exists in several packages, iny modification must be done to other copies too! @@ -39,43 +39,17 @@ import java.util.logging.Logger; class MethodUtil { private static final Logger LOGGER = Logger.getLogger(MethodUtil.class.getName()); - private static final Method INVOKE_METHOD; - - static { - Method method; - try { - Class clazz = Class.forName("sun.reflect.misc.MethodUtil"); - method = clazz.getMethod("invoke", Method.class, Object.class, Object[].class); - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Class sun.reflect.misc.MethodUtil found; it will be used to invoke methods."); - } - } catch (Throwable t) { - method = null; - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Class sun.reflect.misc.MethodUtil not found, probably non-Oracle JVM"); - } - } - INVOKE_METHOD = method; - } static Object invoke(Object target, Method method, Object[] args) throws IllegalAccessException, InvocationTargetException { - if (INVOKE_METHOD != null) { - // sun.reflect.misc.MethodUtil.invoke(method, owner, args) - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Invoking method using sun.reflect.misc.MethodUtil"); - } - try { - return INVOKE_METHOD.invoke(null, method, target, args); - } catch (InvocationTargetException ite) { - // unwrap invocation exception added by reflection code ... - throw unwrapException(ite); - } - } else { - // other then Oracle JDK ... - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Invoking method directly, probably non-Oracle JVM"); - } - return method.invoke(target, args); + // com.sun.xml.internal.ws.util.MethodUtil.invoke(method, owner, args) + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.log(Level.FINE, "Invoking method using com.sun.xml.internal.ws.util.MethodUtil"); + } + try { + return com.sun.xml.internal.ws.util.MethodUtil.invoke(method, target, args); + } catch (InvocationTargetException ite) { + // unwrap invocation exception added by reflection code ... + throw unwrapException(ite); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/commons/xmlutil/ContextClassloaderLocal.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/commons/xmlutil/ContextClassloaderLocal.java index 63809b00875..7ae8158bbf8 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/commons/xmlutil/ContextClassloaderLocal.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/commons/xmlutil/ContextClassloaderLocal.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,10 +25,10 @@ package com.sun.xml.internal.ws.commons.xmlutil; +import com.sun.xml.internal.ws.resources.ContextClassloaderLocalMessages; + import java.security.AccessController; import java.security.PrivilegedAction; -import java.text.MessageFormat; -import java.util.ResourceBundle; import java.util.WeakHashMap; /** @@ -36,9 +36,7 @@ import java.util.WeakHashMap; */ abstract class ContextClassloaderLocal { - private static final String FAILED_TO_CREATE_NEW_INSTANCE = "FAILED_TO_CREATE_NEW_INSTANCE"; - - private WeakHashMap CACHE = new WeakHashMap(); + private WeakHashMap CACHE = new WeakHashMap<>(); public V get() throws Error { ClassLoader tccl = getContextClassLoader(); @@ -60,26 +58,21 @@ abstract class ContextClassloaderLocal { try { return initialValue(); } catch (Exception e) { - throw new Error(format(FAILED_TO_CREATE_NEW_INSTANCE, getClass().getName()), e); + throw new Error(ContextClassloaderLocalMessages.FAILED_TO_CREATE_NEW_INSTANCE(getClass().getName()), e); } } - private static String format(String property, Object... args) { - String text = ResourceBundle.getBundle(ContextClassloaderLocal.class.getName()).getString(property); - return MessageFormat.format(text, args); - } - private static ClassLoader getContextClassLoader() { - return (ClassLoader) - AccessController.doPrivileged(new PrivilegedAction() { - public Object run() { - ClassLoader cl = null; - try { - cl = Thread.currentThread().getContextClassLoader(); - } catch (SecurityException ex) { - } - return cl; - } - }); + return AccessController.doPrivileged(new PrivilegedAction() { + @Override + public ClassLoader run() { + ClassLoader cl = null; + try { + cl = Thread.currentThread().getContextClassLoader(); + } catch (SecurityException ex) { + } + return cl; + } + }); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/commons/xmlutil/ContextClassloaderLocal.properties b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/commons/xmlutil/ContextClassloaderLocal.properties deleted file mode 100644 index c0267b823ea..00000000000 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/commons/xmlutil/ContextClassloaderLocal.properties +++ /dev/null @@ -1,26 +0,0 @@ -# -# Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. Oracle designates this -# particular file as subject to the "Classpath" exception as provided -# by Oracle in the LICENSE file that accompanied this code. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -FAILED_TO_CREATE_NEW_INSTANCE=Failed to create new instance of {0} diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/developer/ContextClassloaderLocal.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/developer/ContextClassloaderLocal.java index e7d0050e775..957607e8cae 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/developer/ContextClassloaderLocal.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/developer/ContextClassloaderLocal.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,10 +25,10 @@ package com.sun.xml.internal.ws.developer; +import com.sun.xml.internal.ws.resources.ContextClassloaderLocalMessages; + import java.security.AccessController; import java.security.PrivilegedAction; -import java.text.MessageFormat; -import java.util.ResourceBundle; import java.util.WeakHashMap; /** @@ -36,9 +36,7 @@ import java.util.WeakHashMap; */ abstract class ContextClassloaderLocal { - private static final String FAILED_TO_CREATE_NEW_INSTANCE = "FAILED_TO_CREATE_NEW_INSTANCE"; - - private WeakHashMap CACHE = new WeakHashMap(); + private WeakHashMap CACHE = new WeakHashMap<>(); public V get() throws Error { ClassLoader tccl = getContextClassLoader(); @@ -60,26 +58,21 @@ abstract class ContextClassloaderLocal { try { return initialValue(); } catch (Exception e) { - throw new Error(format(FAILED_TO_CREATE_NEW_INSTANCE, getClass().getName()), e); + throw new Error(ContextClassloaderLocalMessages.FAILED_TO_CREATE_NEW_INSTANCE(getClass().getName()), e); } } - private static String format(String property, Object... args) { - String text = ResourceBundle.getBundle(ContextClassloaderLocal.class.getName()).getString(property); - return MessageFormat.format(text, args); - } - private static ClassLoader getContextClassLoader() { - return (ClassLoader) - AccessController.doPrivileged(new PrivilegedAction() { - public Object run() { - ClassLoader cl = null; - try { - cl = Thread.currentThread().getContextClassLoader(); - } catch (SecurityException ex) { - } - return cl; - } - }); + return AccessController.doPrivileged(new PrivilegedAction() { + @Override + public ClassLoader run() { + ClassLoader cl = null; + try { + cl = Thread.currentThread().getContextClassLoader(); + } catch (SecurityException ex) { + } + return cl; + } + }); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/Injector.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/Injector.java index 158e0a9f8ef..adbcb7967bf 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/Injector.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/Injector.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,12 +25,16 @@ package com.sun.xml.internal.ws.model; +import java.lang.reflect.Field; import javax.xml.ws.WebServiceException; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.net.URL; import java.security.AccessController; import java.security.PrivilegedAction; +import java.security.PrivilegedActionException; +import java.security.PrivilegedExceptionAction; +import java.security.ProtectionDomain; import java.util.logging.Level; import java.util.logging.Logger; @@ -44,31 +48,68 @@ final class Injector { private static final Logger LOGGER = Logger.getLogger(Injector.class.getName()); - private static final Method defineClass; - private static final Method resolveClass; - private static final Method getPackage; - private static final Method definePackage; + private static Method defineClass; + private static Method resolveClass; + private static Method getPackage; + private static Method definePackage; + private static Object U; static { - Method[] m = AccessController.doPrivileged( - new PrivilegedAction() { - @Override - public Method[] run() { - return new Method[]{ - getMethod(ClassLoader.class, "defineClass", String.class, byte[].class, Integer.TYPE, Integer.TYPE), - getMethod(ClassLoader.class, "resolveClass", Class.class), - getMethod(ClassLoader.class, "getPackage", String.class), - getMethod(ClassLoader.class, "definePackage", - String.class, String.class, String.class, String.class, - String.class, String.class, String.class, URL.class) - }; - } + try { + Method[] m = AccessController.doPrivileged( + new PrivilegedAction() { + @Override + public Method[] run() { + return new Method[]{ + getMethod(ClassLoader.class, "defineClass", String.class, byte[].class, Integer.TYPE, Integer.TYPE), + getMethod(ClassLoader.class, "resolveClass", Class.class), + getMethod(ClassLoader.class, "getPackage", String.class), + getMethod(ClassLoader.class, "definePackage", + String.class, String.class, String.class, String.class, + String.class, String.class, String.class, URL.class) + }; } - ); - defineClass = m[0]; - resolveClass = m[1]; - getPackage = m[2]; - definePackage = m[3]; + } + ); + defineClass = m[0]; + resolveClass = m[1]; + getPackage = m[2]; + definePackage = m[3]; + + } catch (Throwable t) { + try { + U = AccessController.doPrivileged(new PrivilegedExceptionAction() { + @Override + public Object run() throws Exception { + Class u = Class.forName("sun.misc.Unsafe"); + Field theUnsafe = u.getDeclaredField("theUnsafe"); + theUnsafe.setAccessible(true); + return theUnsafe.get(null); + } + }); + defineClass = AccessController.doPrivileged(new PrivilegedExceptionAction() { + @Override + public Method run() throws Exception { + try { + return U.getClass().getMethod("defineClass", + new Class[]{String.class, + byte[].class, + Integer.TYPE, + Integer.TYPE, + ClassLoader.class, + ProtectionDomain.class}); + } catch (NoSuchMethodException | SecurityException ex) { + throw ex; + } + } + }); + } catch (SecurityException | PrivilegedActionException ex) { + Logger.getLogger(Injector.class.getName()).log(Level.SEVERE, null, ex); + WebServiceException we = new WebServiceException(ex); + we.addSuppressed(t); + throw we; + } + } } private static Method getMethod(final Class c, final String methodname, final Class... params) { @@ -91,24 +132,26 @@ final class Injector { // nothing to do } try { + if (definePackage == null) { + return (Class) defineClass.invoke(U, className.replace('/', '.'), image, 0, image.length, cl, Injector.class.getProtectionDomain()); + } int packIndex = className.lastIndexOf('.'); if (packIndex != -1) { String pkgname = className.substring(0, packIndex); // Check if package already loaded. - Package pkg = (Package)getPackage.invoke(cl, pkgname); + Package pkg = (Package) getPackage.invoke(cl, pkgname); if (pkg == null) { definePackage.invoke(cl, pkgname, null, null, null, null, null, null, null); } } - Class c = (Class)defineClass.invoke(cl,className.replace('/','.'),image,0,image.length); + Class c = (Class) defineClass.invoke(cl, className.replace('/', '.'), image, 0, image.length); resolveClass.invoke(cl, c); return c; - } catch (IllegalAccessException e) { - LOGGER.log(Level.FINE,"Unable to inject "+className,e); - throw new WebServiceException(e); - } catch (InvocationTargetException e) { - LOGGER.log(Level.FINE,"Unable to inject "+className,e); + } catch (IllegalAccessException | InvocationTargetException e) { + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.log(Level.FINE, "Unable to inject " + className, e); + } throw new WebServiceException(e); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/RuntimeModeler.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/RuntimeModeler.java index 29f852ed033..ad6f52f342e 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/RuntimeModeler.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/RuntimeModeler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -346,7 +346,6 @@ public class RuntimeModeler { } private boolean noWrapperGen() { - if (Runtime.version().major() >= 9) return true; Object o = config.properties().get(SuppressDocLitWrapperGeneration); return (o!= null && o instanceof Boolean) ? ((Boolean) o) : false; } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/SOAPSEIModel.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/SOAPSEIModel.java index 6879a6062dc..4e72aac154b 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/SOAPSEIModel.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/model/SOAPSEIModel.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,6 +33,8 @@ import javax.xml.namespace.QName; import java.util.HashSet; import java.util.Iterator; import java.util.Set; +import java.util.concurrent.locks.Lock; +import java.util.concurrent.locks.ReentrantLock; /** * Creates SOAP specific RuntimeModel @@ -41,6 +43,8 @@ import java.util.Set; */ public class SOAPSEIModel extends AbstractSEIModelImpl { + private final Lock lock = new ReentrantLock(); + public SOAPSEIModel(WebServiceFeatureList features) { super(features); } @@ -72,15 +76,22 @@ public class SOAPSEIModel extends AbstractSEIModelImpl { public Set getKnownHeaders() { Set headers = new HashSet(); - for (JavaMethodImpl method : getJavaMethods()) { - // fill in request headers - Iterator params = method.getRequestParameters().iterator(); - fillHeaders(params, headers, Mode.IN); + + try{ + lock.lock(); + for (JavaMethodImpl method : getJavaMethods()) { + // fill in request headers + Iterator params = method.getRequestParameters().iterator(); + fillHeaders(params, headers, Mode.IN); // fill in response headers - params = method.getResponseParameters().iterator(); - fillHeaders(params, headers, Mode.OUT); - } + params = method.getResponseParameters().iterator(); + fillHeaders(params, headers, Mode.OUT); + } + }finally + { + lock.unlock(); + } return headers; } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/policy/privateutil/MethodUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/policy/privateutil/MethodUtil.java index ad2ad4a6ef5..127f74476b3 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/policy/privateutil/MethodUtil.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/policy/privateutil/MethodUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,49 +31,22 @@ import java.util.logging.Level; import java.util.logging.Logger; /** - * Utility class to invoke sun.reflect.misc.MethodUtil.invoke() if available. If not (other then Oracle JDK) fallbacks + * Utility class to invoke com.sun.xml.internal.ws.policy.util.MethodUtil.invoke() if available. If not (other then Oracle JDK) fallbacks * to java.lang,reflect.Method.invoke() */ class MethodUtil { private static final Logger LOGGER = Logger.getLogger(MethodUtil.class.getName()); - private static final Method INVOKE_METHOD; - - static { - Method method; - try { - Class clazz = Class.forName("sun.reflect.misc.MethodUtil"); - method = clazz.getMethod("invoke", Method.class, Object.class, Object[].class); - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Class sun.reflect.misc.MethodUtil found; it will be used to invoke methods."); - } - } catch (Throwable t) { - method = null; - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Class sun.reflect.misc.MethodUtil not found, probably non-Oracle JVM"); - } - } - INVOKE_METHOD = method; - } static Object invoke(Object target, Method method, Object[] args) throws IllegalAccessException, InvocationTargetException { - if (INVOKE_METHOD != null) { - // sun.reflect.misc.MethodUtil.invoke(method, owner, args) - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Invoking method using sun.reflect.misc.MethodUtil"); - } - try { - return INVOKE_METHOD.invoke(null, method, target, args); - } catch (InvocationTargetException ite) { - // unwrap invocation exception added by reflection code ... - throw unwrapException(ite); - } - } else { - // other then Oracle JDK ... - if (LOGGER.isLoggable(Level.FINE)) { - LOGGER.log(Level.FINE, "Invoking method directly, probably non-Oracle JVM"); - } - return method.invoke(target, args); + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.log(Level.FINE, "Invoking method using com.sun.xml.internal.ws.policy.util.MethodUtil"); + } + try { + return com.sun.xml.internal.ws.policy.util.MethodUtil.invoke(method, target, args); + } catch (InvocationTargetException ite) { + // unwrap invocation exception added by reflection code ... + throw unwrapException(ite); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/policy/util/MethodUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/policy/util/MethodUtil.java new file mode 100644 index 00000000000..b8af4d28a37 --- /dev/null +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/policy/util/MethodUtil.java @@ -0,0 +1,293 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package com.sun.xml.internal.ws.policy.util; + +import java.io.IOException; +import java.io.InputStream; +import java.lang.reflect.InvocationTargetException; +import java.lang.reflect.Method; +import java.lang.reflect.Proxy; +import java.security.AccessController; +import java.security.AllPermission; +import java.security.CodeSource; +import java.security.PermissionCollection; +import java.security.PrivilegedExceptionAction; +import java.security.SecureClassLoader; +import java.util.Arrays; + +/* + * This copies from sun.reflect.misc.MethodUtil to implement the trampoline + * code such that when a Method is invoked, it will be called through + * the trampoline that is defined by this MethodUtil class loader. + */ +class Trampoline { + static { + if (Trampoline.class.getClassLoader() == null) { + throw new Error( + "Trampoline must not be defined by the bootstrap classloader"); + } + } + + private static void ensureInvocableMethod(Method m) + throws InvocationTargetException { + Class clazz = m.getDeclaringClass(); + if (clazz.equals(AccessController.class) || + clazz.equals(Method.class) || + clazz.getName().startsWith("java.lang.invoke.")) + throw new InvocationTargetException( + new UnsupportedOperationException("invocation not supported")); + } + + private static Object invoke(Method m, Object obj, Object[] params) + throws InvocationTargetException, IllegalAccessException { + ensureInvocableMethod(m); + return m.invoke(obj, params); + } +} + +/* + * Create a trampoline class. + */ +public final class MethodUtil extends SecureClassLoader { + private static final String WS_UTIL_POLICY_PKG = "com.sun.xml.internal.ws.policy.util."; + private static final String TRAMPOLINE = WS_UTIL_POLICY_PKG + "Trampoline"; + private static final Method bounce = getTrampoline(); + private static final int DEFAULT_BUFFER_SIZE = 8192; + private static final int MAX_BUFFER_SIZE = Integer.MAX_VALUE - 8; + + + private MethodUtil() { + super(); + } + + /* + * Bounce through the trampoline. + */ + public static Object invoke(Method m, Object obj, Object[] params) + throws InvocationTargetException, IllegalAccessException { + try { + return bounce.invoke(null, m, obj, params); + } catch (InvocationTargetException ie) { + Throwable t = ie.getCause(); + + if (t instanceof InvocationTargetException) { + throw (InvocationTargetException) t; + } else if (t instanceof IllegalAccessException) { + throw (IllegalAccessException) t; + } else if (t instanceof RuntimeException) { + throw (RuntimeException) t; + } else if (t instanceof Error) { + throw (Error) t; + } else { + throw new Error("Unexpected invocation error", t); + } + } catch (IllegalAccessException iae) { + // this can't happen + throw new Error("Unexpected invocation error", iae); + } + } + + private static Method getTrampoline() { + try { + return AccessController.doPrivileged( + new PrivilegedExceptionAction() { + public Method run() throws Exception { + Class t = getTrampolineClass(); + Method b = t.getDeclaredMethod("invoke", + Method.class, Object.class, Object[].class); + b.setAccessible(true); + return b; + } + }); + } catch (Exception e) { + throw new InternalError("bouncer cannot be found", e); + } + } + + + protected synchronized Class loadClass(String name, boolean resolve) + throws ClassNotFoundException { + // First, check if the class has already been loaded + checkPackageAccess(name); + Class c = findLoadedClass(name); + if (c == null) { + try { + c = findClass(name); + } catch (ClassNotFoundException e) { + // Fall through ... + } + if (c == null) { + c = getParent().loadClass(name); + } + } + if (resolve) { + resolveClass(c); + } + return c; + } + + + protected Class findClass(final String name) + throws ClassNotFoundException { + if (!name.startsWith(WS_UTIL_POLICY_PKG)) { + throw new ClassNotFoundException(name); + } + String path = "/".concat(name.replace('.', '/').concat(".class")); + try (InputStream in = MethodUtil.class.getResourceAsStream(path)) { + byte[] b = readAllBytes(in); + return defineClass(name, b); + } catch (IOException e) { + throw new ClassNotFoundException(name, e); + } + } + + /** + * JDK9 {@link InputStream#readAllBytes()} substitution. + */ + private byte[] readAllBytes(InputStream in) throws IOException { + byte[] buf = new byte[DEFAULT_BUFFER_SIZE]; + int capacity = buf.length; + int nread = 0; + int n; + for (; ; ) { + // read to EOF which may read more or less than initial buffer size + while ((n = in.read(buf, nread, capacity - nread)) > 0) + nread += n; + + // if the last call to read returned -1, then we're done + if (n < 0) + break; + + // need to allocate a larger buffer + if (capacity <= MAX_BUFFER_SIZE - capacity) { + capacity = capacity << 1; + } else { + if (capacity == MAX_BUFFER_SIZE) + throw new OutOfMemoryError("Required array size too large"); + capacity = MAX_BUFFER_SIZE; + } + buf = Arrays.copyOf(buf, capacity); + } + return (capacity == nread) ? buf : Arrays.copyOf(buf, nread); + } + + + /* + * Define the proxy classes + */ + private Class defineClass(String name, byte[] b) throws IOException { + CodeSource cs = new CodeSource(null, (java.security.cert.Certificate[]) null); + if (!name.equals(TRAMPOLINE)) { + throw new IOException("MethodUtil: bad name " + name); + } + return defineClass(name, b, 0, b.length, cs); + } + + protected PermissionCollection getPermissions(CodeSource codesource) { + PermissionCollection perms = super.getPermissions(codesource); + perms.add(new AllPermission()); + return perms; + } + + private static Class getTrampolineClass() { + try { + return Class.forName(TRAMPOLINE, true, new MethodUtil()); + } catch (ClassNotFoundException e) { + } + return null; + } + + /** + * Checks package access on the given classname. + * This method is typically called when the Class instance is not + * available and the caller attempts to load a class on behalf + * the true caller (application). + */ + private static void checkPackageAccess(String name) { + SecurityManager s = System.getSecurityManager(); + if (s != null) { + String cname = name.replace('/', '.'); + if (cname.startsWith("[")) { + int b = cname.lastIndexOf('[') + 2; + if (b > 1 && b < cname.length()) { + cname = cname.substring(b); + } + } + int i = cname.lastIndexOf('.'); + if (i != -1) { + s.checkPackageAccess(cname.substring(0, i)); + } + } + } + + /** + * Checks package access on the given class. + *

    + * If it is a {@link Proxy#isProxyClass(Class)} that implements + * a non-public interface (i.e. may be in a non-restricted package), + * also check the package access on the proxy interfaces. + */ + private static void checkPackageAccess(Class clazz) { + checkPackageAccess(clazz.getName()); + if (isNonPublicProxyClass(clazz)) { + checkProxyPackageAccess(clazz); + } + } + + // Note that bytecode instrumentation tools may exclude 'sun.*' + // classes but not generated proxy classes and so keep it in com.sun.* + private static final String PROXY_PACKAGE = "com.sun.proxy"; + + /** + * Test if the given class is a proxy class that implements + * non-public interface. Such proxy class may be in a non-restricted + * package that bypasses checkPackageAccess. + */ + private static boolean isNonPublicProxyClass(Class cls) { + String name = cls.getName(); + int i = name.lastIndexOf('.'); + String pkg = (i != -1) ? name.substring(0, i) : ""; + return Proxy.isProxyClass(cls) && !pkg.startsWith(PROXY_PACKAGE); + } + + /** + * Check package access on the proxy interfaces that the given proxy class + * implements. + * + * @param clazz Proxy class object + */ + private static void checkProxyPackageAccess(Class clazz) { + SecurityManager s = System.getSecurityManager(); + if (s != null) { + // check proxy interfaces if the given class is a proxy class + if (Proxy.isProxyClass(clazz)) { + for (Class intf : clazz.getInterfaces()) { + checkPackageAccess(intf); + } + } + } + } +} diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/spi/ContextClassloaderLocal.properties b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/resources/ContextClassloaderLocal.properties similarity index 94% rename from jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/spi/ContextClassloaderLocal.properties rename to jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/resources/ContextClassloaderLocal.properties index c0267b823ea..d79956811cb 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/spi/ContextClassloaderLocal.properties +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/resources/ContextClassloaderLocal.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/resources/ContextClassloaderLocalMessages.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/resources/ContextClassloaderLocalMessages.java new file mode 100644 index 00000000000..d52a1ab00d3 --- /dev/null +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/resources/ContextClassloaderLocalMessages.java @@ -0,0 +1,71 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package com.sun.xml.internal.ws.resources; + +import java.util.Locale; +import java.util.ResourceBundle; +import javax.annotation.Generated; +import com.sun.istack.internal.localization.Localizable; +import com.sun.istack.internal.localization.LocalizableMessageFactory; +import com.sun.istack.internal.localization.LocalizableMessageFactory.ResourceBundleSupplier; +import com.sun.istack.internal.localization.Localizer; + + +/** + * Defines string formatting method for each constant in the resource file + * + */ +@Generated("com.sun.istack.internal.maven.ResourceGenMojo") +public final class ContextClassloaderLocalMessages { + + private final static String BUNDLE_NAME = "com.sun.xml.internal.ws.resources.ContextClassloaderLocal"; + private final static LocalizableMessageFactory MESSAGE_FACTORY = new LocalizableMessageFactory(BUNDLE_NAME, new ContextClassloaderLocalMessages.BundleSupplier()); + private final static Localizer LOCALIZER = new Localizer(); + + public static Localizable localizableFAILED_TO_CREATE_NEW_INSTANCE(Object arg0) { + return MESSAGE_FACTORY.getMessage("FAILED_TO_CREATE_NEW_INSTANCE", arg0); + } + + /** + * Failed to create new instance of {0} + * + */ + public static String FAILED_TO_CREATE_NEW_INSTANCE(Object arg0) { + return LOCALIZER.localize(localizableFAILED_TO_CREATE_NEW_INSTANCE(arg0)); + } + + private static class BundleSupplier + implements ResourceBundleSupplier + { + + + public ResourceBundle getResourceBundle(Locale locale) { + return ResourceBundle.getBundle(BUNDLE_NAME, locale); + } + + } + +} diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/spi/ContextClassloaderLocal.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/spi/ContextClassloaderLocal.java index cf0bf26eec3..976cdd1e7b5 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/spi/ContextClassloaderLocal.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/spi/ContextClassloaderLocal.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,10 +25,10 @@ package com.sun.xml.internal.ws.spi; +import com.sun.xml.internal.ws.resources.ContextClassloaderLocalMessages; + import java.security.AccessController; import java.security.PrivilegedAction; -import java.text.MessageFormat; -import java.util.ResourceBundle; import java.util.WeakHashMap; /** @@ -36,9 +36,7 @@ import java.util.WeakHashMap; */ abstract class ContextClassloaderLocal { - private static final String FAILED_TO_CREATE_NEW_INSTANCE = "FAILED_TO_CREATE_NEW_INSTANCE"; - - private WeakHashMap CACHE = new WeakHashMap(); + private WeakHashMap CACHE = new WeakHashMap<>(); public V get() throws Error { ClassLoader tccl = getContextClassLoader(); @@ -60,26 +58,21 @@ abstract class ContextClassloaderLocal { try { return initialValue(); } catch (Exception e) { - throw new Error(format(FAILED_TO_CREATE_NEW_INSTANCE, getClass().getName()), e); + throw new Error(ContextClassloaderLocalMessages.FAILED_TO_CREATE_NEW_INSTANCE(getClass().getName()), e); } } - private static String format(String property, Object... args) { - String text = ResourceBundle.getBundle(ContextClassloaderLocal.class.getName()).getString(property); - return MessageFormat.format(text, args); - } - private static ClassLoader getContextClassLoader() { - return (ClassLoader) - AccessController.doPrivileged(new PrivilegedAction() { - public Object run() { - ClassLoader cl = null; - try { - cl = Thread.currentThread().getContextClassLoader(); - } catch (SecurityException ex) { - } - return cl; - } - }); + return AccessController.doPrivileged(new PrivilegedAction() { + @Override + public ClassLoader run() { + ClassLoader cl = null; + try { + cl = Thread.currentThread().getContextClassLoader(); + } catch (SecurityException ex) { + } + return cl; + } + }); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/transport/http/server/EndpointImpl.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/transport/http/server/EndpointImpl.java index 9f23f51b43a..944dd388df6 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/transport/http/server/EndpointImpl.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/transport/http/server/EndpointImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -69,13 +69,11 @@ import org.w3c.dom.Element; /** * Implements {@link Endpoint}. - *

    - *

    + * * This class accumulates the information necessary to create * {@link WSEndpoint}, and then when {@link #publish} method * is called it will be created. - *

    - *

    + * * This object also allows accumulated information to be retrieved. * * @author Jitendra Kotamraju @@ -205,14 +203,17 @@ public class EndpointImpl extends Endpoint { invoker = null; } + @Override public Binding getBinding() { return binding; } + @Override public Object getImplementor() { return implementor; } + @Override public void publish(String address) { canPublish(); URL url; @@ -232,6 +233,7 @@ public class EndpointImpl extends Endpoint { ((HttpEndpoint) actualEndpoint).publish(address); } + @Override public void publish(Object serverContext) { canPublish(); if (!com.sun.net.httpserver.HttpContext.class.isAssignableFrom(serverContext.getClass())) { @@ -241,12 +243,14 @@ public class EndpointImpl extends Endpoint { ((HttpEndpoint) actualEndpoint).publish(serverContext); } + @Override public void publish(HttpContext serverContext) { canPublish(); createEndpoint(serverContext.getPath()); ((HttpEndpoint) actualEndpoint).publish(serverContext); } + @Override public void stop() { if (isPublished()) { ((HttpEndpoint) actualEndpoint).stop(); @@ -255,14 +259,17 @@ public class EndpointImpl extends Endpoint { } } + @Override public boolean isPublished() { return actualEndpoint != null; } + @Override public List getMetadata() { return metadata; } + @Override public void setMetadata(java.util.List metadata) { if (isPublished()) { throw new IllegalStateException("Cannot set Metadata. Endpoint is already published"); @@ -270,20 +277,24 @@ public class EndpointImpl extends Endpoint { this.metadata = metadata; } + @Override public Executor getExecutor() { return executor; } + @Override public void setExecutor(Executor executor) { this.executor = executor; } + @Override public Map getProperties() { - return new HashMap(properties); + return new HashMap<>(properties); } + @Override public void setProperties(Map map) { - this.properties = new HashMap(map); + this.properties = new HashMap<>(map); } /* @@ -335,7 +346,7 @@ public class EndpointImpl extends Endpoint { * reuse the Source object multiple times. */ private List buildDocList() { - List r = new ArrayList(); + List r = new ArrayList<>(); if (metadata != null) { for (Source source : metadata) { @@ -344,14 +355,8 @@ public class EndpointImpl extends Endpoint { String systemId = source.getSystemId(); r.add(SDDocumentSource.create(new URL(systemId), xsbr.getXMLStreamBuffer())); - } catch (TransformerException te) { + } catch (TransformerException | IOException | SAXException | ParserConfigurationException te) { throw new ServerRtException("server.rt.err", te); - } catch (IOException te) { - throw new ServerRtException("server.rt.err", te); - } catch (SAXException e) { - throw new ServerRtException("server.rt.err", e); - } catch (ParserConfigurationException e) { - throw new ServerRtException("server.rt.err", e); } } } @@ -367,11 +372,6 @@ public class EndpointImpl extends Endpoint { EndpointFactory.verifyImplementorClass(implClass, metadataReader); String wsdlLocation = EndpointFactory.getWsdlLocation(implClass, metadataReader); if (wsdlLocation != null) { - ClassLoader cl = implClass.getClassLoader(); - URL url = cl.getResource(wsdlLocation); - if (url != null) { - return SDDocumentSource.create(url); - } return SDDocumentSource.create(implClass, wsdlLocation); } return null; @@ -388,10 +388,12 @@ public class EndpointImpl extends Endpoint { } } + @Override public EndpointReference getEndpointReference(Element...referenceParameters) { return getEndpointReference(W3CEndpointReference.class, referenceParameters); } + @Override public T getEndpointReference(Class clazz, Element...referenceParameters) { if (!isPublished()) { throw new WebServiceException("Endpoint is not published yet"); @@ -458,13 +460,12 @@ public class EndpointImpl extends Endpoint { public void start(@NotNull WSWebServiceContext wsc, @NotNull WSEndpoint endpoint) { try { spiInvoker.inject(wsc); - } catch (IllegalAccessException e) { - throw new WebServiceException(e); - } catch (InvocationTargetException e) { + } catch (IllegalAccessException | InvocationTargetException e) { throw new WebServiceException(e); } } + @Override public Object invoke(@NotNull Packet p, @NotNull Method m, @NotNull Object... args) throws InvocationTargetException, IllegalAccessException { return spiInvoker.invoke(m, args); } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/transport/http/server/ServerMgr.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/transport/http/server/ServerMgr.java index 6455b83efa9..2d8ecee4cfc 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/transport/http/server/ServerMgr.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/transport/http/server/ServerMgr.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,8 +37,8 @@ import java.util.Map; import java.util.Set; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; +import java.util.logging.Level; import java.util.logging.Logger; -import java.util.Optional; /** @@ -49,10 +49,10 @@ import java.util.Optional; final class ServerMgr { private static final ServerMgr serverMgr = new ServerMgr(); - private static final Logger logger = + private static final Logger LOGGER = Logger.getLogger( com.sun.xml.internal.ws.util.Constants.LoggingDomain + ".server.http"); - private final Map servers = new HashMap(); + private final Map servers = new HashMap<>(); private ServerMgr() {} @@ -83,25 +83,26 @@ final class ServerMgr { synchronized(servers) { state = servers.get(inetAddress); if (state == null) { - final int finalPortNum = port; - Optional stateOpt = - servers.values() - .stream() - .filter(s -> s.getServer() - .getAddress() - .getPort() == finalPortNum) - .findAny(); - - if (inetAddress.getAddress().isAnyLocalAddress() && - stateOpt.isPresent()) { - state = stateOpt.get(); + ServerState free = null; + for (ServerState ss : servers.values()) { + if (port == ss.getServer().getAddress().getPort()) { + free = ss; + break; + } + } + if (inetAddress.getAddress().isAnyLocalAddress() && free != null) { + state = free; } else { - logger.fine("Creating new HTTP Server at "+inetAddress); + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.fine("Creating new HTTP Server at "+inetAddress); + } // Creates server with default socket backlog server = HttpServer.create(inetAddress, 0); server.setExecutor(Executors.newCachedThreadPool()); String path = url.toURI().getPath(); - logger.fine("Creating HTTP Context at = "+path); + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.fine("Creating HTTP Context at = "+path); + } HttpContext context = server.createContext(path); server.start(); @@ -110,7 +111,9 @@ final class ServerMgr { // or IP: 0.0.0.0 - which is used to monitor network traffic from any valid IP address inetAddress = server.getAddress(); - logger.fine("HTTP server started = "+inetAddress); + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.fine("HTTP server started = "+inetAddress); + } state = new ServerState(server, path); servers.put(inetAddress, state); return context; @@ -121,11 +124,15 @@ final class ServerMgr { if (state.getPaths().contains(url.getPath())) { String err = "Context with URL path "+url.getPath()+ " already exists on the server "+server.getAddress(); - logger.fine(err); + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.fine(err); + } throw new IllegalArgumentException(err); } - logger.fine("Creating HTTP Context at = "+url.getPath()); + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.fine("Creating HTTP Context at = "+url.getPath()); + } HttpContext context = server.createContext(url.getPath()); state.oneMoreContext(url.getPath()); return context; @@ -157,7 +164,7 @@ final class ServerMgr { private static final class ServerState { private final HttpServer server; private int instances; - private Set paths = new HashSet(); + private final Set paths = new HashSet<>(); ServerState(HttpServer server, String path) { this.server = server; diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/HandlerAnnotationProcessor.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/HandlerAnnotationProcessor.java index 42385239f3f..53d37f3dee8 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/HandlerAnnotationProcessor.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/HandlerAnnotationProcessor.java @@ -234,17 +234,15 @@ public class HandlerAnnotationProcessor { } private static InputStream moduleResource(Class resolvingClass, String name) { - java.lang.reflect.Module module = resolvingClass.getModule(); - if (module != null) { - try { - InputStream stream = module.getResourceAsStream(name); - if (stream != null) { - return stream; - } - } catch(IOException e) { - throw new UtilException("util.failed.to.find.handlerchain.file", - resolvingClass.getName(), name); + Module module = resolvingClass.getModule(); + try { + InputStream stream = module.getResourceAsStream(name); + if (stream != null) { + return stream; } + } catch(IOException e) { + throw new UtilException("util.failed.to.find.handlerchain.file", + resolvingClass.getName(), name); } return null; } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/MethodUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/MethodUtil.java new file mode 100644 index 00000000000..8eaf51e461f --- /dev/null +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/MethodUtil.java @@ -0,0 +1,293 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package com.sun.xml.internal.ws.util; + +import java.io.IOException; +import java.io.InputStream; +import java.lang.reflect.InvocationTargetException; +import java.lang.reflect.Method; +import java.lang.reflect.Proxy; +import java.security.AccessController; +import java.security.AllPermission; +import java.security.CodeSource; +import java.security.PermissionCollection; +import java.security.PrivilegedExceptionAction; +import java.security.SecureClassLoader; +import java.util.Arrays; + +/* + * This copies from sun.reflect.misc.MethodUtil to implement the trampoline + * code such that when a Method is invoked, it will be called through + * the trampoline that is defined by this MethodUtil class loader. + */ +class Trampoline { + static { + if (Trampoline.class.getClassLoader() == null) { + throw new Error( + "Trampoline must not be defined by the bootstrap classloader"); + } + } + + private static void ensureInvocableMethod(Method m) + throws InvocationTargetException { + Class clazz = m.getDeclaringClass(); + if (clazz.equals(AccessController.class) || + clazz.equals(Method.class) || + clazz.getName().startsWith("java.lang.invoke.")) + throw new InvocationTargetException( + new UnsupportedOperationException("invocation not supported")); + } + + private static Object invoke(Method m, Object obj, Object[] params) + throws InvocationTargetException, IllegalAccessException { + ensureInvocableMethod(m); + return m.invoke(obj, params); + } +} + +/* + * Create a trampoline class. + */ +public final class MethodUtil extends SecureClassLoader { + private static final String WS_UTIL_PKG = "com.sun.xml.internal.ws.util."; + private static final String TRAMPOLINE = WS_UTIL_PKG + "Trampoline"; + private static final Method bounce = getTrampoline(); + private static final int DEFAULT_BUFFER_SIZE = 8192; + private static final int MAX_BUFFER_SIZE = Integer.MAX_VALUE - 8; + + + private MethodUtil() { + super(); + } + + /* + * Bounce through the trampoline. + */ + public static Object invoke(Method m, Object obj, Object[] params) + throws InvocationTargetException, IllegalAccessException { + try { + return bounce.invoke(null, m, obj, params); + } catch (InvocationTargetException ie) { + Throwable t = ie.getCause(); + + if (t instanceof InvocationTargetException) { + throw (InvocationTargetException) t; + } else if (t instanceof IllegalAccessException) { + throw (IllegalAccessException) t; + } else if (t instanceof RuntimeException) { + throw (RuntimeException) t; + } else if (t instanceof Error) { + throw (Error) t; + } else { + throw new Error("Unexpected invocation error", t); + } + } catch (IllegalAccessException iae) { + // this can't happen + throw new Error("Unexpected invocation error", iae); + } + } + + private static Method getTrampoline() { + try { + return AccessController.doPrivileged( + new PrivilegedExceptionAction() { + public Method run() throws Exception { + Class t = getTrampolineClass(); + Method b = t.getDeclaredMethod("invoke", + Method.class, Object.class, Object[].class); + b.setAccessible(true); + return b; + } + }); + } catch (Exception e) { + throw new InternalError("bouncer cannot be found", e); + } + } + + + protected synchronized Class loadClass(String name, boolean resolve) + throws ClassNotFoundException { + // First, check if the class has already been loaded + checkPackageAccess(name); + Class c = findLoadedClass(name); + if (c == null) { + try { + c = findClass(name); + } catch (ClassNotFoundException e) { + // Fall through ... + } + if (c == null) { + c = getParent().loadClass(name); + } + } + if (resolve) { + resolveClass(c); + } + return c; + } + + + protected Class findClass(final String name) + throws ClassNotFoundException { + if (!name.startsWith(WS_UTIL_PKG)) { + throw new ClassNotFoundException(name); + } + String path = "/".concat(name.replace('.', '/').concat(".class")); + try (InputStream in = MethodUtil.class.getResourceAsStream(path)) { + byte[] b = readAllBytes(in); + return defineClass(name, b); + } catch (IOException e) { + throw new ClassNotFoundException(name, e); + } + } + + /** + * JDK9 {@link InputStream#readAllBytes()} substitution. + */ + private byte[] readAllBytes(InputStream in) throws IOException { + byte[] buf = new byte[DEFAULT_BUFFER_SIZE]; + int capacity = buf.length; + int nread = 0; + int n; + for (; ; ) { + // read to EOF which may read more or less than initial buffer size + while ((n = in.read(buf, nread, capacity - nread)) > 0) + nread += n; + + // if the last call to read returned -1, then we're done + if (n < 0) + break; + + // need to allocate a larger buffer + if (capacity <= MAX_BUFFER_SIZE - capacity) { + capacity = capacity << 1; + } else { + if (capacity == MAX_BUFFER_SIZE) + throw new OutOfMemoryError("Required array size too large"); + capacity = MAX_BUFFER_SIZE; + } + buf = Arrays.copyOf(buf, capacity); + } + return (capacity == nread) ? buf : Arrays.copyOf(buf, nread); + } + + + /* + * Define the proxy classes + */ + private Class defineClass(String name, byte[] b) throws IOException { + CodeSource cs = new CodeSource(null, (java.security.cert.Certificate[]) null); + if (!name.equals(TRAMPOLINE)) { + throw new IOException("MethodUtil: bad name " + name); + } + return defineClass(name, b, 0, b.length, cs); + } + + protected PermissionCollection getPermissions(CodeSource codesource) { + PermissionCollection perms = super.getPermissions(codesource); + perms.add(new AllPermission()); + return perms; + } + + private static Class getTrampolineClass() { + try { + return Class.forName(TRAMPOLINE, true, new MethodUtil()); + } catch (ClassNotFoundException e) { + } + return null; + } + + /** + * Checks package access on the given classname. + * This method is typically called when the Class instance is not + * available and the caller attempts to load a class on behalf + * the true caller (application). + */ + private static void checkPackageAccess(String name) { + SecurityManager s = System.getSecurityManager(); + if (s != null) { + String cname = name.replace('/', '.'); + if (cname.startsWith("[")) { + int b = cname.lastIndexOf('[') + 2; + if (b > 1 && b < cname.length()) { + cname = cname.substring(b); + } + } + int i = cname.lastIndexOf('.'); + if (i != -1) { + s.checkPackageAccess(cname.substring(0, i)); + } + } + } + + /** + * Checks package access on the given class. + *

    + * If it is a {@link Proxy#isProxyClass(Class)} that implements + * a non-public interface (i.e. may be in a non-restricted package), + * also check the package access on the proxy interfaces. + */ + private static void checkPackageAccess(Class clazz) { + checkPackageAccess(clazz.getName()); + if (isNonPublicProxyClass(clazz)) { + checkProxyPackageAccess(clazz); + } + } + + // Note that bytecode instrumentation tools may exclude 'sun.*' + // classes but not generated proxy classes and so keep it in com.sun.* + private static final String PROXY_PACKAGE = "com.sun.proxy"; + + /** + * Test if the given class is a proxy class that implements + * non-public interface. Such proxy class may be in a non-restricted + * package that bypasses checkPackageAccess. + */ + private static boolean isNonPublicProxyClass(Class cls) { + String name = cls.getName(); + int i = name.lastIndexOf('.'); + String pkg = (i != -1) ? name.substring(0, i) : ""; + return Proxy.isProxyClass(cls) && !pkg.startsWith(PROXY_PACKAGE); + } + + /** + * Check package access on the proxy interfaces that the given proxy class + * implements. + * + * @param clazz Proxy class object + */ + private static void checkProxyPackageAccess(Class clazz) { + SecurityManager s = System.getSecurityManager(); + if (s != null) { + // check proxy interfaces if the given class is a proxy class + if (Proxy.isProxyClass(clazz)) { + for (Class intf : clazz.getInterfaces()) { + checkPackageAccess(intf); + } + } + } + } +} diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/version.properties b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/version.properties index eedc7c2b359..82452acb3d7 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/version.properties +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/version.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -26,4 +26,4 @@ build-id=2.3.0-SNAPSHOT build-version=JAX-WS RI 2.3.0-SNAPSHOT major-version=2.3.0 -svn-revision=5c2c1fd2f2ab3b5c7cea25f79aa49e54cb84b7cc +svn-revision=e8c5e9697d9b27d83ff35d767939b2f55e667621 diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/ContextClassloaderLocal.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/ContextClassloaderLocal.java index 93a44b68050..715db421328 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/ContextClassloaderLocal.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/ContextClassloaderLocal.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,10 +25,10 @@ package com.sun.xml.internal.ws.util.xml; +import com.sun.xml.internal.ws.resources.ContextClassloaderLocalMessages; + import java.security.AccessController; import java.security.PrivilegedAction; -import java.text.MessageFormat; -import java.util.ResourceBundle; import java.util.WeakHashMap; /** @@ -36,9 +36,7 @@ import java.util.WeakHashMap; */ abstract class ContextClassloaderLocal { - private static final String FAILED_TO_CREATE_NEW_INSTANCE = "FAILED_TO_CREATE_NEW_INSTANCE"; - - private WeakHashMap CACHE = new WeakHashMap(); + private WeakHashMap CACHE = new WeakHashMap<>(); public V get() throws Error { ClassLoader tccl = getContextClassLoader(); @@ -60,26 +58,21 @@ abstract class ContextClassloaderLocal { try { return initialValue(); } catch (Exception e) { - throw new Error(format(FAILED_TO_CREATE_NEW_INSTANCE, getClass().getName()), e); + throw new Error(ContextClassloaderLocalMessages.FAILED_TO_CREATE_NEW_INSTANCE(getClass().getName()), e); } } - private static String format(String property, Object... args) { - String text = ResourceBundle.getBundle(ContextClassloaderLocal.class.getName()).getString(property); - return MessageFormat.format(text, args); - } - private static ClassLoader getContextClassLoader() { - return (ClassLoader) - AccessController.doPrivileged(new PrivilegedAction() { - public Object run() { - ClassLoader cl = null; - try { - cl = Thread.currentThread().getContextClassLoader(); - } catch (SecurityException ex) { - } - return cl; - } - }); + return AccessController.doPrivileged(new PrivilegedAction() { + @Override + public ClassLoader run() { + ClassLoader cl = null; + try { + cl = Thread.currentThread().getContextClassLoader(); + } catch (SecurityException ex) { + } + return cl; + } + }); } } diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/ContextClassloaderLocal.properties b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/ContextClassloaderLocal.properties deleted file mode 100644 index c0267b823ea..00000000000 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/ContextClassloaderLocal.properties +++ /dev/null @@ -1,26 +0,0 @@ -# -# Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. Oracle designates this -# particular file as subject to the "Classpath" exception as provided -# by Oracle in the LICENSE file that accompanied this code. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -FAILED_TO_CREATE_NEW_INSTANCE=Failed to create new instance of {0} diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/XmlCatalogUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/XmlCatalogUtil.java new file mode 100644 index 00000000000..d1ef8648bfc --- /dev/null +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/XmlCatalogUtil.java @@ -0,0 +1,114 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package com.sun.xml.internal.ws.util.xml; + +import com.sun.istack.internal.Nullable; +import com.sun.xml.internal.ws.server.ServerRtException; +import java.io.File; +import java.net.URI; +import java.net.URL; +import java.util.ArrayList; +import java.util.Collections; +import java.util.Enumeration; +import javax.xml.catalog.CatalogFeatures; +import javax.xml.catalog.CatalogFeatures.Feature; +import javax.xml.catalog.CatalogManager; +import javax.xml.ws.WebServiceException; +import org.xml.sax.EntityResolver; + +/** + * + * @author lukas + */ +public class XmlCatalogUtil { + + // Cache CatalogFeatures instance for future usages. + // Resolve feature is set to "continue" value for backward compatibility. + private static final CatalogFeatures CATALOG_FEATURES + = CatalogFeatures.builder().with(Feature.RESOLVE, "continue").build(); + + /** + * Gets an EntityResolver using XML catalog + * + * @param catalogUrl + * @return + */ + public static EntityResolver createEntityResolver(@Nullable URL catalogUrl) { + ArrayList urlsArray = new ArrayList<>(); + EntityResolver er; + if (catalogUrl != null) { + urlsArray.add(catalogUrl); + } + try { + er = createCatalogResolver(urlsArray); + } catch (Exception e) { + throw new ServerRtException("server.rt.err", e); + } + return er; + } + + /** + * Gets a default EntityResolver for catalog at META-INF/jaxws-catalog.xml + * + * @return + */ + public static EntityResolver createDefaultCatalogResolver() { + EntityResolver er; + try { + /** + * Gets a URLs for catalog defined at META-INF/jaxws-catalog.xml + */ + ClassLoader cl = Thread.currentThread().getContextClassLoader(); + Enumeration catalogEnum; + if (cl == null) { + catalogEnum = ClassLoader.getSystemResources("META-INF/jax-ws-catalog.xml"); + } else { + catalogEnum = cl.getResources("META-INF/jax-ws-catalog.xml"); + } + er = createCatalogResolver(Collections.list(catalogEnum)); + } catch (Exception e) { + throw new WebServiceException(e); + } + + return er; + } + + /** + * Instantiate catalog resolver using new catalog API (javax.xml.catalog.*) + * added in JDK9. Usage of new API removes dependency on internal API + * (com.sun.org.apache.xml.internal) for modular runtime. + */ + private static EntityResolver createCatalogResolver(ArrayList urls) throws Exception { + // Prepare array of catalog URIs + URI[] uris = urls.stream() + .map(u -> URI.create(u.toExternalForm())) + .toArray(URI[]::new); + + //Create CatalogResolver with new JDK9+ API + return (EntityResolver) CatalogManager.catalogResolver(CATALOG_FEATURES, uris); + } + +} diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/XmlUtil.java b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/XmlUtil.java index d84fa5e7d11..213b584b15a 100644 --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/XmlUtil.java +++ b/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/util/xml/XmlUtil.java @@ -26,30 +26,21 @@ package com.sun.xml.internal.ws.util.xml; import com.sun.istack.internal.Nullable; -import com.sun.xml.internal.ws.server.ServerRtException; import com.sun.xml.internal.ws.util.ByteArrayBuffer; import java.io.IOException; import java.io.InputStream; import java.io.OutputStreamWriter; import java.io.Writer; -import java.lang.reflect.Method; -import java.net.URI; import java.net.URL; import java.security.AccessController; import java.security.PrivilegedAction; import java.util.ArrayList; -import java.util.Collections; -import java.util.Enumeration; import java.util.Iterator; import java.util.List; import java.util.StringTokenizer; import java.util.logging.Level; import java.util.logging.Logger; -import java.util.stream.Collectors; import javax.xml.XMLConstants; -import javax.xml.catalog.CatalogFeatures; -import javax.xml.catalog.CatalogFeatures.Feature; -import javax.xml.catalog.CatalogManager; import javax.xml.namespace.QName; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; @@ -65,7 +56,6 @@ import javax.xml.transform.sax.SAXTransformerFactory; import javax.xml.transform.sax.TransformerHandler; import javax.xml.transform.stream.StreamSource; import javax.xml.validation.SchemaFactory; -import javax.xml.ws.WebServiceException; import javax.xml.xpath.XPathFactory; import javax.xml.xpath.XPathFactoryConfigurationException; import org.w3c.dom.Attr; @@ -78,6 +68,8 @@ import org.xml.sax.EntityResolver; import org.xml.sax.ErrorHandler; import org.xml.sax.InputSource; import org.xml.sax.SAXException; +import org.xml.sax.SAXNotRecognizedException; +import org.xml.sax.SAXNotSupportedException; import org.xml.sax.SAXParseException; import org.xml.sax.XMLReader; @@ -184,7 +176,7 @@ public class XmlUtil { } public static List parseTokenList(String tokenList) { - List result = new ArrayList(); + List result = new ArrayList<>(); StringTokenizer tokenizer = new StringTokenizer(tokenList, " "); while (tokenizer.hasMoreTokens()) { result.add(tokenizer.nextToken()); @@ -247,6 +239,7 @@ public class XmlUtil { /** * Creates a new identity transformer. + * @return */ public static Transformer newTransformer() { try { @@ -258,9 +251,17 @@ public class XmlUtil { /** * Performs identity transformation. + * @param + * @param src + * @param result + * @return + * @throws javax.xml.transform.TransformerException + * @throws java.io.IOException + * @throws org.xml.sax.SAXException + * @throws javax.xml.parsers.ParserConfigurationException */ - public static - T identityTransform(Source src, T result) throws TransformerException, SAXException, ParserConfigurationException, IOException { + public static T identityTransform(Source src, T result) + throws TransformerException, SAXException, ParserConfigurationException, IOException { if (src instanceof StreamSource) { // work around a bug in JAXP in JDK6u4 and earlier where the namespace processing // is not turned on by default @@ -286,68 +287,25 @@ public class XmlUtil { return is; } - /* - * Gets an EntityResolver using XML catalog - */ - public static EntityResolver createEntityResolver(@Nullable URL catalogUrl) { - ArrayList urlsArray = new ArrayList(); - EntityResolver er; - if (catalogUrl != null) { - urlsArray.add(catalogUrl); - } - try { - er = createCatalogResolver(urlsArray); - } catch (Exception e) { - throw new ServerRtException("server.rt.err",e); - } - return er; + /** + * Gets an EntityResolver using XML catalog + * + * @param catalogUrl + * @return + */ + public static EntityResolver createEntityResolver(@Nullable URL catalogUrl) { + return XmlCatalogUtil.createEntityResolver(catalogUrl); } /** * Gets a default EntityResolver for catalog at META-INF/jaxws-catalog.xml + * + * @return */ public static EntityResolver createDefaultCatalogResolver() { - EntityResolver er; - try { - /** - * Gets a URLs for catalog defined at META-INF/jaxws-catalog.xml - */ - ClassLoader cl = Thread.currentThread().getContextClassLoader(); - Enumeration catalogEnum; - if (cl == null) { - catalogEnum = ClassLoader.getSystemResources("META-INF/jax-ws-catalog.xml"); - } else { - catalogEnum = cl.getResources("META-INF/jax-ws-catalog.xml"); - } - er = createCatalogResolver(Collections.list(catalogEnum)); - } catch (Exception e) { - throw new WebServiceException(e); - } - - return er; + return XmlCatalogUtil.createDefaultCatalogResolver(); } - /** - * Instantiate catalog resolver using new catalog API (javax.xml.catalog.*) - * added in JDK9. Usage of new API removes dependency on internal API - * (com.sun.org.apache.xml.internal) for modular runtime. - */ - private static EntityResolver createCatalogResolver(ArrayList urls) throws Exception { - // Prepare array of catalog URIs - URI[] uris = urls.stream() - .map(u -> URI.create(u.toExternalForm())) - .toArray(URI[]::new); - - //Create CatalogResolver with new JDK9+ API - return (EntityResolver) CatalogManager.catalogResolver(catalogFeatures, uris); - } - - // Cache CatalogFeatures instance for future usages. - // Resolve feature is set to "continue" value for backward compatibility. - private static CatalogFeatures catalogFeatures = CatalogFeatures.builder() - .with(Feature.RESOLVE, "continue") - .build(); - /** * {@link ErrorHandler} that always treat the error as fatal. */ @@ -391,7 +349,7 @@ public class XmlUtil { SAXParserFactory factory = SAXParserFactory.newInstance(); try { factory.setFeature(XMLConstants.FEATURE_SECURE_PROCESSING, !xmlSecurityDisabled(disableSecurity)); - } catch (Exception e) { + } catch (ParserConfigurationException | SAXNotRecognizedException | SAXNotSupportedException e) { LOGGER.log(Level.WARNING, "Factory [{0}] doesn't support secure xml processing!", new Object[]{factory.getClass().getName()}); } return factory; diff --git a/jaxws/src/java.xml.ws/share/classes/javax/xml/soap/FactoryFinder.java b/jaxws/src/java.xml.ws/share/classes/javax/xml/soap/FactoryFinder.java index ef5500a0627..190471cd9d5 100644 --- a/jaxws/src/java.xml.ws/share/classes/javax/xml/soap/FactoryFinder.java +++ b/jaxws/src/java.xml.ws/share/classes/javax/xml/soap/FactoryFinder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -245,10 +245,14 @@ class FactoryFinder { return null; } - private static String getSystemProperty(String property) { + private static String getSystemProperty(final String property) { logger.log(Level.FINE, "Checking system property {0}", property); - String value = AccessController.doPrivileged( - (PrivilegedAction) () -> System.getProperty(property)); + String value = AccessController.doPrivileged(new PrivilegedAction() { + @Override + public String run() { + return System.getProperty(property); + } + }); logFound(value); return value; } diff --git a/jaxws/src/java.xml.ws/share/classes/module-info.java b/jaxws/src/java.xml.ws/share/classes/module-info.java index 4a0175eeae2..a1f9cfb66bb 100644 --- a/jaxws/src/java.xml.ws/share/classes/module-info.java +++ b/jaxws/src/java.xml.ws/share/classes/module-info.java @@ -26,7 +26,11 @@ /** * Defines the Java API for XML-Based Web Services (JAX-WS), and * the Web Services Metadata API. + * + * @moduleGraph + * @since 9 */ +@Deprecated(since="9", forRemoval=true) module java.xml.ws { requires transitive java.activation; requires transitive java.xml; @@ -36,6 +40,7 @@ module java.xml.ws { requires java.logging; requires java.management; requires jdk.httpserver; + requires jdk.unsupported; uses javax.xml.ws.spi.Provider; uses javax.xml.soap.MessageFactory; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/JJavaName.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/JJavaName.java index 1af2c5d9a31..fe7813ebc4e 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/JJavaName.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/JJavaName.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -85,8 +85,8 @@ public class JJavaName { * ("my_children","MyChildren","myChildren", and "MY-CHILDREN", "CODE003-children" respectively) *

    * Although this method only works for English words, it handles non-English - * words gracefully (by just returning it as-is.) For example, "日本語" - * will be returned as-is without modified, not "日本語s" + * words gracefully (by just returning it as-is.) For example, "{@literal 日本語}" + * will be returned as-is without modified, not "{@literal 日本語s}" *

    * This method doesn't handle suffixes very well. For example, passing * "person56" will return "person56s", not "people56". diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/JModuleDirective.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/JModuleDirective.java index 472aa508b28..af71cbd9218 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/JModuleDirective.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/JModuleDirective.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -101,7 +101,7 @@ public abstract class JModuleDirective { */ @Override public int hashCode() { - return 97 * (Integer.hashCode(getType().ordinal() + 1)) + name.hashCode(); + return 97 * (Integer.valueOf(getType().ordinal() + 1)).hashCode() + name.hashCode(); } /** diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/util/JavadocEscapeWriter.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/util/JavadocEscapeWriter.java index 9a9fae31705..a824946273c 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/util/JavadocEscapeWriter.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/util/JavadocEscapeWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,7 +37,7 @@ import java.io.Writer; * *

    * Note that this class doesn't escape other Unicode characters - * that are typically unsafe. For example, 愛 (A kanji + * that are typically unsafe. For example, {@literal 愛} (A kanji * that means "love") can be considered as unsafe because * javac with English Windows cannot accept this character in the * source code. diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/istack/internal/tools/DefaultAuthenticator.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/istack/internal/tools/DefaultAuthenticator.java index d4feaeecb91..c149697ea1c 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/istack/internal/tools/DefaultAuthenticator.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/istack/internal/tools/DefaultAuthenticator.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,6 +33,7 @@ import java.io.IOException; import java.io.InputStreamReader; import java.io.UnsupportedEncodingException; import java.lang.reflect.Field; +import java.lang.reflect.Method; import java.net.Authenticator; import java.net.Authenticator.RequestorType; import java.net.MalformedURLException; @@ -42,6 +43,8 @@ import java.net.URLDecoder; import java.net.URLEncoder; import java.security.AccessController; import java.security.PrivilegedAction; +import java.security.PrivilegedActionException; +import java.security.PrivilegedExceptionAction; import java.util.ArrayList; import java.util.List; import java.util.logging.Level; @@ -56,11 +59,12 @@ import org.xml.sax.helpers.LocatorImpl; */ public class DefaultAuthenticator extends Authenticator { + private static final Logger LOGGER = Logger.getLogger(DefaultAuthenticator.class.getName()); private static DefaultAuthenticator instance; private static Authenticator systemAuthenticator = getCurrentAuthenticator(); private String proxyUser; private String proxyPasswd; - private final List authInfo = new ArrayList(); + private final List authInfo = new ArrayList<>(); private static int counter = 0; DefaultAuthenticator() { @@ -145,10 +149,7 @@ public class DefaultAuthenticator extends Authenticator { fi = new FileInputStream(f); is = new InputStreamReader(fi, "UTF-8"); in = new BufferedReader(is); - } catch (UnsupportedEncodingException e) { - listener.onError(e, locator); - return; - } catch (FileNotFoundException e) { + } catch (UnsupportedEncodingException | FileNotFoundException e) { listener.onError(e, locator); return; } @@ -170,7 +171,7 @@ public class DefaultAuthenticator extends Authenticator { } } catch (IOException e) { listener.onError(e, locator); - Logger.getLogger(DefaultAuthenticator.class.getName()).log(Level.SEVERE, e.getMessage(), e); + LOGGER.log(Level.SEVERE, e.getMessage(), e); } } finally { try { @@ -184,7 +185,7 @@ public class DefaultAuthenticator extends Authenticator { fi.close(); } } catch (IOException ex) { - Logger.getLogger(DefaultAuthenticator.class.getName()).log(Level.SEVERE, null, ex); + LOGGER.log(Level.SEVERE, null, ex); } } } @@ -225,6 +226,29 @@ public class DefaultAuthenticator extends Authenticator { } static Authenticator getCurrentAuthenticator() { + try { + return AccessController.doPrivileged(new PrivilegedExceptionAction() { + @Override + public Authenticator run() throws Exception { + Method method = Authenticator.class.getMethod("getDefault"); + return (Authenticator) method.invoke(null); + } + + }); + } catch (PrivilegedActionException pae) { + if (LOGGER.isLoggable(Level.FINE)) { + LOGGER.log(Level.FINE, null, pae); + } + Exception ex = pae.getException(); + if (!(ex instanceof NoSuchMethodException)) { + // if Authenticator.getDefault has not been found, + // we likely didn't get through sec, so return null + // and don't care about JDK version we're on + return null; + } + // or we're on JDK <9, so let's continue the old way... + } + final Field f = getTheAuthenticator(); if (f == null) { return null; @@ -239,7 +263,7 @@ public class DefaultAuthenticator extends Authenticator { } }); return (Authenticator) f.get(null); - } catch (Exception ex) { + } catch (IllegalAccessException | IllegalArgumentException ex) { return null; } finally { AccessController.doPrivileged(new PrivilegedAction() { @@ -255,7 +279,7 @@ public class DefaultAuthenticator extends Authenticator { private static Field getTheAuthenticator() { try { return Authenticator.class.getDeclaredField("theAuthenticator"); - } catch (Exception ex) { + } catch (NoSuchFieldException | SecurityException ex) { return null; } } @@ -277,7 +301,7 @@ public class DefaultAuthenticator extends Authenticator { @Override public void onError(Exception e, Locator loc) { System.err.println(getLocationString(loc) + ": " + e.getMessage()); - Logger.getLogger(DefaultAuthenticator.class.getName()).log(Level.SEVERE, e.getMessage(), e); + LOGGER.log(Level.SEVERE, e.getMessage(), e); } private String getLocationString(Locator l) { diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/istack/internal/tools/SecureLoader.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/istack/internal/tools/SecureLoader.java index 4c08e4da25f..4061f18702d 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/istack/internal/tools/SecureLoader.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/istack/internal/tools/SecureLoader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,9 @@ package com.sun.istack.internal.tools; +import java.security.AccessController; +import java.security.PrivilegedAction; + /** * Class defined for safe calls of getClassLoader methods of any kind (context/system/class * classloader. This MUST be package private and defined in every package which @@ -37,9 +40,10 @@ class SecureLoader { if (System.getSecurityManager() == null) { return Thread.currentThread().getContextClassLoader(); } else { - return (ClassLoader) java.security.AccessController.doPrivileged( - new java.security.PrivilegedAction() { - public java.lang.Object run() { + return AccessController.doPrivileged( + new PrivilegedAction() { + @Override + public ClassLoader run() { return Thread.currentThread().getContextClassLoader(); } }); @@ -50,9 +54,10 @@ class SecureLoader { if (System.getSecurityManager() == null) { return c.getClassLoader(); } else { - return (ClassLoader) java.security.AccessController.doPrivileged( - new java.security.PrivilegedAction() { - public java.lang.Object run() { + return AccessController.doPrivileged( + new PrivilegedAction() { + @Override + public ClassLoader run() { return c.getClassLoader(); } }); @@ -63,9 +68,10 @@ class SecureLoader { if (System.getSecurityManager() == null) { return ClassLoader.getSystemClassLoader(); } else { - return (ClassLoader) java.security.AccessController.doPrivileged( - new java.security.PrivilegedAction() { - public java.lang.Object run() { + return AccessController.doPrivileged( + new PrivilegedAction() { + @Override + public ClassLoader run() { return ClassLoader.getSystemClassLoader(); } }); @@ -76,9 +82,10 @@ class SecureLoader { if (System.getSecurityManager() == null) { return cl.getParent(); } else { - return (ClassLoader) java.security.AccessController.doPrivileged( - new java.security.PrivilegedAction() { - public java.lang.Object run() { + return AccessController.doPrivileged( + new PrivilegedAction() { + @Override + public ClassLoader run() { return cl.getParent(); } }); @@ -89,9 +96,10 @@ class SecureLoader { if (System.getSecurityManager() == null) { Thread.currentThread().setContextClassLoader(cl); } else { - java.security.AccessController.doPrivileged( - new java.security.PrivilegedAction() { - public java.lang.Object run() { + AccessController.doPrivileged( + new PrivilegedAction() { + @Override + public ClassLoader run() { Thread.currentThread().setContextClassLoader(cl); return null; } diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle.properties index 0cc3e21ee84..0f2b377cc5b 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -30,10 +30,10 @@ BASEDIR_DOESNT_EXIST = \ Non-existent directory: {0} VERSION = \ - schemagen 2.3.0-SNAPSHOT + schemagen 2.3.0-b170215.1712 FULLVERSION = \ - schemagen full version "2.3.0-SNAPSHOT" + schemagen full version "2.3.0-b170215.1712" USAGE = \ Usage: schemagen [-options ...] \n\ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_de.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_de.properties index 3158ce32236..be77744f1df 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_de.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = Nicht erkanntes {0} in Zeile {1} Spalte {2} BASEDIR_DOESNT_EXIST = Nicht vorhandenes Verzeichnis: {0} -VERSION = schemagen 2.3.0-SNAPSHOT +VERSION = schemagen 2.3.0-b170215.1712 -FULLVERSION = schemagen vollst\u00E4ndige Version "2.3.0-SNAPSHOT" +FULLVERSION = schemagen vollst\u00E4ndige Version "2.3.0-b170215.1712" USAGE = Verwendung: schemagen [-options ...] \nOptionen: \n\\ \\ \\ \\ -d : Gibt an, wo die von Prozessor und javac generierten Klassendateien gespeichert werden sollen\n\\ \\ \\ \\ -cp : Gibt an, wo die vom Benutzer angegebenen Dateien gespeichert sind\n\\ \\ \\ \\ -classpath : Gibt an, wo die vom Benutzer angegebenen Dateien gespeichert sind\n\\ \\ \\ \\ -encoding : Gibt die Codierung f\u00FCr die Annotationsverarbeitung/den javac-Aufruf an \n\\ \\ \\ \\ -episode : Generiert Episodendatei f\u00FCr separate Kompilierung\n\\ \\ \\ \\ -version : Zeigt Versionsinformation an\n\\ \\ \\ \\ -fullversion : Zeigt vollst\u00E4ndige Versionsinformationen an\n\\ \\ \\ \\ -help : Zeigt diese Verwendungsmeldung an diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_es.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_es.properties index 81d9274dc3c..632f594e2b5 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_es.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = Aparece un {0} inesperado en la l\u00EDnea {1} y la colu BASEDIR_DOESNT_EXIST = Directorio no existente: {0} -VERSION = schemagen 2.3.0-SNAPSHOT +VERSION = schemagen 2.3.0-b170215.1712 -FULLVERSION = versi\u00F3n completa de schemagen "2.3.0-SNAPSHOT" +FULLVERSION = versi\u00F3n completa de schemagen "2.3.0-b170215.1712" USAGE = Sintaxis: schemagen [-options ...] \nOpciones: \n\\ \\ \\ \\ -d : especifique d\u00F3nde se colocan los archivos de clase generados por javac y el procesador\n\\ \\ \\ \\ -cp : especifique d\u00F3nde se encuentran los archivos especificados por el usuario\n\\ \\ \\ \\ -encoding : especifique la codificaci\u00F3n que se va a utilizar para el procesamiento de anotaciones/llamada de javac\n\\ \\ \\ \\ -episode : genera un archivo de episodio para una compilaci\u00F3n diferente\n\\ \\ \\ \\ -version : muestra la informaci\u00F3n de la versi\u00F3n\n\\ \\ \\ \\ -fullversion : muestra la informaci\u00F3n completa de la versi\u00F3n\n\\ \\ \\ \\ -help : muestra este mensaje de sintaxis diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_fr.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_fr.properties index 597ce0e512b..6acdbba38d8 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_fr.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = Un \u00E9l\u00E9ment {0} inattendu appara\u00EEt \u00E0 BASEDIR_DOESNT_EXIST = R\u00E9pertoire {0} inexistant -VERSION = schemagen 2.3.0-SNAPSHOT +VERSION = schemagen 2.3.0-b170215.1712 -FULLVERSION = version compl\u00E8te de schemagen "2.3.0-SNAPSHOT" +FULLVERSION = version compl\u00E8te de schemagen "2.3.0-b170215.1712" USAGE = Syntaxe : schemagen [-options ...] \nOptions : \n\ \ \ \ -d : indiquez o\u00F9 placer les fichiers de classe g\u00E9n\u00E9r\u00E9s par le processeur et le compilateur javac\n\ \ \ \ -cp : indiquez o\u00F9 trouver les fichiers sp\u00E9cifi\u00E9s par l'utilisateur\n\ \ \ \ -classpath : indiquez o\u00F9 trouver les fichiers sp\u00E9cifi\u00E9s par l'utilisateur\n\ \ \ \ -encoding : indiquez l'encodage \u00E0 utiliser pour l'appel de javac/traitement de l'annotation \n\ \ \ \ -episode : g\u00E9n\u00E9rez un fichier d'\u00E9pisode pour la compilation s\u00E9par\u00E9e\n\ \ \ \ -version : affichez les informations de version\n\ \ \ \ -fullversion : affichez les informations compl\u00E8tes de version\n\ \ \ \ -help : affichez ce message de syntaxe diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_it.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_it.properties index c7ef575e06e..00fe597645f 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_it.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = {0} imprevisto visualizzato sulla riga {1} colonna {2} BASEDIR_DOESNT_EXIST = Directory non esistente: {0} -VERSION = schemagen 2.3.0-SNAPSHOT +VERSION = schemagen 2.3.0-b170215.1712 -FULLVERSION = versione completa schemagen "2.3.0-SNAPSHOT" +FULLVERSION = versione completa schemagen "2.3.0-b170215.1712" USAGE = Uso: schemagen [-options ...] \nOpzioni: \n\ \ \ \ -d : specifica dove posizionare il processore e i file della classe generata javac\n\ \ \ \ -cp : specifica dove trovare i file specificati dall'utente\n\ \ \ \ -classpath : specifica dove trovare i file specificati dall'utente\n\ \ \ \ -encoding : specifica la codifica da usare per l'elaborazione dell'annotazione/richiamo javac \n\ \ \ \ -episode : genera il file di episodio per la compilazione separata\n\ \ \ \ -version : visualizza le informazioni sulla versione\n\ \ \ \ -fullversion : visualizza le informazioni sulla versione completa\n\ \ \ \ -help : visualizza questo messaggio sull'uso diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_ja.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_ja.properties index e07c234ff85..638e47d9ce5 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_ja.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = \u4E88\u671F\u3057\u306A\u3044{0}\u304C\u884C{1}\u3001\u BASEDIR_DOESNT_EXIST = \u30C7\u30A3\u30EC\u30AF\u30C8\u30EA\u304C\u5B58\u5728\u3057\u307E\u305B\u3093: {0} -VERSION = schemagen 2.3.0-SNAPSHOT +VERSION = schemagen 2.3.0-b170215.1712 -FULLVERSION = schemagen\u30D5\u30EB\u30FB\u30D0\u30FC\u30B8\u30E7\u30F3"2.3.0-SNAPSHOT" +FULLVERSION = schemagen\u30D5\u30EB\u30FB\u30D0\u30FC\u30B8\u30E7\u30F3"2.3.0-b170215.1712" USAGE = \u4F7F\u7528\u65B9\u6CD5: schemagen [-options ...] \n\u30AA\u30D7\u30B7\u30E7\u30F3: \n\ \ \ \ -d : \u30D7\u30ED\u30BB\u30C3\u30B5\u304A\u3088\u3073javac\u304C\u751F\u6210\u3057\u305F\u30AF\u30E9\u30B9\u30FB\u30D5\u30A1\u30A4\u30EB\u3092\u7F6E\u304F\u4F4D\u7F6E\u3092\u6307\u5B9A\u3057\u307E\u3059\n\ \ \ \ -cp : \u30E6\u30FC\u30B6\u30FC\u304C\u6307\u5B9A\u3057\u305F\u30D5\u30A1\u30A4\u30EB\u3092\u691C\u7D22\u3059\u308B\u4F4D\u7F6E\u3092\u6307\u5B9A\u3057\u307E\u3059\n\ \ \ \ -classpath : \u30E6\u30FC\u30B6\u30FC\u304C\u6307\u5B9A\u3057\u305F\u30D5\u30A1\u30A4\u30EB\u3092\u691C\u7D22\u3059\u308B\u4F4D\u7F6E\u3092\u6307\u5B9A\u3057\u307E\u3059\n\ \ \ \ -encoding : \u6CE8\u91C8\u51E6\u7406/javac\u547C\u51FA\u3057\u306B\u4F7F\u7528\u3059\u308B\u30A8\u30F3\u30B3\u30FC\u30C7\u30A3\u30F3\u30B0\u3092\u6307\u5B9A\u3057\u307E\u3059\n\ \ \ \ -episode : \u30B3\u30F3\u30D1\u30A4\u30EB\u3054\u3068\u306B\u30A8\u30D4\u30BD\u30FC\u30C9\u30FB\u30D5\u30A1\u30A4\u30EB\u3092\u751F\u6210\u3057\u307E\u3059\n\ \ \ \ -version : \u30D0\u30FC\u30B8\u30E7\u30F3\u60C5\u5831\u3092\u8868\u793A\u3057\u307E\u3059\n\ \ \ \ -fullversion : \u30D5\u30EB\u30FB\u30D0\u30FC\u30B8\u30E7\u30F3\u60C5\u5831\u3092\u8868\u793A\u3057\u307E\u3059\n\ \ \ \ -help : \u3053\u306E\u4F7F\u7528\u4F8B\u30E1\u30C3\u30BB\u30FC\u30B8\u3092\u8868\u793A\u3057\u307E\u3059 diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_ko.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_ko.properties index f4e5fa4d62e..416931124b3 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_ko.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = \uC608\uC0C1\uCE58 \uC54A\uC740 {0}\uC774(\uAC00) {1}\uD BASEDIR_DOESNT_EXIST = \uC874\uC7AC\uD558\uC9C0 \uC54A\uB294 \uB514\uB809\uD1A0\uB9AC: {0} -VERSION = schemagen 2.3.0-SNAPSHOT +VERSION = schemagen 2.3.0-b170215.1712 -FULLVERSION = schemagen \uC815\uC2DD \uBC84\uC804 "2.3.0-SNAPSHOT" +FULLVERSION = schemagen \uC815\uC2DD \uBC84\uC804 "2.3.0-b170215.1712" USAGE = \uC0AC\uC6A9\uBC95: schemagen [-options ...] \n\uC635\uC158: \n\ \ \ \ -d : \uD504\uB85C\uC138\uC11C \uBC0F javac\uC5D0\uC11C \uC0DD\uC131\uD55C \uD074\uB798\uC2A4 \uD30C\uC77C\uC744 \uBC30\uCE58\uD560 \uC704\uCE58\uB97C \uC9C0\uC815\uD569\uB2C8\uB2E4.\n\ \ \ \ -cp : \uC0AC\uC6A9\uC790\uAC00 \uC9C0\uC815\uD55C \uD30C\uC77C\uC744 \uCC3E\uC744 \uC704\uCE58\uB97C \uC9C0\uC815\uD569\uB2C8\uB2E4.\n\ \ \ \ -classpath : \uC0AC\uC6A9\uC790\uAC00 \uC9C0\uC815\uD55C \uD30C\uC77C\uC744 \uCC3E\uC744 \uC704\uCE58\uB97C \uC9C0\uC815\uD569\uB2C8\uB2E4.\n\ \ \ \ -encoding : \uC8FC\uC11D \uCC98\uB9AC/javac \uD638\uCD9C\uC5D0 \uC0AC\uC6A9\uD560 \uC778\uCF54\uB529\uC744 \uC9C0\uC815\uD569\uB2C8\uB2E4. \n\ \ \ \ -episode : \uBCC4\uB3C4 \uCEF4\uD30C\uC77C\uC744 \uC704\uD574 episode \uD30C\uC77C\uC744 \uC0DD\uC131\uD569\uB2C8\uB2E4.\n\ \ \ \ -version : \uBC84\uC804 \uC815\uBCF4\uB97C \uD45C\uC2DC\uD569\uB2C8\uB2E4.\n\ \ \ \ -fullversion : \uC815\uC2DD \uBC84\uC804 \uC815\uBCF4\uB97C \uD45C\uC2DC\uD569\uB2C8\uB2E4.\n\ \ \ \ -help : \uC774 \uC0AC\uC6A9\uBC95 \uBA54\uC2DC\uC9C0\uB97C \uD45C\uC2DC\uD569\uB2C8\uB2E4. diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_pt_BR.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_pt_BR.properties index d56ca3894d5..6da2bc93337 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_pt_BR.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = {0} inesperado aparece na linha {1} coluna {2} BASEDIR_DOESNT_EXIST = Diret\u00F3rio n\u00E3o existente: {0} -VERSION = gera\u00E7\u00E3o do esquema 2.3.0-SNAPSHOT +VERSION = gera\u00E7\u00E3o do esquema 2.3.0-b170215.1712 -FULLVERSION = vers\u00E3o completa da gera\u00E7\u00E3o do esquema "2.3.0-SNAPSHOT" +FULLVERSION = vers\u00E3o completa da gera\u00E7\u00E3o do esquema "2.3.0-b170215.1712" USAGE = Uso: gera\u00E7\u00E3o do esquema [-options ...] \nOp\u00E7\u00F5es: \n\\ \\ \\ \\ -d : especificar onde colocar o processador e os arquivos da classe gerados por javac\n\\ \\ \\ \\ -cp : especificar onde localizar arquivos especificados pelo usu\u00E1rio\n\\ \\ \\ \\ -classpath : especificar onde localizar os arquivos especificados pelo usu\u00E1rio\n\\ \\ \\ \\ -encoding : especificar codifica\u00E7\u00E3o a ser usada para processamento de anota\u00E7\u00E3o/chamada javac \n\\ \\ \\ \\ -episode : gerar arquivo do epis\u00F3dio para compila\u00E7\u00E3o separada\n\\ \\ \\ \\ -version : exibir informa\u00E7\u00F5es da vers\u00E3o\n\\ \\ \\ \\ -fullversion : exibir informa\u00E7\u00F5es da vers\u00E3o completa\n\\ \\ \\ \\ -help : exibir esta mensagem de uso diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_zh_CN.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_zh_CN.properties index c1be9f0f704..beed169c9ae 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_zh_CN.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = \u5728\u7B2C {1} \u884C, \u7B2C {2} \u5217\u51FA\u73B0\u BASEDIR_DOESNT_EXIST = \u4E0D\u5B58\u5728\u7684\u76EE\u5F55: {0} -VERSION = schemagen 2.3.0-SNAPSHOT +VERSION = schemagen 2.3.0-b170215.1712 -FULLVERSION = schemagen \u5B8C\u6574\u7248\u672C "2.3.0-SNAPSHOT" +FULLVERSION = schemagen \u5B8C\u6574\u7248\u672C "2.3.0-b170215.1712" USAGE = \u7528\u6CD5: schemagen [-options ...] \n\u9009\u9879: \n\ \ \ \ -d : \u6307\u5B9A\u653E\u7F6E\u5904\u7406\u7A0B\u5E8F\u548C javac \u751F\u6210\u7684\u7C7B\u6587\u4EF6\u7684\u4F4D\u7F6E\n\ \ \ \ -cp : \u6307\u5B9A\u67E5\u627E\u7528\u6237\u6307\u5B9A\u6587\u4EF6\u7684\u4F4D\u7F6E\n\ \ \ \ -classpath : \u6307\u5B9A\u67E5\u627E\u7528\u6237\u6307\u5B9A\u6587\u4EF6\u7684\u4F4D\u7F6E\n\ \ \ \ -encoding : \u6307\u5B9A\u7528\u4E8E\u6CE8\u91CA\u5904\u7406/javac \u8C03\u7528\u7684\u7F16\u7801\n\ \ \ \ -episode : \u751F\u6210\u7247\u6BB5\u6587\u4EF6\u4EE5\u4F9B\u5355\u72EC\u7F16\u8BD1\n\ \ \ \ -version : \u663E\u793A\u7248\u672C\u4FE1\u606F\n\ \ \ \ -fullversion : \u663E\u793A\u5B8C\u6574\u7684\u7248\u672C\u4FE1\u606F\n\ \ \ \ -help : \u663E\u793A\u6B64\u7528\u6CD5\u6D88\u606F diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_zh_TW.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_zh_TW.properties index dcd7976be7c..01744696586 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_zh_TW.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/MessageBundle_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,8 @@ UNEXPECTED_NGCC_TOKEN = \u672A\u9810\u671F\u7684 {0} \u986F\u793A\u65BC\u884C {1 BASEDIR_DOESNT_EXIST = \u4E0D\u5B58\u5728\u7684\u76EE\u9304: {0} -VERSION = schemagen 2.3.0-SNAPSHOT +VERSION = schemagen 2.3.0-b170215.1712 -FULLVERSION = schemagen \u5B8C\u6574\u7248\u672C "2.3.0-SNAPSHOT" +FULLVERSION = schemagen \u5B8C\u6574\u7248\u672C "2.3.0-b170215.1712" USAGE = \u7528\u6CD5: schemagen [-options ...] \n\u9078\u9805: \n\\ \\ \\ \\ -d : \u6307\u5B9A\u8655\u7406\u5668\u4EE5\u53CA javac \u7522\u751F\u7684\u985E\u5225\u6A94\u6848\u653E\u7F6E\u4F4D\u7F6E\n\\ \\ \\ \\ -cp : \u6307\u5B9A\u8981\u5C0B\u627E\u4F7F\u7528\u8005\u6307\u5B9A\u6A94\u6848\u7684\u4F4D\u7F6E\n\\ \\ \\ \\ -classpath : \u6307\u5B9A\u8981\u5C0B\u627E\u4F7F\u7528\u8005\u6307\u5B9A\u6A94\u6848\u7684\u4F4D\u7F6E\n\\ \\ \\ \\ -encoding : \u6307\u5B9A\u8981\u7528\u65BC\u8A3B\u89E3\u8655\u7406/javac \u547C\u53EB\u7684\u7DE8\u78BC \n\\ \\ \\ \\ -episode : \u7522\u751F\u7368\u7ACB\u7DE8\u8B6F\u7684\u4E8B\u4EF6 (episode) \u6A94\u6848\n\\ \\ \\ \\ -version : \u986F\u793A\u7248\u672C\u8CC7\u8A0A\n\\ \\ \\ \\ -fullversion : \u986F\u793A\u5B8C\u6574\u7248\u672C\u8CC7\u8A0A\n\\ \\ \\ \\ -help : \u986F\u793A\u6B64\u7528\u6CD5\u8A0A\u606F diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/ap/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/ap/package-info.java new file mode 100644 index 00000000000..52b29b23e93 --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/ap/package-info.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Annotation Processing related code. + * + * This package hosts a driver that runs annotation processing for java-to-schema processing, + * and additional implementations that deal primarily with AP. + */ +package com.sun.tools.internal.jxc.ap; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/ap/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/ap/package.html deleted file mode 100644 index 8f893b55ef2..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/jxc/ap/package.html +++ /dev/null @@ -1,33 +0,0 @@ - - - - - Annotation Processing related code. - - This package hosts a driver that runs annotation processing for java-to-schema processing, - and additional implementations that deal primarily with AP. - - diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/CatalogUtil.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/CatalogUtil.java new file mode 100644 index 00000000000..0d3dbc5839f --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/CatalogUtil.java @@ -0,0 +1,53 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package com.sun.tools.internal.xjc; + +import java.io.File; +import java.io.IOException; +import java.net.URI; +import java.util.ArrayList; +import javax.xml.catalog.CatalogFeatures; +import javax.xml.catalog.CatalogFeatures.Feature; +import javax.xml.catalog.CatalogManager; +import org.xml.sax.EntityResolver; + +/** + * + * @author lukas + */ +final class CatalogUtil { + + // Cache CatalogFeatures instance for future usages. + // Resolve feature is set to "continue" value for backward compatibility. + private static final CatalogFeatures CATALOG_FEATURES = CatalogFeatures.builder() + .with(Feature.RESOLVE, "continue") + .build(); + + static EntityResolver getCatalog(EntityResolver entityResolver, File catalogFile, ArrayList catalogUrls) throws IOException { + return CatalogManager.catalogResolver( + CATALOG_FEATURES, catalogUrls.stream().toArray(URI[]::new)); + } +} diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle.properties index 6a418f594ad..fa3f5b2f8f3 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -173,20 +173,20 @@ Driver.CompilingSchema = \ Driver.FailedToGenerateCode = \ Failed to produce code. -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn Driver.FilePrologComment = \ - This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.3.0-SNAPSHOT \n\ + This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.3.0-b170215.1712 \n\ See https://jaxb.java.net/ \n\ Any modifications to this file will be lost upon recompilation of the source schema. \n\ Generated on: {0} \n Driver.Version = \ - xjc 2.3.0-SNAPSHOT + xjc 2.3.0-b170215.1712 Driver.FullVersion = \ - xjc full version "2.3.0-SNAPSHOT" + xjc full version "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_de.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_de.properties index 7d645e92472..57e1bb38224 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_de.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_de.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -127,14 +127,14 @@ Driver.CompilingSchema = Ein Schema wird kompiliert ... Driver.FailedToGenerateCode = Code konnte nicht erzeugt werden. -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = Diese Datei wurde mit der JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.3.0-SNAPSHOT generiert \nSiehe https://jaxb.java.net/ \n\u00c4nderungen an dieser Datei gehen bei einer Neukompilierung des Quellschemas verloren. \nGeneriert: {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = Diese Datei wurde mit der JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.3.0-b170215.1712 generiert \nSiehe https://jaxb.java.net/ \n\u00c4nderungen an dieser Datei gehen bei einer Neukompilierung des Quellschemas verloren. \nGeneriert: {0} \n -Driver.Version = xjc 2.3.0-SNAPSHOT +Driver.Version = xjc 2.3.0-b170215.1712 -Driver.FullVersion = xjc vollst\u00E4ndige Version "2.3.0-SNAPSHOT" +Driver.FullVersion = xjc vollst\u00E4ndige Version "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_es.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_es.properties index e7196a558f3..63de1fab45b 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_es.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_es.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -127,14 +127,14 @@ Driver.CompilingSchema = Compilando un esquema... Driver.FailedToGenerateCode = Fallo al producir c\u00f3digo. -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = Este archivo ha sido generado por la arquitectura JavaTM para la implantaci\u00f3n de la referencia de enlace (JAXB) XML v2.3.0-SNAPSHOT \nVisite https://jaxb.java.net/ \nTodas las modificaciones realizadas en este archivo se perder\u00e1n si se vuelve a compilar el esquema de origen. \nGenerado el: {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = Este archivo ha sido generado por la arquitectura JavaTM para la implantaci\u00f3n de la referencia de enlace (JAXB) XML v2.3.0-b170215.1712 \nVisite https://jaxb.java.net/ \nTodas las modificaciones realizadas en este archivo se perder\u00e1n si se vuelve a compilar el esquema de origen. \nGenerado el: {0} \n -Driver.Version = xjc 2.3.0-SNAPSHOT +Driver.Version = xjc 2.3.0-b170215.1712 -Driver.FullVersion = versi\u00F3n completa de xjc "2.3.0-SNAPSHOT" +Driver.FullVersion = versi\u00F3n completa de xjc "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_fr.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_fr.properties index 6a1719d4042..5ad5ff87055 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_fr.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_fr.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -131,14 +131,14 @@ Driver.CompilingSchema = compilation d'un sch\u00e9ma... Driver.FailedToGenerateCode = Echec de la production du code. -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = Ce fichier a \u00e9t\u00e9 g\u00e9n\u00e9r\u00e9 par l''impl\u00e9mentation de r\u00e9f\u00e9rence JavaTM Architecture for XML Binding (JAXB), v2.3.0-SNAPSHOT \nVoir https://jaxb.java.net/ \nToute modification apport\u00e9e \u00e0 ce fichier sera perdue lors de la recompilation du sch\u00e9ma source. \nG\u00e9n\u00e9r\u00e9 le : {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = Ce fichier a \u00e9t\u00e9 g\u00e9n\u00e9r\u00e9 par l''impl\u00e9mentation de r\u00e9f\u00e9rence JavaTM Architecture for XML Binding (JAXB), v2.3.0-b170215.1712 \nVoir https://jaxb.java.net/ \nToute modification apport\u00e9e \u00e0 ce fichier sera perdue lors de la recompilation du sch\u00e9ma source. \nG\u00e9n\u00e9r\u00e9 le : {0} \n -Driver.Version = xjc 2.3.0-SNAPSHOT +Driver.Version = xjc 2.3.0-b170215.1712 -Driver.FullVersion = version compl\u00E8te xjc "2.3.0-SNAPSHOT" +Driver.FullVersion = version compl\u00E8te xjc "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_it.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_it.properties index a1762e7b93d..9d00dd77f4e 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_it.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_it.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -127,14 +127,14 @@ Driver.CompilingSchema = compilazione di uno schema in corso... Driver.FailedToGenerateCode = Produzione del codice non riuscita. -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = Questo file \u00e8 stato generato dall''architettura JavaTM per XML Binding (JAXB) Reference Implementation, v2.3.0-SNAPSHOT \nVedere https://jaxb.java.net/ \nQualsiasi modifica a questo file andr\u00e0 persa durante la ricompilazione dello schema di origine. \nGenerato il: {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = Questo file \u00e8 stato generato dall''architettura JavaTM per XML Binding (JAXB) Reference Implementation, v2.3.0-b170215.1712 \nVedere https://jaxb.java.net/ \nQualsiasi modifica a questo file andr\u00e0 persa durante la ricompilazione dello schema di origine. \nGenerato il: {0} \n -Driver.Version = xjc 2.3.0-SNAPSHOT +Driver.Version = xjc 2.3.0-b170215.1712 -Driver.FullVersion = versione completa xjc "2.3.0-SNAPSHOT" +Driver.FullVersion = versione completa xjc "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_ja.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_ja.properties index abdf441ddf4..c7a60c6e59a 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_ja.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_ja.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -127,14 +127,14 @@ Driver.CompilingSchema = \u30b9\u30ad\u30fc\u30de\u306e\u30b3\u30f3\u30d1\u30a4\ Driver.FailedToGenerateCode = \u30b3\u30fc\u30c9\u306e\u751f\u6210\u306b\u5931\u6557\u3057\u307e\u3057\u305f\u3002 -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = \u3053\u306e\u30d5\u30a1\u30a4\u30eb\u306f\u3001JavaTM Architecture for XML Binding(JAXB) Reference Implementation\u3001v2.3.0-SNAPSHOT\u306b\u3088\u3063\u3066\u751f\u6210\u3055\u308c\u307e\u3057\u305f \nhttps://jaxb.java.net/\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044 \n\u30bd\u30fc\u30b9\u30fb\u30b9\u30ad\u30fc\u30de\u306e\u518d\u30b3\u30f3\u30d1\u30a4\u30eb\u6642\u306b\u3053\u306e\u30d5\u30a1\u30a4\u30eb\u306e\u5909\u66f4\u306f\u5931\u308f\u308c\u307e\u3059\u3002 \n\u751f\u6210\u65e5: {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = \u3053\u306e\u30d5\u30a1\u30a4\u30eb\u306f\u3001JavaTM Architecture for XML Binding(JAXB) Reference Implementation\u3001v2.3.0-b170215.1712\u306b\u3088\u3063\u3066\u751f\u6210\u3055\u308c\u307e\u3057\u305f \nhttps://jaxb.java.net/\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044 \n\u30bd\u30fc\u30b9\u30fb\u30b9\u30ad\u30fc\u30de\u306e\u518d\u30b3\u30f3\u30d1\u30a4\u30eb\u6642\u306b\u3053\u306e\u30d5\u30a1\u30a4\u30eb\u306e\u5909\u66f4\u306f\u5931\u308f\u308c\u307e\u3059\u3002 \n\u751f\u6210\u65e5: {0} \n -Driver.Version = xjc 2.3.0-SNAPSHOT +Driver.Version = xjc 2.3.0-b170215.1712 -Driver.FullVersion = xjc\u30D5\u30EB\u30FB\u30D0\u30FC\u30B8\u30E7\u30F3"2.3.0-SNAPSHOT" +Driver.FullVersion = xjc\u30D5\u30EB\u30FB\u30D0\u30FC\u30B8\u30E7\u30F3"2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_ko.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_ko.properties index d129d33031c..31018022265 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_ko.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_ko.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -127,14 +127,14 @@ Driver.CompilingSchema = \uc2a4\ud0a4\ub9c8\ub97c \ucef4\ud30c\uc77c\ud558\ub294 Driver.FailedToGenerateCode = \ucf54\ub4dc \uc0dd\uc131\uc744 \uc2e4\ud328\ud588\uc2b5\ub2c8\ub2e4. -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = \uc774 \ud30c\uc77c\uc740 JAXB(JavaTM Architecture for XML Binding) \ucc38\uc870 \uad6c\ud604 2.3.0-SNAPSHOT \ubc84\uc804\uc744 \ud1b5\ud574 \uc0dd\uc131\ub418\uc5c8\uc2b5\ub2c8\ub2e4. \nhttps://jaxb.java.net/\ub97c \ucc38\uc870\ud558\uc2ed\uc2dc\uc624. \n\uc774 \ud30c\uc77c\uc744 \uc218\uc815\ud558\uba74 \uc18c\uc2a4 \uc2a4\ud0a4\ub9c8\ub97c \uc7ac\ucef4\ud30c\uc77c\ud560 \ub54c \uc218\uc815 \uc0ac\ud56d\uc774 \uc190\uc2e4\ub429\ub2c8\ub2e4. \n\uc0dd\uc131 \ub0a0\uc9dc: {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = \uc774 \ud30c\uc77c\uc740 JAXB(JavaTM Architecture for XML Binding) \ucc38\uc870 \uad6c\ud604 2.3.0-b170215.1712 \ubc84\uc804\uc744 \ud1b5\ud574 \uc0dd\uc131\ub418\uc5c8\uc2b5\ub2c8\ub2e4. \nhttps://jaxb.java.net/\ub97c \ucc38\uc870\ud558\uc2ed\uc2dc\uc624. \n\uc774 \ud30c\uc77c\uc744 \uc218\uc815\ud558\uba74 \uc18c\uc2a4 \uc2a4\ud0a4\ub9c8\ub97c \uc7ac\ucef4\ud30c\uc77c\ud560 \ub54c \uc218\uc815 \uc0ac\ud56d\uc774 \uc190\uc2e4\ub429\ub2c8\ub2e4. \n\uc0dd\uc131 \ub0a0\uc9dc: {0} \n -Driver.Version = XJC 2.3.0-SNAPSHOT +Driver.Version = XJC 2.3.0-b170215.1712 -Driver.FullVersion = XJC \uC815\uC2DD \uBC84\uC804 "2.3.0-SNAPSHOT" +Driver.FullVersion = XJC \uC815\uC2DD \uBC84\uC804 "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_pt_BR.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_pt_BR.properties index 58083953f6d..71c827a099b 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_pt_BR.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_pt_BR.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -127,14 +127,14 @@ Driver.CompilingSchema = compilando um esquema... Driver.FailedToGenerateCode = Falha ao produzir o c\u00f3digo. -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = Este arquivo foi gerado pela Arquitetura JavaTM para Implementa\u00e7\u00e3o de Refer\u00eancia (JAXB) de Bind XML, v2.3.0-SNAPSHOT \nConsulte https://jaxb.java.net/ \nTodas as modifica\u00e7\u00f5es neste arquivo ser\u00e3o perdidas ap\u00f3s a recompila\u00e7\u00e3o do esquema de origem. \nGerado em: {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = Este arquivo foi gerado pela Arquitetura JavaTM para Implementa\u00e7\u00e3o de Refer\u00eancia (JAXB) de Bind XML, v2.3.0-b170215.1712 \nConsulte https://jaxb.java.net/ \nTodas as modifica\u00e7\u00f5es neste arquivo ser\u00e3o perdidas ap\u00f3s a recompila\u00e7\u00e3o do esquema de origem. \nGerado em: {0} \n -Driver.Version = xjc 2.3.0-SNAPSHOT +Driver.Version = xjc 2.3.0-b170215.1712 -Driver.FullVersion = vers\u00E3o completa de xjc "2.3.0-SNAPSHOT" +Driver.FullVersion = vers\u00E3o completa de xjc "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_zh_CN.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_zh_CN.properties index 34397261515..efd45c540e8 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_zh_CN.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_zh_CN.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -131,14 +131,14 @@ Driver.CompilingSchema = \u6b63\u5728\u7f16\u8bd1\u6a21\u5f0f... Driver.FailedToGenerateCode = \u65e0\u6cd5\u751f\u6210\u4ee3\u7801\u3002 -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = \u6b64\u6587\u4ef6\u662f\u7531 JavaTM Architecture for XML Binding (JAXB) \u5f15\u7528\u5b9e\u73b0 v2.3.0-SNAPSHOT \u751f\u6210\u7684\n\u8bf7\u8bbf\u95ee https://jaxb.java.net/ \n\u5728\u91cd\u65b0\u7f16\u8bd1\u6e90\u6a21\u5f0f\u65f6, \u5bf9\u6b64\u6587\u4ef6\u7684\u6240\u6709\u4fee\u6539\u90fd\u5c06\u4e22\u5931\u3002\n\u751f\u6210\u65f6\u95f4: {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = \u6b64\u6587\u4ef6\u662f\u7531 JavaTM Architecture for XML Binding (JAXB) \u5f15\u7528\u5b9e\u73b0 v2.3.0-b170215.1712 \u751f\u6210\u7684\n\u8bf7\u8bbf\u95ee https://jaxb.java.net/ \n\u5728\u91cd\u65b0\u7f16\u8bd1\u6e90\u6a21\u5f0f\u65f6, \u5bf9\u6b64\u6587\u4ef6\u7684\u6240\u6709\u4fee\u6539\u90fd\u5c06\u4e22\u5931\u3002\n\u751f\u6210\u65f6\u95f4: {0} \n -Driver.Version = xjc 2.3.0-SNAPSHOT +Driver.Version = xjc 2.3.0-b170215.1712 -Driver.FullVersion = xjc \u5B8C\u6574\u7248\u672C "2.3.0-SNAPSHOT" +Driver.FullVersion = xjc \u5B8C\u6574\u7248\u672C "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_zh_TW.properties b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_zh_TW.properties index 2685c64a2bf..4889fc512ae 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_zh_TW.properties +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/MessageBundle_zh_TW.properties @@ -1,5 +1,5 @@ # -# Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -127,14 +127,14 @@ Driver.CompilingSchema = \u6b63\u5728\u7de8\u8b6f\u7db1\u8981... Driver.FailedToGenerateCode = \u7121\u6cd5\u7522\u751f\u7a0b\u5f0f\u78bc. -# DO NOT localize the 2.3.0-SNAPSHOT string - it is a token for an mvn -Driver.FilePrologComment = \u6b64\u6a94\u6848\u662f\u7531 JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.3.0-SNAPSHOT \u6240\u7522\u751f \n\u8acb\u53c3\u95b1 https://jaxb.java.net/ \n\u4e00\u65e6\u91cd\u65b0\u7de8\u8b6f\u4f86\u6e90\u7db1\u8981, \u5c0d\u6b64\u6a94\u6848\u6240\u505a\u7684\u4efb\u4f55\u4fee\u6539\u90fd\u5c07\u6703\u907a\u5931. \n\u7522\u751f\u6642\u9593: {0} \n +# DO NOT localize the 2.3.0-b170215.1712 string - it is a token for an mvn +Driver.FilePrologComment = \u6b64\u6a94\u6848\u662f\u7531 JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.3.0-b170215.1712 \u6240\u7522\u751f \n\u8acb\u53c3\u95b1 https://jaxb.java.net/ \n\u4e00\u65e6\u91cd\u65b0\u7de8\u8b6f\u4f86\u6e90\u7db1\u8981, \u5c0d\u6b64\u6a94\u6848\u6240\u505a\u7684\u4efb\u4f55\u4fee\u6539\u90fd\u5c07\u6703\u907a\u5931. \n\u7522\u751f\u6642\u9593: {0} \n -Driver.Version = xjc 2.3.0-SNAPSHOT +Driver.Version = xjc 2.3.0-b170215.1712 -Driver.FullVersion = xjc \u5B8C\u6574\u7248\u672C "2.3.0-SNAPSHOT" +Driver.FullVersion = xjc \u5B8C\u6574\u7248\u672C "2.3.0-b170215.1712" -Driver.BuildID = 2.3.0-SNAPSHOT +Driver.BuildID = 2.3.0-b170215.1712 # for JDK integration - include version in source zip jaxb.jdk.version=@@JAXB_JDK_VERSION@@ diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/Options.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/Options.java index 10c1bda5157..e1603cb9aaa 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/Options.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/Options.java @@ -25,6 +25,27 @@ package com.sun.tools.internal.xjc; +import java.io.BufferedReader; +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.io.InputStreamReader; +import java.io.PrintWriter; +import java.io.StringWriter; +import java.net.MalformedURLException; +import java.net.URL; +import java.net.URLClassLoader; +import java.security.AccessController; +import java.security.PrivilegedAction; +import java.text.SimpleDateFormat; +import java.util.ArrayList; +import java.util.Date; +import java.util.Enumeration; +import java.util.HashSet; +import java.util.List; +import java.util.ServiceLoader; +import java.util.Set; + import com.sun.codemodel.internal.CodeWriter; import com.sun.codemodel.internal.JPackage; import com.sun.codemodel.internal.JResourceFile; @@ -37,40 +58,16 @@ import com.sun.tools.internal.xjc.generator.bean.field.FieldRendererFactory; import com.sun.tools.internal.xjc.model.Model; import com.sun.tools.internal.xjc.reader.Util; import com.sun.xml.internal.bind.api.impl.NameConverter; -import org.xml.sax.EntityResolver; -import org.xml.sax.InputSource; - -import java.io.BufferedReader; -import java.io.File; -import java.io.FileInputStream; -import java.io.IOException; -import java.io.InputStreamReader; -import java.io.PrintWriter; -import java.io.StringWriter; -import java.net.MalformedURLException; import java.net.URI; import java.net.URISyntaxException; -import java.net.URL; -import java.net.URLClassLoader; import java.nio.charset.Charset; import java.nio.charset.IllegalCharsetNameException; -import java.security.AccessController; -import java.security.PrivilegedAction; -import java.text.SimpleDateFormat; -import java.util.ArrayList; -import java.util.Date; -import java.util.Enumeration; -import java.util.HashSet; -import java.util.List; import java.util.Locale; -import java.util.ServiceLoader; -import java.util.Set; import java.util.logging.Level; import java.util.logging.Logger; -import javax.xml.catalog.CatalogFeatures; -import javax.xml.catalog.CatalogFeatures.Feature; -import javax.xml.catalog.CatalogManager; +import org.xml.sax.EntityResolver; +import org.xml.sax.InputSource; /** * Global options. @@ -181,7 +178,7 @@ public class Options public File targetDir = new File("."); /** - * Actually stores {@link CatalogResolver}, but the field + * On JDK 8 an odler stores {@code CatalogResolver}, but the field * type is made to {@link EntityResolver} so that XJC can be * used even if resolver.jar is not available in the classpath. */ @@ -208,9 +205,9 @@ public class Options /** * Input schema files as a list of {@link InputSource}s. */ - private final List grammars = new ArrayList(); + private final List grammars = new ArrayList<>(); - private final List bindFiles = new ArrayList(); + private final List bindFiles = new ArrayList<>(); // Proxy setting. private String proxyHost = null; @@ -220,7 +217,7 @@ public class Options /** * {@link Plugin}s that are enabled in this compilation. */ - public final List activePlugins = new ArrayList(); + public final List activePlugins = new ArrayList<>(); /** * All discovered {@link Plugin}s. @@ -233,7 +230,7 @@ public class Options /** * Set of URIs that plug-ins recognize as extension bindings. */ - public final Set pluginURIs = new HashSet(); + public final Set pluginURIs = new HashSet<>(); /** * This allocator has the final say on deciding the class name. @@ -357,6 +354,7 @@ public class Options * A plugins are enumerated when this method is called for the first time, * by taking {@link #classpaths} into account. That means * "-cp plugin.jar" has to come before you specify options to enable it. + * @return */ public List getAllPlugins() { if(allPlugins==null) { @@ -375,13 +373,15 @@ public class Options this.schemaLanguage = _schemaLanguage; } - /** Input schema files. */ + /** Input schema files. + * @return */ public InputSource[] getGrammars() { return grammars.toArray(new InputSource[grammars.size()]); } /** * Adds a new input schema. + * @param is */ public void addGrammar( InputSource is ) { grammars.add(absolutize(is)); @@ -402,6 +402,7 @@ public class Options /** * Recursively scan directories and add all XSD files in it. + * @param dir */ public void addGrammarRecursive( File dir ) { addRecursive(dir,".xsd",grammars); @@ -432,13 +433,15 @@ public class Options return is; } - /** Input external binding files. */ + /** Input external binding files. + * @return */ public InputSource[] getBindFiles() { return bindFiles.toArray(new InputSource[bindFiles.size()]); } /** * Adds a new binding file. + * @param is */ public void addBindFile( InputSource is ) { bindFiles.add(absolutize(is)); @@ -446,6 +449,7 @@ public class Options /** * Adds a new binding file. + * @param bindFile */ public void addBindFile( File bindFile ) { bindFiles.add(fileToInputSource(bindFile)); @@ -453,15 +457,18 @@ public class Options /** * Recursively scan directories and add all ".xjb" files in it. + * @param dir */ public void addBindFileRecursive( File dir ) { addRecursive(dir,".xjb",bindFiles); } - public final List classpaths = new ArrayList(); + public final List classpaths = new ArrayList<>(); /** * Gets a classLoader that can load classes specified via the * -classpath option. + * @param parent + * @return */ public ClassLoader getUserClassLoader( ClassLoader parent ) { if (classpaths.isEmpty()) @@ -482,6 +489,8 @@ public class Options * Parses an option {@code args[i]} and return * the number of tokens consumed. * + * @param args + * @param i * @return * 0 if the argument is not understood. Returning 0 * will let the caller report an error. @@ -610,10 +619,8 @@ public class Options Messages.format(Messages.NO_SUCH_FILE,file)); } - try { - BufferedReader in = new BufferedReader(new InputStreamReader(new FileInputStream(file),"UTF-8")); + try (BufferedReader in = new BufferedReader(new InputStreamReader(new FileInputStream(file),"UTF-8"))) { parseProxy(in.readLine()); - in.close(); } catch (IOException e) { throw new BadCommandLineException( Messages.format(Messages.FAILED_TO_PARSE,file,e.getMessage()),e); @@ -639,7 +646,9 @@ public class Options return 2; } if( args[i].equals("-catalog") ) { - // use javax.xml.catalog to resolve external entities. + // use Sun's "XML Entity and URI Resolvers" by Norman Walsh + // to resolve external entities. + // https://xerces.apache.org/xml-commons/components/resolver/resolver-article.html File catalogFile = new File(requireArgument("-catalog",args,++i)); try { @@ -652,6 +661,7 @@ public class Options } if( args[i].equals("-Xtest-class-name-allocator") ) { classNameAllocator = new ClassNameAllocator() { + @Override public String assignClassName(String packageName, String className) { System.out.printf("assignClassName(%s,%s)\n",packageName,className); return className+"_Type"; @@ -736,6 +746,11 @@ public class Options /** * Obtains an operand and reports an error if it's not there. + * @param optionName + * @param args + * @param i + * @return + * @throws com.sun.tools.internal.xjc.BadCommandLineException */ public String requireArgument(String optionName, String[] args, int i) throws BadCommandLineException { if (i == args.length || args[i].startsWith("-")) { @@ -773,34 +788,27 @@ public class Options } } - /** - * Adds a new catalog file. - */ - public void addCatalog(File catalogFile) throws IOException { - URI newUrl = catalogFile.toURI(); - if (!catalogUrls.contains(newUrl)) { - catalogUrls.add(newUrl); - } - try { - entityResolver = CatalogManager.catalogResolver(catalogFeatures, - catalogUrls.stream().toArray(URI[]::new)); - } catch (Exception ex) { - entityResolver = null; - } - } - // Since javax.xml.catalog is unmodifiable we need to track catalog // URLs added and create new catalog each time addCatalog is called private final ArrayList catalogUrls = new ArrayList<>(); - // Cache CatalogFeatures instance for future usages. - // Resolve feature is set to "continue" value for backward compatibility. - private static CatalogFeatures catalogFeatures = CatalogFeatures.builder() - .with(Feature.RESOLVE, "continue") - .build(); + /** + * Adds a new catalog file.Use created or existed resolver to parse new catalog file. + * @param catalogFile + * @throws java.io.IOException + */ + public void addCatalog(File catalogFile) throws IOException { + URI newUri = catalogFile.toURI(); + if (!catalogUrls.contains(newUri)) { + catalogUrls.add(newUri); + } + entityResolver = CatalogUtil.getCatalog(entityResolver, catalogFile, catalogUrls); + } + /** * Parses arguments and fill fields of this object. * + * @param args * @exception BadCommandLineException * thrown when there's a problem in the command-line arguments */ @@ -861,6 +869,8 @@ public class Options /** * Finds the {@code META-INF/sun-jaxb.episode} file to add as a binding customization. + * @param jar + * @throws com.sun.tools.internal.xjc.BadCommandLineException */ public void scanEpisodeFile(File jar) throws BadCommandLineException { try { @@ -879,6 +889,7 @@ public class Options /** * Guesses the schema language. + * @return */ public Language guessSchemaLanguage() { @@ -899,6 +910,8 @@ public class Options /** * Creates a configured CodeWriter that produces files into the specified directory. + * @return + * @throws java.io.IOException */ public CodeWriter createCodeWriter() throws IOException { return createCodeWriter(new FileCodeWriter( targetDir, readOnly, encoding )); @@ -906,6 +919,8 @@ public class Options /** * Creates a configured CodeWriter that produces files into the specified directory. + * @param core + * @return */ public CodeWriter createCodeWriter( CodeWriter core ) { if(noFileHeader) @@ -915,8 +930,8 @@ public class Options } /** - * Gets the string suitable to be used as the prolog comment baked into artifacts. - * This is the string like "This file was generated by the JAXB RI on YYYY/mm/dd..." + * Gets the string suitable to be used as the prolog comment baked into artifacts.This is the string like "This file was generated by the JAXB RI on YYYY/mm/dd..." + * @return */ public String getPrologComment() { // generate format syntax: 'at'

    + * This package provides a way to invoke XJC from within another program. The primary target of this API is the JAX-WS + * RI, but we hope that this API would be useful for other integration purposes as well. + * + *

    Getting Started: Using XJC

    + *

    + * To invoke XJC, a typical client would do something like this: + *

    + *    SchemaCompiler sc = XJC.createSchemaCompiler();
    + *    sc.parseSchema(new InputSource(schema1Url.toExternalForm()));
    + *    sc.parseSchema(new InputSource(schema2Url.toExternalForm()));
    + *    ...
    + *    S2JModel model = sc.bind();
    + * 
    + *

    + * The bind operation causes XJC to do the bulk of the work, such as figuring out what classes to generate, what + * methods/fields to generate, etc. The obtained model contains useful introspective information about how the binding + * was performed (such as the mapping between XML types and generated Java classes) + * + *

    + * Once the model is obtained, generate the code into the file system as follows: + *

    + *   JCodeModel cm = model.generateCode( null, ... );
    + *   cm.build(new FileCodeWriter(outputDir));
    + * 
    + * + *

    Implementation Note

    + *

    + * This package shouldn't contain any implementation code. + */ +package com.sun.tools.internal.xjc.api; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/api/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/api/package.html deleted file mode 100644 index 5ec97a80e19..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/api/package.html +++ /dev/null @@ -1,64 +0,0 @@ - - - - - -API for programmatic invocation of XJC and schemagen. - -

    -This package provides a way to invoke XJC from within another program. -The primary target of this API is the JAX-WS RI, but we hope that -this API would be useful for other integration purposes as well. - -

    Getting Started: Using XJC

    -

    -To invoke XJC, a typical client would do something like this: -

    -    SchemaCompiler sc = XJC.createSchemaCompiler();
    -    sc.parseSchema(new InputSource(schema1Url.toExternalForm()));
    -    sc.parseSchema(new InputSource(schema2Url.toExternalForm()));
    -    ...
    -    S2JModel model = sc.bind();
    -
    -

    -The bind operation causes XJC to do the bulk of the work, such as -figuring out what classes to generate, what methods/fields to generate, etc. -The obtained model contains useful introspective information about -how the binding was performed (such as the mapping between XML types -and generated Java classes) - -

    -Once the model is obtained, generate the code into the file system as follows: -

    -    JCodeModel cm = model.generateCode( null, ... );
    -    cm.build(new FileCodeWriter(outputDir));
    -
    - - -

    Implementation Note

    -

    -This package shouldn't contain any implementation code. - diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/generator/bean/field/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/generator/bean/field/package-info.java new file mode 100644 index 00000000000..28d16b99d11 --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/generator/bean/field/package-info.java @@ -0,0 +1,31 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * FieldRenderer and its implementation classes. + * Unless you are deriving from these classes to define your own custom renderer, + * you shouldn't be using these classes directly. Use the outline package. + */ +package com.sun.tools.internal.xjc.generator.bean.field; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/generator/bean/field/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/generator/bean/field/package.html deleted file mode 100644 index 149a2f33f39..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/generator/bean/field/package.html +++ /dev/null @@ -1,30 +0,0 @@ - - -

    -FieldRenderer and its implementation classes. -Unless you are deriving from these classes to define your own custom renderer, -you shouldn't be using these classes directly. Use the outline package. -

    diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/model/nav/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/model/nav/package-info.java new file mode 100644 index 00000000000..f40b82a7150 --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/model/nav/package-info.java @@ -0,0 +1,41 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + *

    + * Compile-time representation of Java type system. + * + *

    + * These classes are used as TypeT and ClassDeclT of the model parameterization. This implementaion is designed to be + * capable of representing pre-existing classes (such as java.lang.String) as well as the generated classes (represented + * as JDefinedClass.) + * + *

    Handling of Primitive Types

    + *

    + * Primitive types have two forms (int and Integer), and this complicates the binding process. For this reason, inside + * the front end, we always use the boxed types. We'll use the unboxed form only in the back end when we know the field + * doesn't need to represent the null value. + */ +package com.sun.tools.internal.xjc.model.nav; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/model/nav/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/model/nav/package.html deleted file mode 100644 index 24ecf544b4d..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/model/nav/package.html +++ /dev/null @@ -1,42 +0,0 @@ - - - - - -

    - Compile-time representation of Java type system. - -

    - These classes are used as TypeT and ClassDeclT of the model parameterization. - This implementaion is designed to be capable of representing pre-existing classes - (such as java.lang.String) as well as the generated classes (represented as JDefinedClass.) - -

    Handling of Primitive Types

    -

    - Primitive types have two forms (int and Integer), and this complicates the binding process. - For this reason, inside the front end, we always use the boxed types. We'll use the unboxed - form only in the back end when we know the field doesn't need to represent the null value. - diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/outline/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/outline/package-info.java new file mode 100644 index 00000000000..271f84ccebf --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/outline/package-info.java @@ -0,0 +1,35 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Provides the outline of the generated Java source code so that + * additional processing (such as adding more annotations) can be + * done on the generated code. + * + *

    + * Code generation phase builds an outline little by little, while each step is using the outline built by the prior + * steps. + */ +package com.sun.tools.internal.xjc.outline; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/outline/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/outline/package.html deleted file mode 100644 index 371364c7a27..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/outline/package.html +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - Provides the outline of the generated Java source code so that - additional processings (such as adding more annotations) can be - done on the generated code. - -

    - Code generation phase builds an outline little by little, while - each step is using the outline built by the prior steps. - diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/dtd/bindinfo/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/dtd/bindinfo/package-info.java new file mode 100644 index 00000000000..11e9f94d952 --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/dtd/bindinfo/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Object Model that represents DTD binding information. + */ +package com.sun.tools.internal.xjc.reader.dtd.bindinfo; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/dtd/bindinfo/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/dtd/bindinfo/package.html deleted file mode 100644 index 87bbd14bc37..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/dtd/bindinfo/package.html +++ /dev/null @@ -1,26 +0,0 @@ - - -

    Object Model that represents DTD binding information.

    diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/gbind/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/gbind/package-info.java new file mode 100644 index 00000000000..1faa04caa10 --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/gbind/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Binary expressions are left-associative. IOW, ((A,B),C) instead of (A,(B,C)). + */ +package com.sun.tools.internal.xjc.reader.gbind; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/gbind/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/gbind/package.html deleted file mode 100644 index 36465475b32..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/gbind/package.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - Binary expressions are left-associative. IOW, ((A,B),C) instead of (A,(B,C)) - - diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/internalizer/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/internalizer/package-info.java new file mode 100644 index 00000000000..e32f91f28e4 --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/internalizer/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * internalization of external binding files and <jaxb:bindings> customizations. + */ +package com.sun.tools.internal.xjc.reader.internalizer; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/internalizer/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/internalizer/package.html deleted file mode 100644 index e6f2aa14379..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/internalizer/package.html +++ /dev/null @@ -1,26 +0,0 @@ - - -

    internalization of external binding files and <jaxb:bindings> customizations.

    diff --git a/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/RunAllTests.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/package-info.java similarity index 71% rename from jdk/test/sun/net/www/protocol/jar/jarbug/src/test/RunAllTests.java rename to jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/package-info.java index 6ab82c7eb7b..d6719858a56 100644 --- a/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/RunAllTests.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/package-info.java @@ -1,10 +1,12 @@ /* - * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or @@ -21,10 +23,7 @@ * questions. */ -public class RunAllTests { - public static void main(String[] args) throws Exception { - String[] noArgs = new String[0]; - TestBug4361044.main(noArgs); - TestBug4523159.main(noArgs); - } -} +/** + * Front-end that reads schema(s) and produce BGM. + */ +package com.sun.tools.internal.xjc.reader; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/package.html deleted file mode 100644 index 7da51871e6a..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/package.html +++ /dev/null @@ -1,26 +0,0 @@ - - -

    Front-end that reads schema(s) and produce BGM.

    diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/xmlschema/bindinfo/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/xmlschema/bindinfo/package-info.java index 0c313cbcd1d..898bfcaab34 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/xmlschema/bindinfo/package-info.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/xmlschema/bindinfo/package-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,6 +23,12 @@ * questions. */ +/** + * Object Model that represents customization declarations. + * RelaxNGCC is used to parse + * XML syntax into this representation, and the other parts of XJC will use + * this object model. + */ @XmlSchema(elementFormDefault = QUALIFIED, namespace=Const.JAXB_NSURI) package com.sun.tools.internal.xjc.reader.xmlschema.bindinfo; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/xmlschema/bindinfo/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/xmlschema/bindinfo/package.html deleted file mode 100644 index e71625d1171..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/reader/xmlschema/bindinfo/package.html +++ /dev/null @@ -1,34 +0,0 @@ - - - -Object Model that represents customization declarations. - -

    - RelaxNGCC is used to parse - XML syntax into this representation, and the other parts of XJC will use - this object model. -

    - diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/runtime/package-info.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/runtime/package-info.java new file mode 100644 index 00000000000..5387ad02145 --- /dev/null +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/runtime/package-info.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Code generated into the user's packages in certain compilation mode. + */ +package com.sun.tools.internal.xjc.runtime; diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/runtime/package.html b/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/runtime/package.html deleted file mode 100644 index 3e675192b04..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/tools/internal/xjc/runtime/package.html +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - Code generated into the user's packages in certain compilation mode. - - diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/ElementDecl.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/ElementDecl.java index c4a9f35d90b..e74b7e0a494 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/ElementDecl.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/ElementDecl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -70,7 +70,7 @@ public class ElementDecl extends DeclarationImpl implements XSElementDecl, Ref.T this.substHead = _substHead; this.substDisallowed = _substDisallowed; this.substExcluded = _substExcluded; - this.idConstraints = Collections.unmodifiableList((List)idConstraints); + this.idConstraints = (List) Collections.unmodifiableList((List)idConstraints); for (IdentityConstraintImpl idc : idConstraints) idc.setParent(this); @@ -80,42 +80,52 @@ public class ElementDecl extends DeclarationImpl implements XSElementDecl, Ref.T } private XmlString defaultValue; + @Override public XmlString getDefaultValue() { return defaultValue; } private XmlString fixedValue; + @Override public XmlString getFixedValue() { return fixedValue; } private boolean nillable; + @Override public boolean isNillable() { return nillable; } private boolean _abstract; + @Override public boolean isAbstract() { return _abstract; } private Ref.Type type; + @Override public XSType getType() { return type.getType(); } private Ref.Element substHead; + @Override public XSElementDecl getSubstAffiliation() { if(substHead==null) return null; return substHead.get(); } private int substDisallowed; + @Override public boolean isSubstitutionDisallowed( int method ) { return (substDisallowed&method)!=0; } private int substExcluded; + @Override public boolean isSubstitutionExcluded( int method ) { return (substExcluded&method)!=0; } private final List idConstraints; + @Override public List getIdentityConstraints() { return idConstraints; } private Boolean form; + @Override public Boolean getForm() { return form; } @@ -124,6 +134,7 @@ public class ElementDecl extends DeclarationImpl implements XSElementDecl, Ref.T /** * @deprecated */ + @Override public XSElementDecl[] listSubstitutables() { Set s = getSubstitutables(); return s.toArray(new XSElementDecl[s.size()]); @@ -135,6 +146,7 @@ public class ElementDecl extends DeclarationImpl implements XSElementDecl, Ref.T /** Unmodifieable view of {@link #substitutables}. */ private Set substitutablesView = null; + @Override public Set getSubstitutables() { if( substitutables==null ) { // if the field is null by the time this method @@ -194,42 +206,57 @@ public class ElementDecl extends DeclarationImpl implements XSElementDecl, Ref.T } } + @Override public boolean canBeSubstitutedBy(XSElementDecl e) { return getSubstitutables().contains(e); } + @Override public boolean isWildcard() { return false; } + @Override public boolean isModelGroupDecl() { return false; } + @Override public boolean isModelGroup() { return false; } + @Override public boolean isElementDecl() { return true; } + @Override public XSWildcard asWildcard() { return null; } + @Override public XSModelGroupDecl asModelGroupDecl() { return null; } + @Override public XSModelGroup asModelGroup() { return null; } + @Override public XSElementDecl asElementDecl() { return this; } + @Override public void visit( XSVisitor visitor ) { visitor.elementDecl(this); } + @Override public void visit( XSTermVisitor visitor ) { visitor.elementDecl(this); } + @Override public Object apply( XSTermFunction function ) { return function.elementDecl(this); } + @Override public T apply(XSTermFunctionWithParam function, P param) { return function.elementDecl(this,param); } + @Override public Object apply( XSFunction function ) { return function.elementDecl(this); } // Ref.Term implementation + @Override public XSTerm getTerm() { return this; } } diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/IdentityConstraintImpl.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/IdentityConstraintImpl.java index 2a4c69475e8..4ca87b29c52 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/IdentityConstraintImpl.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/IdentityConstraintImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -59,17 +59,19 @@ public class IdentityConstraintImpl extends ComponentImpl implements XSIdentityC this.name = name; this.selector = selector; selector.setParent(this); - this.fields = Collections.unmodifiableList((List)fields); + this.fields = (List) Collections.unmodifiableList((List)fields); for( XPathImpl xp : fields ) xp.setParent(this); this.refer = refer; } + @Override public void visit(XSVisitor visitor) { visitor.identityConstraint(this); } + @Override public T apply(XSFunction function) { return function.identityConstraint(this); } @@ -79,30 +81,37 @@ public class IdentityConstraintImpl extends ComponentImpl implements XSIdentityC parent.getOwnerSchema().addIdentityConstraint(this); } + @Override public XSElementDecl getParent() { return parent; } + @Override public String getName() { return name; } + @Override public String getTargetNamespace() { return getParent().getTargetNamespace(); } + @Override public short getCategory() { return category; } + @Override public XSXPath getSelector() { return selector; } + @Override public List getFields() { return fields; } + @Override public XSIdentityConstraint getReferencedKey() { if(category==KEYREF) return refer.get(); @@ -110,6 +119,7 @@ public class IdentityConstraintImpl extends ComponentImpl implements XSIdentityC throw new IllegalStateException("not a keyref"); } + @Override public XSIdentityConstraint get() { return this; } diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/parser/NGCCRuntimeEx.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/parser/NGCCRuntimeEx.java index 4e600c32e55..297ff889b6d 100644 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/parser/NGCCRuntimeEx.java +++ b/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/parser/NGCCRuntimeEx.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,7 +34,6 @@ import com.sun.xml.internal.xsom.impl.UName; import com.sun.xml.internal.xsom.impl.Const; import com.sun.xml.internal.xsom.impl.parser.state.NGCCRuntime; import com.sun.xml.internal.xsom.impl.parser.state.Schema; -import com.sun.xml.internal.xsom.impl.util.Uri; import com.sun.xml.internal.xsom.parser.AnnotationParser; import com.sun.xml.internal.org.relaxng.datatype.ValidationContext; import org.xml.sax.Attributes; @@ -48,8 +47,10 @@ import org.xml.sax.helpers.LocatorImpl; import java.io.IOException; import java.net.URI; +import java.net.URL; import java.text.MessageFormat; import java.util.Stack; +import java.util.regex.Pattern; /** * NGCCRuntime extended with various utility methods for @@ -150,12 +151,15 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { /* registers a patcher that will run after all the parsing has finished. */ + @Override public void addPatcher( Patch patcher ) { parser.patcherManager.addPatcher(patcher); } + @Override public void addErrorChecker( Patch patcher ) { parser.patcherManager.addErrorChecker(patcher); } + @Override public void reportError( String msg, Locator loc ) throws SAXException { parser.patcherManager.reportError(msg,loc); } @@ -188,8 +192,15 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { EntityResolver er = parser.getEntityResolver(); String systemId = null; - if (relativeUri!=null) - systemId = Uri.resolve(baseUri,relativeUri); + if (relativeUri!=null) { + if (isAbsolute(relativeUri)) { + systemId = relativeUri; + } + if (baseUri == null || !isAbsolute(baseUri)) { + throw new IOException("Unable to resolve relative URI " + relativeUri + " because base URI is not absolute: " + baseUri); + } + systemId = new URL(new URL(baseUri), relativeUri).toString(); + } if (er!=null) { InputSource is = er.resolveEntity(namespaceURI,systemId); @@ -217,7 +228,21 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { } } - /** Includes the specified schema. */ + private static final Pattern P = Pattern.compile(".*[/#?].*"); + + private static boolean isAbsolute(String uri) { + int i = uri.indexOf(':'); + if (i < 0) { + return false; + } + return !P.matcher(uri.substring(0, i)).matches(); + } + + /** + * Includes the specified schema. + * + * @param schemaLocation + * @throws org.xml.sax.SAXException */ public void includeSchema( String schemaLocation ) throws SAXException { NGCCRuntimeEx runtime = new NGCCRuntimeEx(parser,chameleonMode,this); runtime.currentSchema = this.currentSchema; @@ -235,7 +260,12 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { true, currentSchema.getTargetNamespace(), getLocator() ); } - /** Imports the specified schema. */ + /** + * Imports the specified schema. + * + * @param ns + * @param schemaLocation + * @throws org.xml.sax.SAXException */ public void importSchema( String ns, String schemaLocation ) throws SAXException { NGCCRuntimeEx newRuntime = new NGCCRuntimeEx(parser,false,this); InputSource source = resolveRelativeURL(ns,schemaLocation); @@ -317,9 +347,13 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { /** * Parses the specified entity. * + * @param source * @param importLocation * The source location of the import/include statement. * Used for reporting errors. + * @param includeMode + * @param expectedNamespace + * @throws org.xml.sax.SAXException */ public void parseEntity( InputSource source, boolean includeMode, String expectedNamespace, Locator importLocation ) throws SAXException { @@ -342,6 +376,8 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { /** * Creates a new instance of annotation parser. + * + * @return Annotation parser */ public AnnotationParser createAnnotationParser() { if(parser.getAnnotationParserFactory()==null) @@ -351,14 +387,19 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { } /** - * Gets the element name that contains the annotation element. - * This method works correctly only when called by the annotation handler. + * Gets the element name that contains the annotation element.This method works correctly only when called by the annotation handler. + * + * @return Element name */ public String getAnnotationContextElementName() { return elementNames.get( elementNames.size()-2 ); } - /** Creates a copy of the current locator object. */ + /** + * Creates a copy of the current locator object. + * + * @return Locator copy + */ public Locator copyLocator() { return new LocatorImpl(getLocator()); } @@ -397,6 +438,7 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { this.uri = _uri; } + @Override public String resolveNamespacePrefix(String p) { if(p.equals(prefix)) return uri; if(previous==null) return null; @@ -408,14 +450,20 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { private final Context previous; // XSDLib don't use those methods, so we cut a corner here. + @Override public String getBaseUri() { return null; } + @Override public boolean isNotation(String arg0) { return false; } + @Override public boolean isUnparsedEntity(String arg0) { return false; } } private Context currentContext=null; - /** Returns an immutable snapshot of the current context. */ + /** Returns an immutable snapshot of the current context. + * + * @return Snapshot of current context + */ public ValidationContext createValidationContext() { return currentContext; } @@ -446,6 +494,7 @@ public class NGCCRuntimeEx extends NGCCRuntime implements PatcherManager { * Parses UName under the given context. * @param qname Attribute name. * @return New {@link UName} instance based on attribute name. + * @throws org.xml.sax.SAXException */ public UName parseUName(final String qname ) throws SAXException { int idx = qname.indexOf(':'); diff --git a/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/util/Uri.java b/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/util/Uri.java deleted file mode 100644 index d6cddc7529b..00000000000 --- a/jaxws/src/jdk.xml.bind/share/classes/com/sun/xml/internal/xsom/impl/util/Uri.java +++ /dev/null @@ -1,187 +0,0 @@ -/* -Copyright (c) 2001, 2002 Thai Open Source Software Center Ltd -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in - the documentation and/or other materials provided with the - distribution. - - Neither the name of the Thai Open Source Software Center Ltd nor - the names of its contributors may be used to endorse or promote - products derived from this software without specific prior written - permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR -CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, -EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -*/ -// @@3RD PARTY CODE@@ - -package com.sun.xml.internal.xsom.impl.util; - -import java.io.IOException; -import java.io.UnsupportedEncodingException; -import java.net.URL; - -public class Uri { - private static String utf8 = "UTF-8"; - - public static boolean isValid(String s) { - return isValidPercent(s) && isValidFragment(s) && isValidScheme(s); - } - - private static final String HEX_DIGITS = "0123456789abcdef"; - - public static String escapeDisallowedChars(String s) { - StringBuffer buf = null; - int len = s.length(); - int done = 0; - for (;;) { - int i = done; - for (;;) { - if (i == len) { - if (done == 0) - return s; - break; - } - if (isExcluded(s.charAt(i))) - break; - i++; - } - if (buf == null) - buf = new StringBuffer(); - if (i > done) { - buf.append(s.substring(done, i)); - done = i; - } - if (i == len) - break; - for (i++; i < len && isExcluded(s.charAt(i)); i++) - ; - String tem = s.substring(done, i); - byte[] bytes; - try { - bytes = tem.getBytes(utf8); - } - catch (UnsupportedEncodingException e) { - utf8 = "UTF8"; - try { - bytes = tem.getBytes(utf8); - } - catch (UnsupportedEncodingException e2) { - // Give up - return s; - } - } - for (int j = 0; j < bytes.length; j++) { - buf.append('%'); - buf.append(HEX_DIGITS.charAt((bytes[j] & 0xFF) >> 4)); - buf.append(HEX_DIGITS.charAt(bytes[j] & 0xF)); - } - done = i; - } - return buf.toString(); - } - - private static String excluded = "<>\"{}|\\^`"; - - private static boolean isExcluded(char c) { - return c <= 0x20 || c >= 0x7F || excluded.indexOf(c) >= 0; - } - - private static boolean isAlpha(char c) { - return ('a' <= c && c <= 'z') || ('A' <= c && c <= 'Z'); - } - - private static boolean isHexDigit(char c) { - return ('a' <= c && c <= 'f') || ('A' <= c && c <= 'F') || isDigit(c); - } - - private static boolean isDigit(char c) { - return '0' <= c && c <= '9'; - } - - private static boolean isSchemeChar(char c) { - return isAlpha(c) || isDigit(c) || c == '+' || c == '-' || c =='.'; - } - - private static boolean isValidPercent(String s) { - int len = s.length(); - for (int i = 0; i < len; i++) - if (s.charAt(i) == '%') { - if (i + 2 >= len) - return false; - else if (!isHexDigit(s.charAt(i + 1)) - || !isHexDigit(s.charAt(i + 2))) - return false; - } - return true; - } - - private static boolean isValidFragment(String s) { - int i = s.indexOf('#'); - return i < 0 || s.indexOf('#', i + 1) < 0; - } - - private static boolean isValidScheme(String s) { - if (!isAbsolute(s)) - return true; - int i = s.indexOf(':'); - if (i == 0 - || i + 1 == s.length() - || !isAlpha(s.charAt(0))) - return false; - while (--i > 0) - if (!isSchemeChar(s.charAt(i))) - return false; - return true; - } - - public static String resolve(String baseUri, String uriReference) throws IOException { - if (isAbsolute(uriReference)) - return uriReference; - - if(baseUri==null) - throw new IOException("Unable to resolve relative URI "+uriReference+" without a base URI"); - - if(!isAbsolute(baseUri)) - throw new IOException("Unable to resolve relative URI "+uriReference+" because base URI is not absolute: "+baseUri); - - return new URL(new URL(baseUri), uriReference).toString(); - } - - public static boolean hasFragmentId(String uri) { - return uri.indexOf('#') >= 0; - } - - public static boolean isAbsolute(String uri) { - int i = uri.indexOf(':'); - if (i < 0) - return false; - while (--i >= 0) { - switch (uri.charAt(i)) { - case '#': - case '/': - case '?': - return false; - } - } - return true; - } -} diff --git a/jaxws/src/jdk.xml.bind/share/legal/relaxngdatatype.md b/jaxws/src/jdk.xml.bind/share/legal/relaxngdatatype.md index 54343b7483d..2555613c67c 100644 --- a/jaxws/src/jdk.xml.bind/share/legal/relaxngdatatype.md +++ b/jaxws/src/jdk.xml.bind/share/legal/relaxngdatatype.md @@ -3,7 +3,7 @@ ### RelaxNG Datatype License
     
    -Copyright (c) 2001, Thai Open Source Software Center Ltd, Sun Microsystems.
    +Copyright (c) 2005, 2010 Thai Open Source Software Center Ltd
     All rights reserved.
     
     Redistribution and use in source and binary forms, with or without
    diff --git a/jaxws/src/jdk.xml.bind/share/legal/xmlresolver.md b/jaxws/src/jdk.xml.bind/share/legal/xmlresolver.md
    index cf18bb439b3..696f8d3e148 100644
    --- a/jaxws/src/jdk.xml.bind/share/legal/xmlresolver.md
    +++ b/jaxws/src/jdk.xml.bind/share/legal/xmlresolver.md
    @@ -1,6 +1,6 @@
     ## Apache XML Resolver Library v1.2
     
    -### Notice
    +### Apache XML Resolver Notice
     
     
     Apache XML Commons Resolver
    diff --git a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/streaming/ContextClassloaderLocal.properties b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/ContextClassloaderLocal.properties
    similarity index 94%
    rename from jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/streaming/ContextClassloaderLocal.properties
    rename to jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/ContextClassloaderLocal.properties
    index c0267b823ea..d79956811cb 100644
    --- a/jaxws/src/java.xml.ws/share/classes/com/sun/xml/internal/ws/api/streaming/ContextClassloaderLocal.properties
    +++ b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/ContextClassloaderLocal.properties
    @@ -1,5 +1,5 @@
     #
    -# Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
    +# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
     # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     #
     # This code is free software; you can redistribute it and/or modify it
    diff --git a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/ContextClassloaderLocalMessages.java b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/ContextClassloaderLocalMessages.java
    new file mode 100644
    index 00000000000..24584fa50aa
    --- /dev/null
    +++ b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/ContextClassloaderLocalMessages.java
    @@ -0,0 +1,69 @@
    +/*
    + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
    + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    + *
    + * This code is free software; you can redistribute it and/or modify it
    + * under the terms of the GNU General Public License version 2 only, as
    + * published by the Free Software Foundation.  Oracle designates this
    + * particular file as subject to the "Classpath" exception as provided
    + * by Oracle in the LICENSE file that accompanied this code.
    + *
    + * This code is distributed in the hope that it will be useful, but WITHOUT
    + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    + * version 2 for more details (a copy is included in the LICENSE file that
    + * accompanied this code).
    + *
    + * You should have received a copy of the GNU General Public License version
    + * 2 along with this work; if not, write to the Free Software Foundation,
    + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    + *
    + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    + * or visit www.oracle.com if you need additional information or have any
    + * questions.
    + */
    +
    +package com.sun.tools.internal.ws.resources;
    +
    +import java.util.Locale;
    +import java.util.ResourceBundle;
    +import com.sun.istack.internal.localization.Localizable;
    +import com.sun.istack.internal.localization.LocalizableMessageFactory;
    +import com.sun.istack.internal.localization.LocalizableMessageFactory.ResourceBundleSupplier;
    +import com.sun.istack.internal.localization.Localizer;
    +
    +
    +/**
    + * Defines string formatting method for each constant in the resource file
    + *
    + */
    +public final class ContextClassloaderLocalMessages {
    +
    +    private final static String BUNDLE_NAME = "com.sun.tools.internal.ws.resources.ContextClassloaderLocal";
    +    private final static LocalizableMessageFactory MESSAGE_FACTORY = new LocalizableMessageFactory(BUNDLE_NAME, new ContextClassloaderLocalMessages.BundleSupplier());
    +    private final static Localizer LOCALIZER = new Localizer();
    +
    +    public static Localizable localizableFAILED_TO_CREATE_NEW_INSTANCE(Object arg0) {
    +        return MESSAGE_FACTORY.getMessage("FAILED_TO_CREATE_NEW_INSTANCE", arg0);
    +    }
    +
    +    /**
    +     * Failed to create new instance of {0}
    +     *
    +     */
    +    public static String FAILED_TO_CREATE_NEW_INSTANCE(Object arg0) {
    +        return LOCALIZER.localize(localizableFAILED_TO_CREATE_NEW_INSTANCE(arg0));
    +    }
    +
    +    private static class BundleSupplier
    +        implements ResourceBundleSupplier
    +    {
    +
    +
    +        public ResourceBundle getResourceBundle(Locale locale) {
    +            return ResourceBundle.getBundle(BUNDLE_NAME, locale);
    +        }
    +
    +    }
    +
    +}
    diff --git a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/newmessages.properties b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/newmessages.properties
    new file mode 100644
    index 00000000000..bd358f254f9
    --- /dev/null
    +++ b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/resources/newmessages.properties
    @@ -0,0 +1,6 @@
    +wrapperTask.needEndorsed=\
    +You are running on JDK6 or newer which comes with JAX-WS {0} API, but this tool requires JAX-WS {1} or newer API. Use \
    +the standard override mechanism. 
    +
    +runtime.modeler.addressing.responses.nosuchmethod = JAX-WS 2.1 API is loaded from {0}, But JAX-WS runtime requires JAX-WS 2.2 or newer API. \
    +  Use the standard override mechanism to load JAX-WS 2.2 or newer API.
    \ No newline at end of file
    diff --git a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/version.properties b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/version.properties
    index eedc7c2b359..82452acb3d7 100644
    --- a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/version.properties
    +++ b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/version.properties
    @@ -1,5 +1,5 @@
     #
    -# Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
    +# Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
     # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     #
     # This code is free software; you can redistribute it and/or modify it
    @@ -26,4 +26,4 @@
     build-id=2.3.0-SNAPSHOT
     build-version=JAX-WS RI 2.3.0-SNAPSHOT
     major-version=2.3.0
    -svn-revision=5c2c1fd2f2ab3b5c7cea25f79aa49e54cb84b7cc
    +svn-revision=e8c5e9697d9b27d83ff35d767939b2f55e667621
    diff --git a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wscompile/WsgenTool.java b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wscompile/WsgenTool.java
    index 4f29dc67fb4..e730c8e4ebb 100644
    --- a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wscompile/WsgenTool.java
    +++ b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wscompile/WsgenTool.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -144,12 +144,9 @@ public class WsgenTool {
         public boolean buildModel(String endpoint, Listener listener) throws BadCommandLineException {
             final ErrorReceiverFilter errReceiver = new ErrorReceiverFilter(listener);
     
    -        List args = new ArrayList(6 + (options.nocompile ? 1 : 0)
    +        List args = new ArrayList<>(6 + (options.nocompile ? 1 : 0)
                     + (options.encoding != null ? 2 : 0));
     
    -        args.add("--add-modules");
    -        args.add("java.xml.ws");
    -
             args.add("-d");
             args.add(options.destDir.getAbsolutePath());
             args.add("-classpath");
    @@ -163,8 +160,27 @@ public class WsgenTool {
                 args.add("-encoding");
                 args.add(options.encoding);
             }
    +
    +        boolean addModules = true;
             if (options.javacOptions != null) {
    -            args.addAll(options.getJavacOptions(args, listener));
    +            List javacOptions = options.getJavacOptions(args, listener);
    +            for (int i = 0; i < javacOptions.size(); i++) {
    +                String opt = javacOptions.get(i);
    +                if ("-source".equals(opt) && 9 >= getVersion(javacOptions.get(i + 1))) {
    +                    addModules = false;
    +                }
    +                if ("-target".equals(opt) && 9 >= getVersion(javacOptions.get(i + 1))) {
    +                    addModules = false;
    +                }
    +                if ("--release".equals(opt) && 9 >= getVersion(javacOptions.get(i + 1))) {
    +                    addModules = false;
    +                }
    +                args.add(opt);
    +            }
    +        }
    +        if (addModules) {
    +            args.add("--add-modules");
    +            args.add("java.xml.ws");
             }
     
             JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
    @@ -227,7 +243,7 @@ public class WsgenTool {
                 com.sun.xml.internal.ws.db.DatabindingImpl rt = (com.sun.xml.internal.ws.db.DatabindingImpl) fac.createRuntime(config);
     
                 final File[] wsdlFileName = new File[1]; // used to capture the generated WSDL file.
    -            final Map schemaFiles = new HashMap();
    +            final Map schemaFiles = new HashMap<>();
     
                 WSDLGenInfo wsdlGenInfo = new WSDLGenInfo();
                 wsdlGenInfo.setSecureXmlProcessingDisabled(disableXmlSecurity);
    @@ -299,7 +315,7 @@ public class WsgenTool {
         }
     
         private List getExternalFiles(List exts) {
    -        List files = new ArrayList();
    +        List files = new ArrayList<>();
             for (String ext : exts) {
                 // first try absolute path ...
                 File file = new File(ext);
    @@ -341,6 +357,10 @@ public class WsgenTool {
             }
         }
     
    +    private float getVersion(String s) {
    +        return Float.parseFloat(s);
    +    }
    +
         /**
          * "Namespace" for code needed to generate the report file.
          */
    diff --git a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wscompile/WsimportTool.java b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wscompile/WsimportTool.java
    index 3768118feb2..33664a05c7d 100644
    --- a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wscompile/WsimportTool.java
    +++ b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wscompile/WsimportTool.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -246,7 +246,7 @@ public class WsimportTool {
         }
     
         private void deleteGeneratedFiles() {
    -        Set trackedRootPackages = new HashSet();
    +        Set trackedRootPackages = new HashSet<>();
     
             if (options.clientjar != null) {
                 //remove all non-java artifacts as they will packaged in jar.
    @@ -282,7 +282,7 @@ public class WsimportTool {
     
         private void addClassesToGeneratedFiles() throws IOException {
             Iterable generatedFiles = options.getGeneratedFiles();
    -        final List trackedClassFiles = new ArrayList();
    +        final List trackedClassFiles = new ArrayList<>();
             for(File f: generatedFiles) {
                 if(f.getName().endsWith(".java")) {
                     String relativeDir = DirectoryUtil.getRelativePathfromCommonBase(f.getParentFile(),options.sourceDir);
    @@ -504,7 +504,7 @@ public class WsimportTool {
         }
     
         protected boolean compileGeneratedClasses(ErrorReceiver receiver, WsimportListener listener){
    -        List sourceFiles = new ArrayList();
    +        List sourceFiles = new ArrayList<>();
     
             for (File f : options.getGeneratedFiles()) {
                 if (f.exists() && f.getName().endsWith(".java")) {
    @@ -515,10 +515,7 @@ public class WsimportTool {
             if (sourceFiles.size() > 0) {
                 String classDir = options.destDir.getAbsolutePath();
                 String classpathString = createClasspathString();
    -            List args = new ArrayList();
    -
    -            args.add("--add-modules");
    -            args.add("java.xml.ws");
    +            List args = new ArrayList<>();
     
                 args.add("-d");
                 args.add(classDir);
    @@ -534,8 +531,26 @@ public class WsimportTool {
                     args.add(options.encoding);
                 }
     
    +            boolean addModules = true;
                 if (options.javacOptions != null) {
    -                args.addAll(options.getJavacOptions(args, listener));
    +                List javacOptions = options.getJavacOptions(args, listener);
    +                for (int i = 0; i < javacOptions.size(); i++) {
    +                    String opt = javacOptions.get(i);
    +                    if ("-source".equals(opt) && 9 >= getVersion(javacOptions.get(i + 1))) {
    +                        addModules = false;
    +                    }
    +                    if ("-target".equals(opt) && 9 >= getVersion(javacOptions.get(i + 1))) {
    +                        addModules = false;
    +                    }
    +                    if ("--release".equals(opt) && 9 >= getVersion(javacOptions.get(i + 1))) {
    +                        addModules = false;
    +                    }
    +                    args.add(opt);
    +                }
    +            }
    +            if (addModules) {
    +                args.add("--add-modules");
    +                args.add("java.xml.ws");
                 }
     
                 for (int i = 0; i < sourceFiles.size(); ++i) {
    @@ -572,4 +587,8 @@ public class WsimportTool {
             System.out.println(WscompileMessages.WSIMPORT_USAGE_EXTENSIONS());
             System.out.println(WscompileMessages.WSIMPORT_USAGE_EXAMPLES());
         }
    +
    +    private float getVersion(String s) {
    +        return Float.parseFloat(s);
    +    }
     }
    diff --git a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wsdl/parser/ContextClassloaderLocal.java b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wsdl/parser/ContextClassloaderLocal.java
    index c8c847907cd..e15ab93b9c1 100644
    --- a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wsdl/parser/ContextClassloaderLocal.java
    +++ b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wsdl/parser/ContextClassloaderLocal.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -25,10 +25,10 @@
     
     package com.sun.tools.internal.ws.wsdl.parser;
     
    +import com.sun.tools.internal.ws.resources.ContextClassloaderLocalMessages;
    +
     import java.security.AccessController;
     import java.security.PrivilegedAction;
    -import java.text.MessageFormat;
    -import java.util.ResourceBundle;
     import java.util.WeakHashMap;
     
     /**
    @@ -36,9 +36,7 @@ import java.util.WeakHashMap;
      */
     abstract class ContextClassloaderLocal {
     
    -    private static final String FAILED_TO_CREATE_NEW_INSTANCE = "FAILED_TO_CREATE_NEW_INSTANCE";
    -
    -    private WeakHashMap CACHE = new WeakHashMap();
    +    private WeakHashMap CACHE = new WeakHashMap<>();
     
         public V get() throws Error {
             ClassLoader tccl = getContextClassLoader();
    @@ -60,26 +58,21 @@ abstract class ContextClassloaderLocal {
             try {
                 return initialValue();
             } catch (Exception e) {
    -            throw new Error(format(FAILED_TO_CREATE_NEW_INSTANCE, getClass().getName()), e);
    +            throw new Error(ContextClassloaderLocalMessages.FAILED_TO_CREATE_NEW_INSTANCE(getClass().getName()), e);
             }
         }
     
    -    private static String format(String property, Object... args) {
    -        String text = ResourceBundle.getBundle(ContextClassloaderLocal.class.getName()).getString(property);
    -        return MessageFormat.format(text, args);
    -    }
    -
         private static ClassLoader getContextClassLoader() {
    -        return (ClassLoader)
    -                AccessController.doPrivileged(new PrivilegedAction() {
    -                    public Object run() {
    -                        ClassLoader cl = null;
    -                        try {
    -                            cl = Thread.currentThread().getContextClassLoader();
    -                        } catch (SecurityException ex) {
    -                        }
    -                        return cl;
    -                    }
    -                });
    +        return AccessController.doPrivileged(new PrivilegedAction() {
    +            @Override
    +            public ClassLoader run() {
    +                ClassLoader cl = null;
    +                try {
    +                    cl = Thread.currentThread().getContextClassLoader();
    +                } catch (SecurityException ex) {
    +                }
    +                return cl;
    +            }
    +        });
         }
     }
    diff --git a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wsdl/parser/ContextClassloaderLocal.properties b/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wsdl/parser/ContextClassloaderLocal.properties
    deleted file mode 100644
    index c0267b823ea..00000000000
    --- a/jaxws/src/jdk.xml.ws/share/classes/com/sun/tools/internal/ws/wsdl/parser/ContextClassloaderLocal.properties
    +++ /dev/null
    @@ -1,26 +0,0 @@
    -#
    -# Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
    -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    -#
    -# This code is free software; you can redistribute it and/or modify it
    -# under the terms of the GNU General Public License version 2 only, as
    -# published by the Free Software Foundation.  Oracle designates this
    -# particular file as subject to the "Classpath" exception as provided
    -# by Oracle in the LICENSE file that accompanied this code.
    -#
    -# This code is distributed in the hope that it will be useful, but WITHOUT
    -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    -# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    -# version 2 for more details (a copy is included in the LICENSE file that
    -# accompanied this code).
    -#
    -# You should have received a copy of the GNU General Public License version
    -# 2 along with this work; if not, write to the Free Software Foundation,
    -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    -#
    -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    -# or visit www.oracle.com if you need additional information or have any
    -# questions.
    -#
    -
    -FAILED_TO_CREATE_NEW_INSTANCE=Failed to create new instance of {0}
    diff --git a/jdk/.hgtags b/jdk/.hgtags
    index 140c6960e0f..d58a1758875 100644
    --- a/jdk/.hgtags
    +++ b/jdk/.hgtags
    @@ -396,9 +396,11 @@ c41140100bf1e5c10c7b8f3bde91c16eff7485f5 jdk-9+147
     d27bab22ff62823902d93d1d35ca397cfd50d059 jdk-9+151
     a20f2cf90762673e1bc4980fd6597e70a2578045 jdk-9+152
     1c4411322327aea3f91011ec3977a12a05b09629 jdk-9+153
    +f2325d80b37c2817e15039bf64189a08e29c6d39 jdk-10+0
     c97e7a8b8da062b9070df442f9cf308e10845fb7 jdk-9+154
     e170c858888e83d5c0994504599b6ed7a1fb0cfc jdk-9+155
     7d64e541a6c04c714bcad4c8b553db912f827cd5 jdk-9+156
    +e209a98d40a1c353199285f31ca0ff6f0d68264a jdk-10+1
     fdfa7b2fe9a7db06792eae20f97748f3e85bb83a jdk-9+157
     c476ca73750698fa5654e101af699ee45db38e2a jdk-9+158
     49b54a4d9e84b7ba956b8c27fced5035465146ae jdk-9+159
    @@ -409,11 +411,21 @@ f6bf027e88e9a4dd19f721001a7af00157af42c4 jdk-9+162
     6dea581453d7c0e767e3169cfec8b423a381e71d jdk-9+164
     a7942c3b1e59495dbf51dc7c41aab355fcd253d7 jdk-9+165
     5d2b48f1f0a322aca719b49ff02ab421705bffc7 jdk-9+166
    +5adecda6cf9a5623f983ea29e5511755ccfd1273 jdk-10+2
    +4723e1d233195e253f018e8a46732c7ffbe6ce90 jdk-10+3
    +37f8b938b680cf8fb551e9a48bffc5536b061fa8 jdk-10+4
    +d1436b2945383cef15edbdba9bb41ef1656c987b jdk-10+5
    +329609d00aef2443cf1e44ded94637c5ed55a143 jdk-10+6
     7828aedcb525df40b7c8122bcc3f997c75ebaf7f jdk-9+167
     e78da9db6299b3fcba49300d52e2359e82fdd218 jdk-9+168
     177436a54ca13730ffc725a6e5dbfcd9486f3da3 jdk-9+169
     ef9954f6896bb0b95ac62bf769f68b59a7a56ccd jdk-9+170
    +cbd65760a005766610583949b3b5c9ace92e74b3 jdk-10+7
    +f0adc10ed8316e6cf316e3208c5ecf6835d22bc4 jdk-10+8
    +b9409a7daa6c793dd631e52fe6ef79d08a3b337a jdk-10+9
     29bbedd4cce8e14742bdb22118c057b877c02f0f jdk-9+171
    +df64bd4757d0d130d62a22b8143ba31d3a16ac18 jdk-10+10
     0ff9ad7d067cd4fa14450cf208bf019175a0aaba jdk-9+172
    +7c54889c0ec649ee04643e5cace434623d0dc667 jdk-10+11
     a5506b425f1bf91530d8417b57360e5d89328c0c jdk-9+173
     42f18c931bd4fae5c206ccf6d8e591e4c4e69d31 jdk-9+174
    diff --git a/jdk/.jcheck/conf b/jdk/.jcheck/conf
    index 5c6f62dc12c..b2581358014 100644
    --- a/jdk/.jcheck/conf
    +++ b/jdk/.jcheck/conf
    @@ -1 +1 @@
    -project=jdk9
    +project=jdk10
    diff --git a/jdk/make/launcher/Launcher-java.base.gmk b/jdk/make/launcher/Launcher-java.base.gmk
    index f70d90029a6..06ccec771ea 100644
    --- a/jdk/make/launcher/Launcher-java.base.gmk
    +++ b/jdk/make/launcher/Launcher-java.base.gmk
    @@ -1,5 +1,5 @@
     #
    -# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
    +# Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved.
     # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     #
     # This code is free software; you can redistribute it and/or modify it
    @@ -71,102 +71,37 @@ $(eval $(call SetupBuildLauncher, keytool, \
     
     ################################################################################
     
    -BUILD_JEXEC :=
    -BUILD_JEXEC_SRC :=
    -BUILD_JEXEC_INC :=
    -BUILD_JEXEC_DST_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/java.base
    -
    -#
    -# UNHANDLED:
    -# - COMPILE_APPROACH = normal
    -#
    -
    -#
    -# jdk/make/java/Makefile
    -#
    -ifeq ($(OPENJDK_TARGET_OS), solaris)
    -  ifeq ($(OPENJDK_TARGET_CPU_BITS), 32)
    -    BUILD_JEXEC := 1
    -  endif
    -endif
    -
     ifeq ($(OPENJDK_TARGET_OS), linux)
    -  BUILD_JEXEC := 1
    -endif # OPENJDK_TARGET_OS
    -
    -#
    -# jdk/make/java/jexec/Makefile
    -#
    -ifeq ($(BUILD_JEXEC), 1)
    -
    -  ifeq ($(OPENJDK_TARGET_OS), windows)
    -  else ifeq ($(OPENJDK_TARGET_OS), macosx)
    -    BUILD_JEXEC_SRC := $(JDK_TOPDIR)/src/java.base/macosx/native/launcher
    -  else
    -    BUILD_JEXEC_SRC := $(JDK_TOPDIR)/src/java.base/unix/native/launcher
    -  endif
    -
    -  ifeq ($(OPENJDK_TARGET_OS), linux)
    -    BUILD_JEXEC_DST_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/java.base
    -    BUILD_JEXEC_INC += -I$(JDK_TOPDIR)/src/java.base/share/native/libjli
    -  endif
    -endif
    -
    -#
    -# Note that the two Makefile's seems to contradict each other,
    -# and that src/macosx/bin/jexec.c seems unused
    -#
    -ifneq ($(BUILD_JEXEC_SRC), )
    -  $(eval $(call SetupNativeCompilation,BUILD_JEXEC, \
    -      SRC := $(BUILD_JEXEC_SRC), \
    +  $(eval $(call SetupNativeCompilation, BUILD_JEXEC, \
    +      SRC := $(JDK_TOPDIR)/src/$(MODULE)/unix/native/launcher, \
           INCLUDE_FILES := jexec.c, \
           OPTIMIZATION := LOW, \
           CFLAGS := $(CFLAGS_JDKEXE) \
    -          $(BUILD_JEXEC_INC), \
    +          -I$(JDK_TOPDIR)/src/$(MODULE)/share/native/libjli, \
           CFLAGS_linux := -fPIC, \
           CFLAGS_solaris := -KPIC, \
           LDFLAGS := $(LDFLAGS_JDKEXE), \
           OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/jexec_obj, \
    -      OUTPUT_DIR := $(BUILD_JEXEC_DST_DIR), \
    -      PROGRAM := jexec))
    +      OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \
    +      PROGRAM := jexec, \
    +  ))
     
       TARGETS += $(BUILD_JEXEC)
     endif
     
     ################################################################################
     
    -BUILD_JSPAWNHELPER :=
    -BUILD_JSPAWNHELPER_SRC := $(JDK_TOPDIR)/src/java.base/unix/native/jspawnhelper
    -JSPAWNHELPER_CFLAGS := -I$(JDK_TOPDIR)/src/java.base/unix/native/libjava
    -BUILD_JSPAWNHELPER_DST_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/java.base
    -LINK_JSPAWNHELPER_OBJECTS := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libjava/childproc.o
    -BUILD_JSPAWNHELPER_LDFLAGS :=
    -
     ifneq ($(findstring $(OPENJDK_TARGET_OS), macosx solaris aix), )
    -  BUILD_JSPAWNHELPER := 1
    -endif
    -
    -ifeq ($(OPENJDK_TARGET_OS), macosx)
    -  BUILD_JSPAWNHELPER_DST_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/java.base
    -endif
    -
    -ifeq ($(OPENJDK_TARGET_CPU_BITS), 64)
    -  BUILD_JSPAWNHELPER_LDFLAGS += $(COMPILER_TARGET_BITS_FLAG)64
    -endif
    -
    -ifeq ($(BUILD_JSPAWNHELPER), 1)
    -  $(eval $(call SetupNativeCompilation,BUILD_JSPAWNHELPER, \
    -      SRC := $(BUILD_JSPAWNHELPER_SRC), \
    -      INCLUDE_FILES := jspawnhelper.c, \
    +  $(eval $(call SetupNativeCompilation, BUILD_JSPAWNHELPER, \
    +      SRC := $(JDK_TOPDIR)/src/$(MODULE)/unix/native/jspawnhelper, \
           OPTIMIZATION := LOW, \
    -      CFLAGS := $(CFLAGS_JDKEXE) $(JSPAWNHELPER_CFLAGS), \
    -      LDFLAGS := $(LDFLAGS_JDKEXE) $(BUILD_JSPAWNHELPER_LDFLAGS), \
    -      LIBS := $(LINK_JSPAWNHELPER_OBJECTS), \
    +      CFLAGS := $(CFLAGS_JDKEXE) -I$(JDK_TOPDIR)/src/$(MODULE)/unix/native/libjava, \
    +      EXTRA_OBJECT_FILES := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/libjava/childproc.o, \
    +      LDFLAGS := $(LDFLAGS_JDKEXE), \
           OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/jspawnhelper, \
    -      OUTPUT_DIR := $(BUILD_JSPAWNHELPER_DST_DIR), \
    -      PROGRAM := jspawnhelper))
    -
    -  $(BUILD_JSPAWNHELPER): $(LINK_JSPAWNHELPER_OBJECTS)
    +      OUTPUT_DIR := $(SUPPORT_OUTPUTDIR)/modules_libs/$(MODULE), \
    +      PROGRAM := jspawnhelper, \
    +  ))
     
       TARGETS += $(BUILD_JSPAWNHELPER)
     endif
    diff --git a/jdk/make/launcher/Launcher-jdk.aot.gmk b/jdk/make/launcher/Launcher-jdk.aot.gmk
    index 9aea620ac9e..2a46c7a6a13 100644
    --- a/jdk/make/launcher/Launcher-jdk.aot.gmk
    +++ b/jdk/make/launcher/Launcher-jdk.aot.gmk
    @@ -30,7 +30,7 @@ include LauncherCommon.gmk
     
     $(eval $(call SetupBuildLauncher, jaotc, \
         MAIN_CLASS := jdk.tools.jaotc.Main, \
    -    JAVA_ARGS := -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI \
    +    EXTRA_JAVA_ARGS := -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.aarch64=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.amd64=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.code=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
    @@ -38,12 +38,13 @@ $(eval $(call SetupBuildLauncher, jaotc, \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.code.stack=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.common=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.hotspot=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
    -        --add-exports=jdk.internal.vm.ci/jdk.vm.ci.hotspot.aarch64=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
    +    , \
    +    JAVA_ARGS := --add-exports=jdk.internal.vm.ci/jdk.vm.ci.hotspot.aarch64=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.hotspot.amd64=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.hotspot.sparc=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.meta=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
             --add-exports=jdk.internal.vm.ci/jdk.vm.ci.runtime=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
    -        --add-exports=jdk.internal.vm.ci/jdk.vm.ci.sparc=$(call CommaList, jdk.internal.vm.compiler  jdk.aot) \
    +        --add-exports=jdk.internal.vm.ci/jdk.vm.ci.sparc=$(call CommaList, jdk.internal.vm.compiler  jdk.aot)  \
             -XX:+UseAOT \
             -Djvmci.UseProfilingInformation=false \
             -Dgraal.UseExceptionProbability=false \
    diff --git a/jdk/make/launcher/LauncherCommon.gmk b/jdk/make/launcher/LauncherCommon.gmk
    index a4178039d6e..08938e05fb2 100644
    --- a/jdk/make/launcher/LauncherCommon.gmk
    +++ b/jdk/make/launcher/LauncherCommon.gmk
    @@ -66,7 +66,10 @@ JAVA_MANIFEST := $(JDK_TOPDIR)/src/java.base/windows/native/launcher/java.manife
     # MAIN_MODULE  The module of the main class to launch if different from the
     #     current module
     # MAIN_CLASS   The Java main class to launch
    -# JAVA_ARGS   Processed into a -DJAVA_ARGS C flag
    +# JAVA_ARGS   Processed into a -DJAVA_ARGS and added to CFLAGS
    +# EXTRA_JAVA_ARGS Processed into a -DEXTRA_JAVA_ARGS and is prepended
    +#     before JAVA_ARGS to CFLAGS, primarily to allow long string literal
    +#     compile time defines exceeding Visual Studio 2013 limitations.
     # CFLAGS   Additional CFLAGS
     # CFLAGS_windows   Additional CFLAGS_windows
     # LIBS_unix   Additional LIBS_unix
    @@ -104,6 +107,11 @@ define SetupBuildLauncherBody
       endif
     
       ifneq ($$($1_JAVA_ARGS), )
    +    ifneq ($$($1_EXTRA_JAVA_ARGS), )
    +      $1_EXTRA_JAVA_ARGS_STR := '{ $$(strip $$(foreach a, \
    +        $$(addprefix -J, $$($1_EXTRA_JAVA_ARGS)), "$$a"$(COMMA) )) }'
    +      $1_CFLAGS += -DEXTRA_JAVA_ARGS=$$($1_EXTRA_JAVA_ARGS_STR)
    +    endif
         $1_JAVA_ARGS_STR := '{ $$(strip $$(foreach a, \
             $$(addprefix -J, $$($1_JAVA_ARGS)) -m $$($1_MAIN_MODULE)/$$($1_MAIN_CLASS), "$$a"$(COMMA) )) }'
         $1_CFLAGS += -DJAVA_ARGS=$$($1_JAVA_ARGS_STR)
    diff --git a/jdk/make/lib/CoreLibraries.gmk b/jdk/make/lib/CoreLibraries.gmk
    index 5bb93942087..224b3392a03 100644
    --- a/jdk/make/lib/CoreLibraries.gmk
    +++ b/jdk/make/lib/CoreLibraries.gmk
    @@ -132,7 +132,8 @@ TARGETS += $(BUILD_LIBVERIFY)
     
     ##########################################################################################
     
    -LIBJAVA_SRC_DIRS := $(call FindSrcDirsForLib, java.base, java)
    +# Allow a custom makefile to add extra src dirs
    +LIBJAVA_SRC_DIRS += $(call FindSrcDirsForLib, java.base, java)
     
     LIBJAVA_CFLAGS := $(addprefix -I, $(LIBJAVA_SRC_DIRS)) \
         -I$(JDK_TOPDIR)/src/java.base/share/native/libfdlibm \
    diff --git a/jdk/make/src/classes/build/tools/cldrconverter/LDMLParseHandler.java b/jdk/make/src/classes/build/tools/cldrconverter/LDMLParseHandler.java
    index 8683f282581..b229c91731f 100644
    --- a/jdk/make/src/classes/build/tools/cldrconverter/LDMLParseHandler.java
    +++ b/jdk/make/src/classes/build/tools/cldrconverter/LDMLParseHandler.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -549,12 +549,20 @@ class LDMLParseHandler extends AbstractLDMLHandler {
             case "decimal":
                 // for FormatData
                 // copy string for later assembly into NumberElements
    -            pushStringEntry(qName, attributes, currentNumberingSystem + "NumberElements/decimal");
    +            if (currentContainer.getqName().equals("symbols")) {
    +                pushStringEntry(qName, attributes, currentNumberingSystem + "NumberElements/decimal");
    +            } else {
    +                pushIgnoredContainer(qName);
    +            }
                 break;
             case "group":
                 // for FormatData
                 // copy string for later assembly into NumberElements
    -            pushStringEntry(qName, attributes, currentNumberingSystem + "NumberElements/group");
    +            if (currentContainer.getqName().equals("symbols")) {
    +                pushStringEntry(qName, attributes, currentNumberingSystem + "NumberElements/group");
    +            } else {
    +                pushIgnoredContainer(qName);
    +            }
                 break;
             case "list":
                 // for FormatData
    diff --git a/jdk/src/java.base/aix/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java b/jdk/src/java.base/aix/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java
    new file mode 100644
    index 00000000000..1ba654eb28e
    --- /dev/null
    +++ b/jdk/src/java.base/aix/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java
    @@ -0,0 +1,47 @@
    +/*
    + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
    + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    + *
    + * This code is free software; you can redistribute it and/or modify it
    + * under the terms of the GNU General Public License version 2 only, as
    + * published by the Free Software Foundation.  Oracle designates this
    + * particular file as subject to the "Classpath" exception as provided
    + * by Oracle in the LICENSE file that accompanied this code.
    + *
    + * This code is distributed in the hope that it will be useful, but WITHOUT
    + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    + * version 2 for more details (a copy is included in the LICENSE file that
    + * accompanied this code).
    + *
    + * You should have received a copy of the GNU General Public License version
    + * 2 along with this work; if not, write to the Free Software Foundation,
    + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    + *
    + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    + * or visit www.oracle.com if you need additional information or have any
    + * questions.
    + */
    +
    +package sun.nio.ch;
    +
    +import java.nio.channels.spi.AsynchronousChannelProvider;
    +
    +/**
    + * Creates this platform's default AsynchronousChannelProvider
    + */
    +
    +public class DefaultAsynchronousChannelProvider {
    +
    +    /**
    +     * Prevent instantiation.
    +     */
    +    private DefaultAsynchronousChannelProvider() { }
    +
    +    /**
    +     * Returns the default AsynchronousChannelProvider.
    +     */
    +    public static AsynchronousChannelProvider create() {
    +        return new AixAsynchronousChannelProvider();
    +    }
    +}
    diff --git a/jdk/src/java.base/aix/classes/sun/nio/ch/DefaultSelectorProvider.java b/jdk/src/java.base/aix/classes/sun/nio/ch/DefaultSelectorProvider.java
    index 3f23cc4fa3b..dbc3ab61de8 100644
    --- a/jdk/src/java.base/aix/classes/sun/nio/ch/DefaultSelectorProvider.java
    +++ b/jdk/src/java.base/aix/classes/sun/nio/ch/DefaultSelectorProvider.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -42,7 +42,6 @@ public class DefaultSelectorProvider {
          * Returns the default SelectorProvider.
          */
         public static SelectorProvider create() {
    -        return new sun.nio.ch.PollSelectorProvider();
    +        return new PollSelectorProvider();
         }
    -
     }
    diff --git a/jdk/src/java.base/aix/native/libnet/aix_close.c b/jdk/src/java.base/aix/native/libnet/aix_close.c
    index 51bf81f1d21..f7e14cd0ef6 100644
    --- a/jdk/src/java.base/aix/native/libnet/aix_close.c
    +++ b/jdk/src/java.base/aix/native/libnet/aix_close.c
    @@ -1,6 +1,6 @@
     /*
    - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
    - * Copyright (c) 2016, SAP SE and/or its affiliates. All rights reserved.
    + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2016, 2017, SAP SE and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -65,6 +65,8 @@
     #include 
     #include 
     #include 
    +#include "jvm.h"
    +#include "net_util.h"
     
     /*
      * Stack allocated by thread when doing blocking operation
    @@ -503,9 +505,9 @@ int NET_Poll(struct pollfd *ufds, unsigned int nfds, int timeout) {
      * Auto restarts with adjusted timeout if interrupted by
      * signal other than our wakeup signal.
      */
    -int NET_Timeout0(int s, long timeout, long currentTime) {
    -    long prevtime = currentTime, newtime;
    -    struct timeval t;
    +int NET_Timeout(JNIEnv *env, int s, long timeout, jlong nanoTimeStamp) {
    +    jlong prevNanoTime = nanoTimeStamp;
    +    jlong nanoTimeout = (jlong) timeout * NET_NSEC_PER_MSEC;
         fdEntry_t *fdEntry = getFdEntry(s);
     
         /*
    @@ -529,7 +531,7 @@ int NET_Timeout0(int s, long timeout, long currentTime) {
             pfd.events = POLLIN | POLLERR;
     
             startOp(fdEntry, &self);
    -        rv = poll(&pfd, 1, timeout);
    +        rv = poll(&pfd, 1, nanoTimeout / NET_NSEC_PER_MSEC);
             endOp(fdEntry, &self);
     
             /*
    @@ -537,18 +539,14 @@ int NET_Timeout0(int s, long timeout, long currentTime) {
              * has expired return 0 (indicating timeout expired).
              */
             if (rv < 0 && errno == EINTR) {
    -            if (timeout > 0) {
    -                gettimeofday(&t, NULL);
    -                newtime = t.tv_sec * 1000  +  t.tv_usec / 1000;
    -                timeout -= newtime - prevtime;
    -                if (timeout <= 0) {
    -                    return 0;
    -                }
    -                prevtime = newtime;
    +            jlong newNanoTime = JVM_NanoTime(env, 0);
    +            nanoTimeout -= newNanoTime - prevNanoTime;
    +            if (nanoTimeout < NET_NSEC_PER_MSEC) {
    +                return 0;
                 }
    +            prevNanoTime = newNanoTime;
             } else {
                 return rv;
             }
    -
         }
     }
    diff --git a/jdk/src/java.base/linux/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java b/jdk/src/java.base/linux/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java
    new file mode 100644
    index 00000000000..f2354103264
    --- /dev/null
    +++ b/jdk/src/java.base/linux/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java
    @@ -0,0 +1,47 @@
    +/*
    + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
    + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    + *
    + * This code is free software; you can redistribute it and/or modify it
    + * under the terms of the GNU General Public License version 2 only, as
    + * published by the Free Software Foundation.  Oracle designates this
    + * particular file as subject to the "Classpath" exception as provided
    + * by Oracle in the LICENSE file that accompanied this code.
    + *
    + * This code is distributed in the hope that it will be useful, but WITHOUT
    + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    + * version 2 for more details (a copy is included in the LICENSE file that
    + * accompanied this code).
    + *
    + * You should have received a copy of the GNU General Public License version
    + * 2 along with this work; if not, write to the Free Software Foundation,
    + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    + *
    + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    + * or visit www.oracle.com if you need additional information or have any
    + * questions.
    + */
    +
    +package sun.nio.ch;
    +
    +import java.nio.channels.spi.AsynchronousChannelProvider;
    +
    +/**
    + * Creates this platform's default AsynchronousChannelProvider
    + */
    +
    +public class DefaultAsynchronousChannelProvider {
    +
    +    /**
    +     * Prevent instantiation.
    +     */
    +    private DefaultAsynchronousChannelProvider() { }
    +
    +    /**
    +     * Returns the default AsynchronousChannelProvider.
    +     */
    +    public static AsynchronousChannelProvider create() {
    +        return new LinuxAsynchronousChannelProvider();
    +    }
    +}
    diff --git a/jdk/src/java.base/linux/classes/sun/nio/ch/DefaultSelectorProvider.java b/jdk/src/java.base/linux/classes/sun/nio/ch/DefaultSelectorProvider.java
    index 1278f1583ee..77531b283b3 100644
    --- a/jdk/src/java.base/linux/classes/sun/nio/ch/DefaultSelectorProvider.java
    +++ b/jdk/src/java.base/linux/classes/sun/nio/ch/DefaultSelectorProvider.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -42,7 +42,6 @@ public class DefaultSelectorProvider {
          * Returns the default SelectorProvider.
          */
         public static SelectorProvider create() {
    -        return new sun.nio.ch.EPollSelectorProvider();
    +        return new EPollSelectorProvider();
         }
    -
     }
    diff --git a/jdk/src/java.base/linux/native/libnet/linux_close.c b/jdk/src/java.base/linux/native/libnet/linux_close.c
    index 2bf7cc72283..d2b60a9e96e 100644
    --- a/jdk/src/java.base/linux/native/libnet/linux_close.c
    +++ b/jdk/src/java.base/linux/native/libnet/linux_close.c
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -37,6 +37,8 @@
     #include 
     #include 
     #include 
    +#include "jvm.h"
    +#include "net_util.h"
     
     /*
      * Stack allocated by thread when doing blocking operation
    @@ -410,9 +412,9 @@ int NET_Poll(struct pollfd *ufds, unsigned int nfds, int timeout) {
      * Auto restarts with adjusted timeout if interrupted by
      * signal other than our wakeup signal.
      */
    -int NET_Timeout0(int s, long timeout, long currentTime) {
    -    long prevtime = currentTime, newtime;
    -    struct timeval t;
    +int NET_Timeout(JNIEnv *env, int s, long timeout, jlong nanoTimeStamp) {
    +    jlong prevNanoTime = nanoTimeStamp;
    +    jlong nanoTimeout = (jlong)timeout * NET_NSEC_PER_MSEC;
         fdEntry_t *fdEntry = getFdEntry(s);
     
         /*
    @@ -436,26 +438,21 @@ int NET_Timeout0(int s, long timeout, long currentTime) {
             pfd.events = POLLIN | POLLERR;
     
             startOp(fdEntry, &self);
    -        rv = poll(&pfd, 1, timeout);
    +        rv = poll(&pfd, 1, nanoTimeout / NET_NSEC_PER_MSEC);
             endOp(fdEntry, &self);
    -
             /*
              * If interrupted then adjust timeout. If timeout
              * has expired return 0 (indicating timeout expired).
              */
             if (rv < 0 && errno == EINTR) {
    -            if (timeout > 0) {
    -                gettimeofday(&t, NULL);
    -                newtime = t.tv_sec * 1000  +  t.tv_usec / 1000;
    -                timeout -= newtime - prevtime;
    -                if (timeout <= 0) {
    -                    return 0;
    -                }
    -                prevtime = newtime;
    +            jlong newNanoTime = JVM_NanoTime(env, 0);
    +            nanoTimeout -= newNanoTime - prevNanoTime;
    +            if (nanoTimeout < NET_NSEC_PER_MSEC) {
    +                return 0;
                 }
    +            prevNanoTime = newNanoTime;
             } else {
                 return rv;
             }
    -
         }
     }
    diff --git a/jdk/src/java.base/macosx/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java b/jdk/src/java.base/macosx/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java
    new file mode 100644
    index 00000000000..8bb368223e4
    --- /dev/null
    +++ b/jdk/src/java.base/macosx/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java
    @@ -0,0 +1,47 @@
    +/*
    + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
    + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    + *
    + * This code is free software; you can redistribute it and/or modify it
    + * under the terms of the GNU General Public License version 2 only, as
    + * published by the Free Software Foundation.  Oracle designates this
    + * particular file as subject to the "Classpath" exception as provided
    + * by Oracle in the LICENSE file that accompanied this code.
    + *
    + * This code is distributed in the hope that it will be useful, but WITHOUT
    + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    + * version 2 for more details (a copy is included in the LICENSE file that
    + * accompanied this code).
    + *
    + * You should have received a copy of the GNU General Public License version
    + * 2 along with this work; if not, write to the Free Software Foundation,
    + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    + *
    + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    + * or visit www.oracle.com if you need additional information or have any
    + * questions.
    + */
    +
    +package sun.nio.ch;
    +
    +import java.nio.channels.spi.AsynchronousChannelProvider;
    +
    +/**
    + * Creates this platform's default AsynchronousChannelProvider
    + */
    +
    +public class DefaultAsynchronousChannelProvider {
    +
    +    /**
    +     * Prevent instantiation.
    +     */
    +    private DefaultAsynchronousChannelProvider() { }
    +
    +    /**
    +     * Returns the default AsynchronousChannelProvider.
    +     */
    +    public static AsynchronousChannelProvider create() {
    +        return new BsdAsynchronousChannelProvider();
    +    }
    +}
    diff --git a/jdk/src/java.base/macosx/classes/sun/nio/ch/DefaultSelectorProvider.java b/jdk/src/java.base/macosx/classes/sun/nio/ch/DefaultSelectorProvider.java
    index e55f8e6bf34..c7d67b27ecd 100644
    --- a/jdk/src/java.base/macosx/classes/sun/nio/ch/DefaultSelectorProvider.java
    +++ b/jdk/src/java.base/macosx/classes/sun/nio/ch/DefaultSelectorProvider.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -42,7 +42,6 @@ public class DefaultSelectorProvider {
          * Returns the default SelectorProvider.
          */
         public static SelectorProvider create() {
    -        return new sun.nio.ch.KQueueSelectorProvider();
    +        return new KQueueSelectorProvider();
         }
    -
     }
    diff --git a/jdk/src/java.base/macosx/native/launcher/jexec.c b/jdk/src/java.base/macosx/native/launcher/jexec.c
    deleted file mode 100644
    index 24df31f5288..00000000000
    --- a/jdk/src/java.base/macosx/native/launcher/jexec.c
    +++ /dev/null
    @@ -1,239 +0,0 @@
    -/*
    - * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
    - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    - *
    - * This code is free software; you can redistribute it and/or modify it
    - * under the terms of the GNU General Public License version 2 only, as
    - * published by the Free Software Foundation.  Oracle designates this
    - * particular file as subject to the "Classpath" exception as provided
    - * by Oracle in the LICENSE file that accompanied this code.
    - *
    - * This code is distributed in the hope that it will be useful, but WITHOUT
    - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    - * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    - * version 2 for more details (a copy is included in the LICENSE file that
    - * accompanied this code).
    - *
    - * You should have received a copy of the GNU General Public License version
    - * 2 along with this work; if not, write to the Free Software Foundation,
    - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    - *
    - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    - * or visit www.oracle.com if you need additional information or have any
    - * questions.
    - */
    -
    -/*
    - * jexec for J2SE
    - *
    - * jexec is used by the system to allow execution of JAR files.
    - *    Essentially jexec needs to run java and
    - *    needs to be a native ISA executable (not a shell script), although
    - *    this native ISA executable requirement was a mistake that will be fixed.
    - *    ( is sparc or i386 or amd64).
    - *
    - *    When you execute a jar file, jexec is executed by the system as follows:
    - *      /usr/java/jre/lib//jexec -jar JARFILENAME
    - *    so this just needs to be turned into:
    - *      /usr/java/jre/bin/java -jar JARFILENAME
    - *
    - * Solaris systems (new 7's and all 8's) will be looking for jexec at:
    - *      /usr/java/jre/lib//jexec
    - * Older systems may need to add this to their /etc/system file:
    - *      set javaexec:jexec="/usr/java/jre/lib//jexec"
    - *     and reboot the machine for this to work.
    - *
    - * This source should be compiled as:
    - *      cc -o jexec jexec.c
    - *
    - * And jexec should be placed at the following location of the installation:
    - *      /jre/lib//jexec  (for Solaris)
    - *      /lib/jexec            (for Linux)
    - *
    - * NOTE: Unless  is the "default" JDK on the system
    - *       (i.e. /usr/java -> ), this jexec will not be
    - *       found.  The 1.2 java is only the default on Solaris 8 and
    - *       on systems where the 1.2 packages were installed and no 1.1
    - *       java was found.
    - *
    - * NOTE: You must use 1.2 jar to build your jar files. The system
    - *       doesn't seem to pick up 1.1 jar files.
    - *
    - * NOTE: We don't need to set LD_LIBRARY_PATH here, even though we
    - *       are running the actual java binary because the java binary will
    - *       look for it's libraries through it's own runpath, which uses
    - *       $ORIGIN.
    - *
    - * NOTE: This jexec should NOT have any special .so library needs because
    - *       it appears that this executable will NOT get the $ORIGIN of jexec
    - *       but the $ORIGIN of the jar file being executed. Be careful to keep
    - *       this program simple and with no .so dependencies.
    - */
    -
    -#include 
    -#include 
    -#include 
    -#include 
    -#include 
    -#include 
    -
    -static const int CRAZY_EXEC = ENOEXEC;
    -static const int BAD_MAGIC  = ENOEXEC;
    -
    -static const char * BAD_EXEC_MSG     = "jexec failed";
    -static const char * CRAZY_EXEC_MSG   = "missing args";
    -static const char * MISSING_JAVA_MSG = "can't locate java";
    -static const char * UNKNOWN_ERROR    = "unknown error";
    -
    -/* Define a constant that represents the number of directories to pop off the
    - * current location to find the java binary */
    -static const int RELATIVE_DEPTH = 3;
    -
    -/* path to java after popping */
    -static const char * BIN_PATH = "/bin/java";
    -
    -/* flag used when running JAR files */
    -static const char * JAR_FLAG = "-jar";
    -
    -int main(int argc, const char * argv[]);
    -void errorExit(int error, const char * message);
    -int getJavaPath(const char * path, char * buf, int depth);
    -
    -/*
    - * This is the main entry point.  This program (jexec) will attempt to execute
    - * a JAR file by finding the Java program (java), relative to its own location.
    - * The exact location of the Java program depends on the platform, i.e.
    - *
    - *      /jre/lib//jexec  (for Solaris)
    - *      /lib/jexec            (for Linux JDK)
    - *
    - * Once the Java program is found, this program copies any remaining arguments
    - * into another array, which is then used to exec the Java program.
    - *
    - * On Linux this program does some additional steps.  When copying the array of
    - * args, it is necessary to insert the "-jar" flag between arg[0], the program
    - * name, and the original arg[1], which is presumed to be a path to a JAR file.
    - * It is also necessary to verify that the original arg[1] really is a JAR file.
    - * (These steps are unnecessary on Solaris because they are taken care of by
    - * the kernel.)
    - */
    -int main(int argc, const char * argv[]) {
    -    /* We need to exec the original arguments using java, instead of jexec.
    -     * Also, for Linux, it is necessary to add the "-jar" argument between
    -     * the new arg[0], and the old arg[1].  To do this we will create a new
    -     * args array. */
    -    char          java[PATH_MAX + 1];    /* path to java binary  */
    -    const char ** nargv = NULL;          /* new args array       */
    -    int           nargc = 0;             /* new args array count */
    -    int           argi  = 0;             /* index into old array */
    -
    -    /* Make sure we have something to work with */
    -    if ((argc < 1) || (argv == NULL)) {
    -        /* Shouldn't happen... */
    -        errorExit(CRAZY_EXEC, CRAZY_EXEC_MSG);
    -    }
    -
    -    /* Get the path to the java binary, which is in a known position relative
    -     * to our current position, which is in argv[0]. */
    -    if (getJavaPath(argv[argi++], java, RELATIVE_DEPTH) != 0) {
    -        errorExit(errno, MISSING_JAVA_MSG);
    -    }
    -
    -    nargv = (const char **) malloc((argc + 2) * (sizeof (const char *)));
    -    nargv[nargc++] = java;
    -
    -    if (argc >= 2) {
    -        const char * jarfile = argv[argi++];
    -        const char * message = NULL;
    -
    -        /* the next argument is the path to the JAR file */
    -        nargv[nargc++] = jarfile;
    -    }
    -
    -    /* finally copy any remaining arguments */
    -    while (argi < argc) {
    -        nargv[nargc++] = argv[argi++];
    -    }
    -
    -    /* finally add one last terminating null */
    -    nargv[nargc++] = NULL;
    -
    -    /* It's time to exec the java binary with the new arguments.  It
    -     * is possible that we've reached this point without actually
    -     * having a JAR file argument (i.e. if argc < 2), but we still
    -     * want to exec the java binary, since that will take care of
    -     * displaying the correct usage. */
    -    execv(java, (char * const *) nargv);
    -
    -    /* If the exec worked, this process would have been replaced
    -     * by the new process.  So any code reached beyond this point
    -     * implies an error in the exec. */
    -    free(nargv);
    -    errorExit(errno, BAD_EXEC_MSG);
    -    return 0; // keep the compiler happy
    -}
    -
    -
    -/*
    - * Exit the application by setting errno, and writing a message.
    - *
    - * Parameters:
    - *     error   - errno is set to this value, and it is used to exit.
    - *     message - the message to write.
    - */
    -void errorExit(int error, const char * message) {
    -    if (error != 0) {
    -        errno = error;
    -        perror((message != NULL) ? message : UNKNOWN_ERROR);
    -    }
    -
    -    exit((error == 0) ? 0 : 1);
    -}
    -
    -
    -/*
    - * Get the path to the java binary that should be relative to the current path.
    - *
    - * Parameters:
    - *     path  - the input path that the java binary that should be relative to.
    - *     buf   - a buffer of size PATH_MAX or greater that the java path is
    - *             copied to.
    - *     depth - the number of names to trim off the current path, including the
    - *             name of this program.
    - *
    - * Returns:
    - *     This function returns 0 on success; otherwise it returns the value of
    - *     errno.
    - */
    -int getJavaPath(const char * path, char * buf, int depth) {
    -    int result = 0;
    -
    -    /* Get the full path to this program.  Depending on whether this is Solaris
    -     * or Linux, this will be something like,
    -     *
    -     *     /jre/lib//jexec  (for Solaris)
    -     *     /lib/jexec            (for Linux)
    -     */
    -    if (realpath(path, buf) != NULL) {
    -        int count = 0;
    -
    -        /* Pop off the filename, and then subdirectories for each level of
    -         * depth */
    -        for (count = 0; count < depth; count++) {
    -            *(strrchr(buf, '/')) = '\0';
    -        }
    -
    -        /* Append the relative location of java, creating something like,
    -         *
    -         *     /jre/bin/java  (for Solaris)
    -         *     /bin/java      (for Linux)
    -         */
    -        strcat(buf, BIN_PATH);
    -    }
    -    else {
    -        /* Failed to get the path */
    -        result = errno;
    -    }
    -
    -    return (result);
    -}
    diff --git a/jdk/src/java.base/macosx/native/libjli/java_md_macosx.c b/jdk/src/java.base/macosx/native/libjli/java_md_macosx.c
    index f21201ced6a..0abf273921b 100644
    --- a/jdk/src/java.base/macosx/native/libjli/java_md_macosx.c
    +++ b/jdk/src/java.base/macosx/native/libjli/java_md_macosx.c
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -136,8 +136,7 @@ struct NSAppArgs {
      *  |
      * \|/
      * ParseArguments
    - * (removes -d32 and -d64 if any,
    - *  processes version options,
    + * (processes version options,
      *  creates argument list for vm,
      *  etc.)
      *   |
    @@ -147,20 +146,20 @@ struct NSAppArgs {
      *   |
      *   |
      *  \|/
    - * Path is desired JRE ? YES --> Have Desired Model ? NO --> Re-exec --> Main
    - *  NO                               YES --> Continue
    + * Path is desired JRE ? YES --> Continue
    + *  NO
      *   |
      *   |
      *  \|/
      * Paths have well known
    - * jvm paths ?       --> NO --> Have Desired Model ? NO --> Re-exec --> Main
    - *  YES                              YES --> Continue
    + * jvm paths ?       --> NO --> Continue
    + *  YES
      *   |
      *   |
      *  \|/
      *  Does libjvm.so exist
    - *  in any of them ? --> NO --> Have Desired Model ? NO --> Re-exec --> Main
    - *   YES                             YES --> Continue
    + *  in any of them ? --> NO --> Continue
    + *   YES
      *   |
      *   |
      *  \|/
    @@ -217,7 +216,7 @@ static InvocationFunctions *GetExportedJNIFunctions() {
         }
     
         char jvmPath[PATH_MAX];
    -    jboolean gotJVMPath = GetJVMPath(jrePath, preferredJVM, jvmPath, sizeof(jvmPath), CURRENT_DATA_MODEL);
    +    jboolean gotJVMPath = GetJVMPath(jrePath, preferredJVM, jvmPath, sizeof(jvmPath));
         if (!gotJVMPath) {
             JLI_ReportErrorMessage("Failed to GetJVMPath()");
             return NULL;
    @@ -362,203 +361,51 @@ CreateExecutionEnvironment(int *pargc, char ***pargv,
                                char jrepath[], jint so_jrepath,
                                char jvmpath[], jint so_jvmpath,
                                char jvmcfg[],  jint so_jvmcfg) {
    -  /*
    -   * First, determine if we are running the desired data model.  If we
    -   * are running the desired data model, all the error messages
    -   * associated with calling GetJREPath, ReadKnownVMs, etc. should be
    -   * output.  However, if we are not running the desired data model,
    -   * some of the errors should be suppressed since it is more
    -   * informative to issue an error message based on whether or not the
    -   * os/processor combination has dual mode capabilities.
    -   */
         jboolean jvmpathExists;
     
         /* Compute/set the name of the executable */
         SetExecname(*pargv);
     
    -    /* Check data model flags, and exec process, if needed */
    -    {
    -      char * jvmtype    = NULL;
    -      int  argc         = *pargc;
    -      char **argv       = *pargv;
    -      int running       = CURRENT_DATA_MODEL;
    +    char * jvmtype    = NULL;
    +    int  argc         = *pargc;
    +    char **argv       = *pargv;
     
    -      int wanted        = running;      /* What data mode is being
    -                                           asked for? Current model is
    -                                           fine unless another model
    -                                           is asked for */
    -
    -      char** newargv    = NULL;
    -      int    newargc    = 0;
    -
    -      /*
    -       * Starting in 1.5, all unix platforms accept the -d32 and -d64
    -       * options.  On platforms where only one data-model is supported
    -       * (e.g. ia-64 Linux), using the flag for the other data model is
    -       * an error and will terminate the program.
    -       */
    -
    -      { /* open new scope to declare local variables */
    -        int i;
    -
    -        newargv = (char **)JLI_MemAlloc((argc+1) * sizeof(char*));
    -        newargv[newargc++] = argv[0];
    -
    -        /* scan for data model arguments and remove from argument list;
    -           last occurrence determines desired data model */
    -        for (i=1; i < argc; i++) {
    -
    -          if (JLI_StrCmp(argv[i], "-J-d64") == 0 || JLI_StrCmp(argv[i], "-d64") == 0) {
    -            wanted = 64;
    -            continue;
    -          }
    -          if (JLI_StrCmp(argv[i], "-J-d32") == 0 || JLI_StrCmp(argv[i], "-d32") == 0) {
    -            wanted = 32;
    -            continue;
    -          }
    -          newargv[newargc++] = argv[i];
    -
    -          if (IsJavaArgs()) {
    -            if (argv[i][0] != '-') continue;
    -          } else {
    -            if (JLI_StrCmp(argv[i], "-classpath") == 0 || JLI_StrCmp(argv[i], "-cp") == 0) {
    -              i++;
    -              if (i >= argc) break;
    -              newargv[newargc++] = argv[i];
    -              continue;
    -            }
    -            if (argv[i][0] != '-') { i++; break; }
    -          }
    -        }
    -
    -        /* copy rest of args [i .. argc) */
    -        while (i < argc) {
    -          newargv[newargc++] = argv[i++];
    -        }
    -        newargv[newargc] = NULL;
    -
    -        /*
    -         * newargv has all proper arguments here
    -         */
    -
    -        argc = newargc;
    -        argv = newargv;
    -      }
    -
    -      /* If the data model is not changing, it is an error if the
    -         jvmpath does not exist */
    -      if (wanted == running) {
    -        /* Find out where the JRE is that we will be using. */
    -        if (!GetJREPath(jrepath, so_jrepath, JNI_FALSE) ) {
    -          JLI_ReportErrorMessage(JRE_ERROR1);
    -          exit(2);
    -        }
    -        JLI_Snprintf(jvmcfg, so_jvmcfg, "%s%slib%s%s%sjvm.cfg",
    -          jrepath, FILESEP, FILESEP,  "", "");
    -        /* Find the specified JVM type */
    -        if (ReadKnownVMs(jvmcfg, JNI_FALSE) < 1) {
    -          JLI_ReportErrorMessage(CFG_ERROR7);
    -          exit(1);
    -        }
    -
    -        jvmpath[0] = '\0';
    -        jvmtype = CheckJvmType(pargc, pargv, JNI_FALSE);
    -        if (JLI_StrCmp(jvmtype, "ERROR") == 0) {
    -            JLI_ReportErrorMessage(CFG_ERROR9);
    -            exit(4);
    -        }
    -
    -        if (!GetJVMPath(jrepath, jvmtype, jvmpath, so_jvmpath, wanted)) {
    -          JLI_ReportErrorMessage(CFG_ERROR8, jvmtype, jvmpath);
    -          exit(4);
    -        }
    -
    -        /*
    -         * Mac OS X requires the Cocoa event loop to be run on the "main"
    -         * thread. Spawn off a new thread to run main() and pass
    -         * this thread off to the Cocoa event loop.
    -         */
    -        MacOSXStartup(argc, argv);
    -
    -        /*
    -         * we seem to have everything we need, so without further ado
    -         * we return back, otherwise proceed to set the environment.
    -         */
    -        return;
    -      } else {  /* do the same speculatively or exit */
    -#if defined(DUAL_MODE)
    -        if (running != wanted) {
    -          /* Find out where the JRE is that we will be using. */
    -          if (!GetJREPath(jrepath, so_jrepath, JNI_TRUE)) {
    -            /* give up and let other code report error message */
    -            JLI_ReportErrorMessage(JRE_ERROR2, wanted);
    -            exit(1);
    -          }
    -          JLI_Snprintf(jvmcfg, so_jvmcfg, "%s%slib%s%s%sjvm.cfg",
    -            jrepath, FILESEP, FILESEP,  "", "");
    -          /*
    -           * Read in jvm.cfg for target data model and process vm
    -           * selection options.
    -           */
    -          if (ReadKnownVMs(jvmcfg, JNI_TRUE) < 1) {
    -            /* give up and let other code report error message */
    -            JLI_ReportErrorMessage(JRE_ERROR2, wanted);
    -            exit(1);
    -          }
    -          jvmpath[0] = '\0';
    -          jvmtype = CheckJvmType(pargc, pargv, JNI_TRUE);
    -          if (JLI_StrCmp(jvmtype, "ERROR") == 0) {
    -            JLI_ReportErrorMessage(CFG_ERROR9);
    -            exit(4);
    -          }
    -
    -          /* exec child can do error checking on the existence of the path */
    -          jvmpathExists = GetJVMPath(jrepath, jvmtype, jvmpath, so_jvmpath, wanted);
    -        }
    -#else /* ! DUAL_MODE */
    -        JLI_ReportErrorMessage(JRE_ERROR2, wanted);
    -        exit(1);
    -#endif /* DUAL_MODE */
    -        }
    -        {
    -            char *newexec = execname;
    -            JLI_TraceLauncher("TRACER_MARKER:About to EXEC\n");
    -            (void) fflush(stdout);
    -            (void) fflush(stderr);
    -            /*
    -            * Use posix_spawn() instead of execv() on Mac OS X.
    -            * This allows us to choose which architecture the child process
    -            * should run as.
    -            */
    -            {
    -                posix_spawnattr_t attr;
    -                size_t unused_size;
    -                pid_t  unused_pid;
    -
    -#if defined(__i386__) || defined(__x86_64__)
    -                cpu_type_t cpu_type[] = { (wanted == 64) ? CPU_TYPE_X86_64 : CPU_TYPE_X86,
    -                                    (running== 64) ? CPU_TYPE_X86_64 : CPU_TYPE_X86 };
    -#else
    -                cpu_type_t cpu_type[] = { CPU_TYPE_ANY };
    -#endif /* __i386 .. */
    -
    -                posix_spawnattr_init(&attr);
    -                posix_spawnattr_setflags(&attr, POSIX_SPAWN_SETEXEC);
    -                posix_spawnattr_setbinpref_np(&attr, sizeof(cpu_type) / sizeof(cpu_type_t),
    -                                            cpu_type, &unused_size);
    -
    -                posix_spawn(&unused_pid, newexec, NULL, &attr, argv, environ);
    -            }
    -            JLI_ReportErrorMessageSys(JRE_ERROR4, newexec);
    -
    -#if defined(DUAL_MODE)
    -            if (running != wanted) {
    -                JLI_ReportErrorMessage(JRE_ERROR5, wanted, running);
    -            }
    -#endif /* DUAL_MODE */
    -        }
    +    /* Find out where the JRE is that we will be using. */
    +    if (!GetJREPath(jrepath, so_jrepath, JNI_FALSE) ) {
    +        JLI_ReportErrorMessage(JRE_ERROR1);
    +        exit(2);
    +    }
    +    JLI_Snprintf(jvmcfg, so_jvmcfg, "%s%slib%sjvm.cfg",
    +                 jrepath, FILESEP, FILESEP);
    +    /* Find the specified JVM type */
    +    if (ReadKnownVMs(jvmcfg, JNI_FALSE) < 1) {
    +        JLI_ReportErrorMessage(CFG_ERROR7);
             exit(1);
         }
    +
    +    jvmpath[0] = '\0';
    +    jvmtype = CheckJvmType(pargc, pargv, JNI_FALSE);
    +    if (JLI_StrCmp(jvmtype, "ERROR") == 0) {
    +        JLI_ReportErrorMessage(CFG_ERROR9);
    +        exit(4);
    +    }
    +
    +    if (!GetJVMPath(jrepath, jvmtype, jvmpath, so_jvmpath)) {
    +        JLI_ReportErrorMessage(CFG_ERROR8, jvmtype, jvmpath);
    +        exit(4);
    +    }
    +
    +    /*
    +     * Mac OS X requires the Cocoa event loop to be run on the "main"
    +     * thread. Spawn off a new thread to run main() and pass
    +     * this thread off to the Cocoa event loop.
    +     */
    +    MacOSXStartup(argc, argv);
    +
    +    /*
    +     * we seem to have everything we need
    +     */
    +    return;
     }
     
     /*
    @@ -566,7 +413,7 @@ CreateExecutionEnvironment(int *pargc, char ***pargv,
      */
     static jboolean
     GetJVMPath(const char *jrepath, const char *jvmtype,
    -           char *jvmpath, jint jvmpathsize, int bitsWanted)
    +           char *jvmpath, jint jvmpathsize)
     {
         struct stat s;
     
    @@ -577,8 +424,7 @@ GetJVMPath(const char *jrepath, const char *jvmtype,
              * macosx client library is built thin, i386 only.
              * 64 bit client requests must load server library
              */
    -        const char *jvmtypeUsed = ((bitsWanted == 64) && (strcmp(jvmtype, "client") == 0)) ? "server" : jvmtype;
    -        JLI_Snprintf(jvmpath, jvmpathsize, "%s/lib/%s/" JVM_DLL, jrepath, jvmtypeUsed);
    +        JLI_Snprintf(jvmpath, jvmpathsize, "%s/lib/%s/" JVM_DLL, jrepath, jvmtype);
         }
     
         JLI_TraceLauncher("Does `%s' exist ... ", jvmpath);
    diff --git a/jdk/src/java.base/macosx/native/libnet/bsd_close.c b/jdk/src/java.base/macosx/native/libnet/bsd_close.c
    index 14739b12caf..2d7d2fbf0f0 100644
    --- a/jdk/src/java.base/macosx/native/libnet/bsd_close.c
    +++ b/jdk/src/java.base/macosx/native/libnet/bsd_close.c
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -39,6 +39,8 @@
     #include 
     #include 
     #include 
    +#include "jvm.h"
    +#include "net_util.h"
     
     /*
      * Stack allocated by thread when doing blocking operation
    @@ -414,8 +416,7 @@ int NET_Poll(struct pollfd *ufds, unsigned int nfds, int timeout) {
      * Auto restarts with adjusted timeout if interrupted by
      * signal other than our wakeup signal.
      */
    -int NET_Timeout0(int s, long timeout, long currentTime) {
    -    long prevtime = currentTime, newtime;
    +int NET_Timeout(JNIEnv *env, int s, long timeout, jlong nanoTimeStamp) {
         struct timeval t, *tp = &t;
         fd_set fds;
         fd_set* fdsp = NULL;
    @@ -460,6 +461,8 @@ int NET_Timeout0(int s, long timeout, long currentTime) {
         }
         FD_SET(s, fdsp);
     
    +    jlong prevNanoTime = nanoTimeStamp;
    +    jlong nanoTimeout = (jlong) timeout * NET_NSEC_PER_MSEC;
         for(;;) {
             int rv;
     
    @@ -477,25 +480,21 @@ int NET_Timeout0(int s, long timeout, long currentTime) {
              * has expired return 0 (indicating timeout expired).
              */
             if (rv < 0 && errno == EINTR) {
    -            if (timeout > 0) {
    -                struct timeval now;
    -                gettimeofday(&now, NULL);
    -                newtime = now.tv_sec * 1000  +  now.tv_usec / 1000;
    -                timeout -= newtime - prevtime;
    -                if (timeout <= 0) {
    -                    if (allocated != 0)
    -                        free(fdsp);
    -                    return 0;
    -                }
    -                prevtime = newtime;
    -                t.tv_sec = timeout / 1000;
    -                t.tv_usec = (timeout % 1000) * 1000;
    +            jlong newNanoTime = JVM_NanoTime(env, 0);
    +            nanoTimeout -= newNanoTime - prevNanoTime;
    +            if (nanoTimeout < NET_NSEC_PER_MSEC) {
    +                if (allocated != 0)
    +                    free(fdsp);
    +                return 0;
                 }
    +            prevNanoTime = newNanoTime;
    +            t.tv_sec = nanoTimeout / NET_NSEC_PER_SEC;
    +            t.tv_usec = (nanoTimeout % NET_NSEC_PER_SEC) / NET_NSEC_PER_USEC;
    +
             } else {
                 if (allocated != 0)
                     free(fdsp);
                 return rv;
             }
    -
         }
     }
    diff --git a/jdk/src/java.base/share/classes/java/lang/Math.java b/jdk/src/java.base/share/classes/java/lang/Math.java
    index 40e8926e052..14093908c6e 100644
    --- a/jdk/src/java.base/share/classes/java/lang/Math.java
    +++ b/jdk/src/java.base/share/classes/java/lang/Math.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 1994, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 1994, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -1442,8 +1442,8 @@ public final class Math {
         }
     
         // Use raw bit-wise conversions on guaranteed non-NaN arguments.
    -    private static long negativeZeroFloatBits  = Float.floatToRawIntBits(-0.0f);
    -    private static long negativeZeroDoubleBits = Double.doubleToRawLongBits(-0.0d);
    +    private static final long negativeZeroFloatBits  = Float.floatToRawIntBits(-0.0f);
    +    private static final long negativeZeroDoubleBits = Double.doubleToRawLongBits(-0.0d);
     
         /**
          * Returns the greater of two {@code float} values.  That is,
    diff --git a/jdk/src/java.base/share/classes/java/lang/StringCoding.java b/jdk/src/java.base/share/classes/java/lang/StringCoding.java
    index 7340fed04ca..065dcd794b4 100644
    --- a/jdk/src/java.base/share/classes/java/lang/StringCoding.java
    +++ b/jdk/src/java.base/share/classes/java/lang/StringCoding.java
    @@ -272,8 +272,7 @@ class StringCoding {
             // (2)The defensive copy of the input byte/char[] has a big performance
             // impact, as well as the outgoing result byte/char[]. Need to do the
             // optimization check of (sm==null && classLoader0==null) for both.
    -        // (3)getClass().getClassLoader0() is expensive
    -        // (4)There might be a timing gap in isTrusted setting. getClassLoader0()
    +        // (3)There might be a timing gap in isTrusted setting. getClassLoader0()
             // is only checked (and then isTrusted gets set) when (SM==null). It is
             // possible that the SM==null for now but then SM is NOT null later
             // when safeTrim() is invoked...the "safe" way to do is to redundant
    @@ -299,8 +298,8 @@ class StringCoding {
             if (len == 0) {
                 return new Result().with();
             }
    -        if (System.getSecurityManager() != null &&
    -            cs.getClass().getClassLoader0() != null) {
    +        if (cs.getClass().getClassLoader0() != null &&
    +            System.getSecurityManager() != null) {
                 ba =  Arrays.copyOfRange(ba, off, off + len);
                 off = 0;
             }
    @@ -609,8 +608,8 @@ class StringCoding {
             if (len == 0) {
                 return ba;
             }
    -        boolean isTrusted = System.getSecurityManager() == null ||
    -                            cs.getClass().getClassLoader0() == null;
    +        boolean isTrusted = cs.getClass().getClassLoader0() == null ||
    +                            System.getSecurityManager() == null;
             ce.onMalformedInput(CodingErrorAction.REPLACE)
               .onUnmappableCharacter(CodingErrorAction.REPLACE)
               .reset();
    diff --git a/jdk/src/java.base/share/classes/java/lang/System.java b/jdk/src/java.base/share/classes/java/lang/System.java
    index 10664819e4f..1f569a5bf70 100644
    --- a/jdk/src/java.base/share/classes/java/lang/System.java
    +++ b/jdk/src/java.base/share/classes/java/lang/System.java
    @@ -534,6 +534,8 @@ public final class System {
          * @param x object for which the hashCode is to be calculated
          * @return  the hashCode
          * @since   1.1
    +     * @see Object#hashCode
    +     * @see java.util.Objects#hashCode(Object)
          */
         @HotSpotIntrinsicCandidate
         public static native int identityHashCode(Object x);
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/BoundMethodHandle.java b/jdk/src/java.base/share/classes/java/lang/invoke/BoundMethodHandle.java
    index cec436690b9..f4675e15905 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/BoundMethodHandle.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/BoundMethodHandle.java
    @@ -450,32 +450,29 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
          */
         static class Factory {
     
    -        static final String JLO_SIG  = "Ljava/lang/Object;";
    -        static final String JLS_SIG  = "Ljava/lang/String;";
    -        static final String JLC_SIG  = "Ljava/lang/Class;";
    -        static final String MH       = "java/lang/invoke/MethodHandle";
    -        static final String MH_SIG   = "L"+MH+";";
    -        static final String BMH      = "java/lang/invoke/BoundMethodHandle";
    -        static final String BMH_SIG  = "L"+BMH+";";
    -        static final String SPECIES_DATA     = "java/lang/invoke/BoundMethodHandle$SpeciesData";
    -        static final String SPECIES_DATA_SIG = "L"+SPECIES_DATA+";";
    -        static final String STABLE_SIG       = "Ljdk/internal/vm/annotation/Stable;";
    +        private static final String JLO_SIG  = "Ljava/lang/Object;";
    +        private static final String MH       = "java/lang/invoke/MethodHandle";
    +        private static final String MH_SIG   = "L"+MH+";";
    +        private static final String BMH      = "java/lang/invoke/BoundMethodHandle";
    +        private static final String BMH_NAME = "java.lang.invoke.BoundMethodHandle";
    +        private static final String BMH_SIG  = "L"+BMH+";";
    +        private static final String SPECIES_DATA     = "java/lang/invoke/BoundMethodHandle$SpeciesData";
    +        private static final String SPECIES_DATA_SIG = "L"+SPECIES_DATA+";";
    +        private static final String STABLE_SIG       = "Ljdk/internal/vm/annotation/Stable;";
     
    -        static final String SPECIES_PREFIX_NAME = "Species_";
    -        static final String SPECIES_PREFIX_PATH = BMH + "$" + SPECIES_PREFIX_NAME;
    -        static final String SPECIES_CLASS_PREFIX = SPECIES_PREFIX_PATH.replace('/', '.');
    +        private static final String SPECIES_PREFIX_NAME = "Species_";
    +        private static final String SPECIES_PREFIX_PATH = BMH + "$" + SPECIES_PREFIX_NAME;
    +        private static final String SPECIES_CLASS_PREFIX = BMH_NAME + "$" + SPECIES_PREFIX_NAME;
     
    -        static final String BMHSPECIES_DATA_EWI_SIG = "(B)" + SPECIES_DATA_SIG;
    -        static final String BMHSPECIES_DATA_GFC_SIG = "(" + JLS_SIG + JLC_SIG + ")" + SPECIES_DATA_SIG;
    -        static final String MYSPECIES_DATA_SIG = "()" + SPECIES_DATA_SIG;
    -        static final String VOID_SIG   = "()V";
    -        static final String INT_SIG    = "()I";
    +        private static final String BMHSPECIES_DATA_EWI_SIG = "(B)" + SPECIES_DATA_SIG;
    +        private static final String MYSPECIES_DATA_SIG = "()" + SPECIES_DATA_SIG;
    +        private static final String INT_SIG    = "()I";
     
    -        static final String SIG_INCIPIT = "(Ljava/lang/invoke/MethodType;Ljava/lang/invoke/LambdaForm;";
    +        private static final String SIG_INCIPIT = "(Ljava/lang/invoke/MethodType;Ljava/lang/invoke/LambdaForm;";
     
    -        static final String[] E_THROWABLE = new String[] { "java/lang/Throwable" };
    +        private static final String[] E_THROWABLE = new String[] { "java/lang/Throwable" };
     
    -        static final ConcurrentMap> CLASS_CACHE = new ConcurrentHashMap<>();
    +        private static final ConcurrentMap> CLASS_CACHE = new ConcurrentHashMap<>();
     
             /**
              * Get a concrete subclass of BMH for a given combination of bound types.
    @@ -830,15 +827,27 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
     
             private static String makeSignature(String types, boolean ctor) {
                 StringBuilder buf = new StringBuilder(SIG_INCIPIT);
    -            for (char c : types.toCharArray()) {
    -                buf.append(typeSig(c));
    +            int len = types.length();
    +            for (int i = 0; i < len; i++) {
    +                buf.append(typeSig(types.charAt(i)));
                 }
                 return buf.append(')').append(ctor ? "V" : BMH_SIG).toString();
             }
     
    +        private static MethodType makeConstructorType(String types) {
    +            int length = types.length();
    +            Class ptypes[] = new Class[length + 2];
    +            ptypes[0] = MethodType.class;
    +            ptypes[1] = LambdaForm.class;
    +            for (int i = 0; i < length; i++) {
    +                ptypes[i + 2] = BasicType.basicType(types.charAt(i)).basicTypeClass();
    +            }
    +            return MethodType.makeImpl(BoundMethodHandle.class, ptypes, true);
    +        }
    +
             static MethodHandle makeCbmhCtor(Class cbmh, String types) {
                 try {
    -                return LOOKUP.findStatic(cbmh, "make", MethodType.fromDescriptor(makeSignature(types, false), null));
    +                return LOOKUP.findStatic(cbmh, "make", makeConstructorType(types));
                 } catch (NoSuchMethodException | IllegalAccessException | IllegalArgumentException | TypeNotPresentException e) {
                     throw newInternalError(e);
                 }
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/DelegatingMethodHandle.java b/jdk/src/java.base/share/classes/java/lang/invoke/DelegatingMethodHandle.java
    index d11012e6487..cecfe5efc34 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/DelegatingMethodHandle.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/DelegatingMethodHandle.java
    @@ -98,21 +98,17 @@ abstract class DelegatingMethodHandle extends MethodHandle {
                                             Object constraint,
                                             NamedFunction getTargetFn) {
             // No pre-action needed.
    -        return makeReinvokerForm(target, whichCache, constraint, null, true, getTargetFn, null);
    +        return makeReinvokerForm(target, whichCache, constraint, true, getTargetFn, null);
         }
         /** Create a LF which simply reinvokes a target of the given basic type. */
         static LambdaForm makeReinvokerForm(MethodHandle target,
                                             int whichCache,
                                             Object constraint,
    -                                        String debugString,
                                             boolean forceInline,
                                             NamedFunction getTargetFn,
                                             NamedFunction preActionFn) {
             MethodType mtype = target.type().basicType();
             Kind kind = whichKind(whichCache);
    -        if (debugString == null) {
    -            debugString = kind.defaultLambdaName;
    -        }
             boolean customized = (whichCache < 0 ||
                     mtype.parameterSlotCount() > MethodType.MAX_MH_INVOKER_ARITY);
             boolean hasPreAction = (preActionFn != null);
    @@ -144,7 +140,7 @@ abstract class DelegatingMethodHandle extends MethodHandle {
                 targetArgs[0] = names[NEXT_MH];  // overwrite this MH with next MH
                 names[REINVOKE] = new LambdaForm.Name(mtype, targetArgs);
             }
    -        form = new LambdaForm(debugString, ARG_LIMIT, names, forceInline, kind);
    +        form = new LambdaForm(ARG_LIMIT, names, forceInline, kind);
             if (!customized) {
                 form = mtype.form().setCachedLambdaForm(whichCache, form);
             }
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/DirectMethodHandle.java b/jdk/src/java.base/share/classes/java/lang/invoke/DirectMethodHandle.java
    index ce1f938583f..bd06ffa5348 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/DirectMethodHandle.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/DirectMethodHandle.java
    @@ -224,12 +224,12 @@ class DirectMethodHandle extends MethodHandle {
             assert(names.length == nameCursor);
             if (doesAlloc) {
                 // names = { argx,y,z,... new C, init method }
    -            names[NEW_OBJ] = new Name(NF_allocateInstance, names[DMH_THIS]);
    -            names[GET_MEMBER] = new Name(NF_constructorMethod, names[DMH_THIS]);
    +            names[NEW_OBJ] = new Name(getFunction(NF_allocateInstance), names[DMH_THIS]);
    +            names[GET_MEMBER] = new Name(getFunction(NF_constructorMethod), names[DMH_THIS]);
             } else if (needsInit) {
    -            names[GET_MEMBER] = new Name(NF_internalMemberNameEnsureInit, names[DMH_THIS]);
    +            names[GET_MEMBER] = new Name(getFunction(NF_internalMemberNameEnsureInit), names[DMH_THIS]);
             } else {
    -            names[GET_MEMBER] = new Name(NF_internalMemberName, names[DMH_THIS]);
    +            names[GET_MEMBER] = new Name(getFunction(NF_internalMemberName), names[DMH_THIS]);
             }
             assert(findDirectMethodHandle(names[GET_MEMBER]) == names[DMH_THIS]);
             Object[] outArgs = Arrays.copyOfRange(names, ARG_BASE, GET_MEMBER+1, Object[].class);
    @@ -242,18 +242,17 @@ class DirectMethodHandle extends MethodHandle {
                 result = NEW_OBJ;
             }
             names[LINKER_CALL] = new Name(linker, outArgs);
    -        String lambdaName = kind.defaultLambdaName + "_" + shortenSignature(basicTypeSignature(mtype));
    -        LambdaForm lform = new LambdaForm(lambdaName, ARG_LIMIT, names, result, kind);
    +        LambdaForm lform = new LambdaForm(ARG_LIMIT, names, result, kind);
     
             // This is a tricky bit of code.  Don't send it through the LF interpreter.
             lform.compileToBytecode();
             return lform;
         }
     
    -    static Object findDirectMethodHandle(Name name) {
    -        if (name.function == NF_internalMemberName ||
    -            name.function == NF_internalMemberNameEnsureInit ||
    -            name.function == NF_constructorMethod) {
    +    /* assert */ static Object findDirectMethodHandle(Name name) {
    +        if (name.function.equals(getFunction(NF_internalMemberName)) ||
    +            name.function.equals(getFunction(NF_internalMemberNameEnsureInit)) ||
    +            name.function.equals(getFunction(NF_constructorMethod))) {
                 assert(name.arguments.length == 1);
                 return name.arguments[0];
             }
    @@ -675,18 +674,18 @@ class DirectMethodHandle extends MethodHandle {
             final int RESULT    = nameCursor-1;  // either the call or the cast
             Name[] names = arguments(nameCursor - ARG_LIMIT, mtype.invokerType());
             if (needsInit)
    -            names[INIT_BAR] = new Name(NF_ensureInitialized, names[DMH_THIS]);
    +            names[INIT_BAR] = new Name(getFunction(NF_ensureInitialized), names[DMH_THIS]);
             if (needsCast && !isGetter)
    -            names[PRE_CAST] = new Name(NF_checkCast, names[DMH_THIS], names[SET_VALUE]);
    +            names[PRE_CAST] = new Name(getFunction(NF_checkCast), names[DMH_THIS], names[SET_VALUE]);
             Object[] outArgs = new Object[1 + linkerType.parameterCount()];
             assert(outArgs.length == (isGetter ? 3 : 4));
    -        outArgs[0] = names[U_HOLDER] = new Name(NF_UNSAFE);
    +        outArgs[0] = names[U_HOLDER] = new Name(getFunction(NF_UNSAFE));
             if (isStatic) {
    -            outArgs[1] = names[F_HOLDER]  = new Name(NF_staticBase, names[DMH_THIS]);
    -            outArgs[2] = names[F_OFFSET]  = new Name(NF_staticOffset, names[DMH_THIS]);
    +            outArgs[1] = names[F_HOLDER]  = new Name(getFunction(NF_staticBase), names[DMH_THIS]);
    +            outArgs[2] = names[F_OFFSET]  = new Name(getFunction(NF_staticOffset), names[DMH_THIS]);
             } else {
    -            outArgs[1] = names[OBJ_CHECK] = new Name(NF_checkBase, names[OBJ_BASE]);
    -            outArgs[2] = names[F_OFFSET]  = new Name(NF_fieldOffset, names[DMH_THIS]);
    +            outArgs[1] = names[OBJ_CHECK] = new Name(getFunction(NF_checkBase), names[OBJ_BASE]);
    +            outArgs[2] = names[F_OFFSET]  = new Name(getFunction(NF_fieldOffset), names[DMH_THIS]);
             }
             if (!isGetter) {
                 outArgs[3] = (needsCast ? names[PRE_CAST] : names[SET_VALUE]);
    @@ -694,70 +693,105 @@ class DirectMethodHandle extends MethodHandle {
             for (Object a : outArgs)  assert(a != null);
             names[LINKER_CALL] = new Name(linker, outArgs);
             if (needsCast && isGetter)
    -            names[POST_CAST] = new Name(NF_checkCast, names[DMH_THIS], names[LINKER_CALL]);
    +            names[POST_CAST] = new Name(getFunction(NF_checkCast), names[DMH_THIS], names[LINKER_CALL]);
             for (Name n : names)  assert(n != null);
    -        // add some detail to the lambdaForm debugname,
    -        // significant only for debugging
    -        StringBuilder nameBuilder = new StringBuilder(kind.methodName);
    -        if (isStatic) {
    -            nameBuilder.append("Static");
    -        } else {
    -            nameBuilder.append("Field");
    -        }
    -        if (needsCast)  nameBuilder.append("Cast");
    -        if (needsInit)  nameBuilder.append("Init");
    +
    +        LambdaForm form;
             if (needsCast || needsInit) {
                 // can't use the pre-generated form when casting and/or initializing
    -            return new LambdaForm(nameBuilder.toString(), ARG_LIMIT, names, RESULT);
    +            form = new LambdaForm(ARG_LIMIT, names, RESULT);
             } else {
    -            return new LambdaForm(nameBuilder.toString(), ARG_LIMIT, names, RESULT, kind);
    +            form = new LambdaForm(ARG_LIMIT, names, RESULT, kind);
             }
    +
    +        if (LambdaForm.debugNames()) {
    +            // add some detail to the lambdaForm debugname,
    +            // significant only for debugging
    +            StringBuilder nameBuilder = new StringBuilder(kind.methodName);
    +            if (isStatic) {
    +                nameBuilder.append("Static");
    +            } else {
    +                nameBuilder.append("Field");
    +            }
    +            if (needsCast) {
    +                nameBuilder.append("Cast");
    +            }
    +            if (needsInit) {
    +                nameBuilder.append("Init");
    +            }
    +            LambdaForm.associateWithDebugName(form, nameBuilder.toString());
    +        }
    +        return form;
         }
     
         /**
          * Pre-initialized NamedFunctions for bootstrapping purposes.
    -     * Factored in an inner class to delay initialization until first usage.
          */
    -    static final NamedFunction
    -            NF_internalMemberName,
    -            NF_internalMemberNameEnsureInit,
    -            NF_ensureInitialized,
    -            NF_fieldOffset,
    -            NF_checkBase,
    -            NF_staticBase,
    -            NF_staticOffset,
    -            NF_checkCast,
    -            NF_allocateInstance,
    -            NF_constructorMethod,
    -            NF_UNSAFE;
    -    static {
    +    static final byte NF_internalMemberName = 0,
    +            NF_internalMemberNameEnsureInit = 1,
    +            NF_ensureInitialized = 2,
    +            NF_fieldOffset = 3,
    +            NF_checkBase = 4,
    +            NF_staticBase = 5,
    +            NF_staticOffset = 6,
    +            NF_checkCast = 7,
    +            NF_allocateInstance = 8,
    +            NF_constructorMethod = 9,
    +            NF_UNSAFE = 10,
    +            NF_LIMIT = 11;
    +
    +    private static final @Stable NamedFunction[] NFS = new NamedFunction[NF_LIMIT];
    +
    +    private static NamedFunction getFunction(byte func) {
    +        NamedFunction nf = NFS[func];
    +        if (nf != null) {
    +            return nf;
    +        }
    +        // Each nf must be statically invocable or we get tied up in our bootstraps.
    +        nf = NFS[func] = createFunction(func);
    +        assert(InvokerBytecodeGenerator.isStaticallyInvocable(nf));
    +        return nf;
    +    }
    +
    +    private static NamedFunction createFunction(byte func) {
             try {
    -            NamedFunction nfs[] = {
    -                    NF_internalMemberName = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("internalMemberName", Object.class)),
    -                    NF_internalMemberNameEnsureInit = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("internalMemberNameEnsureInit", Object.class)),
    -                    NF_ensureInitialized = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("ensureInitialized", Object.class)),
    -                    NF_fieldOffset = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("fieldOffset", Object.class)),
    -                    NF_checkBase = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("checkBase", Object.class)),
    -                    NF_staticBase = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("staticBase", Object.class)),
    -                    NF_staticOffset = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("staticOffset", Object.class)),
    -                    NF_checkCast = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("checkCast", Object.class, Object.class)),
    -                    NF_allocateInstance = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("allocateInstance", Object.class)),
    -                    NF_constructorMethod = new NamedFunction(DirectMethodHandle.class
    -                            .getDeclaredMethod("constructorMethod", Object.class)),
    -                    NF_UNSAFE = new NamedFunction(new MemberName(MethodHandleStatics.class
    -                            .getDeclaredField("UNSAFE")))
    -            };
    -            // Each nf must be statically invocable or we get tied up in our bootstraps.
    -            assert(InvokerBytecodeGenerator.isStaticallyInvocable(nfs));
    +            switch (func) {
    +                case NF_internalMemberName:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("internalMemberName", Object.class));
    +                case NF_internalMemberNameEnsureInit:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("internalMemberNameEnsureInit", Object.class));
    +                case NF_ensureInitialized:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("ensureInitialized", Object.class));
    +                case NF_fieldOffset:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("fieldOffset", Object.class));
    +                case NF_checkBase:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("checkBase", Object.class));
    +                case NF_staticBase:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("staticBase", Object.class));
    +                case NF_staticOffset:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("staticOffset", Object.class));
    +                case NF_checkCast:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("checkCast", Object.class, Object.class));
    +                case NF_allocateInstance:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("allocateInstance", Object.class));
    +                case NF_constructorMethod:
    +                    return new NamedFunction(DirectMethodHandle.class
    +                            .getDeclaredMethod("constructorMethod", Object.class));
    +                case NF_UNSAFE:
    +                    return new NamedFunction(new MemberName(MethodHandleStatics.class
    +                            .getDeclaredField("UNSAFE")));
    +                default:
    +                    throw newInternalError("Unknown function: " + func);
    +            }
             } catch (ReflectiveOperationException ex) {
                 throw newInternalError(ex);
             }
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/InvokerBytecodeGenerator.java b/jdk/src/java.base/share/classes/java/lang/invoke/InvokerBytecodeGenerator.java
    index d903d488211..7349ea2bec4 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/InvokerBytecodeGenerator.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/InvokerBytecodeGenerator.java
    @@ -73,6 +73,7 @@ class InvokerBytecodeGenerator {
         private static final String LL_SIG  = "(L" + OBJ + ";)L" + OBJ + ";";
         private static final String LLV_SIG = "(L" + OBJ + ";L" + OBJ + ";)V";
         private static final String CLASS_PREFIX = LF + "$";
    +    private static final String SOURCE_PREFIX = "LambdaForm$";
     
         /** Name of its super class*/
         static final String INVOKER_SUPER_NAME = OBJ;
    @@ -80,9 +81,6 @@ class InvokerBytecodeGenerator {
         /** Name of new class */
         private final String className;
     
    -    /** Name of the source file (for stack trace printing). */
    -    private final String sourceFile;
    -
         private final LambdaForm lambdaForm;
         private final String     invokerName;
         private final MethodType invokerType;
    @@ -109,8 +107,7 @@ class InvokerBytecodeGenerator {
             if (DUMP_CLASS_FILES) {
                 className = makeDumpableClassName(className);
             }
    -        this.className  = CLASS_PREFIX + className;
    -        this.sourceFile = "LambdaForm$" + className;
    +        this.className  = className;
             this.lambdaForm = lambdaForm;
             this.invokerName = invokerName;
             this.invokerType = invokerType;
    @@ -130,7 +127,7 @@ class InvokerBytecodeGenerator {
     
         /** For generating customized code for a single LambdaForm. */
         private InvokerBytecodeGenerator(String className, LambdaForm form, MethodType invokerType) {
    -        this(className, form.debugName, form, invokerType);
    +        this(className, form.lambdaName(), form, invokerType);
         }
     
         /** For generating customized code for a single LambdaForm. */
    @@ -173,6 +170,13 @@ class InvokerBytecodeGenerator {
             }
         }
     
    +    private void maybeDump(final byte[] classFile) {
    +        if (DUMP_CLASS_FILES) {
    +            maybeDump(CLASS_PREFIX + className, classFile);
    +        }
    +    }
    +
    +    // Also used from BoundMethodHandle
         static void maybeDump(final String className, final byte[] classFile) {
             if (DUMP_CLASS_FILES) {
                 java.security.AccessController.doPrivileged(
    @@ -306,8 +310,9 @@ class InvokerBytecodeGenerator {
         private ClassWriter classFilePrologue() {
             final int NOT_ACC_PUBLIC = 0;  // not ACC_PUBLIC
             cw = new ClassWriter(ClassWriter.COMPUTE_MAXS + ClassWriter.COMPUTE_FRAMES);
    -        cw.visit(Opcodes.V1_8, NOT_ACC_PUBLIC + Opcodes.ACC_FINAL + Opcodes.ACC_SUPER, className, null, INVOKER_SUPER_NAME, null);
    -        cw.visitSource(sourceFile, null);
    +        cw.visit(Opcodes.V1_8, NOT_ACC_PUBLIC + Opcodes.ACC_FINAL + Opcodes.ACC_SUPER,
    +                CLASS_PREFIX + className, null, INVOKER_SUPER_NAME, null);
    +        cw.visitSource(SOURCE_PREFIX + className, null);
             return cw;
         }
     
    @@ -617,12 +622,11 @@ class InvokerBytecodeGenerator {
             return resolvedMember;
         }
     
    -    private static MemberName lookupPregenerated(LambdaForm form) {
    +    private static MemberName lookupPregenerated(LambdaForm form, MethodType invokerType) {
             if (form.customized != null) {
                 // No pre-generated version for customized LF
                 return null;
             }
    -        MethodType invokerType = form.methodType();
             String name = form.kind.methodName;
             switch (form.kind) {
                 case BOUND_REINVOKER: {
    @@ -670,7 +674,7 @@ class InvokerBytecodeGenerator {
          * Generate customized bytecode for a given LambdaForm.
          */
         static MemberName generateCustomizedCode(LambdaForm form, MethodType invokerType) {
    -        MemberName pregenerated = lookupPregenerated(form);
    +        MemberName pregenerated = lookupPregenerated(form, invokerType);
             if (pregenerated != null)  return pregenerated; // pre-generated bytecode
     
             InvokerBytecodeGenerator g = new InvokerBytecodeGenerator("MH", form, invokerType);
    @@ -720,7 +724,7 @@ class InvokerBytecodeGenerator {
             bogusMethod(lambdaForm);
     
             final byte[] classFile = toByteArray();
    -        maybeDump(className, classFile);
    +        maybeDump(classFile);
             return classFile;
         }
     
    @@ -908,7 +912,7 @@ class InvokerBytecodeGenerator {
             //MethodHandle.class already covered
         };
     
    -    static boolean isStaticallyInvocable(NamedFunction[] functions) {
    +    static boolean isStaticallyInvocable(NamedFunction ... functions) {
             for (NamedFunction nf : functions) {
                 if (!isStaticallyInvocable(nf.member())) {
                     return false;
    @@ -1761,7 +1765,7 @@ class InvokerBytecodeGenerator {
             bogusMethod(invokerType);
     
             final byte[] classFile = cw.toByteArray();
    -        maybeDump(className, classFile);
    +        maybeDump(classFile);
             return classFile;
         }
     
    @@ -1829,7 +1833,7 @@ class InvokerBytecodeGenerator {
             bogusMethod(dstType);
     
             final byte[] classFile = cw.toByteArray();
    -        maybeDump(className, classFile);
    +        maybeDump(classFile);
             return classFile;
         }
     
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/Invokers.java b/jdk/src/java.base/share/classes/java/lang/invoke/Invokers.java
    index 0a97622fe84..8eeb4c3954e 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/Invokers.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/Invokers.java
    @@ -132,7 +132,7 @@ class Invokers {
             MethodType mtype = targetType;
             MethodType invokerType = mtype.insertParameterTypes(0, VarHandle.class);
     
    -        LambdaForm lform = varHandleMethodInvokerHandleForm(ak.methodName(), mtype, isExact);
    +        LambdaForm lform = varHandleMethodInvokerHandleForm(ak, mtype, isExact);
             VarHandle.AccessDescriptor ad = new VarHandle.AccessDescriptor(mtype, ak.at.ordinal(), ak.ordinal());
             MethodHandle invoker = BoundMethodHandle.bindSingle(invokerType, lform, ad);
     
    @@ -313,21 +313,21 @@ class Invokers {
             Object[] outArgs = Arrays.copyOfRange(names, CALL_MH, OUTARG_LIMIT, Object[].class);
             Object mtypeArg = (customized ? mtype : names[MTYPE_ARG]);
             if (!isGeneric) {
    -            names[CHECK_TYPE] = new Name(NF_checkExactType, names[CALL_MH], mtypeArg);
    +            names[CHECK_TYPE] = new Name(getFunction(NF_checkExactType), names[CALL_MH], mtypeArg);
                 // mh.invokeExact(a*):R => checkExactType(mh, TYPEOF(a*:R)); mh.invokeBasic(a*)
             } else {
    -            names[CHECK_TYPE] = new Name(NF_checkGenericType, names[CALL_MH], mtypeArg);
    +            names[CHECK_TYPE] = new Name(getFunction(NF_checkGenericType), names[CALL_MH], mtypeArg);
                 // mh.invokeGeneric(a*):R => checkGenericType(mh, TYPEOF(a*:R)).invokeBasic(a*)
                 outArgs[0] = names[CHECK_TYPE];
             }
             if (CHECK_CUSTOM != -1) {
    -            names[CHECK_CUSTOM] = new Name(NF_checkCustomized, outArgs[0]);
    +            names[CHECK_CUSTOM] = new Name(getFunction(NF_checkCustomized), outArgs[0]);
             }
             names[LINKER_CALL] = new Name(outCallType, outArgs);
             if (customized) {
    -            lform = new LambdaForm(kind.defaultLambdaName, INARG_LIMIT, names);
    +            lform = new LambdaForm(INARG_LIMIT, names);
             } else {
    -            lform = new LambdaForm(kind.defaultLambdaName, INARG_LIMIT, names, kind);
    +            lform = new LambdaForm(INARG_LIMIT, names, kind);
             }
             if (isLinker)
                 lform.compileToBytecode();  // JVM needs a real methodOop
    @@ -337,11 +337,10 @@ class Invokers {
         }
     
     
    -    static MemberName varHandleInvokeLinkerMethod(String name,
    -                                                  MethodType mtype) {
    +    static MemberName varHandleInvokeLinkerMethod(VarHandle.AccessMode ak, MethodType mtype) {
             LambdaForm lform;
             if (mtype.parameterSlotCount() <= MethodType.MAX_MH_ARITY - MH_LINKER_ARG_APPENDED) {
    -            lform = varHandleMethodGenericLinkerHandleForm(name, mtype);
    +            lform = varHandleMethodGenericLinkerHandleForm(ak, mtype);
             } else {
                 // TODO
                 throw newInternalError("Unsupported parameter slot count " + mtype.parameterSlotCount());
    @@ -349,7 +348,8 @@ class Invokers {
             return lform.vmentry;
         }
     
    -    private static LambdaForm varHandleMethodGenericLinkerHandleForm(String name, MethodType mtype) {
    +    private static LambdaForm varHandleMethodGenericLinkerHandleForm(VarHandle.AccessMode ak,
    +            MethodType mtype) {
             // TODO Cache form?
     
             final int THIS_VH      = 0;
    @@ -368,7 +368,7 @@ class Invokers {
             }
             names[VAD_ARG] = new Name(ARG_LIMIT, BasicType.basicType(Object.class));
     
    -        names[CHECK_TYPE] = new Name(NF_checkVarHandleGenericType, names[THIS_VH], names[VAD_ARG]);
    +        names[CHECK_TYPE] = new Name(getFunction(NF_checkVarHandleGenericType), names[THIS_VH], names[VAD_ARG]);
     
             Object[] outArgs = new Object[ARG_LIMIT + 1];
             outArgs[0] = names[CHECK_TYPE];
    @@ -377,20 +377,24 @@ class Invokers {
             }
     
             if (CHECK_CUSTOM != -1) {
    -            names[CHECK_CUSTOM] = new Name(NF_checkCustomized, outArgs[0]);
    +            names[CHECK_CUSTOM] = new Name(getFunction(NF_checkCustomized), outArgs[0]);
             }
     
             MethodType outCallType = mtype.insertParameterTypes(0, VarHandle.class)
                     .basicType();
             names[LINKER_CALL] = new Name(outCallType, outArgs);
    -        LambdaForm lform = new LambdaForm(name + ":VarHandle_invoke_MT_" + shortenSignature(basicTypeSignature(mtype)),
    -                                          ARG_LIMIT + 1, names);
    -
    +        LambdaForm lform = new LambdaForm(ARG_LIMIT + 1, names, VARHANDLE_LINKER);
    +        if (LambdaForm.debugNames()) {
    +            String name = ak.methodName() + ":VarHandle_invoke_MT_" +
    +                    shortenSignature(basicTypeSignature(mtype));
    +            LambdaForm.associateWithDebugName(lform, name);
    +        }
             lform.compileToBytecode();
             return lform;
         }
     
    -    private static LambdaForm varHandleMethodInvokerHandleForm(String name, MethodType mtype, boolean isExact) {
    +    private static LambdaForm varHandleMethodInvokerHandleForm(VarHandle.AccessMode ak,
    +            MethodType mtype, boolean isExact) {
             // TODO Cache form?
     
             final int THIS_MH      = 0;
    @@ -416,9 +420,9 @@ class Invokers {
             names[VAD_ARG] = new Name(getter, names[THIS_MH]);
     
             if (isExact) {
    -            names[CHECK_TYPE] = new Name(NF_checkVarHandleExactType, names[CALL_VH], names[VAD_ARG]);
    +            names[CHECK_TYPE] = new Name(getFunction(NF_checkVarHandleExactType), names[CALL_VH], names[VAD_ARG]);
             } else {
    -            names[CHECK_TYPE] = new Name(NF_checkVarHandleGenericType, names[CALL_VH], names[VAD_ARG]);
    +            names[CHECK_TYPE] = new Name(getFunction(NF_checkVarHandleGenericType), names[CALL_VH], names[VAD_ARG]);
             }
             Object[] outArgs = new Object[ARG_LIMIT];
             outArgs[0] = names[CHECK_TYPE];
    @@ -429,10 +433,14 @@ class Invokers {
             MethodType outCallType = mtype.insertParameterTypes(0, VarHandle.class)
                     .basicType();
             names[LINKER_CALL] = new Name(outCallType, outArgs);
    -        String debugName = isExact ? ":VarHandle_exactInvoker" : ":VarHandle_invoker";
    -        LambdaForm lform = new LambdaForm(name + debugName + shortenSignature(basicTypeSignature(mtype)),
    -                                          ARG_LIMIT, names);
    -
    +        Kind kind = isExact ? VARHANDLE_EXACT_INVOKER : VARHANDLE_INVOKER;
    +        LambdaForm lform = new LambdaForm(ARG_LIMIT, names, kind);
    +        if (LambdaForm.debugNames()) {
    +            String name = ak.methodName() +
    +                    (isExact ? ":VarHandle_exactInvoker_" : ":VarHandle_invoker_") +
    +                    shortenSignature(basicTypeSignature(mtype));
    +            LambdaForm.associateWithDebugName(lform, name);
    +        }
             lform.prepare();
             return lform;
         }
    @@ -535,7 +543,7 @@ class Invokers {
             assert(names.length == nameCursor);
             assert(names[APPENDIX_ARG] != null);
             if (!skipCallSite)
    -            names[CALL_MH] = new Name(NF_getCallSiteTarget, names[CSITE_ARG]);
    +            names[CALL_MH] = new Name(getFunction(NF_getCallSiteTarget), names[CSITE_ARG]);
             // (site.)invokedynamic(a*):R => mh = site.getTarget(); mh.invokeBasic(a*)
             final int PREPEND_MH = 0, PREPEND_COUNT = 1;
             Object[] outArgs = Arrays.copyOfRange(names, ARG_BASE, OUTARG_LIMIT + PREPEND_COUNT, Object[].class);
    @@ -543,7 +551,8 @@ class Invokers {
             System.arraycopy(outArgs, 0, outArgs, PREPEND_COUNT, outArgs.length - PREPEND_COUNT);
             outArgs[PREPEND_MH] = names[CALL_MH];
             names[LINKER_CALL] = new Name(mtype, outArgs);
    -        lform = new LambdaForm((skipCallSite ? "linkToTargetMethod" : "linkToCallSite"), INARG_LIMIT, names);
    +        lform = new LambdaForm(INARG_LIMIT, names,
    +                (skipCallSite ? LINK_TO_TARGET_METHOD : LINK_TO_CALL_SITE));
             lform.compileToBytecode();  // JVM needs a real methodOop
             lform = mtype.form().setCachedLambdaForm(which, lform);
             return lform;
    @@ -577,31 +586,51 @@ class Invokers {
         }
     
         // Local constant functions:
    -    private static final NamedFunction
    -        NF_checkExactType,
    -        NF_checkGenericType,
    -        NF_getCallSiteTarget,
    -        NF_checkCustomized,
    -        NF_checkVarHandleGenericType,
    -        NF_checkVarHandleExactType;
    -    static {
    +    private static final byte NF_checkExactType = 0,
    +        NF_checkGenericType = 1,
    +        NF_getCallSiteTarget = 2,
    +        NF_checkCustomized = 3,
    +        NF_checkVarHandleGenericType = 4,
    +        NF_checkVarHandleExactType = 5,
    +        NF_LIMIT = 6;
    +
    +    private static final @Stable NamedFunction[] NFS = new NamedFunction[NF_LIMIT];
    +
    +    private static NamedFunction getFunction(byte func) {
    +        NamedFunction nf = NFS[func];
    +        if (nf != null) {
    +            return nf;
    +        }
    +        NFS[func] = nf = createFunction(func);
    +        // Each nf must be statically invocable or we get tied up in our bootstraps.
    +        assert(InvokerBytecodeGenerator.isStaticallyInvocable(nf));
    +        return nf;
    +    }
    +
    +    private static NamedFunction createFunction(byte func) {
             try {
    -            NamedFunction nfs[] = {
    -                NF_checkExactType = new NamedFunction(Invokers.class
    -                        .getDeclaredMethod("checkExactType", MethodHandle.class,  MethodType.class)),
    -                NF_checkGenericType = new NamedFunction(Invokers.class
    -                        .getDeclaredMethod("checkGenericType", MethodHandle.class,  MethodType.class)),
    -                NF_getCallSiteTarget = new NamedFunction(Invokers.class
    -                        .getDeclaredMethod("getCallSiteTarget", CallSite.class)),
    -                NF_checkCustomized = new NamedFunction(Invokers.class
    -                        .getDeclaredMethod("checkCustomized", MethodHandle.class)),
    -                NF_checkVarHandleGenericType = new NamedFunction(Invokers.class
    -                        .getDeclaredMethod("checkVarHandleGenericType", VarHandle.class, VarHandle.AccessDescriptor.class)),
    -                NF_checkVarHandleExactType = new NamedFunction(Invokers.class
    -                        .getDeclaredMethod("checkVarHandleExactType", VarHandle.class, VarHandle.AccessDescriptor.class)),
    -            };
    -            // Each nf must be statically invocable or we get tied up in our bootstraps.
    -            assert(InvokerBytecodeGenerator.isStaticallyInvocable(nfs));
    +            switch (func) {
    +                case NF_checkExactType:
    +                    return new NamedFunction(Invokers.class
    +                        .getDeclaredMethod("checkExactType", MethodHandle.class,  MethodType.class));
    +                case NF_checkGenericType:
    +                    return new NamedFunction(Invokers.class
    +                        .getDeclaredMethod("checkGenericType", MethodHandle.class,  MethodType.class));
    +                case NF_getCallSiteTarget:
    +                    return new NamedFunction(Invokers.class
    +                        .getDeclaredMethod("getCallSiteTarget", CallSite.class));
    +                case NF_checkCustomized:
    +                    return new NamedFunction(Invokers.class
    +                        .getDeclaredMethod("checkCustomized", MethodHandle.class));
    +                case NF_checkVarHandleGenericType:
    +                    return new NamedFunction(Invokers.class
    +                        .getDeclaredMethod("checkVarHandleGenericType", VarHandle.class, VarHandle.AccessDescriptor.class));
    +                case NF_checkVarHandleExactType:
    +                    return new NamedFunction(Invokers.class
    +                        .getDeclaredMethod("checkVarHandleExactType", VarHandle.class, VarHandle.AccessDescriptor.class));
    +                default:
    +                    throw newInternalError("Unknown function: " + func);
    +            }
             } catch (ReflectiveOperationException ex) {
                 throw newInternalError(ex);
             }
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/LambdaForm.java b/jdk/src/java.base/share/classes/java/lang/invoke/LambdaForm.java
    index 96b0a944800..efb7e9490dd 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/LambdaForm.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/LambdaForm.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -126,7 +126,6 @@ class LambdaForm {
         final boolean forceInline;
         final MethodHandle customized;
         @Stable final Name[] names;
    -    final String debugName;
         final Kind kind;
         MemberName vmentry;   // low-level behavior, or null if not yet prepared
         private boolean isCompiled;
    @@ -268,22 +267,24 @@ class LambdaForm {
         }
     
         enum Kind {
    -        GENERIC(""),
    +        GENERIC("invoke"),
             ZERO("zero"),
             IDENTITY("identity"),
    -        BOUND_REINVOKER("BMH.reinvoke"),
    -        REINVOKER("MH.reinvoke"),
    -        DELEGATE("MH.delegate"),
    -        EXACT_LINKER("MH.invokeExact_MT"),
    -        EXACT_INVOKER("MH.exactInvoker"),
    -        GENERIC_LINKER("MH.invoke_MT"),
    -        GENERIC_INVOKER("MH.invoker"),
    -        DIRECT_INVOKE_VIRTUAL("DMH.invokeVirtual"),
    -        DIRECT_INVOKE_SPECIAL("DMH.invokeSpecial"),
    -        DIRECT_INVOKE_STATIC("DMH.invokeStatic"),
    -        DIRECT_NEW_INVOKE_SPECIAL("DMH.newInvokeSpecial"),
    -        DIRECT_INVOKE_INTERFACE("DMH.invokeInterface"),
    -        DIRECT_INVOKE_STATIC_INIT("DMH.invokeStaticInit"),
    +        BOUND_REINVOKER("BMH.reinvoke", "reinvoke"),
    +        REINVOKER("MH.reinvoke", "reinvoke"),
    +        DELEGATE("MH.delegate", "delegate"),
    +        EXACT_LINKER("MH.invokeExact_MT", "invokeExact_MT"),
    +        EXACT_INVOKER("MH.exactInvoker", "exactInvoker"),
    +        GENERIC_LINKER("MH.invoke_MT", "invoke_MT"),
    +        GENERIC_INVOKER("MH.invoker", "invoker"),
    +        LINK_TO_TARGET_METHOD("linkToTargetMethod"),
    +        LINK_TO_CALL_SITE("linkToCallSite"),
    +        DIRECT_INVOKE_VIRTUAL("DMH.invokeVirtual", "invokeVirtual"),
    +        DIRECT_INVOKE_SPECIAL("DMH.invokeSpecial", "invokeSpecial"),
    +        DIRECT_INVOKE_STATIC("DMH.invokeStatic", "invokeStatic"),
    +        DIRECT_NEW_INVOKE_SPECIAL("DMH.newInvokeSpecial", "newInvokeSpecial"),
    +        DIRECT_INVOKE_INTERFACE("DMH.invokeInterface", "invokeInterface"),
    +        DIRECT_INVOKE_STATIC_INIT("DMH.invokeStaticInit", "invokeStaticInit"),
             GET_OBJECT("getObject"),
             PUT_OBJECT("putObject"),
             GET_OBJECT_VOLATILE("getObjectVolatile"),
    @@ -319,41 +320,46 @@ class LambdaForm {
             GET_DOUBLE("getDouble"),
             PUT_DOUBLE("putDouble"),
             GET_DOUBLE_VOLATILE("getDoubleVolatile"),
    -        PUT_DOUBLE_VOLATILE("putDoubleVolatile");
    +        PUT_DOUBLE_VOLATILE("putDoubleVolatile"),
    +        TRY_FINALLY("tryFinally"),
    +        COLLECT("collect"),
    +        CONVERT("convert"),
    +        SPREAD("spread"),
    +        LOOP("loop"),
    +        FIELD("field"),
    +        GUARD("guard"),
    +        GUARD_WITH_CATCH("guardWithCatch"),
    +        VARHANDLE_EXACT_INVOKER("VH.exactInvoker"),
    +        VARHANDLE_INVOKER("VH.invoker", "invoker"),
    +        VARHANDLE_LINKER("VH.invoke_MT", "invoke_MT");
     
             final String defaultLambdaName;
             final String methodName;
     
             private Kind(String defaultLambdaName) {
    +            this(defaultLambdaName, defaultLambdaName);
    +        }
    +
    +        private Kind(String defaultLambdaName, String methodName) {
                 this.defaultLambdaName = defaultLambdaName;
    -            int p = defaultLambdaName.indexOf('.');
    -            if (p > -1) {
    -                this.methodName = defaultLambdaName.substring(p + 1);
    -            } else {
    -                this.methodName = defaultLambdaName;
    -            }
    +            this.methodName = methodName;
             }
         }
     
    -    LambdaForm(String debugName,
    -               int arity, Name[] names, int result) {
    -        this(debugName, arity, names, result, /*forceInline=*/true, /*customized=*/null, Kind.GENERIC);
    +    LambdaForm(int arity, Name[] names, int result) {
    +        this(arity, names, result, /*forceInline=*/true, /*customized=*/null, Kind.GENERIC);
         }
    -    LambdaForm(String debugName,
    -               int arity, Name[] names, int result, Kind kind) {
    -        this(debugName, arity, names, result, /*forceInline=*/true, /*customized=*/null, kind);
    +    LambdaForm(int arity, Name[] names, int result, Kind kind) {
    +        this(arity, names, result, /*forceInline=*/true, /*customized=*/null, kind);
         }
    -    LambdaForm(String debugName,
    -               int arity, Name[] names, int result, boolean forceInline, MethodHandle customized) {
    -        this(debugName, arity, names, result, forceInline, customized, Kind.GENERIC);
    +    LambdaForm(int arity, Name[] names, int result, boolean forceInline, MethodHandle customized) {
    +        this(arity, names, result, forceInline, customized, Kind.GENERIC);
         }
    -    LambdaForm(String debugName,
    -               int arity, Name[] names, int result, boolean forceInline, MethodHandle customized, Kind kind) {
    +    LambdaForm(int arity, Name[] names, int result, boolean forceInline, MethodHandle customized, Kind kind) {
             assert(namesOK(arity, names));
             this.arity = arity;
             this.result = fixResult(result, names);
             this.names = names.clone();
    -        this.debugName = fixDebugName(debugName);
             this.forceInline = forceInline;
             this.customized = customized;
             this.kind = kind;
    @@ -364,31 +370,23 @@ class LambdaForm {
                 compileToBytecode();
             }
         }
    -    LambdaForm(String debugName,
    -               int arity, Name[] names) {
    -        this(debugName, arity, names, LAST_RESULT, /*forceInline=*/true, /*customized=*/null, Kind.GENERIC);
    +    LambdaForm(int arity, Name[] names) {
    +        this(arity, names, LAST_RESULT, /*forceInline=*/true, /*customized=*/null, Kind.GENERIC);
         }
    -    LambdaForm(String debugName,
    -               int arity, Name[] names, Kind kind) {
    -        this(debugName, arity, names, LAST_RESULT, /*forceInline=*/true, /*customized=*/null, kind);
    +    LambdaForm(int arity, Name[] names, Kind kind) {
    +        this(arity, names, LAST_RESULT, /*forceInline=*/true, /*customized=*/null, kind);
         }
    -    LambdaForm(String debugName,
    -               int arity, Name[] names, boolean forceInline) {
    -        this(debugName, arity, names, LAST_RESULT, forceInline, /*customized=*/null, Kind.GENERIC);
    +    LambdaForm(int arity, Name[] names, boolean forceInline) {
    +        this(arity, names, LAST_RESULT, forceInline, /*customized=*/null, Kind.GENERIC);
         }
    -    LambdaForm(String debugName,
    -               int arity, Name[] names, boolean forceInline, Kind kind) {
    -        this(debugName, arity, names, LAST_RESULT, forceInline, /*customized=*/null, kind);
    +    LambdaForm(int arity, Name[] names, boolean forceInline, Kind kind) {
    +        this(arity, names, LAST_RESULT, forceInline, /*customized=*/null, kind);
         }
    -    LambdaForm(String debugName,
    -               Name[] formals, Name[] temps, Name result) {
    -        this(debugName,
    -             formals.length, buildNames(formals, temps, result), LAST_RESULT, /*forceInline=*/true, /*customized=*/null);
    +    LambdaForm(Name[] formals, Name[] temps, Name result) {
    +        this(formals.length, buildNames(formals, temps, result), LAST_RESULT, /*forceInline=*/true, /*customized=*/null);
         }
    -    LambdaForm(String debugName,
    -               Name[] formals, Name[] temps, Name result, boolean forceInline) {
    -        this(debugName,
    -             formals.length, buildNames(formals, temps, result), LAST_RESULT, forceInline, /*customized=*/null);
    +    LambdaForm(Name[] formals, Name[] temps, Name result, boolean forceInline) {
    +        this(formals.length, buildNames(formals, temps, result), LAST_RESULT, forceInline, /*customized=*/null);
         }
     
         private static Name[] buildNames(Name[] formals, Name[] temps, Name result) {
    @@ -408,10 +406,9 @@ class LambdaForm {
             this.arity = mt.parameterCount();
             this.result = (mt.returnType() == void.class || mt.returnType() == Void.class) ? -1 : arity;
             this.names = buildEmptyNames(arity, mt, result == -1);
    -        this.debugName = "LF.zero";
             this.forceInline = true;
             this.customized = null;
    -        this.kind = Kind.GENERIC;
    +        this.kind = Kind.ZERO;
             assert(nameRefsAreLegal());
             assert(isEmpty());
             String sig = null;
    @@ -436,36 +433,46 @@ class LambdaForm {
             return result;
         }
     
    -    private static String fixDebugName(String debugName) {
    -        if (DEBUG_NAME_COUNTERS != null) {
    -            int under = debugName.indexOf('_');
    -            int length = debugName.length();
    -            if (under < 0)  under = length;
    -            String debugNameStem = debugName.substring(0, under);
    -            Integer ctr;
    -            synchronized (DEBUG_NAME_COUNTERS) {
    -                ctr = DEBUG_NAME_COUNTERS.get(debugNameStem);
    -                if (ctr == null)  ctr = 0;
    -                DEBUG_NAME_COUNTERS.put(debugNameStem, ctr+1);
    -            }
    -            StringBuilder buf = new StringBuilder(debugNameStem);
    -            buf.append('_');
    -            int leadingZero = buf.length();
    -            buf.append((int) ctr);
    -            for (int i = buf.length() - leadingZero; i < 3; i++)
    -                buf.insert(leadingZero, '0');
    -            if (under < length) {
    -                ++under;    // skip "_"
    -                while (under < length && Character.isDigit(debugName.charAt(under))) {
    -                    ++under;
    -                }
    -                if (under < length && debugName.charAt(under) == '_')  ++under;
    -                if (under < length)
    -                    buf.append('_').append(debugName, under, length);
    -            }
    -            return buf.toString();
    +    static boolean debugNames() {
    +        return DEBUG_NAME_COUNTERS != null;
    +    }
    +
    +    static void associateWithDebugName(LambdaForm form, String name) {
    +        assert (debugNames());
    +        synchronized (DEBUG_NAMES) {
    +            DEBUG_NAMES.put(form, name);
             }
    -        return debugName;
    +    }
    +
    +    String lambdaName() {
    +        if (DEBUG_NAMES != null) {
    +            synchronized (DEBUG_NAMES) {
    +                String name = DEBUG_NAMES.get(this);
    +                if (name == null) {
    +                    name = generateDebugName();
    +                }
    +                return name;
    +            }
    +        }
    +        return kind.defaultLambdaName;
    +    }
    +
    +    private String generateDebugName() {
    +        assert (debugNames());
    +        String debugNameStem = kind.defaultLambdaName;
    +        Integer ctr = DEBUG_NAME_COUNTERS.getOrDefault(debugNameStem, 0);
    +        DEBUG_NAME_COUNTERS.put(debugNameStem, ctr + 1);
    +        StringBuilder buf = new StringBuilder(debugNameStem);
    +        int leadingZero = buf.length();
    +        buf.append((int) ctr);
    +        for (int i = buf.length() - leadingZero; i < 3; i++) {
    +            buf.insert(leadingZero, '0');
    +        }
    +        buf.append('_');
    +        buf.append(basicTypeSignature());
    +        String name = buf.toString();
    +        associateWithDebugName(this, name);
    +        return name;
         }
     
         private static boolean namesOK(int arity, Name[] names) {
    @@ -482,7 +489,7 @@ class LambdaForm {
     
         /** Customize LambdaForm for a particular MethodHandle */
         LambdaForm customize(MethodHandle mh) {
    -        LambdaForm customForm = new LambdaForm(debugName, arity, names, result, forceInline, mh, kind);
    +        LambdaForm customForm = new LambdaForm(arity, names, result, forceInline, mh, kind);
             if (COMPILE_THRESHOLD >= 0 && isCompiled) {
                 // If shared LambdaForm has been compiled, compile customized version as well.
                 customForm.compileToBytecode();
    @@ -634,7 +641,7 @@ class LambdaForm {
             for (int i = 0; i < arity; ++i) {
                 ptypes[i] = parameterType(i).btClass;
             }
    -        return MethodType.methodType(returnType().btClass, ptypes);
    +        return MethodType.makeImpl(returnType().btClass, ptypes, true);
         }
     
         /** Return ABC_Z, where the ABC are parameter type characters, and Z is the return type character. */
    @@ -670,7 +677,7 @@ class LambdaForm {
             for (int i = 0; i < ptypes.length; i++)
                 ptypes[i] = basicType(sig.charAt(i)).btClass;
             Class rtype = signatureReturn(sig).btClass;
    -        return MethodType.methodType(rtype, ptypes);
    +        return MethodType.makeImpl(rtype, ptypes, true);
         }
     
         /**
    @@ -840,6 +847,10 @@ class LambdaForm {
             if (vmentry != null && isCompiled) {
                 return;  // already compiled somehow
             }
    +
    +        // Obtain the invoker MethodType outside of the following try block.
    +        // This ensures that an IllegalArgumentException is directly thrown if the
    +        // type would have 256 or more parameters
             MethodType invokerType = methodType();
             assert(vmentry == null || vmentry.getMethodType().basicType().equals(invokerType));
             try {
    @@ -894,10 +905,6 @@ class LambdaForm {
             }
             return true;
         }
    -    private static boolean returnTypesMatch(String sig, Object[] av, Object res) {
    -        MethodHandle mh = (MethodHandle) av[0];
    -        return valueMatches(signatureReturn(sig), mh.type().returnType(), res);
    -    }
         private static boolean checkInt(Class type, Object x) {
             assert(x instanceof Integer);
             if (type == int.class)  return true;
    @@ -1030,7 +1037,8 @@ class LambdaForm {
         }
     
         public String toString() {
    -        StringBuilder buf = new StringBuilder(debugName+"=Lambda(");
    +        String lambdaName = lambdaName();
    +        StringBuilder buf = new StringBuilder(lambdaName + "=Lambda(");
             for (int i = 0; i < names.length; i++) {
                 if (i == arity)  buf.append(")=>{");
                 Name n = names[i];
    @@ -1084,13 +1092,24 @@ class LambdaForm {
             final MemberName member;
             private @Stable MethodHandle resolvedHandle;
             @Stable MethodHandle invoker;
    +        private final MethodHandleImpl.Intrinsic intrinsicName;
     
             NamedFunction(MethodHandle resolvedHandle) {
    -            this(resolvedHandle.internalMemberName(), resolvedHandle);
    +            this(resolvedHandle.internalMemberName(), resolvedHandle, MethodHandleImpl.Intrinsic.NONE);
    +        }
    +        NamedFunction(MethodHandle resolvedHandle, MethodHandleImpl.Intrinsic intrinsic) {
    +            this(resolvedHandle.internalMemberName(), resolvedHandle, intrinsic);
             }
             NamedFunction(MemberName member, MethodHandle resolvedHandle) {
    +            this(member, resolvedHandle, MethodHandleImpl.Intrinsic.NONE);
    +        }
    +        NamedFunction(MemberName member, MethodHandle resolvedHandle, MethodHandleImpl.Intrinsic intrinsic) {
                 this.member = member;
                 this.resolvedHandle = resolvedHandle;
    +            this.intrinsicName = intrinsic;
    +            assert(resolvedHandle == null ||
    +                   resolvedHandle.intrinsicName() == MethodHandleImpl.Intrinsic.NONE ||
    +                   resolvedHandle.intrinsicName() == intrinsic) : resolvedHandle.intrinsicName() + " != " + intrinsic;
                  // The following assert is almost always correct, but will fail for corner cases, such as PrivateInvokeTest.
                  //assert(!isInvokeBasic(member));
             }
    @@ -1103,6 +1122,7 @@ class LambdaForm {
                     // necessary to pass BigArityTest
                     this.member = Invokers.invokeBasicMethod(basicInvokerType);
                 }
    +            this.intrinsicName = MethodHandleImpl.Intrinsic.NONE;
                 assert(isInvokeBasic(member));
             }
     
    @@ -1171,7 +1191,6 @@ class LambdaForm {
                 // If we have a cached invoker, call it right away.
                 // NOTE: The invoker always returns a reference value.
                 if (TRACE_INTERPRETER)  return invokeWithArgumentsTracing(arguments);
    -            assert(checkArgumentTypes(arguments, methodType()));
                 return invoker().invokeBasic(resolvedHandle(), arguments);
             }
     
    @@ -1189,7 +1208,6 @@ class LambdaForm {
                         traceInterpreter("| resolve", this);
                         resolvedHandle();
                     }
    -                assert(checkArgumentTypes(arguments, methodType()));
                     rval = invoker().invokeBasic(resolvedHandle(), arguments);
                 } catch (Throwable ex) {
                     traceInterpreter("] throw =>", ex);
    @@ -1205,23 +1223,6 @@ class LambdaForm {
                 return invoker = computeInvoker(methodType().form());
             }
     
    -        private static boolean checkArgumentTypes(Object[] arguments, MethodType methodType) {
    -            if (true)  return true;  // FIXME
    -            MethodType dstType = methodType.form().erasedType();
    -            MethodType srcType = dstType.basicType().wrap();
    -            Class[] ptypes = new Class[arguments.length];
    -            for (int i = 0; i < arguments.length; i++) {
    -                Object arg = arguments[i];
    -                Class ptype = arg == null ? Object.class : arg.getClass();
    -                // If the dest. type is a primitive we keep the
    -                // argument type.
    -                ptypes[i] = dstType.parameterType(i).isPrimitive() ? ptype : Object.class;
    -            }
    -            MethodType argType = MethodType.methodType(srcType.returnType(), ptypes).wrap();
    -            assert(argType.isConvertibleTo(srcType)) : "wrong argument types: cannot convert " + argType + " to " + srcType;
    -            return true;
    -        }
    -
             MethodType methodType() {
                 if (resolvedHandle != null)
                     return resolvedHandle.type();
    @@ -1274,8 +1275,7 @@ class LambdaForm {
             }
     
             public MethodHandleImpl.Intrinsic intrinsicName() {
    -            return resolvedHandle == null ? MethodHandleImpl.Intrinsic.NONE
    -                                          : resolvedHandle.intrinsicName();
    +            return intrinsicName;
             }
         }
     
    @@ -1717,7 +1717,7 @@ class LambdaForm {
             boolean isVoid = (type == V_TYPE);
             Class btClass = type.btClass;
             MethodType zeType = MethodType.methodType(btClass);
    -        MethodType idType = (isVoid) ? zeType : zeType.appendParameterTypes(btClass);
    +        MethodType idType = (isVoid) ? zeType : MethodType.methodType(btClass, btClass);
     
             // Look up symbolic names.  It might not be necessary to have these,
             // but if we need to emit direct references to bytecodes, it helps.
    @@ -1742,7 +1742,7 @@ class LambdaForm {
             // bootstrap dependency on this method in case we're interpreting LFs
             if (isVoid) {
                 Name[] idNames = new Name[] { argument(0, L_TYPE) };
    -            idForm = new LambdaForm(idMem.getName(), 1, idNames, VOID_RESULT, Kind.IDENTITY);
    +            idForm = new LambdaForm(1, idNames, VOID_RESULT, Kind.IDENTITY);
                 idForm.compileToBytecode();
                 idFun = new NamedFunction(idMem, SimpleMethodHandle.make(idMem.getInvocationType(), idForm));
     
    @@ -1750,17 +1750,17 @@ class LambdaForm {
                 zeFun = idFun;
             } else {
                 Name[] idNames = new Name[] { argument(0, L_TYPE), argument(1, type) };
    -            idForm = new LambdaForm(idMem.getName(), 2, idNames, 1, Kind.IDENTITY);
    +            idForm = new LambdaForm(2, idNames, 1, Kind.IDENTITY);
                 idForm.compileToBytecode();
    -            idFun = new NamedFunction(idMem, MethodHandleImpl.makeIntrinsic(
    -                    idMem.getInvocationType(), idForm, MethodHandleImpl.Intrinsic.IDENTITY));
    +            idFun = new NamedFunction(idMem, SimpleMethodHandle.make(idMem.getInvocationType(), idForm),
    +                        MethodHandleImpl.Intrinsic.IDENTITY);
     
                 Object zeValue = Wrapper.forBasicType(btChar).zero();
                 Name[] zeNames = new Name[] { argument(0, L_TYPE), new Name(idFun, zeValue) };
    -            zeForm = new LambdaForm(zeMem.getName(), 1, zeNames, 1, Kind.ZERO);
    +            zeForm = new LambdaForm(1, zeNames, 1, Kind.ZERO);
                 zeForm.compileToBytecode();
    -            zeFun = new NamedFunction(zeMem, MethodHandleImpl.makeIntrinsic(
    -                    zeMem.getInvocationType(), zeForm, MethodHandleImpl.Intrinsic.ZERO));
    +            zeFun = new NamedFunction(zeMem, SimpleMethodHandle.make(zeMem.getInvocationType(), zeForm),
    +                    MethodHandleImpl.Intrinsic.ZERO);
             }
     
             LF_zero[ord] = zeForm;
    @@ -1805,11 +1805,15 @@ class LambdaForm {
         }
     
         private static final HashMap DEBUG_NAME_COUNTERS;
    +    private static final HashMap DEBUG_NAMES;
         static {
    -        if (debugEnabled())
    +        if (debugEnabled()) {
                 DEBUG_NAME_COUNTERS = new HashMap<>();
    -        else
    +            DEBUG_NAMES = new HashMap<>();
    +        } else {
                 DEBUG_NAME_COUNTERS = null;
    +            DEBUG_NAMES = null;
    +        }
         }
     
         static {
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormBuffer.java b/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormBuffer.java
    index cc4b97b5479..bcf1733461b 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormBuffer.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormBuffer.java
    @@ -40,7 +40,6 @@ final class LambdaFormBuffer {
         private byte flags;
         private int firstChange;
         private Name resultName;
    -    private String debugName;
         private ArrayList dups;
     
         private static final int F_TRANS = 0x10, F_OWNED = 0x03;
    @@ -50,15 +49,15 @@ final class LambdaFormBuffer {
             setNames(lf.names);
             int result = lf.result;
             if (result == LAST_RESULT)  result = length - 1;
    -        if (result >= 0 && lf.names[result].type != V_TYPE)
    +        if (result >= 0 && lf.names[result].type != V_TYPE) {
                 resultName = lf.names[result];
    -        debugName = lf.debugName;
    +        }
             assert(lf.nameRefsAreLegal());
         }
     
         private LambdaForm lambdaForm() {
             assert(!inTrans());  // need endEdit call to tidy things up
    -        return new LambdaForm(debugName, arity, nameArray(), resultIndex());
    +        return new LambdaForm(arity, nameArray(), resultIndex());
         }
     
         Name name(int i) {
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormEditor.java b/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormEditor.java
    index ddd60ca082f..542500efc3f 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormEditor.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormEditor.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -532,7 +532,8 @@ class LambdaFormEditor {
             assert(pos > 0);  // cannot spread the MH arg itself
     
             Name spreadParam = new Name(L_TYPE);
    -        Name checkSpread = new Name(MethodHandleImpl.NF_checkSpreadArgument, spreadParam, arrayLength);
    +        Name checkSpread = new Name(MethodHandleImpl.getFunction(MethodHandleImpl.NF_checkSpreadArgument),
    +                spreadParam, arrayLength);
     
             // insert the new expressions
             int exprPos = lambdaForm.arity();
    @@ -540,7 +541,7 @@ class LambdaFormEditor {
             // adjust the arguments
             MethodHandle aload = MethodHandles.arrayElementGetter(erasedArrayType);
             for (int i = 0; i < arrayLength; i++) {
    -            Name loadArgument = new Name(aload, spreadParam, i);
    +            Name loadArgument = new Name(new NamedFunction(aload, Intrinsic.ARRAY_LOAD), spreadParam, i);
                 buf.insertExpression(exprPos + i, loadArgument);
                 buf.replaceParameterByCopy(pos + i, exprPos + i);
             }
    @@ -603,7 +604,8 @@ class LambdaFormEditor {
             for (int i = 0; i < collectorArity; i++) {
                 newParams[i] = new Name(pos + i, argType);
             }
    -        Name callCombiner = new Name(arrayCollector, (Object[]) /*...*/ newParams);
    +        Name callCombiner = new Name(new NamedFunction(arrayCollector, Intrinsic.NEW_ARRAY),
    +                                        (Object[]) /*...*/ newParams);
     
             // insert the new expression
             int exprPos = lambdaForm.arity();
    @@ -915,7 +917,7 @@ class LambdaFormEditor {
                 }
             }
     
    -        form = new LambdaForm(lambdaForm.debugName, arity2, names2, result2);
    +        form = new LambdaForm(arity2, names2, result2);
             return putInCache(key, form);
         }
     
    @@ -932,14 +934,14 @@ class LambdaFormEditor {
     
             // replace the null entry in the MHImpl.loop invocation with localTypes
             Name invokeLoop = lambdaForm.names[pos + 1];
    -        assert(invokeLoop.function == NF_loop);
    +        assert(invokeLoop.function.equals(MethodHandleImpl.getFunction(NF_loop)));
             Object[] args = Arrays.copyOf(invokeLoop.arguments, invokeLoop.arguments.length);
             assert(args[0] == null);
             args[0] = localTypes;
     
             LambdaFormBuffer buf = buffer();
             buf.startEdit();
    -        buf.changeName(pos + 1, new Name(NF_loop, args));
    +        buf.changeName(pos + 1, new Name(MethodHandleImpl.getFunction(NF_loop), args));
             form = buf.endEdit();
     
             return putInCache(key, form);
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/MemberName.java b/jdk/src/java.base/share/classes/java/lang/invoke/MemberName.java
    index 92ab77cedf4..41a4545d6bb 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/MemberName.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/MemberName.java
    @@ -148,7 +148,7 @@ import static java.lang.invoke.MethodHandleStatics.newInternalError;
                     Object[] typeInfo = (Object[]) type;
                     Class[] ptypes = (Class[]) typeInfo[1];
                     Class rtype = (Class) typeInfo[0];
    -                MethodType res = MethodType.methodType(rtype, ptypes);
    +                MethodType res = MethodType.makeImpl(rtype, ptypes, true);
                     type = res;
                 }
                 // Make sure type is a MethodType for racing threads.
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java b/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java
    index 010b61809ee..d6222f99cc5 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -399,7 +399,7 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
                 assert(RETURN_CONV == names.length-1);
             }
     
    -        LambdaForm form = new LambdaForm("convert", lambdaType.parameterCount(), names, RESULT);
    +        LambdaForm form = new LambdaForm(lambdaType.parameterCount(), names, RESULT, Kind.CONVERT);
             return SimpleMethodHandle.make(srcType, form);
         }
     
    @@ -589,10 +589,10 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
                     // Spread the array.
                     MethodHandle aload = MethodHandles.arrayElementGetter(spreadArgType);
                     Name array = names[argIndex];
    -                names[nameCursor++] = new Name(NF_checkSpreadArgument, array, spreadArgCount);
    +                names[nameCursor++] = new Name(getFunction(NF_checkSpreadArgument), array, spreadArgCount);
                     for (int j = 0; j < spreadArgCount; i++, j++) {
                         indexes[i] = nameCursor;
    -                    names[nameCursor++] = new Name(aload, array, j);
    +                    names[nameCursor++] = new Name(new NamedFunction(aload, Intrinsic.ARRAY_LOAD), array, j);
                     }
                 } else if (i < indexes.length) {
                     indexes[i] = argIndex;
    @@ -608,7 +608,7 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
             }
             names[names.length - 1] = new Name(target, (Object[]) targetArgs);
     
    -        LambdaForm form = new LambdaForm("spread", lambdaType.parameterCount(), names);
    +        LambdaForm form = new LambdaForm(lambdaType.parameterCount(), names, Kind.SPREAD);
             return SimpleMethodHandle.make(srcType, form);
         }
     
    @@ -676,7 +676,7 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
             assert(inputArgPos + chunk == collectNamePos);  // use of rest of input args also
             names[targetNamePos] = new Name(target, (Object[]) targetArgs);
     
    -        LambdaForm form = new LambdaForm("collect", lambdaType.parameterCount(), names);
    +        LambdaForm form = new LambdaForm(lambdaType.parameterCount(), names, Kind.COLLECT);
             return SimpleMethodHandle.make(srcType, form);
         }
     
    @@ -774,7 +774,7 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
                 @Override
                 public LambdaForm apply(MethodHandle target) {
                     return DelegatingMethodHandle.makeReinvokerForm(target,
    -                                   MethodTypeForm.LF_DELEGATE_BLOCK_INLINING, CountingWrapper.class, "reinvoker.dontInline", false,
    +                                   MethodTypeForm.LF_DELEGATE_BLOCK_INLINING, CountingWrapper.class, false,
                                        DelegatingMethodHandle.NF_getTarget, CountingWrapper.NF_maybeStopCounting);
                 }
             };
    @@ -934,16 +934,16 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
     
             // profile branch
             if (PROFILE != -1) {
    -            names[PROFILE] = new Name(NF_profileBoolean, names[CALL_TEST], names[GET_COUNTERS]);
    +            names[PROFILE] = new Name(getFunction(NF_profileBoolean), names[CALL_TEST], names[GET_COUNTERS]);
             }
             // call selectAlternative
    -        names[SELECT_ALT] = new Name(getConstantHandle(MH_selectAlternative), names[TEST], names[GET_TARGET], names[GET_FALLBACK]);
    +        names[SELECT_ALT] = new Name(new NamedFunction(getConstantHandle(MH_selectAlternative), Intrinsic.SELECT_ALTERNATIVE), names[TEST], names[GET_TARGET], names[GET_FALLBACK]);
     
             // call target or fallback
             invokeArgs[0] = names[SELECT_ALT];
             names[CALL_TARGET] = new Name(basicType, invokeArgs);
     
    -        lform = new LambdaForm("guard", lambdaType.parameterCount(), names, /*forceInline=*/true);
    +        lform = new LambdaForm(lambdaType.parameterCount(), names, /*forceInline=*/true, Kind.GUARD);
     
             return basicType.form().setCachedLambdaForm(MethodTypeForm.LF_GWT, lform);
         }
    @@ -1008,18 +1008,18 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
             Object[] args = new Object[invokeBasic.type().parameterCount()];
             args[0] = names[GET_COLLECT_ARGS];
             System.arraycopy(names, ARG_BASE, args, 1, ARG_LIMIT-ARG_BASE);
    -        names[BOXED_ARGS] = new Name(makeIntrinsic(invokeBasic, Intrinsic.GUARD_WITH_CATCH), args);
    +        names[BOXED_ARGS] = new Name(new NamedFunction(invokeBasic, Intrinsic.GUARD_WITH_CATCH), args);
     
             // t_{i+1}:L=MethodHandleImpl.guardWithCatch(target:L,exType:L,catcher:L,t_{i}:L);
             Object[] gwcArgs = new Object[] {names[GET_TARGET], names[GET_CLASS], names[GET_CATCHER], names[BOXED_ARGS]};
    -        names[TRY_CATCH] = new Name(NF_guardWithCatch, gwcArgs);
    +        names[TRY_CATCH] = new Name(getFunction(NF_guardWithCatch), gwcArgs);
     
             // t_{i+2}:I=MethodHandle.invokeBasic(unbox:L,t_{i+1}:L);
             MethodHandle invokeBasicUnbox = MethodHandles.basicInvoker(MethodType.methodType(basicType.rtype(), Object.class));
             Object[] unboxArgs  = new Object[] {names[GET_UNBOX_RESULT], names[TRY_CATCH]};
             names[UNBOX_RESULT] = new Name(invokeBasicUnbox, unboxArgs);
     
    -        lform = new LambdaForm("guardWithCatch", lambdaType.parameterCount(), names);
    +        lform = new LambdaForm(lambdaType.parameterCount(), names, Kind.GUARD_WITH_CATCH);
     
             return basicType.form().setCachedLambdaForm(MethodTypeForm.LF_GWC, lform);
         }
    @@ -1085,7 +1085,7 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
                 mh = MethodHandles.dropArguments(mh, 1, Arrays.copyOfRange(type.parameterArray(), 1, arity));
                 return mh;
             }
    -        return makePairwiseConvert(NF_throwException.resolvedHandle(), type, false, true);
    +        return makePairwiseConvert(getFunction(NF_throwException).resolvedHandle(), type, false, true);
         }
     
         static  Empty throwException(T t) throws T { throw t; }
    @@ -1673,33 +1673,57 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
         }
     
         // Local constant functions:
    -    /*non-public*/ static final NamedFunction
    -        NF_checkSpreadArgument,
    -        NF_guardWithCatch,
    -        NF_throwException,
    -        NF_tryFinally,
    -        NF_loop,
    -        NF_profileBoolean;
     
    -    static {
    +    /* non-public */
    +    static final byte NF_checkSpreadArgument = 0,
    +            NF_guardWithCatch = 1,
    +            NF_throwException = 2,
    +            NF_tryFinally = 3,
    +            NF_loop = 4,
    +            NF_profileBoolean = 5,
    +            NF_LIMIT = 6;
    +
    +    private static final @Stable NamedFunction[] NFS = new NamedFunction[NF_LIMIT];
    +
    +    static NamedFunction getFunction(byte func) {
    +        NamedFunction nf = NFS[func];
    +        if (nf != null) {
    +            return nf;
    +        }
    +        return NFS[func] = createFunction(func);
    +    }
    +
    +    private static NamedFunction createFunction(byte func) {
             try {
    -            NF_checkSpreadArgument = new NamedFunction(MethodHandleImpl.class
    -                    .getDeclaredMethod("checkSpreadArgument", Object.class, int.class));
    -            NF_guardWithCatch = new NamedFunction(MethodHandleImpl.class
    -                    .getDeclaredMethod("guardWithCatch", MethodHandle.class, Class.class,
    -                            MethodHandle.class, Object[].class));
    -            NF_tryFinally = new NamedFunction(MethodHandleImpl.class
    -                    .getDeclaredMethod("tryFinally", MethodHandle.class, MethodHandle.class, Object[].class));
    -            NF_loop = new NamedFunction(MethodHandleImpl.class
    -                    .getDeclaredMethod("loop", BasicType[].class, LoopClauses.class, Object[].class));
    -            NF_throwException = new NamedFunction(MethodHandleImpl.class
    -                    .getDeclaredMethod("throwException", Throwable.class));
    -            NF_profileBoolean = new NamedFunction(MethodHandleImpl.class
    -                    .getDeclaredMethod("profileBoolean", boolean.class, int[].class));
    +            switch (func) {
    +                case NF_checkSpreadArgument:
    +                    return new NamedFunction(MethodHandleImpl.class
    +                            .getDeclaredMethod("checkSpreadArgument", Object.class, int.class));
    +                case NF_guardWithCatch:
    +                    return new NamedFunction(MethodHandleImpl.class
    +                            .getDeclaredMethod("guardWithCatch", MethodHandle.class, Class.class,
    +                                    MethodHandle.class, Object[].class));
    +                case NF_tryFinally:
    +                    return new NamedFunction(MethodHandleImpl.class
    +                            .getDeclaredMethod("tryFinally", MethodHandle.class, MethodHandle.class, Object[].class));
    +                case NF_loop:
    +                    return new NamedFunction(MethodHandleImpl.class
    +                            .getDeclaredMethod("loop", BasicType[].class, LoopClauses.class, Object[].class));
    +                case NF_throwException:
    +                    return new NamedFunction(MethodHandleImpl.class
    +                            .getDeclaredMethod("throwException", Throwable.class));
    +                case NF_profileBoolean:
    +                    return new NamedFunction(MethodHandleImpl.class
    +                            .getDeclaredMethod("profileBoolean", boolean.class, int[].class));
    +                default:
    +                    throw new InternalError("Undefined function: " + func);
    +            }
             } catch (ReflectiveOperationException ex) {
                 throw newInternalError(ex);
             }
    +    }
     
    +    static {
             SharedSecrets.setJavaLangInvokeAccess(new JavaLangInvokeAccess() {
                 @Override
                 public Object newMemberName() {
    @@ -1872,13 +1896,13 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
                 Object[] args = new Object[invokeBasic.type().parameterCount()];
                 args[0] = names[GET_COLLECT_ARGS];
                 System.arraycopy(names, ARG_BASE, args, 1, ARG_LIMIT - ARG_BASE);
    -            names[BOXED_ARGS] = new Name(makeIntrinsic(invokeBasic, Intrinsic.LOOP), args);
    +            names[BOXED_ARGS] = new Name(new NamedFunction(invokeBasic, Intrinsic.LOOP), args);
     
                 // t_{i+1}:L=MethodHandleImpl.loop(localTypes:L,clauses:L,t_{i}:L);
                 Object[] lArgs =
                         new Object[]{null, // placeholder for BasicType[] localTypes - will be added by LambdaFormEditor
                                 names[GET_CLAUSE_DATA], names[BOXED_ARGS]};
    -            names[LOOP] = new Name(NF_loop, lArgs);
    +            names[LOOP] = new Name(getFunction(NF_loop), lArgs);
     
                 // t_{i+2}:I=MethodHandle.invokeBasic(unbox:L,t_{i+1}:L);
                 MethodHandle invokeBasicUnbox = MethodHandles.basicInvoker(MethodType.methodType(basicType.rtype(), Object.class));
    @@ -1886,7 +1910,7 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
                 names[UNBOX_RESULT] = new Name(invokeBasicUnbox, unboxArgs);
     
                 lform = basicType.form().setCachedLambdaForm(MethodTypeForm.LF_LOOP,
    -                    new LambdaForm("loop", lambdaType.parameterCount(), names));
    +                    new LambdaForm(lambdaType.parameterCount(), names, Kind.LOOP));
             }
     
             // BOXED_ARGS is the index into the names array where the loop idiom starts
    @@ -2109,18 +2133,18 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
             Object[] args = new Object[invokeBasic.type().parameterCount()];
             args[0] = names[GET_COLLECT_ARGS];
             System.arraycopy(names, ARG_BASE, args, 1, ARG_LIMIT-ARG_BASE);
    -        names[BOXED_ARGS] = new Name(makeIntrinsic(invokeBasic, Intrinsic.TRY_FINALLY), args);
    +        names[BOXED_ARGS] = new Name(new NamedFunction(invokeBasic, Intrinsic.TRY_FINALLY), args);
     
             // t_{i+1}:L=MethodHandleImpl.tryFinally(target:L,exType:L,catcher:L,t_{i}:L);
             Object[] tfArgs = new Object[] {names[GET_TARGET], names[GET_CLEANUP], names[BOXED_ARGS]};
    -        names[TRY_FINALLY] = new Name(NF_tryFinally, tfArgs);
    +        names[TRY_FINALLY] = new Name(getFunction(NF_tryFinally), tfArgs);
     
             // t_{i+2}:I=MethodHandle.invokeBasic(unbox:L,t_{i+1}:L);
             MethodHandle invokeBasicUnbox = MethodHandles.basicInvoker(MethodType.methodType(basicType.rtype(), Object.class));
             Object[] unboxArgs  = new Object[] {names[GET_UNBOX_RESULT], names[TRY_FINALLY]};
             names[UNBOX_RESULT] = new Name(invokeBasicUnbox, unboxArgs);
     
    -        lform = new LambdaForm("tryFinally", lambdaType.parameterCount(), names);
    +        lform = new LambdaForm(lambdaType.parameterCount(), names, Kind.TRY_FINALLY);
     
             return basicType.form().setCachedLambdaForm(MethodTypeForm.LF_TF, lform);
         }
    @@ -2201,9 +2225,8 @@ import static jdk.internal.org.objectweb.asm.Opcodes.*;
                         return IMPL_LOOKUP.findStatic(MethodHandleImpl.class, "fillNewTypedArray",
                                 MethodType.methodType(Object[].class, Object[].class, Integer.class, Object[].class));
                     case MH_selectAlternative:
    -                    return makeIntrinsic(IMPL_LOOKUP.findStatic(MethodHandleImpl.class, "selectAlternative",
    -                            MethodType.methodType(MethodHandle.class, boolean.class, MethodHandle.class, MethodHandle.class)),
    -                        Intrinsic.SELECT_ALTERNATIVE);
    +                    return IMPL_LOOKUP.findStatic(MethodHandleImpl.class, "selectAlternative",
    +                            MethodType.methodType(MethodHandle.class, boolean.class, MethodHandle.class, MethodHandle.class));
                     case MH_countedLoopPred:
                         return IMPL_LOOKUP.findStatic(MethodHandleImpl.class, "countedLoopPredicate",
                                 MethodType.methodType(boolean.class, int.class, int.class));
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleNatives.java b/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleNatives.java
    index 1065b8d1482..110369fb13e 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleNatives.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleNatives.java
    @@ -420,7 +420,7 @@ class MethodHandleNatives {
                                                                  MethodType mtype,
                                                                  Object[] appendixResult) {
             // Get the signature method type
    -        MethodType sigType = mtype.basicType();
    +        final MethodType sigType = mtype.basicType();
     
             // Get the access kind from the method name
             VarHandle.AccessMode ak;
    @@ -430,32 +430,37 @@ class MethodHandleNatives {
                 throw MethodHandleStatics.newInternalError(e);
             }
     
    -        // If not polymorphic in the return type, such as the compareAndSet
    -        // methods that return boolean
    -        if (ak.at.isMonomorphicInReturnType) {
    -            if (ak.at.returnType != mtype.returnType()) {
    -                // The caller contains a different return type than that
    -                // defined by the method
    -                throw newNoSuchMethodErrorOnVarHandle(name, mtype);
    -            }
    -            // Adjust the return type of the signature method type
    -            sigType = sigType.changeReturnType(ak.at.returnType);
    -        }
    -
    -        // Get the guard method type for linking
    -        MethodType guardType = sigType
    -                // VarHandle at start
    -                .insertParameterTypes(0, VarHandle.class)
    -                // Access descriptor at end
    -                .appendParameterTypes(VarHandle.AccessDescriptor.class);
    -
             // Create the appendix descriptor constant
             VarHandle.AccessDescriptor ad = new VarHandle.AccessDescriptor(mtype, ak.at.ordinal(), ak.ordinal());
             appendixResult[0] = ad;
     
             if (MethodHandleStatics.VAR_HANDLE_GUARDS) {
    +            // If not polymorphic in the return type, such as the compareAndSet
    +            // methods that return boolean
    +            Class guardReturnType = sigType.returnType();
    +            if (ak.at.isMonomorphicInReturnType) {
    +                if (ak.at.returnType != mtype.returnType()) {
    +                    // The caller contains a different return type than that
    +                    // defined by the method
    +                    throw newNoSuchMethodErrorOnVarHandle(name, mtype);
    +                }
    +                // Adjust the return type of the signature method type
    +                guardReturnType = ak.at.returnType;
    +            }
    +
    +            // Get the guard method type for linking
    +            final Class[] guardParams = new Class[sigType.parameterCount() + 2];
    +            // VarHandle at start
    +            guardParams[0] = VarHandle.class;
    +            for (int i = 0; i < sigType.parameterCount(); i++) {
    +                guardParams[i + 1] = sigType.parameterType(i);
    +            }
    +            // Access descriptor at end
    +            guardParams[guardParams.length - 1] = VarHandle.AccessDescriptor.class;
    +            MethodType guardType = MethodType.makeImpl(guardReturnType, guardParams, true);
    +
                 MemberName linker = new MemberName(
    -                    VarHandleGuards.class, "guard_" + getVarHandleMethodSignature(sigType),
    +                    VarHandleGuards.class, getVarHandleGuardMethodName(guardType),
                         guardType, REF_invokeStatic);
     
                 linker = MemberName.getFactory().resolveOrNull(REF_invokeStatic, linker,
    @@ -466,16 +471,18 @@ class MethodHandleNatives {
                 // Fall back to lambda form linkage if guard method is not available
                 // TODO Optionally log fallback ?
             }
    -        return Invokers.varHandleInvokeLinkerMethod(name, mtype);
    +        return Invokers.varHandleInvokeLinkerMethod(ak, mtype);
         }
    -    static String getVarHandleMethodSignature(MethodType mt) {
    -        StringBuilder sb = new StringBuilder(mt.parameterCount() + 2);
    +    static String getVarHandleGuardMethodName(MethodType guardType) {
    +        String prefix = "guard_";
    +        StringBuilder sb = new StringBuilder(prefix.length() + guardType.parameterCount());
     
    -        for (int i = 0; i < mt.parameterCount(); i++) {
    -            Class pt = mt.parameterType(i);
    +        sb.append(prefix);
    +        for (int i = 1; i < guardType.parameterCount() - 1; i++) {
    +            Class pt = guardType.parameterType(i);
                 sb.append(getCharType(pt));
             }
    -        sb.append('_').append(getCharType(mt.returnType()));
    +        sb.append('_').append(getCharType(guardType.returnType()));
             return sb.toString();
         }
         static char getCharType(Class pt) {
    diff --git a/jdk/src/java.base/share/classes/java/lang/invoke/MethodType.java b/jdk/src/java.base/share/classes/java/lang/invoke/MethodType.java
    index 860ef23f019..df7904de00d 100644
    --- a/jdk/src/java.base/share/classes/java/lang/invoke/MethodType.java
    +++ b/jdk/src/java.base/share/classes/java/lang/invoke/MethodType.java
    @@ -95,7 +95,7 @@ class MethodType implements java.io.Serializable {
         private static final long serialVersionUID = 292L;  // {rtype, {ptype...}}
     
         // The rtype and ptypes fields define the structural identity of the method type:
    -    private final Class   rtype;
    +    private final @Stable Class   rtype;
         private final @Stable Class[] ptypes;
     
         // The remaining fields are caches of various sorts:
    @@ -117,7 +117,8 @@ class MethodType implements java.io.Serializable {
     
         /**
          * Construct a temporary unchecked instance of MethodType for use only as a key to the intern table.
    -     * Does not check the given parameters for validity, and must be discarded after it is used as a searching key.
    +     * Does not check the given parameters for validity, and must discarded (if untrusted) or checked
    +     * (if trusted) after it has been used as a searching key.
          * The parameters are reversed for this constructor, so that it is not accidentally used.
          */
         private MethodType(Class[] ptypes, Class rtype) {
    @@ -181,6 +182,7 @@ class MethodType implements java.io.Serializable {
             checkSlotCount(ptypes.length + slots);
             return slots;
         }
    +
         static {
             // MAX_JVM_ARITY must be power of 2 minus 1 for following code trick to work:
             assert((MAX_JVM_ARITY & (MAX_JVM_ARITY+1)) == 0);
    @@ -303,18 +305,26 @@ class MethodType implements java.io.Serializable {
          */
         /*trusted*/ static
         MethodType makeImpl(Class rtype, Class[] ptypes, boolean trusted) {
    -        MethodType mt = internTable.get(new MethodType(ptypes, rtype));
    -        if (mt != null)
    -            return mt;
             if (ptypes.length == 0) {
                 ptypes = NO_PTYPES; trusted = true;
             }
    -        mt = new MethodType(rtype, ptypes, trusted);
    +        MethodType primordialMT = new MethodType(ptypes, rtype);
    +        MethodType mt = internTable.get(primordialMT);
    +        if (mt != null)
    +            return mt;
    +
             // promote the object to the Real Thing, and reprobe
    +        if (trusted) {
    +            MethodType.checkRtype(rtype);
    +            MethodType.checkPtypes(ptypes);
    +            mt = primordialMT;
    +        } else {
    +            mt = new MethodType(rtype, ptypes, false);
    +        }
             mt.form = MethodTypeForm.findForm(mt);
             return internTable.add(mt);
         }
    -    private static final MethodType[] objectOnlyTypes = new MethodType[20];
    +    private static final @Stable MethodType[] objectOnlyTypes = new MethodType[20];
     
         /**
          * Finds or creates a method type whose components are {@code Object} with an optional trailing {@code Object[]} array.
    @@ -398,9 +408,14 @@ class MethodType implements java.io.Serializable {
             checkSlotCount(parameterSlotCount() + ptypesToInsert.length + ins);
             int ilen = ptypesToInsert.length;
             if (ilen == 0)  return this;
    -        Class[] nptypes = Arrays.copyOfRange(ptypes, 0, len+ilen);
    -        System.arraycopy(nptypes, num, nptypes, num+ilen, len-num);
    +        Class[] nptypes = new Class[len + ilen];
    +        if (num > 0) {
    +            System.arraycopy(ptypes, 0, nptypes, 0, num);
    +        }
             System.arraycopy(ptypesToInsert, 0, nptypes, num, ilen);
    +        if (num < len) {
    +            System.arraycopy(ptypes, num, nptypes, num+ilen, len-num);
    +        }
             return makeImpl(rtype, nptypes, true);
         }
     
    @@ -636,11 +651,14 @@ class MethodType implements java.io.Serializable {
             return form.basicType();
         }
     
    +    private static final @Stable Class[] METHOD_HANDLE_ARRAY
    +            = new Class[] { MethodHandle.class };
    +
         /**
          * @return a version of the original type with MethodHandle prepended as the first argument
          */
         /*non-public*/ MethodType invokerType() {
    -        return insertParameterTypes(0, MethodHandle.class);
    +        return insertParameterTypes(0, METHOD_HANDLE_ARRAY);
         }
     
         /**
    diff --git a/jdk/src/java.base/share/classes/java/net/ContentHandler.java b/jdk/src/java.base/share/classes/java/net/ContentHandler.java
    index bea0391b1ea..119af89fed4 100644
    --- a/jdk/src/java.base/share/classes/java/net/ContentHandler.java
    +++ b/jdk/src/java.base/share/classes/java/net/ContentHandler.java
    @@ -37,10 +37,10 @@ import java.io.IOException;
      * application calls the {@code getContent} method in class
      * {@code URL} or in {@code URLConnection}.
      * The application's content handler factory (an instance of a class that
    - * implements the interface {@code ContentHandlerFactory} set
    - * up by a call to {@code setContentHandler}) is
    - * called with a {@code String} giving the MIME type of the
    - * object being received on the socket. The factory returns an
    + * implements the interface {@code ContentHandlerFactory} set up by a call to
    + * {@link URLConnection#setContentHandlerFactory(ContentHandlerFactory)
    + * setContentHandlerFactory} is called with a {@code String} giving the
    + * MIME type of the object being received on the socket. The factory returns an
      * instance of a subclass of {@code ContentHandler}, and its
      * {@code getContent} method is called to create the object.
      * 

    @@ -99,7 +99,8 @@ public abstract class ContentHandler { * representation of an object, this method reads that stream and * creates an object that matches one of the types specified. * - * The default implementation of this method should call getContent() + * The default implementation of this method should call + * {@link #getContent(URLConnection)} * and screen the return type for a match of the suggested types. * * @param urlc a URL connection. diff --git a/jdk/src/java.base/share/classes/java/net/URLConnection.java b/jdk/src/java.base/share/classes/java/net/URLConnection.java index c9331b704af..e54a0b1a126 100644 --- a/jdk/src/java.base/share/classes/java/net/URLConnection.java +++ b/jdk/src/java.base/share/classes/java/net/URLConnection.java @@ -881,7 +881,7 @@ public abstract class URLConnection { * Sets the value of the {@code doInput} field for this * {@code URLConnection} to the specified value. *

    - * A URL connection can be used for input and/or output. Set the DoInput + * A URL connection can be used for input and/or output. Set the doInput * flag to true if you intend to use the URL connection for input, * false if not. The default is true. * @@ -911,7 +911,7 @@ public abstract class URLConnection { * Sets the value of the {@code doOutput} field for this * {@code URLConnection} to the specified value. *

    - * A URL connection can be used for input and/or output. Set the DoOutput + * A URL connection can be used for input and/or output. Set the doOutput * flag to true if you intend to use the URL connection for output, * false if not. The default is false. * @@ -977,7 +977,7 @@ public abstract class URLConnection { * Returns the default value of the {@code allowUserInteraction} * field. *

    - * Ths default is "sticky", being a part of the static state of all + * This default is "sticky", being a part of the static state of all * URLConnections. This flag applies to the next, and all following * URLConnections that are created. * @@ -998,7 +998,7 @@ public abstract class URLConnection { * "reload" button in a browser). If the UseCaches flag on a connection * is true, the connection is allowed to use whatever caches it can. * If false, caches are to be ignored. - * The default value comes from DefaultUseCaches, which defaults to + * The default value comes from defaultUseCaches, which defaults to * true. A default value can also be set per-protocol using * {@link #setDefaultUseCaches(String,boolean)}. * @@ -1257,7 +1257,7 @@ public abstract class URLConnection { * application. It can be called at most once by an application. *

    * The {@code ContentHandlerFactory} instance is used to - * construct a content handler from a content type + * construct a content handler from a content type. *

    * If there is a security manager, this method first calls * the security manager's {@code checkSetFactory} method diff --git a/jdk/src/java.base/share/classes/java/security/cert/X509CRL.java b/jdk/src/java.base/share/classes/java/security/cert/X509CRL.java index d23e3416272..bbff8c841f1 100644 --- a/jdk/src/java.base/share/classes/java/security/cert/X509CRL.java +++ b/jdk/src/java.base/share/classes/java/security/cert/X509CRL.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,6 +32,7 @@ import java.security.SignatureException; import java.security.Principal; import java.security.Provider; import java.security.PublicKey; +import java.security.Signature; import javax.security.auth.x500.X500Principal; import java.math.BigInteger; @@ -242,7 +243,17 @@ public abstract class X509CRL extends CRL implements X509Extension { public void verify(PublicKey key, Provider sigProvider) throws CRLException, NoSuchAlgorithmException, InvalidKeyException, SignatureException { - X509CRLImpl.verify(this, key, sigProvider); + Signature sig = (sigProvider == null) + ? Signature.getInstance(getSigAlgName()) + : Signature.getInstance(getSigAlgName(), sigProvider); + sig.initVerify(key); + + byte[] tbsCRL = getTBSCertList(); + sig.update(tbsCRL, 0, tbsCRL.length); + + if (sig.verify(getSignature()) == false) { + throw new SignatureException("Signature does not match."); + } } /** diff --git a/jdk/src/java.base/share/classes/java/security/cert/X509Certificate.java b/jdk/src/java.base/share/classes/java/security/cert/X509Certificate.java index ab4391e53d5..9690f826e67 100644 --- a/jdk/src/java.base/share/classes/java/security/cert/X509Certificate.java +++ b/jdk/src/java.base/share/classes/java/security/cert/X509Certificate.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -648,7 +648,7 @@ implements X509Extension { return X509CertImpl.getIssuerAlternativeNames(this); } - /** + /** * Verifies that this certificate was signed using the * private key that corresponds to the specified public key. * This method uses the signature verification engine @@ -674,6 +674,16 @@ implements X509Extension { public void verify(PublicKey key, Provider sigProvider) throws CertificateException, NoSuchAlgorithmException, InvalidKeyException, SignatureException { - X509CertImpl.verify(this, key, sigProvider); + Signature sig = (sigProvider == null) + ? Signature.getInstance(getSigAlgName()) + : Signature.getInstance(getSigAlgName(), sigProvider); + sig.initVerify(key); + + byte[] tbsCert = getTBSCertificate(); + sig.update(tbsCert, 0, tbsCert.length); + + if (sig.verify(getSignature()) == false) { + throw new SignatureException("Signature does not match."); + } } } diff --git a/jdk/src/java.base/share/classes/java/text/DecimalFormat.java b/jdk/src/java.base/share/classes/java/text/DecimalFormat.java index 448cf6f2d75..84f6fcbab8e 100644 --- a/jdk/src/java.base/share/classes/java/text/DecimalFormat.java +++ b/jdk/src/java.base/share/classes/java/text/DecimalFormat.java @@ -3202,13 +3202,6 @@ public class DecimalFormat extends NumberFormat { isCurrencyFormat = false; useExponentialNotation = false; - // Two variables are used to record the subrange of the pattern - // occupied by phase 1. This is used during the processing of the - // second pattern (the one representing negative numbers) to ensure - // that no deviation exists in phase 1 between the two patterns. - int phaseOneStart = 0; - int phaseOneLength = 0; - int start = 0; for (int j = 1; j >= 0 && start < pattern.length(); --j) { boolean inQuote = false; @@ -3259,9 +3252,6 @@ public class DecimalFormat extends NumberFormat { ch == groupingSeparator || ch == decimalSeparator) { phase = 1; - if (j == 1) { - phaseOneStart = pos; - } --pos; // Reprocess this character continue; } else if (ch == CURRENCY_SIGN) { @@ -3332,17 +3322,29 @@ public class DecimalFormat extends NumberFormat { break; case 1: - // Phase one must be identical in the two sub-patterns. We - // enforce this by doing a direct comparison. While - // processing the first sub-pattern, we just record its - // length. While processing the second, we compare - // characters. - if (j == 1) { - ++phaseOneLength; - } else { - if (--phaseOneLength == 0) { - phase = 2; - affix = suffix; + // The negative subpattern (j = 0) serves only to specify the + // negative prefix and suffix, so all the phase 1 characters + // e.g. digits, zeroDigit, groupingSeparator, + // decimalSeparator, exponent are ignored + if (j == 0) { + while (pos < pattern.length()) { + char negPatternChar = pattern.charAt(pos); + if (negPatternChar == digit + || negPatternChar == zeroDigit + || negPatternChar == groupingSeparator + || negPatternChar == decimalSeparator) { + ++pos; + } else if (pattern.regionMatches(pos, exponent, + 0, exponent.length())) { + pos = pos + exponent.length(); + } else { + // Not a phase 1 character, consider it as + // suffix and parse it in phase 2 + --pos; //process it again in outer loop + phase = 2; + affix = suffix; + break; + } } continue; } @@ -3396,7 +3398,6 @@ public class DecimalFormat extends NumberFormat { while (pos < pattern.length() && pattern.charAt(pos) == zeroDigit) { ++minExponentDigits; - ++phaseOneLength; ++pos; } @@ -3415,7 +3416,6 @@ public class DecimalFormat extends NumberFormat { phase = 2; affix = suffix; --pos; - --phaseOneLength; continue; } break; diff --git a/jdk/src/java.base/share/classes/java/time/chrono/AbstractChronology.java b/jdk/src/java.base/share/classes/java/time/chrono/AbstractChronology.java index c2e91d7f5f8..a32ecb78da1 100644 --- a/jdk/src/java.base/share/classes/java/time/chrono/AbstractChronology.java +++ b/jdk/src/java.base/share/classes/java/time/chrono/AbstractChronology.java @@ -126,36 +126,6 @@ import sun.util.logging.PlatformLogger; */ public abstract class AbstractChronology implements Chronology { - /** - * ChronoLocalDate order constant. - */ - static final Comparator DATE_ORDER = - (Comparator & Serializable) (date1, date2) -> { - return Long.compare(date1.toEpochDay(), date2.toEpochDay()); - }; - /** - * ChronoLocalDateTime order constant. - */ - static final Comparator> DATE_TIME_ORDER = - (Comparator> & Serializable) (dateTime1, dateTime2) -> { - int cmp = Long.compare(dateTime1.toLocalDate().toEpochDay(), dateTime2.toLocalDate().toEpochDay()); - if (cmp == 0) { - cmp = Long.compare(dateTime1.toLocalTime().toNanoOfDay(), dateTime2.toLocalTime().toNanoOfDay()); - } - return cmp; - }; - /** - * ChronoZonedDateTime order constant. - */ - static final Comparator> INSTANT_ORDER = - (Comparator> & Serializable) (dateTime1, dateTime2) -> { - int cmp = Long.compare(dateTime1.toEpochSecond(), dateTime2.toEpochSecond()); - if (cmp == 0) { - cmp = Long.compare(dateTime1.toLocalTime().getNano(), dateTime2.toLocalTime().getNano()); - } - return cmp; - }; - /** * Map of available calendars by ID. */ diff --git a/jdk/src/java.base/share/classes/java/time/chrono/ChronoLocalDate.java b/jdk/src/java.base/share/classes/java/time/chrono/ChronoLocalDate.java index 03a7a48d209..fb6938664ec 100644 --- a/jdk/src/java.base/share/classes/java/time/chrono/ChronoLocalDate.java +++ b/jdk/src/java.base/share/classes/java/time/chrono/ChronoLocalDate.java @@ -66,6 +66,7 @@ import static java.time.temporal.ChronoField.ERA; import static java.time.temporal.ChronoField.YEAR; import static java.time.temporal.ChronoUnit.DAYS; +import java.io.Serializable; import java.time.DateTimeException; import java.time.LocalDate; import java.time.LocalTime; @@ -256,7 +257,9 @@ public interface ChronoLocalDate * @see #isEqual */ static Comparator timeLineOrder() { - return AbstractChronology.DATE_ORDER; + return (Comparator & Serializable) (date1, date2) -> { + return Long.compare(date1.toEpochDay(), date2.toEpochDay()); + }; } //----------------------------------------------------------------------- diff --git a/jdk/src/java.base/share/classes/java/time/chrono/ChronoLocalDateTime.java b/jdk/src/java.base/share/classes/java/time/chrono/ChronoLocalDateTime.java index b211a52ff84..d8411961697 100644 --- a/jdk/src/java.base/share/classes/java/time/chrono/ChronoLocalDateTime.java +++ b/jdk/src/java.base/share/classes/java/time/chrono/ChronoLocalDateTime.java @@ -66,6 +66,7 @@ import static java.time.temporal.ChronoField.NANO_OF_DAY; import static java.time.temporal.ChronoUnit.FOREVER; import static java.time.temporal.ChronoUnit.NANOS; +import java.io.Serializable; import java.time.DateTimeException; import java.time.Instant; import java.time.LocalDateTime; @@ -136,7 +137,13 @@ public interface ChronoLocalDateTime * @see #isEqual */ static Comparator> timeLineOrder() { - return AbstractChronology.DATE_TIME_ORDER; + return (Comparator> & Serializable) (dateTime1, dateTime2) -> { + int cmp = Long.compare(dateTime1.toLocalDate().toEpochDay(), dateTime2.toLocalDate().toEpochDay()); + if (cmp == 0) { + cmp = Long.compare(dateTime1.toLocalTime().toNanoOfDay(), dateTime2.toLocalTime().toNanoOfDay()); + } + return cmp; + }; } //----------------------------------------------------------------------- diff --git a/jdk/src/java.base/share/classes/java/time/chrono/ChronoZonedDateTime.java b/jdk/src/java.base/share/classes/java/time/chrono/ChronoZonedDateTime.java index 8227c482831..eadcf9df958 100644 --- a/jdk/src/java.base/share/classes/java/time/chrono/ChronoZonedDateTime.java +++ b/jdk/src/java.base/share/classes/java/time/chrono/ChronoZonedDateTime.java @@ -66,6 +66,7 @@ import static java.time.temporal.ChronoField.OFFSET_SECONDS; import static java.time.temporal.ChronoUnit.FOREVER; import static java.time.temporal.ChronoUnit.NANOS; +import java.io.Serializable; import java.time.DateTimeException; import java.time.Instant; import java.time.LocalTime; @@ -137,7 +138,13 @@ public interface ChronoZonedDateTime * @see #isEqual */ static Comparator> timeLineOrder() { - return AbstractChronology.INSTANT_ORDER; + return (Comparator> & Serializable) (dateTime1, dateTime2) -> { + int cmp = Long.compare(dateTime1.toEpochSecond(), dateTime2.toEpochSecond()); + if (cmp == 0) { + cmp = Long.compare(dateTime1.toLocalTime().getNano(), dateTime2.toLocalTime().getNano()); + } + return cmp; + }; } //----------------------------------------------------------------------- diff --git a/jdk/src/java.base/share/classes/java/time/format/DateTimeTextProvider.java b/jdk/src/java.base/share/classes/java/time/format/DateTimeTextProvider.java index c2b8a411524..d3fa2161f2b 100644 --- a/jdk/src/java.base/share/classes/java/time/format/DateTimeTextProvider.java +++ b/jdk/src/java.base/share/classes/java/time/format/DateTimeTextProvider.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -112,6 +112,9 @@ class DateTimeTextProvider { } }; + // Singleton instance + private static final DateTimeTextProvider INSTANCE = new DateTimeTextProvider(); + DateTimeTextProvider() {} /** @@ -120,7 +123,7 @@ class DateTimeTextProvider { * @return the provider, not null */ static DateTimeTextProvider getInstance() { - return new DateTimeTextProvider(); + return INSTANCE; } /** diff --git a/jdk/src/java.base/share/classes/java/time/temporal/ValueRange.java b/jdk/src/java.base/share/classes/java/time/temporal/ValueRange.java index 4e5c2fdb2f6..d31cdca58f8 100644 --- a/jdk/src/java.base/share/classes/java/time/temporal/ValueRange.java +++ b/jdk/src/java.base/share/classes/java/time/temporal/ValueRange.java @@ -385,7 +385,7 @@ public final class ValueRange implements Serializable { } if (obj instanceof ValueRange) { ValueRange other = (ValueRange) obj; - return minSmallest == other.minSmallest && minLargest == other.minLargest && + return minSmallest == other.minSmallest && minLargest == other.minLargest && maxSmallest == other.maxSmallest && maxLargest == other.maxLargest; } return false; @@ -398,8 +398,9 @@ public final class ValueRange implements Serializable { */ @Override public int hashCode() { - long hash = minSmallest + minLargest << 16 + minLargest >> 48 + maxSmallest << 32 + - maxSmallest >> 32 + maxLargest << 48 + maxLargest >> 16; + long hash = minSmallest + (minLargest << 16) + (minLargest >> 48) + + (maxSmallest << 32) + (maxSmallest >> 32) + (maxLargest << 48) + + (maxLargest >> 16); return (int) (hash ^ (hash >>> 32)); } diff --git a/jdk/src/java.base/share/classes/java/util/Calendar.java b/jdk/src/java.base/share/classes/java/util/Calendar.java index 83435a90e9e..5ea332b459e 100644 --- a/jdk/src/java.base/share/classes/java/util/Calendar.java +++ b/jdk/src/java.base/share/classes/java/util/Calendar.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -2216,7 +2216,7 @@ public abstract class Calendar implements Serializable, Cloneable, Comparable= fields.length || - baseStyle < minStyle || baseStyle > maxStyle) { + baseStyle < minStyle || baseStyle > maxStyle || baseStyle == 3) { throw new IllegalArgumentException(); } if (locale == null) { diff --git a/jdk/src/java.base/share/classes/java/util/Locale.java b/jdk/src/java.base/share/classes/java/util/Locale.java index 45d13fa3db9..1ebd6cb03ab 100644 --- a/jdk/src/java.base/share/classes/java/util/Locale.java +++ b/jdk/src/java.base/share/classes/java/util/Locale.java @@ -2702,6 +2702,7 @@ public final class Locale implements Cloneable, Serializable { * @see #setExtension(char, String) */ public Builder removeUnicodeLocaleAttribute(String attribute) { + Objects.requireNonNull(attribute); try { localeBuilder.removeUnicodeLocaleAttribute(attribute); } catch (LocaleSyntaxException e) { diff --git a/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentHashMap.java b/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentHashMap.java index aec44a2d4c7..b2fe964eb03 100644 --- a/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentHashMap.java +++ b/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentHashMap.java @@ -1032,9 +1032,10 @@ public class ConcurrentHashMap extends AbstractMap } else if ((fh = f.hash) == MOVED) tab = helpTransfer(tab, f); - else if (onlyIfAbsent && fh == hash && // check first node - ((fk = f.key) == key || fk != null && key.equals(fk)) && - (fv = f.val) != null) + else if (onlyIfAbsent // check first node without acquiring lock + && fh == hash + && ((fk = f.key) == key || (fk != null && key.equals(fk))) + && (fv = f.val) != null) return fv; else { V oldVal = null; @@ -1728,9 +1729,9 @@ public class ConcurrentHashMap extends AbstractMap } else if ((fh = f.hash) == MOVED) tab = helpTransfer(tab, f); - else if (fh == h && // check first node - ((fk = f.key) == key || fk != null && key.equals(fk)) && - (fv = f.val) != null) + else if (fh == h // check first node without acquiring lock + && ((fk = f.key) == key || (fk != null && key.equals(fk))) + && (fv = f.val) != null) return fv; else { boolean added = false; @@ -3468,9 +3469,9 @@ public class ConcurrentHashMap extends AbstractMap static final class KeyIterator extends BaseIterator implements Iterator, Enumeration { - KeyIterator(Node[] tab, int index, int size, int limit, + KeyIterator(Node[] tab, int size, int index, int limit, ConcurrentHashMap map) { - super(tab, index, size, limit, map); + super(tab, size, index, limit, map); } public final K next() { @@ -3488,9 +3489,9 @@ public class ConcurrentHashMap extends AbstractMap static final class ValueIterator extends BaseIterator implements Iterator, Enumeration { - ValueIterator(Node[] tab, int index, int size, int limit, + ValueIterator(Node[] tab, int size, int index, int limit, ConcurrentHashMap map) { - super(tab, index, size, limit, map); + super(tab, size, index, limit, map); } public final V next() { @@ -3508,9 +3509,9 @@ public class ConcurrentHashMap extends AbstractMap static final class EntryIterator extends BaseIterator implements Iterator> { - EntryIterator(Node[] tab, int index, int size, int limit, + EntryIterator(Node[] tab, int size, int index, int limit, ConcurrentHashMap map) { - super(tab, index, size, limit, map); + super(tab, size, index, limit, map); } public final Map.Entry next() { diff --git a/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentSkipListMap.java b/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentSkipListMap.java index 8be87529539..8e56e9be3aa 100644 --- a/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentSkipListMap.java +++ b/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentSkipListMap.java @@ -48,7 +48,6 @@ import java.util.Comparator; import java.util.Iterator; import java.util.List; import java.util.Map; -import java.util.NavigableMap; import java.util.NavigableSet; import java.util.NoSuchElementException; import java.util.Set; diff --git a/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentSkipListSet.java b/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentSkipListSet.java index d61fb2170cc..aa0a2e98e2b 100644 --- a/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentSkipListSet.java +++ b/jdk/src/java.base/share/classes/java/util/concurrent/ConcurrentSkipListSet.java @@ -43,7 +43,6 @@ import java.util.Collections; import java.util.Comparator; import java.util.Iterator; import java.util.Map; -import java.util.NavigableMap; import java.util.NavigableSet; import java.util.Set; import java.util.SortedSet; diff --git a/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java b/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java index cd14b0057ec..1e4f6671553 100644 --- a/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java +++ b/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java @@ -2354,7 +2354,7 @@ public class ForkJoinPool extends AbstractExecutorService { checkPermission(); } - private Object newInstanceFromSystemProperty(String property) + private static Object newInstanceFromSystemProperty(String property) throws ReflectiveOperationException { String className = System.getProperty(property); return (className == null) @@ -2524,15 +2524,13 @@ public class ForkJoinPool extends AbstractExecutorService { * @throws RejectedExecutionException if the task cannot be * scheduled for execution */ + @SuppressWarnings("unchecked") public ForkJoinTask submit(Runnable task) { if (task == null) throw new NullPointerException(); - ForkJoinTask job; - if (task instanceof ForkJoinTask) // avoid re-wrap - job = (ForkJoinTask) task; - else - job = new ForkJoinTask.AdaptedRunnableAction(task); - return externalSubmit(job); + return externalSubmit((task instanceof ForkJoinTask) + ? (ForkJoinTask) task // avoid re-wrap + : new ForkJoinTask.AdaptedRunnableAction(task)); } /** diff --git a/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinWorkerThread.java b/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinWorkerThread.java index a3054b865ba..b1550f9f648 100644 --- a/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinWorkerThread.java +++ b/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinWorkerThread.java @@ -203,21 +203,19 @@ public class ForkJoinWorkerThread extends Thread { static final class InnocuousForkJoinWorkerThread extends ForkJoinWorkerThread { /** The ThreadGroup for all InnocuousForkJoinWorkerThreads */ private static final ThreadGroup innocuousThreadGroup = - java.security.AccessController.doPrivileged( - new java.security.PrivilegedAction<>() { - public ThreadGroup run() { - ThreadGroup group = Thread.currentThread().getThreadGroup(); - for (ThreadGroup p; (p = group.getParent()) != null; ) - group = p; - return new ThreadGroup(group, "InnocuousForkJoinWorkerThreadGroup"); - }}); + AccessController.doPrivileged(new PrivilegedAction<>() { + public ThreadGroup run() { + ThreadGroup group = Thread.currentThread().getThreadGroup(); + for (ThreadGroup p; (p = group.getParent()) != null; ) + group = p; + return new ThreadGroup( + group, "InnocuousForkJoinWorkerThreadGroup"); + }}); /** An AccessControlContext supporting no privileges */ private static final AccessControlContext INNOCUOUS_ACC = new AccessControlContext( - new ProtectionDomain[] { - new ProtectionDomain(null, null) - }); + new ProtectionDomain[] { new ProtectionDomain(null, null) }); InnocuousForkJoinWorkerThread(ForkJoinPool pool) { super(pool, diff --git a/jdk/src/java.base/share/classes/java/util/concurrent/locks/ReentrantReadWriteLock.java b/jdk/src/java.base/share/classes/java/util/concurrent/locks/ReentrantReadWriteLock.java index ab43971e84d..4f093bf5631 100644 --- a/jdk/src/java.base/share/classes/java/util/concurrent/locks/ReentrantReadWriteLock.java +++ b/jdk/src/java.base/share/classes/java/util/concurrent/locks/ReentrantReadWriteLock.java @@ -444,7 +444,7 @@ public class ReentrantReadWriteLock } } - private IllegalMonitorStateException unmatchedUnlockException() { + private static IllegalMonitorStateException unmatchedUnlockException() { return new IllegalMonitorStateException( "attempt to unlock read lock, not locked by current thread"); } diff --git a/jdk/src/java.base/share/classes/java/util/stream/FindOps.java b/jdk/src/java.base/share/classes/java/util/stream/FindOps.java index 45e1d697de0..299cebec571 100644 --- a/jdk/src/java.base/share/classes/java/util/stream/FindOps.java +++ b/jdk/src/java.base/share/classes/java/util/stream/FindOps.java @@ -54,9 +54,10 @@ final class FindOps { * first element in the encounter order * @return a {@code TerminalOp} implementing the find operation */ + @SuppressWarnings("unchecked") public static TerminalOp> makeRef(boolean mustFindFirst) { - return new FindOp<>(mustFindFirst, StreamShape.REFERENCE, Optional.empty(), - Optional::isPresent, FindSink.OfRef::new); + return (TerminalOp>) + (mustFindFirst ? FindSink.OfRef.OP_FIND_FIRST : FindSink.OfRef.OP_FIND_ANY); } /** @@ -67,8 +68,7 @@ final class FindOps { * @return a {@code TerminalOp} implementing the find operation */ public static TerminalOp makeInt(boolean mustFindFirst) { - return new FindOp<>(mustFindFirst, StreamShape.INT_VALUE, OptionalInt.empty(), - OptionalInt::isPresent, FindSink.OfInt::new); + return mustFindFirst ? FindSink.OfInt.OP_FIND_FIRST : FindSink.OfInt.OP_FIND_ANY; } /** @@ -79,8 +79,7 @@ final class FindOps { * @return a {@code TerminalOp} implementing the find operation */ public static TerminalOp makeLong(boolean mustFindFirst) { - return new FindOp<>(mustFindFirst, StreamShape.LONG_VALUE, OptionalLong.empty(), - OptionalLong::isPresent, FindSink.OfLong::new); + return mustFindFirst ? FindSink.OfLong.OP_FIND_FIRST : FindSink.OfLong.OP_FIND_ANY; } /** @@ -91,8 +90,7 @@ final class FindOps { * @return a {@code TerminalOp} implementing the find operation */ public static TerminalOp makeDouble(boolean mustFindFirst) { - return new FindOp<>(mustFindFirst, StreamShape.DOUBLE_VALUE, OptionalDouble.empty(), - OptionalDouble::isPresent, FindSink.OfDouble::new); + return mustFindFirst ? FindSink.OfDouble.OP_FIND_FIRST : FindSink.OfDouble.OP_FIND_ANY; } /** @@ -195,6 +193,14 @@ final class FindOps { public Optional get() { return hasValue ? Optional.of(value) : null; } + + static final TerminalOp OP_FIND_FIRST = new FindOp<>(true, + StreamShape.REFERENCE, Optional.empty(), + Optional::isPresent, FindSink.OfRef::new); + + static final TerminalOp OP_FIND_ANY = new FindOp<>(false, + StreamShape.REFERENCE, Optional.empty(), + Optional::isPresent, FindSink.OfRef::new); } /** Specialization of {@code FindSink} for int streams */ @@ -210,6 +216,13 @@ final class FindOps { public OptionalInt get() { return hasValue ? OptionalInt.of(value) : null; } + + static final TerminalOp OP_FIND_FIRST = new FindOp<>(true, + StreamShape.INT_VALUE, OptionalInt.empty(), + OptionalInt::isPresent, FindSink.OfInt::new); + static final TerminalOp OP_FIND_ANY = new FindOp<>(false, + StreamShape.INT_VALUE, OptionalInt.empty(), + OptionalInt::isPresent, FindSink.OfInt::new); } /** Specialization of {@code FindSink} for long streams */ @@ -225,6 +238,13 @@ final class FindOps { public OptionalLong get() { return hasValue ? OptionalLong.of(value) : null; } + + static final TerminalOp OP_FIND_FIRST = new FindOp<>(true, + StreamShape.LONG_VALUE, OptionalLong.empty(), + OptionalLong::isPresent, FindSink.OfLong::new); + static final TerminalOp OP_FIND_ANY = new FindOp<>(false, + StreamShape.LONG_VALUE, OptionalLong.empty(), + OptionalLong::isPresent, FindSink.OfLong::new); } /** Specialization of {@code FindSink} for double streams */ @@ -240,6 +260,13 @@ final class FindOps { public OptionalDouble get() { return hasValue ? OptionalDouble.of(value) : null; } + + static final TerminalOp OP_FIND_FIRST = new FindOp<>(true, + StreamShape.DOUBLE_VALUE, OptionalDouble.empty(), + OptionalDouble::isPresent, FindSink.OfDouble::new); + static final TerminalOp OP_FIND_ANY = new FindOp<>(false, + StreamShape.DOUBLE_VALUE, OptionalDouble.empty(), + OptionalDouble::isPresent, FindSink.OfDouble::new); } } diff --git a/jdk/src/java.base/share/classes/jdk/internal/logger/SimpleConsoleLogger.java b/jdk/src/java.base/share/classes/jdk/internal/logger/SimpleConsoleLogger.java index fb0ffe64426..b6e42468f80 100644 --- a/jdk/src/java.base/share/classes/jdk/internal/logger/SimpleConsoleLogger.java +++ b/jdk/src/java.base/share/classes/jdk/internal/logger/SimpleConsoleLogger.java @@ -33,6 +33,7 @@ import java.security.AccessController; import java.security.PrivilegedAction; import java.time.ZonedDateTime; import java.util.Optional; +import java.util.MissingResourceException; import java.util.ResourceBundle; import java.util.function.Function; import java.lang.System.Logger; @@ -106,7 +107,7 @@ public class SimpleConsoleLogger extends LoggerConfiguration public final void log(Level level, ResourceBundle bundle, String key, Throwable thrown) { if (isLoggable(level)) { if (bundle != null) { - key = bundle.getString(key); + key = getString(bundle, key); } publish(getCallerInfo(), logLevel(level), key, thrown); } @@ -116,7 +117,7 @@ public class SimpleConsoleLogger extends LoggerConfiguration public final void log(Level level, ResourceBundle bundle, String format, Object... params) { if (isLoggable(level)) { if (bundle != null) { - format = bundle.getString(format); + format = getString(bundle, format); } publish(getCallerInfo(), logLevel(level), format, params); } @@ -364,7 +365,7 @@ public class SimpleConsoleLogger extends LoggerConfiguration public final void logrb(PlatformLogger.Level level, String sourceClass, String sourceMethod, ResourceBundle bundle, String key, Object... params) { if (isLoggable(level)) { - String msg = bundle == null ? key : bundle.getString(key); + String msg = bundle == null ? key : getString(bundle, key); publish(getCallerInfo(sourceClass, sourceMethod), logLevel(level), msg, params); } } @@ -373,7 +374,7 @@ public class SimpleConsoleLogger extends LoggerConfiguration public final void logrb(PlatformLogger.Level level, String sourceClass, String sourceMethod, ResourceBundle bundle, String key, Throwable thrown) { if (isLoggable(level)) { - String msg = bundle == null ? key : bundle.getString(key); + String msg = bundle == null ? key : getString(bundle, key); publish(getCallerInfo(sourceClass, sourceMethod), logLevel(level), msg, thrown); } } @@ -382,7 +383,7 @@ public class SimpleConsoleLogger extends LoggerConfiguration public final void logrb(PlatformLogger.Level level, ResourceBundle bundle, String key, Object... params) { if (isLoggable(level)) { - String msg = bundle == null ? key : bundle.getString(key); + String msg = bundle == null ? key : getString(bundle,key); publish(getCallerInfo(), logLevel(level), msg, params); } } @@ -391,11 +392,23 @@ public class SimpleConsoleLogger extends LoggerConfiguration public final void logrb(PlatformLogger.Level level, ResourceBundle bundle, String key, Throwable thrown) { if (isLoggable(level)) { - String msg = bundle == null ? key : bundle.getString(key); + String msg = bundle == null ? key : getString(bundle,key); publish(getCallerInfo(), logLevel(level), msg, thrown); } } + static String getString(ResourceBundle bundle, String key) { + if (bundle == null || key == null) return key; + try { + return bundle.getString(key); + } catch (MissingResourceException x) { + // Emulate what java.util.logging Formatters do + // We don't want unchecked exception to propagate up to + // the caller's code. + return key; + } + } + static final class Formatting { // The default simple log format string. // Used both by SimpleConsoleLogger when java.logging is not present, diff --git a/jdk/src/java.base/share/classes/sun/invoke/util/VerifyAccess.java b/jdk/src/java.base/share/classes/sun/invoke/util/VerifyAccess.java index d0e2a98995a..758d59aa0c0 100644 --- a/jdk/src/java.base/share/classes/sun/invoke/util/VerifyAccess.java +++ b/jdk/src/java.base/share/classes/sun/invoke/util/VerifyAccess.java @@ -296,10 +296,13 @@ public class VerifyAccess { * @param refc the class attempting to make the reference */ public static boolean isTypeVisible(java.lang.invoke.MethodType type, Class refc) { - for (int n = -1, max = type.parameterCount(); n < max; n++) { - Class ptype = (n < 0 ? type.returnType() : type.parameterType(n)); - if (!isTypeVisible(ptype, refc)) + if (!isTypeVisible(type.returnType(), refc)) { + return false; + } + for (int n = 0, max = type.parameterCount(); n < max; n++) { + if (!isTypeVisible(type.parameterType(n), refc)) { return false; + } } return true; } diff --git a/jdk/src/java.base/share/classes/sun/invoke/util/Wrapper.java b/jdk/src/java.base/share/classes/sun/invoke/util/Wrapper.java index f22eda0ea45..9f1f31218b4 100644 --- a/jdk/src/java.base/share/classes/sun/invoke/util/Wrapper.java +++ b/jdk/src/java.base/share/classes/sun/invoke/util/Wrapper.java @@ -26,20 +26,20 @@ package sun.invoke.util; public enum Wrapper { - // wrapperType primitiveType char emptyArray format - BOOLEAN( Boolean.class, boolean.class, 'Z', new boolean[0], Format.unsigned( 1)), + // wrapperType simple primitiveType simple char emptyArray format + BOOLEAN( Boolean.class, "Boolean", boolean.class, "boolean", 'Z', new boolean[0], Format.unsigned( 1)), // These must be in the order defined for widening primitive conversions in JLS 5.1.2 // Avoid boxing integral types here to defer initialization of internal caches - BYTE ( Byte.class, byte.class, 'B', new byte[0], Format.signed( 8)), - SHORT ( Short.class, short.class, 'S', new short[0], Format.signed( 16)), - CHAR (Character.class, char.class, 'C', new char[0], Format.unsigned(16)), - INT ( Integer.class, int.class, 'I', new int[0], Format.signed( 32)), - LONG ( Long.class, long.class, 'J', new long[0], Format.signed( 64)), - FLOAT ( Float.class, float.class, 'F', new float[0], Format.floating(32)), - DOUBLE ( Double.class, double.class, 'D', new double[0], Format.floating(64)), - OBJECT ( Object.class, Object.class, 'L', new Object[0], Format.other( 1)), + BYTE ( Byte.class, "Byte", byte.class, "byte", 'B', new byte[0], Format.signed( 8)), + SHORT ( Short.class, "Short", short.class, "short", 'S', new short[0], Format.signed( 16)), + CHAR (Character.class, "Character", char.class, "char", 'C', new char[0], Format.unsigned(16)), + INT ( Integer.class, "Integer", int.class, "int", 'I', new int[0], Format.signed( 32)), + LONG ( Long.class, "Long", long.class, "long", 'J', new long[0], Format.signed( 64)), + FLOAT ( Float.class, "Float", float.class, "float", 'F', new float[0], Format.floating(32)), + DOUBLE ( Double.class, "Double", double.class, "double", 'D', new double[0], Format.floating(64)), + OBJECT ( Object.class, "Object", Object.class, "Object", 'L', new Object[0], Format.other( 1)), // VOID must be the last type, since it is "assignable" from any other type: - VOID ( Void.class, void.class, 'V', null, Format.other( 0)), + VOID ( Void.class, "Void", void.class, "void", 'V', null, Format.other( 0)), ; public static final int COUNT = 10; @@ -52,14 +52,14 @@ public enum Wrapper { private final String wrapperSimpleName; private final String primitiveSimpleName; - private Wrapper(Class wtype, Class ptype, char tchar, Object emptyArray, int format) { + private Wrapper(Class wtype, String wtypeName, Class ptype, String ptypeName, char tchar, Object emptyArray, int format) { this.wrapperType = wtype; this.primitiveType = ptype; this.basicTypeChar = tchar; this.emptyArray = emptyArray; this.format = format; - this.wrapperSimpleName = wtype.getSimpleName(); - this.primitiveSimpleName = ptype.getSimpleName(); + this.wrapperSimpleName = wtypeName; + this.primitiveSimpleName = ptypeName; } /** For debugging, give the details of this wrapper. */ @@ -518,12 +518,6 @@ public enum Wrapper { * If the target type is a primitive, change it to a wrapper. */ static Class forceType(Class type, Class exampleType) { - boolean z = (type == exampleType || - type.isPrimitive() && forPrimitiveType(type) == findWrapperType(exampleType) || - exampleType.isPrimitive() && forPrimitiveType(exampleType) == findWrapperType(type) || - type == Object.class && !exampleType.isPrimitive()); - if (!z) - System.out.println(type+" <= "+exampleType); assert(type == exampleType || type.isPrimitive() && forPrimitiveType(type) == findWrapperType(exampleType) || exampleType.isPrimitive() && forPrimitiveType(exampleType) == findWrapperType(type) || diff --git a/jdk/src/java.base/share/classes/sun/launcher/LauncherHelper.java b/jdk/src/java.base/share/classes/sun/launcher/LauncherHelper.java index c547836bc1d..ffff21dfd24 100644 --- a/jdk/src/java.base/share/classes/sun/launcher/LauncherHelper.java +++ b/jdk/src/java.base/share/classes/sun/launcher/LauncherHelper.java @@ -363,10 +363,6 @@ public final class LauncherHelper { static void initHelpMessage(String progname) { outBuf = outBuf.append(getLocalizedMessage("java.launcher.opt.header", (progname == null) ? "java" : progname )); - outBuf = outBuf.append(getLocalizedMessage("java.launcher.opt.datamodel", - 32)); - outBuf = outBuf.append(getLocalizedMessage("java.launcher.opt.datamodel", - 64)); } /** diff --git a/jdk/src/java.base/share/classes/sun/launcher/resources/launcher.properties b/jdk/src/java.base/share/classes/sun/launcher/resources/launcher.properties index 40b549b9f75..a347a0ac0d2 100644 --- a/jdk/src/java.base/share/classes/sun/launcher/resources/launcher.properties +++ b/jdk/src/java.base/share/classes/sun/launcher/resources/launcher.properties @@ -34,7 +34,6 @@ java.launcher.opt.header = Usage: {0} [options] [args...]\n\ \ / are passed as the arguments to main class.\n\n\ \ where options include:\n\n -java.launcher.opt.datamodel =\ -d{0}\t Deprecated, will be removed in a future release\n java.launcher.opt.vmselect =\ {0}\t to select the "{1}" VM\n java.launcher.opt.hotspot =\ {0}\t is a synonym for the "{1}" VM [deprecated]\n diff --git a/jdk/src/java.base/share/classes/sun/security/provider/X509Factory.java b/jdk/src/java.base/share/classes/sun/security/provider/X509Factory.java index 1789dd62cf5..34a3c8e1ac4 100644 --- a/jdk/src/java.base/share/classes/sun/security/provider/X509Factory.java +++ b/jdk/src/java.base/share/classes/sun/security/provider/X509Factory.java @@ -553,8 +553,7 @@ public class X509Factory extends CertificateFactorySpi { return bout.toByteArray(); } else { // Read BASE64 encoded data, might skip info at the beginning - char[] data = new char[2048]; - int pos = 0; + ByteArrayOutputStream data = new ByteArrayOutputStream(); // Step 1: Read until header is found int hyphen = (c=='-') ? 1: 0; // count of consequent hyphens @@ -598,7 +597,10 @@ public class X509Factory extends CertificateFactorySpi { end = '\n'; } else { end = '\r'; - data[pos++] = (char)next; + // Skip all white space chars + if (next != 9 && next != 10 && next != 13 && next != 32) { + data.write(next); + } } break; } @@ -612,9 +614,9 @@ public class X509Factory extends CertificateFactorySpi { throw new IOException("Incomplete data"); } if (next != '-') { - data[pos++] = (char)next; - if (pos >= data.length) { - data = Arrays.copyOf(data, data.length+1024); + // Skip all white space chars + if (next != 9 && next != 10 && next != 13 && next != 32) { + data.write(next); } } else { break; @@ -635,7 +637,11 @@ public class X509Factory extends CertificateFactorySpi { checkHeaderFooter(header.toString(), footer.toString()); - return Pem.decode(new String(data, 0, pos)); + try { + return Base64.getDecoder().decode(data.toByteArray()); + } catch (IllegalArgumentException e) { + throw new IOException(e); + } } } diff --git a/jdk/src/java.base/share/classes/sun/security/provider/certpath/AdaptableX509CertSelector.java b/jdk/src/java.base/share/classes/sun/security/provider/certpath/AdaptableX509CertSelector.java index 0ad5387b324..dd86415fbcb 100644 --- a/jdk/src/java.base/share/classes/sun/security/provider/certpath/AdaptableX509CertSelector.java +++ b/jdk/src/java.base/share/classes/sun/security/provider/certpath/AdaptableX509CertSelector.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -214,7 +214,7 @@ class AdaptableX509CertSelector extends X509CertSelector { try { byte[] extVal = xcert.getExtensionValue("2.5.29.14"); if (extVal == null) { - if (debug != null) { + if (debug != null && Debug.isVerbose()) { debug.println("AdaptableX509CertSelector.match: " + "no subject key ID extension. Subject: " + xcert.getSubjectX500Principal()); @@ -225,7 +225,7 @@ class AdaptableX509CertSelector extends X509CertSelector { byte[] certSubjectKeyID = in.getOctetString(); if (certSubjectKeyID == null || !Arrays.equals(ski, certSubjectKeyID)) { - if (debug != null) { + if (debug != null && Debug.isVerbose()) { debug.println("AdaptableX509CertSelector.match: " + "subject key IDs don't match. " + "Expected: " + Arrays.toString(ski) + " " @@ -234,7 +234,7 @@ class AdaptableX509CertSelector extends X509CertSelector { return false; } } catch (IOException ex) { - if (debug != null) { + if (debug != null && Debug.isVerbose()) { debug.println("AdaptableX509CertSelector.match: " + "exception in subject key ID check"); } diff --git a/jdk/src/java.base/share/classes/sun/security/provider/certpath/PKIXCertPathValidator.java b/jdk/src/java.base/share/classes/sun/security/provider/certpath/PKIXCertPathValidator.java index 53ae439baf3..c65ebf03986 100644 --- a/jdk/src/java.base/share/classes/sun/security/provider/certpath/PKIXCertPathValidator.java +++ b/jdk/src/java.base/share/classes/sun/security/provider/certpath/PKIXCertPathValidator.java @@ -117,7 +117,7 @@ public final class PKIXCertPathValidator extends CertPathValidatorSpi { // if this trust anchor is not worth trying, // we move on to the next one if (selector != null && !selector.match(trustedCert)) { - if (debug != null) { + if (debug != null && Debug.isVerbose()) { debug.println("NO - don't try this trustedCert"); } continue; diff --git a/jdk/src/java.base/share/classes/sun/security/provider/certpath/RevocationChecker.java b/jdk/src/java.base/share/classes/sun/security/provider/certpath/RevocationChecker.java index 9b443a733dd..468cad0022c 100644 --- a/jdk/src/java.base/share/classes/sun/security/provider/certpath/RevocationChecker.java +++ b/jdk/src/java.base/share/classes/sun/security/provider/certpath/RevocationChecker.java @@ -986,9 +986,7 @@ class RevocationChecker extends PKIXRevocationChecker { // any way to convey them back to the application. // That's the default, so no need to write code. builderParams.setDate(params.date()); - // CertPathCheckers need to be cloned to start from fresh state - builderParams.setCertPathCheckers( - params.getPKIXParameters().getCertPathCheckers()); + builderParams.setCertPathCheckers(params.certPathCheckers()); builderParams.setSigProvider(params.sigProvider()); // Skip revocation during this build to detect circular @@ -1116,15 +1114,6 @@ class RevocationChecker extends PKIXRevocationChecker { } } - @Override - public RevocationChecker clone() { - RevocationChecker copy = (RevocationChecker)super.clone(); - // we don't deep-copy the exceptions, but that is ok because they - // are never modified after they are instantiated - copy.softFailExceptions = new LinkedList<>(softFailExceptions); - return copy; - } - /* * This inner class extends the X509CertSelector to add an additional * check to make sure the subject public key isn't on a particular list. diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/CipherSuite.java b/jdk/src/java.base/share/classes/sun/security/ssl/CipherSuite.java index 2ffb5f32b4b..c8080ca9a67 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/CipherSuite.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/CipherSuite.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -44,6 +44,7 @@ import static sun.security.ssl.CipherSuite.CipherType.*; import static sun.security.ssl.CipherSuite.MacAlg.*; import static sun.security.ssl.CipherSuite.BulkCipher.*; import static sun.security.ssl.JsseJce.*; +import static sun.security.ssl.NamedGroupType.*; /** * An SSL/TLS CipherSuite. Constants for the standard key exchange, cipher, @@ -376,38 +377,38 @@ final class CipherSuite implements Comparable { static enum KeyExchange { // key exchange algorithms - K_NULL ("NULL", false, false), - K_RSA ("RSA", true, false), - K_RSA_EXPORT ("RSA_EXPORT", true, false), - K_DH_RSA ("DH_RSA", false, false), - K_DH_DSS ("DH_DSS", false, false), - K_DHE_DSS ("DHE_DSS", true, false), - K_DHE_RSA ("DHE_RSA", true, false), - K_DH_ANON ("DH_anon", true, false), + K_NULL ("NULL", false, NAMED_GROUP_NONE), + K_RSA ("RSA", true, NAMED_GROUP_NONE), + K_RSA_EXPORT ("RSA_EXPORT", true, NAMED_GROUP_NONE), + K_DH_RSA ("DH_RSA", false, NAMED_GROUP_NONE), + K_DH_DSS ("DH_DSS", false, NAMED_GROUP_NONE), + K_DHE_DSS ("DHE_DSS", true, NAMED_GROUP_FFDHE), + K_DHE_RSA ("DHE_RSA", true, NAMED_GROUP_FFDHE), + K_DH_ANON ("DH_anon", true, NAMED_GROUP_FFDHE), - K_ECDH_ECDSA ("ECDH_ECDSA", ALLOW_ECC, true), - K_ECDH_RSA ("ECDH_RSA", ALLOW_ECC, true), - K_ECDHE_ECDSA("ECDHE_ECDSA", ALLOW_ECC, true), - K_ECDHE_RSA ("ECDHE_RSA", ALLOW_ECC, true), - K_ECDH_ANON ("ECDH_anon", ALLOW_ECC, true), + K_ECDH_ECDSA ("ECDH_ECDSA", ALLOW_ECC, NAMED_GROUP_ECDHE), + K_ECDH_RSA ("ECDH_RSA", ALLOW_ECC, NAMED_GROUP_ECDHE), + K_ECDHE_ECDSA("ECDHE_ECDSA", ALLOW_ECC, NAMED_GROUP_ECDHE), + K_ECDHE_RSA ("ECDHE_RSA", ALLOW_ECC, NAMED_GROUP_ECDHE), + K_ECDH_ANON ("ECDH_anon", ALLOW_ECC, NAMED_GROUP_ECDHE), // Kerberos cipher suites - K_KRB5 ("KRB5", true, false), - K_KRB5_EXPORT("KRB5_EXPORT", true, false), + K_KRB5 ("KRB5", true, NAMED_GROUP_NONE), + K_KRB5_EXPORT("KRB5_EXPORT", true, NAMED_GROUP_NONE), // renegotiation protection request signaling cipher suite - K_SCSV ("SCSV", true, false); + K_SCSV ("SCSV", true, NAMED_GROUP_NONE); // name of the key exchange algorithm, e.g. DHE_DSS final String name; final boolean allowed; - final boolean isEC; + final NamedGroupType groupType; private final boolean alwaysAvailable; - KeyExchange(String name, boolean allowed, boolean isEC) { + KeyExchange(String name, boolean allowed, NamedGroupType groupType) { this.name = name; this.allowed = allowed; - this.isEC = isEC; + this.groupType = groupType; this.alwaysAvailable = allowed && (!name.startsWith("EC")) && (!name.startsWith("KRB")); } @@ -417,7 +418,7 @@ final class CipherSuite implements Comparable { return true; } - if (isEC) { + if (groupType == NAMED_GROUP_ECDHE) { return (allowed && JsseJce.isEcAvailable()); } else if (name.startsWith("KRB")) { return (allowed && JsseJce.isKerberosAvailable()); diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/CipherSuiteList.java b/jdk/src/java.base/share/classes/sun/security/ssl/CipherSuiteList.java index a114f4acb83..025f40bda61 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/CipherSuiteList.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/CipherSuiteList.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,6 +30,7 @@ import java.io.*; import java.util.*; import javax.net.ssl.SSLException; +import static sun.security.ssl.NamedGroupType.*; /** * A list of CipherSuites. Also maintains the lists of supported and @@ -42,15 +43,16 @@ final class CipherSuiteList { private final Collection cipherSuites; private String[] suiteNames; - - // flag indicating whether this list contains any ECC ciphersuites. - // null if not yet checked. - private volatile Boolean containsEC; + private final EnumSet groupsTypes = + EnumSet.noneOf(NamedGroupType.class); // for use by buildAvailableCache() and // Handshaker.getKickstartMessage() only CipherSuiteList(Collection cipherSuites) { this.cipherSuites = cipherSuites; + for (CipherSuite suite : cipherSuites) { + updateGroupTypes(suite); + } } /** @@ -59,6 +61,7 @@ final class CipherSuiteList { CipherSuiteList(CipherSuite suite) { cipherSuites = new ArrayList(1); cipherSuites.add(suite); + updateGroupTypes(suite); } /** @@ -82,6 +85,7 @@ final class CipherSuiteList { + suiteName + " with currently installed providers"); } cipherSuites.add(suite); + updateGroupTypes(suite); } } @@ -97,7 +101,20 @@ final class CipherSuiteList { } cipherSuites = new ArrayList(bytes.length >> 1); for (int i = 0; i < bytes.length; i += 2) { - cipherSuites.add(CipherSuite.valueOf(bytes[i], bytes[i+1])); + CipherSuite suite = CipherSuite.valueOf(bytes[i], bytes[i+1]); + cipherSuites.add(suite); + updateGroupTypes(suite); + } + } + + // Please don't use this method except constructors. + private void updateGroupTypes(CipherSuite cipherSuite) { + if (cipherSuite.keyExchange != null && (!cipherSuite.exportable)) { + NamedGroupType groupType = cipherSuite.keyExchange.groupType; + if ((groupType != NAMED_GROUP_NONE) && + (!groupsTypes.contains(groupType))) { + groupsTypes.add(groupType); + } } } @@ -108,20 +125,9 @@ final class CipherSuiteList { return cipherSuites.contains(suite); } - // Return whether this list contains any ECC ciphersuites - boolean containsEC() { - if (containsEC == null) { - for (CipherSuite c : cipherSuites) { - if (c.keyExchange.isEC) { - containsEC = true; - return true; - } - } - - containsEC = false; - } - - return containsEC; + // Return whether this list contains cipher suites of a named group type. + boolean contains(NamedGroupType groupType) { + return groupsTypes.contains(groupType); } /** diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/ClientHandshaker.java b/jdk/src/java.base/share/classes/sun/security/ssl/ClientHandshaker.java index b95de5ecde2..1d6c74eab3a 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/ClientHandshaker.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/ClientHandshaker.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -148,6 +148,10 @@ final class ClientHandshaker extends Handshaker { private static final boolean enableMFLExtension = Debug.getBooleanProperty("jsse.enableMFLExtension", false); + // To switch off the supported_groups extension for DHE cipher suite. + private static final boolean enableFFDHE = + Debug.getBooleanProperty("jsse.enableFFDHE", true); + // Whether an ALPN extension was sent in the ClientHello private boolean alpnActive = false; @@ -767,13 +771,15 @@ final class ClientHandshaker extends Handshaker { fatalSE(Alerts.alert_unexpected_message, "Server set " + type + " extension when not requested by client"); } - } else if ((type != ExtensionType.EXT_ELLIPTIC_CURVES) + } else if ((type != ExtensionType.EXT_SUPPORTED_GROUPS) && (type != ExtensionType.EXT_EC_POINT_FORMATS) && (type != ExtensionType.EXT_SERVER_NAME) && (type != ExtensionType.EXT_ALPN) && (type != ExtensionType.EXT_RENEGOTIATION_INFO) && (type != ExtensionType.EXT_STATUS_REQUEST) && (type != ExtensionType.EXT_STATUS_REQUEST_V2)) { + // Note: Better to check client requested extensions rather + // than all supported extensions. fatalSE(Alerts.alert_unsupported_extension, "Server sent an unsupported extension: " + type); } @@ -823,6 +829,17 @@ final class ClientHandshaker extends Handshaker { * our own D-H algorithm object so we can defer key calculations * until after we've sent the client key exchange message (which * gives client and server some useful parallelism). + * + * Note per section 3 of RFC 7919, if the server is not compatible with + * FFDHE specification, the client MAY decide to continue the connection + * if the selected DHE group is acceptable under local policy, or it MAY + * decide to terminate the connection with a fatal insufficient_security + * (71) alert. The algorithm constraints mechanism is JDK local policy + * used for additional DHE parameters checking. So this implementation + * does not check the server compatibility and just pass to the local + * algorithm constraints checking. The client will continue the + * connection if the server selected DHE group is acceptable by the + * specified algorithm constraints. */ private void serverKeyExchange(DH_ServerKeyExchange mesg) throws IOException { @@ -1495,14 +1512,17 @@ final class ClientHandshaker extends Handshaker { sslContext.getSecureRandom(), maxProtocolVersion, sessionId, cipherSuites, isDTLS); - // add elliptic curves and point format extensions - if (cipherSuites.containsEC()) { - EllipticCurvesExtension ece = - EllipticCurvesExtension.createExtension(algorithmConstraints); - if (ece != null) { - clientHelloMessage.extensions.add(ece); + // Add named groups extension for ECDHE and FFDHE if necessary. + SupportedGroupsExtension sge = + SupportedGroupsExtension.createExtension( + algorithmConstraints, + cipherSuites, enableFFDHE); + if (sge != null) { + clientHelloMessage.extensions.add(sge); + // Add elliptic point format extensions + if (cipherSuites.contains(NamedGroupType.NAMED_GROUP_ECDHE)) { clientHelloMessage.extensions.add( - EllipticPointFormatsExtension.DEFAULT); + EllipticPointFormatsExtension.DEFAULT); } } diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/DHCrypt.java b/jdk/src/java.base/share/classes/sun/security/ssl/DHCrypt.java index f7dadcaf66d..a9d4c2a37e4 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/DHCrypt.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/DHCrypt.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,14 +26,8 @@ package sun.security.ssl; -import java.util.Map; -import java.util.HashMap; -import java.util.Collections; -import java.util.regex.Pattern; -import java.util.regex.Matcher; import java.math.BigInteger; import java.security.*; -import java.io.IOException; import javax.net.ssl.SSLHandshakeException; import javax.crypto.SecretKey; import javax.crypto.KeyAgreement; @@ -101,7 +95,7 @@ final class DHCrypt { */ DHCrypt(int keyLength, SecureRandom random) { this(keyLength, - ParametersHolder.definedParams.get(keyLength), random); + PredefinedDHParameterSpecs.definedParams.get(keyLength), random); } /** @@ -115,6 +109,14 @@ final class DHCrypt { new DHParameterSpec(modulus, base), random); } + /** + * Generate a Diffie-Hellman keypair using the named group. + */ + DHCrypt(NamedGroup namedGroup, SecureRandom random) { + this(-1, // The length (-1) is not used in the implementation. + SupportedGroupsExtension.getDHParameterSpec(namedGroup), random); + } + /** * Generate a Diffie-Hellman keypair using the specified size and * parameters. @@ -272,266 +274,5 @@ final class DHCrypt { return null; } - - // lazy initialization holder class idiom for static default parameters - // - // See Effective Java Second Edition: Item 71. - private static class ParametersHolder { - private final static boolean debugIsOn = - (Debug.getInstance("ssl") != null) && Debug.isOn("sslctx"); - - // - // Default DH ephemeral parameters - // - private static final BigInteger p512 = new BigInteger( // generated - "D87780E15FF50B4ABBE89870188B049406B5BEA98AB23A02" + - "41D88EA75B7755E669C08093D3F0CA7FC3A5A25CF067DCB9" + - "A43DD89D1D90921C6328884461E0B6D3", 16); - private static final BigInteger p768 = new BigInteger( // RFC 2409 - "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD1" + - "29024E088A67CC74020BBEA63B139B22514A08798E3404DD" + - "EF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245" + - "E485B576625E7EC6F44C42E9A63A3620FFFFFFFFFFFFFFFF", 16); - - private static final BigInteger p1024 = new BigInteger( // RFC 2409 - "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD1" + - "29024E088A67CC74020BBEA63B139B22514A08798E3404DD" + - "EF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245" + - "E485B576625E7EC6F44C42E9A637ED6B0BFF5CB6F406B7ED" + - "EE386BFB5A899FA5AE9F24117C4B1FE649286651ECE65381" + - "FFFFFFFFFFFFFFFF", 16); - private static final BigInteger p1536 = new BigInteger( // RFC 3526 - "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD1" + - "29024E088A67CC74020BBEA63B139B22514A08798E3404DD" + - "EF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245" + - "E485B576625E7EC6F44C42E9A637ED6B0BFF5CB6F406B7ED" + - "EE386BFB5A899FA5AE9F24117C4B1FE649286651ECE45B3D" + - "C2007CB8A163BF0598DA48361C55D39A69163FA8FD24CF5F" + - "83655D23DCA3AD961C62F356208552BB9ED529077096966D" + - "670C354E4ABC9804F1746C08CA237327FFFFFFFFFFFFFFFF", 16); - private static final BigInteger p2048 = new BigInteger( // TLS FFDHE - "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + - "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + - "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + - "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + - "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + - "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + - "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + - "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + - "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + - "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + - "886B423861285C97FFFFFFFFFFFFFFFF", 16); - private static final BigInteger p3072 = new BigInteger( // TLS FFDHE - "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + - "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + - "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + - "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + - "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + - "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + - "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + - "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + - "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + - "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + - "886B4238611FCFDCDE355B3B6519035BBC34F4DEF99C0238" + - "61B46FC9D6E6C9077AD91D2691F7F7EE598CB0FAC186D91C" + - "AEFE130985139270B4130C93BC437944F4FD4452E2D74DD3" + - "64F2E21E71F54BFF5CAE82AB9C9DF69EE86D2BC522363A0D" + - "ABC521979B0DEADA1DBF9A42D5C4484E0ABCD06BFA53DDEF" + - "3C1B20EE3FD59D7C25E41D2B66C62E37FFFFFFFFFFFFFFFF", 16); - private static final BigInteger p4096 = new BigInteger( // TLS FFDHE - "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + - "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + - "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + - "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + - "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + - "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + - "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + - "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + - "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + - "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + - "886B4238611FCFDCDE355B3B6519035BBC34F4DEF99C0238" + - "61B46FC9D6E6C9077AD91D2691F7F7EE598CB0FAC186D91C" + - "AEFE130985139270B4130C93BC437944F4FD4452E2D74DD3" + - "64F2E21E71F54BFF5CAE82AB9C9DF69EE86D2BC522363A0D" + - "ABC521979B0DEADA1DBF9A42D5C4484E0ABCD06BFA53DDEF" + - "3C1B20EE3FD59D7C25E41D2B669E1EF16E6F52C3164DF4FB" + - "7930E9E4E58857B6AC7D5F42D69F6D187763CF1D55034004" + - "87F55BA57E31CC7A7135C886EFB4318AED6A1E012D9E6832" + - "A907600A918130C46DC778F971AD0038092999A333CB8B7A" + - "1A1DB93D7140003C2A4ECEA9F98D0ACC0A8291CDCEC97DCF" + - "8EC9B55A7F88A46B4DB5A851F44182E1C68A007E5E655F6A" + - "FFFFFFFFFFFFFFFF", 16); - private static final BigInteger p6144 = new BigInteger( // TLS FFDHE - "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + - "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + - "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + - "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + - "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + - "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + - "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + - "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + - "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + - "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + - "886B4238611FCFDCDE355B3B6519035BBC34F4DEF99C0238" + - "61B46FC9D6E6C9077AD91D2691F7F7EE598CB0FAC186D91C" + - "AEFE130985139270B4130C93BC437944F4FD4452E2D74DD3" + - "64F2E21E71F54BFF5CAE82AB9C9DF69EE86D2BC522363A0D" + - "ABC521979B0DEADA1DBF9A42D5C4484E0ABCD06BFA53DDEF" + - "3C1B20EE3FD59D7C25E41D2B669E1EF16E6F52C3164DF4FB" + - "7930E9E4E58857B6AC7D5F42D69F6D187763CF1D55034004" + - "87F55BA57E31CC7A7135C886EFB4318AED6A1E012D9E6832" + - "A907600A918130C46DC778F971AD0038092999A333CB8B7A" + - "1A1DB93D7140003C2A4ECEA9F98D0ACC0A8291CDCEC97DCF" + - "8EC9B55A7F88A46B4DB5A851F44182E1C68A007E5E0DD902" + - "0BFD64B645036C7A4E677D2C38532A3A23BA4442CAF53EA6" + - "3BB454329B7624C8917BDD64B1C0FD4CB38E8C334C701C3A" + - "CDAD0657FCCFEC719B1F5C3E4E46041F388147FB4CFDB477" + - "A52471F7A9A96910B855322EDB6340D8A00EF092350511E3" + - "0ABEC1FFF9E3A26E7FB29F8C183023C3587E38DA0077D9B4" + - "763E4E4B94B2BBC194C6651E77CAF992EEAAC0232A281BF6" + - "B3A739C1226116820AE8DB5847A67CBEF9C9091B462D538C" + - "D72B03746AE77F5E62292C311562A846505DC82DB854338A" + - "E49F5235C95B91178CCF2DD5CACEF403EC9D1810C6272B04" + - "5B3B71F9DC6B80D63FDD4A8E9ADB1E6962A69526D43161C1" + - "A41D570D7938DAD4A40E329CD0E40E65FFFFFFFFFFFFFFFF", 16); - private static final BigInteger p8192 = new BigInteger( // TLS FFDHE - "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + - "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + - "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + - "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + - "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + - "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + - "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + - "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + - "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + - "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + - "886B4238611FCFDCDE355B3B6519035BBC34F4DEF99C0238" + - "61B46FC9D6E6C9077AD91D2691F7F7EE598CB0FAC186D91C" + - "AEFE130985139270B4130C93BC437944F4FD4452E2D74DD3" + - "64F2E21E71F54BFF5CAE82AB9C9DF69EE86D2BC522363A0D" + - "ABC521979B0DEADA1DBF9A42D5C4484E0ABCD06BFA53DDEF" + - "3C1B20EE3FD59D7C25E41D2B669E1EF16E6F52C3164DF4FB" + - "7930E9E4E58857B6AC7D5F42D69F6D187763CF1D55034004" + - "87F55BA57E31CC7A7135C886EFB4318AED6A1E012D9E6832" + - "A907600A918130C46DC778F971AD0038092999A333CB8B7A" + - "1A1DB93D7140003C2A4ECEA9F98D0ACC0A8291CDCEC97DCF" + - "8EC9B55A7F88A46B4DB5A851F44182E1C68A007E5E0DD902" + - "0BFD64B645036C7A4E677D2C38532A3A23BA4442CAF53EA6" + - "3BB454329B7624C8917BDD64B1C0FD4CB38E8C334C701C3A" + - "CDAD0657FCCFEC719B1F5C3E4E46041F388147FB4CFDB477" + - "A52471F7A9A96910B855322EDB6340D8A00EF092350511E3" + - "0ABEC1FFF9E3A26E7FB29F8C183023C3587E38DA0077D9B4" + - "763E4E4B94B2BBC194C6651E77CAF992EEAAC0232A281BF6" + - "B3A739C1226116820AE8DB5847A67CBEF9C9091B462D538C" + - "D72B03746AE77F5E62292C311562A846505DC82DB854338A" + - "E49F5235C95B91178CCF2DD5CACEF403EC9D1810C6272B04" + - "5B3B71F9DC6B80D63FDD4A8E9ADB1E6962A69526D43161C1" + - "A41D570D7938DAD4A40E329CCFF46AAA36AD004CF600C838" + - "1E425A31D951AE64FDB23FCEC9509D43687FEB69EDD1CC5E" + - "0B8CC3BDF64B10EF86B63142A3AB8829555B2F747C932665" + - "CB2C0F1CC01BD70229388839D2AF05E454504AC78B758282" + - "2846C0BA35C35F5C59160CC046FD8251541FC68C9C86B022" + - "BB7099876A460E7451A8A93109703FEE1C217E6C3826E52C" + - "51AA691E0E423CFC99E9E31650C1217B624816CDAD9A95F9" + - "D5B8019488D9C0A0A1FE3075A577E23183F81D4A3F2FA457" + - "1EFC8CE0BA8A4FE8B6855DFE72B0A66EDED2FBABFBE58A30" + - "FAFABE1C5D71A87E2F741EF8C1FE86FEA6BBFDE530677F0D" + - "97D11D49F7A8443D0822E506A9F4614E011E2A94838FF88C" + - "D68C8BB7C5C6424CFFFFFFFFFFFFFFFF", 16); - - private static final BigInteger[] supportedPrimes = { - p512, p768, p1024, p1536, p2048, p3072, p4096, p6144, p8192}; - - // a measure of the uncertainty that prime modulus p is not a prime - // - // see BigInteger.isProbablePrime(int certainty) - private final static int PRIME_CERTAINTY = 120; - - // the known security property, jdk.tls.server.defaultDHEParameters - private final static String PROPERTY_NAME = - "jdk.tls.server.defaultDHEParameters"; - - private static final Pattern spacesPattern = Pattern.compile("\\s+"); - - private final static Pattern syntaxPattern = Pattern.compile( - "(\\{[0-9A-Fa-f]+,[0-9A-Fa-f]+\\})" + - "(,\\{[0-9A-Fa-f]+,[0-9A-Fa-f]+\\})*"); - - private static final Pattern paramsPattern = Pattern.compile( - "\\{([0-9A-Fa-f]+),([0-9A-Fa-f]+)\\}"); - - // cache of predefined default DH ephemeral parameters - private final static Map definedParams; - - static { - String property = AccessController.doPrivileged( - new PrivilegedAction() { - public String run() { - return Security.getProperty(PROPERTY_NAME); - } - }); - - if (property != null && !property.isEmpty()) { - // remove double quote marks from beginning/end of the property - if (property.length() >= 2 && property.charAt(0) == '"' && - property.charAt(property.length() - 1) == '"') { - property = property.substring(1, property.length() - 1); - } - - property = property.trim(); - } - - if (property != null && !property.isEmpty()) { - Matcher spacesMatcher = spacesPattern.matcher(property); - property = spacesMatcher.replaceAll(""); - - if (debugIsOn) { - System.out.println("The Security Property " + - PROPERTY_NAME + ": " + property); - } - } - - Map defaultParams = new HashMap<>(); - if (property != null && !property.isEmpty()) { - Matcher syntaxMatcher = syntaxPattern.matcher(property); - if (syntaxMatcher.matches()) { - Matcher paramsFinder = paramsPattern.matcher(property); - while(paramsFinder.find()) { - String primeModulus = paramsFinder.group(1); - BigInteger p = new BigInteger(primeModulus, 16); - if (!p.isProbablePrime(PRIME_CERTAINTY)) { - if (debugIsOn) { - System.out.println( - "Prime modulus p in Security Property, " + - PROPERTY_NAME + ", is not a prime: " + - primeModulus); - } - - continue; - } - - String baseGenerator = paramsFinder.group(2); - BigInteger g = new BigInteger(baseGenerator, 16); - - DHParameterSpec spec = new DHParameterSpec(p, g); - int primeLen = p.bitLength(); - defaultParams.put(primeLen, spec); - } - } else if (debugIsOn) { - System.out.println("Invalid Security Property, " + - PROPERTY_NAME + ", definition"); - } - } - - for (BigInteger p : supportedPrimes) { - int primeLen = p.bitLength(); - defaultParams.putIfAbsent(primeLen, - new DHParameterSpec(p, BigInteger.TWO)); - } - - definedParams = - Collections.unmodifiableMap( - defaultParams); - } - } } + diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/ECDHCrypt.java b/jdk/src/java.base/share/classes/sun/security/ssl/ECDHCrypt.java index 929c592d698..7e4f5932a58 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/ECDHCrypt.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/ECDHCrypt.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -56,17 +56,17 @@ final class ECDHCrypt { } // Called by ServerHandshaker for ephemeral ECDH - ECDHCrypt(int curveId, SecureRandom random) { + ECDHCrypt(NamedGroup namedGroup, SecureRandom random) { try { KeyPairGenerator kpg = JsseJce.getKeyPairGenerator("EC"); ECGenParameterSpec params = - EllipticCurvesExtension.getECGenParamSpec(curveId); + SupportedGroupsExtension.getECGenParamSpec(namedGroup); kpg.initialize(params, random); KeyPair kp = kpg.generateKeyPair(); privateKey = kp.getPrivate(); publicKey = (ECPublicKey)kp.getPublic(); } catch (GeneralSecurityException e) { - throw new RuntimeException("Could not generate DH keypair", e); + throw new RuntimeException("Could not generate ECDH keypair", e); } } @@ -79,7 +79,7 @@ final class ECDHCrypt { privateKey = kp.getPrivate(); publicKey = (ECPublicKey)kp.getPublic(); } catch (GeneralSecurityException e) { - throw new RuntimeException("Could not generate DH keypair", e); + throw new RuntimeException("Could not generate ECDH keypair", e); } } diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/EllipticCurvesExtension.java b/jdk/src/java.base/share/classes/sun/security/ssl/EllipticCurvesExtension.java deleted file mode 100644 index c91b25e72ef..00000000000 --- a/jdk/src/java.base/share/classes/sun/security/ssl/EllipticCurvesExtension.java +++ /dev/null @@ -1,400 +0,0 @@ -/* - * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * by Oracle in the LICENSE file that accompanied this code. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package sun.security.ssl; - -import java.io.IOException; -import java.security.spec.ECParameterSpec; -import java.security.spec.ECGenParameterSpec; -import java.security.spec.InvalidParameterSpecException; -import java.security.AlgorithmParameters; -import java.security.AlgorithmConstraints; -import java.security.CryptoPrimitive; -import java.security.AccessController; -import java.util.EnumSet; -import java.util.HashMap; -import java.util.Map; -import java.util.ArrayList; -import javax.net.ssl.SSLProtocolException; - -import sun.security.action.GetPropertyAction; - -final class EllipticCurvesExtension extends HelloExtension { - - /* Class and subclass dynamic debugging support */ - private static final Debug debug = Debug.getInstance("ssl"); - - private static final int ARBITRARY_PRIME = 0xff01; - private static final int ARBITRARY_CHAR2 = 0xff02; - - // speed up the searching - private static final Map oidToIdMap = new HashMap<>(); - private static final Map idToOidMap = new HashMap<>(); - - // speed up the parameters construction - private static final Map idToParams = new HashMap<>(); - - // the supported elliptic curves - private static final int[] supportedCurveIds; - - // the curves of the extension - private final int[] curveIds; - - // See sun.security.util.CurveDB for the OIDs - private static enum NamedEllipticCurve { - T163_K1(1, "sect163k1", "1.3.132.0.1", true), // NIST K-163 - T163_R1(2, "sect163r1", "1.3.132.0.2", false), - T163_R2(3, "sect163r2", "1.3.132.0.15", true), // NIST B-163 - T193_R1(4, "sect193r1", "1.3.132.0.24", false), - T193_R2(5, "sect193r2", "1.3.132.0.25", false), - T233_K1(6, "sect233k1", "1.3.132.0.26", true), // NIST K-233 - T233_R1(7, "sect233r1", "1.3.132.0.27", true), // NIST B-233 - T239_K1(8, "sect239k1", "1.3.132.0.3", false), - T283_K1(9, "sect283k1", "1.3.132.0.16", true), // NIST K-283 - T283_R1(10, "sect283r1", "1.3.132.0.17", true), // NIST B-283 - T409_K1(11, "sect409k1", "1.3.132.0.36", true), // NIST K-409 - T409_R1(12, "sect409r1", "1.3.132.0.37", true), // NIST B-409 - T571_K1(13, "sect571k1", "1.3.132.0.38", true), // NIST K-571 - T571_R1(14, "sect571r1", "1.3.132.0.39", true), // NIST B-571 - - P160_K1(15, "secp160k1", "1.3.132.0.9", false), - P160_R1(16, "secp160r1", "1.3.132.0.8", false), - P160_R2(17, "secp160r2", "1.3.132.0.30", false), - P192_K1(18, "secp192k1", "1.3.132.0.31", false), - P192_R1(19, "secp192r1", "1.2.840.10045.3.1.1", true), // NIST P-192 - P224_K1(20, "secp224k1", "1.3.132.0.32", false), - P224_R1(21, "secp224r1", "1.3.132.0.33", true), // NIST P-224 - P256_K1(22, "secp256k1", "1.3.132.0.10", false), - P256_R1(23, "secp256r1", "1.2.840.10045.3.1.7", true), // NIST P-256 - P384_R1(24, "secp384r1", "1.3.132.0.34", true), // NIST P-384 - P521_R1(25, "secp521r1", "1.3.132.0.35", true); // NIST P-521 - - int id; - String name; - String oid; - boolean isFips; - - NamedEllipticCurve(int id, String name, String oid, boolean isFips) { - this.id = id; - this.name = name; - this.oid = oid; - this.isFips = isFips; - - if (oidToIdMap.put(oid, id) != null || - idToOidMap.put(id, oid) != null) { - - throw new RuntimeException( - "Duplicate named elliptic curve definition: " + name); - } - } - - static NamedEllipticCurve getCurve(String name, boolean requireFips) { - for (NamedEllipticCurve curve : NamedEllipticCurve.values()) { - if (curve.name.equals(name) && (!requireFips || curve.isFips)) { - return curve; - } - } - - return null; - } - } - - static { - boolean requireFips = SunJSSE.isFIPS(); - - // hack code to initialize NamedEllipticCurve - NamedEllipticCurve nec = - NamedEllipticCurve.getCurve("secp256r1", false); - - // The value of the System Property defines a list of enabled named - // curves in preference order, separated with comma. For example: - // - // jdk.tls.namedGroups="secp521r1, secp256r1, secp384r1" - // - // If the System Property is not defined or the value is empty, the - // default curves and preferences will be used. - String property = AccessController.doPrivileged( - new GetPropertyAction("jdk.tls.namedGroups")); - if (property != null && property.length() != 0) { - // remove double quote marks from beginning/end of the property - if (property.length() > 1 && property.charAt(0) == '"' && - property.charAt(property.length() - 1) == '"') { - property = property.substring(1, property.length() - 1); - } - } - - ArrayList idList; - if (property != null && property.length() != 0) { // customized curves - String[] curves = property.split(","); - idList = new ArrayList<>(curves.length); - for (String curve : curves) { - curve = curve.trim(); - if (!curve.isEmpty()) { - NamedEllipticCurve namedCurve = - NamedEllipticCurve.getCurve(curve, requireFips); - if (namedCurve != null) { - if (isAvailableCurve(namedCurve.id)) { - idList.add(namedCurve.id); - } - } // ignore unknown curves - } - } - if (idList.isEmpty() && JsseJce.isEcAvailable()) { - throw new IllegalArgumentException( - "System property jdk.tls.namedGroups(" + property + ") " + - "contains no supported elliptic curves"); - } - } else { // default curves - int[] ids; - if (requireFips) { - ids = new int[] { - // only NIST curves in FIPS mode - 23, 24, 25, 9, 10, 11, 12, 13, 14, - }; - } else { - ids = new int[] { - // NIST curves first - 23, 24, 25, 9, 10, 11, 12, 13, 14, - // non-NIST curves - 22, - }; - } - - idList = new ArrayList<>(ids.length); - for (int curveId : ids) { - if (isAvailableCurve(curveId)) { - idList.add(curveId); - } - } - } - - if (debug != null && idList.isEmpty()) { - Debug.log( - "Initialized [jdk.tls.namedGroups|default] list contains " + - "no available elliptic curves. " + - (property != null ? "(" + property + ")" : "[Default]")); - } - - supportedCurveIds = new int[idList.size()]; - int i = 0; - for (Integer id : idList) { - supportedCurveIds[i++] = id; - } - } - - // check whether the curve is supported by the underlying providers - private static boolean isAvailableCurve(int curveId) { - String oid = idToOidMap.get(curveId); - if (oid != null) { - AlgorithmParameters params = null; - try { - params = JsseJce.getAlgorithmParameters("EC"); - params.init(new ECGenParameterSpec(oid)); - } catch (Exception e) { - return false; - } - - // cache the parameters - idToParams.put(curveId, params); - - return true; - } - - return false; - } - - private EllipticCurvesExtension(int[] curveIds) { - super(ExtensionType.EXT_ELLIPTIC_CURVES); - - this.curveIds = curveIds; - } - - EllipticCurvesExtension(HandshakeInStream s, int len) - throws IOException { - super(ExtensionType.EXT_ELLIPTIC_CURVES); - - int k = s.getInt16(); - if (((len & 1) != 0) || (k + 2 != len)) { - throw new SSLProtocolException("Invalid " + type + " extension"); - } - - // Note: unknown curves will be ignored later. - curveIds = new int[k >> 1]; - for (int i = 0; i < curveIds.length; i++) { - curveIds[i] = s.getInt16(); - } - } - - // get the preferred active curve - static int getActiveCurves(AlgorithmConstraints constraints) { - return getPreferredCurve(supportedCurveIds, constraints); - } - - static boolean hasActiveCurves(AlgorithmConstraints constraints) { - return getActiveCurves(constraints) >= 0; - } - - static EllipticCurvesExtension createExtension( - AlgorithmConstraints constraints) { - - ArrayList idList = new ArrayList<>(supportedCurveIds.length); - for (int curveId : supportedCurveIds) { - if (constraints.permits( - EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), - "EC", idToParams.get(curveId))) { - idList.add(curveId); - } - } - - if (!idList.isEmpty()) { - int[] ids = new int[idList.size()]; - int i = 0; - for (Integer id : idList) { - ids[i++] = id; - } - - return new EllipticCurvesExtension(ids); - } - - return null; - } - - // get the preferred activated curve - int getPreferredCurve(AlgorithmConstraints constraints) { - return getPreferredCurve(curveIds, constraints); - } - - // get a preferred activated curve - private static int getPreferredCurve(int[] curves, - AlgorithmConstraints constraints) { - for (int curveId : curves) { - if (isSupported(curveId) && constraints.permits( - EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), - "EC", idToParams.get(curveId))) { - return curveId; - } - } - - return -1; - } - - boolean contains(int index) { - for (int curveId : curveIds) { - if (index == curveId) { - return true; - } - } - return false; - } - - @Override - int length() { - return 6 + (curveIds.length << 1); - } - - @Override - void send(HandshakeOutStream s) throws IOException { - s.putInt16(type.id); - int k = curveIds.length << 1; - s.putInt16(k + 2); - s.putInt16(k); - for (int curveId : curveIds) { - s.putInt16(curveId); - } - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("Extension " + type + ", curve names: {"); - boolean first = true; - for (int curveId : curveIds) { - if (first) { - first = false; - } else { - sb.append(", "); - } - // first check if it is a known named curve, then try other cases. - String curveName = getCurveName(curveId); - if (curveName != null) { - sb.append(curveName); - } else if (curveId == ARBITRARY_PRIME) { - sb.append("arbitrary_explicit_prime_curves"); - } else if (curveId == ARBITRARY_CHAR2) { - sb.append("arbitrary_explicit_char2_curves"); - } else { - sb.append("unknown curve " + curveId); - } - } - sb.append("}"); - return sb.toString(); - } - - // Test whether the given curve is supported. - static boolean isSupported(int index) { - for (int curveId : supportedCurveIds) { - if (index == curveId) { - return true; - } - } - - return false; - } - - static int getCurveIndex(ECParameterSpec params) { - String oid = JsseJce.getNamedCurveOid(params); - if (oid == null) { - return -1; - } - Integer n = oidToIdMap.get(oid); - return (n == null) ? -1 : n; - } - - static String getCurveOid(int index) { - return idToOidMap.get(index); - } - - static ECGenParameterSpec getECGenParamSpec(int index) { - AlgorithmParameters params = idToParams.get(index); - try { - return params.getParameterSpec(ECGenParameterSpec.class); - } catch (InvalidParameterSpecException ipse) { - // should be unlikely - String curveOid = getCurveOid(index); - return new ECGenParameterSpec(curveOid); - } - } - - private static String getCurveName(int index) { - for (NamedEllipticCurve namedCurve : NamedEllipticCurve.values()) { - if (namedCurve.id == index) { - return namedCurve.name; - } - } - - return null; - } -} diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/ExtensionType.java b/jdk/src/java.base/share/classes/sun/security/ssl/ExtensionType.java index be64dfde624..5338807bbdc 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/ExtensionType.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/ExtensionType.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -82,9 +82,9 @@ final class ExtensionType { static final ExtensionType EXT_CERT_TYPE = e(0x0009, "cert_type"); // IANA registry value: 9 - // extensions defined in RFC 4492 (ECC) - static final ExtensionType EXT_ELLIPTIC_CURVES = - e(0x000A, "elliptic_curves"); // IANA registry value: 10 + // extensions defined in RFC 4492 (ECC) and RFC 7919 (FFDHE) + static final ExtensionType EXT_SUPPORTED_GROUPS = + e(0x000A, "supported_groups"); // IANA registry value: 10 static final ExtensionType EXT_EC_POINT_FORMATS = e(0x000B, "ec_point_formats"); // IANA registry value: 11 diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/HandshakeMessage.java b/jdk/src/java.base/share/classes/sun/security/ssl/HandshakeMessage.java index 4717fbba178..8477456c4d5 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/HandshakeMessage.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/HandshakeMessage.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1369,8 +1369,9 @@ class ECDH_ServerKeyExchange extends ServerKeyExchange { private static final int CURVE_EXPLICIT_CHAR2 = 2; private static final int CURVE_NAMED_CURVE = 3; - // id of the curve we are using - private int curveId; + // id of the named group we are using + private int groupId; + // encoded public point private byte[] pointBytes; @@ -1389,7 +1390,8 @@ class ECDH_ServerKeyExchange extends ServerKeyExchange { ECDH_ServerKeyExchange(ECDHCrypt obj, PrivateKey privateKey, byte[] clntNonce, byte[] svrNonce, SecureRandom sr, SignatureAndHashAlgorithm signAlgorithm, - ProtocolVersion protocolVersion) throws GeneralSecurityException { + ProtocolVersion protocolVersion) + throws SSLHandshakeException, GeneralSecurityException { this.protocolVersion = protocolVersion; @@ -1397,7 +1399,14 @@ class ECDH_ServerKeyExchange extends ServerKeyExchange { ECParameterSpec params = publicKey.getParams(); ECPoint point = publicKey.getW(); pointBytes = JsseJce.encodePoint(point, params.getCurve()); - curveId = EllipticCurvesExtension.getCurveIndex(params); + + NamedGroup namedGroup = NamedGroup.valueOf(params); + if ((namedGroup == null) || (namedGroup.oid == null) ){ + // unlikely + throw new SSLHandshakeException( + "Unnamed EC parameter spec: " + params); + } + groupId = namedGroup.id; if (privateKey == null) { // ECDH_anon @@ -1434,20 +1443,27 @@ class ECDH_ServerKeyExchange extends ServerKeyExchange { // These parsing errors should never occur as we negotiated // the supported curves during the exchange of the Hello messages. if (curveType == CURVE_NAMED_CURVE) { - curveId = input.getInt16(); - if (!EllipticCurvesExtension.isSupported(curveId)) { + groupId = input.getInt16(); + NamedGroup namedGroup = NamedGroup.valueOf(groupId); + if (namedGroup == null) { throw new SSLHandshakeException( - "Unsupported curveId: " + curveId); + "Unknown named group ID: " + groupId); } - String curveOid = EllipticCurvesExtension.getCurveOid(curveId); - if (curveOid == null) { + + if (!SupportedGroupsExtension.supports(namedGroup)) { throw new SSLHandshakeException( - "Unknown named curve: " + curveId); + "Unsupported named group: " + namedGroup); } - parameters = JsseJce.getECParameterSpec(curveOid); + + if (namedGroup.oid == null) { + throw new SSLHandshakeException( + "Unknown named EC curve: " + namedGroup); + } + + parameters = JsseJce.getECParameterSpec(namedGroup.oid); if (parameters == null) { throw new SSLHandshakeException( - "Unsupported curve: " + curveOid); + "No supported EC parameter for named group: " + namedGroup); } } else { throw new SSLHandshakeException( @@ -1530,8 +1546,8 @@ class ECDH_ServerKeyExchange extends ServerKeyExchange { sig.update(svrNonce); sig.update((byte)CURVE_NAMED_CURVE); - sig.update((byte)(curveId >> 8)); - sig.update((byte)curveId); + sig.update((byte)(groupId >> 8)); + sig.update((byte)groupId); sig.update((byte)pointBytes.length); sig.update(pointBytes); } @@ -1552,7 +1568,7 @@ class ECDH_ServerKeyExchange extends ServerKeyExchange { @Override void send(HandshakeOutStream s) throws IOException { s.putInt8(CURVE_NAMED_CURVE); - s.putInt16(curveId); + s.putInt16(groupId); s.putBytes8(pointBytes); if (signatureBytes != null) { diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/Handshaker.java b/jdk/src/java.base/share/classes/sun/security/ssl/Handshaker.java index f830bc70ce1..e26495b3c5f 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/Handshaker.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/Handshaker.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -52,6 +52,7 @@ import sun.security.ssl.CipherSuite.*; import static sun.security.ssl.CipherSuite.PRF.*; import static sun.security.ssl.CipherSuite.CipherType.*; +import static sun.security.ssl.NamedGroupType.*; /** * Handshaker ... processes handshake records from an SSL V3.0 @@ -685,42 +686,14 @@ abstract class Handshaker { ArrayList suites = new ArrayList<>(); if (!(activeProtocols.collection().isEmpty()) && activeProtocols.min.v != ProtocolVersion.NONE.v) { - boolean checkedCurves = false; - boolean hasCurves = false; + Map cachedStatus = + new EnumMap<>(NamedGroupType.class); for (CipherSuite suite : enabledCipherSuites.collection()) { - if (!activeProtocols.min.obsoletes(suite) && + if (suite.isAvailable() && + (!activeProtocols.min.obsoletes(suite)) && activeProtocols.max.supports(suite)) { - if (algorithmConstraints.permits( - EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), - suite.name, null)) { - - boolean available = true; - if (suite.keyExchange.isEC) { - if (!checkedCurves) { - hasCurves = EllipticCurvesExtension - .hasActiveCurves(algorithmConstraints); - checkedCurves = true; - - if (!hasCurves && debug != null && - Debug.isOn("verbose")) { - System.out.println( - "No available elliptic curves"); - } - } - - available = hasCurves; - - if (!available && debug != null && - Debug.isOn("verbose")) { - System.out.println( - "No active elliptic curves, ignore " + - suite); - } - } - - if (available) { - suites.add(suite); - } + if (isActivatable(suite, cachedStatus)) { + suites.add(suite); } } else if (debug != null && Debug.isOn("verbose")) { if (activeProtocols.min.obsoletes(suite)) { @@ -779,46 +752,15 @@ abstract class Handshaker { } boolean found = false; + Map cachedStatus = + new EnumMap<>(NamedGroupType.class); for (CipherSuite suite : enabledCipherSuites.collection()) { if (suite.isAvailable() && (!protocol.obsoletes(suite)) && protocol.supports(suite)) { - if (algorithmConstraints.permits( - EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), - suite.name, null)) { - - boolean available = true; - if (suite.keyExchange.isEC) { - if (!checkedCurves) { - hasCurves = EllipticCurvesExtension - .hasActiveCurves(algorithmConstraints); - checkedCurves = true; - - if (!hasCurves && debug != null && - Debug.isOn("verbose")) { - System.out.println( - "No activated elliptic curves"); - } - } - - available = hasCurves; - - if (!available && debug != null && - Debug.isOn("verbose")) { - System.out.println( - "No active elliptic curves, ignore " + - suite + " for " + protocol); - } - } - - if (available) { - protocols.add(protocol); - found = true; - break; - } - } else if (debug != null && Debug.isOn("verbose")) { - System.out.println( - "Ignoring disabled cipher suite: " + suite + - " for " + protocol); + if (isActivatable(suite, cachedStatus)) { + protocols.add(protocol); + found = true; + break; } } else if (debug != null && Debug.isOn("verbose")) { System.out.println( @@ -826,6 +768,7 @@ abstract class Handshaker { " for " + protocol); } } + if (!found && (debug != null) && Debug.isOn("handshake")) { System.out.println( "No available cipher suite for " + protocol); @@ -842,6 +785,43 @@ abstract class Handshaker { return activeProtocols; } + private boolean isActivatable(CipherSuite suite, + Map cachedStatus) { + + if (algorithmConstraints.permits( + EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), suite.name, null)) { + boolean available = true; + NamedGroupType groupType = suite.keyExchange.groupType; + if (groupType != NAMED_GROUP_NONE) { + Boolean checkedStatus = cachedStatus.get(groupType); + if (checkedStatus == null) { + available = SupportedGroupsExtension.isActivatable( + algorithmConstraints, groupType); + cachedStatus.put(groupType, available); + + if (!available && debug != null && Debug.isOn("verbose")) { + System.out.println("No activated named group"); + } + } else { + available = checkedStatus.booleanValue(); + } + + if (!available && debug != null && Debug.isOn("verbose")) { + System.out.println( + "No active named group, ignore " + suite); + } + + return available; + } else { + return true; + } + } else if (debug != null && Debug.isOn("verbose")) { + System.out.println("Ignoring disabled cipher suite: " + suite); + } + + return false; + } + /** * As long as handshaking has not activated, we can * change whether session creations are allowed. diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/HelloExtensions.java b/jdk/src/java.base/share/classes/sun/security/ssl/HelloExtensions.java index f831db12391..82975c962f5 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/HelloExtensions.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/HelloExtensions.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -49,7 +49,7 @@ import javax.net.ssl.*; * explicitly support. * . ServerNameExtension: the server_name extension. * . SignatureAlgorithmsExtension: the signature_algorithms extension. - * . EllipticCurvesExtension: the ECC supported curves extension. + * . SupportedGroupsExtension: the supported groups extension. * . EllipticPointFormatsExtension: the ECC supported point formats * (compressed/uncompressed) extension. * . ALPNExtension: the application_layer_protocol_negotiation extension. @@ -79,8 +79,8 @@ final class HelloExtensions { extension = new ServerNameExtension(s, extlen); } else if (extType == ExtensionType.EXT_SIGNATURE_ALGORITHMS) { extension = new SignatureAlgorithmsExtension(s, extlen); - } else if (extType == ExtensionType.EXT_ELLIPTIC_CURVES) { - extension = new EllipticCurvesExtension(s, extlen); + } else if (extType == ExtensionType.EXT_SUPPORTED_GROUPS) { + extension = new SupportedGroupsExtension(s, extlen); } else if (extType == ExtensionType.EXT_EC_POINT_FORMATS) { extension = new EllipticPointFormatsExtension(s, extlen); } else if (extType == ExtensionType.EXT_RENEGOTIATION_INFO) { diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/NamedGroup.java b/jdk/src/java.base/share/classes/sun/security/ssl/NamedGroup.java new file mode 100644 index 00000000000..452e839a205 --- /dev/null +++ b/jdk/src/java.base/share/classes/sun/security/ssl/NamedGroup.java @@ -0,0 +1,169 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package sun.security.ssl; + +import java.security.spec.ECParameterSpec; +import java.security.spec.ECGenParameterSpec; +import static sun.security.ssl.NamedGroupType.*; + +enum NamedGroup { + // Elliptic Curves (RFC 4492) + // + // See sun.security.util.CurveDB for the OIDs + + // NIST K-163 + SECT163_K1(1, NAMED_GROUP_ECDHE, "sect163k1", "1.3.132.0.1", true), + + SECT163_R1(2, NAMED_GROUP_ECDHE, "sect163r1", "1.3.132.0.2", false), + + // NIST B-163 + SECT163_R2(3, NAMED_GROUP_ECDHE, "sect163r2", "1.3.132.0.15", true), + + SECT193_R1(4, NAMED_GROUP_ECDHE, "sect193r1", "1.3.132.0.24", false), + SECT193_R2(5, NAMED_GROUP_ECDHE, "sect193r2", "1.3.132.0.25", false), + + // NIST K-233 + SECT233_K1(6, NAMED_GROUP_ECDHE, "sect233k1", "1.3.132.0.26", true), + + // NIST B-233 + SECT233_R1(7, NAMED_GROUP_ECDHE, "sect233r1", "1.3.132.0.27", true), + + SECT239_K1(8, NAMED_GROUP_ECDHE, "sect239k1", "1.3.132.0.3", false), + + // NIST K-283 + SECT283_K1(9, NAMED_GROUP_ECDHE, "sect283k1", "1.3.132.0.16", true), + + // NIST B-283 + SECT283_R1(10, NAMED_GROUP_ECDHE, "sect283r1", "1.3.132.0.17", true), + + // NIST K-409 + SECT409_K1(11, NAMED_GROUP_ECDHE, "sect409k1", "1.3.132.0.36", true), + + // NIST B-409 + SECT409_R1(12, NAMED_GROUP_ECDHE, "sect409r1", "1.3.132.0.37", true), + + // NIST K-571 + SECT571_K1(13, NAMED_GROUP_ECDHE, "sect571k1", "1.3.132.0.38", true), + + // NIST B-571 + SECT571_R1(14, NAMED_GROUP_ECDHE, "sect571r1", "1.3.132.0.39", true), + + SECP160_K1(15, NAMED_GROUP_ECDHE, "secp160k1", "1.3.132.0.9", false), + SECP160_R1(16, NAMED_GROUP_ECDHE, "secp160r1", "1.3.132.0.8", false), + SECP160_R2(17, NAMED_GROUP_ECDHE, "secp160r2", "1.3.132.0.30", false), + SECP192_K1(18, NAMED_GROUP_ECDHE, "secp192k1", "1.3.132.0.31", false), + + // NIST P-192 + SECP192_R1(19, NAMED_GROUP_ECDHE, "secp192r1", "1.2.840.10045.3.1.1", true), + + SECP224_K1(20, NAMED_GROUP_ECDHE, "secp224k1", "1.3.132.0.32", false), + // NIST P-224 + SECP224_R1(21, NAMED_GROUP_ECDHE, "secp224r1", "1.3.132.0.33", true), + + SECP256_K1(22, NAMED_GROUP_ECDHE, "secp256k1", "1.3.132.0.10", false), + + // NIST P-256 + SECP256_R1(23, NAMED_GROUP_ECDHE, "secp256r1", "1.2.840.10045.3.1.7", true), + + // NIST P-384 + SECP384_R1(24, NAMED_GROUP_ECDHE, "secp384r1", "1.3.132.0.34", true), + + // NIST P-521 + SECP521_R1(25, NAMED_GROUP_ECDHE, "secp521r1", "1.3.132.0.35", true), + + // Finite Field Diffie-Hellman Ephemeral Parameters (RFC 7919) + FFDHE_2048(256, NAMED_GROUP_FFDHE, "ffdhe2048", true), + FFDHE_3072(257, NAMED_GROUP_FFDHE, "ffdhe3072", true), + FFDHE_4096(258, NAMED_GROUP_FFDHE, "ffdhe4096", true), + FFDHE_6144(259, NAMED_GROUP_FFDHE, "ffdhe6144", true), + FFDHE_8192(260, NAMED_GROUP_FFDHE, "ffdhe8192", true); + + int id; + NamedGroupType type; + String name; + String oid; + String algorithm; + boolean isFips; + + // Constructor used for Elliptic Curve Groups (ECDHE) + NamedGroup(int id, NamedGroupType type, + String name, String oid, boolean isFips) { + this.id = id; + this.type = type; + this.name = name; + this.oid = oid; + this.algorithm = "EC"; + this.isFips = isFips; + } + + // Constructor used for Finite Field Diffie-Hellman Groups (FFDHE) + NamedGroup(int id, NamedGroupType type, String name, boolean isFips) { + this.id = id; + this.type = type; + this.name = name; + this.oid = null; + this.algorithm = "DiffieHellman"; + this.isFips = isFips; + } + + static NamedGroup valueOf(int id) { + for (NamedGroup group : NamedGroup.values()) { + if (group.id == id) { + return group; + } + } + + return null; + } + + static NamedGroup nameOf(String name) { + for (NamedGroup group : NamedGroup.values()) { + if (group.name.equals(name)) { + return group; + } + } + + return null; + } + + static NamedGroup valueOf(ECParameterSpec params) { + String oid = JsseJce.getNamedCurveOid(params); + if ((oid != null) && (!oid.isEmpty())) { + for (NamedGroup group : NamedGroup.values()) { + if (oid.equals(group.oid)) { + return group; + } + } + } + + return null; + } + + @Override + public String toString() { + return this.name; + } +} diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/NamedGroupType.java b/jdk/src/java.base/share/classes/sun/security/ssl/NamedGroupType.java new file mode 100644 index 00000000000..0e0c982e4a2 --- /dev/null +++ b/jdk/src/java.base/share/classes/sun/security/ssl/NamedGroupType.java @@ -0,0 +1,32 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package sun.security.ssl; + +enum NamedGroupType { + NAMED_GROUP_ECDHE, // Elliptic Curve Groups (ECDHE) + NAMED_GROUP_FFDHE, // Finite Field Groups (DHE) + NAMED_GROUP_NONE // No predefined named group +} diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/PredefinedDHParameterSpecs.java b/jdk/src/java.base/share/classes/sun/security/ssl/PredefinedDHParameterSpecs.java new file mode 100644 index 00000000000..54d8c7d3109 --- /dev/null +++ b/jdk/src/java.base/share/classes/sun/security/ssl/PredefinedDHParameterSpecs.java @@ -0,0 +1,314 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package sun.security.ssl; + +import java.security.*; +import java.math.BigInteger; +import java.util.regex.Pattern; +import java.util.regex.Matcher; +import java.util.Map; +import java.util.HashMap; +import java.util.Collections; +import javax.crypto.spec.DHParameterSpec; + +/** + * Predefined default DH ephemeral parameters. + */ +final class PredefinedDHParameterSpecs { + private final static boolean debugIsOn = + (Debug.getInstance("ssl") != null) && Debug.isOn("sslctx"); + + // + // Default DH ephemeral parameters + // + private static final BigInteger p512 = new BigInteger( // generated + "D87780E15FF50B4ABBE89870188B049406B5BEA98AB23A02" + + "41D88EA75B7755E669C08093D3F0CA7FC3A5A25CF067DCB9" + + "A43DD89D1D90921C6328884461E0B6D3", 16); + private static final BigInteger p768 = new BigInteger( // RFC 2409 + "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD1" + + "29024E088A67CC74020BBEA63B139B22514A08798E3404DD" + + "EF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245" + + "E485B576625E7EC6F44C42E9A63A3620FFFFFFFFFFFFFFFF", 16); + + private static final BigInteger p1024 = new BigInteger( // RFC 2409 + "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD1" + + "29024E088A67CC74020BBEA63B139B22514A08798E3404DD" + + "EF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245" + + "E485B576625E7EC6F44C42E9A637ED6B0BFF5CB6F406B7ED" + + "EE386BFB5A899FA5AE9F24117C4B1FE649286651ECE65381" + + "FFFFFFFFFFFFFFFF", 16); + private static final BigInteger p1536 = new BigInteger( // RFC 3526 + "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD1" + + "29024E088A67CC74020BBEA63B139B22514A08798E3404DD" + + "EF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245" + + "E485B576625E7EC6F44C42E9A637ED6B0BFF5CB6F406B7ED" + + "EE386BFB5A899FA5AE9F24117C4B1FE649286651ECE45B3D" + + "C2007CB8A163BF0598DA48361C55D39A69163FA8FD24CF5F" + + "83655D23DCA3AD961C62F356208552BB9ED529077096966D" + + "670C354E4ABC9804F1746C08CA237327FFFFFFFFFFFFFFFF", 16); + private static final BigInteger p2048 = new BigInteger( // TLS FFDHE + "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + + "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + + "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + + "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + + "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + + "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + + "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + + "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + + "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + + "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + + "886B423861285C97FFFFFFFFFFFFFFFF", 16); + private static final BigInteger p3072 = new BigInteger( // TLS FFDHE + "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + + "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + + "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + + "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + + "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + + "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + + "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + + "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + + "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + + "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + + "886B4238611FCFDCDE355B3B6519035BBC34F4DEF99C0238" + + "61B46FC9D6E6C9077AD91D2691F7F7EE598CB0FAC186D91C" + + "AEFE130985139270B4130C93BC437944F4FD4452E2D74DD3" + + "64F2E21E71F54BFF5CAE82AB9C9DF69EE86D2BC522363A0D" + + "ABC521979B0DEADA1DBF9A42D5C4484E0ABCD06BFA53DDEF" + + "3C1B20EE3FD59D7C25E41D2B66C62E37FFFFFFFFFFFFFFFF", 16); + private static final BigInteger p4096 = new BigInteger( // TLS FFDHE + "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + + "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + + "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + + "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + + "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + + "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + + "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + + "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + + "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + + "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + + "886B4238611FCFDCDE355B3B6519035BBC34F4DEF99C0238" + + "61B46FC9D6E6C9077AD91D2691F7F7EE598CB0FAC186D91C" + + "AEFE130985139270B4130C93BC437944F4FD4452E2D74DD3" + + "64F2E21E71F54BFF5CAE82AB9C9DF69EE86D2BC522363A0D" + + "ABC521979B0DEADA1DBF9A42D5C4484E0ABCD06BFA53DDEF" + + "3C1B20EE3FD59D7C25E41D2B669E1EF16E6F52C3164DF4FB" + + "7930E9E4E58857B6AC7D5F42D69F6D187763CF1D55034004" + + "87F55BA57E31CC7A7135C886EFB4318AED6A1E012D9E6832" + + "A907600A918130C46DC778F971AD0038092999A333CB8B7A" + + "1A1DB93D7140003C2A4ECEA9F98D0ACC0A8291CDCEC97DCF" + + "8EC9B55A7F88A46B4DB5A851F44182E1C68A007E5E655F6A" + + "FFFFFFFFFFFFFFFF", 16); + private static final BigInteger p6144 = new BigInteger( // TLS FFDHE + "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + + "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + + "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + + "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + + "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + + "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + + "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + + "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + + "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + + "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + + "886B4238611FCFDCDE355B3B6519035BBC34F4DEF99C0238" + + "61B46FC9D6E6C9077AD91D2691F7F7EE598CB0FAC186D91C" + + "AEFE130985139270B4130C93BC437944F4FD4452E2D74DD3" + + "64F2E21E71F54BFF5CAE82AB9C9DF69EE86D2BC522363A0D" + + "ABC521979B0DEADA1DBF9A42D5C4484E0ABCD06BFA53DDEF" + + "3C1B20EE3FD59D7C25E41D2B669E1EF16E6F52C3164DF4FB" + + "7930E9E4E58857B6AC7D5F42D69F6D187763CF1D55034004" + + "87F55BA57E31CC7A7135C886EFB4318AED6A1E012D9E6832" + + "A907600A918130C46DC778F971AD0038092999A333CB8B7A" + + "1A1DB93D7140003C2A4ECEA9F98D0ACC0A8291CDCEC97DCF" + + "8EC9B55A7F88A46B4DB5A851F44182E1C68A007E5E0DD902" + + "0BFD64B645036C7A4E677D2C38532A3A23BA4442CAF53EA6" + + "3BB454329B7624C8917BDD64B1C0FD4CB38E8C334C701C3A" + + "CDAD0657FCCFEC719B1F5C3E4E46041F388147FB4CFDB477" + + "A52471F7A9A96910B855322EDB6340D8A00EF092350511E3" + + "0ABEC1FFF9E3A26E7FB29F8C183023C3587E38DA0077D9B4" + + "763E4E4B94B2BBC194C6651E77CAF992EEAAC0232A281BF6" + + "B3A739C1226116820AE8DB5847A67CBEF9C9091B462D538C" + + "D72B03746AE77F5E62292C311562A846505DC82DB854338A" + + "E49F5235C95B91178CCF2DD5CACEF403EC9D1810C6272B04" + + "5B3B71F9DC6B80D63FDD4A8E9ADB1E6962A69526D43161C1" + + "A41D570D7938DAD4A40E329CD0E40E65FFFFFFFFFFFFFFFF", 16); + private static final BigInteger p8192 = new BigInteger( // TLS FFDHE + "FFFFFFFFFFFFFFFFADF85458A2BB4A9AAFDC5620273D3CF1" + + "D8B9C583CE2D3695A9E13641146433FBCC939DCE249B3EF9" + + "7D2FE363630C75D8F681B202AEC4617AD3DF1ED5D5FD6561" + + "2433F51F5F066ED0856365553DED1AF3B557135E7F57C935" + + "984F0C70E0E68B77E2A689DAF3EFE8721DF158A136ADE735" + + "30ACCA4F483A797ABC0AB182B324FB61D108A94BB2C8E3FB" + + "B96ADAB760D7F4681D4F42A3DE394DF4AE56EDE76372BB19" + + "0B07A7C8EE0A6D709E02FCE1CDF7E2ECC03404CD28342F61" + + "9172FE9CE98583FF8E4F1232EEF28183C3FE3B1B4C6FAD73" + + "3BB5FCBC2EC22005C58EF1837D1683B2C6F34A26C1B2EFFA" + + "886B4238611FCFDCDE355B3B6519035BBC34F4DEF99C0238" + + "61B46FC9D6E6C9077AD91D2691F7F7EE598CB0FAC186D91C" + + "AEFE130985139270B4130C93BC437944F4FD4452E2D74DD3" + + "64F2E21E71F54BFF5CAE82AB9C9DF69EE86D2BC522363A0D" + + "ABC521979B0DEADA1DBF9A42D5C4484E0ABCD06BFA53DDEF" + + "3C1B20EE3FD59D7C25E41D2B669E1EF16E6F52C3164DF4FB" + + "7930E9E4E58857B6AC7D5F42D69F6D187763CF1D55034004" + + "87F55BA57E31CC7A7135C886EFB4318AED6A1E012D9E6832" + + "A907600A918130C46DC778F971AD0038092999A333CB8B7A" + + "1A1DB93D7140003C2A4ECEA9F98D0ACC0A8291CDCEC97DCF" + + "8EC9B55A7F88A46B4DB5A851F44182E1C68A007E5E0DD902" + + "0BFD64B645036C7A4E677D2C38532A3A23BA4442CAF53EA6" + + "3BB454329B7624C8917BDD64B1C0FD4CB38E8C334C701C3A" + + "CDAD0657FCCFEC719B1F5C3E4E46041F388147FB4CFDB477" + + "A52471F7A9A96910B855322EDB6340D8A00EF092350511E3" + + "0ABEC1FFF9E3A26E7FB29F8C183023C3587E38DA0077D9B4" + + "763E4E4B94B2BBC194C6651E77CAF992EEAAC0232A281BF6" + + "B3A739C1226116820AE8DB5847A67CBEF9C9091B462D538C" + + "D72B03746AE77F5E62292C311562A846505DC82DB854338A" + + "E49F5235C95B91178CCF2DD5CACEF403EC9D1810C6272B04" + + "5B3B71F9DC6B80D63FDD4A8E9ADB1E6962A69526D43161C1" + + "A41D570D7938DAD4A40E329CCFF46AAA36AD004CF600C838" + + "1E425A31D951AE64FDB23FCEC9509D43687FEB69EDD1CC5E" + + "0B8CC3BDF64B10EF86B63142A3AB8829555B2F747C932665" + + "CB2C0F1CC01BD70229388839D2AF05E454504AC78B758282" + + "2846C0BA35C35F5C59160CC046FD8251541FC68C9C86B022" + + "BB7099876A460E7451A8A93109703FEE1C217E6C3826E52C" + + "51AA691E0E423CFC99E9E31650C1217B624816CDAD9A95F9" + + "D5B8019488D9C0A0A1FE3075A577E23183F81D4A3F2FA457" + + "1EFC8CE0BA8A4FE8B6855DFE72B0A66EDED2FBABFBE58A30" + + "FAFABE1C5D71A87E2F741EF8C1FE86FEA6BBFDE530677F0D" + + "97D11D49F7A8443D0822E506A9F4614E011E2A94838FF88C" + + "D68C8BB7C5C6424CFFFFFFFFFFFFFFFF", 16); + + private static final BigInteger[] supportedPrimes = { + p512, p768, p1024, p1536, p2048, p3072, p4096, p6144, p8192}; + + private static final BigInteger[] ffdhePrimes = { + p2048, p3072, p4096, p6144, p8192}; + + // a measure of the uncertainty that prime modulus p is not a prime + // + // see BigInteger.isProbablePrime(int certainty) + private final static int PRIME_CERTAINTY = 120; + + // the known security property, jdk.tls.server.defaultDHEParameters + private final static String PROPERTY_NAME = + "jdk.tls.server.defaultDHEParameters"; + + private static final Pattern spacesPattern = Pattern.compile("\\s+"); + + private final static Pattern syntaxPattern = Pattern.compile( + "(\\{[0-9A-Fa-f]+,[0-9A-Fa-f]+\\})" + + "(,\\{[0-9A-Fa-f]+,[0-9A-Fa-f]+\\})*"); + + private static final Pattern paramsPattern = Pattern.compile( + "\\{([0-9A-Fa-f]+),([0-9A-Fa-f]+)\\}"); + + // cache of predefined default DH ephemeral parameters + final static Map definedParams; + + // cache of Finite Field DH Ephemeral parameters (RFC 7919/FFDHE) + final static Map ffdheParams; + + static { + String property = AccessController.doPrivileged( + new PrivilegedAction() { + public String run() { + return Security.getProperty(PROPERTY_NAME); + } + }); + + if (property != null && !property.isEmpty()) { + // remove double quote marks from beginning/end of the property + if (property.length() >= 2 && property.charAt(0) == '"' && + property.charAt(property.length() - 1) == '"') { + property = property.substring(1, property.length() - 1); + } + + property = property.trim(); + } + + if (property != null && !property.isEmpty()) { + Matcher spacesMatcher = spacesPattern.matcher(property); + property = spacesMatcher.replaceAll(""); + + if (debugIsOn) { + System.out.println("The Security Property " + + PROPERTY_NAME + ": " + property); + } + } + + Map defaultParams = new HashMap<>(); + if (property != null && !property.isEmpty()) { + Matcher syntaxMatcher = syntaxPattern.matcher(property); + if (syntaxMatcher.matches()) { + Matcher paramsFinder = paramsPattern.matcher(property); + while(paramsFinder.find()) { + String primeModulus = paramsFinder.group(1); + BigInteger p = new BigInteger(primeModulus, 16); + if (!p.isProbablePrime(PRIME_CERTAINTY)) { + if (debugIsOn) { + System.out.println( + "Prime modulus p in Security Property, " + + PROPERTY_NAME + ", is not a prime: " + + primeModulus); + } + + continue; + } + + String baseGenerator = paramsFinder.group(2); + BigInteger g = new BigInteger(baseGenerator, 16); + + DHParameterSpec spec = new DHParameterSpec(p, g); + int primeLen = p.bitLength(); + defaultParams.put(primeLen, spec); + } + } else if (debugIsOn) { + System.out.println("Invalid Security Property, " + + PROPERTY_NAME + ", definition"); + } + } + + Map tempFFDHEs = new HashMap<>(); + for (BigInteger p : ffdhePrimes) { + int primeLen = p.bitLength(); + DHParameterSpec dhps = new DHParameterSpec(p, BigInteger.TWO); + tempFFDHEs.put(primeLen, dhps); + defaultParams.putIfAbsent(primeLen, dhps); + } + + for (BigInteger p : supportedPrimes) { + int primeLen = p.bitLength(); + if (defaultParams.get(primeLen) == null) { + defaultParams.put(primeLen, + new DHParameterSpec(p, BigInteger.TWO)); + } + } + + ffdheParams = + Collections.unmodifiableMap(tempFFDHEs); + definedParams = + Collections.unmodifiableMap(defaultParams); + } +} diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/RecordType.java b/jdk/src/java.base/share/classes/sun/security/ssl/RecordType.java deleted file mode 100644 index 1468802aeb0..00000000000 --- a/jdk/src/java.base/share/classes/sun/security/ssl/RecordType.java +++ /dev/null @@ -1,122 +0,0 @@ -/* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * by Oracle in the LICENSE file that accompanied this code. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package sun.security.ssl; - -/* - * enumation of record type - */ -enum RecordType { - - RECORD_CHANGE_CIPHER_SPEC (Record.ct_change_cipher_spec, - HandshakeMessage.ht_not_applicable), - RECORD_ALERT (Record.ct_alert, - HandshakeMessage.ht_not_applicable), - RECORD_HELLO_REQUEST (Record.ct_handshake, - HandshakeMessage.ht_hello_request), - RECORD_CLIENT_HELLO (Record.ct_handshake, - HandshakeMessage.ht_client_hello), - RECORD_SERVER_HELLO (Record.ct_handshake, - HandshakeMessage.ht_server_hello), - RECORD_HELLO_VERIFY_REQUEST (Record.ct_handshake, - HandshakeMessage.ht_hello_verify_request), - RECORD_NEW_SESSION_TICKET (Record.ct_handshake, - HandshakeMessage.ht_new_session_ticket), - RECORD_CERTIFICATE (Record.ct_handshake, - HandshakeMessage.ht_certificate), - RECORD_SERVER_KEY_EXCHANGE (Record.ct_handshake, - HandshakeMessage.ht_server_key_exchange), - RECORD_CERTIFICATE_REQUEST (Record.ct_handshake, - HandshakeMessage.ht_certificate_request), - RECORD_SERVER_HELLO_DONE (Record.ct_handshake, - HandshakeMessage.ht_server_hello_done), - RECORD_CERTIFICATE_VERIFY (Record.ct_handshake, - HandshakeMessage.ht_certificate_verify), - RECORD_CLIENT_KEY_EXCHANGE (Record.ct_handshake, - HandshakeMessage.ht_client_key_exchange), - RECORD_FINISHED (Record.ct_handshake, - HandshakeMessage.ht_finished), - RECORD_CERTIFICATE_URL (Record.ct_handshake, - HandshakeMessage.ht_certificate_url), - RECORD_CERTIFICATE_STATUS (Record.ct_handshake, - HandshakeMessage.ht_certificate_status), - RECORD_SUPPLIEMENTAL_DATA (Record.ct_handshake, - HandshakeMessage.ht_supplemental_data), - RECORD_APPLICATION_DATA (Record.ct_application_data, - HandshakeMessage.ht_not_applicable); - - byte contentType; - byte handshakeType; - - private RecordType(byte contentType, byte handshakeType) { - this.contentType = contentType; - this.handshakeType = handshakeType; - } - - static RecordType valueOf(byte contentType, byte handshakeType) { - if (contentType == Record.ct_change_cipher_spec) { - return RECORD_CHANGE_CIPHER_SPEC; - } else if (contentType == Record.ct_alert) { - return RECORD_ALERT; - } else if (contentType == Record.ct_application_data) { - return RECORD_APPLICATION_DATA; - } else if (handshakeType == HandshakeMessage.ht_hello_request) { - return RECORD_HELLO_REQUEST; - } else if (handshakeType == HandshakeMessage.ht_client_hello) { - return RECORD_CLIENT_HELLO; - } else if (handshakeType == HandshakeMessage.ht_server_hello) { - return RECORD_SERVER_HELLO; - } else if (handshakeType == HandshakeMessage.ht_hello_verify_request) { - return RECORD_HELLO_VERIFY_REQUEST; - } else if (handshakeType == HandshakeMessage.ht_new_session_ticket) { - return RECORD_NEW_SESSION_TICKET; - } else if (handshakeType == HandshakeMessage.ht_certificate) { - return RECORD_CERTIFICATE; - } else if (handshakeType == HandshakeMessage.ht_server_key_exchange) { - return RECORD_SERVER_KEY_EXCHANGE; - } else if (handshakeType == HandshakeMessage.ht_certificate_request) { - return RECORD_CERTIFICATE_REQUEST; - } else if (handshakeType == HandshakeMessage.ht_server_hello_done) { - return RECORD_SERVER_HELLO_DONE; - } else if (handshakeType == HandshakeMessage.ht_certificate_verify) { - return RECORD_CERTIFICATE_VERIFY; - } else if (handshakeType == HandshakeMessage.ht_client_key_exchange) { - return RECORD_CLIENT_KEY_EXCHANGE; - } else if (handshakeType == HandshakeMessage.ht_finished) { - return RECORD_FINISHED; - } else if (handshakeType == HandshakeMessage.ht_certificate_url) { - return RECORD_CERTIFICATE_URL; - } else if (handshakeType == HandshakeMessage.ht_certificate_status) { - return RECORD_CERTIFICATE_STATUS; - } else if (handshakeType == HandshakeMessage.ht_supplemental_data) { - return RECORD_SUPPLIEMENTAL_DATA; - } - - // otherwise, invalid record type - throw new IllegalArgumentException( - "Invalid record type (ContentType:" + contentType + - ", HandshakeType:" + handshakeType + ")"); - } -} diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/ServerHandshaker.java b/jdk/src/java.base/share/classes/sun/security/ssl/ServerHandshaker.java index 4ad18b163e5..85b96cd3f8b 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/ServerHandshaker.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/ServerHandshaker.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -96,7 +96,7 @@ final class ServerHandshaker extends Handshaker { private ProtocolVersion clientRequestedVersion; // client supported elliptic curves - private EllipticCurvesExtension requestedCurves; + private SupportedGroupsExtension requestedGroups; // the preferable signature algorithm used by ServerKeyExchange message SignatureAndHashAlgorithm preferableSignatureAlgorithm; @@ -751,8 +751,8 @@ final class ServerHandshaker extends Handshaker { throw new SSLException("Client did not resume a session"); } - requestedCurves = (EllipticCurvesExtension) - mesg.extensions.get(ExtensionType.EXT_ELLIPTIC_CURVES); + requestedGroups = (SupportedGroupsExtension) + mesg.extensions.get(ExtensionType.EXT_SUPPORTED_GROUPS); // We only need to handle the "signature_algorithm" extension // for full handshakes and TLS 1.2 or later. @@ -1341,6 +1341,8 @@ final class ServerHandshaker extends Handshaker { } } + // The named group used for ECDHE and FFDHE. + NamedGroup namedGroup = null; switch (keyExchange) { case K_RSA: // need RSA certs for authentication @@ -1366,6 +1368,37 @@ final class ServerHandshaker extends Handshaker { } break; case K_DHE_RSA: + // Is ephemeral DH cipher suite usable for the connection? + // + // [RFC 7919] If a compatible TLS server receives a Supported + // Groups extension from a client that includes any FFDHE group + // (i.e., any codepoint between 256 and 511, inclusive, even if + // unknown to the server), and if none of the client-proposed + // FFDHE groups are known and acceptable to the server, then + // the server MUST NOT select an FFDHE cipher suite. In this + // case, the server SHOULD select an acceptable non-FFDHE cipher + // suite from the client's offered list. If the extension is + // present with FFDHE groups, none of the client's offered + // groups are acceptable by the server, and none of the client's + // proposed non-FFDHE cipher suites are acceptable to the server, + // the server MUST end the connection with a fatal TLS alert + // of type insufficient_security(71). + // + // Note: For compatibility, if an application is customized to + // use legacy sizes (512 bits for exportable cipher suites and + // 768 bits for others), or the cipher suite is exportable, the + // FFDHE extension will not be used. + if ((!useLegacyEphemeralDHKeys) && (!suite.exportable) && + (requestedGroups != null) && requestedGroups.hasFFDHEGroup()) { + + namedGroup = requestedGroups.getPreferredGroup( + algorithmConstraints, NamedGroupType.NAMED_GROUP_FFDHE); + if (namedGroup == null) { + // no match found, cannot use this cipher suite. + return false; + } + } + // need RSA certs for authentication if (setupPrivateKeyAndChain("RSA") == false) { return false; @@ -1386,9 +1419,20 @@ final class ServerHandshaker extends Handshaker { } } - setupEphemeralDHKeys(suite.exportable, privateKey); + setupEphemeralDHKeys(namedGroup, suite.exportable, privateKey); break; case K_ECDHE_RSA: + // Is ECDHE cipher suite usable for the connection? + namedGroup = (requestedGroups != null) ? + requestedGroups.getPreferredGroup( + algorithmConstraints, NamedGroupType.NAMED_GROUP_ECDHE) : + SupportedGroupsExtension.getPreferredECGroup( + algorithmConstraints); + if (namedGroup == null) { + // no match found, cannot use this ciphersuite + return false; + } + // need RSA certs for authentication if (setupPrivateKeyAndChain("RSA") == false) { return false; @@ -1409,11 +1453,23 @@ final class ServerHandshaker extends Handshaker { } } - if (setupEphemeralECDHKeys() == false) { - return false; - } + setupEphemeralECDHKeys(namedGroup); break; case K_DHE_DSS: + // Is ephemeral DH cipher suite usable for the connection? + // + // See comment in K_DHE_RSA case. + if ((!useLegacyEphemeralDHKeys) && (!suite.exportable) && + (requestedGroups != null) && requestedGroups.hasFFDHEGroup()) { + + namedGroup = requestedGroups.getPreferredGroup( + algorithmConstraints, NamedGroupType.NAMED_GROUP_FFDHE); + if (namedGroup == null) { + // no match found, cannot use this cipher suite. + return false; + } + } + // get preferable peer signature algorithm for server key exchange if (protocolVersion.useTLS12PlusSpec()) { preferableSignatureAlgorithm = @@ -1434,9 +1490,20 @@ final class ServerHandshaker extends Handshaker { return false; } - setupEphemeralDHKeys(suite.exportable, privateKey); + setupEphemeralDHKeys(namedGroup, suite.exportable, privateKey); break; case K_ECDHE_ECDSA: + // Is ECDHE cipher suite usable for the connection? + namedGroup = (requestedGroups != null) ? + requestedGroups.getPreferredGroup( + algorithmConstraints, NamedGroupType.NAMED_GROUP_ECDHE) : + SupportedGroupsExtension.getPreferredECGroup( + algorithmConstraints); + if (namedGroup == null) { + // no match found, cannot use this ciphersuite + return false; + } + // get preferable peer signature algorithm for server key exchange if (protocolVersion.useTLS12PlusSpec()) { preferableSignatureAlgorithm = @@ -1456,9 +1523,8 @@ final class ServerHandshaker extends Handshaker { if (setupPrivateKeyAndChain("EC") == false) { return false; } - if (setupEphemeralECDHKeys() == false) { - return false; - } + + setupEphemeralECDHKeys(namedGroup); break; case K_ECDH_RSA: // need EC cert @@ -1475,14 +1541,36 @@ final class ServerHandshaker extends Handshaker { setupStaticECDHKeys(); break; case K_DH_ANON: + // Is ephemeral DH cipher suite usable for the connection? + // + // See comment in K_DHE_RSA case. + if ((!useLegacyEphemeralDHKeys) && (!suite.exportable) && + (requestedGroups != null) && requestedGroups.hasFFDHEGroup()) { + namedGroup = requestedGroups.getPreferredGroup( + algorithmConstraints, NamedGroupType.NAMED_GROUP_FFDHE); + if (namedGroup == null) { + // no match found, cannot use this cipher suite. + return false; + } + } + // no certs needed for anonymous - setupEphemeralDHKeys(suite.exportable, null); + setupEphemeralDHKeys(namedGroup, suite.exportable, null); break; case K_ECDH_ANON: - // no certs needed for anonymous - if (setupEphemeralECDHKeys() == false) { + // Is ECDHE cipher suite usable for the connection? + namedGroup = (requestedGroups != null) ? + requestedGroups.getPreferredGroup( + algorithmConstraints, NamedGroupType.NAMED_GROUP_ECDHE) : + SupportedGroupsExtension.getPreferredECGroup( + algorithmConstraints); + if (namedGroup == null) { + // no match found, cannot use this ciphersuite return false; } + + // no certs needed for anonymous + setupEphemeralECDHKeys(namedGroup); break; default: ClientKeyExchangeService p = @@ -1544,7 +1632,15 @@ final class ServerHandshaker extends Handshaker { * Acquire some "ephemeral" Diffie-Hellman keys for this handshake. * We don't reuse these, for improved forward secrecy. */ - private void setupEphemeralDHKeys(boolean export, Key key) { + private void setupEphemeralDHKeys( + NamedGroup namedGroup, boolean export, Key key) { + // Are the client and server willing to negotiate FFDHE groups? + if ((!useLegacyEphemeralDHKeys) && (!export) && (namedGroup != null)) { + dh = new DHCrypt(namedGroup, sslContext.getSecureRandom()); + + return; + } // Otherwise, the client is not compatible with FFDHE extension. + /* * 768 bits ephemeral DH private keys were used to be used in * ServerKeyExchange except that exportable ciphers max out at 512 @@ -1613,20 +1709,11 @@ final class ServerHandshaker extends Handshaker { dh = new DHCrypt(keySize, sslContext.getSecureRandom()); } - // Setup the ephemeral ECDH parameters. - // If we cannot continue because we do not support any of the curves that - // the client requested, return false. Otherwise (all is well), return true. - private boolean setupEphemeralECDHKeys() { - int index = (requestedCurves != null) ? - requestedCurves.getPreferredCurve(algorithmConstraints) : - EllipticCurvesExtension.getActiveCurves(algorithmConstraints); - if (index < 0) { - // no match found, cannot use this ciphersuite - return false; - } - - ecdh = new ECDHCrypt(index, sslContext.getSecureRandom()); - return true; + /** + * Setup the ephemeral ECDH parameters. + */ + private void setupEphemeralECDHKeys(NamedGroup namedGroup) { + ecdh = new ECDHCrypt(namedGroup, sslContext.getSecureRandom()); } private void setupStaticECDHKeys() { @@ -1674,9 +1761,11 @@ final class ServerHandshaker extends Handshaker { return false; } ECParameterSpec params = ((ECPublicKey)publicKey).getParams(); - int id = EllipticCurvesExtension.getCurveIndex(params); - if ((id <= 0) || !EllipticCurvesExtension.isSupported(id) || - ((requestedCurves != null) && !requestedCurves.contains(id))) { + NamedGroup namedGroup = NamedGroup.valueOf(params); + if ((namedGroup == null) || + (!SupportedGroupsExtension.supports(namedGroup)) || + ((requestedGroups != null) && + !requestedGroups.contains(namedGroup.id))) { return false; } } diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/SignatureAndHashAlgorithm.java b/jdk/src/java.base/share/classes/sun/security/ssl/SignatureAndHashAlgorithm.java index 8445a665da3..b9f11f851bf 100644 --- a/jdk/src/java.base/share/classes/sun/security/ssl/SignatureAndHashAlgorithm.java +++ b/jdk/src/java.base/share/classes/sun/security/ssl/SignatureAndHashAlgorithm.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -411,16 +411,12 @@ final class SignatureAndHashAlgorithm { "SHA1withRSA", --p); supports(HashAlgorithm.SHA1, SignatureAlgorithm.ECDSA, "SHA1withECDSA", --p); - - if (Security.getProvider("SunMSCAPI") == null) { - supports(HashAlgorithm.SHA224, SignatureAlgorithm.DSA, - "SHA224withDSA", --p); - supports(HashAlgorithm.SHA224, SignatureAlgorithm.RSA, - "SHA224withRSA", --p); - supports(HashAlgorithm.SHA224, SignatureAlgorithm.ECDSA, - "SHA224withECDSA", --p); - } - + supports(HashAlgorithm.SHA224, SignatureAlgorithm.DSA, + "SHA224withDSA", --p); + supports(HashAlgorithm.SHA224, SignatureAlgorithm.RSA, + "SHA224withRSA", --p); + supports(HashAlgorithm.SHA224, SignatureAlgorithm.ECDSA, + "SHA224withECDSA", --p); supports(HashAlgorithm.SHA256, SignatureAlgorithm.DSA, "SHA256withDSA", --p); supports(HashAlgorithm.SHA256, SignatureAlgorithm.RSA, diff --git a/jdk/src/java.base/share/classes/sun/security/ssl/SupportedGroupsExtension.java b/jdk/src/java.base/share/classes/sun/security/ssl/SupportedGroupsExtension.java new file mode 100644 index 00000000000..b33cc1e6e55 --- /dev/null +++ b/jdk/src/java.base/share/classes/sun/security/ssl/SupportedGroupsExtension.java @@ -0,0 +1,491 @@ +/* + * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package sun.security.ssl; + +import java.io.IOException; +import java.security.spec.ECGenParameterSpec; +import java.security.spec.InvalidParameterSpecException; +import java.security.AlgorithmParameters; +import java.security.AlgorithmConstraints; +import java.security.CryptoPrimitive; +import java.security.AccessController; +import java.security.spec.AlgorithmParameterSpec; +import javax.crypto.spec.DHParameterSpec; +import java.util.EnumSet; +import java.util.HashMap; +import java.util.Map; +import java.util.ArrayList; +import javax.net.ssl.SSLProtocolException; + +import sun.security.action.GetPropertyAction; + +// +// Note: Since RFC 7919, the extension's semantics are expanded from +// "Supported Elliptic Curves" to "Supported Groups". The enum datatype +// used in the extension has been renamed from NamedCurve to NamedGroup. +// Its semantics are likewise expanded from "named curve" to "named group". +// +final class SupportedGroupsExtension extends HelloExtension { + + /* Class and subclass dynamic debugging support */ + private static final Debug debug = Debug.getInstance("ssl"); + + private static final int ARBITRARY_PRIME = 0xff01; + private static final int ARBITRARY_CHAR2 = 0xff02; + + // cache to speed up the parameters construction + private static final Map namedGroupParams = new HashMap<>(); + + // the supported named groups + private static final NamedGroup[] supportedNamedGroups; + + // the named group presented in the extension + private final int[] requestedNamedGroupIds; + + static { + boolean requireFips = SunJSSE.isFIPS(); + + // The value of the System Property defines a list of enabled named + // groups in preference order, separated with comma. For example: + // + // jdk.tls.namedGroups="secp521r1, secp256r1, ffdhe2048" + // + // If the System Property is not defined or the value is empty, the + // default groups and preferences will be used. + String property = AccessController.doPrivileged( + new GetPropertyAction("jdk.tls.namedGroups")); + if (property != null && property.length() != 0) { + // remove double quote marks from beginning/end of the property + if (property.length() > 1 && property.charAt(0) == '"' && + property.charAt(property.length() - 1) == '"') { + property = property.substring(1, property.length() - 1); + } + } + + ArrayList groupList; + if (property != null && property.length() != 0) { // customized groups + String[] groups = property.split(","); + groupList = new ArrayList<>(groups.length); + for (String group : groups) { + group = group.trim(); + if (!group.isEmpty()) { + NamedGroup namedGroup = NamedGroup.nameOf(group); + if (namedGroup != null && + (!requireFips || namedGroup.isFips)) { + if (isAvailableGroup(namedGroup)) { + groupList.add(namedGroup); + } + } // ignore unknown groups + } + } + + if (groupList.isEmpty() && JsseJce.isEcAvailable()) { + throw new IllegalArgumentException( + "System property jdk.tls.namedGroups(" + property + ") " + + "contains no supported elliptic curves"); + } + } else { // default groups + NamedGroup[] groups; + if (requireFips) { + groups = new NamedGroup[] { + // only NIST curves in FIPS mode + NamedGroup.SECP256_R1, + NamedGroup.SECP384_R1, + NamedGroup.SECP521_R1, + NamedGroup.SECT283_K1, + NamedGroup.SECT283_R1, + NamedGroup.SECT409_K1, + NamedGroup.SECT409_R1, + NamedGroup.SECT571_K1, + NamedGroup.SECT571_R1, + + // FFDHE 2048 + NamedGroup.FFDHE_2048, + NamedGroup.FFDHE_3072, + NamedGroup.FFDHE_4096, + NamedGroup.FFDHE_6144, + NamedGroup.FFDHE_8192, + }; + } else { + groups = new NamedGroup[] { + // NIST curves first + NamedGroup.SECP256_R1, + NamedGroup.SECP384_R1, + NamedGroup.SECP521_R1, + NamedGroup.SECT283_K1, + NamedGroup.SECT283_R1, + NamedGroup.SECT409_K1, + NamedGroup.SECT409_R1, + NamedGroup.SECT571_K1, + NamedGroup.SECT571_R1, + + // non-NIST curves + NamedGroup.SECP256_K1, + + // FFDHE 2048 + NamedGroup.FFDHE_2048, + NamedGroup.FFDHE_3072, + NamedGroup.FFDHE_4096, + NamedGroup.FFDHE_6144, + NamedGroup.FFDHE_8192, + }; + } + + groupList = new ArrayList<>(groups.length); + for (NamedGroup group : groups) { + if (isAvailableGroup(group)) { + groupList.add(group); + } + } + } + + if (debug != null && groupList.isEmpty()) { + Debug.log( + "Initialized [jdk.tls.namedGroups|default] list contains " + + "no available elliptic curves. " + + (property != null ? "(" + property + ")" : "[Default]")); + } + + supportedNamedGroups = new NamedGroup[groupList.size()]; + int i = 0; + for (NamedGroup namedGroup : groupList) { + supportedNamedGroups[i++] = namedGroup; + } + } + + // check whether the group is supported by the underlying providers + private static boolean isAvailableGroup(NamedGroup namedGroup) { + AlgorithmParameters params = null; + AlgorithmParameterSpec spec = null; + if ("EC".equals(namedGroup.algorithm)) { + if (namedGroup.oid != null) { + try { + params = JsseJce.getAlgorithmParameters("EC"); + spec = new ECGenParameterSpec(namedGroup.oid); + } catch (Exception e) { + return false; + } + } + } else if ("DiffieHellman".equals(namedGroup.algorithm)) { + try { + params = JsseJce.getAlgorithmParameters("DiffieHellman"); + spec = getFFDHEDHParameterSpec(namedGroup); + } catch (Exception e) { + return false; + } + } + + if ((params != null) && (spec != null)) { + try { + params.init(spec); + } catch (Exception e) { + return false; + } + + // cache the parameters + namedGroupParams.put(namedGroup, params); + + return true; + } + + return false; + } + + private static DHParameterSpec getFFDHEDHParameterSpec( + NamedGroup namedGroup) { + DHParameterSpec spec = null; + switch (namedGroup) { + case FFDHE_2048: + spec = PredefinedDHParameterSpecs.ffdheParams.get(2048); + break; + case FFDHE_3072: + spec = PredefinedDHParameterSpecs.ffdheParams.get(3072); + break; + case FFDHE_4096: + spec = PredefinedDHParameterSpecs.ffdheParams.get(4096); + break; + case FFDHE_6144: + spec = PredefinedDHParameterSpecs.ffdheParams.get(6144); + break; + case FFDHE_8192: + spec = PredefinedDHParameterSpecs.ffdheParams.get(8192); + } + + return spec; + } + + private static DHParameterSpec getPredefinedDHParameterSpec( + NamedGroup namedGroup) { + DHParameterSpec spec = null; + switch (namedGroup) { + case FFDHE_2048: + spec = PredefinedDHParameterSpecs.definedParams.get(2048); + break; + case FFDHE_3072: + spec = PredefinedDHParameterSpecs.definedParams.get(3072); + break; + case FFDHE_4096: + spec = PredefinedDHParameterSpecs.definedParams.get(4096); + break; + case FFDHE_6144: + spec = PredefinedDHParameterSpecs.definedParams.get(6144); + break; + case FFDHE_8192: + spec = PredefinedDHParameterSpecs.definedParams.get(8192); + } + + return spec; + } + + private SupportedGroupsExtension(int[] requestedNamedGroupIds) { + super(ExtensionType.EXT_SUPPORTED_GROUPS); + + this.requestedNamedGroupIds = requestedNamedGroupIds; + } + + SupportedGroupsExtension(HandshakeInStream s, int len) throws IOException { + super(ExtensionType.EXT_SUPPORTED_GROUPS); + + int k = s.getInt16(); + if (((len & 1) != 0) || (k == 0) || (k + 2 != len)) { + throw new SSLProtocolException("Invalid " + type + " extension"); + } + + // Note: unknown named group will be ignored later. + requestedNamedGroupIds = new int[k >> 1]; + for (int i = 0; i < requestedNamedGroupIds.length; i++) { + requestedNamedGroupIds[i] = s.getInt16(); + } + } + + // Get a local preferred supported ECDHE group permitted by the constraints. + static NamedGroup getPreferredECGroup(AlgorithmConstraints constraints) { + for (NamedGroup namedGroup : supportedNamedGroups) { + if ((namedGroup.type == NamedGroupType.NAMED_GROUP_ECDHE) && + constraints.permits(EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), + namedGroup.algorithm, namedGroupParams.get(namedGroup))) { + + return namedGroup; + } + } + + return null; + } + + // Is there any supported group permitted by the constraints? + static boolean isActivatable( + AlgorithmConstraints constraints, NamedGroupType type) { + + boolean hasFFDHEGroups = false; + for (NamedGroup namedGroup : supportedNamedGroups) { + if (namedGroup.type == type) { + if (constraints.permits( + EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), + namedGroup.algorithm, + namedGroupParams.get(namedGroup))) { + + return true; + } + + if (!hasFFDHEGroups && + (type == NamedGroupType.NAMED_GROUP_FFDHE)) { + + hasFFDHEGroups = true; + } + } + } + + // For compatibility, if no FFDHE groups are defined, the non-FFDHE + // compatible mode (using DHE cipher suite without FFDHE extension) + // is allowed. + // + // Note that the constraints checking on DHE parameters will be + // performed during key exchanging in a handshake. + if (!hasFFDHEGroups && (type == NamedGroupType.NAMED_GROUP_FFDHE)) { + return true; + } + + return false; + } + + // Create the default supported groups extension. + static SupportedGroupsExtension createExtension( + AlgorithmConstraints constraints, + CipherSuiteList cipherSuites, boolean enableFFDHE) { + + ArrayList groupList = + new ArrayList<>(supportedNamedGroups.length); + for (NamedGroup namedGroup : supportedNamedGroups) { + if ((!enableFFDHE) && + (namedGroup.type == NamedGroupType.NAMED_GROUP_FFDHE)) { + continue; + } + + if (cipherSuites.contains(namedGroup.type) && + constraints.permits(EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), + namedGroup.algorithm, namedGroupParams.get(namedGroup))) { + + groupList.add(namedGroup.id); + } + } + + if (!groupList.isEmpty()) { + int[] ids = new int[groupList.size()]; + int i = 0; + for (Integer id : groupList) { + ids[i++] = id; + } + + return new SupportedGroupsExtension(ids); + } + + return null; + } + + // get the preferred activated named group + NamedGroup getPreferredGroup( + AlgorithmConstraints constraints, NamedGroupType type) { + + for (int groupId : requestedNamedGroupIds) { + NamedGroup namedGroup = NamedGroup.valueOf(groupId); + if ((namedGroup != null) && (namedGroup.type == type) && + SupportedGroupsExtension.supports(namedGroup) && + constraints.permits(EnumSet.of(CryptoPrimitive.KEY_AGREEMENT), + namedGroup.algorithm, namedGroupParams.get(namedGroup))) { + + return namedGroup; + } + } + + return null; + } + + boolean hasFFDHEGroup() { + for (int groupId : requestedNamedGroupIds) { + /* + * [RFC 7919] Codepoints in the "Supported Groups Registry" + * with a high byte of 0x01 (that is, between 256 and 511, + * inclusive) are set aside for FFDHE groups. + */ + if ((groupId >= 256) && (groupId <= 511)) { + return true; + } + } + + return false; + } + + boolean contains(int index) { + for (int groupId : requestedNamedGroupIds) { + if (index == groupId) { + return true; + } + } + return false; + } + + @Override + int length() { + return 6 + (requestedNamedGroupIds.length << 1); + } + + @Override + void send(HandshakeOutStream s) throws IOException { + s.putInt16(type.id); + int k = requestedNamedGroupIds.length << 1; + s.putInt16(k + 2); + s.putInt16(k); + for (int groupId : requestedNamedGroupIds) { + s.putInt16(groupId); + } + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("Extension " + type + ", group names: {"); + boolean first = true; + for (int groupId : requestedNamedGroupIds) { + if (first) { + first = false; + } else { + sb.append(", "); + } + // first check if it is a known named group, then try other cases. + NamedGroup namedGroup = NamedGroup.valueOf(groupId); + if (namedGroup != null) { + sb.append(namedGroup.name); + } else if (groupId == ARBITRARY_PRIME) { + sb.append("arbitrary_explicit_prime_curves"); + } else if (groupId == ARBITRARY_CHAR2) { + sb.append("arbitrary_explicit_char2_curves"); + } else { + sb.append("unknown named group " + groupId); + } + } + sb.append("}"); + return sb.toString(); + } + + static boolean supports(NamedGroup namedGroup) { + for (NamedGroup group : supportedNamedGroups) { + if (namedGroup.id == group.id) { + return true; + } + } + + return false; + } + + static ECGenParameterSpec getECGenParamSpec(NamedGroup namedGroup) { + if (namedGroup.type != NamedGroupType.NAMED_GROUP_ECDHE) { + throw new RuntimeException("Not a named EC group: " + namedGroup); + } + + AlgorithmParameters params = namedGroupParams.get(namedGroup); + try { + return params.getParameterSpec(ECGenParameterSpec.class); + } catch (InvalidParameterSpecException ipse) { + // should be unlikely + return new ECGenParameterSpec(namedGroup.oid); + } + } + + static DHParameterSpec getDHParameterSpec(NamedGroup namedGroup) { + if (namedGroup.type != NamedGroupType.NAMED_GROUP_FFDHE) { + throw new RuntimeException("Not a named DH group: " + namedGroup); + } + + AlgorithmParameters params = namedGroupParams.get(namedGroup); + try { + return params.getParameterSpec(DHParameterSpec.class); + } catch (InvalidParameterSpecException ipse) { + // should be unlikely + return getPredefinedDHParameterSpec(namedGroup); + } + } +} diff --git a/jdk/src/java.base/share/classes/sun/security/tools/keytool/Main.java b/jdk/src/java.base/share/classes/sun/security/tools/keytool/Main.java index 53ea9706207..51a31da5e17 100644 --- a/jdk/src/java.base/share/classes/sun/security/tools/keytool/Main.java +++ b/jdk/src/java.base/share/classes/sun/security/tools/keytool/Main.java @@ -181,7 +181,7 @@ public final class Main { enum Command { CERTREQ("Generates.a.certificate.request", ALIAS, SIGALG, FILEOUT, KEYPASS, KEYSTORE, DNAME, - STOREPASS, STORETYPE, PROVIDERNAME, ADDPROVIDER, + EXT, STOREPASS, STORETYPE, PROVIDERNAME, ADDPROVIDER, PROVIDERCLASS, PROVIDERPATH, V, PROTECTED), CHANGEALIAS("Changes.an.entry.s.alias", ALIAS, DESTALIAS, KEYPASS, KEYSTORE, CACERTS, STOREPASS, @@ -250,12 +250,12 @@ public final class Main { KEYSTORE, STOREPASS, PROVIDERNAME, ADDPROVIDER, PROVIDERCLASS, PROVIDERPATH, V), SELFCERT("Generates.a.self.signed.certificate", - ALIAS, SIGALG, DNAME, STARTDATE, VALIDITY, KEYPASS, + ALIAS, SIGALG, DNAME, STARTDATE, EXT, VALIDITY, KEYPASS, STORETYPE, KEYSTORE, STOREPASS, PROVIDERNAME, ADDPROVIDER, PROVIDERCLASS, PROVIDERPATH, V), GENCRL("Generates.CRL", RFC, FILEOUT, ID, - ALIAS, SIGALG, EXT, KEYPASS, KEYSTORE, + ALIAS, SIGALG, KEYPASS, KEYSTORE, STOREPASS, STORETYPE, PROVIDERNAME, ADDPROVIDER, PROVIDERCLASS, PROVIDERPATH, V, PROTECTED), IDENTITYDB("Imports.entries.from.a.JDK.1.1.x.style.identity.database", @@ -485,7 +485,9 @@ public final class Main { if (c != null) { command = c; - } else if (collator.compare(flags, "-help") == 0) { + } else if (collator.compare(flags, "-help") == 0 || + collator.compare(flags, "-h") == 0 || + collator.compare(flags, "-?") == 0) { help = true; } else if (collator.compare(flags, "-conf") == 0) { i++; diff --git a/jdk/src/java.base/share/classes/sun/security/util/AlgorithmDecomposer.java b/jdk/src/java.base/share/classes/sun/security/util/AlgorithmDecomposer.java index 1774cabb8fb..4e1e6241dc5 100644 --- a/jdk/src/java.base/share/classes/sun/security/util/AlgorithmDecomposer.java +++ b/jdk/src/java.base/share/classes/sun/security/util/AlgorithmDecomposer.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,6 +27,8 @@ package sun.security.util; import java.util.HashSet; import java.util.Set; +import java.util.Arrays; +import java.util.Collection; import java.util.regex.Pattern; /** @@ -134,6 +136,23 @@ public class AlgorithmDecomposer { return elements; } + /** + * Get aliases of the specified algorithm. + * + * May support more algorithms in the future. + */ + public static Collection getAliases(String algorithm) { + String[] aliases; + if (algorithm.equalsIgnoreCase("DH") || + algorithm.equalsIgnoreCase("DiffieHellman")) { + aliases = new String[] {"DH", "DiffieHellman"}; + } else { + aliases = new String[] {algorithm}; + } + + return Arrays.asList(aliases); + } + private static void hasLoop(Set elements, String find, String replace) { if (elements.contains(find)) { if (!elements.contains(replace)) { diff --git a/jdk/src/java.base/share/classes/sun/security/util/Debug.java b/jdk/src/java.base/share/classes/sun/security/util/Debug.java index b8018c8fe21..134be05965a 100644 --- a/jdk/src/java.base/share/classes/sun/security/util/Debug.java +++ b/jdk/src/java.base/share/classes/sun/security/util/Debug.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,7 @@ package sun.security.util; +import java.io.PrintStream; import java.math.BigInteger; import java.util.regex.Pattern; import java.util.regex.Matcher; @@ -32,7 +33,7 @@ import java.util.Locale; import sun.security.action.GetPropertyAction; /** - * A utility class for debuging. + * A utility class for debugging. * * @author Roland Schemers */ @@ -118,6 +119,7 @@ public class Debug { System.err.println("The following can be used with certpath:"); System.err.println(); System.err.println("ocsp dump the OCSP protocol exchanges"); + System.err.println("verbose verbose debugging"); System.err.println(); System.err.println("Note: Separate multiple options with a comma"); System.exit(0); @@ -165,6 +167,13 @@ public class Debug { } } + /** + * Check if verbose messages is enabled for extra debugging. + */ + public static boolean isVerbose() { + return isOn("verbose"); + } + /** * print a message to stderr that is prefixed with the prefix * created from the call to getInstance. @@ -203,6 +212,13 @@ public class Debug { System.err.println(prefix + ": "+message); } + /** + * PrintStream for debug methods. Currently only System.err is supported. + */ + public PrintStream getPrintStream() { + return System.err; + } + /** * return a hexadecimal printed representation of the specified * BigInteger object. the value is formatted to fit on lines of diff --git a/jdk/src/java.base/share/classes/sun/security/util/DerInputBuffer.java b/jdk/src/java.base/share/classes/sun/security/util/DerInputBuffer.java index 54eade39044..acc0def2180 100644 --- a/jdk/src/java.base/share/classes/sun/security/util/DerInputBuffer.java +++ b/jdk/src/java.base/share/classes/sun/security/util/DerInputBuffer.java @@ -27,7 +27,6 @@ package sun.security.util; import java.io.ByteArrayInputStream; import java.io.IOException; -import java.io.OutputStream; import java.math.BigInteger; import java.util.Date; import sun.util.calendar.CalendarDate; @@ -275,7 +274,7 @@ class DerInputBuffer extends ByteArrayInputStream implements Cloneable { if (len > available()) throw new IOException("short read of DER Generalized Time"); - if (len < 13 || len > 23) + if (len < 13) throw new IOException("DER Generalized Time length error"); return getTime(len, true); @@ -350,7 +349,7 @@ class DerInputBuffer extends ByteArrayInputStream implements Cloneable { */ millis = 0; - if (len > 2 && len < 12) { + if (len > 2) { second = 10 * Character.digit((char)buf[pos++], 10); second += Character.digit((char)buf[pos++], 10); len -= 2; @@ -358,31 +357,30 @@ class DerInputBuffer extends ByteArrayInputStream implements Cloneable { if (buf[pos] == '.' || buf[pos] == ',') { len --; pos++; - // handle upto milisecond precision only int precision = 0; - int peek = pos; - while (buf[peek] != 'Z' && - buf[peek] != '+' && - buf[peek] != '-') { - peek++; + while (buf[pos] != 'Z' && + buf[pos] != '+' && + buf[pos] != '-') { + // Validate all digits in the fractional part but + // store millisecond precision only + int thisDigit = Character.digit((char)buf[pos], 10); precision++; + pos++; + switch (precision) { + case 1: + millis += 100 * thisDigit; + break; + case 2: + millis += 10 * thisDigit; + break; + case 3: + millis += thisDigit; + break; + } } - switch (precision) { - case 3: - millis += 100 * Character.digit((char)buf[pos++], 10); - millis += 10 * Character.digit((char)buf[pos++], 10); - millis += Character.digit((char)buf[pos++], 10); - break; - case 2: - millis += 100 * Character.digit((char)buf[pos++], 10); - millis += 10 * Character.digit((char)buf[pos++], 10); - break; - case 1: - millis += 100 * Character.digit((char)buf[pos++], 10); - break; - default: - throw new IOException("Parse " + type + - " time, unsupported precision for seconds value"); + if (precision == 0) { + throw new IOException("Parse " + type + + " time, empty fractional part"); } len -= precision; } diff --git a/jdk/src/java.base/share/classes/sun/security/util/DisabledAlgorithmConstraints.java b/jdk/src/java.base/share/classes/sun/security/util/DisabledAlgorithmConstraints.java index 9051b392970..43b4a83636a 100644 --- a/jdk/src/java.base/share/classes/sun/security/util/DisabledAlgorithmConstraints.java +++ b/jdk/src/java.base/share/classes/sun/security/util/DisabledAlgorithmConstraints.java @@ -45,6 +45,7 @@ import java.util.List; import java.util.Locale; import java.util.Map; import java.util.Set; +import java.util.Collection; import java.util.StringTokenizer; import java.util.TimeZone; import java.util.regex.Pattern; @@ -106,7 +107,15 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { @Override public final boolean permits(Set primitives, String algorithm, AlgorithmParameters parameters) { - return checkAlgorithm(disabledAlgorithms, algorithm, decomposer); + if (!checkAlgorithm(disabledAlgorithms, algorithm, decomposer)) { + return false; + } + + if (parameters != null) { + return algorithmConstraints.permits(algorithm, parameters); + } + + return true; } /* @@ -242,7 +251,12 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { List constraintList = constraintsMap.getOrDefault(algorithm, new ArrayList<>(1)); - constraintsMap.putIfAbsent(algorithm, constraintList); + + // Consider the impact of algorithm aliases. + for (String alias : AlgorithmDecomposer.getAliases(algorithm)) { + constraintsMap.putIfAbsent(alias, constraintList); + } + if (space <= 0) { constraintList.add(new DisabledConstraint(algorithm)); continue; @@ -351,6 +365,27 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { return true; } + // Check if constraints permit this AlgorithmParameters. + public boolean permits(String algorithm, AlgorithmParameters aps) { + List list = getConstraints(algorithm); + if (list == null) { + return true; + } + + for (Constraint constraint : list) { + if (!constraint.permits(aps)) { + if (debug != null) { + debug.println("keySizeConstraint: failed algorithm " + + "parameters constraint check " + aps); + } + + return false; + } + } + + return true; + } + // Check if constraints permit this cert. public void permits(String algorithm, ConstraintsParameters cp) throws CertPathValidatorException { @@ -444,6 +479,18 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { return true; } + /** + * Check if the algorithm constraint permits a given cryptographic + * parameters. + * + * @param parameters the cryptographic parameters + * @return 'true' if the cryptographic parameters is allowed, + * 'false' ortherwise. + */ + public boolean permits(AlgorithmParameters parameters) { + return true; + } + /** * Check if an algorithm constraint is permitted with a given * ConstraintsParameters. @@ -528,6 +575,7 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { * call next() for any following constraints. If it does not, exit * as this constraint(s) does not restrict the operation. */ + @Override public void permits(ConstraintsParameters cp) throws CertPathValidatorException { if (debug != null) { @@ -551,100 +599,101 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { * This class handles the denyAfter constraint. The date is in the UTC/GMT * timezone. */ - private static class DenyAfterConstraint extends Constraint { - private Date denyAfterDate; - private static final SimpleDateFormat dateFormat = - new SimpleDateFormat("EEE, MMM d HH:mm:ss z yyyy"); + private static class DenyAfterConstraint extends Constraint { + private Date denyAfterDate; + private static final SimpleDateFormat dateFormat = + new SimpleDateFormat("EEE, MMM d HH:mm:ss z yyyy"); - DenyAfterConstraint(String algo, int year, int month, int day) { - Calendar c; + DenyAfterConstraint(String algo, int year, int month, int day) { + Calendar c; - algorithm = algo; + algorithm = algo; - if (debug != null) { - debug.println("DenyAfterConstraint read in as: year " + - year + ", month = " + month + ", day = " + day); - } + if (debug != null) { + debug.println("DenyAfterConstraint read in as: year " + + year + ", month = " + month + ", day = " + day); + } - c = new Calendar.Builder().setTimeZone(TimeZone.getTimeZone("GMT")) - .setDate(year, month - 1, day).build(); + c = new Calendar.Builder().setTimeZone(TimeZone.getTimeZone("GMT")) + .setDate(year, month - 1, day).build(); - if (year > c.getActualMaximum(Calendar.YEAR) || - year < c.getActualMinimum(Calendar.YEAR)) { - throw new IllegalArgumentException( - "Invalid year given in constraint: " + year); - } - if ((month - 1) > c.getActualMaximum(Calendar.MONTH) || - (month - 1) < c.getActualMinimum(Calendar.MONTH)) { - throw new IllegalArgumentException( - "Invalid month given in constraint: " + month); - } - if (day > c.getActualMaximum(Calendar.DAY_OF_MONTH) || - day < c.getActualMinimum(Calendar.DAY_OF_MONTH)) { - throw new IllegalArgumentException( - "Invalid Day of Month given in constraint: " + day); - } + if (year > c.getActualMaximum(Calendar.YEAR) || + year < c.getActualMinimum(Calendar.YEAR)) { + throw new IllegalArgumentException( + "Invalid year given in constraint: " + year); + } + if ((month - 1) > c.getActualMaximum(Calendar.MONTH) || + (month - 1) < c.getActualMinimum(Calendar.MONTH)) { + throw new IllegalArgumentException( + "Invalid month given in constraint: " + month); + } + if (day > c.getActualMaximum(Calendar.DAY_OF_MONTH) || + day < c.getActualMinimum(Calendar.DAY_OF_MONTH)) { + throw new IllegalArgumentException( + "Invalid Day of Month given in constraint: " + day); + } - denyAfterDate = c.getTime(); - if (debug != null) { - debug.println("DenyAfterConstraint date set to: " + - dateFormat.format(denyAfterDate)); - } - } + denyAfterDate = c.getTime(); + if (debug != null) { + debug.println("DenyAfterConstraint date set to: " + + dateFormat.format(denyAfterDate)); + } + } - /* - * Checking that the provided date is not beyond the constraint date. - * The provided date can be the PKIXParameter date if given, - * otherwise it is the current date. - * - * If the constraint disallows, call next() for any following - * constraints. Throw an exception if this is the last constraint. - */ - @Override - public void permits(ConstraintsParameters cp) - throws CertPathValidatorException { - Date currentDate; - String errmsg; + /* + * Checking that the provided date is not beyond the constraint date. + * The provided date can be the PKIXParameter date if given, + * otherwise it is the current date. + * + * If the constraint disallows, call next() for any following + * constraints. Throw an exception if this is the last constraint. + */ + @Override + public void permits(ConstraintsParameters cp) + throws CertPathValidatorException { + Date currentDate; + String errmsg; - if (cp.getJARTimestamp() != null) { - currentDate = cp.getJARTimestamp().getTimestamp(); - errmsg = "JAR Timestamp date: "; - } else if (cp.getPKIXParamDate() != null) { - currentDate = cp.getPKIXParamDate(); - errmsg = "PKIXParameter date: "; - } else { - currentDate = new Date(); - errmsg = "Current date: "; - } + if (cp.getJARTimestamp() != null) { + currentDate = cp.getJARTimestamp().getTimestamp(); + errmsg = "JAR Timestamp date: "; + } else if (cp.getPKIXParamDate() != null) { + currentDate = cp.getPKIXParamDate(); + errmsg = "PKIXParameter date: "; + } else { + currentDate = new Date(); + errmsg = "Current date: "; + } - if (!denyAfterDate.after(currentDate)) { - if (next(cp)) { - return; - } - throw new CertPathValidatorException( - "denyAfter constraint check failed: " + algorithm + - " used with Constraint date: " + - dateFormat.format(denyAfterDate) + "; " + errmsg + - dateFormat.format(currentDate) + extendedMsg(cp), - null, null, -1, BasicReason.ALGORITHM_CONSTRAINED); - } - } + if (!denyAfterDate.after(currentDate)) { + if (next(cp)) { + return; + } + throw new CertPathValidatorException( + "denyAfter constraint check failed: " + algorithm + + " used with Constraint date: " + + dateFormat.format(denyAfterDate) + "; " + errmsg + + dateFormat.format(currentDate) + extendedMsg(cp), + null, null, -1, BasicReason.ALGORITHM_CONSTRAINED); + } + } - /* - * Return result if the constraint's date is beyond the current date - * in UTC timezone. - */ - public boolean permits(Key key) { - if (next(key)) { - return true; - } - if (debug != null) { - debug.println("DenyAfterConstraints.permits(): " + algorithm); - } + /* + * Return result if the constraint's date is beyond the current date + * in UTC timezone. + */ + @Override + public boolean permits(Key key) { + if (next(key)) { + return true; + } + if (debug != null) { + debug.println("DenyAfterConstraints.permits(): " + algorithm); + } - return denyAfterDate.after(new Date()); - } - } + return denyAfterDate.after(new Date()); + } + } /* * The usage constraint is for the "usage" keyword. It checks against the @@ -658,6 +707,7 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { this.usages = usages; } + @Override public void permits(ConstraintsParameters cp) throws CertPathValidatorException { for (String usage : usages) { @@ -674,12 +724,11 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { if (debug != null) { debug.println("Checking if usage constraint \"" + v + "\" matches \"" + cp.getVariant() + "\""); - // Because usage checking can come from many places - // a stack trace is very helpful. - ByteArrayOutputStream ba = new ByteArrayOutputStream(); - PrintStream ps = new PrintStream(ba); - (new Exception()).printStackTrace(ps); - debug.println(ba.toString()); + if (Debug.isVerbose()) { + // Because usage checking can come from many places + // a stack trace is very helpful. + (new Exception()).printStackTrace(debug.getPrintStream()); + } } if (cp.getVariant().compareTo(v) == 0) { if (next(cp)) { @@ -747,6 +796,7 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { * constraint Any permitted constraint will exit the linked list * to allow the operation. */ + @Override public void permits(ConstraintsParameters cp) throws CertPathValidatorException { Key key = null; @@ -770,6 +820,7 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { // Check if key constraint disable the specified key // Uses old style permit() + @Override public boolean permits(Key key) { // If we recursively find a constraint that permits us to use // this key, return true and skip any other constraint checks. @@ -783,6 +834,30 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { return permitsImpl(key); } + @Override + public boolean permits(AlgorithmParameters parameters) { + String paramAlg = parameters.getAlgorithm(); + if (!algorithm.equalsIgnoreCase(parameters.getAlgorithm())) { + // Consider the impact of the algorithm aliases. + Collection aliases = + AlgorithmDecomposer.getAliases(algorithm); + if (!aliases.contains(paramAlg)) { + return true; + } + } + + int keySize = KeyUtil.getKeySize(parameters); + if (keySize == 0) { + return false; + } else if (keySize > 0) { + return !((keySize < minSize) || (keySize > maxSize) || + (prohibitedSize == keySize)); + } // Otherwise, the key size is not accessible or determined. + // Conservatively, please don't disable such keys. + + return true; + } + private boolean permitsImpl(Key key) { // Verify this constraint is for this public key algorithm if (algorithm.compareToIgnoreCase(key.getAlgorithm()) != 0) { @@ -810,6 +885,7 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { algorithm = algo; } + @Override public void permits(ConstraintsParameters cp) throws CertPathValidatorException { throw new CertPathValidatorException( @@ -818,6 +894,7 @@ public class DisabledAlgorithmConstraints extends AbstractAlgorithmConstraints { null, null, -1, BasicReason.ALGORITHM_CONSTRAINED); } + @Override public boolean permits(Key key) { return false; } diff --git a/jdk/src/java.base/share/classes/sun/security/util/KeyUtil.java b/jdk/src/java.base/share/classes/sun/security/util/KeyUtil.java index 906d59cdb91..e477b9f8db3 100644 --- a/jdk/src/java.base/share/classes/sun/security/util/KeyUtil.java +++ b/jdk/src/java.base/share/classes/sun/security/util/KeyUtil.java @@ -25,6 +25,7 @@ package sun.security.util; +import java.security.AlgorithmParameters; import java.security.Key; import java.security.PrivilegedAction; import java.security.AccessController; @@ -35,6 +36,8 @@ import java.security.interfaces.DSAKey; import java.security.interfaces.DSAParams; import java.security.SecureRandom; import java.security.spec.KeySpec; +import java.security.spec.ECParameterSpec; +import java.security.spec.InvalidParameterSpecException; import javax.crypto.SecretKey; import javax.crypto.interfaces.DHKey; import javax.crypto.interfaces.DHPublicKey; @@ -99,6 +102,61 @@ public final class KeyUtil { return size; } + /** + * Returns the key size of the given cryptographic parameters in bits. + * + * @param parameters the cryptographic parameters, cannot be null + * @return the key size of the given cryptographic parameters in bits, + * or -1 if the key size is not accessible + */ + public static final int getKeySize(AlgorithmParameters parameters) { + + String algorithm = parameters.getAlgorithm(); + switch (algorithm) { + case "EC": + try { + ECKeySizeParameterSpec ps = parameters.getParameterSpec( + ECKeySizeParameterSpec.class); + if (ps != null) { + return ps.getKeySize(); + } + } catch (InvalidParameterSpecException ipse) { + // ignore + } + + try { + ECParameterSpec ps = parameters.getParameterSpec( + ECParameterSpec.class); + if (ps != null) { + return ps.getOrder().bitLength(); + } + } catch (InvalidParameterSpecException ipse) { + // ignore + } + + // Note: the ECGenParameterSpec case should be covered by the + // ECParameterSpec case above. + // See ECUtil.getECParameterSpec(Provider, String). + + break; + case "DiffieHellman": + try { + DHParameterSpec ps = parameters.getParameterSpec( + DHParameterSpec.class); + if (ps != null) { + return ps.getP().bitLength(); + } + } catch (InvalidParameterSpecException ipse) { + // ignore + } + break; + + // May support more AlgorithmParameters algorithms in the future. + } + + return -1; + } + /** * Returns whether the key is valid or not. *

    diff --git a/jdk/src/java.base/share/classes/sun/security/x509/X509CRLImpl.java b/jdk/src/java.base/share/classes/sun/security/x509/X509CRLImpl.java index 364d47b5f4d..271616e3b00 100644 --- a/jdk/src/java.base/share/classes/sun/security/x509/X509CRLImpl.java +++ b/jdk/src/java.base/share/classes/sun/security/x509/X509CRLImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -442,18 +442,6 @@ public class X509CRLImpl extends X509CRL implements DerEncoder { verifiedPublicKey = key; } - /** - * This static method is the default implementation of the - * verify(PublicKey key, Provider sigProvider) method in X509CRL. - * Called from java.security.cert.X509CRL.verify(PublicKey key, - * Provider sigProvider) - */ - public static void verify(X509CRL crl, PublicKey key, - Provider sigProvider) throws CRLException, - NoSuchAlgorithmException, InvalidKeyException, SignatureException { - crl.verify(key, sigProvider); - } - /** * Encodes an X.509 CRL, and signs it using the given key. * diff --git a/jdk/src/java.base/share/classes/sun/security/x509/X509CertImpl.java b/jdk/src/java.base/share/classes/sun/security/x509/X509CertImpl.java index 8d496ad85c4..8d3ccff9b3a 100644 --- a/jdk/src/java.base/share/classes/sun/security/x509/X509CertImpl.java +++ b/jdk/src/java.base/share/classes/sun/security/x509/X509CertImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -494,18 +494,6 @@ public class X509CertImpl extends X509Certificate implements DerEncoder { } } - /** - * This static method is the default implementation of the - * verify(PublicKey key, Provider sigProvider) method in X509Certificate. - * Called from java.security.cert.X509Certificate.verify(PublicKey key, - * Provider sigProvider) - */ - public static void verify(X509Certificate cert, PublicKey key, - Provider sigProvider) throws CertificateException, - NoSuchAlgorithmException, InvalidKeyException, SignatureException { - cert.verify(key, sigProvider); - } - /** * Creates an X.509 certificate, and signs it using the given key * (associating a signature algorithm and an X.500 name). diff --git a/jdk/src/java.base/share/classes/sun/util/calendar/AbstractCalendar.java b/jdk/src/java.base/share/classes/sun/util/calendar/AbstractCalendar.java index 85dddd42c5b..fa7667c2f48 100644 --- a/jdk/src/java.base/share/classes/sun/util/calendar/AbstractCalendar.java +++ b/jdk/src/java.base/share/classes/sun/util/calendar/AbstractCalendar.java @@ -63,9 +63,9 @@ public abstract class AbstractCalendar extends CalendarSystem { public Era getEra(String eraName) { if (eras != null) { - for (int i = 0; i < eras.length; i++) { - if (eras[i].equals(eraName)) { - return eras[i]; + for (Era era : eras) { + if (era.getName().equals(eraName)) { + return era; } } } diff --git a/jdk/src/java.base/share/native/launcher/defines.h b/jdk/src/java.base/share/native/launcher/defines.h index 4470ae5d466..1e4e35a044f 100644 --- a/jdk/src/java.base/share/native/launcher/defines.h +++ b/jdk/src/java.base/share/native/launcher/defines.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -44,17 +44,24 @@ #define DOT_VERSION "0.0" #ifdef JAVA_ARGS -#define HAS_JAVA_ARGS JNI_TRUE #ifdef PROGNAME static const char* const_progname = PROGNAME; #else static char* const_progname = NULL; #endif static const char* const_jargs[] = JAVA_ARGS; +#ifdef EXTRA_JAVA_ARGS +static const char* const_extra_jargs[] = EXTRA_JAVA_ARGS; +#else +static const char** const_extra_jargs = NULL; +#endif #else /* !JAVA_ARGS */ -#define HAS_JAVA_ARGS JNI_FALSE +#ifdef EXTRA_JAVA_ARGS +#error "EXTRA_JAVA_ARGS defined without JAVA_ARGS" +#endif static const char* const_progname = "java"; static const char** const_jargs = NULL; +static const char** const_extra_jargs = NULL; static const char* const_appclasspath[] = { NULL }; #endif /* JAVA_ARGS */ diff --git a/jdk/src/java.base/share/native/launcher/main.c b/jdk/src/java.base/share/native/launcher/main.c index 8e27a2a2ed9..5c743659fd4 100644 --- a/jdk/src/java.base/share/native/launcher/main.c +++ b/jdk/src/java.base/share/native/launcher/main.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -85,6 +85,8 @@ WinMain(HINSTANCE inst, HINSTANCE previnst, LPSTR cmdline, int cmdshow) { int margc; char** margv; + int jargc; + char** jargv; const jboolean const_javaw = JNI_TRUE; __initenv = _environ; @@ -95,10 +97,47 @@ main(int argc, char **argv) { int margc; char** margv; + int jargc; + char** jargv; const jboolean const_javaw = JNI_FALSE; #endif /* JAVAW */ + { + int i, main_jargc, extra_jargc; + JLI_List list; - JLI_InitArgProcessing(!HAS_JAVA_ARGS, const_disable_argfile); + main_jargc = (sizeof(const_jargs) / sizeof(char *)) > 1 + ? sizeof(const_jargs) / sizeof(char *) + : 0; // ignore the null terminator index + + extra_jargc = (sizeof(const_extra_jargs) / sizeof(char *)) > 1 + ? sizeof(const_extra_jargs) / sizeof(char *) + : 0; // ignore the null terminator index + + if (main_jargc > 0 && extra_jargc > 0) { // combine extra java args + jargc = main_jargc + extra_jargc; + list = JLI_List_new(jargc + 1); + + for (i = 0 ; i < extra_jargc; i++) { + JLI_List_add(list, JLI_StringDup(const_extra_jargs[i])); + } + + for (i = 0 ; i < main_jargc ; i++) { + JLI_List_add(list, JLI_StringDup(const_jargs[i])); + } + + // terminate the list + JLI_List_add(list, NULL); + jargv = list->elements; + } else if (extra_jargc > 0) { // should never happen + fprintf(stderr, "EXTRA_JAVA_ARGS defined without JAVA_ARGS"); + abort(); + } else { // no extra args, business as usual + jargc = main_jargc; + jargv = (char **) const_jargs; + } + } + + JLI_InitArgProcessing(jargc > 0, const_disable_argfile); #ifdef _WIN32 { @@ -164,12 +203,12 @@ main(int argc, char **argv) } #endif /* WIN32 */ return JLI_Launch(margc, margv, - sizeof(const_jargs) / sizeof(char *), const_jargs, + jargc, (const char**) jargv, 0, NULL, VERSION_STRING, DOT_VERSION, (const_progname != NULL) ? const_progname : *margv, (const_launcher != NULL) ? const_launcher : *margv, - HAS_JAVA_ARGS, + jargc > 0, const_cpwildcard, const_javaw, 0); } diff --git a/jdk/src/java.base/share/native/libjli/args.c b/jdk/src/java.base/share/native/libjli/args.c index 9eb2317de6c..3d11f1cffa8 100644 --- a/jdk/src/java.base/share/native/libjli/args.c +++ b/jdk/src/java.base/share/native/libjli/args.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -78,7 +78,7 @@ static size_t argsCount = 1; static jboolean stopExpansion = JNI_FALSE; static jboolean relaunch = JNI_FALSE; -void JLI_InitArgProcessing(jboolean isJava, jboolean disableArgFile) { +void JLI_InitArgProcessing(jboolean hasJavaArgs, jboolean disableArgFile) { // No expansion for relaunch if (argsCount != 1) { relaunch = JNI_TRUE; @@ -91,7 +91,7 @@ void JLI_InitArgProcessing(jboolean isJava, jboolean disableArgFile) { expectingNoDashArg = JNI_FALSE; // for tools, this value remains 0 all the time. - firstAppArgIndex = isJava ? NOT_FOUND : 0; + firstAppArgIndex = hasJavaArgs ? 0: NOT_FOUND; } int JLI_GetAppArgIndex() { diff --git a/jdk/src/java.base/share/native/libjli/java.c b/jdk/src/java.base/share/native/libjli/java.c index 927c09f5d14..e1c13354e80 100644 --- a/jdk/src/java.base/share/native/libjli/java.c +++ b/jdk/src/java.base/share/native/libjli/java.c @@ -129,7 +129,6 @@ static jboolean ValidateModules(JNIEnv* env); static void SetPaths(int argc, char **argv); static void DumpState(); -static jboolean RemovableOption(char *option); enum OptionKind { LAUNCHER_OPTION = 0, @@ -247,6 +246,10 @@ JLI_Launch(int argc, char ** argv, /* main argc, argc */ DumpState(); if (JLI_IsTraceLauncher()) { int i; + printf("Java args:\n"); + for (i = 0; i < jargc ; i++) { + printf("jargv[%d] = %s\n", i, jargv[i]); + } printf("Command line args:\n"); for (i = 0; i < argc ; i++) { printf("argv[%d] = %s\n", i, argv[i]); @@ -771,17 +774,16 @@ CheckJvmType(int *pargc, char ***argv, jboolean speculative) { } /* - * static void SetJvmEnvironment(int argc, char **argv); - * Is called just before the JVM is loaded. We can set env variables - * that are consumed by the JVM. This function is non-destructive, - * leaving the arg list intact. The first use is for the JVM flag - * -XX:NativeMemoryTracking=value. + * This method must be called before the VM is loaded, primarily + * used to parse and set any VM related options or env variables. + * This function is non-destructive leaving the argument list intact. */ static void SetJvmEnvironment(int argc, char **argv) { static const char* NMT_Env_Name = "NMT_LEVEL_"; int i; + /* process only the launcher arguments */ for (i = 0; i < argc; i++) { char *arg = argv[i]; /* @@ -840,11 +842,8 @@ SetJvmEnvironment(int argc, char **argv) { printf("TRACER_MARKER: NativeMemoryTracking: got value %s\n",envBuf); free(envName); } - } - } - } } @@ -1411,8 +1410,6 @@ ParseArguments(int *pargc, char ***pargv, ; /* Ignore machine independent options already handled */ } else if (ProcessPlatformOption(arg)) { ; /* Processing of platform dependent options */ - } else if (RemovableOption(arg)) { - ; /* Do not pass option to vm. */ } else { /* java.class.path set on the command line */ if (JLI_StrCCmp(arg, "-Djava.class.path=") == 0) { @@ -2333,34 +2330,6 @@ DumpState() printf("\tfullversion:%s\n", GetFullVersion()); } -/* - * Return JNI_TRUE for an option string that has no effect but should - * _not_ be passed on to the vm; return JNI_FALSE otherwise. On - * Solaris SPARC, this screening needs to be done if: - * -d32 or -d64 is passed to a binary with an unmatched data model - * (the exec in CreateExecutionEnvironment removes -d options and points the - * exec to the proper binary). In the case of when the data model and the - * requested version is matched, an exec would not occur, and these options - * were erroneously passed to the vm. - */ -jboolean -RemovableOption(char * option) -{ - /* - * Unconditionally remove both -d32 and -d64 options since only - * the last such options has an effect; e.g. - * java -d32 -d64 -d32 -version - * is equivalent to - * java -d32 -version - */ - - if( (JLI_StrCCmp(option, "-d32") == 0 ) || - (JLI_StrCCmp(option, "-d64") == 0 ) ) - return JNI_TRUE; - else - return JNI_FALSE; -} - /* * A utility procedure to always print to stderr */ diff --git a/jdk/src/java.base/share/native/libjli/jli_util.h b/jdk/src/java.base/share/native/libjli/jli_util.h index b4e8a69b3eb..34b1c029509 100644 --- a/jdk/src/java.base/share/native/libjli/jli_util.h +++ b/jdk/src/java.base/share/native/libjli/jli_util.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -133,7 +133,7 @@ char *JLI_List_combine(JLI_List sl); char *JLI_List_join(JLI_List l, char sep); JLI_List JLI_List_split(const char *str, char sep); -void JLI_InitArgProcessing(jboolean isJava, jboolean disableArgFile); +void JLI_InitArgProcessing(jboolean hasJavaArgs, jboolean disableArgFile); JLI_List JLI_PreprocessArg(const char *arg); jboolean JLI_AddArgsFromEnvVar(JLI_List args, const char *var_name); diff --git a/jdk/src/java.base/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java b/jdk/src/java.base/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java new file mode 100644 index 00000000000..36e23bd7d6b --- /dev/null +++ b/jdk/src/java.base/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package sun.nio.ch; + +import java.nio.channels.spi.AsynchronousChannelProvider; + +/** + * Creates this platform's default AsynchronousChannelProvider + */ + +public class DefaultAsynchronousChannelProvider { + + /** + * Prevent instantiation. + */ + private DefaultAsynchronousChannelProvider() { } + + /** + * Returns the default AsynchronousChannelProvider. + */ + public static AsynchronousChannelProvider create() { + return new SolarisAsynchronousChannelProvider(); + } +} diff --git a/jdk/src/java.base/solaris/classes/sun/nio/ch/DefaultSelectorProvider.java b/jdk/src/java.base/solaris/classes/sun/nio/ch/DefaultSelectorProvider.java index 866d8d4c6bb..aa823e49378 100644 --- a/jdk/src/java.base/solaris/classes/sun/nio/ch/DefaultSelectorProvider.java +++ b/jdk/src/java.base/solaris/classes/sun/nio/ch/DefaultSelectorProvider.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,7 +42,6 @@ public class DefaultSelectorProvider { * Returns the default SelectorProvider. */ public static SelectorProvider create() { - return new sun.nio.ch.DevPollSelectorProvider(); + return new DevPollSelectorProvider(); } - } diff --git a/jdk/src/java.base/solaris/native/libnet/solaris_close.c b/jdk/src/java.base/solaris/native/libnet/solaris_close.c index 091dc00d251..087c988d26b 100644 --- a/jdk/src/java.base/solaris/native/libnet/solaris_close.c +++ b/jdk/src/java.base/solaris/native/libnet/solaris_close.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,6 +27,8 @@ #include #include #include +#include "jvm.h" +#include "net_util.h" /* Support for restartable system calls on Solaris. */ @@ -90,25 +92,22 @@ int NET_Poll(struct pollfd *ufds, unsigned int nfds, int timeout) { RESTARTABLE_RETURN_INT(poll(ufds, nfds, timeout)); } -int NET_Timeout0(int s, long timeout, long currentTime) { +int NET_Timeout(JNIEnv *env, int s, long timeout, jlong nanoTimeStamp) { int result; - struct timeval t; - long prevtime = currentTime, newtime; + jlong prevNanoTime = nanoTimeStamp; + jlong nanoTimeout = (jlong) timeout * NET_NSEC_PER_MSEC; struct pollfd pfd; pfd.fd = s; pfd.events = POLLIN; for(;;) { - result = poll(&pfd, 1, timeout); + result = poll(&pfd, 1, nanoTimeout / NET_NSEC_PER_MSEC); if (result < 0 && errno == EINTR) { - if (timeout > 0) { - gettimeofday(&t, NULL); - newtime = (t.tv_sec * 1000) + t.tv_usec /1000; - timeout -= newtime - prevtime; - if (timeout <= 0) - return 0; - prevtime = newtime; - } + jlong newNanoTime = JVM_NanoTime(env, 0); + nanoTimeout -= newNanoTime - prevNanoTime; + if (nanoTimeout < NET_NSEC_PER_MSEC) + return 0; + prevNanoTime = newNanoTime; } else { return result; } diff --git a/jdk/src/java.base/unix/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java b/jdk/src/java.base/unix/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java deleted file mode 100644 index 248c6a154d2..00000000000 --- a/jdk/src/java.base/unix/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * by Oracle in the LICENSE file that accompanied this code. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package sun.nio.ch; - -import java.nio.channels.spi.AsynchronousChannelProvider; -import sun.security.action.GetPropertyAction; - -/** - * Creates this platform's default asynchronous channel provider - */ - -public class DefaultAsynchronousChannelProvider { - - /** - * Prevent instantiation. - */ - private DefaultAsynchronousChannelProvider() { } - - @SuppressWarnings("unchecked") - private static AsynchronousChannelProvider createProvider(String cn) { - Class c; - try { - c = (Class)Class.forName(cn); - } catch (ClassNotFoundException x) { - throw new AssertionError(x); - } - try { - @SuppressWarnings("deprecation") - AsynchronousChannelProvider result = c.newInstance(); - return result; - } catch (IllegalAccessException | InstantiationException x) { - throw new AssertionError(x); - } - - } - - /** - * Returns the default AsynchronousChannelProvider. - */ - public static AsynchronousChannelProvider create() { - String osname = GetPropertyAction.privilegedGetProperty("os.name"); - if (osname.equals("SunOS")) - return createProvider("sun.nio.ch.SolarisAsynchronousChannelProvider"); - if (osname.equals("Linux")) - return createProvider("sun.nio.ch.LinuxAsynchronousChannelProvider"); - if (osname.contains("OS X")) - return createProvider("sun.nio.ch.BsdAsynchronousChannelProvider"); - if (osname.equals("AIX")) - return createProvider("sun.nio.ch.AixAsynchronousChannelProvider"); - throw new InternalError("platform not recognized"); - } -} diff --git a/jdk/src/java.base/unix/native/libjava/UnixFileSystem_md.c b/jdk/src/java.base/unix/native/libjava/UnixFileSystem_md.c index 77fe35dcee0..e3eae8bac17 100644 --- a/jdk/src/java.base/unix/native/libjava/UnixFileSystem_md.c +++ b/jdk/src/java.base/unix/native/libjava/UnixFileSystem_md.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -229,7 +229,16 @@ Java_java_io_UnixFileSystem_getLastModifiedTime(JNIEnv *env, jobject this, WITH_FIELD_PLATFORM_STRING(env, file, ids.path, path) { struct stat64 sb; if (stat64(path, &sb) == 0) { - rv = 1000 * (jlong)sb.st_mtime; +#if defined(_AIX) + rv = (jlong)sb.st_mtime * 1000; + rv += (jlong)sb.st_mtime_n / 1000000; +#elif defined(MACOSX) + rv = (jlong)sb.st_mtimespec.tv_sec * 1000; + rv += (jlong)sb.st_mtimespec.tv_nsec / 1000000; +#else + rv = (jlong)sb.st_mtim.tv_sec * 1000; + rv += (jlong)sb.st_mtim.tv_nsec / 1000000; +#endif } } END_PLATFORM_STRING(env, path); return rv; @@ -413,9 +422,16 @@ Java_java_io_UnixFileSystem_setLastModifiedTime(JNIEnv *env, jobject this, struct timeval tv[2]; /* Preserve access time */ +#if defined(_AIX) tv[0].tv_sec = sb.st_atime; - tv[0].tv_usec = 0; - + tv[0].tv_usec = sb.st_atime_n / 1000; +#elif defined(MACOSX) + tv[0].tv_sec = sb.st_atimespec.tv_sec; + tv[0].tv_usec = sb.st_atimespec.tv_nsec / 1000; +#else + tv[0].tv_sec = sb.st_atim.tv_sec; + tv[0].tv_usec = sb.st_atim.tv_nsec / 1000; +#endif /* Change last-modified time */ tv[1].tv_sec = time / 1000; tv[1].tv_usec = (time % 1000) * 1000; diff --git a/jdk/src/java.base/unix/native/libjli/java_md.h b/jdk/src/java.base/unix/native/libjli/java_md.h index f0eaa302bd3..cc3bb1194e1 100644 --- a/jdk/src/java.base/unix/native/libjli/java_md.h +++ b/jdk/src/java.base/unix/native/libjli/java_md.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -54,7 +54,7 @@ char *FindExecName(char *program); const char *SetExecname(char **argv); const char *GetExecName(); static jboolean GetJVMPath(const char *jrepath, const char *jvmtype, - char *jvmpath, jint jvmpathsize, int bitsWanted); + char *jvmpath, jint jvmpathsize); static jboolean GetJREPath(char *path, jint pathsize, jboolean speculative); #if defined(_AIX) diff --git a/jdk/src/java.base/unix/native/libjli/java_md_solinux.c b/jdk/src/java.base/unix/native/libjli/java_md_solinux.c index cb9afc09822..408b5378bfe 100644 --- a/jdk/src/java.base/unix/native/libjli/java_md_solinux.c +++ b/jdk/src/java.base/unix/native/libjli/java_md_solinux.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -62,9 +62,7 @@ * * The selection of the proper vm shared library to open depends on * several classes of command line options, including vm "flavor" - * options (-client, -server) and the data model options, -d32 and - * -d64, as well as a version specification which may have come from - * the command line or from the manifest of an executable jar file. + * options (-client, -server). * The vm selection options are not passed to the running * virtual machine; they must be screened out by the launcher. * @@ -120,34 +118,30 @@ * | * \|/ * ParseArguments - * (removes -d32 and -d64 if any, - * processes version options, - * creates argument list for vm, - * etc.) * | * | * \|/ * RequiresSetenv * Is LD_LIBRARY_PATH - * and friends set ? --> NO --> Have Desired Model ? NO --> Error/Exit - * YES YES --> Continue + * and friends set ? --> NO --> Continue + * YES * | * | * \|/ - * Path is desired JRE ? YES --> Have Desired Model ? NO --> Error/Exit - * NO YES --> Continue + * Path is desired JRE ? YES --> Continue + * NO * | * | * \|/ * Paths have well known - * jvm paths ? --> NO --> Have Desired Model ? NO --> Error/Exit - * YES YES --> Continue + * jvm paths ? --> NO --> Error/Exit + * YES * | * | * \|/ - * Does libjvm.so exit - * in any of them ? --> NO --> Have Desired Model ? NO --> Error/Exit - * YES YES --> Continue + * Does libjvm.so exist + * in any of them ? --> NO --> Continue + * YES * | * | * \|/ @@ -302,229 +296,97 @@ CreateExecutionEnvironment(int *pargc, char ***pargv, char jrepath[], jint so_jrepath, char jvmpath[], jint so_jvmpath, char jvmcfg[], jint so_jvmcfg) { - /* - * First, determine if we are running the desired data model. If we - * are running the desired data model, all the error messages - * associated with calling GetJREPath, ReadKnownVMs, etc. should be - * output, otherwise we simply exit with an error, as we no longer - * support dual data models. - */ - jboolean jvmpathExists; + + char * jvmtype = NULL; + int argc = *pargc; + char **argv = *pargv; + +#ifdef SETENV_REQUIRED + jboolean mustsetenv = JNI_FALSE; + char *runpath = NULL; /* existing effective LD_LIBRARY_PATH setting */ + char* new_runpath = NULL; /* desired new LD_LIBRARY_PATH string */ + char* newpath = NULL; /* path on new LD_LIBRARY_PATH */ + char* lastslash = NULL; + char** newenvp = NULL; /* current environment */ + size_t new_runpath_size; +#endif /* SETENV_REQUIRED */ /* Compute/set the name of the executable */ SetExecname(*pargv); - /* Check data model flags, and exec process, if needed */ - { - char * jvmtype = NULL; - int argc = *pargc; - char **argv = *pargv; - int running = CURRENT_DATA_MODEL; - /* - * As of jdk9, there is no support for dual mode operations, however - * for legacy error reporting purposes and until -d options are supported - * we need this. - */ - int wanted = running; -#ifdef SETENV_REQUIRED - jboolean mustsetenv = JNI_FALSE; - char *runpath = NULL; /* existing effective LD_LIBRARY_PATH setting */ - char* new_runpath = NULL; /* desired new LD_LIBRARY_PATH string */ - char* newpath = NULL; /* path on new LD_LIBRARY_PATH */ - char* lastslash = NULL; - char** newenvp = NULL; /* current environment */ - size_t new_runpath_size; -#ifdef __solaris__ - char* dmpath = NULL; /* data model specific LD_LIBRARY_PATH, - Solaris only */ -#endif /* __solaris__ */ -#endif /* SETENV_REQUIRED */ - - char** newargv = NULL; - int newargc = 0; - - /* - * Starting in 1.5, all unix platforms accept the -d32 and -d64 - * options. On platforms where only one data-model is supported - * (e.g. ia-64 Linux), using the flag for the other data model is - * an error and will terminate the program. - */ - - { /* open new scope to declare local variables */ - int i; - - newargv = (char **)JLI_MemAlloc((argc+1) * sizeof(char*)); - newargv[newargc++] = argv[0]; - - /* scan for data model arguments and remove from argument list; - last occurrence determines desired data model */ - for (i=1; i < argc; i++) { - - if (JLI_StrCmp(argv[i], "-J-d64") == 0 || JLI_StrCmp(argv[i], "-d64") == 0) { - wanted = 64; - continue; - } - if (JLI_StrCmp(argv[i], "-J-d32") == 0 || JLI_StrCmp(argv[i], "-d32") == 0) { - wanted = 32; - continue; - } - newargv[newargc++] = argv[i]; - - if (IsJavaArgs()) { - if (argv[i][0] != '-') continue; - } else { - if (JLI_StrCmp(argv[i], "-classpath") == 0 || JLI_StrCmp(argv[i], "-cp") == 0) { - i++; - if (i >= argc) break; - newargv[newargc++] = argv[i]; - continue; - } - if (argv[i][0] != '-') { i++; break; } - } - } - - /* copy rest of args [i .. argc) */ - while (i < argc) { - newargv[newargc++] = argv[i++]; - } - newargv[newargc] = NULL; - - /* - * newargv has all proper arguments here - */ - - argc = newargc; - argv = newargv; - } - - /* If the data model is not changing, it is an error if the - jvmpath does not exist */ - if (wanted == running) { - /* Find out where the JRE is that we will be using. */ - if (!GetJREPath(jrepath, so_jrepath, JNI_FALSE) ) { - JLI_ReportErrorMessage(JRE_ERROR1); - exit(2); - } - JLI_Snprintf(jvmcfg, so_jvmcfg, "%s%slib%s%sjvm.cfg", - jrepath, FILESEP, FILESEP, FILESEP); - /* Find the specified JVM type */ - if (ReadKnownVMs(jvmcfg, JNI_FALSE) < 1) { - JLI_ReportErrorMessage(CFG_ERROR7); - exit(1); - } - - jvmpath[0] = '\0'; - jvmtype = CheckJvmType(pargc, pargv, JNI_FALSE); - if (JLI_StrCmp(jvmtype, "ERROR") == 0) { - JLI_ReportErrorMessage(CFG_ERROR9); - exit(4); - } - - if (!GetJVMPath(jrepath, jvmtype, jvmpath, so_jvmpath, 0 )) { - JLI_ReportErrorMessage(CFG_ERROR8, jvmtype, jvmpath); - exit(4); - } - /* - * we seem to have everything we need, so without further ado - * we return back, otherwise proceed to set the environment. - */ -#ifdef SETENV_REQUIRED - mustsetenv = RequiresSetenv(jvmpath); - JLI_TraceLauncher("mustsetenv: %s\n", mustsetenv ? "TRUE" : "FALSE"); - - if (mustsetenv == JNI_FALSE) { - JLI_MemFree(newargv); - return; - } -#else - JLI_MemFree(newargv); - return; -#endif /* SETENV_REQUIRED */ - } else { /* do the same speculatively or exit */ - JLI_ReportErrorMessage(JRE_ERROR2, wanted); + /* Check to see if the jvmpath exists */ + /* Find out where the JRE is that we will be using. */ + if (!GetJREPath(jrepath, so_jrepath, JNI_FALSE)) { + JLI_ReportErrorMessage(JRE_ERROR1); + exit(2); + } + JLI_Snprintf(jvmcfg, so_jvmcfg, "%s%slib%sjvm.cfg", + jrepath, FILESEP, FILESEP); + /* Find the specified JVM type */ + if (ReadKnownVMs(jvmcfg, JNI_FALSE) < 1) { + JLI_ReportErrorMessage(CFG_ERROR7); exit(1); - } + } + + jvmpath[0] = '\0'; + jvmtype = CheckJvmType(pargc, pargv, JNI_FALSE); + if (JLI_StrCmp(jvmtype, "ERROR") == 0) { + JLI_ReportErrorMessage(CFG_ERROR9); + exit(4); + } + + if (!GetJVMPath(jrepath, jvmtype, jvmpath, so_jvmpath)) { + JLI_ReportErrorMessage(CFG_ERROR8, jvmtype, jvmpath); + exit(4); + } + /* + * we seem to have everything we need, so without further ado + * we return back, otherwise proceed to set the environment. + */ #ifdef SETENV_REQUIRED - if (mustsetenv) { - /* - * We will set the LD_LIBRARY_PATH as follows: - * - * o $JVMPATH (directory portion only) - * o $JRE/lib - * o $JRE/../lib - * - * followed by the user's previous effective LD_LIBRARY_PATH, if - * any. - */ + mustsetenv = RequiresSetenv(jvmpath); + JLI_TraceLauncher("mustsetenv: %s\n", mustsetenv ? "TRUE" : "FALSE"); -#ifdef __solaris__ - /* - * Starting in Solaris 7, ld.so.1 supports three LD_LIBRARY_PATH - * variables: - * - * 1. LD_LIBRARY_PATH -- used for 32 and 64 bit searches if - * data-model specific variables are not set. - * - * 2. LD_LIBRARY_PATH_64 -- overrides and replaces LD_LIBRARY_PATH - * for 64-bit binaries. - * The vm uses LD_LIBRARY_PATH to set the java.library.path system - * property. To shield the vm from the complication of multiple - * LD_LIBRARY_PATH variables, if the appropriate data model - * specific variable is set, we will act as if LD_LIBRARY_PATH had - * the value of the data model specific variant and the data model - * specific variant will be unset. Note that the variable for the - * *wanted* data model must be used (if it is set), not simply the - * current running data model. - */ + if (mustsetenv == JNI_FALSE) { + return; + } +#else + return; +#endif /* SETENV_REQUIRED */ - switch (wanted) { - case 0: - case 64: - dmpath = getenv("LD_LIBRARY_PATH_64"); - wanted = 64; - break; +#ifdef SETENV_REQUIRED + if (mustsetenv) { + /* + * We will set the LD_LIBRARY_PATH as follows: + * + * o $JVMPATH (directory portion only) + * o $JRE/lib + * o $JRE/../lib + * + * followed by the user's previous effective LD_LIBRARY_PATH, if + * any. + */ - default: - JLI_ReportErrorMessage(JRE_ERROR3, __LINE__); - exit(1); /* unknown value in wanted */ - break; - } + runpath = getenv(LD_LIBRARY_PATH); - /* - * If dmpath is NULL, the relevant data model specific variable is - * not set and normal LD_LIBRARY_PATH should be used. - */ - if (dmpath == NULL) { - runpath = getenv("LD_LIBRARY_PATH"); - } else { - runpath = dmpath; - } -#else /* ! __solaris__ */ - /* - * If not on Solaris, assume only a single LD_LIBRARY_PATH - * variable. - */ - runpath = getenv(LD_LIBRARY_PATH); -#endif /* __solaris__ */ - - /* runpath contains current effective LD_LIBRARY_PATH setting */ - { /* New scope to declare local variable */ - char *new_jvmpath = JLI_StringDup(jvmpath); - new_runpath_size = ((runpath != NULL) ? JLI_StrLen(runpath) : 0) + - 2 * JLI_StrLen(jrepath) + + /* runpath contains current effective LD_LIBRARY_PATH setting */ + { /* New scope to declare local variable */ + char *new_jvmpath = JLI_StringDup(jvmpath); + new_runpath_size = ((runpath != NULL) ? JLI_StrLen(runpath) : 0) + + 2 * JLI_StrLen(jrepath) + #ifdef AIX - /* On AIX we additionally need 'jli' in the path because ld doesn't support $ORIGIN. */ - JLI_StrLen(jrepath) + JLI_StrLen("/lib//jli:") + + /* On AIX we additionally need 'jli' in the path because ld doesn't support $ORIGIN. */ + JLI_StrLen(jrepath) + JLI_StrLen("/lib//jli:") + #endif - JLI_StrLen(new_jvmpath) + 52; - new_runpath = JLI_MemAlloc(new_runpath_size); - newpath = new_runpath + JLI_StrLen(LD_LIBRARY_PATH "="); + JLI_StrLen(new_jvmpath) + 52; + new_runpath = JLI_MemAlloc(new_runpath_size); + newpath = new_runpath + JLI_StrLen(LD_LIBRARY_PATH "="); - /* - * Create desired LD_LIBRARY_PATH value for target data model. - */ - { + /* + * Create desired LD_LIBRARY_PATH value for target data model. + */ + { /* remove the name of the .so from the JVM path */ lastslash = JLI_StrRChr(new_jvmpath, '/'); if (lastslash) @@ -555,85 +417,66 @@ CreateExecutionEnvironment(int *pargc, char ***pargv, */ if (runpath != NULL && JLI_StrNCmp(newpath, runpath, JLI_StrLen(newpath)) == 0 && - (runpath[JLI_StrLen(newpath)] == 0 || runpath[JLI_StrLen(newpath)] == ':') && - (running == wanted) /* data model does not have to be changed */ -#ifdef __solaris__ - && (dmpath == NULL) /* data model specific variables not set */ -#endif /* __solaris__ */ - ) { - JLI_MemFree(newargv); + (runpath[JLI_StrLen(newpath)] == 0 || + runpath[JLI_StrLen(newpath)] == ':')) { JLI_MemFree(new_runpath); return; } - } } - - /* - * Place the desired environment setting onto the prefix of - * LD_LIBRARY_PATH. Note that this prevents any possible infinite - * loop of execv() because we test for the prefix, above. - */ - if (runpath != 0) { - /* ensure storage for runpath + colon + NULL */ - if ((JLI_StrLen(runpath) + 1 + 1) > new_runpath_size) { - JLI_ReportErrorMessageSys(JRE_ERROR11); - exit(1); - } - JLI_StrCat(new_runpath, ":"); - JLI_StrCat(new_runpath, runpath); - } - - if (putenv(new_runpath) != 0) { - exit(1); /* problem allocating memory; LD_LIBRARY_PATH not set - properly */ - } - - /* - * Unix systems document that they look at LD_LIBRARY_PATH only - * once at startup, so we have to re-exec the current executable - * to get the changed environment variable to have an effect. - */ - -#ifdef __solaris__ - /* - * If dmpath is not NULL, remove the data model specific string - * in the environment for the exec'ed child. - */ - if (dmpath != NULL) - (void)UnsetEnv("LD_LIBRARY_PATH_64"); -#endif /* __solaris */ - - newenvp = environ; } -#endif /* SETENV_REQUIRED */ - { - char *newexec = execname; - JLI_TraceLauncher("TRACER_MARKER:About to EXEC\n"); - (void) fflush(stdout); - (void) fflush(stderr); -#ifdef SETENV_REQUIRED - if (mustsetenv) { - execve(newexec, argv, newenvp); - } else { - execv(newexec, argv); + + /* + * Place the desired environment setting onto the prefix of + * LD_LIBRARY_PATH. Note that this prevents any possible infinite + * loop of execv() because we test for the prefix, above. + */ + if (runpath != 0) { + /* ensure storage for runpath + colon + NULL */ + if ((JLI_StrLen(runpath) + 1 + 1) > new_runpath_size) { + JLI_ReportErrorMessageSys(JRE_ERROR11); + exit(1); } -#else /* !SETENV_REQUIRED */ - execv(newexec, argv); -#endif /* SETENV_REQUIRED */ - JLI_ReportErrorMessageSys(JRE_ERROR4, newexec); + JLI_StrCat(new_runpath, ":"); + JLI_StrCat(new_runpath, runpath); } - exit(1); + + if (putenv(new_runpath) != 0) { + /* problem allocating memory; LD_LIBRARY_PATH not set properly */ + exit(1); + } + + /* + * Unix systems document that they look at LD_LIBRARY_PATH only + * once at startup, so we have to re-exec the current executable + * to get the changed environment variable to have an effect. + */ + + newenvp = environ; } +#endif /* SETENV_REQUIRED */ + { + char *newexec = execname; + JLI_TraceLauncher("TRACER_MARKER:About to EXEC\n"); + (void) fflush(stdout); + (void) fflush(stderr); +#ifdef SETENV_REQUIRED + if (mustsetenv) { + execve(newexec, argv, newenvp); + } else { + execv(newexec, argv); + } +#else /* !SETENV_REQUIRED */ + execv(newexec, argv); +#endif /* SETENV_REQUIRED */ + JLI_ReportErrorMessageSys(JRE_ERROR4, newexec); + } + exit(1); } -/* - * On Solaris VM choosing is done by the launcher (java.c), - * bitsWanted is used by MacOSX, on Solaris and Linux this. - * parameter is unused. - */ + static jboolean GetJVMPath(const char *jrepath, const char *jvmtype, - char *jvmpath, jint jvmpathsize, int bitsWanted) + char *jvmpath, jint jvmpathsize) { struct stat s; diff --git a/jdk/src/java.base/unix/native/libnet/Inet4AddressImpl.c b/jdk/src/java.base/unix/native/libnet/Inet4AddressImpl.c index 385b319391b..829ad20c0a5 100644 --- a/jdk/src/java.base/unix/native/libnet/Inet4AddressImpl.c +++ b/jdk/src/java.base/unix/native/libnet/Inet4AddressImpl.c @@ -46,7 +46,13 @@ extern jobjectArray lookupIfLocalhost(JNIEnv *env, const char *hostname, jboolea #define NI_MAXHOST 1025 #endif -/************************************************************************ +#define SET_NONBLOCKING(fd) { \ + int flags = fcntl(fd, F_GETFL); \ + flags |= O_NONBLOCK; \ + fcntl(fd, F_SETFL, flags); \ +} + +/* * Inet4AddressImpl */ @@ -57,35 +63,26 @@ extern jobjectArray lookupIfLocalhost(JNIEnv *env, const char *hostname, jboolea */ JNIEXPORT jstring JNICALL Java_java_net_Inet4AddressImpl_getLocalHostName(JNIEnv *env, jobject this) { - char hostname[NI_MAXHOST+1]; + char hostname[NI_MAXHOST + 1]; hostname[0] = '\0'; - if (gethostname(hostname, NI_MAXHOST)) { - /* Something went wrong, maybe networking is not setup? */ + if (gethostname(hostname, NI_MAXHOST) != 0) { strcpy(hostname, "localhost"); } else { + // try to resolve hostname via nameservice + // if it is known but getnameinfo fails, hostname will still be the + // value from gethostname struct addrinfo hints, *res; - int error; + // make sure string is null-terminated hostname[NI_MAXHOST] = '\0'; memset(&hints, 0, sizeof(hints)); hints.ai_flags = AI_CANONNAME; hints.ai_family = AF_INET; - error = getaddrinfo(hostname, NULL, &hints, &res); - - if (error == 0) {/* host is known to name service */ - getnameinfo(res->ai_addr, - res->ai_addrlen, - hostname, - NI_MAXHOST, - NULL, - 0, - NI_NAMEREQD); - - /* if getnameinfo fails hostname is still the value - from gethostname */ - + if (getaddrinfo(hostname, NULL, &hints, &res) == 0) { + getnameinfo(res->ai_addr, res->ai_addrlen, hostname, NI_MAXHOST, + NULL, 0, NI_NAMEREQD); freeaddrinfo(res); } } @@ -93,89 +90,70 @@ Java_java_net_Inet4AddressImpl_getLocalHostName(JNIEnv *env, jobject this) { } /* - * Find an internet address for a given hostname. Note that this + * Find an internet address for a given hostname. Note that this * code only works for addresses of type INET. The translation * of %d.%d.%d.%d to an address (int) occurs in java now, so the - * String "host" shouldn't *ever* be a %d.%d.%d.%d string + * String "host" shouldn't be a %d.%d.%d.%d string. The only + * exception should be when any of the %d are out of range and + * we fallback to a lookup. * * Class: java_net_Inet4AddressImpl * Method: lookupAllHostAddr * Signature: (Ljava/lang/String;)[[B */ - JNIEXPORT jobjectArray JNICALL Java_java_net_Inet4AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, - jstring host) { + jstring host) { + jobjectArray ret = NULL; const char *hostname; - jobjectArray ret = 0; - int retLen = 0; int error = 0; - struct addrinfo hints, *res, *resNew = NULL; + struct addrinfo hints, *res = NULL, *resNew = NULL, *last = NULL, + *iterator; initInetAddressIDs(env); JNU_CHECK_EXCEPTION_RETURN(env, NULL); if (IS_NULL(host)) { - JNU_ThrowNullPointerException(env, "host is null"); - return 0; + JNU_ThrowNullPointerException(env, "host argument is null"); + return NULL; } hostname = JNU_GetStringPlatformChars(env, host, JNI_FALSE); CHECK_NULL_RETURN(hostname, NULL); - /* Try once, with our static buffer. */ + // try once, with our static buffer memset(&hints, 0, sizeof(hints)); hints.ai_flags = AI_CANONNAME; hints.ai_family = AF_INET; -#ifdef __solaris__ - /* - * Workaround for Solaris bug 4160367 - if a hostname contains a - * white space then 0.0.0.0 is returned - */ - if (isspace((unsigned char)hostname[0])) { - JNU_ThrowByName(env, JNU_JAVANETPKG "UnknownHostException", - (char *)hostname); - JNU_ReleaseStringPlatformChars(env, host, hostname); - return NULL; - } -#endif - error = getaddrinfo(hostname, NULL, &hints, &res); -#ifdef MACOSX if (error) { +#if defined(MACOSX) // If getaddrinfo fails try getifaddrs, see bug 8170910. ret = lookupIfLocalhost(env, hostname, JNI_FALSE); if (ret != NULL || (*env)->ExceptionCheck(env)) { - JNU_ReleaseStringPlatformChars(env, host, hostname); - return ret; + goto cleanupAndReturn; } - } #endif - - if (error) { - /* report error */ + // report error NET_ThrowUnknownHostExceptionWithGaiError(env, hostname, error); - JNU_ReleaseStringPlatformChars(env, host, hostname); - return NULL; + goto cleanupAndReturn; } else { int i = 0; - struct addrinfo *itr, *last = NULL, *iterator = res; - + iterator = res; while (iterator != NULL) { - // remove the duplicate one + // skip duplicates int skip = 0; - itr = resNew; - while (itr != NULL) { + struct addrinfo *iteratorNew = resNew; + while (iteratorNew != NULL) { struct sockaddr_in *addr1, *addr2; addr1 = (struct sockaddr_in *)iterator->ai_addr; - addr2 = (struct sockaddr_in *)itr->ai_addr; - if (addr1->sin_addr.s_addr == - addr2->sin_addr.s_addr) { + addr2 = (struct sockaddr_in *)iteratorNew->ai_addr; + if (addr1->sin_addr.s_addr == addr2->sin_addr.s_addr) { skip = 1; break; } - itr = itr->ai_next; + iteratorNew = iteratorNew->ai_next; } if (!skip) { @@ -199,44 +177,37 @@ Java_java_net_Inet4AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, iterator = iterator->ai_next; } - retLen = i; - iterator = resNew; - - ret = (*env)->NewObjectArray(env, retLen, ia_class, NULL); - + // allocate array - at this point i contains the number of addresses + ret = (*env)->NewObjectArray(env, i, ia_class, NULL); if (IS_NULL(ret)) { - /* we may have memory to free at the end of this */ goto cleanupAndReturn; } i = 0; + iterator = resNew; while (iterator != NULL) { jobject iaObj = (*env)->NewObject(env, ia4_class, ia4_ctrID); if (IS_NULL(iaObj)) { ret = NULL; goto cleanupAndReturn; } - setInetAddress_addr(env, iaObj, ntohl(((struct sockaddr_in*)iterator->ai_addr)->sin_addr.s_addr)); + setInetAddress_addr(env, iaObj, ntohl(((struct sockaddr_in *) + (iterator->ai_addr))->sin_addr.s_addr)); setInetAddress_hostName(env, iaObj, host); (*env)->SetObjectArrayElement(env, ret, i++, iaObj); iterator = iterator->ai_next; } } - cleanupAndReturn: - { - struct addrinfo *iterator, *tmp; - iterator = resNew; - while (iterator != NULL) { - tmp = iterator; - iterator = iterator->ai_next; - free(tmp); - } - JNU_ReleaseStringPlatformChars(env, host, hostname); + JNU_ReleaseStringPlatformChars(env, host, hostname); + while (resNew != NULL) { + last = resNew; + resNew = resNew->ai_next; + free(last); + } + if (res != NULL) { + freeaddrinfo(res); } - - freeaddrinfo(res); - return ret; } @@ -244,164 +215,243 @@ cleanupAndReturn: * Class: java_net_Inet4AddressImpl * Method: getHostByAddr * Signature: (I)Ljava/lang/String; + * + * Theoretically the UnknownHostException could be enriched with gai error + * information. But as it is silently ignored anyway, there's no need for this. + * It's only important that either a valid hostname is returned or an + * UnknownHostException is thrown. */ JNIEXPORT jstring JNICALL Java_java_net_Inet4AddressImpl_getHostByAddr(JNIEnv *env, jobject this, - jbyteArray addrArray) { + jbyteArray addrArray) { jstring ret = NULL; - - char host[NI_MAXHOST+1]; - int error = 0; - int len = 0; + char host[NI_MAXHOST + 1]; jbyte caddr[4]; - - struct sockaddr_in him4; - struct sockaddr *sa; - jint addr; + struct sockaddr_in sa; + + // construct a sockaddr_in structure + memset((char *)&sa, 0, sizeof(struct sockaddr_in)); (*env)->GetByteArrayRegion(env, addrArray, 0, 4, caddr); - addr = ((caddr[0]<<24) & 0xff000000); - addr |= ((caddr[1] <<16) & 0xff0000); - addr |= ((caddr[2] <<8) & 0xff00); + addr = ((caddr[0] << 24) & 0xff000000); + addr |= ((caddr[1] << 16) & 0xff0000); + addr |= ((caddr[2] << 8) & 0xff00); addr |= (caddr[3] & 0xff); - memset((void *) &him4, 0, sizeof(him4)); - him4.sin_addr.s_addr = htonl(addr); - him4.sin_family = AF_INET; - sa = (struct sockaddr *) &him4; - len = sizeof(him4); + sa.sin_addr.s_addr = htonl(addr); + sa.sin_family = AF_INET; - error = getnameinfo(sa, len, host, NI_MAXHOST, NULL, 0, NI_NAMEREQD); - - if (!error) { + if (getnameinfo((struct sockaddr *)&sa, sizeof(struct sockaddr_in), + host, NI_MAXHOST, NULL, 0, NI_NAMEREQD)) { + JNU_ThrowByName(env, "java/net/UnknownHostException", NULL); + } else { ret = (*env)->NewStringUTF(env, host); - } - - if (ret == NULL) { - JNU_ThrowByName(env, JNU_JAVANETPKG "UnknownHostException", NULL); + if (ret == NULL) { + JNU_ThrowByName(env, "java/net/UnknownHostException", NULL); + } } return ret; } -#define SET_NONBLOCKING(fd) { \ - int flags = fcntl(fd, F_GETFL); \ - flags |= O_NONBLOCK; \ - fcntl(fd, F_SETFL, flags); \ +/** + * ping implementation using tcp port 7 (echo) + */ +static jboolean +tcp_ping4(JNIEnv *env, SOCKETADDRESS *sa, SOCKETADDRESS *netif, jint timeout, + jint ttl) +{ + jint fd; + int connect_rv = -1; + + // open a TCP socket + fd = socket(AF_INET, SOCK_STREAM, 0); + if (fd == -1) { + // note: if you run out of fds, you may not be able to load + // the exception class, and get a NoClassDefFoundError instead. + NET_ThrowNew(env, errno, "Can't create socket"); + return JNI_FALSE; + } + + // set TTL + if (ttl > 0) { + setsockopt(fd, IPPROTO_IP, IP_TTL, &ttl, sizeof(ttl)); + } + + // A network interface was specified, so let's bind to it. + if (netif != NULL) { + if (bind(fd, &netif->sa, sizeof(struct sockaddr_in)) < 0) { + NET_ThrowNew(env, errno, "Can't bind socket"); + close(fd); + return JNI_FALSE; + } + } + + // Make the socket non blocking so we can use select/poll. + SET_NONBLOCKING(fd); + + sa->sa4.sin_port = htons(7); // echo port + connect_rv = NET_Connect(fd, &sa->sa, sizeof(struct sockaddr_in)); + + // connection established or refused immediately, either way it means + // we were able to reach the host! + if (connect_rv == 0 || errno == ECONNREFUSED) { + close(fd); + return JNI_TRUE; + } + + switch (errno) { + case ENETUNREACH: // Network Unreachable + case EAFNOSUPPORT: // Address Family not supported + case EADDRNOTAVAIL: // address is not available on the remote machine +#if defined(__linux__) || defined(_AIX) + // On some Linux versions, when a socket is bound to the loopback + // interface, connect will fail and errno will be set to EINVAL + // or EHOSTUNREACH. When that happens, don't throw an exception, + // just return false. + case EINVAL: + case EHOSTUNREACH: // No route to host +#endif + close(fd); + return JNI_FALSE; + case EINPROGRESS: // this is expected as we'll probably have to wait + break; + default: + NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", + "connect failed"); + close(fd); + return JNI_FALSE; + } + + timeout = NET_Wait(env, fd, NET_WAIT_CONNECT, timeout); + if (timeout >= 0) { + // connection has been established, check for error condition + socklen_t optlen = (socklen_t)sizeof(connect_rv); + if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&connect_rv, + &optlen) <0) + { + connect_rv = errno; + } + if (connect_rv == 0 || connect_rv == ECONNREFUSED) { + close(fd); + return JNI_TRUE; + } + } + close(fd); + return JNI_FALSE; } /** * ping implementation. - * Send a ICMP_ECHO_REQUEST packet every second until either the timeout - * expires or a answer is received. - * Returns true is an ECHO_REPLY is received, otherwise, false. + * Send an ICMP_ECHO_REQUEST packet every second until either the timeout + * expires or an answer is received. + * Returns true if an ECHO_REPLY is received, false otherwise. */ static jboolean -ping4(JNIEnv *env, jint fd, struct sockaddr_in* him, jint timeout, - struct sockaddr_in* netif, jint ttl) { - jint size; - jint n, hlen1, icmplen; +ping4(JNIEnv *env, jint fd, SOCKETADDRESS *sa, SOCKETADDRESS *netif, + jint timeout, jint ttl) +{ + jint n, size = 60 * 1024, hlen, tmout2, seq = 1; socklen_t len; - char sendbuf[1500]; - char recvbuf[1500]; + unsigned char sendbuf[1500], recvbuf[1500]; struct icmp *icmp; struct ip *ip; struct sockaddr_in sa_recv; jchar pid; - jint tmout2, seq = 1; struct timeval tv; - size_t plen; + size_t plen = ICMP_ADVLENMIN + sizeof(tv); - /* icmp_id is a 16 bit data type, therefore down cast the pid */ - pid = (jchar)getpid(); - size = 60*1024; setsockopt(fd, SOL_SOCKET, SO_RCVBUF, &size, sizeof(size)); - /* - * sets the ttl (max number of hops) - */ + + // sets the ttl (max number of hops) if (ttl > 0) { - setsockopt(fd, IPPROTO_IP, IP_TTL, &ttl, sizeof(ttl)); + setsockopt(fd, IPPROTO_IP, IP_TTL, &ttl, sizeof(ttl)); } - /* - * a specific interface was specified, so let's bind the socket - * to that interface to ensure the requests are sent only through it. - */ + + // a specific interface was specified, so let's bind the socket + // to that interface to ensure the requests are sent only through it. if (netif != NULL) { - if (bind(fd, (struct sockaddr*)netif, sizeof(struct sockaddr_in)) < 0) { - NET_ThrowNew(env, errno, "Can't bind socket"); - close(fd); - return JNI_FALSE; - } + if (bind(fd, &netif->sa, sizeof(struct sockaddr_in)) < 0) { + NET_ThrowNew(env, errno, "Can't bind socket"); + close(fd); + return JNI_FALSE; + } } - /* - * Make the socket non blocking so we can use select - */ + + // icmp_id is a 16 bit data type, therefore down cast the pid + pid = (jchar)getpid(); + + // Make the socket non blocking so we can use select SET_NONBLOCKING(fd); do { - /* - * create the ICMP request - */ - icmp = (struct icmp *) sendbuf; - icmp->icmp_type = ICMP_ECHO; - icmp->icmp_code = 0; - icmp->icmp_id = htons(pid); - icmp->icmp_seq = htons(seq); - seq++; - gettimeofday(&tv, NULL); - memcpy(icmp->icmp_data, &tv, sizeof(tv)); - plen = ICMP_ADVLENMIN + sizeof(tv); - icmp->icmp_cksum = 0; - icmp->icmp_cksum = in_cksum((u_short *)icmp, plen); - /* - * send it - */ - n = sendto(fd, sendbuf, plen, 0, (struct sockaddr *)him, - sizeof(struct sockaddr)); - if (n < 0 && errno != EINPROGRESS ) { -#ifdef __linux__ - if (errno != EINVAL && errno != EHOSTUNREACH) - /* - * On some Linux versions, when a socket is bound to the loopback - * interface, sendto will fail and errno will be set to - * EINVAL or EHOSTUNREACH. When that happens, don't throw an - * exception, just return false. - */ -#endif /*__linux__ */ - NET_ThrowNew(env, errno, "Can't send ICMP packet"); - close(fd); - return JNI_FALSE; - } - - tmout2 = timeout > 1000 ? 1000 : timeout; - do { - tmout2 = NET_Wait(env, fd, NET_WAIT_READ, tmout2); - if (tmout2 >= 0) { - len = sizeof(sa_recv); - n = recvfrom(fd, recvbuf, sizeof(recvbuf), 0, (struct sockaddr *)&sa_recv, &len); - ip = (struct ip*) recvbuf; - hlen1 = (ip->ip_hl) << 2; - icmp = (struct icmp *) (recvbuf + hlen1); - icmplen = n - hlen1; - /* - * We did receive something, but is it what we were expecting? - * I.E.: A ICMP_ECHOREPLY packet with the proper PID. - */ - if (icmplen >= 8 && icmp->icmp_type == ICMP_ECHOREPLY - && (ntohs(icmp->icmp_id) == pid)) { - if ((him->sin_addr.s_addr == sa_recv.sin_addr.s_addr)) { - close(fd); - return JNI_TRUE; + // create the ICMP request + icmp = (struct icmp *)sendbuf; + icmp->icmp_type = ICMP_ECHO; + icmp->icmp_code = 0; + // let's tag the ECHO packet with our pid so we can identify it + icmp->icmp_id = htons(pid); + icmp->icmp_seq = htons(seq); + seq++; + gettimeofday(&tv, NULL); + memcpy(icmp->icmp_data, &tv, sizeof(tv)); + icmp->icmp_cksum = 0; + // manually calculate checksum + icmp->icmp_cksum = in_cksum((u_short *)icmp, plen); + // send it + n = sendto(fd, sendbuf, plen, 0, &sa->sa, sizeof(struct sockaddr_in)); + if (n < 0 && errno != EINPROGRESS) { +#if defined(__linux__) + /* + * On some Linux versions, when a socket is bound to the loopback + * interface, sendto will fail and errno will be set to + * EINVAL or EHOSTUNREACH. When that happens, don't throw an + * exception, just return false. + */ + if (errno != EINVAL && errno != EHOSTUNREACH) { + NET_ThrowNew(env, errno, "Can't send ICMP packet"); } - - if (him->sin_addr.s_addr == 0) { - close(fd); - return JNI_TRUE; - } - } - +#else + NET_ThrowNew(env, errno, "Can't send ICMP packet"); +#endif + close(fd); + return JNI_FALSE; } - } while (tmout2 > 0); - timeout -= 1000; - } while (timeout >0); + + tmout2 = timeout > 1000 ? 1000 : timeout; + do { + tmout2 = NET_Wait(env, fd, NET_WAIT_READ, tmout2); + if (tmout2 >= 0) { + len = sizeof(sa_recv); + n = recvfrom(fd, recvbuf, sizeof(recvbuf), 0, + (struct sockaddr *)&sa_recv, &len); + // check if we received enough data + if (n < (jint)sizeof(struct ip)) { + continue; + } + ip = (struct ip *)recvbuf; + hlen = ((jint)(unsigned int)(ip->ip_hl)) << 2; + // check if we received enough data + if (n < (jint)(hlen + sizeof(struct icmp))) { + continue; + } + icmp = (struct icmp *)(recvbuf + hlen); + // We did receive something, but is it what we were expecting? + // I.E.: An ICMP_ECHO_REPLY packet with the proper PID and + // from the host that we are trying to determine is reachable. + if (icmp->icmp_type == ICMP_ECHOREPLY && + (ntohs(icmp->icmp_id) == pid)) + { + if (sa->sa4.sin_addr.s_addr == sa_recv.sin_addr.s_addr) { + close(fd); + return JNI_TRUE; + } else if (sa->sa4.sin_addr.s_addr == 0) { + close(fd); + return JNI_TRUE; + } + } + } + } while (tmout2 > 0); + timeout -= 1000; + } while (timeout > 0); close(fd); return JNI_FALSE; } @@ -413,149 +463,51 @@ ping4(JNIEnv *env, jint fd, struct sockaddr_in* him, jint timeout, */ JNIEXPORT jboolean JNICALL Java_java_net_Inet4AddressImpl_isReachable0(JNIEnv *env, jobject this, - jbyteArray addrArray, - jint timeout, - jbyteArray ifArray, - jint ttl) { - jint addr; + jbyteArray addrArray, jint timeout, + jbyteArray ifArray, jint ttl) +{ jbyte caddr[4]; - jint fd; - struct sockaddr_in him; - struct sockaddr_in* netif = NULL; - struct sockaddr_in inf; - int len = 0; - int connect_rv = -1; - int sz; + jint addr = 0, sz, fd; + SOCKETADDRESS sa, inf, *netif = NULL; - memset((char *) caddr, 0, sizeof(caddr)); - memset((char *) &him, 0, sizeof(him)); - memset((char *) &inf, 0, sizeof(inf)); + // check if address array size is 4 (IPv4 address) sz = (*env)->GetArrayLength(env, addrArray); if (sz != 4) { return JNI_FALSE; } + + // convert IP address from byte array to integer + memset((char *)caddr, 0, sizeof(caddr)); (*env)->GetByteArrayRegion(env, addrArray, 0, 4, caddr); - addr = ((caddr[0]<<24) & 0xff000000); - addr |= ((caddr[1] <<16) & 0xff0000); - addr |= ((caddr[2] <<8) & 0xff00); + addr = ((caddr[0] << 24) & 0xff000000); + addr |= ((caddr[1] << 16) & 0xff0000); + addr |= ((caddr[2] << 8) & 0xff00); addr |= (caddr[3] & 0xff); - addr = htonl(addr); - him.sin_addr.s_addr = addr; - him.sin_family = AF_INET; - len = sizeof(him); - /* - * If a network interface was specified, let's create the address - * for it. - */ + memset((char *)&sa, 0, sizeof(SOCKETADDRESS)); + sa.sa4.sin_addr.s_addr = htonl(addr); + sa.sa4.sin_family = AF_INET; + + // If a network interface was specified, let's convert its address as well. if (!(IS_NULL(ifArray))) { - memset((char *) caddr, 0, sizeof(caddr)); - (*env)->GetByteArrayRegion(env, ifArray, 0, 4, caddr); - addr = ((caddr[0]<<24) & 0xff000000); - addr |= ((caddr[1] <<16) & 0xff0000); - addr |= ((caddr[2] <<8) & 0xff00); - addr |= (caddr[3] & 0xff); - addr = htonl(addr); - inf.sin_addr.s_addr = addr; - inf.sin_family = AF_INET; - inf.sin_port = 0; - netif = &inf; + memset((char *)caddr, 0, sizeof(caddr)); + (*env)->GetByteArrayRegion(env, ifArray, 0, 4, caddr); + addr = ((caddr[0] << 24) & 0xff000000); + addr |= ((caddr[1] << 16) & 0xff0000); + addr |= ((caddr[2] << 8) & 0xff00); + addr |= (caddr[3] & 0xff); + memset((char *)&inf, 0, sizeof(SOCKETADDRESS)); + inf.sa4.sin_addr.s_addr = htonl(addr); + inf.sa4.sin_family = AF_INET; + netif = &inf; } - /* - * Let's try to create a RAW socket to send ICMP packets - * This usually requires "root" privileges, so it's likely to fail. - */ + // Let's try to create a RAW socket to send ICMP packets. + // This usually requires "root" privileges, so it's likely to fail. fd = socket(AF_INET, SOCK_RAW, IPPROTO_ICMP); - if (fd != -1) { - /* - * It didn't fail, so we can use ICMP_ECHO requests. - */ - return ping4(env, fd, &him, timeout, netif, ttl); - } - - /* - * Can't create a raw socket, so let's try a TCP socket - */ - fd = socket(AF_INET, SOCK_STREAM, 0); if (fd == -1) { - /* note: if you run out of fds, you may not be able to load - * the exception class, and get a NoClassDefFoundError - * instead. - */ - NET_ThrowNew(env, errno, "Can't create socket"); - return JNI_FALSE; - } - if (ttl > 0) { - setsockopt(fd, IPPROTO_IP, IP_TTL, &ttl, sizeof(ttl)); - } - - /* - * A network interface was specified, so let's bind to it. - */ - if (netif != NULL) { - if (bind(fd, (struct sockaddr*)netif, sizeof(struct sockaddr_in)) < 0) { - NET_ThrowNew(env, errno, "Can't bind socket"); - close(fd); - return JNI_FALSE; - } - } - - /* - * Make the socket non blocking so we can use select/poll. - */ - SET_NONBLOCKING(fd); - - him.sin_port = htons(7); /* Echo */ - connect_rv = NET_Connect(fd, (struct sockaddr *)&him, len); - - /** - * connection established or refused immediately, either way it means - * we were able to reach the host! - */ - if (connect_rv == 0 || errno == ECONNREFUSED) { - close(fd); - return JNI_TRUE; + return tcp_ping4(env, &sa, netif, timeout, ttl); } else { - socklen_t optlen = (socklen_t)sizeof(connect_rv); - - switch (errno) { - case ENETUNREACH: /* Network Unreachable */ - case EAFNOSUPPORT: /* Address Family not supported */ - case EADDRNOTAVAIL: /* address is not available on the remote machine */ -#if defined(__linux__) || defined(_AIX) - case EINVAL: - case EHOSTUNREACH: /* No route to host */ - /* - * On some Linux versions, when a socket is bound to the loopback - * interface, connect will fail and errno will be set to EINVAL - * or EHOSTUNREACH. When that happens, don't throw an exception, - * just return false. - */ -#endif /* __linux__ */ - close(fd); - return JNI_FALSE; - } - - if (errno != EINPROGRESS) { - NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", - "connect failed"); - close(fd); - return JNI_FALSE; - } - - timeout = NET_Wait(env, fd, NET_WAIT_CONNECT, timeout); - if (timeout >= 0) { - /* has connection been established? */ - if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&connect_rv, - &optlen) <0) { - connect_rv = errno; - } - if (connect_rv == 0 || connect_rv == ECONNREFUSED) { - close(fd); - return JNI_TRUE; - } - } - close(fd); - return JNI_FALSE; + // It didn't fail, so we can use ICMP_ECHO requests. + return ping4(env, fd, &sa, netif, timeout, ttl); } } diff --git a/jdk/src/java.base/unix/native/libnet/Inet6AddressImpl.c b/jdk/src/java.base/unix/native/libnet/Inet6AddressImpl.c index 15f984ebd34..2760baf9303 100644 --- a/jdk/src/java.base/unix/native/libnet/Inet6AddressImpl.c +++ b/jdk/src/java.base/unix/native/libnet/Inet6AddressImpl.c @@ -38,17 +38,22 @@ #include "net_util.h" +#include "java_net_InetAddress.h" #include "java_net_Inet4AddressImpl.h" #include "java_net_Inet6AddressImpl.h" -#include "java_net_InetAddress.h" /* the initial size of our hostent buffers */ #ifndef NI_MAXHOST #define NI_MAXHOST 1025 #endif +#define SET_NONBLOCKING(fd) { \ + int flags = fcntl(fd, F_GETFL); \ + flags |= O_NONBLOCK; \ + fcntl(fd, F_SETFL, flags); \ +} -/************************************************************************ +/* * Inet6AddressImpl */ @@ -59,58 +64,40 @@ */ JNIEXPORT jstring JNICALL Java_java_net_Inet6AddressImpl_getLocalHostName(JNIEnv *env, jobject this) { - int ret; - char hostname[NI_MAXHOST+1]; + char hostname[NI_MAXHOST + 1]; hostname[0] = '\0'; - ret = gethostname(hostname, NI_MAXHOST); - if (ret == -1) { - /* Something went wrong, maybe networking is not setup? */ + if (gethostname(hostname, NI_MAXHOST) != 0) { strcpy(hostname, "localhost"); - } else { - // ensure null-terminated - hostname[NI_MAXHOST] = '\0'; - } - #if defined(__solaris__) - if (ret == 0) { - /* Solaris doesn't want to give us a fully qualified domain name. - * We do a reverse lookup to try and get one. This works - * if DNS occurs before NIS in /etc/resolv.conf, but fails - * if NIS comes first (it still gets only a partial name). - * We use thread-safe system calls. - */ - struct addrinfo hints, *res; - int error; + } else { + // try to resolve hostname via nameservice + // if it is known but getnameinfo fails, hostname will still be the + // value from gethostname + struct addrinfo hints, *res; + // make sure string is null-terminated + hostname[NI_MAXHOST] = '\0'; memset(&hints, 0, sizeof(hints)); hints.ai_flags = AI_CANONNAME; hints.ai_family = AF_UNSPEC; - error = getaddrinfo(hostname, NULL, &hints, &res); - - if (error == 0) { - /* host is known to name service */ - error = getnameinfo(res->ai_addr, - res->ai_addrlen, - hostname, - NI_MAXHOST, - NULL, - 0, - NI_NAMEREQD); - - /* if getnameinfo fails hostname is still the value - from gethostname */ - + if (getaddrinfo(hostname, NULL, &hints, &res) == 0) { + getnameinfo(res->ai_addr, res->ai_addrlen, hostname, NI_MAXHOST, + NULL, 0, NI_NAMEREQD); freeaddrinfo(res); } } +#else + } else { + // make sure string is null-terminated + hostname[NI_MAXHOST] = '\0'; + } #endif - return (*env)->NewStringUTF(env, hostname); } -#ifdef MACOSX +#if defined(MACOSX) /* also called from Inet4AddressImpl.c */ __private_extern__ jobjectArray lookupIfLocalhost(JNIEnv *env, const char *hostname, jboolean includeV6) @@ -163,7 +150,7 @@ lookupIfLocalhost(JNIEnv *env, const char *hostname, jboolean includeV6) struct ifaddrs *iter = ifa; while (iter) { int family = iter->ifa_addr->sa_family; - if (iter->ifa_name[0] != '\0' && iter->ifa_addr) + if (iter->ifa_name[0] != '\0' && iter->ifa_addr) { jboolean isLoopback = iter->ifa_flags & IFF_LOOPBACK; if (family == AF_INET) { @@ -172,9 +159,7 @@ lookupIfLocalhost(JNIEnv *env, const char *hostname, jboolean includeV6) } else if (family == AF_INET6 && includeV6) { addrs6++; if (isLoopback) numV6Loopbacks++; - } else { - /* We don't care e.g. AF_LINK */ - } + } // else we don't care, e.g. AF_LINK } iter = iter->ifa_next; } @@ -205,9 +190,9 @@ lookupIfLocalhost(JNIEnv *env, const char *hostname, jboolean includeV6) jboolean isLoopback = iter->ifa_flags & IFF_LOOPBACK; int family = iter->ifa_addr->sa_family; - if (iter->ifa_name[0] != '\0' && iter->ifa_addr - && (family == AF_INET || (family == AF_INET6 && includeV6)) - && (!isLoopback || includeLoopback)) + if (iter->ifa_name[0] != '\0' && iter->ifa_addr && + (family == AF_INET || (family == AF_INET6 && includeV6)) && + (!isLoopback || includeLoopback)) { int port; int index = (family == AF_INET) ? i++ : j++; @@ -234,93 +219,65 @@ lookupIfLocalhost(JNIEnv *env, const char *hostname, jboolean includeV6) #endif /* - * Find an internet address for a given hostname. Note that this - * code only works for addresses of type INET. The translation - * of %d.%d.%d.%d to an address (int) occurs in java now, so the - * String "host" shouldn't *ever* be a %d.%d.%d.%d string - * * Class: java_net_Inet6AddressImpl * Method: lookupAllHostAddr * Signature: (Ljava/lang/String;)[[B */ - JNIEXPORT jobjectArray JNICALL Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, - jstring host) { + jstring host) { + jobjectArray ret = NULL; const char *hostname; - jobjectArray ret = 0; - int retLen = 0; - - int getaddrinfo_error=0; - struct addrinfo hints, *res, *resNew = NULL; + int error = 0; + struct addrinfo hints, *res = NULL, *resNew = NULL, *last = NULL, + *iterator; initInetAddressIDs(env); JNU_CHECK_EXCEPTION_RETURN(env, NULL); if (IS_NULL(host)) { - JNU_ThrowNullPointerException(env, "host is null"); - return 0; + JNU_ThrowNullPointerException(env, "host argument is null"); + return NULL; } hostname = JNU_GetStringPlatformChars(env, host, JNI_FALSE); CHECK_NULL_RETURN(hostname, NULL); - /* Try once, with our static buffer. */ + // try once, with our static buffer memset(&hints, 0, sizeof(hints)); hints.ai_flags = AI_CANONNAME; hints.ai_family = AF_UNSPEC; -#ifdef __solaris__ - /* - * Workaround for Solaris bug 4160367 - if a hostname contains a - * white space then 0.0.0.0 is returned - */ - if (isspace((unsigned char)hostname[0])) { - JNU_ThrowByName(env, JNU_JAVANETPKG "UnknownHostException", - hostname); - JNU_ReleaseStringPlatformChars(env, host, hostname); - return NULL; - } -#endif + error = getaddrinfo(hostname, NULL, &hints, &res); - getaddrinfo_error = getaddrinfo(hostname, NULL, &hints, &res); - -#ifdef MACOSX - if (getaddrinfo_error) { - /* - * If getaddrinfo fails looking up the local machine, attempt to get the - * address from getifaddrs. This ensures we get an IPv6 address for the - * local machine. - */ + if (error) { +#if defined(MACOSX) + // if getaddrinfo fails try getifaddrs ret = lookupIfLocalhost(env, hostname, JNI_TRUE); if (ret != NULL || (*env)->ExceptionCheck(env)) { - JNU_ReleaseStringPlatformChars(env, host, hostname); - return ret; + goto cleanupAndReturn; } - } #endif - - if (getaddrinfo_error) { - /* report error */ - NET_ThrowUnknownHostExceptionWithGaiError( - env, hostname, getaddrinfo_error); - JNU_ReleaseStringPlatformChars(env, host, hostname); - return NULL; + // report error + NET_ThrowUnknownHostExceptionWithGaiError(env, hostname, error); + goto cleanupAndReturn; } else { - int i = 0, addressPreference = -1; - int inetCount = 0, inet6Count = 0, inetIndex = 0, inet6Index = 0, originalIndex = 0; - struct addrinfo *itr, *last = NULL, *iterator = res; + int i = 0, inetCount = 0, inet6Count = 0, inetIndex = 0, + inet6Index = 0, originalIndex = 0; + int addressPreference = + (*env)->GetStaticIntField(env, ia_class, ia_preferIPv6AddressID);; + iterator = res; while (iterator != NULL) { + // skip duplicates int skip = 0; - itr = resNew; - while (itr != NULL) { - if (iterator->ai_family == itr->ai_family && - iterator->ai_addrlen == itr->ai_addrlen) { - if (itr->ai_family == AF_INET) { /* AF_INET */ + struct addrinfo *iteratorNew = resNew; + while (iteratorNew != NULL) { + if (iterator->ai_family == iteratorNew->ai_family && + iterator->ai_addrlen == iteratorNew->ai_addrlen) { + if (iteratorNew->ai_family == AF_INET) { /* AF_INET */ struct sockaddr_in *addr1, *addr2; addr1 = (struct sockaddr_in *)iterator->ai_addr; - addr2 = (struct sockaddr_in *)itr->ai_addr; - if (addr1->sin_addr.s_addr == - addr2->sin_addr.s_addr) { + addr2 = (struct sockaddr_in *)iteratorNew->ai_addr; + if (addr1->sin_addr.s_addr == addr2->sin_addr.s_addr) { skip = 1; break; } @@ -328,7 +285,7 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, int t; struct sockaddr_in6 *addr1, *addr2; addr1 = (struct sockaddr_in6 *)iterator->ai_addr; - addr2 = (struct sockaddr_in6 *)itr->ai_addr; + addr2 = (struct sockaddr_in6 *)iteratorNew->ai_addr; for (t = 0; t < 16; t++) { if (addr1->sin6_addr.s6_addr[t] != @@ -337,7 +294,7 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, } } if (t < 16) { - itr = itr->ai_next; + iteratorNew = iteratorNew->ai_next; continue; } else { skip = 1; @@ -346,16 +303,16 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, } } else if (iterator->ai_family != AF_INET && iterator->ai_family != AF_INET6) { - /* we can't handle other family types */ + // we can't handle other family types skip = 1; break; } - itr = itr->ai_next; + iteratorNew = iteratorNew->ai_next; } if (!skip) { struct addrinfo *next - = (struct addrinfo*) malloc(sizeof(struct addrinfo)); + = (struct addrinfo *)malloc(sizeof(struct addrinfo)); if (!next) { JNU_ThrowOutOfMemoryError(env, "Native heap allocation failed"); ret = NULL; @@ -371,39 +328,33 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, last = next; i++; if (iterator->ai_family == AF_INET) { - inetCount ++; + inetCount++; } else if (iterator->ai_family == AF_INET6) { - inet6Count ++; + inet6Count++; } } iterator = iterator->ai_next; } - retLen = i; - iterator = resNew; - - ret = (*env)->NewObjectArray(env, retLen, ia_class, NULL); + // allocate array - at this point i contains the number of addresses + ret = (*env)->NewObjectArray(env, i, ia_class, NULL); if (IS_NULL(ret)) { /* we may have memory to free at the end of this */ goto cleanupAndReturn; } - addressPreference = (*env)->GetStaticIntField(env, ia_class, ia_preferIPv6AddressID); - if (addressPreference == java_net_InetAddress_PREFER_IPV6_VALUE) { - /* AF_INET addresses will be offset by inet6Count */ inetIndex = inet6Count; inet6Index = 0; } else if (addressPreference == java_net_InetAddress_PREFER_IPV4_VALUE) { - /* AF_INET6 addresses will be offset by inetCount */ inetIndex = 0; inet6Index = inetCount; } else if (addressPreference == java_net_InetAddress_PREFER_SYSTEM_VALUE) { inetIndex = inet6Index = originalIndex = 0; } + iterator = resNew; while (iterator != NULL) { - jboolean ret1; if (iterator->ai_family == AF_INET) { jobject iaObj = (*env)->NewObject(env, ia4_class, ia4_ctrID); if (IS_NULL(iaObj)) { @@ -416,7 +367,7 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, inetIndex++; } else if (iterator->ai_family == AF_INET6) { jint scope = 0; - + jboolean ret1; jobject iaObj = (*env)->NewObject(env, ia6_class, ia6_ctrID); if (IS_NULL(iaObj)) { ret = NULL; @@ -427,9 +378,8 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, ret = NULL; goto cleanupAndReturn; } - - scope = ((struct sockaddr_in6*)iterator->ai_addr)->sin6_scope_id; - if (scope != 0) { /* zero is default value, no need to set */ + scope = ((struct sockaddr_in6 *)iterator->ai_addr)->sin6_scope_id; + if (scope != 0) { // zero is default value, no need to set setInet6Address_scopeid(env, iaObj, scope); } setInetAddress_hostName(env, iaObj, host); @@ -443,21 +393,16 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, iterator = iterator->ai_next; } } - - cleanupAndReturn: - { - struct addrinfo *iterator, *tmp; - iterator = resNew; - while (iterator != NULL) { - tmp = iterator; - iterator = iterator->ai_next; - free(tmp); - } - JNU_ReleaseStringPlatformChars(env, host, hostname); +cleanupAndReturn: + JNU_ReleaseStringPlatformChars(env, host, hostname); + while (resNew != NULL) { + last = resNew; + resNew = resNew->ai_next; + free(last); + } + if (res != NULL) { + freeaddrinfo(res); } - - freeaddrinfo(res); - return ret; } @@ -465,171 +410,252 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, * Class: java_net_Inet6AddressImpl * Method: getHostByAddr * Signature: (I)Ljava/lang/String; + * + * Theoretically the UnknownHostException could be enriched with gai error + * information. But as it is silently ignored anyway, there's no need for this. + * It's only important that either a valid hostname is returned or an + * UnknownHostException is thrown. */ JNIEXPORT jstring JNICALL Java_java_net_Inet6AddressImpl_getHostByAddr(JNIEnv *env, jobject this, - jbyteArray addrArray) { - + jbyteArray addrArray) { jstring ret = NULL; - - char host[NI_MAXHOST+1]; - int error = 0; + char host[NI_MAXHOST + 1]; int len = 0; jbyte caddr[16]; + SOCKETADDRESS sa; - struct sockaddr_in him4; - struct sockaddr_in6 him6; - struct sockaddr *sa; + memset((void *)&sa, 0, sizeof(SOCKETADDRESS)); - /* - * For IPv4 addresses construct a sockaddr_in structure. - */ + // construct a sockaddr_in structure (AF_INET or AF_INET6) if ((*env)->GetArrayLength(env, addrArray) == 4) { jint addr; (*env)->GetByteArrayRegion(env, addrArray, 0, 4, caddr); - addr = ((caddr[0]<<24) & 0xff000000); - addr |= ((caddr[1] <<16) & 0xff0000); - addr |= ((caddr[2] <<8) & 0xff00); + addr = ((caddr[0] << 24) & 0xff000000); + addr |= ((caddr[1] << 16) & 0xff0000); + addr |= ((caddr[2] << 8) & 0xff00); addr |= (caddr[3] & 0xff); - memset((void *) &him4, 0, sizeof(him4)); - him4.sin_addr.s_addr = htonl(addr); - him4.sin_family = AF_INET; - sa = (struct sockaddr *)&him4; - len = sizeof(him4); + sa.sa4.sin_addr.s_addr = htonl(addr); + sa.sa4.sin_family = AF_INET; + len = sizeof(struct sockaddr_in); } else { - /* - * For IPv6 address construct a sockaddr_in6 structure. - */ (*env)->GetByteArrayRegion(env, addrArray, 0, 16, caddr); - memset((void *)&him6, 0, sizeof(him6)); - memcpy((void *)&(him6.sin6_addr), caddr, sizeof(struct in6_addr)); - him6.sin6_family = AF_INET6; - sa = (struct sockaddr *)&him6; - len = sizeof(him6); + memcpy((void *)&sa.sa6.sin6_addr, caddr, sizeof(struct in6_addr)); + sa.sa6.sin6_family = AF_INET6; + len = sizeof(struct sockaddr_in6); } - error = getnameinfo(sa, len, host, NI_MAXHOST, NULL, 0, NI_NAMEREQD); - - if (!error) { + if (getnameinfo(&sa.sa, len, host, NI_MAXHOST, NULL, 0, NI_NAMEREQD)) { + JNU_ThrowByName(env, "java/net/UnknownHostException", NULL); + } else { ret = (*env)->NewStringUTF(env, host); - CHECK_NULL_RETURN(ret, NULL); - } - - if (ret == NULL) { - JNU_ThrowByName(env, JNU_JAVANETPKG "UnknownHostException", NULL); + if (ret == NULL) { + JNU_ThrowByName(env, "java/net/UnknownHostException", NULL); + } } return ret; } -#define SET_NONBLOCKING(fd) { \ - int flags = fcntl(fd, F_GETFL); \ - flags |= O_NONBLOCK; \ - fcntl(fd, F_SETFL, flags); \ +/** + * ping implementation using tcp port 7 (echo) + */ +static jboolean +tcp_ping6(JNIEnv *env, SOCKETADDRESS *sa, SOCKETADDRESS *netif, jint timeout, + jint ttl) +{ + jint fd; + int connect_rv = -1; + + // open a TCP socket + fd = socket(AF_INET6, SOCK_STREAM, 0); + if (fd == -1) { + // note: if you run out of fds, you may not be able to load + // the exception class, and get a NoClassDefFoundError instead. + NET_ThrowNew(env, errno, "Can't create socket"); + return JNI_FALSE; + } + + // set TTL + if (ttl > 0) { + setsockopt(fd, IPPROTO_IPV6, IPV6_UNICAST_HOPS, &ttl, sizeof(ttl)); + } + + // A network interface was specified, so let's bind to it. + if (netif != NULL) { + if (bind(fd, &netif->sa, sizeof(struct sockaddr_in6)) <0) { + NET_ThrowNew(env, errno, "Can't bind socket"); + close(fd); + return JNI_FALSE; + } + } + + // Make the socket non blocking so we can use select/poll. + SET_NONBLOCKING(fd); + + sa->sa6.sin6_port = htons(7); // echo port + connect_rv = NET_Connect(fd, &sa->sa, sizeof(struct sockaddr_in6)); + + // connection established or refused immediately, either way it means + // we were able to reach the host! + if (connect_rv == 0 || errno == ECONNREFUSED) { + close(fd); + return JNI_TRUE; + } + + switch (errno) { + case ENETUNREACH: // Network Unreachable + case EAFNOSUPPORT: // Address Family not supported + case EADDRNOTAVAIL: // address is not available on the remote machine +#if defined(__linux__) || defined(_AIX) + // On some Linux versions, when a socket is bound to the loopback + // interface, connect will fail and errno will be set to EINVAL + // or EHOSTUNREACH. When that happens, don't throw an exception, + // just return false. + case EINVAL: + case EHOSTUNREACH: // No route to host +#endif + close(fd); + return JNI_FALSE; + case EINPROGRESS: // this is expected as we'll probably have to wait + break; + default: + NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", + "connect failed"); + close(fd); + return JNI_FALSE; + } + + timeout = NET_Wait(env, fd, NET_WAIT_CONNECT, timeout); + if (timeout >= 0) { + // connection has been established, check for error condition + socklen_t optlen = (socklen_t)sizeof(connect_rv); + if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&connect_rv, + &optlen) <0) + { + connect_rv = errno; + } + if (connect_rv == 0 || connect_rv == ECONNREFUSED) { + close(fd); + return JNI_TRUE; + } + } + close(fd); + return JNI_FALSE; } +/** + * ping implementation. + * Send an ICMP_ECHO_REQUEST packet every second until either the timeout + * expires or an answer is received. + * Returns true if an ECHO_REPLY is received, false otherwise. + */ static jboolean -ping6(JNIEnv *env, jint fd, struct sockaddr_in6* him, jint timeout, - struct sockaddr_in6* netif, jint ttl) { - jint size; - jint n; +ping6(JNIEnv *env, jint fd, SOCKETADDRESS *sa, SOCKETADDRESS *netif, + jint timeout, jint ttl) +{ + jint n, size = 60 * 1024, tmout2, seq = 1; socklen_t len; - char sendbuf[1500]; - unsigned char recvbuf[1500]; + unsigned char sendbuf[1500], recvbuf[1500]; struct icmp6_hdr *icmp6; struct sockaddr_in6 sa_recv; - jbyte *caddr, *recv_caddr; jchar pid; - jint tmout2, seq = 1; struct timeval tv; - size_t plen; + size_t plen = sizeof(struct icmp6_hdr) + sizeof(tv); -#ifdef __linux__ - { - int csum_offset; +#if defined(__linux__) /** * For some strange reason, the linux kernel won't calculate the * checksum of ICMPv6 packets unless you set this socket option */ - csum_offset = 2; + int csum_offset = 2; setsockopt(fd, SOL_RAW, IPV6_CHECKSUM, &csum_offset, sizeof(int)); - } #endif - caddr = (jbyte *)&(him->sin6_addr); - - /* icmp_id is a 16 bit data type, therefore down cast the pid */ - pid = (jchar)getpid(); - size = 60*1024; setsockopt(fd, SOL_SOCKET, SO_RCVBUF, &size, sizeof(size)); + + // sets the ttl (max number of hops) if (ttl > 0) { - setsockopt(fd, IPPROTO_IPV6, IPV6_UNICAST_HOPS, &ttl, sizeof(ttl)); + setsockopt(fd, IPPROTO_IPV6, IPV6_UNICAST_HOPS, &ttl, sizeof(ttl)); } + + // a specific interface was specified, so let's bind the socket + // to that interface to ensure the requests are sent only through it. if (netif != NULL) { - if (bind(fd, (struct sockaddr*)netif, sizeof(struct sockaddr_in6)) <0) { - NET_ThrowNew(env, errno, "Can't bind socket"); - close(fd); - return JNI_FALSE; - } - } - SET_NONBLOCKING(fd); - - do { - icmp6 = (struct icmp6_hdr *) sendbuf; - icmp6->icmp6_type = ICMP6_ECHO_REQUEST; - icmp6->icmp6_code = 0; - /* let's tag the ECHO packet with our pid so we can identify it */ - icmp6->icmp6_id = htons(pid); - icmp6->icmp6_seq = htons(seq); - seq++; - icmp6->icmp6_cksum = 0; - gettimeofday(&tv, NULL); - memcpy(sendbuf + sizeof(struct icmp6_hdr), &tv, sizeof(tv)); - plen = sizeof(struct icmp6_hdr) + sizeof(tv); - n = sendto(fd, sendbuf, plen, 0, (struct sockaddr*) him, sizeof(struct sockaddr_in6)); - if (n < 0 && errno != EINPROGRESS) { -#ifdef __linux__ - if (errno != EINVAL && errno != EHOSTUNREACH) - /* - * On some Linux versions, when a socket is bound to the - * loopback interface, sendto will fail and errno will be - * set to EINVAL or EHOSTUNREACH. - * When that happens, don't throw an exception, just return false. - */ -#endif /*__linux__ */ - NET_ThrowNew(env, errno, "Can't send ICMP packet"); - close(fd); - return JNI_FALSE; - } - - tmout2 = timeout > 1000 ? 1000 : timeout; - do { - tmout2 = NET_Wait(env, fd, NET_WAIT_READ, tmout2); - - if (tmout2 >= 0) { - len = sizeof(sa_recv); - n = recvfrom(fd, recvbuf, sizeof(recvbuf), 0, (struct sockaddr*) &sa_recv, &len); - icmp6 = (struct icmp6_hdr *) (recvbuf); - recv_caddr = (jbyte *)&(sa_recv.sin6_addr); - /* - * We did receive something, but is it what we were expecting? - * I.E.: An ICMP6_ECHO_REPLY packet with the proper PID and - * from the host that we are trying to determine is reachable. - */ - if (n >= 8 && icmp6->icmp6_type == ICMP6_ECHO_REPLY && - (ntohs(icmp6->icmp6_id) == pid)) { - if (NET_IsEqual(caddr, recv_caddr)) { - close(fd); - return JNI_TRUE; - } - if (NET_IsZeroAddr(caddr)) { - close(fd); - return JNI_TRUE; - } - } + if (bind(fd, &netif->sa, sizeof(struct sockaddr_in6)) <0) { + NET_ThrowNew(env, errno, "Can't bind socket"); + close(fd); + return JNI_FALSE; } - } while (tmout2 > 0); - timeout -= 1000; + } + + // icmp_id is a 16 bit data type, therefore down cast the pid + pid = (jchar)getpid(); + + // Make the socket non blocking so we can use select + SET_NONBLOCKING(fd); + do { + // create the ICMP request + icmp6 = (struct icmp6_hdr *)sendbuf; + icmp6->icmp6_type = ICMP6_ECHO_REQUEST; + icmp6->icmp6_code = 0; + // let's tag the ECHO packet with our pid so we can identify it + icmp6->icmp6_id = htons(pid); + icmp6->icmp6_seq = htons(seq); + seq++; + gettimeofday(&tv, NULL); + memcpy(sendbuf + sizeof(struct icmp6_hdr), &tv, sizeof(tv)); + icmp6->icmp6_cksum = 0; + // send it + n = sendto(fd, sendbuf, plen, 0, &sa->sa, sizeof(struct sockaddr_in6)); + if (n < 0 && errno != EINPROGRESS) { +#if defined(__linux__) + /* + * On some Linux versions, when a socket is bound to the loopback + * interface, sendto will fail and errno will be set to + * EINVAL or EHOSTUNREACH. When that happens, don't throw an + * exception, just return false. + */ + if (errno != EINVAL && errno != EHOSTUNREACH) { + NET_ThrowNew(env, errno, "Can't send ICMP packet"); + } +#else + NET_ThrowNew(env, errno, "Can't send ICMP packet"); +#endif + close(fd); + return JNI_FALSE; + } + + tmout2 = timeout > 1000 ? 1000 : timeout; + do { + tmout2 = NET_Wait(env, fd, NET_WAIT_READ, tmout2); + if (tmout2 >= 0) { + len = sizeof(sa_recv); + n = recvfrom(fd, recvbuf, sizeof(recvbuf), 0, + (struct sockaddr *)&sa_recv, &len); + // check if we received enough data + if (n < (jint)sizeof(struct icmp6_hdr)) { + continue; + } + icmp6 = (struct icmp6_hdr *)recvbuf; + // We did receive something, but is it what we were expecting? + // I.E.: An ICMP6_ECHO_REPLY packet with the proper PID and + // from the host that we are trying to determine is reachable. + if (icmp6->icmp6_type == ICMP6_ECHO_REPLY && + (ntohs(icmp6->icmp6_id) == pid)) + { + if (NET_IsEqual((jbyte *)&sa->sa6.sin6_addr, + (jbyte *)&sa_recv.sin6_addr)) { + close(fd); + return JNI_TRUE; + } else if (NET_IsZeroAddr((jbyte *)&sa->sa6.sin6_addr)) { + close(fd); + return JNI_TRUE; + } + } + } + } while (tmout2 > 0); + timeout -= 1000; } while (timeout > 0); close(fd); return JNI_FALSE; @@ -642,157 +668,61 @@ ping6(JNIEnv *env, jint fd, struct sockaddr_in6* him, jint timeout, */ JNIEXPORT jboolean JNICALL Java_java_net_Inet6AddressImpl_isReachable0(JNIEnv *env, jobject this, - jbyteArray addrArray, - jint scope, - jint timeout, - jbyteArray ifArray, - jint ttl, jint if_scope) { + jbyteArray addrArray, jint scope, + jint timeout, jbyteArray ifArray, + jint ttl, jint if_scope) +{ jbyte caddr[16]; - jint fd, sz; - struct sockaddr_in6 him6; - struct sockaddr_in6 inf6; - struct sockaddr_in6* netif = NULL; - int len = 0; - int connect_rv = -1; + jint sz, fd; + SOCKETADDRESS sa, inf, *netif = NULL; - /* - * If IPv6 is not enable, then we can't reach an IPv6 address, can we? - */ + // If IPv6 is not enabled, then we can't reach an IPv6 address, can we? + // Actually, we probably shouldn't even get here. if (!ipv6_available()) { - return JNI_FALSE; + return JNI_FALSE; } - /* - * If it's an IPv4 address, ICMP won't work with IPv4 mapped address, - * therefore, let's delegate to the Inet4Address method. - */ + + // If it's an IPv4 address, ICMP won't work with IPv4 mapped address, + // therefore, let's delegate to the Inet4Address method. sz = (*env)->GetArrayLength(env, addrArray); if (sz == 4) { - return Java_java_net_Inet4AddressImpl_isReachable0(env, this, - addrArray, - timeout, - ifArray, ttl); + return Java_java_net_Inet4AddressImpl_isReachable0(env, this, + addrArray, timeout, + ifArray, ttl); } - memset((void *) caddr, 0, 16); - memset((void *) &him6, 0, sizeof(him6)); + // load address to SOCKETADDRESS + memset((char *)caddr, 0, 16); (*env)->GetByteArrayRegion(env, addrArray, 0, 16, caddr); - memcpy((void *)&(him6.sin6_addr), caddr, sizeof(struct in6_addr) ); - him6.sin6_family = AF_INET6; -#ifdef __linux__ - if (scope > 0) - him6.sin6_scope_id = scope; - else - him6.sin6_scope_id = getDefaultIPv6Interface( &(him6.sin6_addr)); - len = sizeof(struct sockaddr_in6); -#else - if (scope > 0) - him6.sin6_scope_id = scope; - len = sizeof(struct sockaddr_in6); -#endif - /* - * If a network interface was specified, let's create the address - * for it. - */ - if (!(IS_NULL(ifArray))) { - memset((void *) caddr, 0, 16); - memset((void *) &inf6, 0, sizeof(inf6)); - (*env)->GetByteArrayRegion(env, ifArray, 0, 16, caddr); - memcpy((void *)&(inf6.sin6_addr), caddr, sizeof(struct in6_addr) ); - inf6.sin6_family = AF_INET6; - inf6.sin6_scope_id = if_scope; - netif = &inf6; - } - /* - * If we can create a RAW socket, then when can use the ICMP ECHO_REQUEST - * otherwise we'll try a tcp socket to the Echo port (7). - * Note that this is empiric, and not connecting could mean it's blocked - * or the echo service has been disabled. - */ - - fd = socket(AF_INET6, SOCK_RAW, IPPROTO_ICMPV6); - - if (fd != -1) { /* Good to go, let's do a ping */ - return ping6(env, fd, &him6, timeout, netif, ttl); - } - - /* No good, let's fall back on TCP */ - fd = socket(AF_INET6, SOCK_STREAM, 0); - if (fd == -1) { - /* note: if you run out of fds, you may not be able to load - * the exception class, and get a NoClassDefFoundError - * instead. - */ - NET_ThrowNew(env, errno, "Can't create socket"); - return JNI_FALSE; - } - if (ttl > 0) { - setsockopt(fd, IPPROTO_IPV6, IPV6_UNICAST_HOPS, &ttl, sizeof(ttl)); - } - - /* - * A network interface was specified, so let's bind to it. - */ - if (netif != NULL) { - if (bind(fd, (struct sockaddr*)netif, sizeof(struct sockaddr_in6)) <0) { - NET_ThrowNew(env, errno, "Can't bind socket"); - close(fd); - return JNI_FALSE; - } - } - SET_NONBLOCKING(fd); - - him6.sin6_port = htons((short) 7); /* Echo port */ - connect_rv = NET_Connect(fd, (struct sockaddr *)&him6, len); - - /** - * connection established or refused immediately, either way it means - * we were able to reach the host! - */ - if (connect_rv == 0 || errno == ECONNREFUSED) { - close(fd); - return JNI_TRUE; + memset((char *)&sa, 0, sizeof(SOCKETADDRESS)); + memcpy((void *)&sa.sa6.sin6_addr, caddr, sizeof(struct in6_addr)); + sa.sa6.sin6_family = AF_INET6; + if (scope > 0) { + sa.sa6.sin6_scope_id = scope; +#if defined(__linux__) } else { - socklen_t optlen = (socklen_t)sizeof(connect_rv); + sa.sa6.sin6_scope_id = getDefaultIPv6Interface(&sa.sa6.sin6_addr); +#endif + } - switch (errno) { - case ENETUNREACH: /* Network Unreachable */ - case EAFNOSUPPORT: /* Address Family not supported */ - case EADDRNOTAVAIL: /* address is not available on the remote machine */ -#if defined(__linux__) || defined(_AIX) - case EINVAL: - case EHOSTUNREACH: /* No route to host */ - /* - * On some Linux versions, when a socket is bound to the - * loopback interface, connect will fail and errno will - * be set to EINVAL or EHOSTUNREACH. When that happens, - * don't throw an exception, just return false. - */ -#endif /* __linux__ */ - close(fd); - return JNI_FALSE; - } + // load network interface address to SOCKETADDRESS, if specified + if (!(IS_NULL(ifArray))) { + memset((char *)caddr, 0, 16); + (*env)->GetByteArrayRegion(env, ifArray, 0, 16, caddr); + memset((char *)&inf, 0, sizeof(SOCKETADDRESS)); + memcpy((void *)&inf.sa6.sin6_addr, caddr, sizeof(struct in6_addr)); + inf.sa6.sin6_family = AF_INET6; + inf.sa6.sin6_scope_id = if_scope; + netif = &inf; + } - if (errno != EINPROGRESS) { - NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", - "connect failed"); - close(fd); - return JNI_FALSE; - } - - timeout = NET_Wait(env, fd, NET_WAIT_CONNECT, timeout); - - if (timeout >= 0) { - /* has connection been established */ - if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&connect_rv, - &optlen) <0) { - connect_rv = errno; - } - if (connect_rv == 0 || connect_rv == ECONNREFUSED) { - close(fd); - return JNI_TRUE; - } - } - close(fd); - return JNI_FALSE; + // Let's try to create a RAW socket to send ICMP packets. + // This usually requires "root" privileges, so it's likely to fail. + fd = socket(AF_INET6, SOCK_RAW, IPPROTO_ICMPV6); + if (fd == -1) { + return tcp_ping6(env, &sa, netif, timeout, ttl); + } else { + // It didn't fail, so we can use ICMP_ECHO requests. + return ping6(env, fd, &sa, netif, timeout, ttl); } } diff --git a/jdk/src/java.base/unix/native/libnet/NetworkInterface.c b/jdk/src/java.base/unix/native/libnet/NetworkInterface.c index 88c27955ac8..96f7dfb9927 100644 --- a/jdk/src/java.base/unix/native/libnet/NetworkInterface.c +++ b/jdk/src/java.base/unix/native/libnet/NetworkInterface.c @@ -361,7 +361,11 @@ JNIEXPORT jobject JNICALL Java_java_net_NetworkInterface_getByInetAddress0 ((struct sockaddr_in6*)addrP->addr)->sin6_addr); jbyte caddr[16]; int i; + unsigned int scopeid; getInet6Address_ipaddress(env, iaObj, (char *)caddr); + scopeid = (unsigned int)getInet6Address_scopeid(env, iaObj); + if (scopeid != 0 && scopeid != ((struct sockaddr_in6*)addrP->addr)->sin6_scope_id) + break; i = 0; while (i < 16) { if (caddr[i] != bytes[i]) { diff --git a/jdk/src/java.base/unix/native/libnet/PlainDatagramSocketImpl.c b/jdk/src/java.base/unix/native/libnet/PlainDatagramSocketImpl.c index 12357330ffe..a3c575f62de 100644 --- a/jdk/src/java.base/unix/native/libnet/PlainDatagramSocketImpl.c +++ b/jdk/src/java.base/unix/native/libnet/PlainDatagramSocketImpl.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -485,7 +485,7 @@ Java_java_net_PlainDatagramSocketImpl_peek(JNIEnv *env, jobject this, return -1; } if (timeout) { - int ret = NET_Timeout(fd, timeout); + int ret = NET_Timeout(env, fd, timeout, JVM_NanoTime(env, 0)); if (ret == 0) { JNU_ThrowByName(env, JNU_JAVANETPKG "SocketTimeoutException", "Peek timed out"); @@ -576,7 +576,7 @@ Java_java_net_PlainDatagramSocketImpl_peekData(JNIEnv *env, jobject this, packetBufferOffset = (*env)->GetIntField(env, packet, dp_offsetID); packetBufferLen = (*env)->GetIntField(env, packet, dp_bufLengthID); if (timeout) { - int ret = NET_Timeout(fd, timeout); + int ret = NET_Timeout(env, fd, timeout, JVM_NanoTime(env, 0)); if (ret == 0) { JNU_ThrowByName(env, JNU_JAVANETPKG "SocketTimeoutException", "Receive timed out"); @@ -789,7 +789,7 @@ Java_java_net_PlainDatagramSocketImpl_receive0(JNIEnv *env, jobject this, retry = JNI_FALSE; if (timeout) { - int ret = NET_Timeout(fd, timeout); + int ret = NET_Timeout(env, fd, timeout, JVM_NanoTime(env, 0)); if (ret <= 0) { if (ret == 0) { JNU_ThrowByName(env, JNU_JAVANETPKG "SocketTimeoutException", diff --git a/jdk/src/java.base/unix/native/libnet/PlainSocketImpl.c b/jdk/src/java.base/unix/native/libnet/PlainSocketImpl.c index 1985085abb4..7d96751b1a2 100644 --- a/jdk/src/java.base/unix/native/libnet/PlainSocketImpl.c +++ b/jdk/src/java.base/unix/native/libnet/PlainSocketImpl.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,6 +24,7 @@ */ #include +#include "jvm.h" #include "net_util.h" #include "java_net_SocketOptions.h" @@ -231,7 +232,6 @@ Java_java_net_PlainSocketImpl_socketConnect(JNIEnv *env, jobject this, { jint localport = (*env)->GetIntField(env, this, psi_localportID); int len = 0; - /* fdObj is the FileDescriptor field on this */ jobject fdObj = (*env)->GetObjectField(env, this, psi_fdID); @@ -325,7 +325,8 @@ Java_java_net_PlainSocketImpl_socketConnect(JNIEnv *env, jobject this, /* connection not established immediately */ if (connect_rv != 0) { socklen_t optlen; - jlong prevTime = JVM_CurrentTimeMillis(env, 0); + jlong nanoTimeout = (jlong) timeout * NET_NSEC_PER_MSEC; + jlong prevNanoTime = JVM_NanoTime(env, 0); if (errno != EINPROGRESS) { NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", @@ -341,13 +342,13 @@ Java_java_net_PlainSocketImpl_socketConnect(JNIEnv *env, jobject this, * this thread. */ while (1) { - jlong newTime; + jlong newNanoTime; struct pollfd pfd; pfd.fd = fd; pfd.events = POLLOUT; errno = 0; - connect_rv = NET_Poll(&pfd, 1, timeout); + connect_rv = NET_Poll(&pfd, 1, nanoTimeout / NET_NSEC_PER_MSEC); if (connect_rv >= 0) { break; @@ -360,13 +361,13 @@ Java_java_net_PlainSocketImpl_socketConnect(JNIEnv *env, jobject this, * The poll was interrupted so adjust timeout and * restart */ - newTime = JVM_CurrentTimeMillis(env, 0); - timeout -= (newTime - prevTime); - if (timeout <= 0) { + newNanoTime = JVM_NanoTime(env, 0); + nanoTimeout -= (newNanoTime - prevNanoTime); + if (nanoTimeout < NET_NSEC_PER_MSEC) { connect_rv = 0; break; } - prevTime = newTime; + prevNanoTime = newNanoTime; } /* while */ @@ -593,7 +594,8 @@ Java_java_net_PlainSocketImpl_socketAccept(JNIEnv *env, jobject this, /* fields on this */ int port; jint timeout = (*env)->GetIntField(env, this, psi_timeoutID); - jlong prevTime = 0; + jlong prevNanoTime = 0; + jlong nanoTimeout = (jlong) timeout * NET_NSEC_PER_MSEC; jobject fdObj = (*env)->GetObjectField(env, this, psi_fdID); /* the FileDescriptor field on socket */ @@ -633,18 +635,19 @@ Java_java_net_PlainSocketImpl_socketAccept(JNIEnv *env, jobject this, */ for (;;) { int ret; + jlong currNanoTime; /* first usage pick up current time */ - if (prevTime == 0 && timeout > 0) { - prevTime = JVM_CurrentTimeMillis(env, 0); + if (prevNanoTime == 0 && nanoTimeout > 0) { + prevNanoTime = JVM_NanoTime(env, 0); } /* passing a timeout of 0 to poll will return immediately, but in the case of ServerSocket 0 means infinite. */ if (timeout <= 0) { - ret = NET_Timeout(fd, -1); + ret = NET_Timeout(env, fd, -1, 0); } else { - ret = NET_Timeout(fd, timeout); + ret = NET_Timeout(env, fd, nanoTimeout / NET_NSEC_PER_MSEC, prevNanoTime); } if (ret == 0) { JNU_ThrowByName(env, JNU_JAVANETPKG "SocketTimeoutException", @@ -676,17 +679,14 @@ Java_java_net_PlainSocketImpl_socketAccept(JNIEnv *env, jobject this, } /* ECONNABORTED or EWOULDBLOCK error so adjust timeout if there is one. */ - if (timeout) { - jlong currTime = JVM_CurrentTimeMillis(env, 0); - timeout -= (currTime - prevTime); - - if (timeout <= 0) { - JNU_ThrowByName(env, JNU_JAVANETPKG "SocketTimeoutException", - "Accept timed out"); - return; - } - prevTime = currTime; + currNanoTime = JVM_NanoTime(env, 0); + nanoTimeout -= (currNanoTime - prevNanoTime); + if (nanoTimeout < NET_NSEC_PER_MSEC) { + JNU_ThrowByName(env, JNU_JAVANETPKG "SocketTimeoutException", + "Accept timed out"); + return; } + prevNanoTime = currNanoTime; } if (newfd < 0) { diff --git a/jdk/src/java.base/unix/native/libnet/SocketInputStream.c b/jdk/src/java.base/unix/native/libnet/SocketInputStream.c index 961f53c7baf..7d927bd02a1 100644 --- a/jdk/src/java.base/unix/native/libnet/SocketInputStream.c +++ b/jdk/src/java.base/unix/native/libnet/SocketInputStream.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,7 @@ #include #include +#include "jvm.h" #include "net_util.h" #include "java_net_SocketInputStream.h" @@ -48,9 +49,10 @@ Java_java_net_SocketInputStream_init(JNIEnv *env, jclass cls) { static int NET_ReadWithTimeout(JNIEnv *env, int fd, char *bufP, int len, long timeout) { int result = 0; - long prevtime = NET_GetCurrentTime(), newtime; - while (timeout > 0) { - result = NET_TimeoutWithCurrentTime(fd, timeout, prevtime); + jlong prevNanoTime = JVM_NanoTime(env, 0); + jlong nanoTimeout = (jlong) timeout * NET_NSEC_PER_MSEC; + while (nanoTimeout >= NET_NSEC_PER_MSEC) { + result = NET_Timeout(env, fd, nanoTimeout / NET_NSEC_PER_MSEC, prevNanoTime); if (result <= 0) { if (result == 0) { JNU_ThrowByName(env, "java/net/SocketTimeoutException", "Read timed out"); @@ -68,10 +70,10 @@ static int NET_ReadWithTimeout(JNIEnv *env, int fd, char *bufP, int len, long ti } result = NET_NonBlockingRead(fd, bufP, len); if (result == -1 && ((errno == EAGAIN) || (errno == EWOULDBLOCK))) { - newtime = NET_GetCurrentTime(); - timeout -= newtime - prevtime; - if (timeout > 0) { - prevtime = newtime; + jlong newtNanoTime = JVM_NanoTime(env, 0); + nanoTimeout -= newtNanoTime - prevNanoTime; + if (nanoTimeout >= NET_NSEC_PER_MSEC) { + prevNanoTime = newtNanoTime; } } else { break; diff --git a/jdk/src/java.base/unix/native/libnet/net_util_md.c b/jdk/src/java.base/unix/native/libnet/net_util_md.c index 744fc2f6298..226315f6a69 100644 --- a/jdk/src/java.base/unix/native/libnet/net_util_md.c +++ b/jdk/src/java.base/unix/native/libnet/net_util_md.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -49,6 +49,7 @@ #include #endif +#include "jvm.h" #include "net_util.h" #include "java_net_SocketOptions.h" @@ -1543,11 +1544,12 @@ NET_Bind(int fd, SOCKETADDRESS *sa, int len) jint NET_Wait(JNIEnv *env, jint fd, jint flags, jint timeout) { - jlong prevTime = JVM_CurrentTimeMillis(env, 0); + jlong prevNanoTime = JVM_NanoTime(env, 0); + jlong nanoTimeout = (jlong) timeout * NET_NSEC_PER_MSEC; jint read_rv; while (1) { - jlong newTime; + jlong newNanoTime; struct pollfd pfd; pfd.fd = fd; pfd.events = 0; @@ -1559,36 +1561,18 @@ NET_Wait(JNIEnv *env, jint fd, jint flags, jint timeout) pfd.events |= POLLOUT; errno = 0; - read_rv = NET_Poll(&pfd, 1, timeout); + read_rv = NET_Poll(&pfd, 1, nanoTimeout / NET_NSEC_PER_MSEC); - newTime = JVM_CurrentTimeMillis(env, 0); - timeout -= (newTime - prevTime); - if (timeout <= 0) { + newNanoTime = JVM_NanoTime(env, 0); + nanoTimeout -= (newNanoTime - prevNanoTime); + if (nanoTimeout < NET_NSEC_PER_MSEC) { return read_rv > 0 ? 0 : -1; } - prevTime = newTime; + prevNanoTime = newNanoTime; if (read_rv > 0) { break; } - - } /* while */ - - return timeout; -} - -long NET_GetCurrentTime() { - struct timeval time; - gettimeofday(&time, NULL); - return (time.tv_sec * 1000 + time.tv_usec / 1000); -} - -int NET_TimeoutWithCurrentTime(int s, long timeout, long currentTime) { - return NET_Timeout0(s, timeout, currentTime); -} - -int NET_Timeout(int s, long timeout) { - long currentTime = (timeout > 0) ? NET_GetCurrentTime() : 0; - return NET_Timeout0(s, timeout, currentTime); + return (nanoTimeout / NET_NSEC_PER_MSEC); } diff --git a/jdk/src/java.base/unix/native/libnet/net_util_md.h b/jdk/src/java.base/unix/native/libnet/net_util_md.h index 15e08c48ae9..d6efd2b4a56 100644 --- a/jdk/src/java.base/unix/native/libnet/net_util_md.h +++ b/jdk/src/java.base/unix/native/libnet/net_util_md.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,6 +34,10 @@ * Macros and constants */ +#define NET_NSEC_PER_MSEC 1000000 +#define NET_NSEC_PER_SEC 1000000000 +#define NET_NSEC_PER_USEC 1000 + /* Defines SO_REUSEPORT */ #ifndef SO_REUSEPORT #ifdef __linux__ @@ -68,12 +72,9 @@ typedef union { * Functions */ -int NET_Timeout(int s, long timeout); -int NET_Timeout0(int s, long timeout, long currentTime); +int NET_Timeout(JNIEnv *env, int s, long timeout, jlong nanoTimeStamp); int NET_Read(int s, void* buf, size_t len); int NET_NonBlockingRead(int s, void* buf, size_t len); -int NET_TimeoutWithCurrentTime(int s, long timeout, long currentTime); -long NET_GetCurrentTime(); int NET_RecvFrom(int s, void *buf, int len, unsigned int flags, struct sockaddr *from, socklen_t *fromlen); int NET_ReadV(int s, const struct iovec * vector, int count); diff --git a/jdk/src/java.base/unix/native/libnio/ch/DatagramChannelImpl.c b/jdk/src/java.base/unix/native/libnio/ch/DatagramChannelImpl.c index ef512a1a1f9..8ed0694d04f 100644 --- a/jdk/src/java.base/unix/native/libnio/ch/DatagramChannelImpl.c +++ b/jdk/src/java.base/unix/native/libnio/ch/DatagramChannelImpl.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -90,29 +90,16 @@ Java_sun_nio_ch_DatagramChannelImpl_disconnect0(JNIEnv *env, jobject this, #if defined(__solaris__) rv = connect(fd, 0, 0); #else - int len; SOCKETADDRESS sa; + socklen_t len = isIPv6 ? sizeof(struct sockaddr_in6) : + sizeof(struct sockaddr_in); memset(&sa, 0, sizeof(sa)); - -#ifdef AF_INET6 - if (isIPv6) { #if defined(_ALLBSD_SOURCE) - sa.sa6.sin6_family = AF_INET6; + sa.sa.sa_family = isIPv6 ? AF_INET6 : AF_INET; #else - sa.sa6.sin6_family = AF_UNSPEC; + sa.sa.sa_family = AF_UNSPEC; #endif - len = sizeof(struct sockaddr_in6); - } else -#endif - { -#if defined(_ALLBSD_SOURCE) - sa.sa4.sin_family = AF_INET; -#else - sa.sa4.sin_family = AF_UNSPEC; -#endif - len = sizeof(struct sockaddr_in); - } rv = connect(fd, &sa.sa, len); @@ -126,8 +113,9 @@ Java_sun_nio_ch_DatagramChannelImpl_disconnect0(JNIEnv *env, jobject this, */ if (rv < 0 && errno == EAFNOSUPPORT) rv = errno = 0; -#endif -#endif +#endif // defined(_ALLBSD_SOURCE) || defined(_AIX) + +#endif // defined(__solaris__) if (rv < 0) handleSocketError(env, errno); diff --git a/jdk/src/java.base/unix/native/libnio/ch/InheritedChannel.c b/jdk/src/java.base/unix/native/libnio/ch/InheritedChannel.c index 37ed11a8937..817a38d66da 100644 --- a/jdk/src/java.base/unix/native/libnio/ch/InheritedChannel.c +++ b/jdk/src/java.base/unix/native/libnio/ch/InheritedChannel.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,14 +37,8 @@ #include "sun_nio_ch_InheritedChannel.h" -static int matchFamily(struct sockaddr *sa) { - int family = sa->sa_family; -#ifdef AF_INET6 - if (ipv6_available()) { - return (family == AF_INET6); - } -#endif - return (family == AF_INET); +static int matchFamily(SOCKETADDRESS *sa) { + return (sa->sa.sa_family == (ipv6_available() ? AF_INET6 : AF_INET)); } JNIEXPORT void JNICALL @@ -63,7 +57,7 @@ Java_sun_nio_ch_InheritedChannel_peerAddress0(JNIEnv *env, jclass cla, jint fd) jint remote_port; if (getpeername(fd, &sa.sa, &len) == 0) { - if (matchFamily(&sa.sa)) { + if (matchFamily(&sa)) { remote_ia = NET_SockaddrToInetAddress(env, &sa, (int *)&remote_port); } } @@ -71,7 +65,6 @@ Java_sun_nio_ch_InheritedChannel_peerAddress0(JNIEnv *env, jclass cla, jint fd) return remote_ia; } - JNIEXPORT jint JNICALL Java_sun_nio_ch_InheritedChannel_peerPort0(JNIEnv *env, jclass cla, jint fd) { @@ -80,7 +73,7 @@ Java_sun_nio_ch_InheritedChannel_peerPort0(JNIEnv *env, jclass cla, jint fd) jint remote_port = -1; if (getpeername(fd, &sa.sa, &len) == 0) { - if (matchFamily(&sa.sa)) { + if (matchFamily(&sa)) { NET_SockaddrToInetAddress(env, &sa, (int *)&remote_port); } } @@ -92,7 +85,7 @@ JNIEXPORT jint JNICALL Java_sun_nio_ch_InheritedChannel_soType0(JNIEnv *env, jclass cla, jint fd) { int sotype; - socklen_t arglen=sizeof(sotype); + socklen_t arglen = sizeof(sotype); if (getsockopt(fd, SOL_SOCKET, SO_TYPE, (void *)&sotype, &arglen) == 0) { if (sotype == SOCK_STREAM) return sun_nio_ch_InheritedChannel_SOCK_STREAM; @@ -123,7 +116,7 @@ Java_sun_nio_ch_InheritedChannel_dup2(JNIEnv *env, jclass cla, jint fd, jint fd2 JNIEXPORT jint JNICALL Java_sun_nio_ch_InheritedChannel_open0(JNIEnv *env, jclass cla, jstring path, jint oflag) { - const char* str; + const char *str; int oflag_actual; /* convert to OS specific value */ diff --git a/jdk/src/java.base/unix/native/libnio/ch/Net.c b/jdk/src/java.base/unix/native/libnio/ch/Net.c index dd9aedccdfa..11587114eb7 100644 --- a/jdk/src/java.base/unix/native/libnio/ch/Net.c +++ b/jdk/src/java.base/unix/native/libnio/ch/Net.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -101,23 +101,21 @@ * Copy IPv6 group, interface index, and IPv6 source address * into group_source_req structure. */ -#ifdef AF_INET6 static void initGroupSourceReq(JNIEnv* env, jbyteArray group, jint index, - jbyteArray source, struct group_source_req* req) + jbyteArray source, struct group_source_req *req) { struct sockaddr_in6* sin6; req->gsr_interface = (uint32_t)index; - sin6 = (struct sockaddr_in6*)&(req->gsr_group); + sin6 = (struct sockaddr_in6 *)&(req->gsr_group); sin6->sin6_family = AF_INET6; - COPY_INET6_ADDRESS(env, group, (jbyte*)&(sin6->sin6_addr)); + COPY_INET6_ADDRESS(env, group, (jbyte *)&(sin6->sin6_addr)); - sin6 = (struct sockaddr_in6*)&(req->gsr_source); + sin6 = (struct sockaddr_in6 *)&(req->gsr_source); sin6->sin6_family = AF_INET6; - COPY_INET6_ADDRESS(env, source, (jbyte*)&(sin6->sin6_addr)); + COPY_INET6_ADDRESS(env, source, (jbyte *)&(sin6->sin6_addr)); } -#endif #ifdef _AIX @@ -199,18 +197,13 @@ Java_sun_nio_ch_Net_socket0(JNIEnv *env, jclass cl, jboolean preferIPv6, { int fd; int type = (stream ? SOCK_STREAM : SOCK_DGRAM); -#ifdef AF_INET6 int domain = (ipv6_available() && preferIPv6) ? AF_INET6 : AF_INET; -#else - int domain = AF_INET; -#endif fd = socket(domain, type, 0); if (fd < 0) { return handleSocketError(env, errno); } -#ifdef AF_INET6 /* Disable IPV6_V6ONLY to ensure dual-socket support */ if (domain == AF_INET6) { int arg = 0; @@ -223,7 +216,6 @@ Java_sun_nio_ch_Net_socket0(JNIEnv *env, jclass cl, jboolean preferIPv6, return -1; } } -#endif if (reuse) { int arg = 1; @@ -250,9 +242,7 @@ Java_sun_nio_ch_Net_socket0(JNIEnv *env, jclass cl, jboolean preferIPv6, return -1; } } -#endif -#if defined(__linux__) && defined(AF_INET6) /* By default, Linux uses the route default */ if (domain == AF_INET6 && type == SOCK_DGRAM) { int arg = 1; @@ -569,7 +559,6 @@ JNIEXPORT jint JNICALL Java_sun_nio_ch_Net_joinOrDrop6(JNIEnv *env, jobject this, jboolean join, jobject fdo, jbyteArray group, jint index, jbyteArray source) { -#ifdef AF_INET6 struct ipv6_mreq mreq6; struct group_source_req req; int opt, n, optlen; @@ -600,21 +589,16 @@ Java_sun_nio_ch_Net_joinOrDrop6(JNIEnv *env, jobject this, jboolean join, jobjec handleSocketError(env, errno); } return 0; -#else - JNU_ThrowInternalError(env, "Should not get here"); - return IOS_THROWN; -#endif /* AF_INET6 */ } JNIEXPORT jint JNICALL Java_sun_nio_ch_Net_blockOrUnblock6(JNIEnv *env, jobject this, jboolean block, jobject fdo, jbyteArray group, jint index, jbyteArray source) { -#ifdef AF_INET6 - #ifdef __APPLE__ +#ifdef __APPLE__ /* no IPv6 exclude-mode filtering for now */ return IOS_UNAVAILABLE; - #else +#else struct group_source_req req; int n; int opt = (block) ? MCAST_BLOCK_SOURCE : MCAST_UNBLOCK_SOURCE; @@ -629,10 +613,6 @@ Java_sun_nio_ch_Net_blockOrUnblock6(JNIEnv *env, jobject this, jboolean block, j handleSocketError(env, errno); } return 0; - #endif -#else - JNU_ThrowInternalError(env, "Should not get here"); - return IOS_THROWN; #endif } diff --git a/jdk/src/java.base/windows/native/libjava/WinNTFileSystem_md.c b/jdk/src/java.base/windows/native/libjava/WinNTFileSystem_md.c index 5e1664e31fd..3ffd441c40c 100644 --- a/jdk/src/java.base/windows/native/libjava/WinNTFileSystem_md.c +++ b/jdk/src/java.base/windows/native/libjava/WinNTFileSystem_md.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -472,7 +472,7 @@ Java_java_io_WinNTFileSystem_getLastModifiedTime(JNIEnv *env, jobject this, jobject file) { jlong rv = 0; - LARGE_INTEGER modTime; + ULARGE_INTEGER modTime; FILETIME t; HANDLE h; WCHAR *pathbuf = fileToNTPath(env, file, ids.path); @@ -784,7 +784,7 @@ Java_java_io_WinNTFileSystem_setLastModifiedTime(JNIEnv *env, jobject this, FILE_FLAG_BACKUP_SEMANTICS, 0); if (h != INVALID_HANDLE_VALUE) { - LARGE_INTEGER modTime; + ULARGE_INTEGER modTime; FILETIME t; modTime.QuadPart = (time + 11644473600000L) * 10000L; t.dwLowDateTime = (DWORD)modTime.LowPart; diff --git a/jdk/src/java.base/windows/native/libjli/java_md.c b/jdk/src/java.base/windows/native/libjli/java_md.c index 385fc8ca36d..18739457298 100644 --- a/jdk/src/java.base/windows/native/libjli/java_md.c +++ b/jdk/src/java.base/windows/native/libjli/java_md.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -158,32 +158,10 @@ CreateExecutionEnvironment(int *pargc, char ***pargv, char *jrepath, jint so_jrepath, char *jvmpath, jint so_jvmpath, char *jvmcfg, jint so_jvmcfg) { - char * jvmtype; + + char *jvmtype; int i = 0; - int running = CURRENT_DATA_MODEL; - - int wanted = running; - char** argv = *pargv; - for (i = 1; i < *pargc ; i++) { - if (JLI_StrCmp(argv[i], "-J-d64") == 0 || JLI_StrCmp(argv[i], "-d64") == 0) { - wanted = 64; - continue; - } - if (JLI_StrCmp(argv[i], "-J-d32") == 0 || JLI_StrCmp(argv[i], "-d32") == 0) { - wanted = 32; - continue; - } - - if (IsJavaArgs() && argv[i][0] != '-') - continue; - if (argv[i][0] != '-') - break; - } - if (running != wanted) { - JLI_ReportErrorMessage(JRE_ERROR2, wanted); - exit(1); - } /* Find out where the JRE is that we will be using. */ if (!GetJREPath(jrepath, so_jrepath)) { diff --git a/jdk/src/java.base/windows/native/libnet/Inet4AddressImpl.c b/jdk/src/java.base/windows/native/libnet/Inet4AddressImpl.c index 8a901af9af4..ea16f7bbc25 100644 --- a/jdk/src/java.base/windows/native/libnet/Inet4AddressImpl.c +++ b/jdk/src/java.base/windows/native/libnet/Inet4AddressImpl.c @@ -29,60 +29,6 @@ #include "java_net_InetAddress.h" #include "java_net_Inet4AddressImpl.h" -/* - * Returns true if hostname is in dotted IP address format. Note that this - * function performs a syntax check only. For each octet it just checks that - * the octet is at most 3 digits. - */ -jboolean isDottedIPAddress(const char *hostname, unsigned int *addrp) { - char *c = (char *)hostname; - int octets = 0; - unsigned int cur = 0; - int digit_cnt = 0; - - while (*c) { - if (*c == '.') { - if (digit_cnt == 0) { - return JNI_FALSE; - } else { - if (octets < 4) { - addrp[octets++] = cur; - cur = 0; - digit_cnt = 0; - } else { - return JNI_FALSE; - } - } - c++; - continue; - } - - if ((*c < '0') || (*c > '9')) { - return JNI_FALSE; - } - - digit_cnt++; - if (digit_cnt > 3) { - return JNI_FALSE; - } - - /* don't check if current octet > 255 */ - cur = cur*10 + (*c - '0'); - - /* Move onto next character and check for EOF */ - c++; - if (*c == '\0') { - if (octets < 4) { - addrp[octets++] = cur; - } else { - return JNI_FALSE; - } - } - } - - return (jboolean)(octets == 4); -} - /* * Inet4AddressImpl */ @@ -93,17 +39,17 @@ jboolean isDottedIPAddress(const char *hostname, unsigned int *addrp) { * Signature: ()Ljava/lang/String; */ JNIEXPORT jstring JNICALL -Java_java_net_Inet4AddressImpl_getLocalHostName (JNIEnv *env, jobject this) { +Java_java_net_Inet4AddressImpl_getLocalHostName(JNIEnv *env, jobject this) { char hostname[256]; - if (gethostname(hostname, sizeof hostname) == -1) { + if (gethostname(hostname, sizeof(hostname)) == -1) { strcpy(hostname, "localhost"); } return JNU_NewStringPlatform(env, hostname); } /* - * Find an internet address for a given hostname. Not this this + * Find an internet address for a given hostname. Note that this * code only works for addresses of type INET. The translation * of %d.%d.%d.%d to an address (int) occurs in java now, so the * String "host" shouldn't be a %d.%d.%d.%d string. The only @@ -120,7 +66,6 @@ Java_java_net_Inet4AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, jobjectArray ret = NULL; const char *hostname; int error = 0; - unsigned int addr[4]; struct addrinfo hints, *res = NULL, *resNew = NULL, *last = NULL, *iterator; @@ -134,57 +79,6 @@ Java_java_net_Inet4AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, hostname = JNU_GetStringPlatformChars(env, host, JNI_FALSE); CHECK_NULL_RETURN(hostname, NULL); - /* - * The NT/2000 resolver tolerates a space in front of localhost. This - * is not consistent with other implementations of gethostbyname. - * In addition we must do a white space check on Solaris to avoid a - * bug whereby 0.0.0.0 is returned if any host name has a white space. - */ - if (isspace(hostname[0])) { - JNU_ThrowByName(env, JNU_JAVANETPKG "UnknownHostException", hostname); - goto cleanupAndReturn; - } - - /* - * If the format is x.x.x.x then don't use gethostbyname as Windows - * is unable to handle octets which are out of range. - */ - if (isDottedIPAddress(hostname, &addr[0])) { - unsigned int address; - jobject iaObj; - - /* - * Are any of the octets out of range? - */ - if (addr[0] > 255 || addr[1] > 255 || addr[2] > 255 || addr[3] > 255) { - JNU_ThrowByName(env, JNU_JAVANETPKG "UnknownHostException", hostname); - goto cleanupAndReturn; - } - - /* - * Return an byte array with the populated address. - */ - address = (addr[3] << 24) & 0xff000000; - address |= (addr[2] << 16) & 0xff0000; - address |= (addr[1] << 8) & 0xff00; - address |= addr[0]; - - ret = (*env)->NewObjectArray(env, 1, ia_class, NULL); - - if (IS_NULL(ret)) { - goto cleanupAndReturn; - } - - iaObj = (*env)->NewObject(env, ia4_class, ia4_ctrID); - if (IS_NULL(iaObj)) { - ret = NULL; - goto cleanupAndReturn; - } - setInetAddress_addr(env, iaObj, ntohl(address)); - (*env)->SetObjectArrayElement(env, ret, 0, iaObj); - goto cleanupAndReturn; - } - // try once, with our static buffer memset(&hints, 0, sizeof(hints)); hints.ai_flags = AI_CANONNAME; @@ -193,6 +87,7 @@ Java_java_net_Inet4AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, error = getaddrinfo(hostname, NULL, &hints, &res); if (error) { + // report error NET_ThrowByNameWithLastError(env, "java/net/UnknownHostException", hostname); goto cleanupAndReturn; @@ -311,145 +206,86 @@ Java_java_net_Inet4AddressImpl_getHostByAddr(JNIEnv *env, jobject this, return ret; } +/** + * ping implementation using tcp port 7 (echo) + */ static jboolean -tcp_ping4(JNIEnv *env, - jbyteArray addrArray, - jint timeout, - jbyteArray ifArray, +tcp_ping4(JNIEnv *env, SOCKETADDRESS *sa, SOCKETADDRESS *netif, jint timeout, jint ttl) { - jint addr; - jbyte caddr[4]; jint fd; - struct sockaddr_in him; - struct sockaddr_in* netif = NULL; - struct sockaddr_in inf; - int len = 0; - WSAEVENT hEvent; int connect_rv = -1; - int sz; + WSAEVENT hEvent; - /** - * Convert IP address from byte array to integer - */ - sz = (*env)->GetArrayLength(env, addrArray); - if (sz != 4) { - return JNI_FALSE; - } - memset((char *) &him, 0, sizeof(him)); - memset((char *) caddr, 0, sizeof(caddr)); - (*env)->GetByteArrayRegion(env, addrArray, 0, 4, caddr); - addr = ((caddr[0]<<24) & 0xff000000); - addr |= ((caddr[1] <<16) & 0xff0000); - addr |= ((caddr[2] <<8) & 0xff00); - addr |= (caddr[3] & 0xff); - addr = htonl(addr); - /** - * Socket address - */ - him.sin_addr.s_addr = addr; - him.sin_family = AF_INET; - len = sizeof(him); - - /** - * If a network interface was specified, let's convert its address - * as well. - */ - if (!(IS_NULL(ifArray))) { - memset((char *) caddr, 0, sizeof(caddr)); - (*env)->GetByteArrayRegion(env, ifArray, 0, 4, caddr); - addr = ((caddr[0]<<24) & 0xff000000); - addr |= ((caddr[1] <<16) & 0xff0000); - addr |= ((caddr[2] <<8) & 0xff00); - addr |= (caddr[3] & 0xff); - addr = htonl(addr); - inf.sin_addr.s_addr = addr; - inf.sin_family = AF_INET; - inf.sin_port = 0; - netif = &inf; - } - - /* - * Can't create a raw socket, so let's try a TCP socket - */ + // open a TCP socket fd = NET_Socket(AF_INET, SOCK_STREAM, 0); - if (fd == -1) { - /* note: if you run out of fds, you may not be able to load - * the exception class, and get a NoClassDefFoundError - * instead. - */ + if (fd == SOCKET_ERROR) { + // note: if you run out of fds, you may not be able to load + // the exception class, and get a NoClassDefFoundError instead. NET_ThrowNew(env, WSAGetLastError(), "Can't create socket"); return JNI_FALSE; } + + // set TTL if (ttl > 0) { setsockopt(fd, IPPROTO_IP, IP_TTL, (const char *)&ttl, sizeof(ttl)); } - /* - * A network interface was specified, so let's bind to it. - */ + + // A network interface was specified, so let's bind to it. if (netif != NULL) { - if (bind(fd, (struct sockaddr*)netif, sizeof(struct sockaddr_in)) < 0) { + if (bind(fd, &netif->sa, sizeof(struct sockaddr_in)) < 0) { NET_ThrowNew(env, WSAGetLastError(), "Can't bind socket"); closesocket(fd); return JNI_FALSE; } } - /* - * Make the socket non blocking so we can use select/poll. - */ + // Make the socket non blocking so we can use select/poll. hEvent = WSACreateEvent(); WSAEventSelect(fd, hEvent, FD_READ|FD_CONNECT|FD_CLOSE); - /* no need to use NET_Connect as non-blocking */ - him.sin_port = htons(7); /* Echo */ - connect_rv = connect(fd, (struct sockaddr *)&him, len); + sa->sa4.sin_port = htons(7); // echo port + connect_rv = connect(fd, &sa->sa, sizeof(struct sockaddr_in)); - /** - * connection established or refused immediately, either way it means - * we were able to reach the host! - */ + // connection established or refused immediately, either way it means + // we were able to reach the host! if (connect_rv == 0 || WSAGetLastError() == WSAECONNREFUSED) { WSACloseEvent(hEvent); closesocket(fd); return JNI_TRUE; - } else { - int optlen; + } - switch (WSAGetLastError()) { - case WSAEHOSTUNREACH: /* Host Unreachable */ - case WSAENETUNREACH: /* Network Unreachable */ - case WSAENETDOWN: /* Network is down */ - case WSAEPFNOSUPPORT: /* Protocol Family unsupported */ + switch (WSAGetLastError()) { + case WSAEHOSTUNREACH: // Host Unreachable + case WSAENETUNREACH: // Network Unreachable + case WSAENETDOWN: // Network is down + case WSAEPFNOSUPPORT: // Protocol Family unsupported + WSACloseEvent(hEvent); + closesocket(fd); + return JNI_FALSE; + case WSAEWOULDBLOCK: // this is expected as we'll probably have to wait + break; + default: + NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", + "connect failed"); + WSACloseEvent(hEvent); + closesocket(fd); + return JNI_FALSE; + } + + timeout = NET_Wait(env, fd, NET_WAIT_CONNECT, timeout); + if (timeout >= 0) { + // connection has been established, check for error condition + int optlen = sizeof(connect_rv); + if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void *)&connect_rv, + &optlen) < 0) + { + connect_rv = WSAGetLastError(); + } + if (connect_rv == 0 || connect_rv == WSAECONNREFUSED) { WSACloseEvent(hEvent); closesocket(fd); - return JNI_FALSE; - } - - if (WSAGetLastError() != WSAEWOULDBLOCK) { - NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", - "connect failed"); - WSACloseEvent(hEvent); - closesocket(fd); - return JNI_FALSE; - } - - timeout = NET_Wait(env, fd, NET_WAIT_CONNECT, timeout); - - /* has connection been established */ - - if (timeout >= 0) { - optlen = sizeof(connect_rv); - if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&connect_rv, - &optlen) <0) { - connect_rv = WSAGetLastError(); - } - - if (connect_rv == 0 || connect_rv == WSAECONNREFUSED) { - WSACloseEvent(hEvent); - closesocket(fd); - return JNI_TRUE; - } + return JNI_TRUE; } } WSACloseEvent(hEvent); @@ -464,21 +300,17 @@ tcp_ping4(JNIEnv *env, * Returns true is an ECHO_REPLY is received, otherwise, false. */ static jboolean -ping4(JNIEnv *env, - unsigned long src_addr, - unsigned long dest_addr, - jint timeout, - HANDLE hIcmpFile) +ping4(JNIEnv *env, HANDLE hIcmpFile, SOCKETADDRESS *sa, + SOCKETADDRESS *netif, jint timeout) { - // See https://msdn.microsoft.com/en-us/library/aa366050%28VS.85%29.aspx - DWORD dwRetVal = 0; char SendData[32] = {0}; LPVOID ReplyBuffer = NULL; DWORD ReplySize = 0; jboolean ret = JNI_FALSE; - // https://msdn.microsoft.com/en-us/library/windows/desktop/aa366051%28v=vs.85%29.aspx + // See https://msdn.microsoft.com/en-us/library/aa366050%28VS.85%29.aspx + // or https://msdn.microsoft.com/en-us/library/windows/desktop/aa366051%28v=vs.85%29.aspx ReplySize = sizeof(ICMP_ECHO_REPLY) // The buffer should be large enough // to hold at least one ICMP_ECHO_REPLY // structure @@ -487,16 +319,16 @@ ping4(JNIEnv *env, // to also hold 8 more bytes of data // (the size of an ICMP error message) - ReplyBuffer = (VOID*) malloc(ReplySize); + ReplyBuffer = (VOID *)malloc(ReplySize); if (ReplyBuffer == NULL) { IcmpCloseHandle(hIcmpFile); NET_ThrowNew(env, WSAGetLastError(), "Unable to allocate memory"); return JNI_FALSE; } - if (src_addr == 0) { + if (netif == NULL) { dwRetVal = IcmpSendEcho(hIcmpFile, // HANDLE IcmpHandle, - dest_addr, // IPAddr DestinationAddress, + sa->sa4.sin_addr.s_addr, // IPAddr DestinationAddress, SendData, // LPVOID RequestData, sizeof(SendData), // WORD RequestSize, NULL, // PIP_OPTION_INFORMATION RequestOptions, @@ -506,20 +338,20 @@ ping4(JNIEnv *env, // seem to have an undocumented minimum // timeout of 1000ms below which the // api behaves inconsistently. - (timeout < 1000) ? 1000 : timeout); // DWORD Timeout + (timeout < 1000) ? 1000 : timeout); // DWORD Timeout } else { dwRetVal = IcmpSendEcho2Ex(hIcmpFile, // HANDLE IcmpHandle, NULL, // HANDLE Event NULL, // PIO_APC_ROUTINE ApcRoutine NULL, // ApcContext - src_addr, // IPAddr SourceAddress, - dest_addr, // IPAddr DestinationAddress, + netif->sa4.sin_addr.s_addr, // IPAddr SourceAddress, + sa->sa4.sin_addr.s_addr, // IPAddr DestinationAddress, SendData, // LPVOID RequestData, - sizeof(SendData), // WORD RequestSize, + sizeof(SendData), // WORD RequestSize, NULL, // PIP_OPTION_INFORMATION RequestOptions, ReplyBuffer,// LPVOID ReplyBuffer, ReplySize, // DWORD ReplySize, - (timeout < 1000) ? 1000 : timeout); // DWORD Timeout + (timeout < 1000) ? 1000 : timeout); // DWORD Timeout } if (dwRetVal == 0) { // if the call failed @@ -544,8 +376,8 @@ ping4(JNIEnv *env, break; default: FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, - NULL, err, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), - (LPTSTR)&buf, 0, NULL); + NULL, err, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), + (LPTSTR)&buf, 0, NULL); NET_ThrowNew(env, err, buf); LocalFree(buf); break; @@ -558,8 +390,8 @@ ping4(JNIEnv *env, // We perform an extra check to make sure that our // roundtrip time was less than our desired timeout // for cases where that timeout is < 1000ms. - if (pEchoReply->Status == IP_SUCCESS - && (int)pEchoReply->RoundTripTime <= timeout) + if (pEchoReply->Status == IP_SUCCESS && + (int)pEchoReply->RoundTripTime <= timeout) { ret = JNI_TRUE; } @@ -578,57 +410,58 @@ ping4(JNIEnv *env, */ JNIEXPORT jboolean JNICALL Java_java_net_Inet4AddressImpl_isReachable0(JNIEnv *env, jobject this, - jbyteArray addrArray, - jint timeout, - jbyteArray ifArray, - jint ttl) { - jint src_addr = 0; - jint dest_addr = 0; + jbyteArray addrArray, jint timeout, + jbyteArray ifArray, jint ttl) +{ jbyte caddr[4]; - int sz; + jint addr = 0, sz; + SOCKETADDRESS sa, inf, *netif = NULL; HANDLE hIcmpFile; - /** - * Convert IP address from byte array to integer - */ + // check if address array size is 4 (IPv4 address) sz = (*env)->GetArrayLength(env, addrArray); if (sz != 4) { return JNI_FALSE; } - memset((char *) caddr, 0, sizeof(caddr)); - (*env)->GetByteArrayRegion(env, addrArray, 0, 4, caddr); - dest_addr = ((caddr[0]<<24) & 0xff000000); - dest_addr |= ((caddr[1] <<16) & 0xff0000); - dest_addr |= ((caddr[2] <<8) & 0xff00); - dest_addr |= (caddr[3] & 0xff); - dest_addr = htonl(dest_addr); - /** - * If a network interface was specified, let's convert its address - * as well. - */ + // convert IP address from byte array to integer + memset((char *)caddr, 0, sizeof(caddr)); + (*env)->GetByteArrayRegion(env, addrArray, 0, 4, caddr); + addr = ((caddr[0] << 24) & 0xff000000); + addr |= ((caddr[1] << 16) & 0xff0000); + addr |= ((caddr[2] << 8) & 0xff00); + addr |= (caddr[3] & 0xff); + memset((char *)&sa, 0, sizeof(SOCKETADDRESS)); + sa.sa4.sin_addr.s_addr = htonl(addr); + sa.sa4.sin_family = AF_INET; + + // If a network interface was specified, let's convert its address as well. if (!(IS_NULL(ifArray))) { - memset((char *) caddr, 0, sizeof(caddr)); + memset((char *)caddr, 0, sizeof(caddr)); (*env)->GetByteArrayRegion(env, ifArray, 0, 4, caddr); - src_addr = ((caddr[0]<<24) & 0xff000000); - src_addr |= ((caddr[1] <<16) & 0xff0000); - src_addr |= ((caddr[2] <<8) & 0xff00); - src_addr |= (caddr[3] & 0xff); - src_addr = htonl(src_addr); + addr = ((caddr[0] << 24) & 0xff000000); + addr |= ((caddr[1] << 16) & 0xff0000); + addr |= ((caddr[2] << 8) & 0xff00); + addr |= (caddr[3] & 0xff); + memset((char *)&inf, 0, sizeof(SOCKETADDRESS)); + inf.sa4.sin_addr.s_addr = htonl(addr); + inf.sa4.sin_family = AF_INET; + netif = &inf; } + // Let's try to create an ICMP handle. hIcmpFile = IcmpCreateFile(); if (hIcmpFile == INVALID_HANDLE_VALUE) { int err = WSAGetLastError(); if (err == ERROR_ACCESS_DENIED) { // fall back to TCP echo if access is denied to ICMP - return tcp_ping4(env, addrArray, timeout, ifArray, ttl); + return tcp_ping4(env, &sa, netif, timeout, ttl); } else { NET_ThrowNew(env, err, "Unable to create ICMP file handle"); return JNI_FALSE; } } else { - return ping4(env, src_addr, dest_addr, timeout, hIcmpFile); + // It didn't fail, so we can use ICMP. + return ping4(env, hIcmpFile, &sa, netif, timeout); } } - diff --git a/jdk/src/java.base/windows/native/libnet/Inet6AddressImpl.c b/jdk/src/java.base/windows/native/libnet/Inet6AddressImpl.c index e07f8a3e46b..0b3fdb8b279 100644 --- a/jdk/src/java.base/windows/native/libnet/Inet6AddressImpl.c +++ b/jdk/src/java.base/windows/native/libnet/Inet6AddressImpl.c @@ -40,41 +40,40 @@ * Signature: ()Ljava/lang/String; */ JNIEXPORT jstring JNICALL -Java_java_net_Inet6AddressImpl_getLocalHostName (JNIEnv *env, jobject this) { - char hostname [256]; +Java_java_net_Inet6AddressImpl_getLocalHostName(JNIEnv *env, jobject this) { + char hostname[256]; - if (gethostname (hostname, sizeof (hostname)) == -1) { - strcpy (hostname, "localhost"); + if (gethostname(hostname, sizeof(hostname)) == -1) { + strcpy(hostname, "localhost"); } - return JNU_NewStringPlatform (env, hostname); + return JNU_NewStringPlatform(env, hostname); } +/* + * Class: java_net_Inet6AddressImpl + * Method: lookupAllHostAddr + * Signature: (Ljava/lang/String;)[[B + */ JNIEXPORT jobjectArray JNICALL Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, - jstring host) { + jstring host) { + jobjectArray ret = NULL; const char *hostname; - jobjectArray ret = 0; - int retLen = 0; - jboolean preferIPv6Address; - - int error=0; - struct addrinfo hints, *res = NULL, *resNew = NULL; + int error = 0; + struct addrinfo hints, *res = NULL, *resNew = NULL, *last = NULL, + *iterator; initInetAddressIDs(env); JNU_CHECK_EXCEPTION_RETURN(env, NULL); if (IS_NULL(host)) { - JNU_ThrowNullPointerException(env, "host is null"); - return 0; + JNU_ThrowNullPointerException(env, "host argument is null"); + return NULL; } hostname = JNU_GetStringPlatformChars(env, host, JNI_FALSE); CHECK_NULL_RETURN(hostname, NULL); - /* get the address preference */ - preferIPv6Address - = (*env)->GetStaticIntField(env, ia_class, ia_preferIPv6AddressID); - - /* Try once, with our static buffer. */ + // try once, with our static buffer memset(&hints, 0, sizeof(hints)); hints.ai_flags = AI_CANONNAME; hints.ai_family = AF_UNSPEC; @@ -82,35 +81,28 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, error = getaddrinfo(hostname, NULL, &hints, &res); if (error) { - if (WSAGetLastError() == WSATRY_AGAIN) { - NET_ThrowByNameWithLastError(env, - JNU_JAVANETPKG "UnknownHostException", - hostname); - JNU_ReleaseStringPlatformChars(env, host, hostname); - return NULL; - } else { - /* report error */ - JNU_ThrowByName(env, JNU_JAVANETPKG "UnknownHostException", - (char *)hostname); - JNU_ReleaseStringPlatformChars(env, host, hostname); - return NULL; - } + // report error + NET_ThrowByNameWithLastError(env, "java/net/UnknownHostException", + hostname); + goto cleanupAndReturn; } else { - int i = 0; - int inetCount = 0, inet6Count = 0, inetIndex = 0, inet6Index = 0, originalIndex = 0; - struct addrinfo *itr, *last, *iterator = res; + int i = 0, inetCount = 0, inet6Count = 0, inetIndex = 0, + inet6Index = 0, originalIndex = 0; + int addressPreference = + (*env)->GetStaticIntField(env, ia_class, ia_preferIPv6AddressID); + iterator = res; while (iterator != NULL) { + // skip duplicates int skip = 0; - itr = resNew; - while (itr != NULL) { - if (iterator->ai_family == itr->ai_family && - iterator->ai_addrlen == itr->ai_addrlen) { - if (itr->ai_family == AF_INET) { /* AF_INET */ + struct addrinfo *iteratorNew = resNew; + while (iteratorNew != NULL) { + if (iterator->ai_family == iteratorNew->ai_family && + iterator->ai_addrlen == iteratorNew->ai_addrlen) { + if (iteratorNew->ai_family == AF_INET) { /* AF_INET */ struct sockaddr_in *addr1, *addr2; addr1 = (struct sockaddr_in *)iterator->ai_addr; - addr2 = (struct sockaddr_in *)itr->ai_addr; - if (addr1->sin_addr.s_addr == - addr2->sin_addr.s_addr) { + addr2 = (struct sockaddr_in *)iteratorNew->ai_addr; + if (addr1->sin_addr.s_addr == addr2->sin_addr.s_addr) { skip = 1; break; } @@ -118,7 +110,7 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, int t; struct sockaddr_in6 *addr1, *addr2; addr1 = (struct sockaddr_in6 *)iterator->ai_addr; - addr2 = (struct sockaddr_in6 *)itr->ai_addr; + addr2 = (struct sockaddr_in6 *)iteratorNew->ai_addr; for (t = 0; t < 16; t++) { if (addr1->sin6_addr.s6_addr[t] != @@ -127,7 +119,7 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, } } if (t < 16) { - itr = itr->ai_next; + iteratorNew = iteratorNew->ai_next; continue; } else { skip = 1; @@ -136,16 +128,16 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, } } else if (iterator->ai_family != AF_INET && iterator->ai_family != AF_INET6) { - /* we can't handle other family types */ + // we can't handle other family types skip = 1; break; } - itr = itr->ai_next; + iteratorNew = iteratorNew->ai_next; } if (!skip) { struct addrinfo *next - = (struct addrinfo*) malloc(sizeof(struct addrinfo)); + = (struct addrinfo *)malloc(sizeof(struct addrinfo)); if (!next) { JNU_ThrowOutOfMemoryError(env, "Native heap allocation failed"); ret = NULL; @@ -161,87 +153,81 @@ Java_java_net_Inet6AddressImpl_lookupAllHostAddr(JNIEnv *env, jobject this, last = next; i++; if (iterator->ai_family == AF_INET) { - inetCount ++; + inetCount++; } else if (iterator->ai_family == AF_INET6) { - inet6Count ++; + inet6Count++; } } iterator = iterator->ai_next; } - retLen = i; - iterator = resNew; - i = 0; - ret = (*env)->NewObjectArray(env, retLen, ia_class, NULL); + // allocate array - at this point i contains the number of addresses + ret = (*env)->NewObjectArray(env, i, ia_class, NULL); if (IS_NULL(ret)) { /* we may have memory to free at the end of this */ goto cleanupAndReturn; } - if (preferIPv6Address == java_net_InetAddress_PREFER_IPV6_VALUE) { + if (addressPreference == java_net_InetAddress_PREFER_IPV6_VALUE) { inetIndex = inet6Count; inet6Index = 0; - } else if (preferIPv6Address == java_net_InetAddress_PREFER_IPV4_VALUE) { + } else if (addressPreference == java_net_InetAddress_PREFER_IPV4_VALUE) { inetIndex = 0; inet6Index = inetCount; - } else if (preferIPv6Address == java_net_InetAddress_PREFER_SYSTEM_VALUE) { + } else if (addressPreference == java_net_InetAddress_PREFER_SYSTEM_VALUE) { inetIndex = inet6Index = originalIndex = 0; } + iterator = resNew; while (iterator != NULL) { if (iterator->ai_family == AF_INET) { - jobject iaObj = (*env)->NewObject(env, ia4_class, ia4_ctrID); - if (IS_NULL(iaObj)) { - ret = NULL; - goto cleanupAndReturn; - } - setInetAddress_addr(env, iaObj, ntohl(((struct sockaddr_in*)iterator->ai_addr)->sin_addr.s_addr)); - setInetAddress_hostName(env, iaObj, host); - (*env)->SetObjectArrayElement(env, ret, (inetIndex | originalIndex), iaObj); - inetIndex ++; + jobject iaObj = (*env)->NewObject(env, ia4_class, ia4_ctrID); + if (IS_NULL(iaObj)) { + ret = NULL; + goto cleanupAndReturn; + } + setInetAddress_addr(env, iaObj, ntohl(((struct sockaddr_in*)iterator->ai_addr)->sin_addr.s_addr)); + setInetAddress_hostName(env, iaObj, host); + (*env)->SetObjectArrayElement(env, ret, (inetIndex | originalIndex), iaObj); + inetIndex++; } else if (iterator->ai_family == AF_INET6) { - jint scope = 0; - jboolean ret1; - jobject iaObj = (*env)->NewObject(env, ia6_class, ia6_ctrID); - if (IS_NULL(iaObj)) { - ret = NULL; - goto cleanupAndReturn; - } - ret1 = setInet6Address_ipaddress(env, iaObj, (jbyte *)&(((struct sockaddr_in6*)iterator->ai_addr)->sin6_addr)); - if (ret1 == JNI_FALSE) { - ret = NULL; - goto cleanupAndReturn; - } - scope = ((struct sockaddr_in6*)iterator->ai_addr)->sin6_scope_id; - if (scope != 0) { /* zero is default value, no need to set */ - setInet6Address_scopeid(env, iaObj, scope); - } - setInetAddress_hostName(env, iaObj, host); - (*env)->SetObjectArrayElement(env, ret, (inet6Index | originalIndex), iaObj); - inet6Index ++; + jint scope = 0; + jboolean ret1; + jobject iaObj = (*env)->NewObject(env, ia6_class, ia6_ctrID); + if (IS_NULL(iaObj)) { + ret = NULL; + goto cleanupAndReturn; + } + ret1 = setInet6Address_ipaddress(env, iaObj, (char *)&(((struct sockaddr_in6*)iterator->ai_addr)->sin6_addr)); + if (ret1 == JNI_FALSE) { + ret = NULL; + goto cleanupAndReturn; + } + scope = ((struct sockaddr_in6 *)iterator->ai_addr)->sin6_scope_id; + if (scope != 0) { // zero is default value, no need to set + setInet6Address_scopeid(env, iaObj, scope); + } + setInetAddress_hostName(env, iaObj, host); + (*env)->SetObjectArrayElement(env, ret, (inet6Index | originalIndex), iaObj); + inet6Index++; } - if (preferIPv6Address == java_net_InetAddress_PREFER_SYSTEM_VALUE) { + if (addressPreference == java_net_InetAddress_PREFER_SYSTEM_VALUE) { originalIndex++; inetIndex = inet6Index = 0; } iterator = iterator->ai_next; } } - cleanupAndReturn: - { - struct addrinfo *iterator, *tmp; - iterator = resNew; - while (iterator != NULL) { - tmp = iterator; - iterator = iterator->ai_next; - free(tmp); - } - JNU_ReleaseStringPlatformChars(env, host, hostname); + JNU_ReleaseStringPlatformChars(env, host, hostname); + while (resNew != NULL) { + last = resNew; + resNew = resNew->ai_next; + free(last); + } + if (res != NULL) { + freeaddrinfo(res); } - - freeaddrinfo(res); - return ret; } @@ -249,57 +235,48 @@ cleanupAndReturn: * Class: java_net_Inet6AddressImpl * Method: getHostByAddr * Signature: (I)Ljava/lang/String; + * + * Theoretically the UnknownHostException could be enriched with gai error + * information. But as it is silently ignored anyway, there's no need for this. + * It's only important that either a valid hostname is returned or an + * UnknownHostException is thrown. */ JNIEXPORT jstring JNICALL Java_java_net_Inet6AddressImpl_getHostByAddr(JNIEnv *env, jobject this, - jbyteArray addrArray) { + jbyteArray addrArray) { jstring ret = NULL; - - char host[NI_MAXHOST+1]; - int error = 0; + char host[NI_MAXHOST + 1]; int len = 0; jbyte caddr[16]; + SOCKETADDRESS sa; - struct sockaddr_in him4; - struct sockaddr_in6 him6; - struct sockaddr *sa; + memset((void *)&sa, 0, sizeof(SOCKETADDRESS)); - /* - * For IPv4 addresses construct a sockaddr_in structure. - */ + // construct a sockaddr_in structure (AF_INET or AF_INET6) if ((*env)->GetArrayLength(env, addrArray) == 4) { jint addr; (*env)->GetByteArrayRegion(env, addrArray, 0, 4, caddr); - addr = ((caddr[0]<<24) & 0xff000000); - addr |= ((caddr[1] <<16) & 0xff0000); - addr |= ((caddr[2] <<8) & 0xff00); + addr = ((caddr[0] << 24) & 0xff000000); + addr |= ((caddr[1] << 16) & 0xff0000); + addr |= ((caddr[2] << 8) & 0xff00); addr |= (caddr[3] & 0xff); - memset((char *) &him4, 0, sizeof(him4)); - him4.sin_addr.s_addr = htonl(addr); - him4.sin_family = AF_INET; - sa = (struct sockaddr *) &him4; - len = sizeof(him4); + sa.sa4.sin_addr.s_addr = htonl(addr); + sa.sa4.sin_family = AF_INET; + len = sizeof(struct sockaddr_in); } else { - /* - * For IPv6 address construct a sockaddr_in6 structure. - */ (*env)->GetByteArrayRegion(env, addrArray, 0, 16, caddr); - memset((char *) &him6, 0, sizeof(him6)); - memcpy((void *)&(him6.sin6_addr), caddr, sizeof(struct in6_addr) ); - him6.sin6_family = AF_INET6; - sa = (struct sockaddr *) &him6 ; - len = sizeof(him6) ; + memcpy((void *)&sa.sa6.sin6_addr, caddr, sizeof(struct in6_addr)); + sa.sa6.sin6_family = AF_INET6; + len = sizeof(struct sockaddr_in6); } - error = getnameinfo(sa, len, host, NI_MAXHOST, NULL, 0, NI_NAMEREQD); - - if (!error) { + if (getnameinfo(&sa.sa, len, host, NI_MAXHOST, NULL, 0, NI_NAMEREQD)) { + JNU_ThrowByName(env, "java/net/UnknownHostException", NULL); + } else { ret = (*env)->NewStringUTF(env, host); - CHECK_NULL_RETURN(ret, NULL); - } - - if (ret == NULL) { - JNU_ThrowByName(env, JNU_JAVANETPKG "UnknownHostException", NULL); + if (ret == NULL) { + JNU_ThrowByName(env, "java/net/UnknownHostException", NULL); + } } return ret; @@ -309,99 +286,82 @@ Java_java_net_Inet6AddressImpl_getHostByAddr(JNIEnv *env, jobject this, * ping implementation using tcp port 7 (echo) */ static jboolean -tcp_ping6(JNIEnv *env, - jint timeout, - jint ttl, - struct sockaddr_in6 him6, - struct sockaddr_in6* netif, - int len) +tcp_ping6(JNIEnv *env, SOCKETADDRESS *sa, SOCKETADDRESS *netif, jint timeout, + jint ttl) { jint fd; - WSAEVENT hEvent; int connect_rv = -1; + WSAEVENT hEvent; + // open a TCP socket fd = NET_Socket(AF_INET6, SOCK_STREAM, 0); if (fd == SOCKET_ERROR) { - /* note: if you run out of fds, you may not be able to load - * the exception class, and get a NoClassDefFoundError - * instead. - */ - NET_ThrowNew(env, errno, "Can't create socket"); + // note: if you run out of fds, you may not be able to load + // the exception class, and get a NoClassDefFoundError instead. + NET_ThrowNew(env, WSAGetLastError(), "Can't create socket"); return JNI_FALSE; } - /** - * A TTL was specified, let's set the socket option. - */ + // set TTL if (ttl > 0) { - setsockopt(fd, IPPROTO_IPV6, IPV6_UNICAST_HOPS, (const char *)&ttl, sizeof(ttl)); + setsockopt(fd, IPPROTO_IPV6, IPV6_UNICAST_HOPS, (const char *)&ttl, sizeof(ttl)); } - /** - * A network interface was specified, let's bind to it. - */ + // A network interface was specified, so let's bind to it. if (netif != NULL) { - if (NET_Bind(fd, (struct sockaddr*)netif, sizeof(struct sockaddr_in6)) < 0) { - NET_ThrowNew(env, WSAGetLastError(), "Can't bind socket to interface"); - closesocket(fd); - return JNI_FALSE; - } + if (bind(fd, &netif->sa, sizeof(struct sockaddr_in6)) < 0) { + NET_ThrowNew(env, WSAGetLastError(), "Can't bind socket to interface"); + closesocket(fd); + return JNI_FALSE; + } } - /** - * Make the socket non blocking. - */ + // Make the socket non blocking so we can use select/poll. hEvent = WSACreateEvent(); WSAEventSelect(fd, hEvent, FD_READ|FD_CONNECT|FD_CLOSE); - /* no need to use NET_Connect as non-blocking */ - him6.sin6_port = htons((short) 7); /* Echo port */ - connect_rv = connect(fd, (struct sockaddr *)&him6, len); + sa->sa6.sin6_port = htons(7); // echo port + connect_rv = connect(fd, &sa->sa, sizeof(struct sockaddr_in6)); - /** - * connection established or refused immediately, either way it means - * we were able to reach the host! - */ + // connection established or refused immediately, either way it means + // we were able to reach the host! if (connect_rv == 0 || WSAGetLastError() == WSAECONNREFUSED) { WSACloseEvent(hEvent); closesocket(fd); return JNI_TRUE; - } else { - int optlen; + } - switch (WSAGetLastError()) { - case WSAEHOSTUNREACH: /* Host Unreachable */ - case WSAENETUNREACH: /* Network Unreachable */ - case WSAENETDOWN: /* Network is down */ - case WSAEPFNOSUPPORT: /* Protocol Family unsupported */ - WSACloseEvent(hEvent); - closesocket(fd); - return JNI_FALSE; - } + switch (WSAGetLastError()) { + case WSAEHOSTUNREACH: // Host Unreachable + case WSAENETUNREACH: // Network Unreachable + case WSAENETDOWN: // Network is down + case WSAEPFNOSUPPORT: // Protocol Family unsupported + WSACloseEvent(hEvent); + closesocket(fd); + return JNI_FALSE; + case WSAEWOULDBLOCK: // this is expected as we'll probably have to wait + break; + default: + NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", + "connect failed"); + WSACloseEvent(hEvent); + closesocket(fd); + return JNI_FALSE; + } - if (WSAGetLastError() != WSAEWOULDBLOCK) { - NET_ThrowByNameWithLastError(env, JNU_JAVANETPKG "ConnectException", - "connect failed"); - WSACloseEvent(hEvent); - closesocket(fd); - return JNI_FALSE; - } - - timeout = NET_Wait(env, fd, NET_WAIT_CONNECT, timeout); - - if (timeout >= 0) { - /* has connection been established? */ - optlen = sizeof(connect_rv); - if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&connect_rv, - &optlen) <0) { + timeout = NET_Wait(env, fd, NET_WAIT_CONNECT, timeout); + if (timeout >= 0) { + // connection has been established, check for error condition + int optlen = sizeof(connect_rv); + if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void *)&connect_rv, + &optlen) < 0) + { connect_rv = WSAGetLastError(); - } - - if (connect_rv == 0 || connect_rv == WSAECONNREFUSED) { + } + if (connect_rv == 0 || connect_rv == WSAECONNREFUSED) { WSACloseEvent(hEvent); closesocket(fd); return JNI_TRUE; - } } } WSACloseEvent(hEvent); @@ -416,21 +376,18 @@ tcp_ping6(JNIEnv *env, * Returns true is an ECHO_REPLY is received, otherwise, false. */ static jboolean -ping6(JNIEnv *env, - struct sockaddr_in6* src, - struct sockaddr_in6* dest, - jint timeout, - HANDLE hIcmpFile) +ping6(JNIEnv *env, HANDLE hIcmpFile, SOCKETADDRESS *sa, + SOCKETADDRESS *netif, jint timeout) { DWORD dwRetVal = 0; char SendData[32] = {0}; LPVOID ReplyBuffer = NULL; DWORD ReplySize = 0; IP_OPTION_INFORMATION ipInfo = {255, 0, 0, 0, NULL}; - struct sockaddr_in6 sa6Source; + SOCKETADDRESS dftNetif; ReplySize = sizeof(ICMPV6_ECHO_REPLY) + sizeof(SendData); - ReplyBuffer = (VOID*) malloc(ReplySize); + ReplyBuffer = (VOID *)malloc(ReplySize); if (ReplyBuffer == NULL) { IcmpCloseHandle(hIcmpFile); NET_ThrowNew(env, WSAGetLastError(), "Unable to allocate memory"); @@ -438,17 +395,20 @@ ping6(JNIEnv *env, } //define local source information - sa6Source.sin6_addr = in6addr_any; - sa6Source.sin6_family = AF_INET6; - sa6Source.sin6_flowinfo = 0; - sa6Source.sin6_port = 0; + if (netif == NULL) { + dftNetif.sa6.sin6_addr = in6addr_any; + dftNetif.sa6.sin6_family = AF_INET6; + dftNetif.sa6.sin6_flowinfo = 0; + dftNetif.sa6.sin6_port = 0; + netif = &dftNetif; + } dwRetVal = Icmp6SendEcho2(hIcmpFile, // HANDLE IcmpHandle, NULL, // HANDLE Event, NULL, // PIO_APC_ROUTINE ApcRoutine, NULL, // PVOID ApcContext, - &sa6Source, // struct sockaddr_in6 *SourceAddress, - dest, // struct sockaddr_in6 *DestinationAddress, + &netif->sa6, // struct sockaddr_in6 *SourceAddress, + &sa->sa6, // struct sockaddr_in6 *DestinationAddress, SendData, // LPVOID RequestData, sizeof(SendData), // WORD RequestSize, &ipInfo, // PIP_OPTION_INFORMATION RequestOptions, @@ -459,11 +419,10 @@ ping6(JNIEnv *env, free(ReplyBuffer); IcmpCloseHandle(hIcmpFile); - - if (dwRetVal != 0) { - return JNI_TRUE; - } else { + if (dwRetVal == 0) { // if the call failed return JNI_FALSE; + } else { + return JNI_TRUE; } } @@ -474,75 +433,64 @@ ping6(JNIEnv *env, */ JNIEXPORT jboolean JNICALL Java_java_net_Inet6AddressImpl_isReachable0(JNIEnv *env, jobject this, - jbyteArray addrArray, - jint scope, - jint timeout, - jbyteArray ifArray, - jint ttl, jint if_scope) { + jbyteArray addrArray, jint scope, + jint timeout, jbyteArray ifArray, + jint ttl, jint if_scope) +{ jbyte caddr[16]; jint sz; - struct sockaddr_in6 him6; - struct sockaddr_in6* netif = NULL; - struct sockaddr_in6 inf6; - int len = 0; + SOCKETADDRESS sa, inf, *netif = NULL; HANDLE hIcmpFile; - /* - * If IPv6 is not enable, then we can't reach an IPv6 address, can we? - * Actually, we probably shouldn't even get here. - */ + // If IPv6 is not enabled, then we can't reach an IPv6 address, can we? + // Actually, we probably shouldn't even get here. if (!ipv6_available()) { - return JNI_FALSE; + return JNI_FALSE; } - /* - * If it's an IPv4 address, ICMP won't work with IPv4 mapped address, - * therefore, let's delegate to the Inet4Address method. - */ + + // If it's an IPv4 address, ICMP won't work with IPv4 mapped address, + // therefore, let's delegate to the Inet4Address method. sz = (*env)->GetArrayLength(env, addrArray); if (sz == 4) { - return Java_java_net_Inet4AddressImpl_isReachable0(env, this, - addrArray, - timeout, - ifArray, ttl); + return Java_java_net_Inet4AddressImpl_isReachable0(env, this, + addrArray, timeout, + ifArray, ttl); } - memset((char *) caddr, 0, 16); - memset((char *) &him6, 0, sizeof(him6)); + // load address to SOCKETADDRESS + memset((char *)caddr, 0, 16); (*env)->GetByteArrayRegion(env, addrArray, 0, 16, caddr); - memcpy((void *)&(him6.sin6_addr), caddr, sizeof(struct in6_addr) ); - him6.sin6_family = AF_INET6; + memset((char *)&sa, 0, sizeof(SOCKETADDRESS)); + memcpy((void *)&sa.sa6.sin6_addr, caddr, sizeof(struct in6_addr)); + sa.sa6.sin6_family = AF_INET6; if (scope > 0) { - him6.sin6_scope_id = scope; + sa.sa6.sin6_scope_id = scope; } - len = sizeof(struct sockaddr_in6); - /** - * A network interface was specified, let's convert the address - */ + // load network interface address to SOCKETADDRESS, if specified if (!(IS_NULL(ifArray))) { - memset((char *) caddr, 0, 16); - memset((char *) &inf6, 0, sizeof(inf6)); - (*env)->GetByteArrayRegion(env, ifArray, 0, 16, caddr); - memcpy((void *)&(inf6.sin6_addr), caddr, sizeof(struct in6_addr) ); - inf6.sin6_family = AF_INET6; - inf6.sin6_port = 0; - inf6.sin6_scope_id = if_scope; - netif = &inf6; + memset((char *)caddr, 0, 16); + (*env)->GetByteArrayRegion(env, ifArray, 0, 16, caddr); + memset((char *)&inf, 0, sizeof(SOCKETADDRESS)); + memcpy((void *)&inf.sa6.sin6_addr, caddr, sizeof(struct in6_addr)); + inf.sa6.sin6_family = AF_INET6; + inf.sa6.sin6_scope_id = if_scope; + netif = &inf; } + // Let's try to create an ICMP handle. hIcmpFile = Icmp6CreateFile(); if (hIcmpFile == INVALID_HANDLE_VALUE) { int err = WSAGetLastError(); if (err == ERROR_ACCESS_DENIED) { // fall back to TCP echo if access is denied to ICMP - return tcp_ping6(env, timeout, ttl, him6, netif, len); + return tcp_ping6(env, &sa, netif, timeout, ttl); } else { NET_ThrowNew(env, err, "Unable to create ICMP file handle"); return JNI_FALSE; } } else { - return ping6(env, netif, &him6, timeout, hIcmpFile); + // It didn't fail, so we can use ICMP. + return ping6(env, hIcmpFile, &sa, netif, timeout); } - - return JNI_FALSE; } diff --git a/jdk/src/java.base/windows/native/libnio/ch/Net.c b/jdk/src/java.base/windows/native/libnio/ch/Net.c index cae8ef03bf8..4b586d3208a 100644 --- a/jdk/src/java.base/windows/native/libnio/ch/Net.c +++ b/jdk/src/java.base/windows/native/libnio/ch/Net.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -50,13 +50,13 @@ #endif /* MCAST_BLOCK_SOURCE */ -typedef struct my_ip_mreq_source { +struct my_ip_mreq_source { IN_ADDR imr_multiaddr; IN_ADDR imr_sourceaddr; IN_ADDR imr_interface; }; -typedef struct my_group_source_req { +struct my_group_source_req { ULONG gsr_interface; SOCKADDR_STORAGE gsr_group; SOCKADDR_STORAGE gsr_source; diff --git a/jdk/src/java.management.rmi/share/classes/javax/management/remote/rmi/RMIConnector.java b/jdk/src/java.management.rmi/share/classes/javax/management/remote/rmi/RMIConnector.java index 16eeff47d4b..200340136ea 100644 --- a/jdk/src/java.management.rmi/share/classes/javax/management/remote/rmi/RMIConnector.java +++ b/jdk/src/java.management.rmi/share/classes/javax/management/remote/rmi/RMIConnector.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -1258,7 +1258,7 @@ public class RMIConnector implements JMXConnector, Serializable, JMXAddressable + ", listener=" + listener); final Integer[] ret = - rmiNotifClient.removeNotificationListener(name, listener); + rmiNotifClient.getListenerIds(name, listener); if (debug) logger.debug("removeNotificationListener", "listenerIDs=" + objects(ret)); @@ -1278,7 +1278,7 @@ public class RMIConnector implements JMXConnector, Serializable, JMXAddressable } finally { popDefaultClassLoader(old); } - + rmiNotifClient.removeNotificationListener(name, listener); } public void removeNotificationListener(ObjectName name, @@ -1300,7 +1300,7 @@ public class RMIConnector implements JMXConnector, Serializable, JMXAddressable + ", handback=" + handback); final Integer ret = - rmiNotifClient.removeNotificationListener(name, listener, + rmiNotifClient.getListenerId(name, listener, filter, handback); if (debug) logger.debug("removeNotificationListener", @@ -1320,7 +1320,8 @@ public class RMIConnector implements JMXConnector, Serializable, JMXAddressable } finally { popDefaultClassLoader(old); } - + rmiNotifClient.removeNotificationListener(name, listener, + filter, handback); } } diff --git a/jdk/src/java.management/share/classes/com/sun/jmx/remote/internal/ClientNotifForwarder.java b/jdk/src/java.management/share/classes/com/sun/jmx/remote/internal/ClientNotifForwarder.java index d835171c0f4..97ac9e45e16 100644 --- a/jdk/src/java.management/share/classes/com/sun/jmx/remote/internal/ClientNotifForwarder.java +++ b/jdk/src/java.management/share/classes/com/sun/jmx/remote/internal/ClientNotifForwarder.java @@ -187,6 +187,53 @@ public abstract class ClientNotifForwarder { init(false); } + public synchronized Integer[] + getListenerIds(ObjectName name, + NotificationListener listener) + throws ListenerNotFoundException, IOException { + + List ids = new ArrayList(); + List values = + new ArrayList(infoList.values()); + for (int i=values.size()-1; i>=0; i--) { + ClientListenerInfo li = values.get(i); + + if (li.sameAs(name, listener)) { + ids.add(li.getListenerID()); + } + } + + if (ids.isEmpty()) + throw new ListenerNotFoundException("Listener not found"); + + return ids.toArray(new Integer[0]); + } + + public synchronized Integer + getListenerId(ObjectName name, + NotificationListener listener, + NotificationFilter filter, + Object handback) + throws ListenerNotFoundException, IOException { + + Integer id = null; + + List values = + new ArrayList(infoList.values()); + for (int i=values.size()-1; i>=0; i--) { + ClientListenerInfo li = values.get(i); + if (li.sameAs(name, listener, filter, handback)) { + id=li.getListenerID(); + break; + } + } + + if (id == null) + throw new ListenerNotFoundException("Listener not found"); + + return id; + } + public synchronized Integer[] removeNotificationListener(ObjectName name, NotificationListener listener) @@ -198,24 +245,12 @@ public abstract class ClientNotifForwarder { logger.trace("removeNotificationListener", "Remove the listener "+listener+" from "+name); } - - List ids = new ArrayList(); - List values = - new ArrayList(infoList.values()); - for (int i=values.size()-1; i>=0; i--) { - ClientListenerInfo li = values.get(i); - - if (li.sameAs(name, listener)) { - ids.add(li.getListenerID()); - - infoList.remove(li.getListenerID()); - } + Integer[] liIds = getListenerIds(name, listener); + for (int i = 0; i < liIds.length; i++) { + infoList.remove(liIds[i]); } - if (ids.isEmpty()) - throw new ListenerNotFoundException("Listener not found"); - - return ids.toArray(new Integer[0]); + return liIds; } public synchronized Integer @@ -231,26 +266,11 @@ public abstract class ClientNotifForwarder { } beforeRemove(); + Integer liId = getListenerId(name, listener, + filter, handback); + infoList.remove(liId); - Integer id = null; - - List values = - new ArrayList(infoList.values()); - for (int i=values.size()-1; i>=0; i--) { - ClientListenerInfo li = values.get(i); - if (li.sameAs(name, listener, filter, handback)) { - id=li.getListenerID(); - - infoList.remove(id); - - break; - } - } - - if (id == null) - throw new ListenerNotFoundException("Listener not found"); - - return id; + return liId; } public synchronized Integer[] removeNotificationListener(ObjectName name) { diff --git a/jdk/src/java.naming/share/classes/com/sun/jndi/ldap/EventSupport.java b/jdk/src/java.naming/share/classes/com/sun/jndi/ldap/EventSupport.java index de78c1f11ab..a13a4da637e 100644 --- a/jdk/src/java.naming/share/classes/com/sun/jndi/ldap/EventSupport.java +++ b/jdk/src/java.naming/share/classes/com/sun/jndi/ldap/EventSupport.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,6 +28,8 @@ package com.sun.jndi.ldap; import java.util.Hashtable; import java.util.Vector; import java.util.EventObject; +import java.util.Iterator; +import java.util.Map; import javax.naming.*; import javax.naming.event.*; @@ -204,31 +206,35 @@ final class EventSupport { * Removes {@code l} from all notifiers in this context. */ synchronized void removeNamingListener(NamingListener l) { - if (debug) System.err.println("EventSupport removing listener"); - + if (debug) { + System.err.println("EventSupport removing listener"); + } // Go through list of notifiers, remove 'l' from each. // If 'l' is notifier's only listener, remove notifier too. - for (NamingEventNotifier notifier : notifiers.values()) { + Iterator iterator = notifiers.values().iterator(); + while (iterator.hasNext()) { + NamingEventNotifier notifier = iterator.next(); if (notifier != null) { - if (debug) + if (debug) { System.err.println("EventSupport removing listener from notifier"); + } notifier.removeNamingListener(l); if (!notifier.hasNamingListeners()) { - if (debug) + if (debug) { System.err.println("EventSupport stopping notifier"); + } notifier.stop(); - notifiers.remove(notifier.info); + iterator.remove(); } } } - // Remove from list of unsolicited notifier - if (debug) System.err.println("EventSupport removing unsolicited: " + - unsolicited); + if (debug) { + System.err.println("EventSupport removing unsolicited: " + unsolicited); + } if (unsolicited != null) { unsolicited.removeElement(l); } - } synchronized boolean hasUnsolicited() { diff --git a/jdk/src/java.security.jgss/share/classes/sun/security/krb5/Config.java b/jdk/src/java.security.jgss/share/classes/sun/security/krb5/Config.java index c43c373785f..561f77f75e5 100644 --- a/jdk/src/java.security.jgss/share/classes/sun/security/krb5/Config.java +++ b/jdk/src/java.security.jgss/share/classes/sun/security/krb5/Config.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -577,7 +577,8 @@ public class Config { for (Path p: files) { if (Files.isDirectory(p)) continue; String name = p.getFileName().toString(); - if (name.matches("[a-zA-Z0-9_-]+")) { + if (name.matches("[a-zA-Z0-9_-]+") || + name.endsWith(".conf")) { // if dir is absolute, so is p readConfigFileLines(p, content, dups); } diff --git a/jdk/src/java.security.jgss/share/classes/sun/security/krb5/KrbAsRep.java b/jdk/src/java.security.jgss/share/classes/sun/security/krb5/KrbAsRep.java index bf7a562eb4f..1d5febdf41d 100644 --- a/jdk/src/java.security.jgss/share/classes/sun/security/krb5/KrbAsRep.java +++ b/jdk/src/java.security.jgss/share/classes/sun/security/krb5/KrbAsRep.java @@ -160,7 +160,7 @@ class KrbAsRep extends KrbKdcRep { creds = new Credentials( rep.ticket, req.reqBody.cname, - rep.ticket.sname, + enc_part.sname, enc_part.key, enc_part.flags, enc_part.authtime, diff --git a/jdk/src/java.security.jgss/share/classes/sun/security/krb5/KrbTgsRep.java b/jdk/src/java.security.jgss/share/classes/sun/security/krb5/KrbTgsRep.java index 6fc6cebaa70..c0e6ef8f0fe 100644 --- a/jdk/src/java.security.jgss/share/classes/sun/security/krb5/KrbTgsRep.java +++ b/jdk/src/java.security.jgss/share/classes/sun/security/krb5/KrbTgsRep.java @@ -88,7 +88,7 @@ public class KrbTgsRep extends KrbKdcRep { this.creds = new Credentials(rep.ticket, rep.cname, - rep.ticket.sname, + enc_part.sname, enc_part.key, enc_part.flags, enc_part.authtime, diff --git a/jdk/src/jdk.crypto.mscapi/windows/classes/sun/security/mscapi/KeyStore.java b/jdk/src/jdk.crypto.mscapi/windows/classes/sun/security/mscapi/KeyStore.java index c4888bf3049..16e99bbfd48 100644 --- a/jdk/src/jdk.crypto.mscapi/windows/classes/sun/security/mscapi/KeyStore.java +++ b/jdk/src/jdk.crypto.mscapi/windows/classes/sun/security/mscapi/KeyStore.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -513,7 +513,7 @@ abstract class KeyStore extends KeyStoreSpi { if (entry != null) { // Get end-entity certificate and remove from system cert store X509Certificate[] certChain = entry.getCertificateChain(); - if (certChain != null) { + if (certChain != null && certChain.length > 0) { try { @@ -629,7 +629,9 @@ abstract class KeyStore extends KeyStoreSpi { for (Map.Entry mapEntry : entries.entrySet()) { KeyEntry entry = mapEntry.getValue(); - if (entry.certChain != null && entry.certChain[0].equals(cert)) { + if (entry.certChain != null && + entry.certChain.length > 0 && + entry.certChain[0].equals(cert)) { return entry.getAlias(); } } diff --git a/jdk/src/jdk.httpserver/share/classes/sun/net/httpserver/LeftOverInputStream.java b/jdk/src/jdk.httpserver/share/classes/sun/net/httpserver/LeftOverInputStream.java index c715d72ad18..d3a6e1b08c3 100644 --- a/jdk/src/jdk.httpserver/share/classes/sun/net/httpserver/LeftOverInputStream.java +++ b/jdk/src/jdk.httpserver/share/classes/sun/net/httpserver/LeftOverInputStream.java @@ -41,8 +41,8 @@ import com.sun.net.httpserver.spi.*; * isEOF() returns true, when all expected bytes have been read */ abstract class LeftOverInputStream extends FilterInputStream { - ExchangeImpl t; - ServerImpl server; + final ExchangeImpl t; + final ServerImpl server; protected boolean closed = false; protected boolean eof = false; byte[] one = new byte [1]; @@ -109,6 +109,9 @@ abstract class LeftOverInputStream extends FilterInputStream { int bufSize = 2048; byte[] db = new byte [bufSize]; while (l > 0) { + if (server.isFinishing()) { + break; + } long len = readImpl (db, 0, bufSize); if (len == -1) { eof = true; diff --git a/jdk/src/jdk.httpserver/share/classes/sun/net/httpserver/ServerImpl.java b/jdk/src/jdk.httpserver/share/classes/sun/net/httpserver/ServerImpl.java index e384a849241..10c3539b84b 100644 --- a/jdk/src/jdk.httpserver/share/classes/sun/net/httpserver/ServerImpl.java +++ b/jdk/src/jdk.httpserver/share/classes/sun/net/httpserver/ServerImpl.java @@ -179,6 +179,10 @@ class ServerImpl implements TimeSource { return httpsConfig; } + public final boolean isFinishing() { + return finished; + } + public void stop (int delay) { if (delay < 0) { throw new IllegalArgumentException ("negative delay parameter"); diff --git a/jdk/src/jdk.internal.le/share/classes/jdk/internal/jline/extra/EditingHistory.java b/jdk/src/jdk.internal.le/share/classes/jdk/internal/jline/extra/EditingHistory.java index fcccd9d2523..b79d8c27864 100644 --- a/jdk/src/jdk.internal.le/share/classes/jdk/internal/jline/extra/EditingHistory.java +++ b/jdk/src/jdk.internal.le/share/classes/jdk/internal/jline/extra/EditingHistory.java @@ -264,9 +264,8 @@ public abstract class EditingHistory implements History { } public boolean previousSnippet() { - for (int i = index() - 1; i >= 0; i--) { - if (get(i) instanceof NarrowingHistoryLine) { - moveTo(i); + while (previous()) { + if (current() instanceof NarrowingHistoryLine) { return true; } } @@ -275,19 +274,17 @@ public abstract class EditingHistory implements History { } public boolean nextSnippet() { - for (int i = index() + 1; i < size(); i++) { - if (get(i) instanceof NarrowingHistoryLine) { - moveTo(i); + boolean success = false; + + while (next()) { + success = true; + + if (current() instanceof NarrowingHistoryLine) { return true; } } - if (index() < size()) { - moveToEnd(); - return true; - } - - return false; + return success; } public final void load(Iterable originalHistory) { diff --git a/jdk/src/jdk.jartool/share/classes/sun/security/tools/jarsigner/Main.java b/jdk/src/jdk.jartool/share/classes/sun/security/tools/jarsigner/Main.java index a42dfe21882..cb86682f7da 100644 --- a/jdk/src/jdk.jartool/share/classes/sun/security/tools/jarsigner/Main.java +++ b/jdk/src/jdk.jartool/share/classes/sun/security/tools/jarsigner/Main.java @@ -444,6 +444,7 @@ public class Main { } else if (collator.compare(flags, "-strict") ==0) { strict = true; } else if (collator.compare(flags, "-h") == 0 || + collator.compare(flags, "-?") == 0 || collator.compare(flags, "-help") == 0) { fullusage(); } else { diff --git a/jdk/src/jdk.jdwp.agent/share/native/libjdwp/util.c b/jdk/src/jdk.jdwp.agent/share/native/libjdwp/util.c index dc428db0186..81e676654d4 100644 --- a/jdk/src/jdk.jdwp.agent/share/native/libjdwp/util.c +++ b/jdk/src/jdk.jdwp.agent/share/native/libjdwp/util.c @@ -2421,7 +2421,6 @@ cbObjectTagInstance(jvmtiHeapReferenceKind reference_kind, /* Check data structure */ data = (ClassInstancesData*)user_data; if (data == NULL) { - data->error = AGENT_ERROR_ILLEGAL_ARGUMENT; return JVMTI_VISIT_ABORT; } @@ -2540,7 +2539,6 @@ cbObjectCounterFromRef(jvmtiHeapReferenceKind reference_kind, /* Check data structure */ data = (ClassCountData*)user_data; if (data == NULL) { - data->error = AGENT_ERROR_ILLEGAL_ARGUMENT; return JVMTI_VISIT_ABORT; } @@ -2598,7 +2596,6 @@ cbObjectCounter(jlong class_tag, jlong size, jlong* tag_ptr, jint length, /* Check data structure */ data = (ClassCountData*)user_data; if (data == NULL) { - data->error = AGENT_ERROR_ILLEGAL_ARGUMENT; return JVMTI_VISIT_ABORT; } @@ -2757,7 +2754,6 @@ cbObjectTagReferrer(jvmtiHeapReferenceKind reference_kind, /* Check data structure */ data = (ReferrerData*)user_data; if (data == NULL) { - data->error = AGENT_ERROR_ILLEGAL_ARGUMENT; return JVMTI_VISIT_ABORT; } diff --git a/jdk/test/ProblemList.txt b/jdk/test/ProblemList.txt index f045c7205c2..7dedb691e33 100644 --- a/jdk/test/ProblemList.txt +++ b/jdk/test/ProblemList.txt @@ -99,9 +99,8 @@ # 1. Make sure test passes on all platforms with samevm, or mark it othervm # 2. Make sure test passes on all platforms when run with it's entire group # 3. Make sure both VMs are tested, -server and -client, if possible -# 4. Make sure you try the -d64 option on Solaris -# 5. Use a tool like JPRT or something to verify these results -# 6. Delete lines in this file, include the changes with your test changes +# 4. Use a tool like JPRT or something to verify these results +# 5. Delete lines in this file, include the changes with your test changes # # You may need to repeat your testing 2 or even 3 times to verify good # results, some of these samevm failures are not very predictable. @@ -143,6 +142,8 @@ java/lang/management/MemoryMXBean/PendingAllGC.sh 8158837 generic- # jdk_io +java/io/pathNames/GeneralWin32.java 8180264 windows-all + ############################################################################ # jdk_management @@ -211,6 +212,8 @@ sun/security/tools/jarsigner/warnings/BadKeyUsageTest.java 8026393 generic- javax/net/ssl/DTLS/PacketLossRetransmission.java 8169086 macosx-x64 javax/net/ssl/DTLS/RespondToRetransmit.java 8169086 macosx-x64 +sun/security/krb5/auto/UnboundSSL.java 8180265 windows-all +sun/security/provider/KeyStore/DKSTest.sh 8180266 windows-all sun/security/ssl/X509KeyManager/PreferredKey.java 8176354 generic-all ############################################################################ @@ -259,6 +262,9 @@ tools/jimage/JImageExtractTest.java 8170120 generic- tools/jimage/JImageListTest.java 8170120 generic-all tools/jimage/JImageVerifyTest.java 8170120 generic-all +tools/schemagen/MultiReleaseJarTest.java 8174692 generic-all +tools/wsgen/MultiReleaseJarTest.java 8174692 generic-all + ############################################################################ # jdk_jdi diff --git a/jdk/test/TEST.ROOT b/jdk/test/TEST.ROOT index b9cb4a27a3f..41cb9e82c8d 100644 --- a/jdk/test/TEST.ROOT +++ b/jdk/test/TEST.ROOT @@ -10,7 +10,7 @@ # randomness tests. # # A "headful" test requires a graphical environment to meaningfully -# run. Tests that are not headful are "headless." +# run. Tests that are not headful are "headless." keys=2d dnd i18n intermittent randomness headful @@ -18,7 +18,7 @@ keys=2d dnd i18n intermittent randomness headful othervm.dirs=java/awt java/beans javax/accessibility javax/imageio javax/sound javax/print javax/management com/sun/awt sun/awt sun/java2d sun/pisces javax/xml/jaxp/testng/validation java/lang/ProcessHandle # Tests that cannot run concurrently -exclusiveAccess.dirs=java/rmi/Naming java/util/prefs sun/management/jmxremote sun/tools/jstatd sun/security/mscapi java/util/stream java/util/BitSet/stream javax/rmi com/sun/corba/cachedSocket +exclusiveAccess.dirs=java/rmi/Naming java/util/prefs sun/management/jmxremote sun/tools/jstatd sun/security/mscapi java/util/stream java/util/Arrays/largeMemory java/util/BitSet/stream javax/rmi com/sun/corba/cachedSocket # Group definitions groups=TEST.groups [closed/TEST.groups] diff --git a/jdk/test/TEST.groups b/jdk/test/TEST.groups index 07f876ce3db..11da7640e98 100644 --- a/jdk/test/TEST.groups +++ b/jdk/test/TEST.groups @@ -1,4 +1,4 @@ -# Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -641,6 +641,7 @@ needs_compact3 = \ java/security/PermissionCollection/Concurrent.java \ java/security/Principal/Implies.java \ java/security/cert/GetInstance.java \ + java/util/Arrays/largeMemory/ParallelPrefix.java \ java/util/logging/DrainFindDeadlockTest.java \ java/util/logging/LoggingMXBeanTest.java \ java/util/logging/TestLogConfigurationDeadLock.java \ @@ -709,7 +710,6 @@ needs_compact2 = \ java/nio/Buffer/Chars.java \ java/nio/file/Files/StreamTest.java \ java/security/BasicPermission/Wildcard.java \ - java/util/Arrays/ParallelPrefix.java \ java/util/Arrays/SetAllTest.java \ java/util/BitSet/stream/BitSetStreamTest.java \ java/util/Collection/CollectionDefaults.java \ diff --git a/jdk/test/com/sun/corba/7130985/CorbaExceptionsCompileTest.java b/jdk/test/com/sun/corba/7130985/CorbaExceptionsCompileTest.java index 15397206330..58bc6ee2a5d 100644 --- a/jdk/test/com/sun/corba/7130985/CorbaExceptionsCompileTest.java +++ b/jdk/test/com/sun/corba/7130985/CorbaExceptionsCompileTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,11 @@ * @test * @bug 7130985 * @summary Four helper classes missing in Sun JDK - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /lib/testlibrary /test/lib * @modules java.corba + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils + * jdk.testlibrary.* * @run main CorbaExceptionsCompileTest */ @@ -35,12 +37,12 @@ import java.io.*; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; -import java.rmi.RemoteException; + import org.omg.CORBA.ORBPackage.InvalidName; import org.omg.CORBA.TypeCodePackage.BadKind; import org.omg.CORBA.TypeCodePackage.Bounds; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; import jdk.testlibrary.JDKToolLauncher; public class CorbaExceptionsCompileTest implements CorbaExceptionsTest { diff --git a/jdk/test/com/sun/crypto/provider/CICO/PBEFunc/CipherNCFuncTest.java b/jdk/test/com/sun/crypto/provider/CICO/PBEFunc/CipherNCFuncTest.java index 73952ebb7c3..c133f11b2d1 100644 --- a/jdk/test/com/sun/crypto/provider/CICO/PBEFunc/CipherNCFuncTest.java +++ b/jdk/test/com/sun/crypto/provider/CICO/PBEFunc/CipherNCFuncTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -20,20 +20,24 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + /* * @test * @bug 8048604 - * @library ../ /lib/testlibrary + * @library ../ /test/lib + * @build jdk.test.lib.RandomFactory + * @run main CipherNCFuncTest * @summary This test verifies the assertion "There should be no transformation - * on the plaintext/ciphertext in encryption/decryption mechanism" for - * feature "NullCipher". + * on the plaintext/ciphertext in encryption/decryption mechanism" for + * feature "NullCipher". */ + import javax.crypto.BadPaddingException; import javax.crypto.Cipher; import javax.crypto.IllegalBlockSizeException; import javax.crypto.NullCipher; import javax.crypto.ShortBufferException; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class CipherNCFuncTest { public static void main(String[] args) throws ShortBufferException, diff --git a/jdk/test/com/sun/jndi/ldap/RemoveNamingListenerTest.java b/jdk/test/com/sun/jndi/ldap/RemoveNamingListenerTest.java new file mode 100644 index 00000000000..ebdc4c60e2b --- /dev/null +++ b/jdk/test/com/sun/jndi/ldap/RemoveNamingListenerTest.java @@ -0,0 +1,241 @@ +/* + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +import java.io.BufferedInputStream; +import java.io.IOException; +import java.io.OutputStreamWriter; +import java.io.PrintWriter; +import java.net.ServerSocket; +import java.net.Socket; +import java.nio.charset.StandardCharsets; +import java.util.ConcurrentModificationException; +import java.util.Hashtable; +import javax.naming.Context; +import javax.naming.InitialContext; +import javax.naming.NamingException; +import javax.naming.event.EventContext; +import javax.naming.event.NamingEvent; +import javax.naming.event.NamingExceptionEvent; +import javax.naming.event.NamingListener; +import javax.naming.event.ObjectChangeListener; + +/** + * @test + * @bug 8176192 + * @summary Incorrect usage of Iterator in Java 8 In com.sun.jndi.ldap. + * EventSupport.removeNamingListener + * @modules java.naming + * @run main RemoveNamingListenerTest + */ +public class RemoveNamingListenerTest { + + private static volatile Exception exception; + + public static void main(String args[]) throws Exception { + // start the LDAP server + TestLDAPServer server = new TestLDAPServer(); + server.start(); + + // Set up environment for creating initial context + Hashtable env = new Hashtable<>(3); + env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory"); + env.put(Context.PROVIDER_URL, "ldap://localhost:" + server.getPort() + "/o=example"); + env.put("com.sun.jndi.ldap.connect.timeout", "2000"); + EventContext ctx = null; + + try { + ctx = (EventContext) (new InitialContext(env).lookup("")); + String target = "cn=Vyom Tewari"; + + // Create listeners + NamingListener oneListener = new SampleListener(); + NamingListener objListener = new SampleListener(); + NamingListener subListener = new SampleListener(); + + // Register listeners using different scopes + ctx.addNamingListener(target, EventContext.ONELEVEL_SCOPE, oneListener); + ctx.addNamingListener(target, EventContext.OBJECT_SCOPE, objListener); + ctx.addNamingListener(target, EventContext.SUBTREE_SCOPE, subListener); + + //remove a listener in different thread + Thread t = new Thread(new RemoveNamingListener(ctx, subListener)); + t.start(); + t.join(); + + if (exception != null) { + throw exception; + } + System.out.println("Test run OK!!!"); + } finally { + if (ctx != null) { + ctx.close(); + } + server.stopServer(); + } + } + + /** + * Helper thread that removes the naming listener. + */ + static class RemoveNamingListener implements Runnable { + + final EventContext ctx; + final NamingListener listener; + + RemoveNamingListener(EventContext ctx, NamingListener listener) { + this.ctx = ctx; + this.listener = listener; + } + + @Override + public void run() { + try { + ctx.removeNamingListener(listener); + } catch (NamingException | ConcurrentModificationException ex) { + exception = ex; + } + } + } + + static class SampleListener implements ObjectChangeListener { + + @Override + public void objectChanged(NamingEvent ne) { + //do nothing + } + + @Override + public void namingExceptionThrown(NamingExceptionEvent nee) { + //do nothing + } + } +} + +class TestLDAPServer extends Thread { + + private final int LDAP_PORT; + private final ServerSocket serverSocket; + private volatile boolean isRunning; + + TestLDAPServer() throws IOException { + serverSocket = new ServerSocket(0); + isRunning = true; + LDAP_PORT = serverSocket.getLocalPort(); + setDaemon(true); + } + + public int getPort() { + return LDAP_PORT; + } + + public void stopServer() { + isRunning = false; + if (serverSocket != null && !serverSocket.isClosed()) { + try { + // this will cause ServerSocket.accept() to throw SocketException. + serverSocket.close(); + } catch (IOException ignored) { + } + } + } + + @Override + public void run() { + try { + while (isRunning) { + Socket clientSocket = serverSocket.accept(); + Thread handler = new Thread(new LDAPServerHandler(clientSocket)); + handler.setDaemon(true); + handler.start(); + } + } catch (IOException iOException) { + //do not throw exception if server is not running. + if (isRunning) { + throw new RuntimeException(iOException); + } + } finally { + stopServer(); + } + } +} + +class LDAPServerHandler implements Runnable { + + private final Socket clientSocket; + + public LDAPServerHandler(final Socket clientSocket) { + this.clientSocket = clientSocket; + } + + @Override + public void run() { + BufferedInputStream in = null; + PrintWriter out = null; + byte[] bindResponse = {0x30, 0x0C, 0x02, 0x01, 0x01, 0x61, 0x07, 0x0A, 0x01, 0x00, 0x04, 0x00, 0x04, 0x00}; + byte[] searchResponse = {0x30, 0x0C, 0x02, 0x01, 0x02, 0x65, 0x07, 0x0A, 0x01, 0x00, 0x04, 0x00, 0x04, 0x00}; + try { + in = new BufferedInputStream(clientSocket.getInputStream()); + out = new PrintWriter(new OutputStreamWriter( + clientSocket.getOutputStream(), StandardCharsets.UTF_8), true); + while (true) { + + // Read the LDAP BindRequest + while (in.read() != -1) { + in.skip(in.available()); + break; + } + + // Write an LDAP BindResponse + out.write(new String(bindResponse)); + out.flush(); + + // Read the LDAP SearchRequest + while (in.read() != -1) { + in.skip(in.available()); + break; + } + + // Write an LDAP SearchResponse + out.write(new String(searchResponse)); + out.flush(); + } + } catch (IOException iOException) { + throw new RuntimeException(iOException); + } finally { + if (in != null) { + try { + in.close(); + } catch (IOException ignored) { + } + } + if (out != null) { + out.close(); + } + if (clientSocket != null) { + try { + clientSocket.close(); + } catch (IOException ignored) { + } + } + } + } +} diff --git a/jdk/test/com/sun/management/HotSpotDiagnosticMXBean/CheckOrigin.java b/jdk/test/com/sun/management/HotSpotDiagnosticMXBean/CheckOrigin.java index 4a0f1d845ef..f2b03d72360 100644 --- a/jdk/test/com/sun/management/HotSpotDiagnosticMXBean/CheckOrigin.java +++ b/jdk/test/com/sun/management/HotSpotDiagnosticMXBean/CheckOrigin.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -62,7 +62,7 @@ public class CheckOrigin { ProcessBuilder pb = ProcessTools. createJavaProcessBuilder( "--add-exports", "jdk.attach/sun.tools.attach=ALL-UNNAMED", - "-XX:+UseConcMarkSweepGC", // this will cause UseParNewGC to be FLAG_SET_ERGO + "-XX:+UseConcMarkSweepGC", // this will cause MaxNewSize to be FLAG_SET_ERGO "-XX:+UseCodeAging", "-XX:+UseCerealGC", // Should be ignored. "-XX:Flags=" + flagsFile.getAbsolutePath(), @@ -110,7 +110,7 @@ public class CheckOrigin { // Set through j.l.m checkOrigin("HeapDumpOnOutOfMemoryError", Origin.MANAGEMENT); // Should be set by the VM, when we set UseConcMarkSweepGC - checkOrigin("UseParNewGC", Origin.ERGONOMIC); + checkOrigin("MaxNewSize", Origin.ERGONOMIC); // Set using attach checkOrigin("HeapDumpPath", Origin.ATTACH_ON_DEMAND); } diff --git a/jdk/test/java/awt/JAWT/JAWT.sh b/jdk/test/java/awt/JAWT/JAWT.sh index d01ff022a42..8432a7188dd 100644 --- a/jdk/test/java/awt/JAWT/JAWT.sh +++ b/jdk/test/java/awt/JAWT/JAWT.sh @@ -85,7 +85,7 @@ case "$OS" in MAKEFILE="Makefile.win" CC="cl" MAKE="nmake" - ${TESTJAVA}${FS}bin${FS}java -d64 -version 2>&1 | grep '64-Bit' > $NULL + ${TESTJAVA}${FS}bin${FS}java -version 2>&1 | grep '64-Bit' > $NULL if [ "$?" -eq '0' ] then ARCH="amd64" @@ -100,7 +100,7 @@ case "$OS" in FS="/" MAKEFILE="Makefile.cygwin" CC="gcc" - ${TESTJAVA}${FS}bin${FS}java -d64 -version 2>&1 | grep '64-Bit' > $NULL + ${TESTJAVA}${FS}bin${FS}java -version 2>&1 | grep '64-Bit' > $NULL if [ "$?" -eq '0' ] then ARCH="amd64" diff --git a/jdk/test/java/io/File/SetLastModified.java b/jdk/test/java/io/File/SetLastModified.java index 249b7cca94c..1f45dd912ef 100644 --- a/jdk/test/java/io/File/SetLastModified.java +++ b/jdk/test/java/io/File/SetLastModified.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,7 +22,7 @@ */ /* @test - @bug 4091757 6652379 + @bug 4091757 6652379 8177809 @summary Basic test for setLastModified method */ diff --git a/jdk/test/java/io/Serializable/resolveClass/deserializeButton/Test.java b/jdk/test/java/io/File/createTempFile/SecurityTest.java similarity index 62% rename from jdk/test/java/io/Serializable/resolveClass/deserializeButton/Test.java rename to jdk/test/java/io/File/createTempFile/SecurityTest.java index 7f973b2213d..f3985da88a9 100644 --- a/jdk/test/java/io/Serializable/resolveClass/deserializeButton/Test.java +++ b/jdk/test/java/io/File/createTempFile/SecurityTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,22 +21,27 @@ * questions. */ -/* - * @bug 4413434 - * @summary Verify that class loaded outside of application class loader is - * correctly resolved during deserialization when read in by custom - * readObject() method of a bootstrap class (in this case, - * java.util.Vector). +/* @test + * @bug 4138064 + * @build SecurityTest + * @run main/othervm/policy=java.policy SecurityTest */ -import java.io.*; -import java.net.*; +import java.io.File; + +public class SecurityTest { -public class Test { public static void main(String[] args) throws Exception { - ClassLoader ldr = - new URLClassLoader(new URL[]{ new URL("file:cb.jar") }); - Runnable r = (Runnable) Class.forName("Foo", true, ldr).newInstance(); - r.run(); + try { + File f = File.createTempFile("foo", null); + } catch (java.security.AccessControlException x) { + throw x; + } catch (SecurityException x) { + if (x.getMessage().equals("Unable to create temporary file")) { + return; + } + throw x; + } + throw new Exception("SecurityException not thrown"); } } diff --git a/jdk/test/java/io/File/createTempFile/java.policy b/jdk/test/java/io/File/createTempFile/java.policy new file mode 100644 index 00000000000..e89913b9f24 --- /dev/null +++ b/jdk/test/java/io/File/createTempFile/java.policy @@ -0,0 +1,2 @@ +grant { +}; diff --git a/jdk/test/java/io/FilePermission/FilePermissionCollectionMerge.java b/jdk/test/java/io/FilePermission/FilePermissionCollectionMerge.java index c85be3d6fde..b8964931f30 100644 --- a/jdk/test/java/io/FilePermission/FilePermissionCollectionMerge.java +++ b/jdk/test/java/io/FilePermission/FilePermissionCollectionMerge.java @@ -28,6 +28,8 @@ * @summary FilePermissionCollection merges incorrectly * @modules java.base/sun.security.util * @library /test/lib + * @build jdk.test.lib.Asserts + * @run main FilePermissionCollectionMerge */ import sun.security.util.FilePermCompat; diff --git a/jdk/test/java/io/FilePermission/Invalid.java b/jdk/test/java/io/FilePermission/Invalid.java index 2a343d7049c..f9cf20da1ca 100644 --- a/jdk/test/java/io/FilePermission/Invalid.java +++ b/jdk/test/java/io/FilePermission/Invalid.java @@ -27,6 +27,8 @@ * @bug 8167646 * @summary Better invalid FilePermission * @library /test/lib + * @build jdk.test.lib.Asserts + * @run main Invalid */ import jdk.test.lib.Asserts; diff --git a/jdk/test/java/io/FilePermission/MergeName.java b/jdk/test/java/io/FilePermission/MergeName.java index 09215877fd8..c2eff765f2d 100644 --- a/jdk/test/java/io/FilePermission/MergeName.java +++ b/jdk/test/java/io/FilePermission/MergeName.java @@ -37,6 +37,13 @@ import java.util.stream.IntStream; * @bug 8170364 * @summary FilePermission path modified during merge * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @run main MergeName */ public class MergeName { diff --git a/jdk/test/java/io/FilePermission/ReadFileOnPath.java b/jdk/test/java/io/FilePermission/ReadFileOnPath.java index 05ea1a10dd8..3d8a60aa089 100644 --- a/jdk/test/java/io/FilePermission/ReadFileOnPath.java +++ b/jdk/test/java/io/FilePermission/ReadFileOnPath.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,11 +27,19 @@ * @library /lib/testlibrary /test/lib * @modules java.base/jdk.internal.misc * jdk.compiler + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main ReadFileOnPath * @summary Still able to read file on the same path */ import jdk.test.lib.process.ProcessTools; +import jdk.test.lib.compiler.CompilerUtils; import java.nio.file.Files; import java.nio.file.Path; diff --git a/jdk/test/java/io/InputStream/ReadAllBytes.java b/jdk/test/java/io/InputStream/ReadAllBytes.java index ef9a2728df9..c190cd2dd54 100644 --- a/jdk/test/java/io/InputStream/ReadAllBytes.java +++ b/jdk/test/java/io/InputStream/ReadAllBytes.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,13 +27,13 @@ import java.io.IOException; import java.io.InputStream; import java.util.Arrays; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /* * @test * @bug 8080835 - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main ReadAllBytes * @summary Basic test for InputStream.readAllBytes * @key randomness diff --git a/jdk/test/java/io/InputStream/ReadNBytes.java b/jdk/test/java/io/InputStream/ReadNBytes.java index 8f26a6e9d78..1fbca35d3bb 100644 --- a/jdk/test/java/io/InputStream/ReadNBytes.java +++ b/jdk/test/java/io/InputStream/ReadNBytes.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,13 +27,13 @@ import java.io.IOException; import java.io.InputStream; import java.util.Arrays; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /* * @test * @bug 8080835 - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main ReadNBytes * @summary Basic test for InputStream.readNBytes * @key randomness diff --git a/jdk/test/java/io/Serializable/class/NonSerialA_1.java b/jdk/test/java/io/Serializable/class/NonSerialA_1/A.java similarity index 100% rename from jdk/test/java/io/Serializable/class/NonSerialA_1.java rename to jdk/test/java/io/Serializable/class/NonSerialA_1/A.java diff --git a/jdk/test/java/io/Serializable/class/NonSerialA_2.java b/jdk/test/java/io/Serializable/class/NonSerialA_2/A.java similarity index 100% rename from jdk/test/java/io/Serializable/class/NonSerialA_2.java rename to jdk/test/java/io/Serializable/class/NonSerialA_2/A.java diff --git a/jdk/test/java/io/Serializable/class/NonSerializableTest.java b/jdk/test/java/io/Serializable/class/NonSerializableTest.java new file mode 100644 index 00000000000..b2ac4e933cb --- /dev/null +++ b/jdk/test/java/io/Serializable/class/NonSerializableTest.java @@ -0,0 +1,110 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4075221 + * @library /test/lib + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @run testng/timeout=300 NonSerializableTest + * @summary Enable serialize of nonSerializable Class descriptor. + */ + +import java.nio.file.Paths; +import java.util.Arrays; + +import org.testng.annotations.DataProvider; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; +import static org.testng.Assert.assertTrue; +import static org.testng.Assert.assertEquals; + +import jdk.test.lib.compiler.CompilerUtils; +import jdk.test.lib.process.ProcessTools; + + +public class NonSerializableTest { + + @BeforeClass + public void setup() throws Exception { + boolean b = CompilerUtils.compile( + Paths.get(System.getProperty("test.src"), "TestEntry.java"), + Paths.get(System.getProperty("user.dir"))); + assertTrue(b, "Compilation failed"); + } + + @DataProvider + public Object[][] provider() { + return new String[][][] { + // Write NonSerial1, Read NonSerial1 + {{"NonSerialA_1", "-cp", ".", "TestEntry", "-s", "A"}}, + {{"NonSerialA_1", "-cp", ".", "TestEntry", "-d"}}, + + // Write NonSerial1, Read NonSerial2 + {{"NonSerialA_1", "-cp", ".", "TestEntry", "-s", "A"}}, + {{"NonSerialA_2", "-cp", ".", "TestEntry", "-d"}}, + + // Write NonSerial1, Read Serial1 + {{"NonSerialA_1", "-cp", ".", "TestEntry", "-s", "A"}}, + {{"SerialA_1", "-cp", ".", "TestEntry", "-d"}}, + + // Write Serial1, Read NonSerial1 + {{"SerialA_1", "-cp", ".", "TestEntry", "-s", "A"}}, + {{"NonSerialA_1", "-cp", ".", "TestEntry", "-doe"}}, + + // Write Serial1, Read Serial2 + {{"SerialA_1", "-cp", ".", "TestEntry", "-s", "A"}}, + {{"SerialA_2", "-cp", ".", "TestEntry", "-d"}}, + + // Write Serial2, Read Serial1 + {{"SerialA_2", "-cp", ".", "TestEntry", "-s", "A"}}, + {{"SerialA_1", "-cp", ".", "TestEntry", "-d"}}, + + // Write Serial1, Read Serial3 + {{"SerialA_1", "-cp", ".", "TestEntry", "-s", "A"}}, + {{"SerialA_3", "-cp", ".", "TestEntry", "-de"}}, + + // Write Serial3, Read Serial1 + {{"SerialA_3", "-cp", ".", "TestEntry", "-s", "A"}}, + {{"SerialA_1", "-cp", ".", "TestEntry", "-de"}}, + }; + } + + @Test(dataProvider="provider") + public void test(String[] args) throws Exception { + boolean b = CompilerUtils.compile(Paths.get(System.getProperty("test.src"), args[0]), + Paths.get(System.getProperty("user.dir"))); + assertTrue(b, "Compilation failed"); + String params[] = Arrays.copyOfRange(args, 1, args.length); + ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(params); + Process p = ProcessTools.startProcess("Serializable Test", pb); + int exitValue = p.waitFor(); + assertEquals(exitValue, 0, "Test failed"); + } +} diff --git a/jdk/test/java/io/Serializable/class/SerialA.java b/jdk/test/java/io/Serializable/class/SerialA_1/A.java similarity index 100% rename from jdk/test/java/io/Serializable/class/SerialA.java rename to jdk/test/java/io/Serializable/class/SerialA_1/A.java diff --git a/jdk/test/java/io/Serializable/class/SerialA_2.java b/jdk/test/java/io/Serializable/class/SerialA_2/A.java similarity index 100% rename from jdk/test/java/io/Serializable/class/SerialA_2.java rename to jdk/test/java/io/Serializable/class/SerialA_2/A.java diff --git a/jdk/test/java/io/Serializable/class/SerialA_3.java b/jdk/test/java/io/Serializable/class/SerialA_3/A.java similarity index 100% rename from jdk/test/java/io/Serializable/class/SerialA_3.java rename to jdk/test/java/io/Serializable/class/SerialA_3/A.java diff --git a/jdk/test/java/io/Serializable/class/Test.java b/jdk/test/java/io/Serializable/class/TestEntry.java similarity index 88% rename from jdk/test/java/io/Serializable/class/Test.java rename to jdk/test/java/io/Serializable/class/TestEntry.java index 39bd32c9dd5..8301cfd8330 100644 --- a/jdk/test/java/io/Serializable/class/Test.java +++ b/jdk/test/java/io/Serializable/class/TestEntry.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2001, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,9 +26,16 @@ * @summary Enable serialize of nonSerializable Class descriptor. */ -import java.io.*; +import java.io.EOFException; +import java.io.File; +import java.io.FileOutputStream; +import java.io.FileInputStream; +import java.io.InvalidClassException; +import java.io.ObjectInputStream; +import java.io.ObjectOutputStream; +import java.io.ObjectStreamClass; -class Test { +class TestEntry { public static void main(String args[]) throws Exception { File f = new File("tmp.ser"); if (args[0].compareTo("-s") == 0) { @@ -73,6 +80,8 @@ class Test { } ois.close(); System.out.println("DeSerialized Class " + cl.getName()); + } else { + throw new RuntimeException("Unrecognized argument"); } } } diff --git a/jdk/test/java/io/Serializable/class/run.sh b/jdk/test/java/io/Serializable/class/run.sh deleted file mode 100644 index 697b87a917e..00000000000 --- a/jdk/test/java/io/Serializable/class/run.sh +++ /dev/null @@ -1,133 +0,0 @@ -# -# Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4075221 -# @run shell/timeout=300 run.sh -# @summary Enable serialize of nonSerializable Class descriptor. - -set -ex - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." - exit 1 -fi - -if [ "${COMPILEJAVA}" = "" ] ; then - COMPILEJAVA="${TESTJAVA}" -fi - -if [ "${TESTSRC}" = "" ] -then -TESTSRC="." -fi - -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}/Test.java - -echo Write NonSerial1, Read NonSerial1 -rm -f A.java -cp ${TESTSRC}/NonSerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -s A -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -d -echo - -echo Write NonSerial1, Read NonSerial2 -rm -f A.java -cp ${TESTSRC}/NonSerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -s A -rm -f A.java -cp ${TESTSRC}/NonSerialA_2.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -d -echo - -echo Write NonSerial1, Read Serial1 -rm -f A.java -cp ${TESTSRC}/NonSerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -s A -rm -f A.java -cp ${TESTSRC}/SerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -d -echo - -echo Write Serial1, Read NonSerial1 -rm -f A.java -cp ${TESTSRC}/SerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -s A -rm -f A.java -cp ${TESTSRC}/NonSerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -doe -echo - -echo Write Serial1, Read Serial2 -rm -f A.java -cp ${TESTSRC}/SerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -s A -rm -f A.java -cp ${TESTSRC}/SerialA_2.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -d -echo - -echo Write Serial2, Read Serial1 -rm -f A.java -cp ${TESTSRC}/SerialA_2.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -s A -rm -f A.java -cp ${TESTSRC}/SerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -d -echo - -echo Write Serial1, Read Serial3 -rm -f A.java -cp ${TESTSRC}/SerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -s A -rm -f A.java -cp ${TESTSRC}/SerialA_3.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -de -echo - -echo Write Serial3, Read Serial1 -rm -f A.java -cp ${TESTSRC}/SerialA_3.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -s A -rm -f A.java -cp ${TESTSRC}/SerialA_1.java A.java -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} A.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -de -echo - -echo Passed diff --git a/jdk/test/java/io/Serializable/evolution/AddedExternField/run.sh b/jdk/test/java/io/Serializable/evolution/AddedExternField/run.sh deleted file mode 100644 index 981f9360af9..00000000000 --- a/jdk/test/java/io/Serializable/evolution/AddedExternField/run.sh +++ /dev/null @@ -1,33 +0,0 @@ -# -# Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# -# @bug 4088176 -# @summary Test reading an evolved class serialization into the original class - -rm *.class tmp.ser -javac WriteAddedField.java -java ${TESTVMOPTS} WriteAddedField -rm *.class -javac ReadAddedField.java -java ${TESTVMOPTS} ReadAddedField diff --git a/jdk/test/java/io/Serializable/evolution/RenamePackage/RenamePackageTest.java b/jdk/test/java/io/Serializable/evolution/RenamePackage/RenamePackageTest.java new file mode 100644 index 00000000000..7a3da8e04d5 --- /dev/null +++ b/jdk/test/java/io/Serializable/evolution/RenamePackage/RenamePackageTest.java @@ -0,0 +1,112 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4087295 4785472 + * @library /test/lib + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @build RenamePackageTest + * @run main RenamePackageTest + * @summary Enable resolveClass() to accommodate package renaming. + * This fix enables one to implement a resolveClass method that maps a + * Serialiazable class within a serialization stream to the same class + * in a different package within the JVM runtime. See run shell script + * for instructions on how to run this test. + */ + +import java.io.File; +import java.nio.file.Path; +import java.nio.file.Paths; + +import jdk.test.lib.compiler.CompilerUtils; +import jdk.test.lib.process.ProcessTools; + +public class RenamePackageTest { + public static void main(String args[]) throws Exception { + setup(); + + runTestSerialDriver(); + runInstallSerialDriver(); + + runInstallSerialDriver(); + runTestSerialDriver(); + } + + private static final Path SHARE = Paths.get(System.getProperty("test.classes"), "share"); + private static final Path OCLASSES = Paths.get(System.getProperty("test.classes"), "oclasses"); + private static final Path NCLASSES = Paths.get(System.getProperty("test.classes"), "nclasses"); + + private static void setup() throws Exception { + + boolean b = CompilerUtils.compile(Paths.get(System.getProperty("test.src"), "extension"), + SHARE); + assertTrue(b); + b = CompilerUtils.compile(Paths.get(System.getProperty("test.src"), "test"), + OCLASSES, + "-classpath", + SHARE.toString()); + assertTrue(b); + b = CompilerUtils.compile(Paths.get(System.getProperty("test.src"), "install"), + NCLASSES, + "-classpath", + SHARE.toString()); + assertTrue(b); + } + + private static void runTestSerialDriver() throws Exception { + ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(true, + "-classpath", + SHARE.toString() + + File.pathSeparator + + OCLASSES.toString(), + "test.SerialDriver", "-s"); + Process p = ProcessTools.startProcess("test SerialDriver", pb); + p.waitFor(); + assertTrue(p.exitValue() == 0); + } + + private static void runInstallSerialDriver() throws Exception { + ProcessBuilder pb = ProcessTools.createJavaProcessBuilder(true, + "-classpath", + SHARE.toString() + + File.pathSeparator + + NCLASSES.toString(), + "install.SerialDriver", "-d"); + Process p = ProcessTools.startProcess("install SerialDriver", pb); + p.waitFor(); + assertTrue(p.exitValue() == 0); + } + + private static void assertTrue(boolean b) { + if (!b) { + throw new RuntimeException("expected true, get false"); + } + } +} diff --git a/jdk/test/java/io/Serializable/evolution/RenamePackage/run.sh b/jdk/test/java/io/Serializable/evolution/RenamePackage/run.sh deleted file mode 100644 index eb9f210083f..00000000000 --- a/jdk/test/java/io/Serializable/evolution/RenamePackage/run.sh +++ /dev/null @@ -1,105 +0,0 @@ -# -# Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4087295 4785472 -# @summary Enable resolveClass() to accommodate package renaming. -# This fix enables one to implement a resolveClass method that maps a -# Serialiazable class within a serialization stream to the same class -# in a different package within the JVM runtime. See run shell script -# for instructions on how to run this test. - - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." - exit 1 -fi - -if [ "${COMPILEJAVA}" = "" ] ; then - COMPILEJAVA="${TESTJAVA}" -fi - - -OS=`uname -s` -# Need to determine the classpath separator and filepath separator based on the -# operating system. -case "$OS" in -SunOS | Linux | Darwin | AIX ) - PS=":" ;; -Windows* | CYGWIN* ) - PS=";" ;; -* ) - echo "Unrecognized system!" - exit 1 ;; -esac - -JAVA=${TESTJAVA}/bin/java -JAVAC=${COMPILEJAVA}/bin/javac -MKDIR=mkdir -RDEL="rm -r" - -if [ -d ${TESTCLASSES}/oclasses ] -then - ${RDEL} ${TESTCLASSES}/oclasses -fi -if [ -d ${TESTCLASSES}/nclasses ] -then - ${RDEL} ${TESTCLASSES}/nclasses -fi -if [ -d ${TESTCLASSES}/share ] -then - ${RDEL} ${TESTCLASSES}/share -fi -if [ -f ${TESTCLASSES}/stream.ser ] -then - ${RDEL} ${TESTCLASSES}/stream.ser -fi - -mkdir ${TESTCLASSES}/oclasses -mkdir ${TESTCLASSES}/share -mkdir ${TESTCLASSES}/nclasses - -# Build sources -set -e -${JAVAC} ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d ${TESTCLASSES}/share \ - ${TESTSRC}/extension/ExtendedObjectInputStream.java -CLASSPATH=${TESTCLASSES}/share; export CLASSPATH; -${JAVAC} ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d ${TESTCLASSES}/oclasses \ - ${TESTSRC}/test/SerialDriver.java -CLASSPATH=${TESTCLASSES}/share; export CLASSPATH; -${JAVAC} ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d ${TESTCLASSES}/nclasses \ - ${TESTSRC}/install/SerialDriver.java - -# Run Case 1. Map test.SerialDriver within stream to install.SerialDriver. -CLASSPATH="${TESTCLASSES}/oclasses${PS}${TESTCLASSES}/share"; export CLASSPATH; -${JAVA} ${TESTVMOPTS} test.SerialDriver -s -CLASSPATH="${TESTCLASSES}/nclasses${PS}${TESTCLASSES}/share"; export CLASSPATH; -${JAVA} ${TESTVMOPTS} install.SerialDriver -d -rm stream.ser - -# Run Case 2. Map install.SerialDriver within stream to test.SerialDriver. -CLASSPATH="${TESTCLASSES}/nclasses${PS}${TESTCLASSES}/share"; export CLASSPATH; -${JAVA} ${TESTVMOPTS} install.SerialDriver -s -CLASSPATH="${TESTCLASSES}/oclasses${PS}${TESTCLASSES}/share"; export CLASSPATH; -${JAVA} ${TESTVMOPTS} test.SerialDriver -d diff --git a/jdk/test/java/io/Serializable/failureAtomicity/FailureAtomicity.java b/jdk/test/java/io/Serializable/failureAtomicity/FailureAtomicity.java index 789153d394d..8be6ce1142b 100644 --- a/jdk/test/java/io/Serializable/failureAtomicity/FailureAtomicity.java +++ b/jdk/test/java/io/Serializable/failureAtomicity/FailureAtomicity.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,9 @@ * @bug 8071474 * @summary Better failure atomicity for default read object. * @modules jdk.compiler - * @library /lib/testlibrary - * @build jdk.testlibrary.FileUtils + * @library /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @compile FailureAtomicity.java SerialRef.java * @run main failureAtomicity.FailureAtomicity */ @@ -59,7 +60,7 @@ import javax.tools.JavaFileObject; import javax.tools.StandardJavaFileManager; import javax.tools.StandardLocation; import javax.tools.ToolProvider; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; @SuppressWarnings("unchecked") public class FailureAtomicity { diff --git a/jdk/test/java/io/Serializable/maskSyntheticModifier/Test.java b/jdk/test/java/io/Serializable/maskSyntheticModifier/MaskSyntheticModifierTest.java similarity index 71% rename from jdk/test/java/io/Serializable/maskSyntheticModifier/Test.java rename to jdk/test/java/io/Serializable/maskSyntheticModifier/MaskSyntheticModifierTest.java index 23e445a441e..08ee9cd6238 100644 --- a/jdk/test/java/io/Serializable/maskSyntheticModifier/Test.java +++ b/jdk/test/java/io/Serializable/maskSyntheticModifier/MaskSyntheticModifierTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,19 +22,31 @@ */ /* + * @test * @bug 4897937 + * @run main MaskSyntheticModifierTest * @summary Verify that the presence of the JVM_ACC_SYNTHETIC bit in the * modifiers of fields and methods does not affect default * serialVersionUID calculation. */ import java.io.ObjectStreamClass; +import java.nio.file.Files; +import java.nio.file.Paths; +import java.nio.file.StandardCopyOption; + +public class MaskSyntheticModifierTest { + public static void main(String[] args) throws Exception { + setup(); -public class Test { - public static void main(String[] args) { long suid = ObjectStreamClass.lookup(Foo.class).getSerialVersionUID(); if (suid != 8027844768744011556L) { throw new Error("incorrect serialVersionUID: " + suid); } } + + private static void setup() throws Exception { + Files.copy(Paths.get(System.getProperty("test.src"), "Foo.class"), + Paths.get("Foo.class"), StandardCopyOption.REPLACE_EXISTING); + } } diff --git a/jdk/test/java/io/Serializable/maskSyntheticModifier/run.sh b/jdk/test/java/io/Serializable/maskSyntheticModifier/run.sh deleted file mode 100644 index eb06b407b1c..00000000000 --- a/jdk/test/java/io/Serializable/maskSyntheticModifier/run.sh +++ /dev/null @@ -1,49 +0,0 @@ -# -# Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4897937 -# @summary Verify that the presence of the JVM_ACC_SYNTHETIC bit in the -# modifiers of fields and methods does not affect default -# serialVersionUID calculation. - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." -exit 1 -fi - -if [ "${COMPILEJAVA}" = "" ] ; then - COMPILEJAVA="${TESTJAVA}" -fi - -if [ "${TESTSRC}" = "" ] -then - TESTSRC="." -fi - -set -ex -cp ${TESTSRC}/Foo.class . -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}/Test.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -rm -f *.class diff --git a/jdk/test/java/io/Serializable/packageAccess/Test.java b/jdk/test/java/io/Serializable/packageAccess/PackageAccessTest.java similarity index 55% rename from jdk/test/java/io/Serializable/packageAccess/Test.java rename to jdk/test/java/io/Serializable/packageAccess/PackageAccessTest.java index 464ccb93504..d53cb3485a8 100644 --- a/jdk/test/java/io/Serializable/packageAccess/Test.java +++ b/jdk/test/java/io/Serializable/packageAccess/PackageAccessTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,41 +22,59 @@ */ /* + * @test * @bug 4765255 + * @library /lib/testlibrary + * @build JarUtils A B C D PackageAccessTest + * @run main PackageAccessTest * @summary Verify proper functioning of package equality checks used to * determine accessibility of superclass constructor and inherited * writeReplace/readResolve methods. */ -import java.io.*; -import java.net.*; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.InputStream; +import java.io.IOException; +import java.io.ObjectInputStream; +import java.io.ObjectOutputStream; +import java.io.ObjectStreamClass; +import java.io.InvalidClassException; +import java.net.URL; +import java.net.URLClassLoader; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; -public class Test { +public class PackageAccessTest { static Class bcl; static Class dcl; public static void main(String[] args) throws Exception { - ClassLoader ldr = + setup(); + + try (URLClassLoader ldr = new URLClassLoader(new URL[]{ new URL("file:foo.jar") }, - Test.class.getClassLoader()); - bcl = Class.forName("B", true, ldr); - dcl = Class.forName("D", true, ldr); + PackageAccessTest.class.getClassLoader())) { + bcl = Class.forName("B", true, ldr); + dcl = Class.forName("D", true, ldr); - Object b = bcl.newInstance(); - try { - swizzle(b); - throw new Error("expected InvalidClassException for class B"); - } catch (InvalidClassException e) { - System.out.println("caught " + e); - e.printStackTrace(); - } - if (A.packagePrivateConstructorInvoked) { - throw new Error("package private constructor of A invoked"); - } + Object b = bcl.newInstance(); + try { + swizzle(b); + throw new Error("expected InvalidClassException for class B"); + } catch (InvalidClassException e) { + System.out.println("caught " + e); + e.printStackTrace(); + } + if (A.packagePrivateConstructorInvoked) { + throw new Error("package private constructor of A invoked"); + } - Object d = dcl.newInstance(); - swizzle(d); + Object d = dcl.newInstance(); + swizzle(d); + } } static void swizzle(Object obj) throws Exception { @@ -68,6 +86,14 @@ public class Test { new ByteArrayInputStream(bout.toByteArray()); new TestObjectInputStream(bin).readObject(); } + + static void setup() throws Exception { + Path classes = Paths.get(System.getProperty("test.classes", "")); + JarUtils.createJarFile(Paths.get("foo.jar"), classes, + classes.resolve("B.class"), classes.resolve("D.class")); + Files.delete(classes.resolve("B.class")); + Files.delete(classes.resolve("D.class")); + } } class TestObjectInputStream extends ObjectInputStream { @@ -80,9 +106,9 @@ class TestObjectInputStream extends ObjectInputStream { { String n = desc.getName(); if (n.equals("B")) { - return Test.bcl; + return PackageAccessTest.bcl; } else if (n.equals("D")) { - return Test.dcl; + return PackageAccessTest.dcl; } else { return super.resolveClass(desc); } diff --git a/jdk/test/java/io/Serializable/packageAccess/run.sh b/jdk/test/java/io/Serializable/packageAccess/run.sh deleted file mode 100644 index 29e9267abcc..00000000000 --- a/jdk/test/java/io/Serializable/packageAccess/run.sh +++ /dev/null @@ -1,54 +0,0 @@ -# -# Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4765255 -# @summary Verify proper functioning of package equality checks used to -# determine accessibility of superclass constructor and inherited -# writeReplace/readResolve methods. - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." -exit 1 -fi - -if [ "${COMPILEJAVA}" = "" ] ; then - COMPILEJAVA="${TESTJAVA}" -fi - -if [ "${TESTSRC}" = "" ] -then - TESTSRC="." -fi - -set -ex - -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . \ - ${TESTSRC}/A.java ${TESTSRC}/B.java ${TESTSRC}/C.java ${TESTSRC}/D.java \ - ${TESTSRC}/Test.java -${COMPILEJAVA}/bin/jar ${TESTTOOLVMOPTS} cf foo.jar B.class D.class -rm -f B.class D.class - -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -rm -f *.class *.jar diff --git a/jdk/test/java/io/Serializable/resolveClass/consTest/Test.java b/jdk/test/java/io/Serializable/resolveClass/consTest/ConsTest.java similarity index 76% rename from jdk/test/java/io/Serializable/resolveClass/consTest/Test.java rename to jdk/test/java/io/Serializable/resolveClass/consTest/ConsTest.java index 1bd03ece763..3cabfdd5014 100644 --- a/jdk/test/java/io/Serializable/resolveClass/consTest/Test.java +++ b/jdk/test/java/io/Serializable/resolveClass/consTest/ConsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,21 +22,30 @@ */ /* + * @test * @bug 4413434 + * @library /lib/testlibrary + * @build JarUtils SetupJar Boot + * @run driver SetupJar + * @run main/othervm -Xbootclasspath/a:boot.jar ConsTest * @summary Verify that generated java.lang.reflect implementation classes do * not interfere with serialization's class resolution mechanism. */ -import java.io.*; -import java.lang.reflect.*; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.ObjectInputStream; +import java.io.ObjectOutputStream; +import java.io.Serializable; +import java.lang.reflect.Constructor; -public class Test implements Serializable { +public class ConsTest implements Serializable { public static void main(String[] args) throws Exception { Constructor cons = Boot.class.getConstructor( new Class[] { ObjectInputStream.class }); ByteArrayOutputStream bout = new ByteArrayOutputStream(); ObjectOutputStream oout = new ObjectOutputStream(bout); - oout.writeObject(new Test()); + oout.writeObject(new ConsTest()); oout.close(); for (int i = 0; i < 100; i++) { diff --git a/jdk/test/java/io/Serializable/resolveClass/consTest/SetupJar.java b/jdk/test/java/io/Serializable/resolveClass/consTest/SetupJar.java new file mode 100644 index 00000000000..f741a61af3b --- /dev/null +++ b/jdk/test/java/io/Serializable/resolveClass/consTest/SetupJar.java @@ -0,0 +1,34 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.nio.file.Path; +import java.nio.file.Paths; + +public class SetupJar { + + public static void main(String args[]) throws Exception { + Path classes = Paths.get(System.getProperty("test.classes", "")); + JarUtils.createJarFile(Paths.get("boot.jar"), classes, + classes.resolve("Boot.class")); + } +} diff --git a/jdk/test/java/io/Serializable/resolveClass/consTest/run.sh b/jdk/test/java/io/Serializable/resolveClass/consTest/run.sh deleted file mode 100644 index 5dfa01e31e8..00000000000 --- a/jdk/test/java/io/Serializable/resolveClass/consTest/run.sh +++ /dev/null @@ -1,53 +0,0 @@ -# -# Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4413434 -# @summary Verify that generated java.lang.reflect implementation classes do -# not interfere with serialization's class resolution mechanism. - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." -exit 1 -fi - -if [ "${COMPILEJAVA}" = "" ] ; then - COMPILEJAVA="${TESTJAVA}" -fi - -if [ "${TESTSRC}" = "" ] -then - TESTSRC="." -fi - -set -ex - -rm -f *.class *.jar -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}/Boot.java -${COMPILEJAVA}/bin/jar ${TESTTOOLVMOPTS} cf boot.jar *.class -rm -f *.class -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -classpath boot.jar -d . \ - ${TESTSRC}/Test.java -${TESTJAVA}/bin/java ${TESTVMOPTS} -Xbootclasspath/a:boot.jar Test -rm -f *.class *.jar diff --git a/jdk/test/java/io/Serializable/resolveClass/deserializeButton/DeserializeButtonTest.java b/jdk/test/java/io/Serializable/resolveClass/deserializeButton/DeserializeButtonTest.java new file mode 100644 index 00000000000..31f6b12f8b0 --- /dev/null +++ b/jdk/test/java/io/Serializable/resolveClass/deserializeButton/DeserializeButtonTest.java @@ -0,0 +1,59 @@ +/* + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4413434 + * @library /lib/testlibrary + * @build JarUtils Foo + * @run main DeserializeButtonTest + * @summary Verify that class loaded outside of application class loader is + * correctly resolved during deserialization when read in by custom + * readObject() method of a bootstrap class (in this case, + * java.util.Vector). + */ + +import java.net.URLClassLoader; +import java.net.URL; +import java.nio.file.Path; +import java.nio.file.Paths; + +public class DeserializeButtonTest { + public static void main(String[] args) throws Exception { + setup(); + + try (URLClassLoader ldr = + new URLClassLoader(new URL[]{ new URL("file:cb.jar") })) { + Runnable r = (Runnable) Class.forName("Foo", true, ldr).newInstance(); + r.run(); + } + } + + private static void setup() throws Exception { + Path classes = Paths.get(System.getProperty("test.classes", "")); + JarUtils.createJarFile(Paths.get("cb.jar"), + classes, + classes.resolve("Foo.class"), + classes.resolve("Foo$TestElement.class")); + } +} diff --git a/jdk/test/java/io/Serializable/resolveClass/deserializeButton/run.sh b/jdk/test/java/io/Serializable/resolveClass/deserializeButton/run.sh deleted file mode 100644 index 40b3da0e028..00000000000 --- a/jdk/test/java/io/Serializable/resolveClass/deserializeButton/run.sh +++ /dev/null @@ -1,54 +0,0 @@ -# -# Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4413434 -# @summary Verify that class loaded outside of application class loader is -# correctly resolved during deserialization when read in by custom -# readObject() method of a bootstrap class (in this case, -# java.util.Vector). - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." -exit 1 -fi - -if [ "${COMPILEJAVA}" = "" ] ; then - COMPILEJAVA="${TESTJAVA}" -fi - -if [ "${TESTSRC}" = "" ] -then - TESTSRC="." -fi - -set -ex - -rm -f *.class *.jar -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}/Foo.java -${COMPILEJAVA}/bin/jar ${TESTTOOLVMOPTS} cf cb.jar *.class -rm -f *.class -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}/Test.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -rm -f *.class *.jar diff --git a/jdk/test/java/io/Serializable/serialver/classpath/ClasspathTest.java b/jdk/test/java/io/Serializable/serialver/classpath/ClasspathTest.java new file mode 100644 index 00000000000..92986eb5aea --- /dev/null +++ b/jdk/test/java/io/Serializable/serialver/classpath/ClasspathTest.java @@ -0,0 +1,63 @@ +/* + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4035147 4785472 + * @library /test/lib + * @build jdk.test.lib.Utils + * @build jdk.test.lib.Asserts + * @build jdk.test.lib.JDKToolFinder + * @build jdk.test.lib.JDKToolLauncher + * @build jdk.test.lib.Platform + * @build jdk.test.lib.process.* + * @build ClasspathTest + * @run main serialver.ClasspathTest + * @summary Test the use of the -classpath switch in the serialver application. + */ + +package serialver; + +import java.io.File; + +import jdk.test.lib.JDKToolLauncher; +import jdk.test.lib.process.ProcessTools; + +public class ClasspathTest implements java.io.Serializable { + int a; + int b; + + public static void main(String args[]) throws Exception { + JDKToolLauncher serialver = + JDKToolLauncher.create("serialver") + .addToolArg("-classpath") + .addToolArg(System.getProperty("test.class.path")) + .addToolArg("serialver.ClasspathTest"); + Process p = ProcessTools.startProcess("serialver", + new ProcessBuilder(serialver.getCommand())); + p.waitFor(); + if (p.exitValue() != 0) { + throw new RuntimeException("error occurs in serialver"); + } + } +} diff --git a/jdk/test/java/io/Serializable/serialver/classpath/run.sh b/jdk/test/java/io/Serializable/serialver/classpath/run.sh deleted file mode 100644 index 2aa1b0e92ea..00000000000 --- a/jdk/test/java/io/Serializable/serialver/classpath/run.sh +++ /dev/null @@ -1,64 +0,0 @@ -# -# Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4035147 4785472 -# @summary Test the use of the -classpath switch in the serialver application. -# @author Naveen Sanjeeva -# -# @build Test -# @run shell run.sh - -# set a few environment variables so that the shell-script can run stand-alone -# in the source directory - -if [ "${TESTSRC}" = "" ] ; then - TESTSRC="." -fi -if [ "${TESTCLASSES}" = "" ] ; then - TESTCLASSES="." -fi -if [ "${TESTJAVA}" = "" ] ; then - echo "TESTJAVA not set. Test cannot execute." - echo "FAILED!!!" - exit 1 -fi - -# set platform-dependent variables -OS=`uname -s` -case "$OS" in - SunOS | Linux | Darwin | AIX ) - PS=":" ;; - Windows* | CYGWIN* ) - PS=";" ;; - * ) - echo "Unrecognized system!" - exit 1 ;; -esac - -# the test code - -echo "Using the classpath .${PS}${TESTCLASSES}" -${TESTJAVA}/bin/serialver -classpath ".${PS}${TESTCLASSES}" serialver.Test - -exit $? diff --git a/jdk/test/java/io/Serializable/serialver/nested/NestedTest.java b/jdk/test/java/io/Serializable/serialver/nested/NestedTest.java new file mode 100644 index 00000000000..9b8963b355e --- /dev/null +++ b/jdk/test/java/io/Serializable/serialver/nested/NestedTest.java @@ -0,0 +1,67 @@ +/* + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4312217 4785473 + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @build NestedTest + * @run main serialver.NestedTest + * @summary To test the use of nested class specification using the '.' + * notation instead of the '$' notation. + */ + +package serialver; + +import java.io.Serializable; + +import jdk.test.lib.JDKToolLauncher; +import jdk.test.lib.process.ProcessTools; + +public class NestedTest implements Serializable { + public static class Test1 implements Serializable { + public static class Test2 implements Serializable{ + private static final long serialVersionUID = 100L; + } + } + + public static void main(String args[]) throws Exception { + JDKToolLauncher serialver = + JDKToolLauncher.create("serialver") + .addToolArg("-classpath") + .addToolArg(System.getProperty("test.class.path")) + .addToolArg("serialver.NestedTest.Test1.Test2"); + Process p = ProcessTools.startProcess("serialver", + new ProcessBuilder(serialver.getCommand())); + p.waitFor(); + if (p.exitValue() != 0) { + throw new RuntimeException("error occurs in serialver."); + } + } +} diff --git a/jdk/test/java/io/Serializable/serialver/nested/run.sh b/jdk/test/java/io/Serializable/serialver/nested/run.sh deleted file mode 100644 index 578e74afc51..00000000000 --- a/jdk/test/java/io/Serializable/serialver/nested/run.sh +++ /dev/null @@ -1,64 +0,0 @@ -# -# Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4312217 4785473 -# @summary Test the use of the -classpath switch in the serialver application. -# @author Naveen Sanjeeva -# -# @build Test -# @run shell run.sh - -# set a few environment variables so that the shell-script can run stand-alone -# in the source directory - -if [ "${TESTSRC}" = "" ] ; then - TESTSRC="." -fi -if [ "${TESTCLASSES}" = "" ] ; then - TESTCLASSES="." -fi -if [ "${TESTJAVA}" = "" ] ; then - echo "TESTJAVA not set. Test cannot execute." - echo "FAILED!!!" - exit 1 -fi - -# set platform-dependent variables -OS=`uname -s` -case "$OS" in - SunOS | Linux | Darwin | AIX ) - PS=":" ;; - Windows* | CYGWIN* ) - PS=";" ;; - * ) - echo "Unrecognized system!" - exit 1 ;; -esac - -# the test code - -echo "Using the classpath .${PS}${TESTCLASSES}" -${TESTJAVA}/bin/serialver -classpath ".${PS}${TESTCLASSES}" 'serialver.Test.Test1.Test2' - -exit $? diff --git a/jdk/test/java/io/Serializable/subclass/Allow.policy b/jdk/test/java/io/Serializable/subclass/Allow.policy index 234de2c9d37..a31cebf4926 100644 --- a/jdk/test/java/io/Serializable/subclass/Allow.policy +++ b/jdk/test/java/io/Serializable/subclass/Allow.policy @@ -2,7 +2,6 @@ grant { // "standard" properies that can be read by anyone permission java.io.FilePermission "-","read,write,execute"; permission java.io.SerializablePermission "enableSubstitution"; - permission java.io.SerializablePermission "enableSubclassImplementation"; // Needed to get access to private writeObjectMethod and // to be able to call it. diff --git a/jdk/test/java/io/Serializable/subclass/Test.java b/jdk/test/java/io/Serializable/subclass/SubclassTest.java similarity index 83% rename from jdk/test/java/io/Serializable/subclass/Test.java rename to jdk/test/java/io/Serializable/subclass/SubclassTest.java index bc72741cba1..916e1d4295c 100644 --- a/jdk/test/java/io/Serializable/subclass/Test.java +++ b/jdk/test/java/io/Serializable/subclass/SubclassTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,23 +26,32 @@ * @bug 4100915 * @summary Verify that [write/read]ObjectOverride methods get called. * Test verifies that ALL methods to write an object can - * be overridden. Howver, the testing for reading an object + * be overridden. However, the testing for reading an object * is incomplete. Only test that readObjectOverride is called. * An entire protocol would need to be implemented and written * out before being able to test the input side of the API. * * Also, would be appropriate that this program verify - * that if SerializablePermission "enableSubclassImplamentation" + * that if SerializablePermission "enableSubclassImplementation" * is not in the security policy and security is enabled, that - * a security excepiton is thrown when constructing the + * a security exception is thrown when constructing the * ObjectOutputStream subclass. * * - * @compile AbstractObjectInputStream.java AbstractObjectOutputStream.java XObjectInputStream.java XObjectOutputStream.java Test.java - * @run main Test + * @compile AbstractObjectInputStream.java AbstractObjectOutputStream.java + * @compile XObjectInputStream.java XObjectOutputStream.java + * @compile SubclassTest.java + * @run main SubclassTest + * @run main/othervm/policy=Allow.policy SubclassTest -expectSecurityException */ -import java.io.*; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.io.ObjectInputStream; +import java.io.ObjectOutputStream; +import java.io.ObjectStreamField; +import java.io.Serializable; /** * Test if customized readObject and writeObject are called. @@ -111,7 +120,7 @@ class A implements Serializable { } }; -public class Test { +public class SubclassTest { public static void main(String argv[]) throws IOException, ClassNotFoundException { @@ -129,10 +138,11 @@ public class Test { throw new Error("Assertion failure. " + "Expected a security exception on previous line."); } catch (SecurityException e) { - if (expectSecurityException) + if (expectSecurityException) { + System.err.println("Caught expected security exception."); return; - else - throw e; + } + throw e; } os.writeObject(new A()); os.close(); diff --git a/jdk/test/java/io/Serializable/subclass/run.sh b/jdk/test/java/io/Serializable/subclass/run.sh deleted file mode 100644 index 8990d50f19b..00000000000 --- a/jdk/test/java/io/Serializable/subclass/run.sh +++ /dev/null @@ -1,30 +0,0 @@ -# -# Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# -# @bug 4100915 -mkdir classes -javac -d classes *.java -java ${TESTVMOPTS} -classpath classes -Djava.policy=Allow.policy Test -# ENABLE next line when new method for invoking a main with a SecureClassLoader is known -#java -classpath classes -Djava.policy=NotAllow.policy Test -expectSecurityException diff --git a/jdk/test/java/io/Serializable/superclassDataLoss/SuperclassDataLossTest.java b/jdk/test/java/io/Serializable/superclassDataLoss/SuperclassDataLossTest.java new file mode 100644 index 00000000000..c1674d1a0de --- /dev/null +++ b/jdk/test/java/io/Serializable/superclassDataLoss/SuperclassDataLossTest.java @@ -0,0 +1,121 @@ +/* + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4325590 + * @library /lib/testlibrary + * @build JarUtils A B + * @run main SuperclassDataLossTest + * @summary Verify that superclass data is not lost when incoming superclass + * descriptor is matched with local class that is not a superclass of + * the deserialized instance's class. + */ + +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.InputStream; +import java.io.IOException; +import java.io.ObjectInputStream; +import java.io.ObjectOutputStream; +import java.io.ObjectStreamClass; +import java.net.URL; +import java.net.URLClassLoader; +import java.net.MalformedURLException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.nio.file.StandardCopyOption; + +class MixedSuperclassStream extends ObjectInputStream { + private boolean ldr12A; + private URLClassLoader ldr1; + private URLClassLoader ldr2; + + MixedSuperclassStream(InputStream in, URLClassLoader ldr1, + URLClassLoader ldr2, boolean ldr1First) throws IOException { + super(in); + this.ldr1 = ldr1; + this.ldr2 = ldr2; + this.ldr12A = ldr12A; + } + + protected Class resolveClass(ObjectStreamClass desc) + throws IOException, ClassNotFoundException + { + // resolve A's classdesc to class != B's superclass + String name = desc.getName(); + if (ldr12A) { + if (name.equals("A")) { + return Class.forName(name, true, ldr1); + } else if (name.equals("B")) { + return Class.forName(name, true, ldr2); + } + } else { + if (name.equals("B")) { + return Class.forName(name, true, ldr1); + } else if (name.equals("A")) { + return Class.forName(name, true, ldr2); + } + } + return super.resolveClass(desc); + } +} + +public class SuperclassDataLossTest { + + public static void main(String[] args) throws Exception { + try (URLClassLoader ldr1 = new URLClassLoader(new URL[] { new URL("file:cb1.jar") }); + URLClassLoader ldr2 = new URLClassLoader(new URL[] { new URL("file:cb2.jar") })) { + setup(); + + Runnable a = (Runnable) Class.forName("B", true, ldr1).newInstance(); + a.run(); + + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + ObjectOutputStream oout = new ObjectOutputStream(bout); + oout.writeObject(a); + oout.close(); + + test(bout, ldr1, ldr2, true); + test(bout, ldr1, ldr2, false); + } + } + + private static void test(ByteArrayOutputStream bout, URLClassLoader ldr1, + URLClassLoader ldr2, boolean ldr12A) throws Exception { + ByteArrayInputStream bin = + new ByteArrayInputStream(bout.toByteArray()); + ObjectInputStream oin = new MixedSuperclassStream(bin, ldr1, ldr2, ldr12A); + Runnable a = (Runnable) oin.readObject(); + a.run(); + } + + private static void setup() throws Exception { + Path classes = Paths.get(System.getProperty("test.classes", "")); + JarUtils.createJarFile(Paths.get("cb1.jar"), classes, + classes.resolve("A.class"), classes.resolve("B.class")); + Files.copy(Paths.get("cb1.jar"), Paths.get("cb2.jar"), + StandardCopyOption.REPLACE_EXISTING); + } +} diff --git a/jdk/test/java/io/Serializable/superclassDataLoss/Test.java b/jdk/test/java/io/Serializable/superclassDataLoss/Test.java deleted file mode 100644 index 49db5f8ae27..00000000000 --- a/jdk/test/java/io/Serializable/superclassDataLoss/Test.java +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -/* - * @bug 4325590 - * @summary Verify that superclass data is not lost when incoming superclass - * descriptor is matched with local class that is not a superclass of - * the deserialized instance's class. - */ - -import java.io.*; -import java.net.*; - -class MixedSuperclassStream extends ObjectInputStream { - MixedSuperclassStream(InputStream in) throws IOException { super(in); } - - protected Class resolveClass(ObjectStreamClass desc) - throws IOException, ClassNotFoundException - { - // resolve A's classdesc to class != B's superclass - String name = desc.getName(); - if (name.equals("A")) { - return Class.forName(name, true, Test.ldr1); - } else if (name.equals("B")) { - return Class.forName(name, true, Test.ldr2); - } else { - return super.resolveClass(desc); - } - } -} - -public class Test { - - static URLClassLoader ldr1, ldr2; - static { - try { - ldr1 = new URLClassLoader(new URL[] { new URL("file:cb1.jar") }); - ldr2 = new URLClassLoader(new URL[] { new URL("file:cb2.jar") }); - } catch (MalformedURLException ex) { - throw new Error(); - } - } - - public static void main(String[] args) throws Exception { - Runnable a = (Runnable) Class.forName("B", true, ldr1).newInstance(); - a.run(); - - ByteArrayOutputStream bout = new ByteArrayOutputStream(); - ObjectOutputStream oout = new ObjectOutputStream(bout); - oout.writeObject(a); - oout.close(); - - ByteArrayInputStream bin = - new ByteArrayInputStream(bout.toByteArray()); - ObjectInputStream oin = new MixedSuperclassStream(bin); - a = (Runnable) oin.readObject(); - a.run(); - } -} diff --git a/jdk/test/java/io/Serializable/superclassDataLoss/run.sh b/jdk/test/java/io/Serializable/superclassDataLoss/run.sh deleted file mode 100644 index 7550cd2c3cb..00000000000 --- a/jdk/test/java/io/Serializable/superclassDataLoss/run.sh +++ /dev/null @@ -1,56 +0,0 @@ -# -# Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4325590 -# @summary Verify that superclass data is not lost when incoming superclass -# descriptor is matched with local class that is not a superclass of -# the deserialized instance's class. - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." -exit 1 -fi - -if [ "${COMPILEJAVA}" = "" ] ; then - COMPILEJAVA="${TESTJAVA}" -fi - -if [ "${TESTSRC}" = "" ] -then - TESTSRC="." -fi - -set -ex - -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . \ - ${TESTSRC}/A.java ${TESTSRC}/B.java -${COMPILEJAVA}/bin/jar ${TESTTOOLVMOPTS} cf cb1.jar A.class B.class -cp cb1.jar cb2.jar -rm -f A.class B.class - -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . \ - ${TESTSRC}/Test.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test -rm -f *.class *.jar diff --git a/jdk/test/java/io/Serializable/unnamedPackageSwitch/Test.java b/jdk/test/java/io/Serializable/unnamedPackageSwitch/UnnamedPackageSwitchTest.java similarity index 82% rename from jdk/test/java/io/Serializable/unnamedPackageSwitch/Test.java rename to jdk/test/java/io/Serializable/unnamedPackageSwitch/UnnamedPackageSwitchTest.java index 51944dfd5b3..9f2b9c88ba9 100644 --- a/jdk/test/java/io/Serializable/unnamedPackageSwitch/Test.java +++ b/jdk/test/java/io/Serializable/unnamedPackageSwitch/UnnamedPackageSwitchTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,23 @@ */ /* + * @test * @bug 4348213 + * @build UnnamedPackageSwitchTest pkg.A + * @run main UnnamedPackageSwitchTest * @summary Verify that deserialization allows an incoming class descriptor * representing a class in the unnamed package to be resolved to a * local class with the same name in a named package, and vice-versa. */ -import java.io.*; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.InputStream; +import java.io.IOException; +import java.io.ObjectOutputStream; +import java.io.ObjectInputStream; +import java.io.ObjectStreamClass; +import java.io.Serializable; class A implements Serializable { private static final long serialVersionUID = 0L; @@ -50,7 +60,7 @@ class TestObjectInputStream extends ObjectInputStream { } } -public class Test { +public class UnnamedPackageSwitchTest { public static void main(String[] args) throws Exception { ByteArrayOutputStream bout = new ByteArrayOutputStream(); ObjectOutputStream oout = new ObjectOutputStream(bout); diff --git a/jdk/test/java/io/Serializable/unnamedPackageSwitch/run.sh b/jdk/test/java/io/Serializable/unnamedPackageSwitch/run.sh deleted file mode 100644 index e801163af0e..00000000000 --- a/jdk/test/java/io/Serializable/unnamedPackageSwitch/run.sh +++ /dev/null @@ -1,49 +0,0 @@ -# -# Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4348213 -# @summary Verify that deserialization allows an incoming class descriptor -# representing a class in the unnamed package to be resolved to a -# local class with the same name in a named package, and vice-versa. - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." -exit 1 -fi - -if [ "${COMPILEJAVA}" = "" ] ; then - COMPILEJAVA="${TESTJAVA}" -fi - -if [ "${TESTSRC}" = "" ] -then - TESTSRC="." -fi - -set -ex - -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . \ - ${TESTSRC}/A.java ${TESTSRC}/Test.java -${TESTJAVA}/bin/java ${TESTVMOPTS} Test diff --git a/jdk/test/java/lang/Class/forName/modules/TestDriver.java b/jdk/test/java/lang/Class/forName/modules/TestDriver.java index 7ab1f636c9e..ad14b3969c8 100644 --- a/jdk/test/java/lang/Class/forName/modules/TestDriver.java +++ b/jdk/test/java/lang/Class/forName/modules/TestDriver.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,7 +29,8 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.BeforeClass; @@ -40,9 +41,13 @@ import static org.testng.Assert.assertTrue; * @test * @bug 8087335 * @summary Tests for Class.forName(Module,String) - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build TestDriver CompilerUtils jdk.testlibrary.ProcessTools jdk.testlibrary.FileUtils TestMain TestLayer + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils + * jdk.test.lib.compiler.CompilerUtils + * jdk.testlibrary.ProcessTools + * TestDriver TestMain TestLayer * @run testng TestDriver */ diff --git a/jdk/test/java/lang/Class/getResource/ResourcesTest.java b/jdk/test/java/lang/Class/getResource/ResourcesTest.java index 7d155765c1b..0e031957a15 100644 --- a/jdk/test/java/lang/Class/getResource/ResourcesTest.java +++ b/jdk/test/java/lang/Class/getResource/ResourcesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,7 @@ import java.nio.file.Path; import java.nio.file.Paths; import static jdk.testlibrary.ProcessTools.executeTestJava; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; @@ -32,9 +33,9 @@ import static org.testng.Assert.*; /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build ResourcesTest CompilerUtils jdk.testlibrary.* + * @build ResourcesTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng ResourcesTest * @summary Driver for basic test of Class getResource and getResourceAsStream */ diff --git a/jdk/test/java/lang/ClassLoader/getResource/modules/ResourcesTest.java b/jdk/test/java/lang/ClassLoader/getResource/modules/ResourcesTest.java index 65f0d371a82..ddc9d71baf3 100644 --- a/jdk/test/java/lang/ClassLoader/getResource/modules/ResourcesTest.java +++ b/jdk/test/java/lang/ClassLoader/getResource/modules/ResourcesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,7 @@ import java.nio.file.Path; import java.nio.file.Paths; import static jdk.testlibrary.ProcessTools.executeTestJava; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; @@ -33,9 +34,9 @@ import static org.testng.Assert.*; /** * @test * @bug 8087335 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build ResourcesTest CompilerUtils jdk.testlibrary.* + * @build ResourcesTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng ResourcesTest * @summary Driver for basic test of ClassLoader getResource and getResourceAsStream */ diff --git a/jdk/test/java/lang/Double/ParseHexFloatingPoint.java b/jdk/test/java/lang/Double/ParseHexFloatingPoint.java index e4b2ac2a62e..a26a8b7a756 100644 --- a/jdk/test/java/lang/Double/ParseHexFloatingPoint.java +++ b/jdk/test/java/lang/Double/ParseHexFloatingPoint.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main ParseHexFloatingPoint * @bug 4826774 8078672 * @summary Numerical tests for hexadecimal inputs to parse{Double, Float} (use -Dseed=X to set PRNG seed) @@ -32,7 +32,7 @@ * @key randomness */ -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class ParseHexFloatingPoint { private ParseHexFloatingPoint(){} diff --git a/jdk/test/java/lang/Integer/BitTwiddle.java b/jdk/test/java/lang/Integer/BitTwiddle.java index 50b5762bd7d..efa8c411331 100644 --- a/jdk/test/java/lang/Integer/BitTwiddle.java +++ b/jdk/test/java/lang/Integer/BitTwiddle.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main BitTwiddle * @bug 4495754 8078672 * @summary Basic test for int bit twiddling (use -Dseed=X to set PRNG seed) @@ -33,7 +33,7 @@ */ import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; import static java.lang.Integer.*; public class BitTwiddle { diff --git a/jdk/test/java/lang/Long/BitTwiddle.java b/jdk/test/java/lang/Long/BitTwiddle.java index d3833ae042c..7502d40aff3 100644 --- a/jdk/test/java/lang/Long/BitTwiddle.java +++ b/jdk/test/java/lang/Long/BitTwiddle.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main BitTwiddle * @bug 4495754 8078672 * @summary Basic test for long bit twiddling (use -Dseed=X to set PRNG seed) @@ -33,7 +33,7 @@ */ import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; import static java.lang.Long.*; public class BitTwiddle { diff --git a/jdk/test/java/lang/Math/CubeRootTests.java b/jdk/test/java/lang/Math/CubeRootTests.java index ca629a53db3..53ef270377f 100644 --- a/jdk/test/java/lang/Math/CubeRootTests.java +++ b/jdk/test/java/lang/Math/CubeRootTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main CubeRootTests * @bug 4347132 4939441 8078672 * @summary Tests for {Math, StrictMath}.cbrt (use -Dseed=X to set PRNG seed) @@ -32,7 +32,7 @@ * @key randomness */ -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class CubeRootTests { private CubeRootTests(){} diff --git a/jdk/test/java/lang/Math/HypotTests.java b/jdk/test/java/lang/Math/HypotTests.java index dbec84bf48f..0f31a8881f8 100644 --- a/jdk/test/java/lang/Math/HypotTests.java +++ b/jdk/test/java/lang/Math/HypotTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main HypotTests * @bug 4851638 4939441 8078672 * @summary Tests for {Math, StrictMath}.hypot (use -Dseed=X to set PRNG seed) @@ -32,7 +32,7 @@ * @key randomness */ -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class HypotTests { private HypotTests(){} diff --git a/jdk/test/java/lang/Math/IeeeRecommendedTests.java b/jdk/test/java/lang/Math/IeeeRecommendedTests.java index 5697505ef17..830b16d765a 100644 --- a/jdk/test/java/lang/Math/IeeeRecommendedTests.java +++ b/jdk/test/java/lang/Math/IeeeRecommendedTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main IeeeRecommendedTests * @bug 4860891 4826732 4780454 4939441 4826652 8078672 * @summary Tests for IEEE 754[R] recommended functions and similar methods (use -Dseed=X to set PRNG seed) @@ -32,7 +32,7 @@ * @key randomness */ -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class IeeeRecommendedTests { private IeeeRecommendedTests(){} diff --git a/jdk/test/java/lang/Math/Log1pTests.java b/jdk/test/java/lang/Math/Log1pTests.java index 7fda0203d75..021a651ed18 100644 --- a/jdk/test/java/lang/Math/Log1pTests.java +++ b/jdk/test/java/lang/Math/Log1pTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main Log1pTests * @bug 4851638 4939441 8078672 * @summary Tests for {Math, StrictMath}.log1p (use -Dseed=X to set PRNG seed) @@ -32,7 +32,7 @@ * @key randomness */ -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class Log1pTests { private Log1pTests(){} diff --git a/jdk/test/java/lang/Math/MultiplicationTests.java b/jdk/test/java/lang/Math/MultiplicationTests.java index 1a9c3da2a67..4fbb787e083 100644 --- a/jdk/test/java/lang/Math/MultiplicationTests.java +++ b/jdk/test/java/lang/Math/MultiplicationTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main MultiplicationTests * @bug 5100935 * @summary Tests for multiplication methods (use -Dseed=X to set PRNG seed) @@ -32,7 +32,7 @@ */ import java.math.BigInteger; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class MultiplicationTests { private MultiplicationTests(){} diff --git a/jdk/test/java/lang/ModuleLayer/LayerAndLoadersTest.java b/jdk/test/java/lang/ModuleLayer/LayerAndLoadersTest.java index a67555a47b1..1389e6e2a10 100644 --- a/jdk/test/java/lang/ModuleLayer/LayerAndLoadersTest.java +++ b/jdk/test/java/lang/ModuleLayer/LayerAndLoadersTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,9 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build LayerAndLoadersTest CompilerUtils ModuleUtils + * @build LayerAndLoadersTest jdk.test.lib.compiler.CompilerUtils ModuleUtils * @run testng LayerAndLoadersTest * @summary Tests for java.lang.ModuleLayer@defineModulesWithXXX methods */ @@ -48,6 +48,7 @@ import java.util.Optional; import java.util.ServiceLoader; import java.util.Set; import java.util.stream.Collectors; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; diff --git a/jdk/test/java/lang/ModuleTests/access/AccessTest.java b/jdk/test/java/lang/ModuleTests/access/AccessTest.java index 4bd3f2bf39b..eb600f93736 100644 --- a/jdk/test/java/lang/ModuleTests/access/AccessTest.java +++ b/jdk/test/java/lang/ModuleTests/access/AccessTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,7 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.List; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.executeTestJava; import org.testng.annotations.BeforeTest; @@ -34,9 +35,9 @@ import static org.testng.Assert.*; /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build AccessTest CompilerUtils jdk.testlibrary.* + * @build AccessTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng AccessTest * @summary Driver for test that checks access to access to types in * exported and non-exported packages. diff --git a/jdk/test/java/lang/ProcessHandle/Basic.java b/jdk/test/java/lang/ProcessHandle/Basic.java index 34e1021a340..09674814283 100644 --- a/jdk/test/java/lang/ProcessHandle/Basic.java +++ b/jdk/test/java/lang/ProcessHandle/Basic.java @@ -39,6 +39,12 @@ import org.testng.annotations.Test; * @library /test/lib * @modules java.base/jdk.internal.misc * jdk.management + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run testng Basic * @summary Basic tests for ProcessHandler * @author Roger Riggs diff --git a/jdk/test/java/lang/ProcessHandle/InfoTest.java b/jdk/test/java/lang/ProcessHandle/InfoTest.java index fbd855db91d..8f6201ff6bf 100644 --- a/jdk/test/java/lang/ProcessHandle/InfoTest.java +++ b/jdk/test/java/lang/ProcessHandle/InfoTest.java @@ -51,7 +51,12 @@ import org.testng.annotations.Test; * @library /test/lib * @modules java.base/jdk.internal.misc * jdk.management - * @build jdk.test.lib.Platform jdk.test.lib.Utils + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run testng InfoTest * @summary Functions of ProcessHandle.Info * @author Roger Riggs diff --git a/jdk/test/java/lang/ProcessHandle/OnExitTest.java b/jdk/test/java/lang/ProcessHandle/OnExitTest.java index 9bdc566fcb1..444143782e9 100644 --- a/jdk/test/java/lang/ProcessHandle/OnExitTest.java +++ b/jdk/test/java/lang/ProcessHandle/OnExitTest.java @@ -43,7 +43,12 @@ import org.testng.TestNG; * @library /test/lib * @modules java.base/jdk.internal.misc * jdk.management - * @build jdk.test.lib.Platform jdk.test.lib.Utils + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run testng OnExitTest * @summary Functions of Process.onExit and ProcessHandle.onExit * @author Roger Riggs diff --git a/jdk/test/java/lang/ProcessHandle/TreeTest.java b/jdk/test/java/lang/ProcessHandle/TreeTest.java index 8e3580a4a84..854734c1c86 100644 --- a/jdk/test/java/lang/ProcessHandle/TreeTest.java +++ b/jdk/test/java/lang/ProcessHandle/TreeTest.java @@ -48,6 +48,11 @@ import org.testng.annotations.Test; * @modules java.base/jdk.internal.misc * jdk.management * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run testng/othervm TreeTest * @summary Test counting and JavaChild.spawning and counting of Processes. * @author Roger Riggs diff --git a/jdk/test/java/lang/StackTraceElement/WithClassLoaderName.java b/jdk/test/java/lang/StackTraceElement/WithClassLoaderName.java index c58e9d6a326..58572496295 100644 --- a/jdk/test/java/lang/StackTraceElement/WithClassLoaderName.java +++ b/jdk/test/java/lang/StackTraceElement/WithClassLoaderName.java @@ -25,9 +25,10 @@ * @test * @bug 6479237 * @summary Basic test StackTraceElement with class loader names - * @library lib /lib/testlibrary + * @library lib /lib/testlibrary /test/lib * @modules jdk.compiler - * @build m1/* WithClassLoaderName + * @build jdk.test.lib.compiler.CompilerUtils + * m1/* WithClassLoaderName * @run main/othervm m1/com.app.Main * @run main/othervm WithClassLoaderName */ @@ -39,6 +40,8 @@ import java.net.URLClassLoader; import java.nio.file.Path; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; + import com.app.Utils; public class WithClassLoaderName { diff --git a/jdk/test/java/lang/StackWalker/StackWalkTest.java b/jdk/test/java/lang/StackWalker/StackWalkTest.java index 711bd4bd584..ad7a2c463ec 100644 --- a/jdk/test/java/lang/StackWalker/StackWalkTest.java +++ b/jdk/test/java/lang/StackWalker/StackWalkTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,14 +31,14 @@ import java.util.Random; import java.util.Set; import java.util.TreeSet; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * @test * @bug 8140450 * @summary Stack Walk Test (use -Dseed=X to set PRNG seed) - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @compile StackRecorderUtil.java * @run main/othervm StackWalkTest * @run main/othervm/java.security.policy=stackwalktest.policy StackWalkTest diff --git a/jdk/test/java/lang/StrictMath/CubeRootTests.java b/jdk/test/java/lang/StrictMath/CubeRootTests.java index afbdb4c7fb5..f4a3978075d 100644 --- a/jdk/test/java/lang/StrictMath/CubeRootTests.java +++ b/jdk/test/java/lang/StrictMath/CubeRootTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ * @test * @bug 4347132 8136799 * @key randomness - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @build Tests * @build FdlibmTranslit * @build CubeRootTests @@ -35,7 +35,7 @@ * @author Joseph D. Darcy */ -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * The tests in ../Math/CubeRootTests.java test properties that should diff --git a/jdk/test/java/lang/StrictMath/ExpTests.java b/jdk/test/java/lang/StrictMath/ExpTests.java index 0a2e1f0304d..9c4b9b20801 100644 --- a/jdk/test/java/lang/StrictMath/ExpTests.java +++ b/jdk/test/java/lang/StrictMath/ExpTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ * @test * @bug 8139688 * @key randomness - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @build Tests * @build FdlibmTranslit * @build ExpTests @@ -34,7 +34,7 @@ * @summary Tests specifically for StrictMath.exp */ -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * The role of this test is to verify that the FDLIBM exp algorithm is diff --git a/jdk/test/java/lang/StrictMath/HypotTests.java b/jdk/test/java/lang/StrictMath/HypotTests.java index 75524334539..0b1dd41691f 100644 --- a/jdk/test/java/lang/StrictMath/HypotTests.java +++ b/jdk/test/java/lang/StrictMath/HypotTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,8 +26,8 @@ * @bug 4851638 * @key randomness * @summary Tests for StrictMath.hypot - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @build Tests * @build FdlibmTranslit * @build HypotTests @@ -35,7 +35,7 @@ * @author Joseph D. Darcy */ -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * The tests in ../Math/HypotTests.java test properties that should diff --git a/jdk/test/java/lang/String/CompactString/SerializationTest.java b/jdk/test/java/lang/String/CompactString/SerializationTest.java index e4c94c573ba..3ef08924233 100644 --- a/jdk/test/java/lang/String/CompactString/SerializationTest.java +++ b/jdk/test/java/lang/String/CompactString/SerializationTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,14 +24,14 @@ import org.testng.annotations.DataProvider; import org.testng.annotations.Test; -import static jdk.testlibrary.SerializationUtils.*; +import static jdk.test.lib.util.SerializationUtils.*; import static org.testng.Assert.assertEquals; /* * @test * @bug 8077559 - * @library /lib/testlibrary - * @build jdk.testlibrary.SerializationUtils + * @library /test/lib + * @build jdk.test.lib.util.SerializationUtils * @summary Tests Compact String. This one is testing String serialization * among -XX:+CompactStrings/-XX:-CompactStrings/LegacyString * @run testng/othervm -XX:+CompactStrings SerializationTest diff --git a/jdk/test/java/lang/String/LiteralReplace.java b/jdk/test/java/lang/String/LiteralReplace.java index 32fc779408f..5e1638bcedf 100644 --- a/jdk/test/java/lang/String/LiteralReplace.java +++ b/jdk/test/java/lang/String/LiteralReplace.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* @test * @bug 8058779 8054307 - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run testng LiteralReplace * @summary Basic tests of String.replace(CharSequence, CharSequence) * @key randomness @@ -37,7 +37,7 @@ import java.util.regex.Matcher; import java.util.regex.Pattern; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; import org.testng.annotations.Test; import org.testng.annotations.DataProvider; diff --git a/jdk/test/java/lang/StringBuffer/CompactStringBufferSerialization.java b/jdk/test/java/lang/StringBuffer/CompactStringBufferSerialization.java index 346c824ed12..8e166a6b623 100644 --- a/jdk/test/java/lang/StringBuffer/CompactStringBufferSerialization.java +++ b/jdk/test/java/lang/StringBuffer/CompactStringBufferSerialization.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,14 +26,14 @@ import java.io.*; import org.testng.annotations.DataProvider; import org.testng.annotations.Test; -import static jdk.testlibrary.SerializationUtils.*; +import static jdk.test.lib.util.SerializationUtils.*; import static org.testng.Assert.*; /* * @test * @bug 8077559 - * @library /lib/testlibrary - * @build jdk.testlibrary.SerializationUtils + * @library /test/lib + * @build jdk.test.lib.util.SerializationUtils * @summary Tests Compact String. This one is testing StringBuffer serialization * among -XX:+CompactStrings/-XX:-CompactStrings/LegacyStringBuffer * @run testng/othervm -XX:+CompactStrings CompactStringBufferSerialization diff --git a/jdk/test/java/lang/StringBuilder/CompactStringBuilderSerialization.java b/jdk/test/java/lang/StringBuilder/CompactStringBuilderSerialization.java index 0c622d78665..931c71fd5d6 100644 --- a/jdk/test/java/lang/StringBuilder/CompactStringBuilderSerialization.java +++ b/jdk/test/java/lang/StringBuilder/CompactStringBuilderSerialization.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,14 +26,14 @@ import java.io.*; import org.testng.annotations.DataProvider; import org.testng.annotations.Test; -import static jdk.testlibrary.SerializationUtils.*; +import static jdk.test.lib.util.SerializationUtils.*; import static org.testng.Assert.*; /* * @test * @bug 8077559 - * @library /lib/testlibrary - * @build jdk.testlibrary.SerializationUtils + * @library /test/lib + * @build jdk.test.lib.util.SerializationUtils * @summary Tests Compact String. This one is testing StringBuilder serialization * among -XX:+CompactStrings/-XX:-CompactStrings/LegacyStringBuilder * @run testng/othervm -XX:+CompactStrings CompactStringBuilderSerialization diff --git a/jdk/test/java/lang/System/LoggerFinder/LoggerFinderAPI/LoggerFinderAPI.java b/jdk/test/java/lang/System/LoggerFinder/LoggerFinderAPI/LoggerFinderAPI.java index 3c8944e437a..998b1fc6759 100644 --- a/jdk/test/java/lang/System/LoggerFinder/LoggerFinderAPI/LoggerFinderAPI.java +++ b/jdk/test/java/lang/System/LoggerFinder/LoggerFinderAPI/LoggerFinderAPI.java @@ -28,17 +28,18 @@ import java.io.PrintStream; import java.lang.System.Logger; import java.lang.System.Logger.Level; import java.lang.System.LoggerFinder; +import java.util.Collections; import java.util.Enumeration; import java.util.Locale; +import java.util.Map; import java.util.Objects; import java.util.ResourceBundle; -import java.util.concurrent.ConcurrentHashMap; // Can't use testng because testng requires java.logging //import org.testng.annotations.Test; /** * @test - * @bug 8177835 + * @bug 8177835 8179222 * @summary Checks that the DefaultLoggerFinder and LoggingProviderImpl * implementations of the System.LoggerFinder conform to the * LoggerFinder specification, in particular with respect to @@ -60,6 +61,8 @@ public class LoggerFinderAPI { static final String JDK_FORMAT_PROP_KEY = "jdk.system.logger.format"; static final String JUL_FORMAT_PROP_KEY = "java.util.logging.SimpleFormatter.format"; + static final String MESSAGE = "{0} with {1}: PASSED"; + static final String LOCALIZED = "[localized] "; static class RecordStream extends OutputStream { static final Object LOCK = new Object[0]; @@ -106,15 +109,28 @@ public class LoggerFinderAPI { } public static class MyResourceBundle extends ResourceBundle { - final ConcurrentHashMap map = new ConcurrentHashMap<>(); + final Map map = Map.of(MESSAGE, LOCALIZED + MESSAGE); @Override protected Object handleGetObject(String string) { - return map.computeIfAbsent(string, s -> "[localized] " + s); + return map.get(string); } @Override public Enumeration getKeys() { - return map.keys(); + return Collections.enumeration(map.keySet()); + } + + } + + public static class EmptyResourceBundle extends ResourceBundle { + @Override + protected Object handleGetObject(String string) { + return null; + } + + @Override + public Enumeration getKeys() { + return Collections.emptyEnumeration(); } } @@ -129,17 +145,23 @@ public class LoggerFinderAPI { LoggerFinderAPI apiTest = new LoggerFinderAPI(); for (Object[] params : getLoggerDataProvider()) { + @SuppressWarnings("unchecked") + Class throwableClass = + Throwable.class.getClass().cast(params[3]); apiTest.testGetLogger((String)params[0], (String)params[1], (Module)params[2], - Throwable.class.getClass().cast(params[3])); + throwableClass); } for (Object[] params : getLocalizedLoggerDataProvider()) { + @SuppressWarnings("unchecked") + Class throwableClass = + Throwable.class.getClass().cast(params[4]); apiTest.testGetLocalizedLogger((String)params[0], (String)params[1], (ResourceBundle)params[2], (Module)params[3], - Throwable.class.getClass().cast(params[4])); + throwableClass); } } @@ -158,15 +180,16 @@ public class LoggerFinderAPI { // Make sure we don't fail if tests are run in parallel synchronized(RecordStream.LOCK) { LOG_STREAM.startRecording(); + byte[] logged = null; try { logger.log(Level.INFO, "{0} with {1}: PASSED", "LoggerFinder.getLogger", desc); } finally { - byte[] logged = LOG_STREAM.stopRecording(); - check(logged, "testGetLogger", desc, null, - "LoggerFinder.getLogger"); + logged = LOG_STREAM.stopRecording(); } + check(logged, "testGetLogger", desc, null, + "LoggerFinder.getLogger"); } } catch (Throwable x) { if (thrown != null && thrown.isInstance(x)) { @@ -192,15 +215,16 @@ public class LoggerFinderAPI { // Make sure we don't fail if tests are run in parallel synchronized(RecordStream.LOCK) { LOG_STREAM.startRecording(); + byte[] logged = null; try { - logger.log(Level.INFO, "{0} with {1}: PASSED", + logger.log(Level.INFO, MESSAGE, "LoggerFinder.getLocalizedLogger", desc); } finally { - byte[] logged = LOG_STREAM.stopRecording(); - check(logged, "testGetLocalizedLogger", desc, bundle, - "LoggerFinder.getLocalizedLogger"); + logged = LOG_STREAM.stopRecording(); } + check(logged, "testGetLocalizedLogger", desc, bundle, + "LoggerFinder.getLocalizedLogger"); } } catch (Throwable x) { if (thrown != null && thrown.isInstance(x)) { @@ -213,9 +237,11 @@ public class LoggerFinderAPI { private void check(byte[] logged, String test, String desc, ResourceBundle bundle, String meth) { String msg = new String(logged); + String localizedPrefix = + ((bundle==null || bundle==EMPTY_BUNDLE)?"":LOCALIZED); String expected = String.format(TEST_FORMAT, null, "LoggerFinderAPI " + test, null, Level.INFO.name(), - (bundle==null?"":"[localized] ") + meth + " with " + desc + ": PASSED", + localizedPrefix + meth + " with " + desc + ": PASSED", ""); if (!Objects.equals(msg, expected)) { throw new AssertionError("Expected log message not found: " @@ -227,6 +253,7 @@ public class LoggerFinderAPI { static final Module MODULE = LoggerFinderAPI.class.getModule(); static final ResourceBundle BUNDLE = new MyResourceBundle(); + static final ResourceBundle EMPTY_BUNDLE = new EmptyResourceBundle(); static final Object[][] GET_LOGGER = { {"null name", null, MODULE , NullPointerException.class}, {"null module", "foo", null, NullPointerException.class}, @@ -236,12 +263,15 @@ public class LoggerFinderAPI { static final Object[][] GET_LOCALIZED_LOGGER = { {"null name", null, BUNDLE, MODULE , NullPointerException.class}, {"null module", "foo", BUNDLE, null, NullPointerException.class}, - {"null name and module", null, BUNDLE, null, NullPointerException.class}, - {"non null name and module", "foo", BUNDLE, MODULE, null}, + {"null name and module, non null bundle", null, BUNDLE, null, NullPointerException.class}, + {"non null name, module, and bundle", "foo", BUNDLE, MODULE, null}, {"null name and bundle", null, null, MODULE , NullPointerException.class}, {"null module and bundle", "foo", null, null, NullPointerException.class}, {"null name and module and bundle", null, null, null, NullPointerException.class}, {"non null name and module, null bundle", "foo", null, MODULE, null}, + // tests that MissingResourceBundle is not propagated to the caller of + // logger.log() if the key is not found in the resource bundle + {"non null name, module, and empty bundle", "foo", EMPTY_BUNDLE, MODULE, null}, }; public static Object[][] getLoggerDataProvider() { return GET_LOGGER; diff --git a/jdk/test/java/lang/System/LoggerFinder/modules/Base.java b/jdk/test/java/lang/System/LoggerFinder/modules/Base.java index 62a0fa00620..912d0c21f21 100644 --- a/jdk/test/java/lang/System/LoggerFinder/modules/Base.java +++ b/jdk/test/java/lang/System/LoggerFinder/modules/Base.java @@ -33,6 +33,7 @@ import java.util.List; import java.util.stream.Stream; import jdk.testlibrary.JDKToolFinder; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.executeCommand; diff --git a/jdk/test/java/lang/System/LoggerFinder/modules/JDKLoggerForImageTest.java b/jdk/test/java/lang/System/LoggerFinder/modules/JDKLoggerForImageTest.java index 2e41d8e3843..3f2437b24f6 100644 --- a/jdk/test/java/lang/System/LoggerFinder/modules/JDKLoggerForImageTest.java +++ b/jdk/test/java/lang/System/LoggerFinder/modules/JDKLoggerForImageTest.java @@ -45,8 +45,8 @@ import static jdk.testlibrary.ProcessTools.executeCommand; * patched system module, or Xbootclasspath * This test does not require existence of java.logging module, * but require jdk.compiler module - * @library /lib/testlibrary - * @build Base CompilerUtils jdk.testlibrary.* + * @library /lib/testlibrary /test/lib + * @build Base jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run main/othervm JDKLoggerForImageTest */ diff --git a/jdk/test/java/lang/System/LoggerFinder/modules/JDKLoggerForJDKTest.java b/jdk/test/java/lang/System/LoggerFinder/modules/JDKLoggerForJDKTest.java index b9c8dbe46da..19e10e97d22 100644 --- a/jdk/test/java/lang/System/LoggerFinder/modules/JDKLoggerForJDKTest.java +++ b/jdk/test/java/lang/System/LoggerFinder/modules/JDKLoggerForJDKTest.java @@ -45,8 +45,8 @@ import static jdk.testlibrary.ProcessTools.executeCommand; * 2. clients are in named/unnamed module, * patched system module, or Xbootclasspath * This test DOES require existence of java.logging module - * @library /lib/testlibrary - * @build Base CompilerUtils jdk.testlibrary.* + * @library /lib/testlibrary /test/lib + * @build Base jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run main/othervm JDKLoggerForJDKTest */ diff --git a/jdk/test/java/lang/System/LoggerFinder/modules/LoggerInImageTest.java b/jdk/test/java/lang/System/LoggerFinder/modules/LoggerInImageTest.java index 2583b1a2744..804b1f3dcfb 100644 --- a/jdk/test/java/lang/System/LoggerFinder/modules/LoggerInImageTest.java +++ b/jdk/test/java/lang/System/LoggerFinder/modules/LoggerInImageTest.java @@ -45,8 +45,8 @@ import static jdk.testlibrary.ProcessTools.executeCommand; * patched system module, or Xbootclasspath * This test does not require existence of java.logging module, * but require jdk.compiler module - * @library /lib/testlibrary - * @build Base CompilerUtils jdk.testlibrary.* + * @library /lib/testlibrary /test/lib + * @build Base jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run main/othervm LoggerInImageTest */ diff --git a/jdk/test/java/lang/System/LoggerFinder/modules/NamedLoggerForImageTest.java b/jdk/test/java/lang/System/LoggerFinder/modules/NamedLoggerForImageTest.java index eda8b3c4628..ee6f62e377e 100644 --- a/jdk/test/java/lang/System/LoggerFinder/modules/NamedLoggerForImageTest.java +++ b/jdk/test/java/lang/System/LoggerFinder/modules/NamedLoggerForImageTest.java @@ -45,8 +45,8 @@ import static jdk.testlibrary.ProcessTools.executeCommand; * patched system module, or Xbootclasspath * This test does not require existence of java.logging module, * but require jdk.compiler module - * @library /lib/testlibrary - * @build Base CompilerUtils jdk.testlibrary.* + * @library /lib/testlibrary /test/lib + * @build Base jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run main/othervm NamedLoggerForImageTest */ diff --git a/jdk/test/java/lang/System/LoggerFinder/modules/NamedLoggerForJDKTest.java b/jdk/test/java/lang/System/LoggerFinder/modules/NamedLoggerForJDKTest.java index f6bebdce1b2..881aaa077ba 100644 --- a/jdk/test/java/lang/System/LoggerFinder/modules/NamedLoggerForJDKTest.java +++ b/jdk/test/java/lang/System/LoggerFinder/modules/NamedLoggerForJDKTest.java @@ -45,8 +45,8 @@ import static jdk.testlibrary.ProcessTools.executeCommand; * patched system module, or Xbootclasspath * This test does not require existence of java.logging module, * but require jdk.compiler module - * @library /lib/testlibrary - * @build Base CompilerUtils jdk.testlibrary.* + * @library /lib/testlibrary /test/lib + * @build Base jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run main/othervm NamedLoggerForJDKTest */ diff --git a/jdk/test/java/lang/System/LoggerFinder/modules/UnnamedLoggerForImageTest.java b/jdk/test/java/lang/System/LoggerFinder/modules/UnnamedLoggerForImageTest.java index 936fe6aaaa6..9b9878d5e46 100644 --- a/jdk/test/java/lang/System/LoggerFinder/modules/UnnamedLoggerForImageTest.java +++ b/jdk/test/java/lang/System/LoggerFinder/modules/UnnamedLoggerForImageTest.java @@ -45,8 +45,8 @@ import static jdk.testlibrary.ProcessTools.executeCommand; * patched system module, or Xbootclasspath * This test does not require existence of java.logging module, * but require jdk.compiler module - * @library /lib/testlibrary - * @build Base CompilerUtils jdk.testlibrary.* + * @library /lib/testlibrary /test/lib + * @build Base jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run main/othervm UnnamedLoggerForImageTest */ diff --git a/jdk/test/java/lang/System/LoggerFinder/modules/UnnamedLoggerForJDKTest.java b/jdk/test/java/lang/System/LoggerFinder/modules/UnnamedLoggerForJDKTest.java index 2049e3732bd..e5cf8751f67 100644 --- a/jdk/test/java/lang/System/LoggerFinder/modules/UnnamedLoggerForJDKTest.java +++ b/jdk/test/java/lang/System/LoggerFinder/modules/UnnamedLoggerForJDKTest.java @@ -45,8 +45,8 @@ import static jdk.testlibrary.ProcessTools.executeCommand; * patched system module, or Xbootclasspath * This test does not require existence of java.logging module, * but require jdk.compiler module - * @library /lib/testlibrary - * @build Base CompilerUtils jdk.testlibrary.* + * @library /lib/testlibrary /test/lib + * @build Base jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run main/othervm UnnamedLoggerForJDKTest */ diff --git a/jdk/test/java/lang/Thread/ThreadStateController.java b/jdk/test/java/lang/Thread/ThreadStateController.java index c426d1b34b4..d644a1a9ece 100644 --- a/jdk/test/java/lang/Thread/ThreadStateController.java +++ b/jdk/test/java/lang/Thread/ThreadStateController.java @@ -27,7 +27,7 @@ import java.util.concurrent.TimeoutException; import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.locks.LockSupport; -import jdk.testlibrary.LockFreeLogManager; +import jdk.test.lib.LockFreeLogger; import jdk.testlibrary.Utils; /** @@ -100,7 +100,7 @@ public class ThreadStateController extends Thread { private final AtomicInteger iterations = new AtomicInteger(); private final AtomicInteger interrupted = new AtomicInteger(); - private final LockFreeLogManager logManager = new LockFreeLogManager(); + private final LockFreeLogger logger = new LockFreeLogger(); @Override public void run() { @@ -349,7 +349,7 @@ public class ThreadStateController extends Thread { } private void log(String msg, Object ... params) { - logManager.log(msg, params); + logger.log(msg, params); } /** @@ -361,6 +361,6 @@ public class ThreadStateController extends Thread { public String getLog() throws InterruptedException { this.join(); - return logManager.toString(); + return logger.toString(); } } diff --git a/jdk/test/java/lang/Thread/ThreadStateTest.java b/jdk/test/java/lang/Thread/ThreadStateTest.java index 843cfd7ddeb..1377c550226 100644 --- a/jdk/test/java/lang/Thread/ThreadStateTest.java +++ b/jdk/test/java/lang/Thread/ThreadStateTest.java @@ -31,7 +31,9 @@ import static java.lang.Thread.State.*; * * @author Mandy Chung * @library /lib/testlibrary + * @library /test/lib * @build jdk.testlibrary.* + * @build jdk.test.lib.LockFreeLogger * @build ThreadStateTest ThreadStateController * @run main/othervm -Xmixed ThreadStateTest */ diff --git a/jdk/test/java/lang/annotation/AnnotationType/AnnotationTypeRuntimeAssumptionTest.java b/jdk/test/java/lang/annotation/AnnotationType/AnnotationTypeRuntimeAssumptionTest.java index 32589256c59..fc45bef98f9 100644 --- a/jdk/test/java/lang/annotation/AnnotationType/AnnotationTypeRuntimeAssumptionTest.java +++ b/jdk/test/java/lang/annotation/AnnotationType/AnnotationTypeRuntimeAssumptionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ * @test * @summary Test consistent parsing of ex-RUNTIME annotations that * were changed and separately compiled to have CLASS retention - * @library /lib/testlibrary - * @build jdk.testlibrary.IOUtils * @run main AnnotationTypeRuntimeAssumptionTest */ @@ -35,8 +33,6 @@ import java.io.InputStream; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; -import jdk.testlibrary.IOUtils; - import static java.lang.annotation.RetentionPolicy.CLASS; import static java.lang.annotation.RetentionPolicy.RUNTIME; @@ -140,7 +136,7 @@ public class AnnotationTypeRuntimeAssumptionTest { String altPath = altName.replace('.', '/').concat(".class"); try (InputStream is = getResourceAsStream(altPath)) { if (is != null) { - byte[] bytes = IOUtils.readFully(is); + byte[] bytes = is.readAllBytes(); // patch class bytes to contain original name for (int i = 0; i < bytes.length - 2; i++) { if (bytes[i] == '_' && @@ -163,7 +159,7 @@ public class AnnotationTypeRuntimeAssumptionTest { String path = name.replace('.', '/').concat(".class"); try (InputStream is = getResourceAsStream(path)) { if (is != null) { - byte[] bytes = IOUtils.readFully(is); + byte[] bytes = is.readAllBytes(); return defineClass(name, bytes, 0, bytes.length); } else { diff --git a/jdk/test/java/lang/invoke/ExplicitCastArgumentsTest.java b/jdk/test/java/lang/invoke/ExplicitCastArgumentsTest.java index 347e312e3b2..8e789b75def 100644 --- a/jdk/test/java/lang/invoke/ExplicitCastArgumentsTest.java +++ b/jdk/test/java/lang/invoke/ExplicitCastArgumentsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,9 @@ * questions. */ -import com.oracle.testlibrary.jsr292.Helper; +import sun.invoke.util.Wrapper; +import test.java.lang.invoke.lib.Helper; + import java.io.File; import java.io.Serializable; import java.lang.invoke.MethodHandle; @@ -31,13 +33,12 @@ import java.lang.invoke.WrongMethodTypeException; import java.util.HashMap; import java.util.Map; import java.util.Random; -import sun.invoke.util.Wrapper; /* * @test * @bug 8060483 8066746 * @key randomness - * @library /lib/testlibrary /lib/testlibrary/jsr292 + * @library /lib/testlibrary /java/lang/invoke/common * @modules java.base/sun.invoke.util * @summary unit tests for MethodHandles.explicitCastArguments() * @run main ExplicitCastArgumentsTest @@ -249,21 +250,27 @@ public class ExplicitCastArgumentsTest { for (Class parent : parents) { for (int j = 0; j < children.length; j++) { // Child type to parent type non-null conversion, shoud succeed - testConversion(mode, children[j], parent, childInst[j], childInst[j], false, null); + testConversion(mode, children[j], parent, childInst[j], + childInst[j], false, null); // Child type to parent type null conversion, shoud succeed - testConversion(mode, children[j], parent, null, null, false, null); + testConversion(mode, children[j], parent, null, + null, false, null); // Parent type to child type non-null conversion with parent // type instance, should fail - testConversion(mode, parent, children[j], testSuperObj, null, true, ClassCastException.class); + testConversion(mode, parent, children[j], testSuperObj, + null, true, ClassCastException.class); // Parent type to child type non-null conversion with child // type instance, should succeed - testConversion(mode, parent, children[j], childInst[j], childInst[j], false, null); + testConversion(mode, parent, children[j], childInst[j], + childInst[j], false, null); // Parent type to child type null conversion, should succeed - testConversion(mode, parent, children[j], null, null, false, null); + testConversion(mode, parent, children[j], null, + null, false, null); } // Parent type to child type non-null conversion with sibling // type instance, should fail - testConversion(mode, parent, testSubClass1, testObj02, null, true, ClassCastException.class); + testConversion(mode, parent, testSubClass1, testObj02, + null, true, ClassCastException.class); } // Sibling type non-null conversion, should fail testConversion(mode, testSubClass1, diff --git a/jdk/test/java/lang/invoke/LFCaching/LFGarbageCollectedTest.java b/jdk/test/java/lang/invoke/LFCaching/LFGarbageCollectedTest.java index b6964c392a7..91be7bdb253 100644 --- a/jdk/test/java/lang/invoke/LFCaching/LFGarbageCollectedTest.java +++ b/jdk/test/java/lang/invoke/LFCaching/LFGarbageCollectedTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,11 +28,16 @@ * @ignore 8078602 * @summary Test verifies that lambda forms are garbage collected * @author kshefov - * @library /lib/testlibrary/jsr292 /lib/testlibrary + * @library /lib/testlibrary /java/lang/invoke/common + * @build jdk.test.lib.TimeLimitedRunner * @build TestMethods * @build LambdaFormTestCase * @build LFGarbageCollectedTest - * @run main/othervm -Xmx64m -XX:SoftRefLRUPolicyMSPerMB=0 -XX:+HeapDumpOnOutOfMemoryError -DHEAP_DUMP=false LFGarbageCollectedTest + * @run main/othervm -Xmx64m + * -XX:SoftRefLRUPolicyMSPerMB=0 + * -XX:+HeapDumpOnOutOfMemoryError + * -DHEAP_DUMP=false + * LFGarbageCollectedTest */ import java.lang.invoke.MethodHandle; @@ -82,9 +87,9 @@ public final class LFGarbageCollectedTest extends LambdaFormTestCase { throw new Error("Unexpected error: Lambda form of the method handle is null"); } - String debugName = (String)DEBUG_NAME.get(lambdaForm); - if (debugName != null && debugName.startsWith("identity_")) { - // Ignore identity_* LambdaForms. + String kind = KIND_FIELD.get(lambdaForm).toString(); + if (kind.equals("IDENTITY")) { + // Ignore identity LambdaForms. return; } diff --git a/jdk/test/java/lang/invoke/LFCaching/LFMultiThreadCachingTest.java b/jdk/test/java/lang/invoke/LFCaching/LFMultiThreadCachingTest.java index 84e1dd54ffe..bd9ace8ccbe 100644 --- a/jdk/test/java/lang/invoke/LFCaching/LFMultiThreadCachingTest.java +++ b/jdk/test/java/lang/invoke/LFCaching/LFMultiThreadCachingTest.java @@ -27,10 +27,11 @@ * @key randomness * @summary Test verifies that lambda forms are cached when run with multiple threads * @author kshefov - * @library /lib/testlibrary/jsr292 /lib/testlibrary + * @library /lib/testlibrary /java/lang/invoke/common /test/lib * @modules java.base/java.lang.invoke:open * java.base/java.lang.ref:open * java.management + * @build jdk.test.lib.TimeLimitedRunner * @build TestMethods * @build LambdaFormTestCase * @build LFCachingTestCase @@ -38,16 +39,16 @@ * @run main/othervm LFMultiThreadCachingTest */ +import test.java.lang.invoke.lib.CodeCacheOverflowProcessor; + import java.lang.invoke.MethodHandle; import java.util.Collections; import java.util.EnumSet; import java.util.HashMap; import java.util.Map; -import java.util.concurrent.BrokenBarrierException; import java.util.concurrent.ConcurrentLinkedQueue; import java.util.concurrent.CountDownLatch; import java.util.concurrent.CyclicBarrier; -import com.oracle.testlibrary.jsr292.CodeCacheOverflowProcessor; /** * Multiple threaded lambda forms caching test class. @@ -57,13 +58,16 @@ public final class LFMultiThreadCachingTest extends LFCachingTestCase { private static final TestMethods.Kind[] KINDS; static { - EnumSet set = EnumSet.complementOf(EnumSet.of(TestMethods.Kind.EXCEPT)); + EnumSet set + = EnumSet.complementOf(EnumSet.of(TestMethods.Kind.EXCEPT)); KINDS = set.toArray(new TestMethods.Kind[set.size()]); if (KINDS.length < 2) { - throw new Error("TESTBUG: KINDS.length[" + KINDS.length + "] should be at least 2"); + throw new Error("TESTBUG: KINDS.length[" + KINDS.length + + "] should be at least 2"); } } - private static final int CORES = Math.max(KINDS.length, Runtime.getRuntime().availableProcessors()); + private static final int CORES + = Math.max(KINDS.length, Runtime.getRuntime().availableProcessors()); /** * Constructor a for multiple threaded lambda forms caching test case. @@ -144,6 +148,7 @@ public final class LFMultiThreadCachingTest extends LFCachingTestCase { * @param args Accepts no arguments. */ public static void main(String[] args) { - LambdaFormTestCase.runTests(LFMultiThreadCachingTest::new, EnumSet.allOf(TestMethods.class)); + LambdaFormTestCase.runTests(LFMultiThreadCachingTest::new, + EnumSet.allOf(TestMethods.class)); } } diff --git a/jdk/test/java/lang/invoke/LFCaching/LFSingleThreadCachingTest.java b/jdk/test/java/lang/invoke/LFCaching/LFSingleThreadCachingTest.java index bc674b0dbd2..5427fba792e 100644 --- a/jdk/test/java/lang/invoke/LFCaching/LFSingleThreadCachingTest.java +++ b/jdk/test/java/lang/invoke/LFCaching/LFSingleThreadCachingTest.java @@ -27,10 +27,11 @@ * @key randomness * @summary Test verifies that lambda forms are cached when run with single thread * @author kshefov - * @library /lib/testlibrary/jsr292 /lib/testlibrary + * @library /lib/testlibrary /java/lang/invoke/common /test/lib * @modules java.base/java.lang.ref:open * java.base/java.lang.invoke:open * java.management + * @build jdk.test.lib.TimeLimitedRunner * @build TestMethods * @build LambdaFormTestCase * @build LFCachingTestCase @@ -77,6 +78,7 @@ public final class LFSingleThreadCachingTest extends LFCachingTestCase { * @param args Accepts no arguments. */ public static void main(String[] args) { - LambdaFormTestCase.runTests(LFSingleThreadCachingTest::new, EnumSet.allOf(TestMethods.class)); + LambdaFormTestCase.runTests(LFSingleThreadCachingTest::new, + EnumSet.allOf(TestMethods.class)); } } diff --git a/jdk/test/java/lang/invoke/LFCaching/LambdaFormTestCase.java b/jdk/test/java/lang/invoke/LFCaching/LambdaFormTestCase.java index 42f6aefbfe7..1bce3484110 100644 --- a/jdk/test/java/lang/invoke/LFCaching/LambdaFormTestCase.java +++ b/jdk/test/java/lang/invoke/LFCaching/LambdaFormTestCase.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,8 +21,11 @@ * questions. */ -import com.oracle.testlibrary.jsr292.Helper; -import com.oracle.testlibrary.jsr292.CodeCacheOverflowProcessor; +import jdk.test.lib.TimeLimitedRunner; +import jdk.testlibrary.Utils; +import test.java.lang.invoke.lib.CodeCacheOverflowProcessor; +import test.java.lang.invoke.lib.Helper; + import java.lang.invoke.MethodHandle; import java.lang.management.GarbageCollectorMXBean; import java.lang.management.ManagementFactory; @@ -32,8 +35,6 @@ import java.lang.reflect.Method; import java.util.Collection; import java.util.List; import java.util.function.Function; -import jdk.testlibrary.Utils; -import jdk.testlibrary.TimeLimitedRunner; /** * Lambda forms caching test case class. Contains all necessary test routines to @@ -44,14 +45,15 @@ import jdk.testlibrary.TimeLimitedRunner; */ public abstract class LambdaFormTestCase { - private static final long TIMEOUT = Helper.IS_THOROUGH ? 0L : (long) (Utils.adjustTimeout(Utils.DEFAULT_TEST_TIMEOUT) * 0.9); + private static final long TIMEOUT = Helper.IS_THOROUGH ? + 0L : (long) (Utils.adjustTimeout(Utils.DEFAULT_TEST_TIMEOUT) * 0.9); /** * Reflection link to {@code j.l.i.MethodHandle.internalForm} method. It is * used to get a lambda form from a method handle. */ protected static final Method INTERNAL_FORM; - protected static final Field DEBUG_NAME; + protected static final Field KIND_FIELD; protected static final Field REF_FIELD; private static final List gcInfo; @@ -64,8 +66,8 @@ public abstract class LambdaFormTestCase { INTERNAL_FORM = MethodHandle.class.getDeclaredMethod("internalForm"); INTERNAL_FORM.setAccessible(true); - DEBUG_NAME = Class.forName("java.lang.invoke.LambdaForm").getDeclaredField("debugName"); - DEBUG_NAME.setAccessible(true); + KIND_FIELD = Class.forName("java.lang.invoke.LambdaForm").getDeclaredField("kind"); + KIND_FIELD.setAccessible(true); REF_FIELD = Reference.class.getDeclaredField("referent"); REF_FIELD.setAccessible(true); @@ -92,7 +94,8 @@ public abstract class LambdaFormTestCase { long failCounter; boolean passed; - TestRun(Function ctor, Collection testMethods) { + TestRun(Function ctor, + Collection testMethods) { this.ctor = ctor; this.testMethods = testMethods; long testCaseNum = testMethods.size(); @@ -175,10 +178,12 @@ public abstract class LambdaFormTestCase { * object. * @param testMethods list of test methods */ - public static void runTests(Function ctor, Collection testMethods) { + public static void runTests(Function ctor, + Collection testMethods) { LambdaFormTestCase.TestRun run = new LambdaFormTestCase.TestRun(ctor, testMethods); - TimeLimitedRunner runner = new TimeLimitedRunner(TIMEOUT, 4.0d, run::doIteration); + TimeLimitedRunner runner + = new TimeLimitedRunner(TIMEOUT, 4.0d, run::doIteration); try { runner.call(); } catch (Exception ex) { diff --git a/jdk/test/java/lang/invoke/LFCaching/TestMethods.java b/jdk/test/java/lang/invoke/LFCaching/TestMethods.java index fe63b252d5d..b99f80f5191 100644 --- a/jdk/test/java/lang/invoke/LFCaching/TestMethods.java +++ b/jdk/test/java/lang/invoke/LFCaching/TestMethods.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,8 @@ * questions. */ -import com.oracle.testlibrary.jsr292.Helper; +import test.java.lang.invoke.lib.Helper; + import java.lang.invoke.MethodHandle; import java.lang.invoke.MethodHandles; import java.lang.invoke.MethodType; @@ -41,462 +42,472 @@ import java.util.Map; public enum TestMethods { FOLD_ARGUMENTS("foldArguments") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int modifierMHArgNum = Helper.RNG.nextInt(realArity + 1); - data.put("modifierMHArgNum", modifierMHArgNum); - Class combinerReturnType; - if (realArity == 0) { - combinerReturnType = void.class; - } else { - combinerReturnType = Helper.RNG.nextBoolean() ? void.class : mtTarget.parameterType(0); - } - data.put("combinerReturnType", combinerReturnType); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int modifierMHArgNum = Helper.RNG.nextInt(realArity + 1); + data.put("modifierMHArgNum", modifierMHArgNum); + Class combinerReturnType; + if (realArity == 0) { + combinerReturnType = void.class; + } else { + combinerReturnType = Helper.RNG.nextBoolean() ? + void.class : mtTarget.parameterType(0); + } + data.put("combinerReturnType", combinerReturnType); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - Class combinerReturnType = (Class) data.get("combinerReturnType"); - int modifierMHArgNum = (int) data.get("modifierMHArgNum"); - MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), kind); - Class rType = mtTarget.returnType(); - int combListStart = (combinerReturnType == void.class) ? 0 : 1; - if (modifierMHArgNum < combListStart) { - modifierMHArgNum = combListStart; - } - MethodHandle combiner = TestMethods.methodHandleGenerator(combinerReturnType, - mtTarget.parameterList().subList(combListStart, - modifierMHArgNum), kind); - return MethodHandles.foldArguments(target, combiner); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + Class combinerReturnType = (Class) data.get("combinerReturnType"); + int modifierMHArgNum = (int) data.get("modifierMHArgNum"); + MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), kind); + Class rType = mtTarget.returnType(); + int combListStart = (combinerReturnType == void.class) ? 0 : 1; + if (modifierMHArgNum < combListStart) { + modifierMHArgNum = combListStart; + } + MethodHandle combiner = TestMethods.methodHandleGenerator(combinerReturnType, + mtTarget.parameterList().subList(combListStart, + modifierMHArgNum), kind); + return MethodHandles.foldArguments(target, combiner); + } + }, DROP_ARGUMENTS("dropArguments") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int dropArgsPos = Helper.RNG.nextInt(realArity + 1); - data.put("dropArgsPos", dropArgsPos); - MethodType mtDropArgs = TestMethods.randomMethodTypeGenerator( - Helper.RNG.nextInt(super.maxArity - realArity)); - data.put("mtDropArgs", mtDropArgs); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int dropArgsPos = Helper.RNG.nextInt(realArity + 1); + data.put("dropArgsPos", dropArgsPos); + MethodType mtDropArgs = TestMethods.randomMethodTypeGenerator( + Helper.RNG.nextInt(super.maxArity - realArity)); + data.put("mtDropArgs", mtDropArgs); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - MethodType mtDropArgs = (MethodType) data.get("mtDropArgs"); - int dropArgsPos = (int) data.get("dropArgsPos"); - MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), kind); - int mtTgtSlotsCount = TestMethods.argSlotsCount(mtTarget); - int mtDASlotsCount = TestMethods.argSlotsCount(mtDropArgs); - List> fakeParList; - if (mtTgtSlotsCount + mtDASlotsCount > super.maxArity - 1) { - fakeParList = TestMethods.reduceArgListToSlotsCount(mtDropArgs.parameterList(), - super.maxArity - mtTgtSlotsCount - 1); - } else { - fakeParList = mtDropArgs.parameterList(); - } - return MethodHandles.dropArguments(target, dropArgsPos, fakeParList); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + MethodType mtDropArgs = (MethodType) data.get("mtDropArgs"); + int dropArgsPos = (int) data.get("dropArgsPos"); + MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), kind); + int mtTgtSlotsCount = TestMethods.argSlotsCount(mtTarget); + int mtDASlotsCount = TestMethods.argSlotsCount(mtDropArgs); + List> fakeParList; + if (mtTgtSlotsCount + mtDASlotsCount > super.maxArity - 1) { + fakeParList = TestMethods.reduceArgListToSlotsCount(mtDropArgs.parameterList(), + super.maxArity - mtTgtSlotsCount - 1); + } else { + fakeParList = mtDropArgs.parameterList(); + } + return MethodHandles.dropArguments(target, dropArgsPos, fakeParList); + } + }, EXPLICIT_CAST_ARGUMENTS("explicitCastArguments", Helper.MAX_ARITY / 2) { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - MethodType mtExcplCastArgs = TestMethods.randomMethodTypeGenerator(realArity); - if (mtTarget.returnType() == void.class) { - mtExcplCastArgs = MethodType.methodType(void.class, - mtExcplCastArgs.parameterArray()); - } - if (mtExcplCastArgs.returnType() == void.class) { - mtExcplCastArgs = MethodType.methodType(mtTarget.returnType(), - mtExcplCastArgs.parameterArray()); - } - data.put("mtExcplCastArgs", mtExcplCastArgs); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + MethodType mtExcplCastArgs = TestMethods.randomMethodTypeGenerator(realArity); + if (mtTarget.returnType() == void.class) { + mtExcplCastArgs = MethodType.methodType(void.class, + mtExcplCastArgs.parameterArray()); + } + if (mtExcplCastArgs.returnType() == void.class) { + mtExcplCastArgs = MethodType.methodType(mtTarget.returnType(), + mtExcplCastArgs.parameterArray()); + } + data.put("mtExcplCastArgs", mtExcplCastArgs); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - MethodType mtExcplCastArgs = (MethodType) data.get("mtExcplCastArgs"); - MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), kind); - return MethodHandles.explicitCastArguments(target, mtExcplCastArgs); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + MethodType mtExcplCastArgs = (MethodType) data.get("mtExcplCastArgs"); + MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), kind); + return MethodHandles.explicitCastArguments(target, mtExcplCastArgs); + } + }, FILTER_ARGUMENTS("filterArguments", Helper.MAX_ARITY / 2) { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int filterArgsPos = Helper.RNG.nextInt(realArity + 1); - data.put("filterArgsPos", filterArgsPos); - int filtersArgsArrayLength = Helper.RNG.nextInt(realArity + 1 - filterArgsPos); - data.put("filtersArgsArrayLength", filtersArgsArrayLength); - MethodType mtFilter = TestMethods.randomMethodTypeGenerator(filtersArgsArrayLength); - data.put("mtFilter", mtFilter); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int filterArgsPos = Helper.RNG.nextInt(realArity + 1); + data.put("filterArgsPos", filterArgsPos); + int filtersArgsArrayLength = Helper.RNG.nextInt(realArity + 1 - filterArgsPos); + data.put("filtersArgsArrayLength", filtersArgsArrayLength); + MethodType mtFilter = TestMethods.randomMethodTypeGenerator(filtersArgsArrayLength); + data.put("mtFilter", mtFilter); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - MethodType mtFilter = (MethodType) data.get("mtFilter"); - int filterArgsPos = (int) data.get("filterArgsPos"); - int filtersArgsArrayLength = (int) data.get("filtersArgsArrayLength"); - MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), kind); - MethodHandle[] filters = new MethodHandle[filtersArgsArrayLength]; - for (int i = 0; i < filtersArgsArrayLength; i++) { - filters[i] = TestMethods.filterGenerator(mtFilter.parameterType(i), - mtTarget.parameterType(filterArgsPos + i), kind); - } - return MethodHandles.filterArguments(target, filterArgsPos, filters); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + MethodType mtFilter = (MethodType) data.get("mtFilter"); + int filterArgsPos = (int) data.get("filterArgsPos"); + int filtersArgsArrayLength = (int) data.get("filtersArgsArrayLength"); + MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), kind); + MethodHandle[] filters = new MethodHandle[filtersArgsArrayLength]; + for (int i = 0; i < filtersArgsArrayLength; i++) { + filters[i] = TestMethods.filterGenerator(mtFilter.parameterType(i), + mtTarget.parameterType(filterArgsPos + i), kind); + } + return MethodHandles.filterArguments(target, filterArgsPos, filters); + } + }, FILTER_RETURN_VALUE("filterReturnValue") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int filterArgsPos = Helper.RNG.nextInt(realArity + 1); - int filtersArgsArrayLength = Helper.RNG.nextInt(realArity + 1 - filterArgsPos); - MethodType mtFilter = TestMethods.randomMethodTypeGenerator(filtersArgsArrayLength); - data.put("mtFilter", mtFilter); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int filterArgsPos = Helper.RNG.nextInt(realArity + 1); + int filtersArgsArrayLength = Helper.RNG.nextInt(realArity + 1 - filterArgsPos); + MethodType mtFilter = TestMethods.randomMethodTypeGenerator(filtersArgsArrayLength); + data.put("mtFilter", mtFilter); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - MethodType mtFilter = (MethodType) data.get("mtFilter"); - MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), kind); - MethodHandle filter = TestMethods.filterGenerator(mtTarget.returnType(), - mtFilter.returnType(), kind); - return MethodHandles.filterReturnValue(target, filter); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + MethodType mtFilter = (MethodType) data.get("mtFilter"); + MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), kind); + MethodHandle filter = TestMethods.filterGenerator(mtTarget.returnType(), + mtFilter.returnType(), kind); + return MethodHandles.filterReturnValue(target, filter); + } + }, INSERT_ARGUMENTS("insertArguments", Helper.MAX_ARITY - 3) { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int insertArgsPos = Helper.RNG.nextInt(realArity + 1); - data.put("insertArgsPos", insertArgsPos); - int insertArgsArrayLength = Helper.RNG.nextInt(realArity + 1 - insertArgsPos); - MethodType mtInsertArgs = MethodType.methodType(void.class, mtTarget.parameterList() - .subList(insertArgsPos, insertArgsPos + insertArgsArrayLength)); - data.put("mtInsertArgs", mtInsertArgs); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int insertArgsPos = Helper.RNG.nextInt(realArity + 1); + data.put("insertArgsPos", insertArgsPos); + int insertArgsArrayLength = Helper.RNG.nextInt(realArity + 1 - insertArgsPos); + MethodType mtInsertArgs = MethodType.methodType(void.class, mtTarget.parameterList() + .subList(insertArgsPos, insertArgsPos + insertArgsArrayLength)); + data.put("mtInsertArgs", mtInsertArgs); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - MethodType mtInsertArgs = (MethodType) data.get("mtInsertArgs"); - int insertArgsPos = (int) data.get("insertArgsPos"); - MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), kind); - Object[] insertList = Helper.randomArgs(mtInsertArgs.parameterList()); - return MethodHandles.insertArguments(target, insertArgsPos, insertList); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + MethodType mtInsertArgs = (MethodType) data.get("mtInsertArgs"); + int insertArgsPos = (int) data.get("insertArgsPos"); + MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), kind); + Object[] insertList = Helper.randomArgs(mtInsertArgs.parameterList()); + return MethodHandles.insertArguments(target, insertArgsPos, insertList); + } + }, PERMUTE_ARGUMENTS("permuteArguments", Helper.MAX_ARITY / 2) { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int[] permuteArgsReorderArray = new int[realArity]; - int mtPermuteArgsNum = Helper.RNG.nextInt(Helper.MAX_ARITY); - mtPermuteArgsNum = mtPermuteArgsNum == 0 ? 1 : mtPermuteArgsNum; - MethodType mtPermuteArgs = TestMethods.randomMethodTypeGenerator(mtPermuteArgsNum); - mtTarget = mtTarget.changeReturnType(mtPermuteArgs.returnType()); - for (int i = 0; i < realArity; i++) { - int mtPermuteArgsParNum = Helper.RNG.nextInt(mtPermuteArgs.parameterCount()); - permuteArgsReorderArray[i] = mtPermuteArgsParNum; - mtTarget = mtTarget.changeParameterType( - i, mtPermuteArgs.parameterType(mtPermuteArgsParNum)); - } - data.put("mtTarget", mtTarget); - data.put("permuteArgsReorderArray", permuteArgsReorderArray); - data.put("mtPermuteArgs", mtPermuteArgs); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int[] permuteArgsReorderArray = new int[realArity]; + int mtPermuteArgsNum = Helper.RNG.nextInt(Helper.MAX_ARITY); + mtPermuteArgsNum = mtPermuteArgsNum == 0 ? 1 : mtPermuteArgsNum; + MethodType mtPermuteArgs = TestMethods.randomMethodTypeGenerator(mtPermuteArgsNum); + mtTarget = mtTarget.changeReturnType(mtPermuteArgs.returnType()); + for (int i = 0; i < realArity; i++) { + int mtPermuteArgsParNum = Helper.RNG.nextInt(mtPermuteArgs.parameterCount()); + permuteArgsReorderArray[i] = mtPermuteArgsParNum; + mtTarget = mtTarget.changeParameterType( + i, mtPermuteArgs.parameterType(mtPermuteArgsParNum)); + } + data.put("mtTarget", mtTarget); + data.put("permuteArgsReorderArray", permuteArgsReorderArray); + data.put("mtPermuteArgs", mtPermuteArgs); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - MethodType mtPermuteArgs = (MethodType) data.get("mtPermuteArgs"); - int[] permuteArgsReorderArray = (int[]) data.get("permuteArgsReorderArray"); - MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), kind); - return MethodHandles.permuteArguments(target, mtPermuteArgs, permuteArgsReorderArray); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + MethodType mtPermuteArgs = (MethodType) data.get("mtPermuteArgs"); + int[] permuteArgsReorderArray = (int[]) data.get("permuteArgsReorderArray"); + MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), kind); + return MethodHandles.permuteArguments(target, mtPermuteArgs, permuteArgsReorderArray); + } + }, THROW_EXCEPTION("throwException") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - Class rType = mtTarget.returnType(); - return MethodHandles.throwException(rType, Exception.class - ); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + Class rType = mtTarget.returnType(); + return MethodHandles.throwException(rType, Exception.class + ); + } + }, GUARD_WITH_TEST("guardWithTest") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int modifierMHArgNum = Helper.RNG.nextInt(realArity + 1); - data.put("modifierMHArgNum", modifierMHArgNum); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int modifierMHArgNum = Helper.RNG.nextInt(realArity + 1); + data.put("modifierMHArgNum", modifierMHArgNum); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - int modifierMHArgNum = (int) data.get("modifierMHArgNum"); - TestMethods.Kind targetKind; - TestMethods.Kind fallbackKind; - if (kind.equals(TestMethods.Kind.ONE)) { - targetKind = TestMethods.Kind.ONE; - fallbackKind = TestMethods.Kind.TWO; - } else { - targetKind = TestMethods.Kind.TWO; - fallbackKind = TestMethods.Kind.ONE; - } - MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), targetKind); - MethodHandle fallback = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), fallbackKind); - MethodHandle test = TestMethods.methodHandleGenerator(boolean.class, - mtTarget.parameterList().subList(0, modifierMHArgNum), kind); - return MethodHandles.guardWithTest(test, target, fallback); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + int modifierMHArgNum = (int) data.get("modifierMHArgNum"); + TestMethods.Kind targetKind; + TestMethods.Kind fallbackKind; + if (kind.equals(TestMethods.Kind.ONE)) { + targetKind = TestMethods.Kind.ONE; + fallbackKind = TestMethods.Kind.TWO; + } else { + targetKind = TestMethods.Kind.TWO; + fallbackKind = TestMethods.Kind.ONE; + } + MethodHandle target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), targetKind); + MethodHandle fallback = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), fallbackKind); + MethodHandle test = TestMethods.methodHandleGenerator(boolean.class, + mtTarget.parameterList().subList(0, modifierMHArgNum), kind); + return MethodHandles.guardWithTest(test, target, fallback); + } + }, CATCH_EXCEPTION("catchException") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int modifierMHArgNum = Helper.RNG.nextInt(realArity + 1); - data.put("modifierMHArgNum", modifierMHArgNum); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int modifierMHArgNum = Helper.RNG.nextInt(realArity + 1); + data.put("modifierMHArgNum", modifierMHArgNum); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - int modifierMHArgNum = (int) data.get("modifierMHArgNum"); - MethodHandle target; - if (kind.equals(TestMethods.Kind.ONE)) { - target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), TestMethods.Kind.ONE); - } else { - target = TestMethods.methodHandleGenerator(mtTarget.returnType(), - mtTarget.parameterList(), TestMethods.Kind.EXCEPT); - } - List> handlerParamList = new ArrayList<>(mtTarget.parameterCount() + 1); - handlerParamList.add(Exception.class); - handlerParamList.addAll(mtTarget.parameterList().subList(0, modifierMHArgNum)); - MethodHandle handler = TestMethods.methodHandleGenerator( - mtTarget.returnType(), handlerParamList, TestMethods.Kind.TWO); - return MethodHandles.catchException(target, Exception.class, handler); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + int modifierMHArgNum = (int) data.get("modifierMHArgNum"); + MethodHandle target; + if (kind.equals(TestMethods.Kind.ONE)) { + target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), TestMethods.Kind.ONE); + } else { + target = TestMethods.methodHandleGenerator(mtTarget.returnType(), + mtTarget.parameterList(), TestMethods.Kind.EXCEPT); + } + List> handlerParamList = new ArrayList<>(mtTarget.parameterCount() + 1); + handlerParamList.add(Exception.class); + handlerParamList.addAll(mtTarget.parameterList().subList(0, modifierMHArgNum)); + MethodHandle handler = TestMethods.methodHandleGenerator( + mtTarget.returnType(), handlerParamList, TestMethods.Kind.TWO); + return MethodHandles.catchException(target, Exception.class, handler); + } + }, INVOKER("invoker", Helper.MAX_ARITY - 1) { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - return MethodHandles.invoker(mtTarget); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + return MethodHandles.invoker(mtTarget); + } + }, EXACT_INVOKER("exactInvoker", Helper.MAX_ARITY - 1) { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - return MethodHandles.exactInvoker(mtTarget); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + return MethodHandles.exactInvoker(mtTarget); + } + }, SPREAD_INVOKER("spreadInvoker", Helper.MAX_ARITY - 1) { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - // Arity after reducing because of long and double take 2 slots. - int realArity = mtTarget.parameterCount(); - int modifierMHArgNum = Helper.RNG.nextInt(realArity + 1); - data.put("modifierMHArgNum", modifierMHArgNum); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + // Arity after reducing because of long and double take 2 slots. + int realArity = mtTarget.parameterCount(); + int modifierMHArgNum = Helper.RNG.nextInt(realArity + 1); + data.put("modifierMHArgNum", modifierMHArgNum); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - int modifierMHArgNum = (int) data.get("modifierMHArgNum"); - return MethodHandles.spreadInvoker(mtTarget, modifierMHArgNum); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + int modifierMHArgNum = (int) data.get("modifierMHArgNum"); + return MethodHandles.spreadInvoker(mtTarget, modifierMHArgNum); + } + }, ARRAY_ELEMENT_GETTER("arrayElementGetter") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - Class rType = mtTarget.returnType(); - if (rType == void.class) { - rType = Object.class; - } - return MethodHandles.arrayElementGetter(Array.newInstance(rType, 2).getClass()); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + Class rType = mtTarget.returnType(); + if (rType == void.class) { + rType = Object.class; + } + return MethodHandles.arrayElementGetter(Array.newInstance(rType, 2).getClass()); + } + }, ARRAY_ELEMENT_SETTER("arrayElementSetter") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - Class rType = mtTarget.returnType(); - if (rType == void.class) { - rType = Object.class; - } - return MethodHandles.arrayElementSetter(Array.newInstance(rType, 2).getClass()); - } - }, + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + Class rType = mtTarget.returnType(); + if (rType == void.class) { + rType = Object.class; + } + return MethodHandles.arrayElementSetter(Array.newInstance(rType, 2).getClass()); + } + }, CONSTANT("constant") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - return data; - } + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - Class rType = mtTarget.returnType(); - if (rType == void.class) { - rType = Object.class; - } - if (rType.equals(boolean.class)) { - // There should be the same return values because for default values there are special "zero" forms - return MethodHandles.constant(rType, true); - } else { - return MethodHandles.constant(rType, kind.getValue(rType)); - } - } - }, - IDENTITY("identity") { - @Override - public Map getTestCaseData() { - Map data = new HashMap<>(); - int desiredArity = Helper.RNG.nextInt(super.maxArity); - MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); - data.put("mtTarget", mtTarget); - return data; - } + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + Class rType = mtTarget.returnType(); + if (rType == void.class) { + rType = Object.class; + } + if (rType.equals(boolean.class)) { + // There should be the same return values because for default values there are special "zero" forms + return MethodHandles.constant(rType, true); + } else { + return MethodHandles.constant(rType, kind.getValue(rType)); + } + } + }, +IDENTITY("identity") { + @Override + public Map getTestCaseData() { + Map data = new HashMap<>(); + int desiredArity = Helper.RNG.nextInt(super.maxArity); + MethodType mtTarget = TestMethods.randomMethodTypeGenerator(desiredArity); + data.put("mtTarget", mtTarget); + return data; + } - @Override - protected MethodHandle getMH(Map data, TestMethods.Kind kind) { - MethodType mtTarget = (MethodType) data.get("mtTarget"); - Class rType = mtTarget.returnType(); - if (rType == void.class) { - rType = Object.class; - } - return MethodHandles.identity(rType); - } - }; + @Override + protected MethodHandle getMH(Map data, TestMethods.Kind kind) { + MethodType mtTarget = (MethodType) data.get("mtTarget"); + Class rType = mtTarget.returnType(); + if (rType == void.class) { + rType = Object.class; + } + return MethodHandles.identity(rType); + } + }; /** * Test method's name. @@ -514,8 +525,10 @@ public enum TestMethods { this(name, Helper.MAX_ARITY); } - protected MethodHandle getMH(Map data, TestMethods.Kind kind) throws NoSuchMethodException, IllegalAccessException { - throw new UnsupportedOperationException("TESTBUG: getMH method is not implemented for test method " + this); + protected MethodHandle getMH(Map data, TestMethods.Kind kind) + throws NoSuchMethodException, IllegalAccessException { + throw new UnsupportedOperationException( + "TESTBUG: getMH method is not implemented for test method " + this); } /** @@ -575,13 +588,15 @@ public enum TestMethods { return Helper.castToWrapper(value, cl); } - private MethodHandle getBasicMH(Class rType) throws NoSuchMethodException, IllegalAccessException { + private MethodHandle getBasicMH(Class rType) + throws NoSuchMethodException, IllegalAccessException { MethodHandle result = null; switch (this) { case ONE: case TWO: if (rType.equals(void.class)) { - result = MethodHandles.lookup().findVirtual(Kind.class, "returnVoid", MethodType.methodType(void.class)); + result = MethodHandles.lookup().findVirtual(Kind.class, + "returnVoid", MethodType.methodType(void.class)); result = MethodHandles.insertArguments(result, 0, this); } else { result = MethodHandles.constant(rType, getValue(rType)); diff --git a/jdk/test/java/lang/invoke/MethodHandles/CatchExceptionTest.java b/jdk/test/java/lang/invoke/MethodHandles/CatchExceptionTest.java index e8af1ea6bd6..de2bec2c198 100644 --- a/jdk/test/java/lang/invoke/MethodHandles/CatchExceptionTest.java +++ b/jdk/test/java/lang/invoke/MethodHandles/CatchExceptionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -20,25 +20,31 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + package test.java.lang.invoke.MethodHandles; -import com.oracle.testlibrary.jsr292.Helper; -import com.oracle.testlibrary.jsr292.CodeCacheOverflowProcessor; +import jdk.test.lib.TimeLimitedRunner; import jdk.testlibrary.Asserts; -import jdk.testlibrary.TimeLimitedRunner; import jdk.testlibrary.Utils; +import test.java.lang.invoke.lib.CodeCacheOverflowProcessor; +import test.java.lang.invoke.lib.Helper; import java.lang.invoke.MethodHandle; import java.lang.invoke.MethodHandles; import java.lang.invoke.MethodType; import java.lang.reflect.Array; -import java.util.*; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; +import java.util.List; +import java.util.Objects; import java.util.function.BiFunction; import java.util.function.Function; import java.util.function.Supplier; /* @test - * @library /lib/testlibrary/jsr292 /lib/testlibrary/ + * @library /lib/testlibrary /java/lang/invoke/common /test/lib + * @build jdk.test.lib.TimeLimitedRunner * @compile CatchExceptionTest.java * @run main/othervm -esa test.java.lang.invoke.MethodHandles.CatchExceptionTest * @key intermittent randomness @@ -68,8 +74,8 @@ public class CatchExceptionTest { private int dropped; private MethodHandle thrower; - public CatchExceptionTest(TestCase testCase, final boolean isVararg, final int argsCount, - final int catchDrops) { + public CatchExceptionTest(TestCase testCase, final boolean isVararg, + final int argsCount, final int catchDrops) { this.testCase = testCase; this.dropped = catchDrops; MethodHandle thrower = testCase.thrower; @@ -353,8 +359,8 @@ class TestCase { new ClassCastException("testing"), new java.io.IOException("testing"), new LinkageError("testing")}; - List> list = new ArrayList<>(constructors.length * - throwables.length * ThrowMode.values().length); + List> list = new ArrayList<>(constructors.length + * throwables.length * ThrowMode.values().length); //noinspection unchecked for (PartialConstructor f : constructors) { for (ThrowMode mode : ThrowMode.values()) { diff --git a/jdk/test/java/lang/invoke/MethodHandlesTest.java b/jdk/test/java/lang/invoke/MethodHandlesTest.java index 2098b5bb2a8..cc3d30d39ed 100644 --- a/jdk/test/java/lang/invoke/MethodHandlesTest.java +++ b/jdk/test/java/lang/invoke/MethodHandlesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,23 +23,46 @@ /* @test * @summary unit tests for java.lang.invoke.MethodHandles - * @library /lib/testlibrary /lib/testlibrary/jsr292 + * @library /lib/testlibrary /java/lang/invoke/common * @compile MethodHandlesTest.java remote/RemoteExample.java - * @run junit/othervm/timeout=2500 -XX:+IgnoreUnrecognizedVMOptions -XX:-VerifyDependencies -esa test.java.lang.invoke.MethodHandlesTest + * @run junit/othervm/timeout=2500 -XX:+IgnoreUnrecognizedVMOptions + * -XX:-VerifyDependencies + * -esa + * test.java.lang.invoke.MethodHandlesTest */ package test.java.lang.invoke; -import test.java.lang.invoke.remote.RemoteExample; -import java.lang.invoke.*; -import static java.lang.invoke.MethodType.methodType; -import java.lang.invoke.MethodHandles.Lookup; -import java.lang.reflect.*; -import java.util.*; import org.junit.*; -import static org.junit.Assert.*; -import com.oracle.testlibrary.jsr292.CodeCacheOverflowProcessor; +import test.java.lang.invoke.lib.CodeCacheOverflowProcessor; +import test.java.lang.invoke.remote.RemoteExample; +import java.lang.invoke.CallSite; +import java.lang.invoke.MethodHandle; +import java.lang.invoke.MethodHandleProxies; +import java.lang.invoke.MethodHandles; +import java.lang.invoke.MethodHandles.Lookup; +import java.lang.invoke.MethodType; +import java.lang.invoke.MutableCallSite; +import java.lang.invoke.WrongMethodTypeException; +import java.lang.reflect.Array; +import java.lang.reflect.Field; +import java.lang.reflect.Method; +import java.lang.reflect.Modifier; +import java.lang.reflect.UndeclaredThrowableException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.Formatter; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import static java.lang.invoke.MethodType.methodType; +import static org.junit.Assert.*; /** * diff --git a/jdk/test/java/lang/invoke/PermuteArgsTest.java b/jdk/test/java/lang/invoke/PermuteArgsTest.java index a47e4d7fc54..e175102eb80 100644 --- a/jdk/test/java/lang/invoke/PermuteArgsTest.java +++ b/jdk/test/java/lang/invoke/PermuteArgsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,10 @@ /* @test * @summary unit tests for method handles which permute their arguments - * @library /lib/testlibrary/jsr292 /lib/testlibrary + * @library /lib/testlibrary /java/lang/invoke/common * @run testng/othervm -XX:+IgnoreUnrecognizedVMOptions -XX:-VerifyDependencies -ea -esa -DPermuteArgsTest.MAX_ARITY=8 test.java.lang.invoke.PermuteArgsTest */ + /* Examples of manual runs: * java -DPermuteArgsTest.{DRY_RUN=true,MAX_ARITY=253} test.java.lang.invoke.PermuteArgsTest * java -DPermuteArgsTest.{VERBOSE=true,MAX_ARITY=5} test.java.lang.invoke.PermuteArgsTest @@ -34,17 +35,23 @@ package test.java.lang.invoke; -import org.testng.*; -import org.testng.annotations.*; +import org.testng.annotations.Test; +import test.java.lang.invoke.lib.CodeCacheOverflowProcessor; -import com.oracle.testlibrary.jsr292.CodeCacheOverflowProcessor; +import java.lang.invoke.MethodHandle; +import java.lang.invoke.MethodType; +import java.lang.invoke.WrongMethodTypeException; +import java.lang.reflect.Method; +import java.lang.reflect.Modifier; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Set; -import java.util.*; -import java.lang.reflect.*; - -import java.lang.invoke.*; -import static java.lang.invoke.MethodHandles.*; -import static java.lang.invoke.MethodType.*; +import static java.lang.invoke.MethodHandles.Lookup; +import static java.lang.invoke.MethodHandles.lookup; +import static java.lang.invoke.MethodHandles.permuteArguments; +import static java.lang.invoke.MethodType.methodType; public class PermuteArgsTest { private static final Class CLASS = PermuteArgsTest.class; @@ -205,7 +212,8 @@ public class PermuteArgsTest { throw new IllegalArgumentException("cannot convert to type "+mt1+" from "+mh, ex); } } - static MethodHandle findTestMH(String name, int[] perm) throws ReflectiveOperationException { + static MethodHandle findTestMH(String name, int[] perm) + throws ReflectiveOperationException { int arity = perm.length; Lookup lookup = lookup(); for (Method m : lookup.lookupClass().getDeclaredMethods()) { @@ -259,7 +267,8 @@ public class PermuteArgsTest { } } - static void testPermutations(MethodHandle mh, int[] perm, int start, int end, Set done) throws Throwable { + static void testPermutations(MethodHandle mh, int[] perm, int start, int end, + Set done) throws Throwable { if (end - start <= 1) return; for (int j = 0; j <= 1; j++) { testRotations(mh, perm, start, end, done); @@ -283,7 +292,8 @@ public class PermuteArgsTest { } } - static void testRotations(MethodHandle mh, int[] perm, int start, int end, Set done) throws Throwable { + static void testRotations(MethodHandle mh, int[] perm, int start, int end, + Set done) throws Throwable { Object[] args = junkArgs(mh.type().parameterArray()); for (int i = start; i < end; i++) { if (done.add(Arrays.toString(perm))) @@ -292,9 +302,11 @@ public class PermuteArgsTest { } } - static void testOnePermutation(MethodHandle mh, int[] perm, Object[] args) throws Throwable { + static void testOnePermutation(MethodHandle mh, int[] perm, Object[] args) + throws Throwable { MethodType mt = mh.type(); - MethodType pmt = methodType(mt.returnType(), unpermuteArgs(perm, mt.parameterArray(), Class[].class)); + MethodType pmt = methodType(mt.returnType(), + unpermuteArgs(perm, mt.parameterArray(), Class[].class)); if (VERBOSE) System.out.println(Arrays.toString(perm)); testCases += 1; diff --git a/jdk/test/java/lang/invoke/TestCatchExceptionWithVarargs.java b/jdk/test/java/lang/invoke/TestCatchExceptionWithVarargs.java index 160c04a65d2..9701cee7f10 100644 --- a/jdk/test/java/lang/invoke/TestCatchExceptionWithVarargs.java +++ b/jdk/test/java/lang/invoke/TestCatchExceptionWithVarargs.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,14 +24,18 @@ /* * @test * @bug 8019184 - * @library /lib/testlibrary /lib/testlibrary/jsr292 + * @library /lib/testlibrary /java/lang/invoke/common * @summary MethodHandles.catchException() fails when methods have 8 args + varargs * @run main TestCatchExceptionWithVarargs */ -import com.oracle.testlibrary.jsr292.CodeCacheOverflowProcessor; -import java.util.*; -import java.lang.invoke.*; +import test.java.lang.invoke.lib.CodeCacheOverflowProcessor; + +import java.lang.invoke.MethodHandle; +import java.lang.invoke.MethodHandles; +import java.lang.invoke.MethodType; +import java.util.LinkedList; +import java.util.List; public class TestCatchExceptionWithVarargs { @@ -48,14 +52,16 @@ public class TestCatchExceptionWithVarargs { public static Object target(Object... a) throws Exception { if (a[0] != firstArg) { - throw new AssertionError("first argument different than expected: " + a[0] + " != " + firstArg); + throw new AssertionError("first argument different than expected: " + + a[0] + " != " + firstArg); } throw new MyException(); } public static Object handler(Object... a) { if (a[0] != firstArg) { - throw new AssertionError("first argument different than expected: " + a[0] + " != " + firstArg); + throw new AssertionError("first argument different than expected: " + + a[0] + " != " + firstArg); } return a[0]; } @@ -83,20 +89,27 @@ public class TestCatchExceptionWithVarargs { for (int i = 1; i < MAX_MH_ARITY - 1; i++) { ptypes.add(0, Object.class); - MethodHandle targetWithArgs = target.asType(MethodType.methodType(Object.class, ptypes)); - MethodHandle handlerWithArgs = handler.asType(MethodType.methodType(Object.class, ptypes)); - handlerWithArgs = MethodHandles.dropArguments(handlerWithArgs, 0, MyException.class); + MethodHandle targetWithArgs = target.asType( + MethodType.methodType(Object.class, ptypes)); + MethodHandle handlerWithArgs = handler.asType( + MethodType.methodType(Object.class, ptypes)); + handlerWithArgs = MethodHandles.dropArguments( + handlerWithArgs, 0, MyException.class); - MethodHandle gwc1 = MethodHandles.catchException(targetWithArgs, MyException.class, handlerWithArgs); + MethodHandle gwc1 = MethodHandles.catchException( + targetWithArgs, MyException.class, handlerWithArgs); // The next line throws an IllegalArgumentException if there is a bug. - MethodHandle gwc2 = MethodHandles.catchException(gwc1, MyException.class, handlerWithArgs); + MethodHandle gwc2 = MethodHandles.catchException( + gwc1, MyException.class, handlerWithArgs); // This is only to verify that the method handles can actually be invoked and do the right thing. firstArg = new Object(); - Object o = gwc2.asSpreader(Object[].class, ptypes.size() - 1).invoke(firstArg, new Object[i]); + Object o = gwc2.asSpreader(Object[].class, ptypes.size() - 1) + .invoke(firstArg, new Object[i]); if (o != firstArg) { - throw new AssertionError("return value different than expected: " + o + " != " + firstArg); + throw new AssertionError("return value different than expected: " + + o + " != " + firstArg); } } } diff --git a/jdk/test/java/lang/invoke/VarargsArrayTest.java b/jdk/test/java/lang/invoke/VarargsArrayTest.java index dad164dcccc..c898bb59f2d 100644 --- a/jdk/test/java/lang/invoke/VarargsArrayTest.java +++ b/jdk/test/java/lang/invoke/VarargsArrayTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,20 +21,20 @@ * questions. */ +import sun.invoke.util.Wrapper; +import test.java.lang.invoke.lib.CodeCacheOverflowProcessor; import java.lang.invoke.MethodHandle; import java.lang.invoke.MethodHandleHelper; import java.lang.invoke.MethodType; -import sun.invoke.util.Wrapper; import java.util.Arrays; import java.util.Collections; -import com.oracle.testlibrary.jsr292.CodeCacheOverflowProcessor; /* @test * @summary unit tests for varargs array methods: MethodHandleInfo.varargsArray(int), * MethodHandleInfo.varargsArray(Class,int) & MethodHandleInfo.varargsList(int) * @modules java.base/sun.invoke.util - * @library /lib/testlibrary /lib/testlibrary/jsr292 + * @library /lib/testlibrary /java/lang/invoke/common * @compile/module=java.base java/lang/invoke/MethodHandleHelper.java * @run main/bootclasspath VarargsArrayTest * @run main/bootclasspath/othervm -DVarargsArrayTest.MAX_ARITY=255 -DVarargsArrayTest.START_ARITY=250 @@ -46,9 +46,12 @@ import com.oracle.testlibrary.jsr292.CodeCacheOverflowProcessor; */ public class VarargsArrayTest { private static final Class CLASS = VarargsArrayTest.class; - private static final int MAX_ARITY = Integer.getInteger(CLASS.getSimpleName()+".MAX_ARITY", 40); - private static final int START_ARITY = Integer.getInteger(CLASS.getSimpleName()+".START_ARITY", 0); - private static final boolean EXHAUSTIVE = Boolean.getBoolean(CLASS.getSimpleName()+".EXHAUSTIVE"); + private static final int MAX_ARITY = Integer.getInteger( + CLASS.getSimpleName()+".MAX_ARITY", 40); + private static final int START_ARITY = Integer.getInteger( + CLASS.getSimpleName()+".START_ARITY", 0); + private static final boolean EXHAUSTIVE = Boolean.getBoolean( + CLASS.getSimpleName()+".EXHAUSTIVE"); public static void main(String[] args) throws Throwable { CodeCacheOverflowProcessor.runMHTest(VarargsArrayTest::test); @@ -211,7 +214,8 @@ public class VarargsArrayTest { } return; } - throw new AssertionError(Arrays.deepToString(arr1) + " != " + Arrays.deepToString(arr2)); + throw new AssertionError(Arrays.deepToString(arr1) + + " != " + Arrays.deepToString(arr2)); } public static void assertEquals(Object o1, Object o2) { diff --git a/jdk/test/lib/testlibrary/jsr292/com/oracle/testlibrary/jsr292/CodeCacheOverflowProcessor.java b/jdk/test/java/lang/invoke/common/test/java/lang/invoke/lib/CodeCacheOverflowProcessor.java similarity index 96% rename from jdk/test/lib/testlibrary/jsr292/com/oracle/testlibrary/jsr292/CodeCacheOverflowProcessor.java rename to jdk/test/java/lang/invoke/common/test/java/lang/invoke/lib/CodeCacheOverflowProcessor.java index ca772aa431f..0cd353897bc 100644 --- a/jdk/test/lib/testlibrary/jsr292/com/oracle/testlibrary/jsr292/CodeCacheOverflowProcessor.java +++ b/jdk/test/java/lang/invoke/common/test/java/lang/invoke/lib/CodeCacheOverflowProcessor.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -20,7 +20,8 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package com.oracle.testlibrary.jsr292; + +package test.java.lang.invoke.lib; import jdk.testlibrary.Utils; diff --git a/jdk/test/lib/testlibrary/jsr292/com/oracle/testlibrary/jsr292/Helper.java b/jdk/test/java/lang/invoke/common/test/java/lang/invoke/lib/Helper.java similarity index 98% rename from jdk/test/lib/testlibrary/jsr292/com/oracle/testlibrary/jsr292/Helper.java rename to jdk/test/java/lang/invoke/common/test/java/lang/invoke/lib/Helper.java index 1f82399434a..4524d586844 100644 --- a/jdk/test/lib/testlibrary/jsr292/com/oracle/testlibrary/jsr292/Helper.java +++ b/jdk/test/java/lang/invoke/common/test/java/lang/invoke/lib/Helper.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -20,7 +20,8 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package com.oracle.testlibrary.jsr292; + +package test.java.lang.invoke.lib; import jdk.testlibrary.Asserts; @@ -28,7 +29,10 @@ import java.lang.invoke.MethodHandle; import java.lang.invoke.MethodHandles; import java.lang.invoke.MethodType; import java.lang.reflect.Array; -import java.util.*; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.Random; public class Helper { /** Flag for verbose output, true if {@code -Dverbose} specified */ diff --git a/jdk/test/java/lang/invoke/lambda/LambdaClassLoaderSerialization.java b/jdk/test/java/lang/invoke/lambda/LambdaClassLoaderSerialization.java index 6c97e3407cb..822fc45c269 100644 --- a/jdk/test/java/lang/invoke/lambda/LambdaClassLoaderSerialization.java +++ b/jdk/test/java/lang/invoke/lambda/LambdaClassLoaderSerialization.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,6 @@ * @test * @bug 8004970 * @summary Lambda serialization in the presence of class loaders - * @library /lib/testlibrary - * @build jdk.testlibrary.IOUtils * @run main LambdaClassLoaderSerialization * @author Peter Levart */ @@ -38,9 +36,6 @@ import java.io.InputStream; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.io.Serializable; -import java.util.Arrays; - -import jdk.testlibrary.IOUtils; public class LambdaClassLoaderSerialization { @@ -130,7 +125,7 @@ public class LambdaClassLoaderSerialization { String path = name.replace('.', '/').concat(".class"); try (InputStream is = getResourceAsStream(path)) { if (is != null) { - byte[] bytes = IOUtils.readFully(is); + byte[] bytes = is.readAllBytes(); return defineClass(name, bytes, 0, bytes.length); } else { throw new ClassNotFoundException(name); diff --git a/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest.java b/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest.java index d029c8ffc4c..da30cf34170 100644 --- a/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest.java +++ b/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,6 @@ * * @requires vm.gc == "null" * @requires vm.opt.ExplicitGCInvokesConcurrent != "true" - * @requires vm.opt.ExplicitGCInvokesConcurrentAndUnloadsClasses != "true" * @requires vm.opt.DisableExplicitGC != "true" * @library /lib/testlibrary/ * diff --git a/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest2.sh b/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest2.sh index 515cb8f9e2f..35ad4d626ad 100644 --- a/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest2.sh +++ b/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest2.sh @@ -1,5 +1,5 @@ # -# Copyright (c) 2004, 2015, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -54,12 +54,12 @@ go() { # Run test with each GC configuration # # Notes: To ensure that metaspace fills up we disable class unloading. -# Also we set the max metaspace to 8MB - otherwise the test takes too +# Also we set the max metaspace to 16MB - otherwise the test takes too # long to run. go -noclassgc -XX:MaxMetaspaceSize=16m -XX:+UseSerialGC LowMemoryTest2 go -noclassgc -XX:MaxMetaspaceSize=16m -XX:+UseParallelGC LowMemoryTest2 -go -noclassgc -XX:MaxMetaspaceSize=16m -XX:+UseParNewGC -XX:+UseConcMarkSweepGC LowMemoryTest2 +go -noclassgc -XX:MaxMetaspaceSize=16m -XX:+UseConcMarkSweepGC LowMemoryTest2 # Test class metaspace - might hit MaxMetaspaceSize instead if # UseCompressedClassPointers is off or if 32 bit. diff --git a/jdk/test/java/lang/management/MemoryMXBean/ResetPeakMemoryUsage.java b/jdk/test/java/lang/management/MemoryMXBean/ResetPeakMemoryUsage.java index a3d69a91c29..8e86042ac6d 100644 --- a/jdk/test/java/lang/management/MemoryMXBean/ResetPeakMemoryUsage.java +++ b/jdk/test/java/lang/management/MemoryMXBean/ResetPeakMemoryUsage.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,7 +33,6 @@ * @author Mandy Chung * * @requires vm.opt.ExplicitGCInvokesConcurrent != "true" - * @requires vm.opt.ExplicitGCInvokesConcurrentAndUnloadsClasses != "true" * @requires vm.opt.DisableExplicitGC != "true" * @library /lib/testlibrary/ * @modules jdk.management diff --git a/jdk/test/java/lang/management/ThreadMXBean/Locks.java b/jdk/test/java/lang/management/ThreadMXBean/Locks.java index fa7a5b63a6f..85761d23ed0 100644 --- a/jdk/test/java/lang/management/ThreadMXBean/Locks.java +++ b/jdk/test/java/lang/management/ThreadMXBean/Locks.java @@ -29,17 +29,17 @@ * @author Mandy Chung * @author Jaroslav Bachorik * - * @library /lib/testlibrary + * @library /test/lib * - * @build jdk.testlibrary.* * @run main/othervm Locks */ import java.lang.management.*; import java.util.Arrays; +import java.util.Objects; import java.util.Optional; import java.util.concurrent.Phaser; import java.util.function.Predicate; -import jdk.testlibrary.LockFreeLogManager; +import jdk.test.lib.LockFreeLogger; public class Locks { @@ -47,7 +47,7 @@ public class Locks { private static final Object OBJB = new Object(); private static final EnhancedWaiter OBJC = new EnhancedWaiter(); private static final ThreadMXBean TM = ManagementFactory.getThreadMXBean(); - private static final LockFreeLogManager LOGGER = new LockFreeLogManager(); + private static final LockFreeLogger LOGGER = new LockFreeLogger(); private static String getLockName(Object lock) { if (lock == null) return null; @@ -60,12 +60,12 @@ public class Locks { if (t == null) { return; } - Optional result = Arrays.asList( - TM.getThreadInfo(TM.getAllThreadIds(), true, true)). - stream(). - filter(tInfo -> (tInfo != null && tInfo.getLockOwnerName() != null) - ? tInfo.getLockOwnerName().equals(t.getName()) : false). - findAny(); + String name = t.getName(); + Optional result = Arrays.stream( + TM.getThreadInfo(TM.getAllThreadIds(), true, true)) + .filter(Objects::nonNull) + .filter(i -> name.equals(i.getLockOwnerName())) + .findAny(); if (result.isPresent()) { throw new RuntimeException("Thread " + t.getName() + " is not " + "supposed to be hold any lock. Currently owning lock : " diff --git a/jdk/test/java/lang/management/ThreadMXBean/ThreadMXBeanStateTest.java b/jdk/test/java/lang/management/ThreadMXBean/ThreadMXBeanStateTest.java index 6a9c9cacedf..fc94d4ab0ca 100644 --- a/jdk/test/java/lang/management/ThreadMXBean/ThreadMXBeanStateTest.java +++ b/jdk/test/java/lang/management/ThreadMXBean/ThreadMXBeanStateTest.java @@ -31,6 +31,7 @@ * * @library ../../Thread * @library /lib/testlibrary + * @library /test/lib * * @build jdk.testlibrary.* * @build ThreadMXBeanStateTest ThreadStateController diff --git a/jdk/test/java/lang/module/ModuleReader/ModuleReaderTest.java b/jdk/test/java/lang/module/ModuleReader/ModuleReaderTest.java index 773b114f338..5b9aca9c533 100644 --- a/jdk/test/java/lang/module/ModuleReader/ModuleReaderTest.java +++ b/jdk/test/java/lang/module/ModuleReader/ModuleReaderTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,10 +23,10 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules java.base/jdk.internal.module * jdk.compiler - * @build ModuleReaderTest CompilerUtils JarUtils + * @build ModuleReaderTest jdk.test.lib.compiler.CompilerUtils JarUtils * @run testng ModuleReaderTest * @summary Basic tests for java.lang.module.ModuleReader */ @@ -53,6 +53,7 @@ import java.util.stream.Collectors; import java.util.spi.ToolProvider; import jdk.internal.module.ModulePath; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; diff --git a/jdk/test/java/lang/module/MultiReleaseJarTest.java b/jdk/test/java/lang/module/MultiReleaseJarTest.java index 4c58e930b08..84bb2ce1518 100644 --- a/jdk/test/java/lang/module/MultiReleaseJarTest.java +++ b/jdk/test/java/lang/module/MultiReleaseJarTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/jdk/test/java/lang/ref/CleanerTest.java b/jdk/test/java/lang/ref/CleanerTest.java index c6778669f00..f7ab46f50d9 100644 --- a/jdk/test/java/lang/ref/CleanerTest.java +++ b/jdk/test/java/lang/ref/CleanerTest.java @@ -51,7 +51,12 @@ import org.testng.annotations.Test; * @test * @library /lib/testlibrary /test/lib * @build sun.hotspot.WhiteBox - * @build jdk.test.lib.Utils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @modules java.base/jdk.internal * java.base/jdk.internal.misc * java.base/jdk.internal.ref diff --git a/jdk/test/java/lang/reflect/Method/InterfaceStatic/StaticInterfaceMethodInWayOfDefault.java b/jdk/test/java/lang/reflect/Method/InterfaceStatic/StaticInterfaceMethodInWayOfDefault.java index 4ad93eb3447..ebd99e4cf84 100644 --- a/jdk/test/java/lang/reflect/Method/InterfaceStatic/StaticInterfaceMethodInWayOfDefault.java +++ b/jdk/test/java/lang/reflect/Method/InterfaceStatic/StaticInterfaceMethodInWayOfDefault.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,19 +27,14 @@ * @summary Test that a static method on an interface doesn't hide a default * method with the same name and signature in a separate compilation * scenario. - * @library /lib/testlibrary - * @build jdk.testlibrary.IOUtils * @run main StaticInterfaceMethodInWayOfDefault */ import java.io.IOException; import java.io.InputStream; -import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.util.concurrent.Callable; -import jdk.testlibrary.IOUtils; - public class StaticInterfaceMethodInWayOfDefault { public interface A_v1 { } @@ -147,7 +142,7 @@ public class StaticInterfaceMethodInWayOfDefault { String altPath = altName.replace('.', '/').concat(".class"); try (InputStream is = getResourceAsStream(altPath)) { if (is != null) { - byte[] bytes = IOUtils.readFully(is); + byte[] bytes = is.readAllBytes(); // patch class bytes to contain original name for (int i = 0; i < bytes.length - 2; i++) { if (bytes[i] == '_' && @@ -170,7 +165,7 @@ public class StaticInterfaceMethodInWayOfDefault { String path = name.replace('.', '/').concat(".class"); try (InputStream is = getResourceAsStream(path)) { if (is != null) { - byte[] bytes = IOUtils.readFully(is); + byte[] bytes = is.readAllBytes(); return defineClass(name, bytes, 0, bytes.length); } else { diff --git a/jdk/test/java/lang/reflect/Proxy/ProxyClassAccessTest.java b/jdk/test/java/lang/reflect/Proxy/ProxyClassAccessTest.java index da7b16938f0..e1b22781ad3 100644 --- a/jdk/test/java/lang/reflect/Proxy/ProxyClassAccessTest.java +++ b/jdk/test/java/lang/reflect/Proxy/ProxyClassAccessTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,6 +29,7 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.List; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.executeTestJava; import org.testng.annotations.BeforeTest; @@ -37,9 +38,10 @@ import static org.testng.Assert.*; /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build ProxyClassAccessTest q.NP CompilerUtils jdk.testlibrary.* + * @build ProxyClassAccessTest q.NP jdk.testlibrary.* + * jdk.test.lib.compiler.CompilerUtils * @run testng ProxyClassAccessTest * @summary Driver for testing proxy class doesn't have access to * types referenced by proxy interfaces diff --git a/jdk/test/java/lang/reflect/Proxy/ProxyLayerTest.java b/jdk/test/java/lang/reflect/Proxy/ProxyLayerTest.java index c420ab4ee99..9623f919ea5 100644 --- a/jdk/test/java/lang/reflect/Proxy/ProxyLayerTest.java +++ b/jdk/test/java/lang/reflect/Proxy/ProxyLayerTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,6 +29,7 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.util.Arrays; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.executeTestJava; import org.testng.annotations.BeforeTest; @@ -37,9 +38,10 @@ import static org.testng.Assert.*; /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build ProxyTest CompilerUtils jdk.testlibrary.ProcessTools + * @build ProxyTest jdk.testlibrary.ProcessTools + * jdk.test.lib.compiler.CompilerUtils * @run testng ProxyLayerTest * @summary Test proxies to implement interfaces in a layer */ diff --git a/jdk/test/java/lang/reflect/Proxy/ProxyTest.java b/jdk/test/java/lang/reflect/Proxy/ProxyTest.java index 2a7945bb5e9..8dd08e1315e 100644 --- a/jdk/test/java/lang/reflect/Proxy/ProxyTest.java +++ b/jdk/test/java/lang/reflect/Proxy/ProxyTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,7 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.List; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.executeTestJava; import org.testng.annotations.BeforeTest; @@ -34,9 +35,10 @@ import static org.testng.Assert.*; /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build ProxyTest q.U CompilerUtils jdk.testlibrary.* + * @build ProxyTest q.U jdk.testlibrary.* + * jdk.test.lib.compiler.CompilerUtils * @run testng ProxyTest * @summary Driver for testing proxies accessing interfaces in named modules */ diff --git a/jdk/test/java/math/BigDecimal/StringConstructor.java b/jdk/test/java/math/BigDecimal/StringConstructor.java index 4a3e3c4757f..47ecf7085cc 100644 --- a/jdk/test/java/math/BigDecimal/StringConstructor.java +++ b/jdk/test/java/math/BigDecimal/StringConstructor.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main StringConstructor * @bug 4103117 4331084 4488017 4490929 6255285 6268365 8074460 8078672 * @summary Tests the BigDecimal string constructor (use -Dseed=X to set PRNG seed). @@ -33,7 +33,7 @@ import java.math.*; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class StringConstructor { diff --git a/jdk/test/java/math/BigInteger/BigIntegerTest.java b/jdk/test/java/math/BigInteger/BigIntegerTest.java index f8632809fb0..8d043c57649 100644 --- a/jdk/test/java/math/BigInteger/BigIntegerTest.java +++ b/jdk/test/java/math/BigInteger/BigIntegerTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main BigIntegerTest * @bug 4181191 4161971 4227146 4194389 4823171 4624738 4812225 4837946 4026465 8074460 8078672 8032027 * @summary tests methods in BigInteger (use -Dseed=X to set PRNG seed) @@ -47,7 +47,7 @@ import java.util.stream.DoubleStream; import java.util.stream.IntStream; import java.util.stream.LongStream; import java.util.stream.Stream; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * This is a simple test class created to ensure that the results diff --git a/jdk/test/java/math/BigInteger/ModPow65537.java b/jdk/test/java/math/BigInteger/ModPow65537.java index 1ca8d603bf0..230336b94f5 100644 --- a/jdk/test/java/math/BigInteger/ModPow65537.java +++ b/jdk/test/java/math/BigInteger/ModPow65537.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main ModPow65537 * @bug 4891312 8074460 8078672 * @summary verify that modPow() not broken by the special case for 65537 (use -Dseed=X to set PRNG seed) @@ -37,7 +37,7 @@ import java.math.BigInteger; import java.security.*; import java.security.spec.*; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class ModPow65537 { diff --git a/jdk/test/java/math/BigInteger/PrimeTest.java b/jdk/test/java/math/BigInteger/PrimeTest.java index 42946106820..74b777239ca 100644 --- a/jdk/test/java/math/BigInteger/PrimeTest.java +++ b/jdk/test/java/math/BigInteger/PrimeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ /* * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main PrimeTest * @bug 8026236 8074460 8078672 * @summary test primality verification methods in BigInteger (use -Dseed=X to set PRNG seed) @@ -40,7 +40,7 @@ import java.util.NavigableSet; import java.util.Set; import java.util.SplittableRandom; import java.util.TreeSet; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; import static java.util.stream.Collectors.toCollection; import static java.util.stream.Collectors.toList; diff --git a/jdk/test/java/math/BigInteger/SymmetricRangeTests.java b/jdk/test/java/math/BigInteger/SymmetricRangeTests.java index bae3c17fd48..61a65b4b7c8 100644 --- a/jdk/test/java/math/BigInteger/SymmetricRangeTests.java +++ b/jdk/test/java/math/BigInteger/SymmetricRangeTests.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,8 +24,7 @@ /* * @test * @ignore This test has huge memory requirements - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib * @run main/timeout=180/othervm -Xmx8g SymmetricRangeTests * @bug 6910473 8021204 8021203 9005933 8074460 8078672 * @summary Test range of BigInteger values (use -Dseed=X to set PRNG seed) @@ -40,7 +39,7 @@ import java.io.ObjectOutputStream; import java.util.Arrays; import java.math.BigInteger; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class SymmetricRangeTests { diff --git a/jdk/test/java/net/Inet6Address/B6206527.java b/jdk/test/java/net/Inet6Address/B6206527.java index 4fc90e170c0..6189606be31 100644 --- a/jdk/test/java/net/Inet6Address/B6206527.java +++ b/jdk/test/java/net/Inet6Address/B6206527.java @@ -25,14 +25,15 @@ * @test 1.1 05/01/05 * @bug 6206527 * @summary "cannot assign address" when binding ServerSocket on Suse 9 - * @library /lib/testlibrary - * @build jdk.testlibrary.NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform * @run main B6206527 */ import java.net.*; import java.util.*; -import jdk.testlibrary.NetworkConfiguration; +import jdk.test.lib.NetworkConfiguration; public class B6206527 { diff --git a/jdk/test/java/net/Inet6Address/B6558853.java b/jdk/test/java/net/Inet6Address/B6558853.java index 3c546c2f02c..bff36c56062 100644 --- a/jdk/test/java/net/Inet6Address/B6558853.java +++ b/jdk/test/java/net/Inet6Address/B6558853.java @@ -25,8 +25,9 @@ * @test * @bug 6558853 * @summary getHostAddress() on connections using IPv6 link-local addrs should have zone id - * @library /lib/testlibrary - * @build jdk.testlibrary.NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform * @run main B6558853 */ @@ -35,7 +36,7 @@ import java.io.InputStream; import java.io.OutputStream; import java.net.*; import java.util.Optional; -import jdk.testlibrary.NetworkConfiguration; +import jdk.test.lib.NetworkConfiguration; public class B6558853 implements Runnable { private InetAddress addr = null; diff --git a/jdk/test/java/net/InetAddress/CheckJNI.java b/jdk/test/java/net/InetAddress/CheckJNI.java index 89f00a9c1a7..54d2255166f 100644 --- a/jdk/test/java/net/InetAddress/CheckJNI.java +++ b/jdk/test/java/net/InetAddress/CheckJNI.java @@ -22,17 +22,18 @@ */ /* @test - @bug 4889870 4890033 - @summary java -Xcheck:jni failing in net code on Solaris / [Datagram]Socket.getLocalAddress() failure - @library /lib/testlibrary - @build jdk.testlibrary.NetworkConfiguration - @run main/othervm -Xcheck:jni CheckJNI -*/ + * @bug 4889870 4890033 + * @summary java -Xcheck:jni failing in net code on Solaris / [Datagram]Socket.getLocalAddress() failure + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform + * @run main/othervm -Xcheck:jni CheckJNI + */ import java.net.*; import java.util.*; import java.util.stream.Collectors; -import jdk.testlibrary.NetworkConfiguration; +import jdk.test.lib.NetworkConfiguration; public class CheckJNI { static Socket s; diff --git a/jdk/test/java/net/InetAddress/ptr/Lookup.java b/jdk/test/java/net/InetAddress/ptr/Lookup.java index c3c5eebde78..d3051173297 100644 --- a/jdk/test/java/net/InetAddress/ptr/Lookup.java +++ b/jdk/test/java/net/InetAddress/ptr/Lookup.java @@ -28,8 +28,12 @@ * @summary Test that reverse lookups of IPv4 addresses work when IPv6 * is enabled * @library /test/lib - * @build jdk.test.lib.JDKToolFinder - * jdk.test.lib.process.OutputAnalyzer + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * Lookup * @run main Lookup root * diff --git a/jdk/test/java/net/MulticastSocket/JoinLeave.java b/jdk/test/java/net/MulticastSocket/JoinLeave.java index 93dd93930b6..a4f914bb650 100644 --- a/jdk/test/java/net/MulticastSocket/JoinLeave.java +++ b/jdk/test/java/net/MulticastSocket/JoinLeave.java @@ -25,8 +25,9 @@ * @test * @bug 4091811 4148753 4102731 * @summary Test java.net.MulticastSocket joinGroup and leaveGroup - * @library /lib/testlibrary - * @build jdk.testlibrary.NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform * @run main JoinLeave */ @@ -35,7 +36,7 @@ import java.io.UncheckedIOException; import java.net.InetAddress; import java.net.MulticastSocket; import java.net.NetworkInterface; -import jdk.testlibrary.NetworkConfiguration; +import jdk.test.lib.NetworkConfiguration; public class JoinLeave { diff --git a/jdk/test/java/net/MulticastSocket/SetLoopbackMode.java b/jdk/test/java/net/MulticastSocket/SetLoopbackMode.java index 0a6108c595d..a23f26dddd7 100644 --- a/jdk/test/java/net/MulticastSocket/SetLoopbackMode.java +++ b/jdk/test/java/net/MulticastSocket/SetLoopbackMode.java @@ -25,9 +25,16 @@ * @test * @bug 4686717 * @summary Test MulticastSocket.setLoopbackMode + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform + * @run main/othervm SetLoopbackMode */ + import java.net.*; import java.io.IOException; +import java.util.Enumeration; +import jdk.test.lib.NetworkConfiguration; public class SetLoopbackMode { @@ -85,8 +92,13 @@ public class SetLoopbackMode { return PASSED; } + private static boolean canUseIPv6(NetworkConfiguration nc) { + return nc.ip6MulticastInterfaces().toArray().length > 0; + } + public static void main (String args[]) throws Exception { int failures = 0; + NetworkConfiguration nc = NetworkConfiguration.probe(); MulticastSocket mc = new MulticastSocket(); InetAddress grp = InetAddress.getByName("224.80.80.80"); @@ -97,11 +109,12 @@ public class SetLoopbackMode { * to workaround Linux IPv6 bug whereby !IPV6_MULTICAST_LOOP * doesn't prevent loopback of IPv4 multicast packets. */ - InetAddress lb = InetAddress.getByName("::1"); - if (NetworkInterface.getByInetAddress(lb) != null) { + + if (canUseIPv6(nc)) { grp = InetAddress.getByName("ff01::1"); } + //mc.setNetworkInterface(NetworkInterface.getByInetAddress(lb)); System.out.println("\nTest will use multicast group: " + grp); mc.joinGroup(grp); diff --git a/jdk/test/java/net/MulticastSocket/Test.java b/jdk/test/java/net/MulticastSocket/Test.java index 53fa961d2d4..853f04d1eae 100644 --- a/jdk/test/java/net/MulticastSocket/Test.java +++ b/jdk/test/java/net/MulticastSocket/Test.java @@ -35,6 +35,10 @@ public class Test { static int count = 0; static int failures = 0; + static boolean isSolaris = System.getProperty("os.name") + .toLowerCase() + .startsWith("sunos"); + void doTest(String address) throws Exception { boolean failed = false; @@ -123,6 +127,14 @@ public class Test { } } + static boolean isValidIpv6Address(InetAddress addr) { + if (! (addr instanceof Inet6Address)) + return false; + if (!isSolaris) + return true; + return !(addr.isAnyLocalAddress() || addr.isLoopbackAddress()); + } + void allTests() throws Exception { /* @@ -146,7 +158,7 @@ public class Test { while (addrs.hasMoreElements()) { InetAddress ia = (InetAddress)addrs.nextElement(); - if (ia instanceof Inet6Address) { + if (isValidIpv6Address(ia)) { has_ipv6 = true; if (ia.isLinkLocalAddress()) has_linklocaladdress = true; if (ia.isSiteLocalAddress()) has_siteaddress = true; diff --git a/jdk/test/java/net/NetworkConfigurationProbe.java b/jdk/test/java/net/NetworkConfigurationProbe.java index 8b8127a55e2..ed3763566bf 100644 --- a/jdk/test/java/net/NetworkConfigurationProbe.java +++ b/jdk/test/java/net/NetworkConfigurationProbe.java @@ -24,15 +24,21 @@ /** * @test * @summary NOT A TEST. Captures the network interface configuration. - * @library /lib/testlibrary - * @build jdk.testlibrary.NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main NetworkConfigurationProbe */ import java.net.Inet4Address; import java.net.Inet6Address; import java.net.NetworkInterface; -import jdk.testlibrary.NetworkConfiguration; +import jdk.test.lib.NetworkConfiguration; import static java.util.stream.Collectors.joining; import static java.lang.System.out; diff --git a/jdk/test/java/net/NetworkInterface/NetworkInterfaceRetrievalTests.java b/jdk/test/java/net/NetworkInterface/NetworkInterfaceRetrievalTests.java new file mode 100644 index 00000000000..276cf42fe7c --- /dev/null +++ b/jdk/test/java/net/NetworkInterface/NetworkInterfaceRetrievalTests.java @@ -0,0 +1,73 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8179559 + */ + +import java.net.InetAddress; +import java.net.NetworkInterface; +import java.util.Enumeration; + +public class NetworkInterfaceRetrievalTests { + public static void main(String[] args) throws Exception { + int checkFailureCount = 0; + + try { + Enumeration en = NetworkInterface + .getNetworkInterfaces(); + while (en.hasMoreElements()) { + NetworkInterface ni = en.nextElement(); + Enumeration addrs = ni.getInetAddresses(); + System.out.println("############ Checking network interface + " + + ni + " #############"); + while (addrs.hasMoreElements()) { + InetAddress addr = addrs.nextElement(); + System.out.println("************ Checking address + " + + addr + " *************"); + NetworkInterface addrNetIf = NetworkInterface + .getByInetAddress(addr); + if (addrNetIf.equals(ni)) { + System.out.println("Retreived net if " + addrNetIf + + " equal to owning net if " + ni); + } else { + System.out.println("Retreived net if " + addrNetIf + + "NOT equal to owning net if " + ni + + "***********"); + checkFailureCount++; + } + + } + } + + } catch (Exception ex) { + + } + + if (checkFailureCount > 0) { + throw new RuntimeException( + "NetworkInterface lookup by address didn't match owner network interface"); + } + } +} diff --git a/jdk/test/java/net/NetworkInterface/NetworkInterfaceStreamTest.java b/jdk/test/java/net/NetworkInterface/NetworkInterfaceStreamTest.java index 1fa3a557941..74a5c014dfd 100644 --- a/jdk/test/java/net/NetworkInterface/NetworkInterfaceStreamTest.java +++ b/jdk/test/java/net/NetworkInterface/NetworkInterfaceStreamTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,7 @@ /* @test * @bug 8081678 8131155 * @summary Tests for stream returning methods - * @library ../../util/stream/bootlib + * @library /lib/testlibrary/bootlib * @build java.base/java.util.stream.OpTestCase * @run testng/othervm NetworkInterfaceStreamTest * @run testng/othervm -Djava.net.preferIPv4Stack=true NetworkInterfaceStreamTest diff --git a/jdk/test/java/net/ServerSocket/AcceptCauseFileDescriptorLeak.java b/jdk/test/java/net/ServerSocket/AcceptCauseFileDescriptorLeak.java index d2e3af48689..b62b6057366 100644 --- a/jdk/test/java/net/ServerSocket/AcceptCauseFileDescriptorLeak.java +++ b/jdk/test/java/net/ServerSocket/AcceptCauseFileDescriptorLeak.java @@ -30,8 +30,12 @@ * can cause fd leak * @requires (os.family != "windows") * @library /test/lib - * @build jdk.test.lib.JDKToolFinder - * jdk.test.lib.process.OutputAnalyzer + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * AcceptCauseFileDescriptorLeak * @run main/othervm AcceptCauseFileDescriptorLeak root */ diff --git a/jdk/test/java/net/Socket/LinkLocal.java b/jdk/test/java/net/Socket/LinkLocal.java index e62522cb581..d048764e981 100644 --- a/jdk/test/java/net/Socket/LinkLocal.java +++ b/jdk/test/java/net/Socket/LinkLocal.java @@ -26,11 +26,13 @@ * @bug 4469866 * @summary Connecting to a link-local IPv6 address should not * causes a SocketException to be thrown. - * @library /lib/testlibrary - * @build jdk.testlibrary.NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform * @run main LinkLocal */ -import jdk.testlibrary.NetworkConfiguration; + +import jdk.test.lib.NetworkConfiguration; import java.net.*; import java.util.List; diff --git a/jdk/test/java/net/Socket/OldSocketImpl.sh b/jdk/test/java/net/Socket/OldSocketImpl.sh deleted file mode 100644 index 70b92afc7b6..00000000000 --- a/jdk/test/java/net/Socket/OldSocketImpl.sh +++ /dev/null @@ -1,61 +0,0 @@ -# -# Copyright (c) 2006, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 6449565 -# @run shell/timeout=140 OldSocketImpl.sh -# @summary Pre-1.4 SocketImpl no longer supported - -OS=`uname -s` -case "$OS" in - SunOS | Linux | Darwin | AIX ) - PS=":" - FS="/" - ;; - CYGWIN* ) - PS=";" - FS="/" - ;; - Windows* ) - PS=";" - FS="\\" - ;; - * ) - echo "Unrecognized system!" - exit 1; - ;; -esac - -# no need to compile the test. It is already compiled -# with 1.3 and in OldStyleImpl.jar - -# run -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} -cp ${TESTSRC}${FS}OldSocketImpl.jar OldSocketImpl -result=$? -if [ "$result" -ne "0" ]; then - exit 1 -fi - -# no failures, exit. -exit 0 - diff --git a/hotspot/test/gc/startup_warnings/TestUseAutoGCSelectPolicy.java b/jdk/test/java/net/Socket/OldSocketImplTestDriver.java similarity index 54% rename from hotspot/test/gc/startup_warnings/TestUseAutoGCSelectPolicy.java rename to jdk/test/java/net/Socket/OldSocketImplTestDriver.java index 360e5e05970..3bfb8967c42 100644 --- a/hotspot/test/gc/startup_warnings/TestUseAutoGCSelectPolicy.java +++ b/jdk/test/java/net/Socket/OldSocketImplTestDriver.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,27 +21,31 @@ * questions. */ -/* - * @test TestUseAutoGCSelectPolicy - * @key gc - * @bug 8166461 8167494 - * @summary Test that UseAutoGCSelectPolicy and AutoGCSelectPauseMillis do print a warning message - * @library /test/lib - * @modules java.base/jdk.internal.misc - * java.management - */ - import jdk.test.lib.process.ProcessTools; -import jdk.test.lib.process.OutputAnalyzer; -public class TestUseAutoGCSelectPolicy { +import java.nio.file.Path; +import java.nio.file.Paths; - public static void main(String args[]) throws Exception { - ProcessBuilder pb = ProcessTools.createJavaProcessBuilder("-XX:+UseAutoGCSelectPolicy", "-XX:AutoGCSelectPauseMillis=3000", "-version"); - OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("UseAutoGCSelectPolicy was deprecated in version 9.0"); - output.shouldContain("AutoGCSelectPauseMillis was deprecated in version 9.0"); - output.shouldNotContain("error"); - output.shouldHaveExitValue(0); - } +/** + * @test + * @bug 6449565 + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @run main OldSocketImplTestDriver + * @summary Test driver for OdlSocketImpl + */ +public class OldSocketImplTestDriver { + public static void main(String[] args) throws Throwable { + Path jar = Paths.get(System.getProperty("test.src"), + "OldSocketImpl.jar"); + ProcessTools.executeTestJava("-cp", jar.toString(), "OldSocketImpl") + .outputTo(System.out) + .errorTo(System.out) + .shouldHaveExitValue(0); + } } diff --git a/jdk/test/java/net/SocketPermission/SocketPermissionTest.java b/jdk/test/java/net/SocketPermission/SocketPermissionTest.java index e67802afc33..c0c3260380a 100644 --- a/jdk/test/java/net/SocketPermission/SocketPermissionTest.java +++ b/jdk/test/java/net/SocketPermission/SocketPermissionTest.java @@ -25,8 +25,9 @@ * @test * @bug 8047031 * @summary SocketPermission tests for legacy socket types - * @library /lib/testlibrary - * @build jdk.testlibrary.NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform * @run testng/othervm SocketPermissionTest */ @@ -55,7 +56,7 @@ import org.testng.annotations.Test; import static org.testng.Assert.*; -import static jdk.testlibrary.NetworkConfiguration.probe; +import static jdk.test.lib.NetworkConfiguration.probe; import static java.nio.charset.StandardCharsets.UTF_8; public class SocketPermissionTest { diff --git a/jdk/test/java/net/URL/B5086147.java b/jdk/test/java/net/URL/B5086147.java index 284b4f60508..47260912a41 100644 --- a/jdk/test/java/net/URL/B5086147.java +++ b/jdk/test/java/net/URL/B5086147.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,12 +24,13 @@ /** * @test * @bug 5086147 - * @run shell B5086147.sh + * @requires (os.family == "windows") + * @run main B5086147 * @summary File,URI,URL conversions are strange for UNC path */ -import java.net.*; -import java.io.*; +import java.io.File; +import java.net.URI; public class B5086147 { public static final void main( String[] aaParamters ) throws Exception{ diff --git a/jdk/test/java/net/URL/B5086147.sh b/jdk/test/java/net/URL/B5086147.sh deleted file mode 100644 index 772d7a32cd1..00000000000 --- a/jdk/test/java/net/URL/B5086147.sh +++ /dev/null @@ -1,56 +0,0 @@ -#! /bin/sh - -# -# Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - - -OS=`uname -s` -case "$OS" in - SunOS | Linux | Darwin | AIX ) - exit 0 - ;; - CYGWIN* ) - PS=";" - FS="/" - ;; - Windows* ) - PS=";" - FS="\\" - ;; - * ) - echo "Unrecognized system!" - exit 1; - ;; -esac -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}${FS}B5086147.java - -failures=0 - -echo '' -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} B5086147 -if [ $? != 0 ]; then failures=`expr $failures + 1`; fi - -if [ "$failures" != "0" ]; then - echo $failures tests failed - exit 1; -fi diff --git a/jdk/test/java/net/URLClassLoader/B5077773.sh b/jdk/test/java/net/URLClassLoader/B5077773.sh deleted file mode 100644 index 3b52698840a..00000000000 --- a/jdk/test/java/net/URLClassLoader/B5077773.sh +++ /dev/null @@ -1,66 +0,0 @@ -#! /bin/sh - -# -# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @author Michael McMahon -# @bug 5077773 -# @summary Change in behaviour w.r.t jdk1.4.2 when loading resourcebundles -# -# ${TESTJAVA} is pointing to the jre -# -# set platform-dependent variables - -OS=`uname -s` -case "$OS" in - SunOS | Darwin | AIX ) - PS=":" - FS="/" - ;; - Linux ) - PS=":" - FS="/" - ;; - CYGWIN* ) - PS=";" - FS="/" - ;; - Windows* ) - PS=";" - FS="\\" - ;; - * ) - echo "Unrecognized system!" - exit 1; - ;; -esac - -cp ${TESTSRC}${FS}foo.jar . - -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . \ - ${TESTSRC}${FS}B5077773.java - -WD=`pwd` -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} B5077773 - diff --git a/jdk/test/java/net/URLClassLoader/closetest/CloseTest.java b/jdk/test/java/net/URLClassLoader/closetest/CloseTest.java index 47feb498c51..3453f8a56a0 100644 --- a/jdk/test/java/net/URLClassLoader/closetest/CloseTest.java +++ b/jdk/test/java/net/URLClassLoader/closetest/CloseTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,24 +26,38 @@ * @bug 4167874 * @modules java.logging * jdk.httpserver + * jdk.compiler * @library ../../../../com/sun/net/httpserver - * @library /lib/testlibrary - * @build FileServerHandler jdk.testlibrary.FileUtils - * @run shell build.sh + * /lib/testlibrary + * /test/lib + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.util.FileUtils + * jdk.test.lib.Platform + * FileServerHandler JarUtils * @run main/othervm CloseTest * @summary URL-downloaded jar files can consume all available file descriptors */ import java.io.File; +import java.io.IOException; import java.lang.reflect.Method; import java.net.URLClassLoader; import java.net.InetSocketAddress; import java.net.URL; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; + +import jdk.test.lib.compiler.CompilerUtils; + import com.sun.net.httpserver.HttpContext; import com.sun.net.httpserver.HttpServer; -public class CloseTest extends Common { +import static java.nio.file.StandardCopyOption.REPLACE_EXISTING; +public class CloseTest extends Common { + private static final String WORK_DIR = System.getProperty("user.dir") + + "/"; // // needs two jar files test1.jar and test2.jar with following structure // @@ -54,39 +68,31 @@ public class CloseTest extends Common { // // and a directory hierarchy with the same structure/contents - public static void main (String args[]) throws Exception { + public static void main(String args[]) throws Exception { + setup(); - String workdir = System.getProperty("test.classes"); - if (workdir == null) { - workdir = args[0]; - } - if (!workdir.endsWith("/")) { - workdir = workdir+"/"; - } + startHttpServer(WORK_DIR + "serverRoot/"); - startHttpServer (workdir+"serverRoot/"); - - String testjar = workdir + "test.jar"; - copyFile (workdir+"test1.jar", testjar); - test (testjar, 1); + String testjar = WORK_DIR + "test.jar"; + copyFile(WORK_DIR + "test1.jar", testjar); + test(testjar, 1); // repeat test with different implementation // of test.jar (whose TestClass.getValue() returns 2 - - copyFile (workdir+"test2.jar", testjar); - test (testjar, 2); + copyFile(WORK_DIR + "test2.jar", testjar); + test(testjar, 2); // repeat test using a directory of files - String testdir=workdir+"testdir/"; - rm_minus_rf (new File(testdir)); - copyDir (workdir+"test1/", testdir); - test (testdir, 1); + String testdir = WORK_DIR + "testdir/"; + rm_minus_rf(new File(testdir)); + copyDir(WORK_DIR + "test1/", testdir); + test(testdir, 1); - testdir=workdir+"testdir/"; - rm_minus_rf (new File(testdir)); - copyDir (workdir+"test2/", testdir); - test (testdir, 2); - getHttpServer().stop (3); + testdir = WORK_DIR + "testdir/"; + rm_minus_rf(new File(testdir)); + copyDir(WORK_DIR + "test2/", testdir); + test(testdir, 2); + getHttpServer().stop(3); } // create a loader on jarfile (or directory), plus a http loader @@ -98,47 +104,48 @@ public class CloseTest extends Common { // check existing classes can be loaded // check boot classes can be loaded - static void test (String name, int expectedValue) throws Exception { - URL url = new URL ("file", null, name); + static void test(String name, int expectedValue) throws Exception { + + URL url = new URL("file", null, name); URL url2 = getServerURL(); - System.out.println ("Doing tests with URL: " + url + " and " + url2); + System.out.println("Doing tests with URL: " + url + " and " + url2); URL[] urls = new URL[2]; - urls[0] = url; - urls[1] = url2; - URLClassLoader loader = new URLClassLoader (urls); - Class testclass = loadClass ("com.foo.TestClass", loader, true); - Class class2 = loadClass ("Test", loader, true); // from http + urls[0] = url; + urls[1] = url2; + URLClassLoader loader = new URLClassLoader(urls); + Class testclass = loadClass("com.foo.TestClass", loader, true); + Class class2 = loadClass("Test", loader, true); // from http class2.newInstance(); Object test = testclass.newInstance(); Method method = testclass.getDeclaredMethods()[0]; // int getValue(); - int res = (Integer) method.invoke (test); + int res = (Integer) method.invoke(test); if (res != expectedValue) { - throw new RuntimeException ("wrong value from getValue() ["+res+ - "/"+expectedValue+"]"); + throw new RuntimeException("wrong value from getValue() [" + res + + "/" + expectedValue + "]"); } // should find /resource1 - URL u1 = loader.findResource ("com/foo/Resource1"); + URL u1 = loader.findResource("com/foo/Resource1"); if (u1 == null) { - throw new RuntimeException ("can't find com/foo/Resource1 in test1.jar"); + throw new RuntimeException("can't find com/foo/Resource1 in test1.jar"); } - loader.close (); + loader.close(); // should NOT find /resource2 even though it is in jar - URL u2 = loader.findResource ("com/foo/Resource2"); + URL u2 = loader.findResource("com/foo/Resource2"); if (u2 != null) { - throw new RuntimeException ("com/foo/Resource2 unexpected in test1.jar"); + throw new RuntimeException("com/foo/Resource2 unexpected in test1.jar"); } // load tests - loadClass ("com.foo.TestClass1", loader, false); - loadClass ("com.foo.TestClass", loader, true); - loadClass ("java.util.ArrayList", loader, true); + loadClass("com.foo.TestClass1", loader, false); + loadClass("com.foo.TestClass", loader, true); + loadClass("java.util.ArrayList", loader, true); // now check we can delete the path - rm_minus_rf (new File(name)); - System.out.println (" ... OK"); + rm_minus_rf(new File(name)); + System.out.println(" ... OK"); } static HttpServer httpServer; @@ -147,17 +154,54 @@ public class CloseTest extends Common { return httpServer; } - static URL getServerURL () throws Exception { + static URL getServerURL() throws Exception { int port = httpServer.getAddress().getPort(); - String s = "http://127.0.0.1:"+port+"/"; + String s = "http://127.0.0.1:" + port + "/"; return new URL(s); } - static void startHttpServer (String docroot) throws Exception { - httpServer = HttpServer.create (new InetSocketAddress(0), 10); - HttpContext ctx = httpServer.createContext ( + static void startHttpServer(String docroot) throws Exception { + httpServer = HttpServer.create(new InetSocketAddress(0), 10); + HttpContext ctx = httpServer.createContext( "/", new FileServerHandler(docroot) ); httpServer.start(); } + + /** + * Prepare jars files for the tests + */ + private static void setup () throws IOException { + String[] tests = new String[]{"test1", "test2"}; + Path workDir = Paths.get(WORK_DIR); + Path testSrc = Paths.get(System.getProperty("test.src")); + for (String test : tests) { + Path testSrcDir = testSrc.resolve(test); + Path testTargetDir = workDir.resolve(test); + // Compile sources for corresponding test + CompilerUtils.compile(testSrcDir, testTargetDir); + // Copy all resources + Path packages = Paths.get("com", "foo"); + Path copySrcDir = testSrcDir.resolve(packages); + Path copyTargetDir = testTargetDir.resolve(packages); + Files.createDirectories(copyTargetDir); + Path res1 = Paths.get("Resource1"); + Path res2 = Paths.get("Resource2"); + Files.copy(copySrcDir.resolve(res1), copyTargetDir.resolve(res1), + REPLACE_EXISTING); + Files.copy(copySrcDir.resolve(res2), copyTargetDir.resolve(res2), + REPLACE_EXISTING); + // Create jar + JarUtils.createJarFile(workDir.resolve(test + ".jar"), testTargetDir); + } + + // Copy and compile server test class + Path serverRoot = Paths.get("serverRoot"); + Path targetDir = workDir.resolve(serverRoot); + Path file = Paths.get("Test.java"); + Files.createDirectories(targetDir); + Files.copy(testSrc.resolve(serverRoot).resolve(file), + targetDir.resolve(file), REPLACE_EXISTING); + CompilerUtils.compile(targetDir, targetDir); + } } diff --git a/jdk/test/java/net/URLClassLoader/closetest/Common.java b/jdk/test/java/net/URLClassLoader/closetest/Common.java index 0326a3d8ce4..0fa16248e1c 100644 --- a/jdk/test/java/net/URLClassLoader/closetest/Common.java +++ b/jdk/test/java/net/URLClassLoader/closetest/Common.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,7 @@ import java.io.*; import java.net.*; import java.nio.file.Files; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; import static java.nio.file.StandardCopyOption.*; public class Common { diff --git a/jdk/test/java/net/URLClassLoader/closetest/GetResourceAsStream.java b/jdk/test/java/net/URLClassLoader/closetest/GetResourceAsStream.java index a11d58afe8f..896dd404b30 100644 --- a/jdk/test/java/net/URLClassLoader/closetest/GetResourceAsStream.java +++ b/jdk/test/java/net/URLClassLoader/closetest/GetResourceAsStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,16 +24,29 @@ /** * @test * @bug 6899919 - * @library /lib/testlibrary - * @build jdk.testlibrary.FileUtils - * @run shell build2.sh + * @library /lib/testlibrary /test/lib + * @modules jdk.compiler + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.util.FileUtils + * jdk.test.lib.Platform + * JarUtils * @run main/othervm GetResourceAsStream */ -import java.io.*; -import java.net.*; +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.net.URL; +import java.net.URLClassLoader; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.nio.file.StandardCopyOption; +import java.nio.file.StandardOpenOption; +import jdk.test.lib.compiler.CompilerUtils; public class GetResourceAsStream extends Common { + private static final String WORK_DIR = System.getProperty("user.dir"); /* * We simply test various scenarios with class/resource files @@ -42,35 +55,30 @@ public class GetResourceAsStream extends Common { * on Windows. It will still run correctly on other platforms */ public static void main (String args[]) throws Exception { - - String workdir = System.getProperty("test.classes"); - if (workdir == null) { - workdir = args[0]; - } + setup(); /* the jar we copy for each test */ - File srcfile = new File (workdir, "foo.jar"); + File srcfile = new File(WORK_DIR, "foo.jar"); /* the jar we use for the test */ - File testfile = new File (workdir, "test.jar"); + File testfile = new File(WORK_DIR, "test.jar"); - copyFile (srcfile, testfile); - test (testfile, false, false); + copyFile(srcfile, testfile); + test(testfile, false, false); - copyFile (srcfile, testfile); - test (testfile, true, false); + copyFile(srcfile, testfile); + test(testfile, true, false); - copyFile (srcfile, testfile); - test (testfile, true, true); + copyFile(srcfile, testfile); + test(testfile, true, true); // repeat test using a directory of files - File testdir= new File (workdir, "testdir"); - File srcdir= new File (workdir, "test3"); - - copyDir (srcdir, testdir); - test (testdir, true, false); + File testdir = new File(WORK_DIR, "testdir"); + File srcdir = new File(WORK_DIR, "test3"); + copyDir(srcdir, testdir); + test(testdir, true, false); } // create a loader on jarfile (or directory) @@ -82,7 +90,7 @@ public class GetResourceAsStream extends Common { static void test (File file, boolean loadclass, boolean readall) throws Exception { - URL[] urls = new URL[] {file.toURL()}; + URL[] urls = new URL[] {file.toURI().toURL()}; System.out.println ("Doing tests with URL: " + urls[0]); URLClassLoader loader = new URLClassLoader (urls); if (loadclass) { @@ -97,7 +105,7 @@ public class GetResourceAsStream extends Common { loader.close (); - // shouuld not find bye.txt now + // should not find bye.txt now InputStream s1 = loader.getResourceAsStream("bye.txt"); if (s1 != null) { throw new RuntimeException ("closed loader returned resource"); @@ -107,4 +115,26 @@ public class GetResourceAsStream extends Common { rm_minus_rf (file); System.out.println (" ... OK"); } + + /** + * Prepare jars files for the tests + */ + private static void setup () throws IOException { + Path classes = Paths.get(WORK_DIR); + Path testSrc = Paths.get(System.getProperty("test.src"), + "test1", "com", "foo", "TestClass.java"); + Path targetDir = classes.resolve("test3"); + Path testTarget = targetDir.resolve("TestClass.java"); + Files.createDirectories(targetDir); + Files.copy(testSrc, testTarget, StandardCopyOption.REPLACE_EXISTING); + // Compile sources for corresponding test + CompilerUtils.compile(targetDir, targetDir); + // Prepare txt files + Files.write(targetDir.resolve("hello.txt"), "Hello world".getBytes(), + StandardOpenOption.CREATE); + Files.write(targetDir.resolve("bye.txt"), "Bye world".getBytes(), + StandardOpenOption.CREATE); + // Create jar + JarUtils.createJarFile(classes.resolve("foo.jar"), targetDir); + } } diff --git a/jdk/test/java/net/URLClassLoader/closetest/build.sh b/jdk/test/java/net/URLClassLoader/closetest/build.sh deleted file mode 100644 index 4fe159be83a..00000000000 --- a/jdk/test/java/net/URLClassLoader/closetest/build.sh +++ /dev/null @@ -1,78 +0,0 @@ -#!/bin/sh -# -# Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# -# -# -# This script builds the test files for the test -# but not the actual test sources themselves. -# -if [ "${TESTSRC}" = "" ] -then - echo "TESTSRC not set. Test cannot execute. Failed." - exit 1 -fi -echo "TESTSRC=${TESTSRC}" - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." - exit 1 -fi -echo "TESTJAVA=${TESTJAVA}" - -if [ "${COMPILEJAVA}" = "" ]; then - COMPILEJAVA="${TESTJAVA}" -fi -echo "COMPILEJAVA=${COMPILEJAVA}" - -if [ "${TESTCLASSES}" = "" ] -then - echo "TESTCLASSES not set. Test cannot execute. Failed." - exit 1 -fi - -JAVAC="${COMPILEJAVA}/bin/javac" -JAR="${COMPILEJAVA}/bin/jar" - -rm -rf ${TESTCLASSES}/test1 -rm -rf ${TESTCLASSES}/test2 -rm -rf ${TESTCLASSES}/serverRoot -mkdir -p ${TESTCLASSES}/test1/com/foo -mkdir -p ${TESTCLASSES}/test2/com/foo -mkdir -p ${TESTCLASSES}/serverRoot - -cd ${TESTSRC}/test1/com/foo -cp * ${TESTCLASSES}/test1/com/foo -cd ${TESTCLASSES}/test1 -${JAVAC} ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} com/foo/*.java -${JAR} ${TESTTOOLVMOPTS} cvf ../test1.jar com/foo/*.class com/foo/Resource* - -cd ${TESTSRC}/test2/com/foo -cp * ${TESTCLASSES}/test2/com/foo -cd ${TESTCLASSES}/test2 -${JAVAC} ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} com/foo/*.java -${JAR} ${TESTTOOLVMOPTS} cvf ../test2.jar com/foo/*.class com/foo/Resource* - -cp ${TESTSRC}/serverRoot/Test.java ${TESTCLASSES}/serverRoot -cd ${TESTCLASSES}/serverRoot -${JAVAC} ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} Test.java diff --git a/jdk/test/java/net/URLClassLoader/closetest/build2.sh b/jdk/test/java/net/URLClassLoader/closetest/build2.sh deleted file mode 100644 index 5b6f830d84e..00000000000 --- a/jdk/test/java/net/URLClassLoader/closetest/build2.sh +++ /dev/null @@ -1,58 +0,0 @@ -#!/bin/sh -# -# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# -if [ "${TESTSRC}" = "" ] -then - echo "TESTSRC not set. Test cannot execute. Failed." - exit 1 -fi -echo "TESTSRC=${TESTSRC}" - -if [ "${TESTJAVA}" = "" ] -then - echo "TESTJAVA not set. Test cannot execute. Failed." - exit 1 -fi -echo "TESTJAVA=${TESTJAVA}" - -if [ "${TESTCLASSES}" = "" ] -then - echo "TESTCLASSES not set. Test cannot execute. Failed." - exit 1 -fi - -JAVAC="${TESTJAVA}/bin/javac" -JAR="${TESTJAVA}/bin/jar" - -rm -rf ${TESTCLASSES}/test3 -mkdir -p ${TESTCLASSES}/test3 - -echo "Hello world" > ${TESTCLASSES}/test3/hello.txt -echo "Bye world" > ${TESTCLASSES}/test3/bye.txt -cp ${TESTSRC}/test1/com/foo/TestClass.java ${TESTCLASSES}/test3 -cd ${TESTCLASSES}/test3 -${JAVAC} -d . TestClass.java - -${JAR} cvf foo.jar hello.txt bye.txt com/foo/TestClass.class -rm -f ../foo.jar -mv foo.jar .. diff --git a/jdk/test/java/net/URLClassLoader/definePackage/SplitPackage.java b/jdk/test/java/net/URLClassLoader/definePackage/SplitPackage.java index f5af425be46..e8698dddf6b 100644 --- a/jdk/test/java/net/URLClassLoader/definePackage/SplitPackage.java +++ b/jdk/test/java/net/URLClassLoader/definePackage/SplitPackage.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ * @test * @bug 8153665 * @summary Test two URLClassLoader define Package object of the same name - * @library /lib/testlibrary - * @build CompilerUtils + * @library /test/lib + * @build jdk.test.lib.compiler.CompilerUtils * @modules jdk.compiler * @run testng SplitPackage */ @@ -38,6 +38,7 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.nio.file.StandardCopyOption; import java.util.jar.Manifest; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; diff --git a/jdk/test/java/net/URLClassLoader/getresourceasstream/TestDriver.java b/jdk/test/java/net/URLClassLoader/getresourceasstream/TestDriver.java new file mode 100644 index 00000000000..526689e21ea --- /dev/null +++ b/jdk/test/java/net/URLClassLoader/getresourceasstream/TestDriver.java @@ -0,0 +1,112 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 5103449 + * @summary REGRESSION: getResourceAsStream is broken in JDK1.5.0-rc + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * Test + * @run main/othervm TestDriver + */ + +import jdk.test.lib.JDKToolFinder; +import jdk.test.lib.process.ProcessTools; + +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import static java.nio.file.StandardCopyOption.REPLACE_EXISTING; + +public class TestDriver { + private static final String ARCHIVE_NAME = "test.jar"; + private static final String TEST_NAME = "Test"; + private static final String POLICY_FILE = "policy"; + public static void main(String[] args) + throws Throwable { + + Path userDir = Paths.get(System.getProperty("user.dir")); + String java = JDKToolFinder.getTestJDKTool("java"); + String basename = userDir.getFileName().toString(); + setup(userDir); + ProcessBuilder[] tests = new ProcessBuilder[]{ + new ProcessBuilder( + java, TEST_NAME, "./" + ARCHIVE_NAME + ), + new ProcessBuilder( + java, "-cp", ".", + "-Djava.security.policy=file:./policy", + "-Djava.security.manager", + TEST_NAME, "./" + ARCHIVE_NAME + ), + new ProcessBuilder( + java, "-cp", ".", + "-Djava.security.policy=file:./policy", + "-Djava.security.manager", + TEST_NAME, "./" + ARCHIVE_NAME + ), + new ProcessBuilder( + java, "-cp", "..", + "-Djava.security.policy=file:../policy", + "-Djava.security.manager", + TEST_NAME, "../" + ARCHIVE_NAME + ).directory(userDir.resolve("tmp").toFile()), + new ProcessBuilder( + java, "-cp", basename, + "-Djava.security.policy=file:" + basename + "/policy", + "-Djava.security.manager", + TEST_NAME, basename + "/" + ARCHIVE_NAME + ).directory(userDir.resolve("..").toFile())}; + for (ProcessBuilder test : tests) { + runTest(test); + } + } + + private static void setup(Path userDir) throws IOException { + Path src = Paths.get(System.getProperty("test.src")); + Path testJar = src.resolve(ARCHIVE_NAME); + Path policy = src.resolve(POLICY_FILE); + Path testClass = Paths.get(System.getProperty("test.classes"), + TEST_NAME + ".class"); + Files.copy(testJar, userDir.resolve(ARCHIVE_NAME), REPLACE_EXISTING); + Files.copy(policy, userDir.resolve(POLICY_FILE), REPLACE_EXISTING); + Files.copy(testClass, userDir.resolve(TEST_NAME + ".class"), + REPLACE_EXISTING); + Files.createDirectories(userDir.resolve("tmp")); + } + + private static void runTest(ProcessBuilder pb) throws Exception { + System.out.println("Testing with command: [" + pb.command() + "]"); + ProcessTools.executeProcess(pb) + .outputTo(System.out) + .errorTo(System.err) + .shouldHaveExitValue(0); + } +} diff --git a/jdk/test/java/io/Serializable/class/SerialA_1.java b/jdk/test/java/net/URLClassLoader/getresourceasstream/policy similarity index 86% rename from jdk/test/java/io/Serializable/class/SerialA_1.java rename to jdk/test/java/net/URLClassLoader/getresourceasstream/policy index 536e2a1fbac..3a2f6b420a6 100644 --- a/jdk/test/java/io/Serializable/class/SerialA_1.java +++ b/jdk/test/java/net/URLClassLoader/getresourceasstream/policy @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,8 +21,6 @@ * questions. */ -import java.io.Serializable; - -public class A implements Serializable { - int field1; +grant { + permission java.lang.RuntimePermission "createClassLoader"; }; diff --git a/jdk/test/java/net/URLClassLoader/getresourceasstream/test.sh b/jdk/test/java/net/URLClassLoader/getresourceasstream/test.sh deleted file mode 100644 index 790017f0b0a..00000000000 --- a/jdk/test/java/net/URLClassLoader/getresourceasstream/test.sh +++ /dev/null @@ -1,71 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2004, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -set -x -# @test -# @bug 5103449 -# @run shell test.sh -# @summary REGRESSION: getResourceAsStream is broken in JDK1.5.0-rc -# - - -cat << POLICY > policy -grant { - permission java.lang.RuntimePermission "createClassLoader"; -}; -POLICY - -checkExit () { - if [ $? != 0 ]; then - exit $1; - fi -} - -${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}/Test.java -cp ${TESTSRC}/test.jar . - -${TESTJAVA}/bin/java ${TESTVMOPTS} Test ./test.jar -checkExit 1 - -# try with security manager - -${TESTJAVA}/bin/java ${TESTVMOPTS} -Djava.security.policy=file:./policy \ - -Djava.security.manager Test ./test.jar -checkExit 2 - -mkdir tmp -cd tmp -${TESTJAVA}/bin/java ${TESTVMOPTS} -Djava.security.policy=file:../policy \ - -cp .. -Djava.security.manager Test ../test.jar -checkExit 3 - -cd .. -THISDIR=$(basename $(pwd)) -cd .. -${TESTJAVA}/bin/java ${TESTVMOPTS} -Djava.security.policy=file:$THISDIR/policy \ - -cp $THISDIR -Djava.security.manager Test $THISDIR/test.jar -checkExit 4 - -exit 0 diff --git a/jdk/test/java/net/URLClassLoader/sealing/CheckSealed.java b/jdk/test/java/net/URLClassLoader/sealing/CheckSealed.java index 7805de0faeb..93f4cce3b6c 100644 --- a/jdk/test/java/net/URLClassLoader/sealing/CheckSealed.java +++ b/jdk/test/java/net/URLClassLoader/sealing/CheckSealed.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,13 +21,6 @@ * questions. */ -/* - * @test - * @bug 4244970 - * @summary Test to see if sealing violation is detected correctly - * @run shell checksealed.sh - * - */ public class CheckSealed { public static void main(String[] argv) throws Exception { diff --git a/jdk/test/java/net/URLClassLoader/sealing/CheckSealedTest.java b/jdk/test/java/net/URLClassLoader/sealing/CheckSealedTest.java new file mode 100644 index 00000000000..b733b678871 --- /dev/null +++ b/jdk/test/java/net/URLClassLoader/sealing/CheckSealedTest.java @@ -0,0 +1,93 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 4244970 + * @summary Test to see if sealing violation is detected correctly + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @run main CheckSealedTest + */ + +import jdk.test.lib.JDKToolFinder; +import jdk.test.lib.process.ProcessTools; + +import java.io.File; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.List; + +import static java.nio.file.StandardCopyOption.REPLACE_EXISTING; + +public class CheckSealedTest { + private static final String ARCHIVE_NAME = "b.jar"; + private static final String TEST_NAME = "CheckSealed"; + public static void main(String[] args) + throws Throwable { + + String baseDir = System.getProperty("user.dir") + File.separator; + String javac = JDKToolFinder.getTestJDKTool("javac"); + String java = JDKToolFinder.getTestJDKTool("java"); + + setup(baseDir); + String srcDir = System.getProperty("test.src"); + String cp = srcDir + File.separator + "a" + File.pathSeparator + + srcDir + File.separator + "b.jar" + File.pathSeparator + + "."; + List allCMDs = List.of( + // Compile command + new String[]{ + javac, "-cp", cp, "-d", ".", + srcDir + File.separator + TEST_NAME + ".java" + }, + // Run test the first time + new String[]{ + java, "-cp", cp, TEST_NAME, "1" + }, + // Run test the second time + new String[]{ + java, "-cp", cp, TEST_NAME, "2" + } + ); + + for (String[] cmd : allCMDs) { + ProcessTools.executeCommand(cmd) + .outputTo(System.out) + .errorTo(System.out) + .shouldHaveExitValue(0); + } + } + + private static void setup(String baseDir) throws IOException { + Path testJar = Paths.get(System.getProperty("test.src"), ARCHIVE_NAME); + Files.copy(testJar, Paths.get(baseDir, ARCHIVE_NAME), REPLACE_EXISTING); + } +} diff --git a/jdk/test/java/net/URLClassLoader/sealing/checksealed.sh b/jdk/test/java/net/URLClassLoader/sealing/checksealed.sh deleted file mode 100644 index 339525a1042..00000000000 --- a/jdk/test/java/net/URLClassLoader/sealing/checksealed.sh +++ /dev/null @@ -1,64 +0,0 @@ -#! /bin/sh - -# -# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# - -OS=`uname -s` -case "$OS" in - SunOS | Darwin | AIX ) - PS=":" - FS="/" - ;; - Linux ) - PS=":" - FS="/" - ;; - CYGWIN* ) - PS=";" - FS="/" - ;; - Windows* ) - PS=";" - FS="\\" - ;; - * ) - echo "Unrecognized system!" - exit 1; - ;; -esac - - -if [ x"$TESTJAVA" = x ]; then TESTJAVA=$1; fi -if [ x"$COMPILEJAVA" = x ]; then COMPILEJAVA=$1; fi -if [ x"$TESTSRC" = x ]; then TESTSRC=.; fi - -CLASSPATH=".${PS}${TESTSRC}${FS}a${PS}${TESTSRC}${FS}b.jar" - -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -classpath "${CLASSPATH}" -d . \ - ${TESTSRC}${FS}CheckSealed.java -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} -cp "${CLASSPATH}" CheckSealed 1 -if [ $? != 0 ]; then exit 1; fi -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} -cp "${CLASSPATH}" CheckSealed 2 -if [ $? != 0 ]; then exit 1; fi diff --git a/jdk/test/java/net/URLConnection/6212146/Test.java b/jdk/test/java/net/URLConnection/6212146/Test.java index 7f3adbf307b..1e33349b9dd 100644 --- a/jdk/test/java/net/URLConnection/6212146/Test.java +++ b/jdk/test/java/net/URLConnection/6212146/Test.java @@ -21,49 +21,43 @@ * questions. */ -import java.net.*; -import java.io.*; +import java.net.URL; +import java.net.URLConnection; +import java.nio.file.Paths; public class Test { public static void main(String[] args) throws Exception { - String BASE_DIR = args[0]; - String ARCHIVE_NAME = args[1]; - String lProperty = System.getProperty( "do.iterations", "5000" ); - int lRepetitions = new Integer( lProperty ).intValue(); - System.out.println ( "Start creating copys of the archive, " + lRepetitions + " times" ); - for( int i = 0; i < lRepetitions; i++ ) { - // Copy the given jar file and add a prefix - copyFile( BASE_DIR, ARCHIVE_NAME, i); + String baseDir = args[0]; + String archiveName = args[1]; + String lProperty = System.getProperty("do.iterations", "5000"); + int lRepetitions = Integer.valueOf(lProperty); + System.out.println("Start creating copys of the archive, " + + lRepetitions + " times"); + for (int i = 0; i < lRepetitions; i++) { + // Copy the given jar file and add a prefix + copyFile(baseDir, archiveName, i); + } + System.out.println("Start opening the archives archive, " + + lRepetitions + " times"); + System.out.println("First URL is jar:" + Paths.get(baseDir, + 0 + archiveName).toUri() + "!/foo/Test.class"); + for (int i = 0; i < lRepetitions; i++) { + // Create URL + String lURLPath = "jar:" + Paths.get(baseDir, i + + archiveName).toUri() + "!/foo/Test.class"; + URL lURL = new URL(lURLPath); + // Open URL Connection + try { + URLConnection lConnection = lURL.openConnection(); + lConnection.getInputStream(); + } catch (java.io.FileNotFoundException fnfe) { + // Ignore this one because we expect this one + } catch (java.util.zip.ZipException ze) { + throw new RuntimeException("Test failed: " + ze.getMessage()); + } } - System.out.println ( "Start opening the archives archive, " + lRepetitions + " times" ); - System.out.println ( "First URL is jar:file://" + BASE_DIR + "1" + ARCHIVE_NAME + "!/foo/Test.class"); - for( int i = 0; i < lRepetitions; i++ ) { - // Create ULR - String lURLPath = "jar:file://" + BASE_DIR + i + ARCHIVE_NAME + "!/foo/Test.class"; - URL lURL = new URL( lURLPath ); - // Open URL Connection - try { - URLConnection lConnection = lURL.openConnection(); - lConnection.getInputStream(); - } catch( java.io.FileNotFoundException fnfe ) { - // Ignore this one because we expect this one - } catch( java.util.zip.ZipException ze ) { - throw new RuntimeException ("Test failed: " + ze.getMessage()); - } - } - //System.out.println ( "Done testing, waiting 20 seconds for checking" ); - //System.out.println ( "Cleaning up"); - //for( int i = 0; i < lRepetitions; i++ ) { - // Copy the given jar file and add a prefix - //deleteFile( BASE_DIR, i, ARCHIVE_NAME); - ////} - } - - private static void deleteFile (String BASE_DIR, int pIndex, String pArchiveName) { - java.io.File file = new java.io.File (BASE_DIR, pIndex + pArchiveName ); - file.delete (); } private static void copyFile( String pBaseDir, String pArchiveName, int pIndex) { diff --git a/jdk/test/java/net/URLConnection/6212146/TestDriver.java b/jdk/test/java/net/URLConnection/6212146/TestDriver.java new file mode 100644 index 00000000000..d6bffb198de --- /dev/null +++ b/jdk/test/java/net/URLConnection/6212146/TestDriver.java @@ -0,0 +1,77 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 6212146 + * @summary URLConnection.connect() fails on JAR Entry it creates + * file handler leak + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * Test + * @run main/othervm TestDriver + */ + +import jdk.test.lib.JDKToolFinder; +import jdk.test.lib.process.ProcessTools; + +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; + +import static java.nio.file.StandardCopyOption.REPLACE_EXISTING; + +public class TestDriver { + private static final String BASE_DIR = System.getProperty("user.dir") + + "/jars/"; + private static final String ARCHIVE_NAME = "test.jar"; + private static final String CMD_ULIMIT = "ulimit -n 300;"; + + public static void main(String[] args) + throws Throwable { + setup(BASE_DIR); + String testCMD = CMD_ULIMIT + JDKToolFinder.getTestJDKTool("java") + + " Test " + BASE_DIR + " " + ARCHIVE_NAME; + boolean isWindows = System.getProperty("os.name").startsWith("Windows"); + if (isWindows) { + testCMD = testCMD.replace("\\", "/"); + } + ProcessTools.executeCommand("sh", "-c", testCMD) + .outputTo(System.out) + .errorTo(System.err) + .shouldHaveExitValue(0); + } + + private static void setup(String baseDir) throws IOException { + Path testJar = Paths.get(System.getProperty("test.src"), ARCHIVE_NAME); + Path targetDir = Paths.get(baseDir); + Files.createDirectories(targetDir); + Files.copy(testJar, targetDir.resolve(ARCHIVE_NAME), REPLACE_EXISTING); + } +} diff --git a/jdk/test/java/net/URLConnection/6212146/test.sh b/jdk/test/java/net/URLConnection/6212146/test.sh deleted file mode 100644 index 9a0615cadf3..00000000000 --- a/jdk/test/java/net/URLConnection/6212146/test.sh +++ /dev/null @@ -1,73 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2006, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# -# @test -# @run shell/timeout=380 test.sh -# @bug 6212146 -# @summary URLConnection.connect() fails on JAR Entry it creates file handler leak -# -# set platform-dependent variables - -OS=`uname -s` -case "$OS" in - SunOS | Darwin | AIX ) - PS=":" - FS="/" - ;; - Linux ) - PS=":" - FS="/" - ;; - CYGWIN* ) - PS=";" - FS="/" - ;; - Windows* ) - PS=";" - FS="\\" - ;; - * ) - echo "Unrecognized system!" - exit 1; - ;; -esac - -if [ -d jars ]; then - rm -rf jars -fi - -mkdir jars - -cp ${TESTSRC}${FS}test.jar jars - -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}${FS}Test.java - -WD=`pwd` -ulimit -H -n 300 -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} Test ${WD}/jars/ test.jar -result=$? -rm -rf jars -exit $? diff --git a/jdk/test/java/net/URLConnection/UNCTest.java b/jdk/test/java/net/URLConnection/UNCTest.java index 2e834f840b7..653b4c96699 100644 --- a/jdk/test/java/net/URLConnection/UNCTest.java +++ b/jdk/test/java/net/URLConnection/UNCTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,16 @@ * questions. */ -import java.net.*; +/** + * @test + * @bug 4401485 + * @requires (os.family == "windows") + * @summary Check that URL.openConnection() doesn't open connection to UNC + * @run main UNCTest file://jdk/LOCAL-JAVA/jdk1.4/win/README.txt + */ + +import java.net.URL; +import java.net.URLConnection; public class UNCTest { public static void main(String args[]) throws Exception { diff --git a/jdk/test/java/net/URLConnection/UNCTest.sh b/jdk/test/java/net/URLConnection/UNCTest.sh deleted file mode 100644 index 8030deb30e3..00000000000 --- a/jdk/test/java/net/URLConnection/UNCTest.sh +++ /dev/null @@ -1,47 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2001, 2002, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - - -# @test -# @bug 4401485 -# @run shell UNCTest.sh -# @summary Check that URL.openConnection() doesn't open connection -# to UNC. - -UNC="file://jdk/LOCAL-JAVA/jdk1.4/win/README.txt" - -OS=`uname -s` -case "$OS" in - Windows_95 | Windows_98 | Windows_NT ) - ${COMPILEJAVA}/bin/javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}\\UNCTest.java - ${TESTJAVA}/bin/java ${TESTVMOPTS} UNCTest ${UNC} - exit - ;; - - * ) - echo "This test is not intended for this OS - passing test" - exit 0 - ;; -esac diff --git a/jdk/test/java/net/httpclient/RequestBodyTest.java b/jdk/test/java/net/httpclient/RequestBodyTest.java index 446eb0324f5..637cbc31aff 100644 --- a/jdk/test/java/net/httpclient/RequestBodyTest.java +++ b/jdk/test/java/net/httpclient/RequestBodyTest.java @@ -26,10 +26,12 @@ * @modules jdk.incubator.httpclient * java.logging * jdk.httpserver - * @library /lib/testlibrary/ + * @library /lib/testlibrary/ /test/lib * @compile ../../../com/sun/net/httpserver/LogFilter.java * @compile ../../../com/sun/net/httpserver/EchoHandler.java * @compile ../../../com/sun/net/httpserver/FileServerHandler.java + * @build jdk.test.lib.Platform + * @build jdk.test.lib.util.FileUtils * @build LightWeightHttpServer * @build jdk.testlibrary.SimpleSSLContext * @run testng/othervm RequestBodyTest @@ -53,7 +55,7 @@ import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.function.Supplier; import javax.net.ssl.SSLContext; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; import static java.nio.charset.StandardCharsets.*; import static java.nio.file.StandardOpenOption.*; import static jdk.incubator.http.HttpRequest.BodyProcessor.*; diff --git a/jdk/test/java/net/ipv6tests/B6521014.java b/jdk/test/java/net/ipv6tests/B6521014.java index 5efa77d9663..6d5aa0b252a 100644 --- a/jdk/test/java/net/ipv6tests/B6521014.java +++ b/jdk/test/java/net/ipv6tests/B6521014.java @@ -25,15 +25,16 @@ * @test * @bug 6521014 6543428 * @summary IOException thrown when Socket tries to bind to an local IPv6 address on SuSE Linux - * @library /lib/testlibrary - * @build jdk.testlibrary.NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform * @run main B6521014 */ import java.net.*; import java.io.*; import java.util.*; -import jdk.testlibrary.NetworkConfiguration; +import jdk.test.lib.NetworkConfiguration; /* * diff --git a/jdk/test/java/net/spi/URLStreamHandlerProvider/Basic.java b/jdk/test/java/net/spi/URLStreamHandlerProvider/Basic.java index 6d287738eee..d5da7fa6621 100644 --- a/jdk/test/java/net/spi/URLStreamHandlerProvider/Basic.java +++ b/jdk/test/java/net/spi/URLStreamHandlerProvider/Basic.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -45,7 +45,7 @@ import javax.tools.JavaFileObject; import javax.tools.StandardJavaFileManager; import javax.tools.StandardLocation; import javax.tools.ToolProvider; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; import jdk.testlibrary.JDKToolFinder; import static java.lang.String.format; import static java.util.Arrays.asList; @@ -55,8 +55,10 @@ import static java.util.Arrays.asList; * @bug 8064924 * @modules jdk.compiler * @summary Basic test for URLStreamHandlerProvider - * @library /lib/testlibrary - * @build jdk.testlibrary.FileUtils jdk.testlibrary.JDKToolFinder + * @library /lib/testlibrary /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils + * jdk.testlibrary.JDKToolFinder * @compile Basic.java Child.java * @run main Basic */ diff --git a/jdk/test/java/nio/Buffer/LimitDirectMemory.java b/jdk/test/java/nio/Buffer/LimitDirectMemory.java index e8a22b4b89c..0036f5ea30b 100644 --- a/jdk/test/java/nio/Buffer/LimitDirectMemory.java +++ b/jdk/test/java/nio/Buffer/LimitDirectMemory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,6 +21,35 @@ * questions. */ +/* + * @test + * @bug 4627316 6743526 + * @summary Test option to limit direct memory allocation + * @requires (os.arch == "x86_64") | (os.arch == "amd64") | (os.arch == "sparcv9") + * @library /test/lib + * + * @summary Test: memory is properly limited using multiple buffers + * @run main/othervm -XX:MaxDirectMemorySize=10 LimitDirectMemory true 10 1 + * @run main/othervm -XX:MaxDirectMemorySize=1k LimitDirectMemory true 1k 100 + * @run main/othervm -XX:MaxDirectMemorySize=10m LimitDirectMemory true 10m 10m + * + * @summary Test: We can increase the amount of available memory + * @run main/othervm -XX:MaxDirectMemorySize=65M LimitDirectMemory false 64M 65M + * + * @summary Test: Exactly the default amount of memory is available + * @run main/othervm LimitDirectMemory false 10 1 + * @run main/othervm -Xmx64m LimitDirectMemory false 0 DEFAULT + * @run main/othervm -Xmx64m LimitDirectMemory true 0 DEFAULT+1 + * + * @summary Test: We should be able to eliminate direct memory allocation entirely + * @run main/othervm -XX:MaxDirectMemorySize=0 LimitDirectMemory true 0 1 + * + * @summary Test: Setting the system property should not work so we should be able + * to allocate the default amount + * @run main/othervm -Dsun.nio.MaxDirectMemorySize=1K -Xmx64m + * LimitDirectMemory false DEFAULT-1 DEFAULT/2 + */ + import java.nio.ByteBuffer; import java.util.Properties; @@ -28,8 +57,13 @@ public class LimitDirectMemory { private static final int K = 1024; public static void main(String [] args) throws Exception { - if (args.length < 2) - throw new RuntimeException(); + if (args.length < 2) { + throw new IllegalArgumentException("Usage: " + + "java LimitDirectMemory" + + " " + + " " + + " "); + } boolean throwp = parseThrow(args[0]); int size = parseSize(args[1]); int incr = (args.length > 2 ? parseSize(args[2]) : size); diff --git a/jdk/test/java/nio/Buffer/LimitDirectMemory.sh b/jdk/test/java/nio/Buffer/LimitDirectMemory.sh deleted file mode 100644 index 372dc0532db..00000000000 --- a/jdk/test/java/nio/Buffer/LimitDirectMemory.sh +++ /dev/null @@ -1,93 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4627316 6743526 -# @summary Test option to limit direct memory allocation -# -# @requires (os.arch == "x86_64") | (os.arch == "amd64") | (os.arch == "sparcv9") -# @build LimitDirectMemory -# @run shell LimitDirectMemory.sh - -TMP1=tmp_$$ - -runTest() { - echo "Testing: $*" - ${TESTJAVA}/bin/java ${TESTVMOPTS} $* - if [ $? -eq 0 ] - then echo "--- passed as expected" - else - echo "--- failed" - exit 1 - fi -} - - -launchFail() { - echo "Testing: -XX:MaxDirectMemorySize=$* -cp ${TESTCLASSES} \ - LimitDirectMemory true DEFAULT DEFAULT+1M" - ${TESTJAVA}/bin/java ${TESTVMOPTS} -XX:MaxDirectMemorySize=$* -cp ${TESTCLASSES} \ - LimitDirectMemory true DEFAULT DEFAULT+1M > ${TMP1} 2>&1 - cat ${TMP1} - cat ${TMP1} | grep -s "Unrecognized VM option: \'MaxDirectMemorySize=" - if [ $? -ne 0 ] - then echo "--- failed as expected" - else - echo "--- failed" - exit 1 - fi -} - -# $java LimitDirectMemory throwp fill_direct_memory size_per_buffer - -# Memory is properly limited using multiple buffers. -runTest -XX:MaxDirectMemorySize=10 -cp ${TESTCLASSES} LimitDirectMemory true 10 1 -runTest -XX:MaxDirectMemorySize=1k -cp ${TESTCLASSES} LimitDirectMemory true 1k 100 -runTest -XX:MaxDirectMemorySize=10m -cp ${TESTCLASSES} LimitDirectMemory true 10m 10m - -# We can increase the amount of available memory. -runTest -XX:MaxDirectMemorySize=65M -cp ${TESTCLASSES} \ - LimitDirectMemory false 64M 65M - -# Exactly the default amount of memory is available. -runTest -cp ${TESTCLASSES} LimitDirectMemory false 10 1 -runTest -Xmx64m -cp ${TESTCLASSES} LimitDirectMemory false 0 DEFAULT -runTest -Xmx64m -cp ${TESTCLASSES} LimitDirectMemory true 0 DEFAULT+1 - -# We should be able to eliminate direct memory allocation entirely. -runTest -XX:MaxDirectMemorySize=0 -cp ${TESTCLASSES} LimitDirectMemory true 0 1 - -# Setting the system property should not work so we should be able to allocate -# the default amount. -runTest -Dsun.nio.MaxDirectMemorySize=1K -Xmx64m -cp ${TESTCLASSES} \ - LimitDirectMemory false DEFAULT-1 DEFAULT/2 - -# Various bad values fail to launch the VM. -launchFail foo -launchFail 10kmt -launchFail -1 - -# Clean-up -rm ${TMP1} diff --git a/jdk/test/java/nio/Buffer/LimitDirectMemoryNegativeTest.java b/jdk/test/java/nio/Buffer/LimitDirectMemoryNegativeTest.java new file mode 100644 index 00000000000..af157136715 --- /dev/null +++ b/jdk/test/java/nio/Buffer/LimitDirectMemoryNegativeTest.java @@ -0,0 +1,63 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4627316 6743526 + * @summary Test option to limit direct memory allocation, + * various bad values fail to launch the VM + * @requires (os.arch == "x86_64") | (os.arch == "amd64") | (os.arch == "sparcv9") + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * + * @run main LimitDirectMemoryNegativeTest foo + * @run main LimitDirectMemoryNegativeTest 10kmt + * @run main LimitDirectMemoryNegativeTest -1 + */ + +import jdk.test.lib.process.ProcessTools; + +public class LimitDirectMemoryNegativeTest { + + private static final String ERR = "Improperly specified VM option 'MaxDirectMemorySize="; + + public static void main(String[] args) throws Exception { + if (args.length != 1) { + throw new IllegalArgumentException("missing size argument"); + } + + int exitCode = ProcessTools.executeTestJava( + "-XX:MaxDirectMemorySize=" + args[0], + LimitDirectMemoryNegativeTest.class.getName()) + .shouldContain(ERR + args[0]) + .getExitValue(); + if (exitCode != 1) { + throw new RuntimeException("Unexpected exit code: " + exitCode); + } + } +} diff --git a/jdk/test/java/nio/ByteOrder/NativeOrder.java b/jdk/test/java/nio/ByteOrder/NativeOrder.java index c44145dd664..d5f472454dd 100644 --- a/jdk/test/java/nio/ByteOrder/NativeOrder.java +++ b/jdk/test/java/nio/ByteOrder/NativeOrder.java @@ -32,12 +32,19 @@ public class NativeOrder { public static void main(String[] args) throws Exception { ByteOrder bo = ByteOrder.nativeOrder(); - System.err.println(bo); + System.err.println("ByteOrder.nativeOrder:" + bo); String arch = System.getProperty("os.arch"); + System.err.println("os.arch:" + arch); if (((arch.equals("i386") && (bo != ByteOrder.LITTLE_ENDIAN))) || + ((arch.equals("amd64") && (bo != ByteOrder.LITTLE_ENDIAN))) || + ((arch.equals("x86_64") && (bo != ByteOrder.LITTLE_ENDIAN))) || + ((arch.equals("ppc64") && (bo != ByteOrder.BIG_ENDIAN))) || + ((arch.equals("ppc64le") && (bo != ByteOrder.LITTLE_ENDIAN))) || + ((arch.equals("s390x") && (bo != ByteOrder.BIG_ENDIAN))) || ((arch.equals("sparc") && (bo != ByteOrder.BIG_ENDIAN)))) { throw new Exception("Wrong byte order"); } + System.err.println("test is OK"); } } diff --git a/jdk/test/java/nio/channels/AsynchronousChannelGroup/AsExecutor.java b/jdk/test/java/nio/channels/AsynchronousChannelGroup/AsExecutor.java index ec4cb09d61c..6accf29d38e 100644 --- a/jdk/test/java/nio/channels/AsynchronousChannelGroup/AsExecutor.java +++ b/jdk/test/java/nio/channels/AsynchronousChannelGroup/AsExecutor.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,13 +21,22 @@ * questions. */ -import java.nio.channels.AsynchronousChannelGroup; -import java.util.concurrent.*; - -/** - * Test that arbitrary tasks can be submitted to a channel group's thread pool. +/* + * @test + * @bug 4607272 + * @summary tests tasks can be submitted to a channel group's thread pool. + * @library /lib/testlibrary bootlib + * @build JarUtils PrivilegedThreadFactory Attack + * @run driver SetupJar + * @run main/othervm -Xbootclasspath/a:privileged.jar AsExecutor */ +import java.nio.channels.AsynchronousChannelGroup; +import java.util.concurrent.CountDownLatch; +import java.util.concurrent.Executor; +import java.util.concurrent.Executors; +import java.util.concurrent.ThreadFactory; + public class AsExecutor { public static void main(String[] args) throws Exception { diff --git a/jdk/test/java/nio/channels/AsynchronousChannelGroup/SetupJar.java b/jdk/test/java/nio/channels/AsynchronousChannelGroup/SetupJar.java new file mode 100644 index 00000000000..a50a3891f30 --- /dev/null +++ b/jdk/test/java/nio/channels/AsynchronousChannelGroup/SetupJar.java @@ -0,0 +1,34 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.nio.file.Path; +import java.nio.file.Paths; + +public class SetupJar { + + public static void main(String args[]) throws Exception { + Path classes = Paths.get(System.getProperty("test.classes", "")); + JarUtils.createJarFile(Paths.get("privileged.jar"), + classes.resolve("bootlib")); + } +} diff --git a/jdk/test/java/nio/channels/AsynchronousChannelGroup/Attack.java b/jdk/test/java/nio/channels/AsynchronousChannelGroup/bootlib/Attack.java similarity index 96% rename from jdk/test/java/nio/channels/AsynchronousChannelGroup/Attack.java rename to jdk/test/java/nio/channels/AsynchronousChannelGroup/bootlib/Attack.java index 7572b89b3f4..c0317632443 100644 --- a/jdk/test/java/nio/channels/AsynchronousChannelGroup/Attack.java +++ b/jdk/test/java/nio/channels/AsynchronousChannelGroup/bootlib/Attack.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2009, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,8 +21,8 @@ * questions. */ -import java.net.*; import java.io.IOException; +import java.net.Socket; import java.util.concurrent.CountDownLatch; /** diff --git a/jdk/test/java/nio/channels/AsynchronousChannelGroup/PrivilegedThreadFactory.java b/jdk/test/java/nio/channels/AsynchronousChannelGroup/bootlib/PrivilegedThreadFactory.java similarity index 100% rename from jdk/test/java/nio/channels/AsynchronousChannelGroup/PrivilegedThreadFactory.java rename to jdk/test/java/nio/channels/AsynchronousChannelGroup/bootlib/PrivilegedThreadFactory.java diff --git a/jdk/test/java/nio/channels/AsynchronousChannelGroup/run_any_task.sh b/jdk/test/java/nio/channels/AsynchronousChannelGroup/run_any_task.sh deleted file mode 100644 index f1631ce8434..00000000000 --- a/jdk/test/java/nio/channels/AsynchronousChannelGroup/run_any_task.sh +++ /dev/null @@ -1,52 +0,0 @@ -# -# Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4607272 -# @summary Unit test for AsynchronousChannelGrou#execute -# @build AsExecutor PrivilegedThreadFactory Attack -# @run shell run_any_task.sh - -# if TESTJAVA isn't set then we assume an interactive run. - -if [ -z "$TESTJAVA" ]; then - TESTSRC=. - TESTCLASSES=. - JAVA=java - JAR=jar -else - JAVA="${TESTJAVA}/bin/java" - JAR="${TESTJAVA}/bin/jar" -fi - -echo "Creating JAR file ..." -$JAR -cf "${TESTCLASSES}/Privileged.jar" \ - -C "${TESTCLASSES}" PrivilegedThreadFactory.class \ - -C "${TESTCLASSES}" PrivilegedThreadFactory\$1.class \ - -C "${TESTCLASSES}" Attack.class - -echo "Running test ..." -$JAVA ${TESTVMOPTS} \ - -Xbootclasspath/a:"${TESTCLASSES}/Privileged.jar" \ - -classpath "${TESTCLASSES}" \ - AsExecutor diff --git a/jdk/test/java/nio/channels/AsynchronousSocketChannel/Basic.java b/jdk/test/java/nio/channels/AsynchronousSocketChannel/Basic.java index 64861b4c865..0dc0318ab68 100644 --- a/jdk/test/java/nio/channels/AsynchronousSocketChannel/Basic.java +++ b/jdk/test/java/nio/channels/AsynchronousSocketChannel/Basic.java @@ -24,8 +24,8 @@ /* @test * @bug 4607272 6842687 6878369 6944810 7023403 * @summary Unit test for AsynchronousSocketChannel(use -Dseed=X to set PRNG seed) - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main Basic -skipSlowConnectTest * @key randomness intermittent */ @@ -40,7 +40,7 @@ import java.util.Random; import java.util.Set; import java.util.concurrent.*; import java.util.concurrent.atomic.*; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class Basic { private static final Random RAND = RandomFactory.getRandom(); diff --git a/jdk/test/java/nio/channels/DatagramChannel/BasicMulticastTests.java b/jdk/test/java/nio/channels/DatagramChannel/BasicMulticastTests.java index c60b6b7cd94..cb2d2c0f15d 100644 --- a/jdk/test/java/nio/channels/DatagramChannel/BasicMulticastTests.java +++ b/jdk/test/java/nio/channels/DatagramChannel/BasicMulticastTests.java @@ -24,7 +24,10 @@ /* @test * @bug 4527345 * @summary Unit test for DatagramChannel's multicast support - * @build BasicMulticastTests NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform + * BasicMulticastTests * @run main BasicMulticastTests */ @@ -34,6 +37,8 @@ import java.net.*; import java.util.*; import java.io.IOException; +import jdk.test.lib.NetworkConfiguration; + public class BasicMulticastTests { /** @@ -204,14 +209,14 @@ public class BasicMulticastTests { NetworkConfiguration config = NetworkConfiguration.probe(); - NetworkInterface nif = config.ip4Interfaces().iterator().next(); + NetworkInterface nif = config.ip4MulticastInterfaces().iterator().next(); InetAddress anySource = config.ip4Addresses(nif).iterator().next(); membershipKeyTests(nif, ip4Group, anySource); exceptionTests(nif); // re-run the membership key tests with IPv6 if available - Iterator iter = config.ip6Interfaces().iterator(); + Iterator iter = config.ip6MulticastInterfaces().iterator(); if (iter.hasNext()) { nif = iter.next(); anySource = config.ip6Addresses(nif).iterator().next(); diff --git a/jdk/test/java/nio/channels/DatagramChannel/MulticastSendReceiveTests.java b/jdk/test/java/nio/channels/DatagramChannel/MulticastSendReceiveTests.java index db061a833fc..7569d14f155 100644 --- a/jdk/test/java/nio/channels/DatagramChannel/MulticastSendReceiveTests.java +++ b/jdk/test/java/nio/channels/DatagramChannel/MulticastSendReceiveTests.java @@ -24,7 +24,10 @@ /* @test * @bug 4527345 7026376 6633549 * @summary Unit test for DatagramChannel's multicast support - * @build MulticastSendReceiveTests NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform + * MulticastSendReceiveTests * @run main MulticastSendReceiveTests * @run main/othervm -Djava.net.preferIPv4Stack=true MulticastSendReceiveTests * @key randomness @@ -36,6 +39,9 @@ import java.net.*; import static java.net.StandardProtocolFamily.*; import java.util.*; import java.io.IOException; +import java.util.stream.Collectors; + +import jdk.test.lib.NetworkConfiguration; public class MulticastSendReceiveTests { @@ -238,14 +244,15 @@ public class MulticastSendReceiveTests { // multicast groups used for the test InetAddress ip4Group = InetAddress.getByName("225.4.5.6"); InetAddress ip6Group = InetAddress.getByName("ff02::a"); - - for (NetworkInterface nif: config.ip4Interfaces()) { + for (NetworkInterface nif: config.ip4MulticastInterfaces() + .collect(Collectors.toList())) { InetAddress source = config.ip4Addresses(nif).iterator().next(); test(INET, nif, ip4Group, source); test(UNSPEC, nif, ip4Group, source); } - for (NetworkInterface nif: config.ip6Interfaces()) { + for (NetworkInterface nif: config.ip6MulticastInterfaces() + .collect(Collectors.toList())) { InetAddress source = config.ip6Addresses(nif).iterator().next(); test(INET6, nif, ip6Group, source); test(UNSPEC, nif, ip6Group, source); diff --git a/jdk/test/java/nio/channels/DatagramChannel/NetworkConfiguration.java b/jdk/test/java/nio/channels/DatagramChannel/NetworkConfiguration.java deleted file mode 100644 index f2d2567bb2a..00000000000 --- a/jdk/test/java/nio/channels/DatagramChannel/NetworkConfiguration.java +++ /dev/null @@ -1,101 +0,0 @@ -/* - * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -import java.net.*; -import java.util.*; -import java.io.IOException; - -/** - * Helper class for multicasting tests. - */ - -class NetworkConfiguration { - - private Map> ip4Interfaces; - private Map> ip6Interfaces; - - private NetworkConfiguration(Map> ip4Interfaces, - Map> ip6Interfaces) - { - this.ip4Interfaces = ip4Interfaces; - this.ip6Interfaces = ip6Interfaces; - } - - Iterable ip4Interfaces() { - return ip4Interfaces.keySet(); - } - - Iterable ip6Interfaces() { - return ip6Interfaces.keySet(); - } - - Iterable ip4Addresses(NetworkInterface nif) { - return ip4Interfaces.get(nif); - } - - Iterable ip6Addresses(NetworkInterface nif) { - return ip6Interfaces.get(nif); - } - - private static final boolean isMacOs = - System.getProperty("os.name").equals("Mac OS X"); - - static NetworkConfiguration probe() throws IOException { - Map> ip4Interfaces = - new HashMap>(); - Map> ip6Interfaces = - new HashMap>(); - - // find the interfaces that support IPv4 and IPv6 - List nifs = Collections - .list(NetworkInterface.getNetworkInterfaces()); - for (NetworkInterface nif: nifs) { - // ignore intertaces that are down or don't support multicast - if (!nif.isUp() || !nif.supportsMulticast() || nif.isLoopback() - || (isMacOs && nif.getName().contains("awdl"))) - continue; - - List addrs = Collections.list(nif.getInetAddresses()); - for (InetAddress addr: addrs) { - if (!addr.isAnyLocalAddress()) { - if (addr instanceof Inet4Address) { - List list = ip4Interfaces.get(nif); - if (list == null) { - list = new LinkedList(); - } - list.add(addr); - ip4Interfaces.put(nif, list); - } else if (addr instanceof Inet6Address) { - List list = ip6Interfaces.get(nif); - if (list == null) { - list = new LinkedList(); - } - list.add(addr); - ip6Interfaces.put(nif, list); - } - } - } - } - return new NetworkConfiguration(ip4Interfaces, ip6Interfaces); - } -} diff --git a/jdk/test/java/nio/channels/DatagramChannel/Promiscuous.java b/jdk/test/java/nio/channels/DatagramChannel/Promiscuous.java index 21c8c18440f..0ee99f155ad 100644 --- a/jdk/test/java/nio/channels/DatagramChannel/Promiscuous.java +++ b/jdk/test/java/nio/channels/DatagramChannel/Promiscuous.java @@ -25,7 +25,10 @@ * @bug 8014377 * @summary Test for interference when two sockets are bound to the same * port but joined to different multicast groups - * @build Promiscuous NetworkConfiguration + * @library /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform + * Promiscuous * @run main Promiscuous * @run main/othervm -Djava.net.preferIPv4Stack=true Promiscuous * @key randomness @@ -37,6 +40,9 @@ import java.net.*; import static java.net.StandardProtocolFamily.*; import java.util.*; import java.io.IOException; +import java.util.stream.Collectors; + +import jdk.test.lib.NetworkConfiguration; public class Promiscuous { @@ -208,7 +214,8 @@ public class Promiscuous { InetAddress ip4Group1 = InetAddress.getByName("225.4.5.6"); InetAddress ip4Group2 = InetAddress.getByName("225.4.6.6"); - for (NetworkInterface nif: config.ip4Interfaces()) { + for (NetworkInterface nif: config.ip4MulticastInterfaces() + .collect(Collectors.toList())) { InetAddress source = config.ip4Addresses(nif).iterator().next(); test(INET, nif, ip4Group1, ip4Group2); diff --git a/jdk/test/java/nio/channels/FileChannel/Transfer.java b/jdk/test/java/nio/channels/FileChannel/Transfer.java index 43d7202408c..9e2eeb49d72 100644 --- a/jdk/test/java/nio/channels/FileChannel/Transfer.java +++ b/jdk/test/java/nio/channels/FileChannel/Transfer.java @@ -25,8 +25,8 @@ * @bug 4434723 4482726 4559072 4795550 5081340 5103988 6984545 * @summary Test FileChannel.transferFrom and transferTo (use -Dseed=X to set PRNG seed) * @library .. - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run testng/timeout=300 Transfer * @key randomness */ @@ -51,7 +51,7 @@ import java.nio.channels.spi.SelectorProvider; import java.util.Random; import java.util.concurrent.TimeUnit; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; import org.testng.annotations.Test; diff --git a/jdk/test/java/nio/channels/Selector/LotsOfUpdates.java b/jdk/test/java/nio/channels/Selector/LotsOfUpdates.java index 97c2e49bf73..9cf380bd038 100644 --- a/jdk/test/java/nio/channels/Selector/LotsOfUpdates.java +++ b/jdk/test/java/nio/channels/Selector/LotsOfUpdates.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,8 +21,10 @@ * questions. */ -import java.nio.channels.*; import java.io.IOException; +import java.nio.channels.SelectionKey; +import java.nio.channels.Selector; +import java.nio.channels.SocketChannel; public class LotsOfUpdates { public static void main(String[] args) throws IOException { diff --git a/jdk/test/java/nio/channels/Selector/LotsOfUpdatesTest.java b/jdk/test/java/nio/channels/Selector/LotsOfUpdatesTest.java new file mode 100644 index 00000000000..ef2c389ef39 --- /dev/null +++ b/jdk/test/java/nio/channels/Selector/LotsOfUpdatesTest.java @@ -0,0 +1,55 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 6824477 + * @summary Selector.select can fail with IOException "Invalid argument" on + * Solaris if maximum number of file descriptors is less than 10000 + * @requires (os.family != "windows") + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * LotsOfUpdates + * @run main LotsOfUpdatesTest + */ + +import jdk.test.lib.process.ProcessTools; + +public class LotsOfUpdatesTest { + + //hard limit needs to be less than 10000 for this bug + private static final String ULIMIT_SET_CMD = "ulimit -n 2048"; + + private static final String JAVA_CMD = ProcessTools.getCommandLine( + ProcessTools.createJavaProcessBuilder(LotsOfUpdates.class.getName())); + + public static void main(String[] args) throws Throwable { + ProcessTools.executeCommand("sh", "-c", ULIMIT_SET_CMD + " && " + JAVA_CMD) + .shouldHaveExitValue(0); + } +} diff --git a/jdk/test/java/nio/channels/Selector/lots_of_updates.sh b/jdk/test/java/nio/channels/Selector/lots_of_updates.sh deleted file mode 100644 index a34ab99e2b0..00000000000 --- a/jdk/test/java/nio/channels/Selector/lots_of_updates.sh +++ /dev/null @@ -1,49 +0,0 @@ -# -# Copyright (c) 2009, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 6824477 -# @summary Selector.select can fail with IOException "Invalid argument" on -# Solaris if maximum number of file descriptors is less than 10000 -# @build LotsOfUpdates -# @run shell lots_of_updates.sh - -OS=`uname -s` -case "$OS" in - Windows_* | CYGWIN* ) - echo "ulimit not on Windows" - exit 0 - ;; - * ) - CLASSPATH=${TESTCLASSES}:${TESTSRC} - ;; -esac -export CLASSPATH - -# hard limit needs to be less than 10000 for this bug -NOFILES=`ulimit -n -H` -if [ "$NOFILES" = "unlimited" ] || [ $NOFILES -ge 10000 ]; then - ulimit -n 2048 -fi - -${TESTJAVA}/bin/java ${TESTVMOPTS} LotsOfUpdates diff --git a/jdk/test/java/nio/channels/SocketChannel/Open.java b/jdk/test/java/nio/channels/SocketChannel/Open.java index 6bcf487f594..d937ae16956 100644 --- a/jdk/test/java/nio/channels/SocketChannel/Open.java +++ b/jdk/test/java/nio/channels/SocketChannel/Open.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2007, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,16 +21,11 @@ * questions. */ -/* @test - * @bug 4614065 - * @summary Test SocketChannel gc after running out of fds - * @build Open - * @run shell Open.sh - */ - -import java.net.*; -import java.nio.*; -import java.nio.channels.*; +import java.net.SocketException; +import java.nio.channels.DatagramChannel; +import java.nio.channels.Pipe; +import java.nio.channels.ServerSocketChannel; +import java.nio.channels.SocketChannel; import java.nio.channels.spi.SelectorProvider; public class Open { diff --git a/jdk/test/java/nio/channels/SocketChannel/Open.sh b/jdk/test/java/nio/channels/SocketChannel/Open.sh deleted file mode 100644 index 283bacce92d..00000000000 --- a/jdk/test/java/nio/channels/SocketChannel/Open.sh +++ /dev/null @@ -1,35 +0,0 @@ -#! /bin/sh - -# -# Copyright (c) 2002, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# - - OS=`uname -s` - case "$OS" in - SunOS ) - ulimit -n 100 - $TESTJAVA/bin/java ${TESTVMOPTS} -classpath $TESTCLASSES Open ;; - * ) - echo "unrecognized system: $OS" ;; - esac diff --git a/hotspot/test/runtime/NMT/AutoshutdownNMT.java b/jdk/test/java/nio/channels/SocketChannel/OpenSocketChannelTest.java similarity index 59% rename from hotspot/test/runtime/NMT/AutoshutdownNMT.java rename to jdk/test/java/nio/channels/SocketChannel/OpenSocketChannelTest.java index d07103e810c..44fc55fba3e 100644 --- a/hotspot/test/runtime/NMT/AutoshutdownNMT.java +++ b/jdk/test/java/nio/channels/SocketChannel/OpenSocketChannelTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,25 +23,26 @@ /* * @test - * @key nmt - * @summary Test for deprecated message if -XX:-AutoShutdownNMT is specified + * @bug 4614065 + * @summary Test SocketChannel gc after running out of fds + * @requires (os.family == "solaris") * @library /test/lib - * @modules java.base/jdk.internal.misc - * java.management + * @build Open + * @run main OpenSocketChannelTest */ import jdk.test.lib.process.ProcessTools; -import jdk.test.lib.process.OutputAnalyzer; -public class AutoshutdownNMT { +public class OpenSocketChannelTest { - public static void main(String args[]) throws Exception { + //hard limit needs to be small for this bug + private static final String ULIMIT_SET_CMD = "ulimit -n 100"; - ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( - "-XX:NativeMemoryTracking=detail", - "-XX:-AutoShutdownNMT", - "-version"); - OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("Ignoring option AutoShutdownNMT"); + private static final String JAVA_CMD = ProcessTools.getCommandLine( + ProcessTools.createJavaProcessBuilder(Open.class.getName())); + + public static void main(String[] args) throws Throwable { + ProcessTools.executeCommand("sh", "-c", ULIMIT_SET_CMD + " && " + JAVA_CMD) + .shouldHaveExitValue(0); } } diff --git a/jdk/test/java/nio/channels/SocketChannel/VectorIO.java b/jdk/test/java/nio/channels/SocketChannel/VectorIO.java index 8f585afb21a..4e5f17d27c8 100644 --- a/jdk/test/java/nio/channels/SocketChannel/VectorIO.java +++ b/jdk/test/java/nio/channels/SocketChannel/VectorIO.java @@ -23,8 +23,8 @@ /* @test * @summary Test socketchannel vector IO (use -Dseed=X to set PRNG seed) - * @library .. /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library .. /test/lib + * @build jdk.test.lib.RandomFactory * @run main VectorIO * @key randomness */ @@ -34,7 +34,7 @@ import java.net.*; import java.nio.*; import java.nio.channels.*; import java.util.*; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class VectorIO { diff --git a/jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/run_tests.sh b/jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/run_tests.sh index 9b01503fe5d..cc227b02910 100644 --- a/jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/run_tests.sh +++ b/jdk/test/java/nio/channels/spi/SelectorProvider/inheritedChannel/run_tests.sh @@ -47,12 +47,7 @@ if [ -z "$TESTJAVA" ]; then TESTCLASSES=`pwd` JAVA=java which $JAVA - ${JAVA} -d64 -version > /dev/null 2<&1 - if [ $? = 1 ]; then ${JAVA} -version - else - ${JAVA} -d64 -version - fi else JAVA="${TESTJAVA}/bin/java" fi diff --git a/jdk/test/java/nio/file/FileStore/Basic.java b/jdk/test/java/nio/file/FileStore/Basic.java index c2b482d8fbd..bc33002b70c 100644 --- a/jdk/test/java/nio/file/FileStore/Basic.java +++ b/jdk/test/java/nio/file/FileStore/Basic.java @@ -25,9 +25,9 @@ * @bug 4313887 6873621 6979526 7006126 7020517 * @summary Unit test for java.nio.file.FileStore * @key intermittent - * @library .. - * @library .. /lib/testlibrary - * @build jdk.testlibrary.FileUtils + * @library .. /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @run main Basic */ @@ -35,8 +35,8 @@ import java.nio.file.*; import java.nio.file.attribute.*; import java.io.File; import java.io.IOException; -import java.util.*; -import jdk.testlibrary.FileUtils; + +import jdk.test.lib.util.FileUtils; public class Basic { diff --git a/jdk/test/java/nio/file/FileSystem/Basic.java b/jdk/test/java/nio/file/FileSystem/Basic.java index bc4c77b021b..83f2acbe9ce 100644 --- a/jdk/test/java/nio/file/FileSystem/Basic.java +++ b/jdk/test/java/nio/file/FileSystem/Basic.java @@ -24,8 +24,9 @@ /* @test * @bug 4313887 6838333 8132497 * @summary Unit test for java.nio.file.FileSystem - * @library .. /lib/testlibrary - * @build jdk.testlibrary.FileUtils + * @library .. /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @run main/othervm Basic */ @@ -41,7 +42,7 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.nio.file.ProviderNotFoundException; import java.util.HashMap; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; /** * Simple sanity checks for java.nio.file.FileSystem diff --git a/jdk/test/java/nio/file/Files/CopyAndMove.java b/jdk/test/java/nio/file/Files/CopyAndMove.java index 80f35b88960..ce9f681d4f7 100644 --- a/jdk/test/java/nio/file/Files/CopyAndMove.java +++ b/jdk/test/java/nio/file/Files/CopyAndMove.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,8 +24,9 @@ /* @test * @bug 4313887 6838333 6917021 7006126 6950237 8006645 * @summary Unit test for java.nio.file.Files copy and move methods (use -Dseed=X to set PRNG seed) - * @library .. /lib/testlibrary/ - * @build jdk.testlibrary.* CopyAndMove PassThroughFileSystem + * @library .. /test/lib + * @build jdk.test.lib.RandomFactory + * CopyAndMove PassThroughFileSystem * @run main/othervm CopyAndMove * @key randomness */ @@ -39,7 +40,7 @@ import java.nio.file.attribute.*; import java.io.*; import java.util.*; import java.util.concurrent.TimeUnit; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class CopyAndMove { static final Random rand = RandomFactory.getRandom(); diff --git a/jdk/test/java/nio/file/Files/DeleteOnClose.java b/jdk/test/java/nio/file/Files/DeleteOnClose.java index 40310ee4eae..f5fab1c5be2 100644 --- a/jdk/test/java/nio/file/Files/DeleteOnClose.java +++ b/jdk/test/java/nio/file/Files/DeleteOnClose.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,20 +21,60 @@ * questions. */ -import java.nio.file.*; -import static java.nio.file.StandardOpenOption.*; -import java.io.*; -import java.util.*; +/* + * @test + * @bug 4313887 + * @summary Unit test for DELETE_ON_CLOSE open option + * @library /test/lib .. + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @run main DeleteOnClose + */ + +import java.io.IOException; +import java.nio.file.DirectoryStream; +import java.nio.file.Files; +import java.nio.file.OpenOption; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.nio.file.SecureDirectoryStream; +import java.util.HashSet; +import java.util.Set; + +import jdk.test.lib.process.ProcessTools; + +import static java.nio.file.StandardOpenOption.READ; +import static java.nio.file.StandardOpenOption.WRITE; +import static java.nio.file.StandardOpenOption.DELETE_ON_CLOSE; public class DeleteOnClose { - public static void main(String[] args) throws IOException { - // open file but do not close it. Its existance will be checked by - // the calling script. - Files.newByteChannel(Paths.get(args[0]), READ, WRITE, DELETE_ON_CLOSE); + public static void main(String[] args) throws Exception { + if (args.length == 0) { + Path file = Files.createTempFile("blah", "tmp"); + ProcessTools.executeTestJava(DeleteOnClose.class.getName(), + file.toAbsolutePath().toString()) + .shouldHaveExitValue(0); + runTest(file); + } else { + // open file but do not close it. Its existance will be checked by + // the caller. + Files.newByteChannel(Paths.get(args[0]), READ, WRITE, DELETE_ON_CLOSE); + } + } + + public static void runTest(Path path) throws Exception { + // check temporary file has been deleted after jvm termination + if (Files.exists(path)) { + throw new RuntimeException("Temporary file was not deleted"); + } // check temporary file has been deleted after closing it - Path file = Files.createTempFile("blah", "tmp"); + Path file = Files.createTempFile("blep", "tmp"); Files.newByteChannel(file, READ, WRITE, DELETE_ON_CLOSE).close(); if (Files.exists(file)) throw new RuntimeException("Temporary file was not deleted"); diff --git a/jdk/test/java/nio/file/Files/StreamLinesTest.java b/jdk/test/java/nio/file/Files/StreamLinesTest.java index aa4c9ba3220..402b114ae0b 100644 --- a/jdk/test/java/nio/file/Files/StreamLinesTest.java +++ b/jdk/test/java/nio/file/Files/StreamLinesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,9 @@ /* @test * @bug 8072773 - * @library /lib/testlibrary/ ../../../util/stream/bootlib + * @library /test/lib /lib/testlibrary/bootlib * @build java.base/java.util.stream.OpTestCase - * @build jdk.testlibrary.RandomFactory + * jdk.test.lib.RandomFactory * @run testng/othervm StreamLinesTest * @summary Tests streams returned from Files.lines, primarily focused on * testing the file-channel-based stream stream with supported @@ -54,7 +54,7 @@ import java.util.function.Supplier; import java.util.stream.OpTestCase; import java.util.stream.Stream; import java.util.stream.TestData; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class StreamLinesTest extends OpTestCase { diff --git a/jdk/test/java/nio/file/Files/delete_on_close.sh b/jdk/test/java/nio/file/Files/delete_on_close.sh deleted file mode 100644 index f07f71446fb..00000000000 --- a/jdk/test/java/nio/file/Files/delete_on_close.sh +++ /dev/null @@ -1,61 +0,0 @@ -# -# Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4313887 -# @summary Unit test for DELETE_ON_CLOSE open option -# @library .. -# @build DeleteOnClose -# @run shell delete_on_close.sh - -# if TESTJAVA isn't set then we assume an interactive run. - -if [ -z "$TESTJAVA" ]; then - TESTSRC=. - TESTCLASSES=. - JAVA=java -else - JAVA="${TESTJAVA}/bin/java" -fi - -OS=`uname -s` -case "$OS" in - Windows_* | CYGWIN* ) - CLASSPATH="${TESTCLASSES};${TESTSRC}" - ;; - * ) - CLASSPATH=${TESTCLASSES}:${TESTSRC} - ;; -esac -export CLASSPATH - -TMPFILE="$$.tmp" -touch $TMPFILE -$JAVA ${TESTVMOPTS} DeleteOnClose $TMPFILE 2>&1 -if [ $? != 0 ]; then exit 1; fi -if [ -f $TMPFILE ]; then - echo "$TMPFILE was not deleted" - exit 1 -fi - -exit 0 diff --git a/jdk/test/java/nio/file/Files/walkFileTree/FindTest.java b/jdk/test/java/nio/file/Files/walkFileTree/FindTest.java new file mode 100644 index 00000000000..9fb16a7b14c --- /dev/null +++ b/jdk/test/java/nio/file/Files/walkFileTree/FindTest.java @@ -0,0 +1,172 @@ +/* + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4313887 6907737 + * @summary Tests that walkFileTree is consistent with the native find program + * @requires (os.family != "windows") + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * CreateFileTree + * @run testng/othervm -Djava.io.tmpdir=. FindTest + */ + +import java.io.IOException; +import java.nio.file.FileSystemLoopException; +import java.nio.file.FileVisitOption; +import java.nio.file.FileVisitResult; +import java.nio.file.FileVisitor; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.attribute.BasicFileAttributes; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Random; +import java.util.Set; +import java.util.stream.Collectors; + +import jdk.test.lib.process.OutputAnalyzer; +import jdk.test.lib.process.ProcessTools; + +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import static org.testng.Assert.assertEquals; +import static org.testng.Assert.assertTrue; + +public class FindTest { + + private static final Random rand = new Random(); + private static final boolean isAIX = System.getProperty("os.name").equals("AIX"); + private static Path top; + private static String TOP; + + @BeforeClass + public static void createFileTree() throws Exception { + top = CreateFileTree.create(); + TOP = top.toAbsolutePath().toString(); + } + + @Test + public void printTreeTest() throws Throwable { + // print the file tree and compare output with find(1) + assertOutputEquals(printFileTree(top), runFind("find", TOP)); + } + + @Test + public void printTreeFollowLinkTest() throws Throwable { + // print the file tree, following links, and compare output with find(1). + + // On AIX "find -follow" may core dump on recursive links without '-L' + // see: http://www-01.ibm.com/support/docview.wss?uid=isg1IV28143 + String[] cmds = isAIX + ? new String[]{"find", "-L", TOP, "-follow"} + : new String[]{"find", TOP, "-follow"}; + OutputAnalyzer expected = runFind(cmds); + + // Some versions of find(1) output cycles (sym links to ancestor + // directories), other versions do not. For that reason we run + // PrintFileTree with the -printCycles option when the output without + // this option differs to find(1). + try { + assertOutputEquals(printFileTree(top, "-follow"), expected); + } catch (AssertionError x) { + assertOutputEquals(printFileTree(top, "-follow", "-printCycles"), expected); + } + } + + private void assertOutputEquals(List actual, OutputAnalyzer expected) + throws IOException { + List expectedList = Arrays.asList(expected.getStdout() + .split(System.lineSeparator())); + assertEquals(actual.size(), expectedList.size()); + assertTrue(actual.removeAll(expectedList)); + } + + private OutputAnalyzer runFind(String... cmds) throws Throwable { + return ProcessTools.executeCommand(cmds); + } + + /** + * Invokes Files.walkFileTree to traverse a file tree and prints + * each of the directories and files. The -follow option causes symbolic + * links to be followed and the -printCycles option will print links + * where the target of the link is an ancestor directory. + */ + private static List printFileTree(Path dir, String... opts) throws Exception { + List fileTreeList = new ArrayList<>(); + + List optsList = Arrays.asList(opts); + boolean followLinks = optsList.contains("-follow"); + boolean reportCycles = optsList.contains("-printCycles"); + + Set options = new HashSet<>(); + if (followLinks) + options.add(FileVisitOption.FOLLOW_LINKS); + + Files.walkFileTree(dir, options, Integer.MAX_VALUE, new FileVisitor() { + @Override + public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs) { + fileTreeList.add(dir); + return FileVisitResult.CONTINUE; + } + @Override + public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) { + fileTreeList.add(file); + return FileVisitResult.CONTINUE; + } + @Override + public FileVisitResult postVisitDirectory(Path dir, IOException exc) + throws IOException + { + if (exc != null) + throw exc; + return FileVisitResult.CONTINUE; + } + @Override + public FileVisitResult visitFileFailed(Path file, IOException exc) + throws IOException + { + if (followLinks && (exc instanceof FileSystemLoopException)) { + if (reportCycles) + fileTreeList.add(file); + return FileVisitResult.CONTINUE; + } else { + throw exc; + } + } + }); + + return fileTreeList.stream() + .map(f -> f.toAbsolutePath().toString()) + .collect(Collectors.toCollection(ArrayList::new)); + } +} diff --git a/jdk/test/java/nio/file/Files/walkFileTree/PrintFileTree.java b/jdk/test/java/nio/file/Files/walkFileTree/PrintFileTree.java deleted file mode 100644 index 11fec7cd6a0..00000000000 --- a/jdk/test/java/nio/file/Files/walkFileTree/PrintFileTree.java +++ /dev/null @@ -1,92 +0,0 @@ -/* - * Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -import java.nio.file.*; -import java.nio.file.attribute.*; -import java.io.IOException; -import java.util.*; - -/** - * Invokes Files.walkFileTree to traverse a file tree and prints - * each of the directories and files. The -follow option causes symbolic - * links to be followed and the -printCycles option will print links - * where the target of the link is an ancestor directory. - */ - -public class PrintFileTree { - - public static void main(String[] args) throws Exception { - boolean followLinks = false; - boolean printCycles = false; - int i = 0; - while (i < (args.length-1)) { - switch (args[i]) { - case "-follow" : followLinks = true; break; - case "-printCycles" : printCycles = true; break; - default: - throw new RuntimeException(args[i] + " not recognized"); - } - i++; - } - Path dir = Paths.get(args[i]); - - Set options = new HashSet(); - if (followLinks) - options.add(FileVisitOption.FOLLOW_LINKS); - - final boolean follow = followLinks; - final boolean reportCycles = printCycles; - Files.walkFileTree(dir, options, Integer.MAX_VALUE, new FileVisitor() { - @Override - public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs) { - System.out.println(dir); - return FileVisitResult.CONTINUE; - } - @Override - public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) { - System.out.println(file); - return FileVisitResult.CONTINUE; - } - @Override - public FileVisitResult postVisitDirectory(Path dir, IOException exc) - throws IOException - { - if (exc != null) - throw exc; - return FileVisitResult.CONTINUE; - } - @Override - public FileVisitResult visitFileFailed(Path file, IOException exc) - throws IOException - { - if (follow && (exc instanceof FileSystemLoopException)) { - if (reportCycles) - System.out.println(file); - return FileVisitResult.CONTINUE; - } else { - throw exc; - } - } - }); - } -} diff --git a/jdk/test/java/nio/file/Files/walkFileTree/find.sh b/jdk/test/java/nio/file/Files/walkFileTree/find.sh deleted file mode 100644 index 1bf7621226b..00000000000 --- a/jdk/test/java/nio/file/Files/walkFileTree/find.sh +++ /dev/null @@ -1,93 +0,0 @@ -# -# Copyright (c) 2008, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4313887 6907737 -# @summary Tests that walkFileTree is consistent with the native find program -# @build CreateFileTree PrintFileTree -# @run shell find.sh - -# if TESTJAVA isn't set then we assume an interactive run. - -if [ -z "$TESTJAVA" ]; then - TESTSRC=. - TESTCLASSES=. - JAVA=java -else - JAVA="${TESTJAVA}/bin/java" -fi - -OS=`uname -s` -case "$OS" in - Windows_* | CYGWIN* ) - echo "This test does not run on Windows" - exit 0 - ;; - AIX ) - CLASSPATH=${TESTCLASSES}:${TESTSRC} - # On AIX "find -follow" may core dump on recursive links without '-L' - # see: http://www-01.ibm.com/support/docview.wss?uid=isg1IV28143 - FIND_FOLLOW_OPT="-L" - ;; - * ) - FIND_FOLLOW_OPT= - CLASSPATH=${TESTCLASSES}:${TESTSRC} - ;; -esac -export CLASSPATH - -# create the file tree -ROOT=`$JAVA CreateFileTree` -if [ $? != 0 ]; then exit 1; fi - -failures=0 - -# print the file tree and compare output with find(1) -$JAVA ${TESTVMOPTS} PrintFileTree "$ROOT" > out1 -find "$ROOT" > out2 -diff out1 out2 -if [ $? != 0 ]; then failures=`expr $failures + 1`; fi - -# repeat test following links. Some versions of find(1) output -# cycles (sym links to ancestor directories), other versions do -# not. For that reason we run PrintFileTree with the -printCycles -# option when the output without this option differs to find(1). -find $FIND_FOLLOW_OPT "$ROOT" -follow > out1 -$JAVA ${TESTVMOPTS} PrintFileTree -follow "$ROOT" > out2 -diff out1 out2 -if [ $? != 0 ]; - then - # re-run printing cycles to stdout - $JAVA ${TESTVMOPTS} PrintFileTree -follow -printCycles "$ROOT" > out2 - diff out1 out2 - if [ $? != 0 ]; then failures=`expr $failures + 1`; fi - fi - -# clean-up -rm -r "$ROOT" - -echo '' -if [ $failures -gt 0 ]; - then echo "$failures test(s) failed"; - else echo "Test passed"; fi -exit $failures diff --git a/jdk/test/java/nio/file/WatchService/LotsOfEvents.java b/jdk/test/java/nio/file/WatchService/LotsOfEvents.java index 6990c1e8d89..d882adae4db 100644 --- a/jdk/test/java/nio/file/WatchService/LotsOfEvents.java +++ b/jdk/test/java/nio/file/WatchService/LotsOfEvents.java @@ -25,8 +25,8 @@ * @bug 6907760 6929532 * @summary Tests WatchService behavior when lots of events are pending (use -Dseed=X to set PRNG seed) * @library .. - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main/timeout=180 LotsOfEvents * @key randomness */ @@ -37,7 +37,7 @@ import java.nio.file.*; import static java.nio.file.StandardWatchEventKinds.*; import java.util.*; import java.util.concurrent.TimeUnit; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class LotsOfEvents { diff --git a/jdk/test/java/rmi/module/ModuleTest.java b/jdk/test/java/rmi/module/ModuleTest.java index be0b2184d28..08fa2cdc4c3 100644 --- a/jdk/test/java/rmi/module/ModuleTest.java +++ b/jdk/test/java/rmi/module/ModuleTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,9 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @build jdk.testlibrary.ProcessTools - * ModuleTest CompilerUtils JarUtils + * ModuleTest jdk.test.lib.compiler.CompilerUtils JarUtils * @run testng ModuleTest * @summary Basic tests for using rmi in module world */ @@ -36,6 +36,7 @@ import static org.testng.Assert.assertTrue; import java.io.File; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; diff --git a/jdk/test/java/security/AccessController/DoPrivAccompliceTest.java b/jdk/test/java/security/AccessController/DoPrivAccompliceTest.java index 6ed63d9d729..711c3030dde 100644 --- a/jdk/test/java/security/AccessController/DoPrivAccompliceTest.java +++ b/jdk/test/java/security/AccessController/DoPrivAccompliceTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,76 +23,96 @@ * questions. */ -import java.io.File; +import jdk.test.lib.process.OutputAnalyzer; +import jdk.test.lib.process.ProcessTools; +import jdk.test.lib.util.JarUtils; + import java.io.FileWriter; import java.io.IOException; -import java.net.URI; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; +import java.nio.file.Path; +import java.nio.file.Paths; /* * @test * @bug 8048362 - * @compile ../../../lib/testlibrary/JavaToolUtils.java - * DoPrivAccomplice.java DoPrivTest.java * @summary Tests the doPrivileged with accomplice Generate two jars * (DoPrivTest.jar and DoPrivAccomplice.jar) and grant permission to - * DoPrivAccmplice.jar for reading user.home property from a PrivilagedAction. - * Run DoPrivTest.jar and try to access user.home property using + * DoPrivAccmplice.jar for reading user.name property from a PrivilagedAction. + * Run DoPrivTest.jar and try to access user.name property using * DoPrivAccmplice.jar. - * @modules jdk.compiler + * + * @library /test/lib + * @build jdk.test.lib.util.JarUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main/othervm DoPrivAccompliceTest */ public class DoPrivAccompliceTest { + private static final String ACTION_SOURCE = DoPrivAccomplice.class.getName(); + private static final String TEST_SOURCE = DoPrivTest.class.getName(); - private static final String PWD = System.getProperty("test.classes", "./"); - private static final String ACTION_SOURCE = "DoPrivAccomplice"; - private static final String TEST_SOURCE = "DoPrivTest"; - - public static void createPolicyFile(URI codebaseURL) throws IOException { - String codebase = codebaseURL.toString(); + private static void createPolicyFile(Path jarFile, Path policy) { + String codebase = jarFile.toFile().toURI().toString(); String quotes = "\""; StringBuilder policyFile = new StringBuilder(); - policyFile.append("grant codeBase ").append(quotes). - append(codebase).append(quotes).append("{\n"). - append("permission java.util.PropertyPermission "). - append(quotes).append("user.name").append(quotes). - append(",").append(quotes).append("read").append(quotes). - append(";\n};"); - try (FileWriter writer = new FileWriter(new File(PWD, "java.policy"))) { + policyFile.append("grant codeBase ") + .append(quotes).append(codebase).append(quotes) + .append("{\n") + .append("permission java.util.PropertyPermission ") + .append(quotes).append("user.name").append(quotes) + .append(",") + .append(quotes).append("read").append(quotes) + .append(";\n};"); + try (FileWriter writer = new FileWriter(policy.toFile())) { writer.write(policyFile.toString()); - writer.close(); } catch (IOException e) { - System.err.println("Error while creating policy file"); - throw e; + throw new Error("Error while creating policy file " + policy, e); } } public static void main(String[] args) throws Exception { - final File class1 = new File(PWD, ACTION_SOURCE + ".class"); - final File class2 = new File(PWD, TEST_SOURCE + ".class"); - final File jarFile1 = new File(PWD, ACTION_SOURCE + ".jar"); - final File jarFile2 = new File(PWD, TEST_SOURCE + ".jar"); - System.out.println("Compilation successfull"); - JavaToolUtils.createJar(jarFile1, Arrays.asList(new File[]{class1})); + // copy class files to pwd + ClassFileInstaller.main(ACTION_SOURCE, TEST_SOURCE); + Path pwd = Paths.get("."); + Path jarFile1 = pwd.resolve(ACTION_SOURCE + ".jar").toAbsolutePath(); + Path jarFile2 = pwd.resolve(TEST_SOURCE + ".jar").toAbsolutePath(); + Path policy = pwd.resolve("java.policy").toAbsolutePath(); + + JarUtils.createJar(jarFile1.toString(), ACTION_SOURCE + ".class"); System.out.println("Created jar file " + jarFile1); - JavaToolUtils.createJar(jarFile2, Arrays.asList(new File[]{class2})); + JarUtils.createJar(jarFile2.toString(), TEST_SOURCE + ".class"); System.out.println("Created jar file " + jarFile2); - createPolicyFile(jarFile1.toURI()); - List commands = new ArrayList<>(); - final String pathSepartor = System.getProperty("path.separator"); - commands.add("-Djava.security.manager"); - commands.add("-Djava.security.policy=" + PWD + "/java.policy"); - commands.add("-classpath"); - commands.add(PWD + "/" + TEST_SOURCE + ".jar" + pathSepartor - + PWD + "/" + ACTION_SOURCE + ".jar"); - commands.add(TEST_SOURCE); - if (JavaToolUtils.runJava(commands) == 0) { - System.out.println("Test PASSES"); - } + + String pathSepartor = System.getProperty("path.separator"); + String[] commands = { + "-Djava.security.manager", + "-Djava.security.policy=" + policy, + "-classpath", jarFile1 + pathSepartor + jarFile2, + TEST_SOURCE + }; + + String userName = System.getProperty("user.name"); + + createPolicyFile(jarFile1, policy); + System.out.println("Created policy for " + jarFile1); + ProcessTools.executeTestJava(commands) + .shouldHaveExitValue(0) + .shouldContain(userName) + .stderrShouldBeEmpty(); + + createPolicyFile(jarFile2, policy); + System.out.println("Created policy for " + jarFile2); + ProcessTools.executeTestJava(commands) + .shouldNotHaveExitValue(0) + .shouldNotContain(userName) + .stderrShouldContain("java.security.AccessControlException"); + + System.out.println("Test PASSES"); } - } diff --git a/jdk/test/java/security/KeyStore/PKCS12/EntryProtectionTest.java b/jdk/test/java/security/KeyStore/PKCS12/EntryProtectionTest.java index 4500431bff0..5395a72fba5 100644 --- a/jdk/test/java/security/KeyStore/PKCS12/EntryProtectionTest.java +++ b/jdk/test/java/security/KeyStore/PKCS12/EntryProtectionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ import java.util.ArrayList; import java.util.List; import java.util.Random; import javax.crypto.spec.PBEParameterSpec; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; import static java.lang.System.out; import java.util.Arrays; @@ -40,8 +40,10 @@ import java.util.Arrays; * @summary Test for feature 'support stronger entry protection'. An entry is * stored to keystore with different PasswordProtection objects which are * specified by different PBE algorithms (use -Dseed=X to set PRNG seed) - * @library /lib/testlibrary ../ + * @library /test/lib /lib/testlibrary ../ * @key randomness + * @build jdk.test.lib.RandomFactory + * @run main EntryProtectionTest */ public class EntryProtectionTest { private static final char[] PASSWORD = "passwd".toCharArray(); diff --git a/jdk/test/java/security/MessageDigest/TestDigestIOStream.java b/jdk/test/java/security/MessageDigest/TestDigestIOStream.java index c94dbfbdd16..13399500893 100644 --- a/jdk/test/java/security/MessageDigest/TestDigestIOStream.java +++ b/jdk/test/java/security/MessageDigest/TestDigestIOStream.java @@ -1,6 +1,5 @@ - /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,7 +31,7 @@ import java.security.NoSuchAlgorithmException; import java.security.Security; import java.util.Arrays; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; import static java.lang.System.out; /** @@ -41,7 +40,8 @@ import static java.lang.System.out; * @summary MessageDigest tests with DigestIOStream * @author Kevin Liu * @key randomness - * @library /lib/testlibrary + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main/timeout=180 TestDigestIOStream */ diff --git a/jdk/test/java/security/MessageDigest/TestSameLength.java b/jdk/test/java/security/MessageDigest/TestSameLength.java index 571dd91619b..3a41776b16f 100644 --- a/jdk/test/java/security/MessageDigest/TestSameLength.java +++ b/jdk/test/java/security/MessageDigest/TestSameLength.java @@ -1,6 +1,5 @@ - /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +26,7 @@ import java.nio.ByteBuffer; import java.security.MessageDigest; import java.security.NoSuchAlgorithmException; import java.security.Security; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * @test @@ -36,7 +35,9 @@ import jdk.testlibrary.RandomFactory; * algorithm/dataLen/(update,digest methods). * @author Kevin Liu * @key randomness - * @library /lib/testlibrary + * @library /test/lib + * @build jdk.test.lib.RandomFactory + * @run main TestSameLength */ public class TestSameLength { diff --git a/jdk/test/java/security/MessageDigest/TestSameValue.java b/jdk/test/java/security/MessageDigest/TestSameValue.java index 931cb6aa7da..b8b69ed722e 100644 --- a/jdk/test/java/security/MessageDigest/TestSameValue.java +++ b/jdk/test/java/security/MessageDigest/TestSameValue.java @@ -1,6 +1,5 @@ - /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,7 +27,7 @@ import java.security.DigestException; import java.security.MessageDigest; import java.security.NoSuchAlgorithmException; import java.security.Security; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * @test @@ -37,7 +36,9 @@ import jdk.testlibrary.RandomFactory; * with various update/digest methods. * @author Kevin Liu * @key randomness - * @library /lib/testlibrary + * @library /test/lib + * @build jdk.test.lib.RandomFactory + * @run main TestSameValue */ public class TestSameValue { diff --git a/jdk/test/java/security/PermissionCollection/PermissionCollectionStreamTest.java b/jdk/test/java/security/PermissionCollection/PermissionCollectionStreamTest.java index 63d962e93b7..e803f0105e5 100644 --- a/jdk/test/java/security/PermissionCollection/PermissionCollectionStreamTest.java +++ b/jdk/test/java/security/PermissionCollection/PermissionCollectionStreamTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,7 @@ /* @test * @bug 8081678 * @summary Tests for stream returning methods - * @library ../../util/stream/bootlib + * @library /lib/testlibrary/bootlib * @build java.base/java.util.stream.OpTestCase * @run testng/othervm PermissionCollectionStreamTest */ diff --git a/jdk/test/java/security/Policy/ExtensiblePolicy/ExtensiblePolicyWithJarTest.java b/jdk/test/java/security/Policy/ExtensiblePolicy/ExtensiblePolicyWithJarTest.java index f3b77b920a7..c851f6d5c3f 100644 --- a/jdk/test/java/security/Policy/ExtensiblePolicy/ExtensiblePolicyWithJarTest.java +++ b/jdk/test/java/security/Policy/ExtensiblePolicy/ExtensiblePolicyWithJarTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,13 +27,14 @@ import java.nio.file.Files; import java.nio.file.Paths; import java.security.AccessController; import jdk.testlibrary.ProcessTools; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8050402 * @summary Check policy is extensible with user defined permissions - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib + * @build jdk.test.lib.util.JarUtils * @compile TVJar/TVPermission.java * @run main ExtensiblePolicyWithJarTest */ diff --git a/jdk/test/java/security/Provider/ProviderVersionCheck.java b/jdk/test/java/security/Provider/ProviderVersionCheck.java index dab3ff80d31..9096b6406f6 100644 --- a/jdk/test/java/security/Provider/ProviderVersionCheck.java +++ b/jdk/test/java/security/Provider/ProviderVersionCheck.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,7 +42,7 @@ public class ProviderVersionCheck { for (Provider p: Security.getProviders()) { System.out.print(p.getName() + " "); - if (p.getVersion() != 9.0d) { + if (p.getVersion() != 10.0d) { System.out.println("failed. " + "Version received was " + p.getVersion()); failure = true; diff --git a/jdk/test/java/security/Provider/SecurityProviderModularTest.java b/jdk/test/java/security/Provider/SecurityProviderModularTest.java index d35162ba4f9..713cae994d3 100644 --- a/jdk/test/java/security/Provider/SecurityProviderModularTest.java +++ b/jdk/test/java/security/Provider/SecurityProviderModularTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,6 +33,7 @@ import java.io.IOException; import java.lang.module.ModuleDescriptor; import jdk.testlibrary.ProcessTools; import jdk.testlibrary.OutputAnalyzer; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; /** @@ -40,8 +41,9 @@ import org.testng.annotations.BeforeTest; * @bug 8130360 * @library /lib/testlibrary * @library /java/security/modules + * @library /test/lib * @modules java.base/jdk.internal.module - * @build CompilerUtils JarUtils + * @build jdk.test.lib.compiler.CompilerUtils JarUtils * @summary Test custom security provider module with all possible modular * condition. The test includes different combination of security * client/provider modules interaction with or without service diff --git a/jdk/test/java/security/SecureRandom/DrbgParametersSpec.java b/jdk/test/java/security/SecureRandom/DrbgParametersSpec.java index f633576f4f0..3017262415a 100644 --- a/jdk/test/java/security/SecureRandom/DrbgParametersSpec.java +++ b/jdk/test/java/security/SecureRandom/DrbgParametersSpec.java @@ -25,6 +25,8 @@ * @bug 8051408 8158534 * @summary Make sure DrbgParameters coded as specified * @library /test/lib + * @build jdk.test.lib.Asserts + * @run main DrbgParametersSpec */ import jdk.test.lib.Asserts; diff --git a/jdk/test/java/security/Signature/Offsets.java b/jdk/test/java/security/Signature/Offsets.java index 9e71690ea4f..a21a7b313e8 100644 --- a/jdk/test/java/security/Signature/Offsets.java +++ b/jdk/test/java/security/Signature/Offsets.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ import java.security.PrivateKey; import java.security.PublicKey; import java.security.Signature; import java.security.SignatureException; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /* * @test @@ -41,7 +41,8 @@ import jdk.testlibrary.RandomFactory; * get random set of clear text data to sign. After the signature * generation, the test tries to verify signature with the above API * and passing in different signature offset (0, 33, 66, 99). - * @library /lib/testlibrary + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main Offsets SUN NONEwithDSA * @run main Offsets SUN SHA1withDSA * @run main Offsets SUN SHA224withDSA diff --git a/jdk/test/java/security/cert/PKIXRevocationChecker/OcspUnauthorized.java b/jdk/test/java/security/cert/PKIXRevocationChecker/OcspUnauthorized.java index 83f19248959..198be22734e 100644 --- a/jdk/test/java/security/cert/PKIXRevocationChecker/OcspUnauthorized.java +++ b/jdk/test/java/security/cert/PKIXRevocationChecker/OcspUnauthorized.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,11 +24,14 @@ /** * @test * @bug 8023362 + * @run main/othervm OcspUnauthorized * @summary Make sure Ocsp UNAUTHORIZED response is treated as failure when * SOFT_FAIL option is set */ import java.io.ByteArrayInputStream; +import java.security.Security; +import java.security.cert.CertPathValidatorException.BasicReason; import java.security.cert.*; import java.security.cert.PKIXRevocationChecker.Option; import java.util.Base64; @@ -69,6 +72,8 @@ public class OcspUnauthorized { private static Base64.Decoder base64Decoder = Base64.getDecoder(); public static void main(String[] args) throws Exception { + // EE_CERT is signed with MD5withRSA + Security.setProperty("jdk.certpath.disabledAlgorithms", ""); cf = CertificateFactory.getInstance("X.509"); X509Certificate taCert = getX509Cert(TRUST_ANCHOR); X509Certificate eeCert = getX509Cert(EE_CERT); @@ -92,6 +97,11 @@ public class OcspUnauthorized { throw new Exception("FAILED: expected CertPathValidatorException"); } catch (CertPathValidatorException cpve) { cpve.printStackTrace(); + if (cpve.getReason() != BasicReason.UNSPECIFIED && + !cpve.getMessage().contains("OCSP response error: UNAUTHORIZED")) { + throw new Exception("FAILED: unexpected " + + "CertPathValidatorException reason"); + } } } diff --git a/jdk/test/java/security/cert/X509CRL/VerifyDefault.java b/jdk/test/java/security/cert/X509CRL/VerifyDefault.java new file mode 100644 index 00000000000..be7c559983e --- /dev/null +++ b/jdk/test/java/security/cert/X509CRL/VerifyDefault.java @@ -0,0 +1,133 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8175029 + * @library ../../testlibrary + * @summary check that default implementation of + * X509CRL.verify(PublicKey, Provider) works on custom X509CRL impl. + */ + +import java.math.BigInteger; +import java.security.InvalidKeyException; +import java.security.NoSuchAlgorithmException; +import java.security.NoSuchProviderException; +import java.security.Principal; +import java.security.Provider; +import java.security.PublicKey; +import java.security.SignatureException; +import java.security.cert.Certificate; +import java.security.cert.CRLException; +import java.security.cert.X509Certificate; +import java.security.cert.X509CRL; +import java.security.cert.X509CRLEntry; +import java.util.Date; +import java.util.Set; + +public class VerifyDefault { + private static final String TEST_CRL = + "-----BEGIN X509 CRL-----\n" + + "MIIBGzCBhQIBATANBgkqhkiG9w0BAQQFADAfMQswCQYDVQQGEwJVUzEQMA4GA1UE\n" + + "ChMHRXhhbXBsZRcNMDkwNDI3MDIzODA0WhcNMjgwNjI2MDIzODA0WjAiMCACAQUX\n" + + "DTA5MDQyNzAyMzgwMFowDDAKBgNVHRUEAwoBBKAOMAwwCgYDVR0UBAMCAQIwDQYJ\n" + + "KoZIhvcNAQEEBQADgYEAoarfzXEtw3ZDi4f9U8eSvRIipHSyxOrJC7HR/hM5VhmY\n" + + "CErChny6x9lBVg9s57tfD/P9PSzBLusCcHwHMAbMOEcTltVVKUWZnnbumpywlYyg\n" + + "oKLrE9+yCOkYUOpiRlz43/3vkEL5hjIKMcDSZnPKBZi1h16Yj2hPe9GMibNip54=\n" + + "-----END X509 CRL-----"; + + private static final String TEST_CERT = + "-----BEGIN CERTIFICATE-----\n" + + "MIICKzCCAZSgAwIBAgIBAjANBgkqhkiG9w0BAQQFADAfMQswCQYDVQQGEwJVUzEQ\n" + + "MA4GA1UEChMHRXhhbXBsZTAeFw0wOTA0MjcwMjI0MzNaFw0yOTAxMTIwMjI0MzNa\n" + + "MB8xCzAJBgNVBAYTAlVTMRAwDgYDVQQKEwdFeGFtcGxlMIGfMA0GCSqGSIb3DQEB\n" + + "AQUAA4GNADCBiQKBgQDMJeBMBybHykI/YpwUJ4O9euqDSLb1kpWpceBS8TVqvgBC\n" + + "SgUJWtFZL0i6bdvF6mMdlbuBkGzhXqHiVAi96/zRLbUC9F8SMEJ6MuD+YhQ0ZFTQ\n" + + "atKy8zf8O9XzztelLJ26Gqb7QPV133WY3haAqHtCXOhEKkCN16NOYNC37DTaJwID\n" + + "AQABo3cwdTAdBgNVHQ4EFgQULXSWzXzUOIpOJpzbSCpW42IJUugwRwYDVR0jBEAw\n" + + "PoAUgiXdIaZeT3QA/SGUvh854OJVyxuhI6QhMB8xCzAJBgNVBAYTAlVTMRAwDgYD\n" + + "VQQKEwdFeGFtcGxlggEAMAsGA1UdDwQEAwIBAjANBgkqhkiG9w0BAQQFAAOBgQAY\n" + + "eMnf5AHSNlyUlzXk8o2S0h4gCuvKX6C3kFfKuZcWvFAbx4yQOWLS2s15/nzR4+AP\n" + + "FGX3lgJjROyAh7fGedTQK+NFWwkM2ag1g3hXktnlnT1qHohi0w31nVBJxXEDO/Ck\n" + + "uJTpJGt8XxxbFaw5v7cHy7XuTAeU/sekvjEiNHW00Q==\n" + + "-----END CERTIFICATE-----"; + + private static class TestX509CRL extends X509CRL { + private final X509CRL crl; + TestX509CRL(X509CRL crl) { + this.crl = crl; + } + public Set getCriticalExtensionOIDs() { + return crl.getCriticalExtensionOIDs(); + } + public byte[] getExtensionValue(String oid) { + return crl.getExtensionValue(oid); + } + public Set getNonCriticalExtensionOIDs() { + return crl.getNonCriticalExtensionOIDs(); + } + public boolean hasUnsupportedCriticalExtension() { + return crl.hasUnsupportedCriticalExtension(); + } + public Set getRevokedCertificates() { + return crl.getRevokedCertificates(); + } + public X509CRLEntry getRevokedCertificate(BigInteger serialNumber) { + return crl.getRevokedCertificate(serialNumber); + } + public boolean isRevoked(Certificate cert) { + return crl.isRevoked(cert); + } + public Date getNextUpdate() { return crl.getNextUpdate(); } + public Date getThisUpdate() { return crl.getThisUpdate(); } + public int getVersion() { return crl.getVersion(); } + public Principal getIssuerDN() { return crl.getIssuerDN(); } + public byte[] getTBSCertList() throws CRLException { + return crl.getTBSCertList(); + } + public byte[] getSignature() { return crl.getSignature(); } + public String getSigAlgName() { return crl.getSigAlgName(); } + public String getSigAlgOID() { return crl.getSigAlgOID(); } + public byte[] getSigAlgParams() { return crl.getSigAlgParams(); } + public byte[] getEncoded() throws CRLException { + return crl.getEncoded(); + } + public void verify(PublicKey key) throws CRLException, + InvalidKeyException, NoSuchAlgorithmException, + NoSuchProviderException, SignatureException { + crl.verify(key); + } + public void verify(PublicKey key, String sigProvider) throws + CRLException, InvalidKeyException, NoSuchAlgorithmException, + NoSuchProviderException, SignatureException { + crl.verify(key, sigProvider); + } + public String toString() { return crl.toString(); } + } + + public static void main(String[] args) throws Exception { + X509Certificate cert = CertUtils.getCertFromString(TEST_CERT); + X509CRL crl = CertUtils.getCRLFromString(TEST_CRL); + new TestX509CRL(crl).verify(cert.getPublicKey(), (Provider)null); + } +} diff --git a/jdk/test/java/security/cert/X509Certificate/VerifyDefault.java b/jdk/test/java/security/cert/X509Certificate/VerifyDefault.java new file mode 100644 index 00000000000..b43ebf37b45 --- /dev/null +++ b/jdk/test/java/security/cert/X509Certificate/VerifyDefault.java @@ -0,0 +1,139 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8175029 + * @library ../../testlibrary + * @summary check that default implementation of + * X509Certificate.verify(PublicKey, Provider) works on custom + * X509Certificate impl. + */ + +import java.math.BigInteger; +import java.security.InvalidKeyException; +import java.security.NoSuchAlgorithmException; +import java.security.NoSuchProviderException; +import java.security.Principal; +import java.security.Provider; +import java.security.PublicKey; +import java.security.SignatureException; +import java.security.cert.CertificateEncodingException; +import java.security.cert.CertificateException; +import java.security.cert.CertificateExpiredException; +import java.security.cert.CertificateNotYetValidException; +import java.security.cert.X509Certificate; +import java.util.Collection; +import java.util.Date; +import java.util.List; +import java.util.Set; + +public class VerifyDefault { + private static final String TEST_CERT = + "-----BEGIN CERTIFICATE-----\n" + + "MIICvTCCAaWgAwIBAgIEGYqL9TANBgkqhkiG9w0BAQsFADAPMQ0wCwYDVQQDEwRT\n" + + "ZWxmMB4XDTE3MDMyODE2NDcyNloXDTE3MDYyNjE2NDcyNlowDzENMAsGA1UEAxME\n" + + "U2VsZjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAL1pfSJljFVSABOL\n" + + "tJbIVPEkz1+2AFgzY1hqwE0EH80lvhOEkiPPYCKwBE5VTZdyFfwFjpyx7eEeJMNT\n" + + "o7cixfmkQaiXHr/S1AS4BRTqLG/zgLzoJpVbzi45rnVEZc0oTm11KG3uUxkZTRr3\n" + + "5ORbYyZpkscKwHL2M0J/1GmnA1hmhQdwUQyIKxg4eKQwyE+/TdbFlCWVNnOlb+91\n" + + "eXvS11nIJ1oaBgn7u4qihuVmFmngLMxExnLYKV6AwdkwFD6pERObclRD9vAl5eUk\n" + + "+sM6zQYwfLdyC2i8e+ETBeOg1ijptM4KT5Uaq89zxjLR0DPH4S+aILp3gYHGrW5r\n" + + "eMxZAEMCAwEAAaMhMB8wHQYDVR0OBBYEFOME39JtbjzQaK3ufpKo/Pl4sZ8XMA0G\n" + + "CSqGSIb3DQEBCwUAA4IBAQCDcw0+Sf0yeVROVlb2/VV3oIblHkGQheXeIurW64k7\n" + + "tEzHtx9i8dnj5lzTZNH6hU4GRlyULbSDzjcM3P2XFRsM+0a/kEJZVqnLz5ji//7/\n" + + "ZXaRX0TiE2IfFOTGbO6LusO3yR4tOER/WHllz2H21C2SbW3+92Ou28glTZa42AAZ\n" + + "mUj9j+p6mZqD4/tUBqAEqqQoMIhw9CNjc46STNayBjt/0/+I2pfy6LagrMbjBzZ0\n" + + "A5kXg9WjnywGk8XFr/3RZz8DrUmCYs2qCYLCHQHsuCE6gCuf9wKhKyD51MFXXRr0\n" + + "cyG6LYQjrreMHYk4ZfN2NPC6lGjWxB5mIbV/DuikCnYu\n" + + "-----END CERTIFICATE-----"; + + private static class TestX509Certificate extends X509Certificate { + private final X509Certificate cert; + TestX509Certificate(X509Certificate cert) { + this.cert = cert; + } + public Set getCriticalExtensionOIDs() { + return cert.getCriticalExtensionOIDs(); + } + public byte[] getExtensionValue(String oid) { + return cert.getExtensionValue(oid); + } + public Set getNonCriticalExtensionOIDs() { + return cert.getNonCriticalExtensionOIDs(); + } + public boolean hasUnsupportedCriticalExtension() { + return cert.hasUnsupportedCriticalExtension(); + } + public void checkValidity() throws CertificateExpiredException, + CertificateNotYetValidException { + cert.checkValidity(); + } + public void checkValidity(Date date) throws CertificateExpiredException, + CertificateNotYetValidException { + cert.checkValidity(date); + } + public int getVersion() { return cert.getVersion(); } + public BigInteger getSerialNumber() { return cert.getSerialNumber(); } + public Principal getIssuerDN() { return cert.getIssuerDN(); } + public Principal getSubjectDN() { return cert.getSubjectDN(); } + public Date getNotBefore() { return cert.getNotBefore(); } + public Date getNotAfter() { return cert.getNotAfter(); } + public byte[] getTBSCertificate() throws CertificateEncodingException { + return cert.getTBSCertificate(); + } + public byte[] getSignature() { return cert.getSignature(); } + public String getSigAlgName() { return cert.getSigAlgName(); } + public String getSigAlgOID() { return cert.getSigAlgOID(); } + public byte[] getSigAlgParams() { return cert.getSigAlgParams(); } + public boolean[] getIssuerUniqueID() { + return cert.getIssuerUniqueID(); + } + public boolean[] getSubjectUniqueID() { + return cert.getSubjectUniqueID(); + } + public boolean[] getKeyUsage() { return cert.getKeyUsage(); } + public int getBasicConstraints() { return cert.getBasicConstraints(); } + public byte[] getEncoded() throws CertificateEncodingException { + return cert.getEncoded(); + } + public void verify(PublicKey key) throws CertificateException, + InvalidKeyException, NoSuchAlgorithmException, + NoSuchProviderException, SignatureException { + cert.verify(key); + } + public void verify(PublicKey key, String sigProvider) throws + CertificateException, InvalidKeyException, NoSuchAlgorithmException, + NoSuchProviderException, SignatureException { + cert.verify(key, sigProvider); + } + public PublicKey getPublicKey() { return cert.getPublicKey(); } + public String toString() { return cert.toString(); } + } + + public static void main(String[] args) throws Exception { + X509Certificate cert = CertUtils.getCertFromString(TEST_CERT); + new TestX509Certificate(cert).verify(cert.getPublicKey(), + (Provider)null); + } +} diff --git a/jdk/test/java/security/testlibrary/CertUtils.java b/jdk/test/java/security/testlibrary/CertUtils.java index e850ed1273d..0857a9af696 100644 --- a/jdk/test/java/security/testlibrary/CertUtils.java +++ b/jdk/test/java/security/testlibrary/CertUtils.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2007, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,17 +27,20 @@ * @author Steve Hanna * */ +import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; import java.io.File; import java.io.FileInputStream; import java.io.InputStream; import java.io.IOException; +import java.security.cert.CertificateException; import java.security.cert.CertificateFactory; import java.security.cert.CertPath; import java.security.cert.CertPathBuilder; import java.security.cert.CertPathValidator; import java.security.cert.CertStore; import java.security.cert.CollectionCertStoreParameters; +import java.security.cert.CRLException; import java.security.cert.PKIXBuilderParameters; import java.security.cert.PKIXCertPathBuilderResult; import java.security.cert.PKIXCertPathValidatorResult; @@ -60,59 +63,71 @@ public class CertUtils { * Get a DER-encoded X.509 certificate from a file. * * @param certFilePath path to file containing DER-encoded certificate - * @return X509Certificate - * @throws IOException on error + * @return the X509Certificate + * @throws CertificateException if the certificate type is not supported + * or cannot be parsed + * @throws IOException if the file cannot be opened */ public static X509Certificate getCertFromFile(String certFilePath) - throws IOException { - X509Certificate cert = null; - try { - File certFile = new File(System.getProperty("test.src", "."), - certFilePath); - if (!certFile.canRead()) - throw new IOException("File " + - certFile.toString() + - " is not a readable file."); - FileInputStream certFileInputStream = - new FileInputStream(certFile); - CertificateFactory cf = CertificateFactory.getInstance("X509"); - cert = (X509Certificate) - cf.generateCertificate(certFileInputStream); - } catch (Exception e) { - e.printStackTrace(); - throw new IOException("Can't construct X509Certificate: " + - e.getMessage()); - } - return cert; + throws CertificateException, IOException { + File certFile = new File(System.getProperty("test.src", "."), + certFilePath); + try (FileInputStream fis = new FileInputStream(certFile)) { + return (X509Certificate) + CertificateFactory.getInstance("X.509") + .generateCertificate(fis); + } + } + + /** + * Get a PEM-encoded X.509 certificate from a string. + * + * @param cert string containing the PEM-encoded certificate + * @return the X509Certificate + * @throws CertificateException if the certificate type is not supported + * or cannot be parsed + */ + public static X509Certificate getCertFromString(String cert) + throws CertificateException { + byte[] certBytes = cert.getBytes(); + ByteArrayInputStream bais = new ByteArrayInputStream(certBytes); + return (X509Certificate) + CertificateFactory.getInstance("X.509").generateCertificate(bais); } /** * Get a DER-encoded X.509 CRL from a file. * * @param crlFilePath path to file containing DER-encoded CRL - * @return X509CRL - * @throws IOException on error + * @return the X509CRL + * @throws CertificateException if the crl type is not supported + * @throws CRLException if the crl cannot be parsed + * @throws IOException if the file cannot be opened */ public static X509CRL getCRLFromFile(String crlFilePath) - throws IOException { - X509CRL crl = null; - try { - File crlFile = new File(System.getProperty("test.src", "."), - crlFilePath); - if (!crlFile.canRead()) - throw new IOException("File " + - crlFile.toString() + - " is not a readable file."); - FileInputStream crlFileInputStream = - new FileInputStream(crlFile); - CertificateFactory cf = CertificateFactory.getInstance("X509"); - crl = (X509CRL) cf.generateCRL(crlFileInputStream); - } catch (Exception e) { - e.printStackTrace(); - throw new IOException("Can't construct X509CRL: " + - e.getMessage()); - } - return crl; + throws CertificateException, CRLException, IOException { + File crlFile = new File(System.getProperty("test.src", "."), + crlFilePath); + try (FileInputStream fis = new FileInputStream(crlFile)) { + return (X509CRL) + CertificateFactory.getInstance("X.509").generateCRL(fis); + } + } + + /** + * Get a PEM-encoded X.509 crl from a string. + * + * @param crl string containing the PEM-encoded crl + * @return the X509CRL + * @throws CertificateException if the crl type is not supported + * @throws CRLException if the crl cannot be parsed + */ + public static X509CRL getCRLFromString(String crl) + throws CertificateException, CRLException { + byte[] crlBytes = crl.getBytes(); + ByteArrayInputStream bais = new ByteArrayInputStream(crlBytes); + return (X509CRL) + CertificateFactory.getInstance("X.509").generateCRL(bais); } /** diff --git a/jdk/test/java/text/Format/DecimalFormat/Bug6609740.java b/jdk/test/java/text/Format/DecimalFormat/Bug6609740.java new file mode 100644 index 00000000000..0dd8bd292d9 --- /dev/null +++ b/jdk/test/java/text/Format/DecimalFormat/Bug6609740.java @@ -0,0 +1,129 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +/* + * @test + * @bug 6609740 + * @summary Checks the formatting and parsing of a number based + * on the positive and negative sub-patterns, also + * checks few invalid number patterns + */ +import java.text.DecimalFormat; +import java.text.NumberFormat; +import java.text.ParseException; +import java.util.Locale; + +public class Bug6609740 { + + public static void main(String[] args) { + + double dNumber = -3456.349347; + String fOutput = "(3,456.35)"; + String[] validCases = {"#,##0.0#;(#,##0.0#)", "#,##0.0#;(#)", + "#,##0.0#;(#,##0)"}; + + // formatting with the valid cases + NumberFormat nf = NumberFormat.getInstance(Locale.US); + for (String pattern : validCases) { + formatOnPattern(nf, pattern, dNumber, fOutput); + } + + // parsing with the valid cases + String parseString = "(3,456.35)"; + Number pOutput = -3456.35; + for (String pattern : validCases) { + parseOnPattern(nf, pattern, parseString, pOutput); + } + + // should throw parse exception + String[] invalidParseCases = {"#,##0.0#;0", "#,##0.0#;()"}; + for (String pattern : invalidParseCases) { + if (nf instanceof DecimalFormat) { + ((DecimalFormat) nf).applyPattern(pattern); + } + + try { + nf.parse(parseString); + } catch (ParseException ex) { + continue; + } + throw new RuntimeException("[FAILED: Should throw" + + " ParseException for pattern: " + + pattern + " and input: " + parseString + "]"); + } + + // should throw exception on invalid patterns + // invalid patterns: no positive subpattern, zero after non-zero in + // the decimal part i.e. 0#0, multiple decimal separators, + // multiple percent, malformed pattern + String[] invalidPatterns = {";(#,##0.0#)", "#,##0.0#0;(#)", + "#,##0.0.#", "#,##0%%", ".#,##0"}; + for (String pattern : invalidPatterns) { + if (nf instanceof DecimalFormat) { + try { + ((DecimalFormat) nf).applyPattern(pattern); + } catch (IllegalArgumentException ex) { + continue; + } + throw new RuntimeException("[FAILED: Should throw" + + " IllegalArgumentException for invalid pattern: " + + pattern + "]"); + } + } + } + + private static void formatOnPattern(NumberFormat nf, String pattern, + double number, String expected) { + + if (nf instanceof DecimalFormat) { + ((DecimalFormat) nf).applyPattern(pattern); + } + + String formatted = nf.format(number); + if (!formatted.equals(expected)) { + throw new RuntimeException("[FAILED: Unable to format the number" + + " based on the pattern: '" + pattern + "', Expected : '" + + expected + "', Found: '" + formatted + "']"); + } + } + + private static void parseOnPattern(NumberFormat nf, String pattern, + String parseString, Number expected) { + + if (nf instanceof DecimalFormat) { + ((DecimalFormat) nf).applyPattern(pattern); + } + + try { + Number output = nf.parse(parseString); + if (expected.doubleValue() != output.doubleValue()) { + throw new RuntimeException("[FAILED: Unable to parse the number" + + " based on the pattern: '" + pattern + "', Expected : '" + + expected + "', Found: '" + output + "']"); + } + } catch (ParseException ex) { + throw new RuntimeException("[FAILED: Unable to parse the pattern:" + + " '" + pattern + "']", ex); + } + } + +} diff --git a/jdk/test/java/util/Arrays/Big.java b/jdk/test/java/util/Arrays/Big.java index cd8f097ac09..1d40b39b846 100644 --- a/jdk/test/java/util/Arrays/Big.java +++ b/jdk/test/java/util/Arrays/Big.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ // A proper regression test for 5045582 requires too much memory. // If you have a really big machine, run like this: -// java -d64 -Xms25g -Xmx25g Big 30 +// java -Xms25g -Xmx25g Big 30 import java.util.*; @@ -68,7 +68,7 @@ public class Big { } // To test Object arrays larger than 1<<30, you need 13GB. Run like: - // java -d64 -Xms13g -Xmx13g Big 30 2 + // java -Xms13g -Xmx13g Big 30 2 if ((tasks & 0x2) != 0) { System.out.println("Integer[]"); System.gc(); diff --git a/jdk/test/java/util/Arrays/ParallelPrefix.java b/jdk/test/java/util/Arrays/largeMemory/ParallelPrefix.java similarity index 86% rename from jdk/test/java/util/Arrays/ParallelPrefix.java rename to jdk/test/java/util/Arrays/largeMemory/ParallelPrefix.java index 7772c6e4c75..9c102fe5f34 100644 --- a/jdk/test/java/util/Arrays/ParallelPrefix.java +++ b/jdk/test/java/util/Arrays/largeMemory/ParallelPrefix.java @@ -25,9 +25,11 @@ * @test 8014076 8025067 * @summary unit test for Arrays.ParallelPrefix(). * @author Tristan Yan - * @run testng ParallelPrefix + * @modules java.management jdk.management + * @run testng/othervm -Xms256m -Xmx1024m ParallelPrefix */ +import java.lang.management.ManagementFactory; import java.util.Arrays; import java.util.function.BinaryOperator; import java.util.function.DoubleBinaryOperator; @@ -36,9 +38,11 @@ import java.util.function.IntBinaryOperator; import java.util.function.LongBinaryOperator; import java.util.stream.IntStream; import java.util.stream.LongStream; +import com.sun.management.OperatingSystemMXBean; import static org.testng.Assert.*; import org.testng.annotations.DataProvider; import org.testng.annotations.Test; +import org.testng.annotations.BeforeSuite; public class ParallelPrefix { //Array size less than MIN_PARTITION @@ -53,12 +57,37 @@ public class ParallelPrefix { //Array size much greater than MIN_PARTITION private static final int LARGE_ARRAY_SIZE = 1 << 14; - private static final int[] ARRAY_SIZE_COLLECTION = new int[]{ - SMALL_ARRAY_SIZE, - THRESHOLD_ARRAY_SIZE, - MEDIUM_ARRAY_SIZE, - LARGE_ARRAY_SIZE - }; + private static int[] arraySizeCollection; + + @BeforeSuite + public static void setup() { + java.lang.management.OperatingSystemMXBean bean = + ManagementFactory.getOperatingSystemMXBean(); + if (bean instanceof OperatingSystemMXBean) { + OperatingSystemMXBean os = (OperatingSystemMXBean)bean; + long physicalMemorySize = os.getTotalPhysicalMemorySize() / (1024 * 1024); + System.out.println("System memory size: " + physicalMemorySize + "M"); + // when we can get system memory size, and it's larger than 2G, + // then we enable large array size test below, + // else disable large array size test below. + if (physicalMemorySize > (2 * 1024)) { + arraySizeCollection = new int[]{ + SMALL_ARRAY_SIZE, + THRESHOLD_ARRAY_SIZE, + MEDIUM_ARRAY_SIZE, + LARGE_ARRAY_SIZE + }; + System.out.println("System memory is large enough, add large array size test"); + return; + } + } + arraySizeCollection = new int[]{ + SMALL_ARRAY_SIZE, + THRESHOLD_ARRAY_SIZE, + MEDIUM_ARRAY_SIZE + }; + System.out.println("System memory is not large enough, remove large array size test"); + } @DataProvider(name = "intSet") public static Object[][] intSet(){ @@ -96,10 +125,10 @@ public class ParallelPrefix { private static Object[][] genericData(Function generateFunc, OPS[] ops) { //test arrays which size is equals n-1, n, n+1, test random data - Object[][] data = new Object[ARRAY_SIZE_COLLECTION.length * 3 * ops.length][4]; - for(int n = 0; n < ARRAY_SIZE_COLLECTION.length; n++ ) { + Object[][] data = new Object[arraySizeCollection.length * 3 * ops.length][4]; + for(int n = 0; n < arraySizeCollection.length; n++ ) { for(int testValue = -1 ; testValue <= 1; testValue++) { - int array_size = ARRAY_SIZE_COLLECTION[n] + testValue; + int array_size = arraySizeCollection[n] + testValue; for(int opsN = 0; opsN < ops.length; opsN++) { int index = n * 3 * ops.length + (testValue + 1) * ops.length + opsN; data[index][0] = generateFunc.apply(array_size); diff --git a/jdk/test/java/util/Base64/TestBase64.java b/jdk/test/java/util/Base64/TestBase64.java index d28f0d0f88a..0874e7fb40b 100644 --- a/jdk/test/java/util/Base64/TestBase64.java +++ b/jdk/test/java/util/Base64/TestBase64.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ * @test 4235519 8004212 8005394 8007298 8006295 8006315 8006530 8007379 8008925 * 8014217 8025003 8026330 8028397 8129544 8165243 * @summary tests java.util.Base64 - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main TestBase64 * @key randomness */ @@ -43,7 +43,7 @@ import java.util.Base64; import java.util.List; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class TestBase64 { diff --git a/jdk/test/java/util/BitSet/stream/BitSetStreamTest.java b/jdk/test/java/util/BitSet/stream/BitSetStreamTest.java index e6bf02715fe..608c53582b3 100644 --- a/jdk/test/java/util/BitSet/stream/BitSetStreamTest.java +++ b/jdk/test/java/util/BitSet/stream/BitSetStreamTest.java @@ -50,7 +50,7 @@ import static org.testng.Assert.assertTrue; * @summary test BitSet stream * @bug 8012645 8076442 * @requires os.maxMemory >= 2g - * @library ../../stream/bootlib + * @library /lib/testlibrary/bootlib * @build java.base/java.util.SpliteratorTestHelper * java.base/java.util.SpliteratorOfIntDataBuilder * @run testng/othervm -Xms512m -Xmx1024m BitSetStreamTest diff --git a/jdk/test/java/util/Calendar/Bug8176847.java b/jdk/test/java/util/Calendar/Bug8176847.java new file mode 100644 index 00000000000..d5e5c050754 --- /dev/null +++ b/jdk/test/java/util/Calendar/Bug8176847.java @@ -0,0 +1,52 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8176847 + * @summary Make sure that style value of '3' throws IllegalArgumentException + * in Calendar.getDisplayName(s) methods. + */ + +import java.util.Calendar; +import java.util.Locale; + +public class Bug8176847 { + public static void main(String[] args) { + Calendar c = new Calendar.Builder().build(); + + try { + c.getDisplayName(Calendar.MONTH, 3, Locale.US); + throw new RuntimeException("IllegalArgumentException was not thrown"); + } catch (IllegalArgumentException iae) { + // success + } + + try { + c.getDisplayNames(Calendar.MONTH, 3, Locale.US); + throw new RuntimeException("IllegalArgumentException was not thrown"); + } catch (IllegalArgumentException iae) { + // success + } + } +} diff --git a/jdk/test/java/util/List/SubList.java b/jdk/test/java/util/List/SubList.java index 8d82dbfeaaa..0b2d02e4fe6 100644 --- a/jdk/test/java/util/List/SubList.java +++ b/jdk/test/java/util/List/SubList.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,8 +24,8 @@ /* * @test * @bug 8079136 - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run testng SubList * @summary Basic functionality of sublists * @key randomness @@ -46,7 +46,7 @@ import java.util.Vector; import org.testng.annotations.Test; import org.testng.annotations.DataProvider; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class SubList extends org.testng.Assert { diff --git a/jdk/test/java/util/Locale/LocaleEnhanceTest.java b/jdk/test/java/util/Locale/LocaleEnhanceTest.java index c30804d3a15..7baac43a046 100644 --- a/jdk/test/java/util/Locale/LocaleEnhanceTest.java +++ b/jdk/test/java/util/Locale/LocaleEnhanceTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -44,7 +44,7 @@ import java.util.Set; /** * @test * @bug 6875847 6992272 7002320 7015500 7023613 7032820 7033504 7004603 - * 7044019 8008577 + * 7044019 8008577 8176853 * @summary test API changes to Locale * @library /java/text/testlib * @modules jdk.localedata @@ -1032,6 +1032,7 @@ public class LocaleEnhanceTest extends IntlTest { // null attribute throws NPE new BuilderNPE("null attribute") { public void call() { b.addUnicodeLocaleAttribute(null); }}; + new BuilderNPE("null attribute removal") { public void call() { b.removeUnicodeLocaleAttribute(null); }}; // illformed attribute throws IllformedLocaleException new BuilderILE("invalid attribute") { public void call() { b.addUnicodeLocaleAttribute("ca"); }}; diff --git a/jdk/test/java/util/ResourceBundle/modules/cache/CacheTest.java b/jdk/test/java/util/ResourceBundle/modules/cache/CacheTest.java index 15d75aec5e4..865dc381caa 100644 --- a/jdk/test/java/util/ResourceBundle/modules/cache/CacheTest.java +++ b/jdk/test/java/util/ResourceBundle/modules/cache/CacheTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,9 +24,9 @@ /** * @test * @bug 8170772 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build CacheTest CompilerUtils jdk.testlibrary.* + * @build CacheTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng CacheTest */ @@ -37,12 +37,12 @@ import java.nio.file.Paths; import jdk.testlibrary.OutputAnalyzer; import static jdk.testlibrary.ProcessTools.*; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; import static org.testng.Assert.*; - @Test public class CacheTest { diff --git a/jdk/test/java/util/ResourceBundle/modules/casesensitive/CaseInsensitiveNameClash.java b/jdk/test/java/util/ResourceBundle/modules/casesensitive/CaseInsensitiveNameClash.java index b3eef5d3d6c..e0e76ff42de 100644 --- a/jdk/test/java/util/ResourceBundle/modules/casesensitive/CaseInsensitiveNameClash.java +++ b/jdk/test/java/util/ResourceBundle/modules/casesensitive/CaseInsensitiveNameClash.java @@ -24,9 +24,10 @@ /* * @test * @bug 8177980 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build CompilerUtils jdk.testlibrary.ProcessTools CaseInsensitiveNameClash + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.testlibrary.ProcessTools CaseInsensitiveNameClash * @run testng CaseInsensitiveNameClash */ @@ -34,6 +35,7 @@ import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; import jdk.testlibrary.ProcessTools; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; diff --git a/jdk/test/java/util/ResourceBundle/modules/security/TestPermission.java b/jdk/test/java/util/ResourceBundle/modules/security/TestPermission.java index 14db7ad2113..43e4abe4c9a 100644 --- a/jdk/test/java/util/ResourceBundle/modules/security/TestPermission.java +++ b/jdk/test/java/util/ResourceBundle/modules/security/TestPermission.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,7 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.List; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.executeTestJava; import org.testng.annotations.BeforeTest; @@ -34,9 +35,9 @@ import static org.testng.Assert.*; /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build TestPermission CompilerUtils jdk.testlibrary.* + * @build TestPermission jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng TestPermission * @summary Driver for testing ResourceBundle::getBundle(String, Module) */ diff --git a/jdk/test/java/util/Scanner/ScannerStreamTest.java b/jdk/test/java/util/Scanner/ScannerStreamTest.java index 99d21dce1c1..a27cae0f437 100644 --- a/jdk/test/java/util/Scanner/ScannerStreamTest.java +++ b/jdk/test/java/util/Scanner/ScannerStreamTest.java @@ -47,7 +47,7 @@ import static org.testng.Assert.*; * @test * @bug 8072722 8150488 * @summary Tests of stream support in java.util.Scanner - * @library ../stream/bootlib + * @library /lib/testlibrary/bootlib * @build java.base/java.util.stream.OpTestCase * @run testng/othervm ScannerStreamTest */ diff --git a/jdk/test/java/util/ServiceLoader/modules/BadProvidersTest.java b/jdk/test/java/util/ServiceLoader/modules/BadProvidersTest.java index a1bf4abf099..84392b1aca7 100644 --- a/jdk/test/java/util/ServiceLoader/modules/BadProvidersTest.java +++ b/jdk/test/java/util/ServiceLoader/modules/BadProvidersTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,9 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build CompilerUtils + * @build jdk.test.lib.compiler.CompilerUtils * @run testng/othervm BadProvidersTest * @summary Basic test of ServiceLoader with bad provider and bad provider * factories deployed on the module path @@ -44,6 +44,8 @@ import java.util.ServiceLoader.Provider; import java.util.Set; import java.util.stream.Collectors; +import jdk.test.lib.compiler.CompilerUtils; + import org.testng.annotations.Test; import org.testng.annotations.DataProvider; import static org.testng.Assert.*; diff --git a/jdk/test/java/util/Spliterator/SpliteratorCollisions.java b/jdk/test/java/util/Spliterator/SpliteratorCollisions.java index da9de48f705..0bc18ede700 100644 --- a/jdk/test/java/util/Spliterator/SpliteratorCollisions.java +++ b/jdk/test/java/util/Spliterator/SpliteratorCollisions.java @@ -24,7 +24,7 @@ /** * @test * @bug 8005698 - * @library ../stream/bootlib + * @library /lib/testlibrary/bootlib * @build java.base/java.util.SpliteratorTestHelper * @run testng SpliteratorCollisions * @summary Spliterator traversing and splitting hash maps containing colliding hashes diff --git a/jdk/test/java/util/Spliterator/SpliteratorTraversingAndSplittingTest.java b/jdk/test/java/util/Spliterator/SpliteratorTraversingAndSplittingTest.java index ca45ab758bc..ece63bfe813 100644 --- a/jdk/test/java/util/Spliterator/SpliteratorTraversingAndSplittingTest.java +++ b/jdk/test/java/util/Spliterator/SpliteratorTraversingAndSplittingTest.java @@ -24,7 +24,7 @@ /** * @test * @summary Spliterator traversing and splitting tests - * @library ../stream/bootlib + * @library /lib/testlibrary/bootlib * @build java.base/java.util.SpliteratorOfIntDataBuilder * java.base/java.util.SpliteratorTestHelper * @run testng SpliteratorTraversingAndSplittingTest diff --git a/jdk/test/java/util/WeakHashMap/GCDuringIteration.java b/jdk/test/java/util/WeakHashMap/GCDuringIteration.java index 029b51e5cbf..53df6e4f755 100644 --- a/jdk/test/java/util/WeakHashMap/GCDuringIteration.java +++ b/jdk/test/java/util/WeakHashMap/GCDuringIteration.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,8 +24,8 @@ /* * @test * @bug 6499848 - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main GCDuringIteration * @summary Check that iterators work properly in the presence of * concurrent finalization and removal of elements. @@ -43,7 +43,7 @@ import java.util.Random; import java.util.WeakHashMap; import java.util.concurrent.CountDownLatch; import java.util.function.BooleanSupplier; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class GCDuringIteration { diff --git a/jdk/test/java/util/concurrent/ThreadPoolExecutor/ConfigChanges.java b/jdk/test/java/util/concurrent/ThreadPoolExecutor/ConfigChanges.java index 7457e6cc252..73969d46720 100644 --- a/jdk/test/java/util/concurrent/ThreadPoolExecutor/ConfigChanges.java +++ b/jdk/test/java/util/concurrent/ThreadPoolExecutor/ConfigChanges.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ * @test * @bug 6450200 * @summary Test proper handling of pool state changes - * @library /lib/testlibrary/ - * @build jdk.testlibrary.RandomFactory + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main/othervm ConfigChanges * @key randomness * @author Martin Buchholz @@ -45,7 +45,7 @@ import java.util.concurrent.RejectedExecutionException; import java.util.concurrent.ThreadFactory; import java.util.concurrent.ThreadPoolExecutor; import java.util.function.Supplier; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class ConfigChanges { static final ThreadGroup tg = new ThreadGroup("pool"); diff --git a/jdk/test/java/util/concurrent/tck/ArrayDeque8Test.java b/jdk/test/java/util/concurrent/tck/ArrayDeque8Test.java index 0a7f26bfe64..c2079555218 100644 --- a/jdk/test/java/util/concurrent/tck/ArrayDeque8Test.java +++ b/jdk/test/java/util/concurrent/tck/ArrayDeque8Test.java @@ -37,7 +37,6 @@ import java.util.Collections; import java.util.Spliterator; import junit.framework.Test; -import junit.framework.TestSuite; public class ArrayDeque8Test extends JSR166TestCase { public static void main(String[] args) { diff --git a/jdk/test/java/util/concurrent/tck/ArrayDequeTest.java b/jdk/test/java/util/concurrent/tck/ArrayDequeTest.java index 1bbd98106ac..344b63c9b79 100644 --- a/jdk/test/java/util/concurrent/tck/ArrayDequeTest.java +++ b/jdk/test/java/util/concurrent/tck/ArrayDequeTest.java @@ -35,7 +35,6 @@ import java.util.ArrayDeque; import java.util.Arrays; import java.util.Collection; -import java.util.Collections; import java.util.Deque; import java.util.Iterator; import java.util.NoSuchElementException; @@ -44,7 +43,6 @@ import java.util.Random; import java.util.concurrent.ThreadLocalRandom; import junit.framework.Test; -import junit.framework.TestSuite; public class ArrayDequeTest extends JSR166TestCase { public static void main(String[] args) { diff --git a/jdk/test/java/util/concurrent/tck/ArrayListTest.java b/jdk/test/java/util/concurrent/tck/ArrayListTest.java index 193b4af8aca..535f04d34b5 100644 --- a/jdk/test/java/util/concurrent/tck/ArrayListTest.java +++ b/jdk/test/java/util/concurrent/tck/ArrayListTest.java @@ -33,11 +33,9 @@ */ import java.util.ArrayList; -import java.util.Collection; import java.util.List; import junit.framework.Test; -import junit.framework.TestSuite; public class ArrayListTest extends JSR166TestCase { public static void main(String[] args) { diff --git a/jdk/test/java/util/concurrent/tck/AtomicReferenceFieldUpdaterTest.java b/jdk/test/java/util/concurrent/tck/AtomicReferenceFieldUpdaterTest.java index fb50658ea91..5fdf279238c 100644 --- a/jdk/test/java/util/concurrent/tck/AtomicReferenceFieldUpdaterTest.java +++ b/jdk/test/java/util/concurrent/tck/AtomicReferenceFieldUpdaterTest.java @@ -75,7 +75,7 @@ public class AtomicReferenceFieldUpdaterTest extends JSR166TestCase { assertTrue(a.compareAndSet(this, two, m4)); assertSame(m4, a.get(this)); assertFalse(a.compareAndSet(this, m5, seven)); - assertFalse(seven == a.get(this)); + assertNotSame(seven, a.get(this)); assertTrue(a.compareAndSet(this, m4, seven)); assertSame(seven, a.get(this)); } @@ -208,7 +208,7 @@ public class AtomicReferenceFieldUpdaterTest extends JSR166TestCase { assertTrue(a.compareAndSet(this, two, m4)); assertSame(m4, a.get(this)); assertFalse(a.compareAndSet(this, m5, seven)); - assertFalse(seven == a.get(this)); + assertNotSame(seven, a.get(this)); assertTrue(a.compareAndSet(this, m4, seven)); assertSame(seven, a.get(this)); } diff --git a/jdk/test/java/util/concurrent/tck/AtomicReferenceTest.java b/jdk/test/java/util/concurrent/tck/AtomicReferenceTest.java index 6242374ee89..eb8c0b7b565 100644 --- a/jdk/test/java/util/concurrent/tck/AtomicReferenceTest.java +++ b/jdk/test/java/util/concurrent/tck/AtomicReferenceTest.java @@ -153,7 +153,7 @@ public class AtomicReferenceTest extends JSR166TestCase { AtomicReference z = serialClone(x); assertNotSame(y, z); assertEquals(one, x.get()); - assertEquals(null, y.get()); + assertNull(y.get()); assertEquals(one, z.get()); } diff --git a/jdk/test/java/util/concurrent/tck/CompletableFutureTest.java b/jdk/test/java/util/concurrent/tck/CompletableFutureTest.java index 6def2fffb3a..6439a40fcb0 100644 --- a/jdk/test/java/util/concurrent/tck/CompletableFutureTest.java +++ b/jdk/test/java/util/concurrent/tck/CompletableFutureTest.java @@ -2589,28 +2589,28 @@ public class CompletableFutureTest extends JSR166TestCase { // unspecified behavior - both source completions available try { - assertEquals(null, h0.join()); + assertNull(h0.join()); rs[0].assertValue(v1); } catch (CompletionException ok) { checkCompletedWithWrappedException(h0, ex); rs[0].assertNotInvoked(); } try { - assertEquals(null, h1.join()); + assertNull(h1.join()); rs[1].assertValue(v1); } catch (CompletionException ok) { checkCompletedWithWrappedException(h1, ex); rs[1].assertNotInvoked(); } try { - assertEquals(null, h2.join()); + assertNull(h2.join()); rs[2].assertValue(v1); } catch (CompletionException ok) { checkCompletedWithWrappedException(h2, ex); rs[2].assertNotInvoked(); } try { - assertEquals(null, h3.join()); + assertNull(h3.join()); rs[3].assertValue(v1); } catch (CompletionException ok) { checkCompletedWithWrappedException(h3, ex); @@ -2849,28 +2849,28 @@ public class CompletableFutureTest extends JSR166TestCase { // unspecified behavior - both source completions available try { - assertEquals(null, h0.join()); + assertNull(h0.join()); rs[0].assertInvoked(); } catch (CompletionException ok) { checkCompletedWithWrappedException(h0, ex); rs[0].assertNotInvoked(); } try { - assertEquals(null, h1.join()); + assertNull(h1.join()); rs[1].assertInvoked(); } catch (CompletionException ok) { checkCompletedWithWrappedException(h1, ex); rs[1].assertNotInvoked(); } try { - assertEquals(null, h2.join()); + assertNull(h2.join()); rs[2].assertInvoked(); } catch (CompletionException ok) { checkCompletedWithWrappedException(h2, ex); rs[2].assertNotInvoked(); } try { - assertEquals(null, h3.join()); + assertNull(h3.join()); rs[3].assertInvoked(); } catch (CompletionException ok) { checkCompletedWithWrappedException(h3, ex); diff --git a/jdk/test/java/util/concurrent/tck/ConcurrentHashMap8Test.java b/jdk/test/java/util/concurrent/tck/ConcurrentHashMap8Test.java index 00f8dc6bb28..e0d9f81a7f1 100644 --- a/jdk/test/java/util/concurrent/tck/ConcurrentHashMap8Test.java +++ b/jdk/test/java/util/concurrent/tck/ConcurrentHashMap8Test.java @@ -237,8 +237,8 @@ public class ConcurrentHashMap8Test extends JSR166TestCase { Set set1 = map.keySet(); Set set2 = map.keySet(true); set2.add(six); - assertTrue(((ConcurrentHashMap.KeySetView)set2).getMap() == map); - assertTrue(((ConcurrentHashMap.KeySetView)set1).getMap() == map); + assertSame(map, ((ConcurrentHashMap.KeySetView)set2).getMap()); + assertSame(map, ((ConcurrentHashMap.KeySetView)set1).getMap()); assertEquals(set2.size(), map.size()); assertEquals(set1.size(), map.size()); assertTrue((Boolean)map.get(six)); @@ -332,10 +332,10 @@ public class ConcurrentHashMap8Test extends JSR166TestCase { assertFalse(set.add(one)); assertTrue(set.add(six)); assertTrue(set.add(seven)); - assertTrue(set.getMappedValue() == one); - assertTrue(map.get(one) != one); - assertTrue(map.get(six) == one); - assertTrue(map.get(seven) == one); + assertSame(one, set.getMappedValue()); + assertNotSame(one, map.get(one)); + assertSame(one, map.get(six)); + assertSame(one, map.get(seven)); } void checkSpliteratorCharacteristics(Spliterator sp, diff --git a/jdk/test/java/util/concurrent/tck/ConcurrentHashMapTest.java b/jdk/test/java/util/concurrent/tck/ConcurrentHashMapTest.java index 1485d2c4dca..729a6e3d146 100644 --- a/jdk/test/java/util/concurrent/tck/ConcurrentHashMapTest.java +++ b/jdk/test/java/util/concurrent/tck/ConcurrentHashMapTest.java @@ -43,8 +43,6 @@ import java.util.Map; import java.util.Random; import java.util.Set; import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ExecutorService; -import java.util.concurrent.Executors; import junit.framework.Test; import junit.framework.TestSuite; @@ -148,7 +146,7 @@ public class ConcurrentHashMapTest extends JSR166TestCase { ConcurrentHashMap m = new ConcurrentHashMap(); for (int i = 0; i < size; i++) { - assertTrue(m.put(new CI(i), true) == null); + assertNull(m.put(new CI(i), true)); } for (int i = 0; i < size; i++) { assertTrue(m.containsKey(new CI(i))); @@ -169,7 +167,7 @@ public class ConcurrentHashMapTest extends JSR166TestCase { BS bs = new BS(String.valueOf(i)); LexicographicList bis = new LexicographicList(bi); LexicographicList bss = new LexicographicList(bs); - assertTrue(m.putIfAbsent(bis, true) == null); + assertNull(m.putIfAbsent(bis, true)); assertTrue(m.containsKey(bis)); if (m.putIfAbsent(bss, true) == null) assertTrue(m.containsKey(bss)); diff --git a/jdk/test/java/util/concurrent/tck/ConcurrentLinkedDequeTest.java b/jdk/test/java/util/concurrent/tck/ConcurrentLinkedDequeTest.java index aac0bb73910..8a8ffeb6ff9 100644 --- a/jdk/test/java/util/concurrent/tck/ConcurrentLinkedDequeTest.java +++ b/jdk/test/java/util/concurrent/tck/ConcurrentLinkedDequeTest.java @@ -43,7 +43,6 @@ import java.util.Random; import java.util.concurrent.ConcurrentLinkedDeque; import junit.framework.Test; -import junit.framework.TestSuite; public class ConcurrentLinkedDequeTest extends JSR166TestCase { @@ -67,7 +66,7 @@ public class ConcurrentLinkedDequeTest extends JSR166TestCase { * Returns a new deque of given size containing consecutive * Integers 0 ... n - 1. */ - private ConcurrentLinkedDeque populatedDeque(int n) { + private static ConcurrentLinkedDeque populatedDeque(int n) { ConcurrentLinkedDeque q = new ConcurrentLinkedDeque<>(); assertTrue(q.isEmpty()); for (int i = 0; i < n; ++i) diff --git a/jdk/test/java/util/concurrent/tck/ConcurrentLinkedQueueTest.java b/jdk/test/java/util/concurrent/tck/ConcurrentLinkedQueueTest.java index 57689cce48d..ee6827a660f 100644 --- a/jdk/test/java/util/concurrent/tck/ConcurrentLinkedQueueTest.java +++ b/jdk/test/java/util/concurrent/tck/ConcurrentLinkedQueueTest.java @@ -41,7 +41,6 @@ import java.util.Queue; import java.util.concurrent.ConcurrentLinkedQueue; import junit.framework.Test; -import junit.framework.TestSuite; public class ConcurrentLinkedQueueTest extends JSR166TestCase { @@ -65,7 +64,7 @@ public class ConcurrentLinkedQueueTest extends JSR166TestCase { * Returns a new queue of given size containing consecutive * Integers 0 ... n - 1. */ - private ConcurrentLinkedQueue populatedQueue(int n) { + private static ConcurrentLinkedQueue populatedQueue(int n) { ConcurrentLinkedQueue q = new ConcurrentLinkedQueue<>(); assertTrue(q.isEmpty()); for (int i = 0; i < n; ++i) diff --git a/jdk/test/java/util/concurrent/tck/ConcurrentSkipListSetTest.java b/jdk/test/java/util/concurrent/tck/ConcurrentSkipListSetTest.java index ae91219f622..cb28b6ae0e7 100644 --- a/jdk/test/java/util/concurrent/tck/ConcurrentSkipListSetTest.java +++ b/jdk/test/java/util/concurrent/tck/ConcurrentSkipListSetTest.java @@ -64,7 +64,7 @@ public class ConcurrentSkipListSetTest extends JSR166TestCase { * Returns a new set of given size containing consecutive * Integers 0 ... n - 1. */ - private ConcurrentSkipListSet populatedSet(int n) { + private static ConcurrentSkipListSet populatedSet(int n) { ConcurrentSkipListSet q = new ConcurrentSkipListSet(); assertTrue(q.isEmpty()); @@ -80,7 +80,7 @@ public class ConcurrentSkipListSetTest extends JSR166TestCase { /** * Returns a new set of first 5 ints. */ - private ConcurrentSkipListSet set5() { + private static ConcurrentSkipListSet set5() { ConcurrentSkipListSet q = new ConcurrentSkipListSet(); assertTrue(q.isEmpty()); q.add(one); @@ -229,7 +229,7 @@ public class ConcurrentSkipListSetTest extends JSR166TestCase { } catch (ClassCastException success) { assertTrue(q.size() < 2); for (int i = 0, size = q.size(); i < size; i++) - assertTrue(q.pollFirst().getClass() == Object.class); + assertSame(Object.class, q.pollFirst().getClass()); assertNull(q.pollFirst()); assertTrue(q.isEmpty()); assertEquals(0, q.size()); diff --git a/jdk/test/java/util/concurrent/tck/ConcurrentSkipListSubSetTest.java b/jdk/test/java/util/concurrent/tck/ConcurrentSkipListSubSetTest.java index 4b299e74b83..19d34cc01e1 100644 --- a/jdk/test/java/util/concurrent/tck/ConcurrentSkipListSubSetTest.java +++ b/jdk/test/java/util/concurrent/tck/ConcurrentSkipListSubSetTest.java @@ -59,7 +59,7 @@ public class ConcurrentSkipListSubSetTest extends JSR166TestCase { * Returns a new set of given size containing consecutive * Integers 0 ... n - 1. */ - private NavigableSet populatedSet(int n) { + private static NavigableSet populatedSet(int n) { ConcurrentSkipListSet q = new ConcurrentSkipListSet(); assertTrue(q.isEmpty()); @@ -79,7 +79,7 @@ public class ConcurrentSkipListSubSetTest extends JSR166TestCase { /** * Returns a new set of first 5 ints. */ - private NavigableSet set5() { + private static NavigableSet set5() { ConcurrentSkipListSet q = new ConcurrentSkipListSet(); assertTrue(q.isEmpty()); q.add(one); @@ -97,7 +97,7 @@ public class ConcurrentSkipListSubSetTest extends JSR166TestCase { /** * Returns a new set of first 5 negative ints. */ - private NavigableSet dset5() { + private static NavigableSet dset5() { ConcurrentSkipListSet q = new ConcurrentSkipListSet(); assertTrue(q.isEmpty()); q.add(m1); diff --git a/jdk/test/java/util/concurrent/tck/CopyOnWriteArrayListTest.java b/jdk/test/java/util/concurrent/tck/CopyOnWriteArrayListTest.java index 329010b308b..2b13e130701 100644 --- a/jdk/test/java/util/concurrent/tck/CopyOnWriteArrayListTest.java +++ b/jdk/test/java/util/concurrent/tck/CopyOnWriteArrayListTest.java @@ -44,7 +44,6 @@ import java.util.NoSuchElementException; import java.util.concurrent.CopyOnWriteArrayList; import junit.framework.Test; -import junit.framework.TestSuite; public class CopyOnWriteArrayListTest extends JSR166TestCase { diff --git a/jdk/test/java/util/concurrent/tck/CountedCompleter8Test.java b/jdk/test/java/util/concurrent/tck/CountedCompleter8Test.java index eb23564ed77..77e800c23b3 100644 --- a/jdk/test/java/util/concurrent/tck/CountedCompleter8Test.java +++ b/jdk/test/java/util/concurrent/tck/CountedCompleter8Test.java @@ -32,9 +32,6 @@ * http://creativecommons.org/publicdomain/zero/1.0/ */ -import static java.util.concurrent.TimeUnit.MILLISECONDS; -import static java.util.concurrent.TimeUnit.SECONDS; - import java.util.concurrent.CountedCompleter; import java.util.concurrent.ThreadLocalRandom; import java.util.concurrent.atomic.AtomicInteger; diff --git a/jdk/test/java/util/concurrent/tck/CountedCompleterTest.java b/jdk/test/java/util/concurrent/tck/CountedCompleterTest.java index 3113b57a563..66e5bd61761 100644 --- a/jdk/test/java/util/concurrent/tck/CountedCompleterTest.java +++ b/jdk/test/java/util/concurrent/tck/CountedCompleterTest.java @@ -40,7 +40,6 @@ import java.util.concurrent.CountedCompleter; import java.util.concurrent.ExecutionException; import java.util.concurrent.ForkJoinPool; import java.util.concurrent.ForkJoinTask; -import java.util.concurrent.ThreadLocalRandom; import java.util.concurrent.TimeoutException; import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.atomic.AtomicReference; diff --git a/jdk/test/java/util/concurrent/tck/ExchangerTest.java b/jdk/test/java/util/concurrent/tck/ExchangerTest.java index ba6c5443623..36eacc7891e 100644 --- a/jdk/test/java/util/concurrent/tck/ExchangerTest.java +++ b/jdk/test/java/util/concurrent/tck/ExchangerTest.java @@ -160,12 +160,12 @@ public class ExchangerTest extends JSR166TestCase { public void realRun() throws InterruptedException { assertSame(one, e.exchange(two)); exchanged.countDown(); - interrupted.await(); + await(interrupted); assertSame(three, e.exchange(one)); }}); Thread t3 = newStartedThread(new CheckedRunnable() { public void realRun() throws InterruptedException { - interrupted.await(); + await(interrupted); assertSame(one, e.exchange(three)); }}); diff --git a/jdk/test/java/util/concurrent/tck/ExecutorCompletionService9Test.java b/jdk/test/java/util/concurrent/tck/ExecutorCompletionService9Test.java index 4ca78a09a49..92e92478cbc 100644 --- a/jdk/test/java/util/concurrent/tck/ExecutorCompletionService9Test.java +++ b/jdk/test/java/util/concurrent/tck/ExecutorCompletionService9Test.java @@ -37,7 +37,6 @@ import java.util.Collection; import java.util.Comparator; import java.util.List; import java.util.Set; -import java.util.HashSet; import java.util.concurrent.Callable; import java.util.concurrent.CompletionService; import java.util.concurrent.ExecutionException; diff --git a/jdk/test/java/util/concurrent/tck/ExecutorCompletionServiceTest.java b/jdk/test/java/util/concurrent/tck/ExecutorCompletionServiceTest.java index 0ab6084b978..9b7251e6865 100644 --- a/jdk/test/java/util/concurrent/tck/ExecutorCompletionServiceTest.java +++ b/jdk/test/java/util/concurrent/tck/ExecutorCompletionServiceTest.java @@ -172,7 +172,7 @@ public class ExecutorCompletionServiceTest extends JSR166TestCase { CompletionService cs = new ExecutorCompletionService(cachedThreadPool); final CountDownLatch proceed = new CountDownLatch(1); cs.submit(new Callable() { public String call() throws Exception { - proceed.await(); + await(proceed); return TEST_STRING; }}); assertNull(cs.poll()); diff --git a/jdk/test/java/util/concurrent/tck/ExecutorsTest.java b/jdk/test/java/util/concurrent/tck/ExecutorsTest.java index 441a52a5922..90764242502 100644 --- a/jdk/test/java/util/concurrent/tck/ExecutorsTest.java +++ b/jdk/test/java/util/concurrent/tck/ExecutorsTest.java @@ -333,16 +333,12 @@ public class ExecutorsTest extends JSR166TestCase { public void realRun() { try { Thread current = Thread.currentThread(); - assertTrue(!current.isDaemon()); + assertFalse(current.isDaemon()); assertTrue(current.getPriority() <= Thread.NORM_PRIORITY); - ThreadGroup g = current.getThreadGroup(); SecurityManager s = System.getSecurityManager(); - if (s != null) - assertTrue(g == s.getThreadGroup()); - else - assertTrue(g == egroup); - String name = current.getName(); - assertTrue(name.endsWith("thread-1")); + assertSame(current.getThreadGroup(), + (s == null) ? egroup : s.getThreadGroup()); + assertTrue(current.getName().endsWith("thread-1")); } catch (SecurityException ok) { // Also pass if not allowed to change setting } @@ -370,16 +366,12 @@ public class ExecutorsTest extends JSR166TestCase { Runnable r = new CheckedRunnable() { public void realRun() { Thread current = Thread.currentThread(); - assertTrue(!current.isDaemon()); + assertFalse(current.isDaemon()); assertTrue(current.getPriority() <= Thread.NORM_PRIORITY); - ThreadGroup g = current.getThreadGroup(); SecurityManager s = System.getSecurityManager(); - if (s != null) - assertTrue(g == s.getThreadGroup()); - else - assertTrue(g == egroup); - String name = current.getName(); - assertTrue(name.endsWith("thread-1")); + assertSame(current.getThreadGroup(), + (s == null) ? egroup : s.getThreadGroup()); + assertTrue(current.getName().endsWith("thread-1")); assertSame(thisccl, current.getContextClassLoader()); assertEquals(thisacc, AccessController.getContext()); done.countDown(); diff --git a/jdk/test/java/util/concurrent/tck/ForkJoinPool8Test.java b/jdk/test/java/util/concurrent/tck/ForkJoinPool8Test.java index b0fea9a0bfe..f24de8828dc 100644 --- a/jdk/test/java/util/concurrent/tck/ForkJoinPool8Test.java +++ b/jdk/test/java/util/concurrent/tck/ForkJoinPool8Test.java @@ -206,7 +206,7 @@ public class ForkJoinPool8Test extends JSR166TestCase { public FJException(Throwable cause) { super(cause); } } - // A simple recursive action for testing + /** A simple recursive action for testing. */ final class FibAction extends CheckedRecursiveAction { final int number; int result; @@ -224,7 +224,7 @@ public class ForkJoinPool8Test extends JSR166TestCase { } } - // A recursive action failing in base case + /** A recursive action failing in base case. */ static final class FailingFibAction extends RecursiveAction { final int number; int result; @@ -932,7 +932,7 @@ public class ForkJoinPool8Test extends JSR166TestCase { } } - // Version of CCF with forced failure in left completions + /** Version of CCF with forced failure in left completions. */ abstract static class FailingCCF extends CountedCompleter { int number; int rnumber; diff --git a/jdk/test/java/util/concurrent/tck/ForkJoinPool9Test.java b/jdk/test/java/util/concurrent/tck/ForkJoinPool9Test.java index 8a87e473a6f..b4153481d61 100644 --- a/jdk/test/java/util/concurrent/tck/ForkJoinPool9Test.java +++ b/jdk/test/java/util/concurrent/tck/ForkJoinPool9Test.java @@ -32,8 +32,6 @@ * http://creativecommons.org/publicdomain/zero/1.0/ */ -import static java.util.concurrent.TimeUnit.MILLISECONDS; - import java.lang.invoke.MethodHandles; import java.lang.invoke.VarHandle; import java.util.concurrent.CountDownLatch; @@ -93,7 +91,7 @@ public class ForkJoinPool9Test extends JSR166TestCase { Future f = ForkJoinPool.commonPool().submit(runInCommonPool); // Ensure runInCommonPool is truly running in the common pool, // by giving this thread no opportunity to "help" on get(). - assertTrue(taskStarted.await(LONG_DELAY_MS, MILLISECONDS)); + await(taskStarted); assertNull(f.get()); } diff --git a/jdk/test/java/util/concurrent/tck/ForkJoinPoolTest.java b/jdk/test/java/util/concurrent/tck/ForkJoinPoolTest.java index bf5a3652f09..766e35081e3 100644 --- a/jdk/test/java/util/concurrent/tck/ForkJoinPoolTest.java +++ b/jdk/test/java/util/concurrent/tck/ForkJoinPoolTest.java @@ -244,7 +244,7 @@ public class ForkJoinPoolTest extends JSR166TestCase { taskStarted.countDown(); assertEquals(1, p.getPoolSize()); assertEquals(1, p.getActiveThreadCount()); - done.await(); + await(done); }}; Future future = p.submit(task); await(taskStarted); diff --git a/jdk/test/java/util/concurrent/tck/ForkJoinTask8Test.java b/jdk/test/java/util/concurrent/tck/ForkJoinTask8Test.java index c1063da31aa..6415111510c 100644 --- a/jdk/test/java/util/concurrent/tck/ForkJoinTask8Test.java +++ b/jdk/test/java/util/concurrent/tck/ForkJoinTask8Test.java @@ -127,7 +127,8 @@ public class ForkJoinTask8Test extends JSR166TestCase { assertNull(a.getException()); assertNull(a.getRawResult()); if (a instanceof BinaryAsyncAction) - assertTrue(((BinaryAsyncAction)a).getForkJoinTaskTag() == INITIAL_STATE); + assertEquals(INITIAL_STATE, + ((BinaryAsyncAction)a).getForkJoinTaskTag()); try { a.get(0L, SECONDS); @@ -148,7 +149,8 @@ public class ForkJoinTask8Test extends JSR166TestCase { assertNull(a.getException()); assertSame(expected, a.getRawResult()); if (a instanceof BinaryAsyncAction) - assertTrue(((BinaryAsyncAction)a).getForkJoinTaskTag() == COMPLETE_STATE); + assertEquals(COMPLETE_STATE, + ((BinaryAsyncAction)a).getForkJoinTaskTag()); { Thread.currentThread().interrupt(); diff --git a/jdk/test/java/util/concurrent/tck/JSR166TestCase.java b/jdk/test/java/util/concurrent/tck/JSR166TestCase.java index 1037eb8f3e7..9625be26fea 100644 --- a/jdk/test/java/util/concurrent/tck/JSR166TestCase.java +++ b/jdk/test/java/util/concurrent/tck/JSR166TestCase.java @@ -26,8 +26,9 @@ * However, the following notice accompanied the original version of this * file: * - * Written by Doug Lea with assistance from members of JCP JSR-166 - * Expert Group and released to the public domain, as explained at + * Written by Doug Lea and Martin Buchholz with assistance from + * members of JCP JSR-166 Expert Group and released to the public + * domain, as explained at * http://creativecommons.org/publicdomain/zero/1.0/ * Other contributors include Andrew Wright, Jeffrey Hayes, * Pat Fisher, Mike Judd. @@ -35,32 +36,33 @@ /* * @test - * @summary JSR-166 tck tests (conformance testing mode) + * @summary JSR-166 tck tests, in a number of variations. + * The first is the conformance testing variant, + * while others also test implementation details. * @build * * @modules java.management * @run junit/othervm/timeout=1000 JSR166TestCase - */ - -/* - * @test - * @summary JSR-166 tck tests (whitebox tests allowed) - * @build * - * @modules java.base/java.util.concurrent:open - * java.base/java.lang:open - * java.management * @run junit/othervm/timeout=1000 + * --add-opens java.base/java.util.concurrent=ALL-UNNAMED + * --add-opens java.base/java.lang=ALL-UNNAMED * -Djsr166.testImplementationDetails=true * JSR166TestCase * @run junit/othervm/timeout=1000 + * --add-opens java.base/java.util.concurrent=ALL-UNNAMED + * --add-opens java.base/java.lang=ALL-UNNAMED * -Djsr166.testImplementationDetails=true * -Djava.util.concurrent.ForkJoinPool.common.parallelism=0 * JSR166TestCase * @run junit/othervm/timeout=1000 + * --add-opens java.base/java.util.concurrent=ALL-UNNAMED + * --add-opens java.base/java.lang=ALL-UNNAMED * -Djsr166.testImplementationDetails=true * -Djava.util.concurrent.ForkJoinPool.common.parallelism=1 * -Djava.util.secureRandomSeed=true * JSR166TestCase * @run junit/othervm/timeout=1000/policy=tck.policy + * --add-opens java.base/java.util.concurrent=ALL-UNNAMED + * --add-opens java.base/java.lang=ALL-UNNAMED * -Djsr166.testImplementationDetails=true * JSR166TestCase */ @@ -79,8 +81,6 @@ import java.lang.management.ThreadMXBean; import java.lang.reflect.Constructor; import java.lang.reflect.Method; import java.lang.reflect.Modifier; -import java.nio.file.Files; -import java.nio.file.Paths; import java.security.CodeSource; import java.security.Permission; import java.security.PermissionCollection; @@ -118,7 +118,6 @@ import java.util.concurrent.ThreadPoolExecutor; import java.util.concurrent.TimeoutException; import java.util.concurrent.atomic.AtomicBoolean; import java.util.concurrent.atomic.AtomicReference; -import java.util.regex.Matcher; import java.util.regex.Pattern; import junit.framework.AssertionFailedError; @@ -328,9 +327,11 @@ public class JSR166TestCase extends TestCase { // public static String cpuModel() { // try { -// Matcher matcher = Pattern.compile("model name\\s*: (.*)") +// java.util.regex.Matcher matcher +// = Pattern.compile("model name\\s*: (.*)") // .matcher(new String( -// Files.readAllBytes(Paths.get("/proc/cpuinfo")), "UTF-8")); +// java.nio.file.Files.readAllBytes( +// java.nio.file.Paths.get("/proc/cpuinfo")), "UTF-8")); // matcher.find(); // return matcher.group(1); // } catch (Exception ex) { return null; } diff --git a/jdk/test/java/util/concurrent/tck/LinkedBlockingDeque8Test.java b/jdk/test/java/util/concurrent/tck/LinkedBlockingDeque8Test.java index 44dcedc0f01..cdcc7a27334 100644 --- a/jdk/test/java/util/concurrent/tck/LinkedBlockingDeque8Test.java +++ b/jdk/test/java/util/concurrent/tck/LinkedBlockingDeque8Test.java @@ -36,7 +36,6 @@ import java.util.concurrent.LinkedBlockingDeque; import java.util.Spliterator; import junit.framework.Test; -import junit.framework.TestSuite; public class LinkedBlockingDeque8Test extends JSR166TestCase { public static void main(String[] args) { diff --git a/jdk/test/java/util/concurrent/tck/LinkedBlockingDequeTest.java b/jdk/test/java/util/concurrent/tck/LinkedBlockingDequeTest.java index 2559fdffe9d..00fbcc9734b 100644 --- a/jdk/test/java/util/concurrent/tck/LinkedBlockingDequeTest.java +++ b/jdk/test/java/util/concurrent/tck/LinkedBlockingDequeTest.java @@ -85,7 +85,7 @@ public class LinkedBlockingDequeTest extends JSR166TestCase { * Returns a new deque of given size containing consecutive * Integers 0 ... n - 1. */ - private LinkedBlockingDeque populatedDeque(int n) { + private static LinkedBlockingDeque populatedDeque(int n) { LinkedBlockingDeque q = new LinkedBlockingDeque(n); assertTrue(q.isEmpty()); @@ -801,7 +801,7 @@ public class LinkedBlockingDequeTest extends JSR166TestCase { } }}); - aboutToWait.await(); + await(aboutToWait); waitForThreadToEnterWaitState(t); t.interrupt(); awaitTermination(t); diff --git a/jdk/test/java/util/concurrent/tck/LinkedBlockingQueue8Test.java b/jdk/test/java/util/concurrent/tck/LinkedBlockingQueue8Test.java index 9900c33da70..2c3e498aeaa 100644 --- a/jdk/test/java/util/concurrent/tck/LinkedBlockingQueue8Test.java +++ b/jdk/test/java/util/concurrent/tck/LinkedBlockingQueue8Test.java @@ -36,7 +36,6 @@ import java.util.concurrent.LinkedBlockingQueue; import java.util.Spliterator; import junit.framework.Test; -import junit.framework.TestSuite; public class LinkedBlockingQueue8Test extends JSR166TestCase { public static void main(String[] args) { diff --git a/jdk/test/java/util/concurrent/tck/LinkedBlockingQueueTest.java b/jdk/test/java/util/concurrent/tck/LinkedBlockingQueueTest.java index 153cbce667a..cdccb75ed87 100644 --- a/jdk/test/java/util/concurrent/tck/LinkedBlockingQueueTest.java +++ b/jdk/test/java/util/concurrent/tck/LinkedBlockingQueueTest.java @@ -85,7 +85,7 @@ public class LinkedBlockingQueueTest extends JSR166TestCase { * Returns a new queue of given size containing consecutive * Integers 0 ... n - 1. */ - private LinkedBlockingQueue populatedQueue(int n) { + private static LinkedBlockingQueue populatedQueue(int n) { LinkedBlockingQueue q = new LinkedBlockingQueue(n); assertTrue(q.isEmpty()); diff --git a/jdk/test/java/util/concurrent/tck/LinkedListTest.java b/jdk/test/java/util/concurrent/tck/LinkedListTest.java index 08a2ddd9dab..66dd8c02c7a 100644 --- a/jdk/test/java/util/concurrent/tck/LinkedListTest.java +++ b/jdk/test/java/util/concurrent/tck/LinkedListTest.java @@ -40,7 +40,6 @@ import java.util.LinkedList; import java.util.NoSuchElementException; import junit.framework.Test; -import junit.framework.TestSuite; public class LinkedListTest extends JSR166TestCase { public static void main(String[] args) { @@ -70,7 +69,7 @@ public class LinkedListTest extends JSR166TestCase { * Returns a new queue of given size containing consecutive * Integers 0 ... n - 1. */ - private LinkedList populatedQueue(int n) { + private static LinkedList populatedQueue(int n) { LinkedList q = new LinkedList<>(); assertTrue(q.isEmpty()); for (int i = 0; i < n; ++i) diff --git a/jdk/test/java/util/concurrent/tck/LinkedTransferQueueTest.java b/jdk/test/java/util/concurrent/tck/LinkedTransferQueueTest.java index 6a22b0e20a9..7f38351a30a 100644 --- a/jdk/test/java/util/concurrent/tck/LinkedTransferQueueTest.java +++ b/jdk/test/java/util/concurrent/tck/LinkedTransferQueueTest.java @@ -321,7 +321,7 @@ public class LinkedTransferQueueTest extends JSR166TestCase { assertTrue(millisElapsedSince(startTime) < LONG_DELAY_MS); }}); - aboutToWait.await(); + await(aboutToWait); waitForThreadToEnterWaitState(t); t.interrupt(); awaitTermination(t); @@ -826,7 +826,7 @@ public class LinkedTransferQueueTest extends JSR166TestCase { Thread first = newStartedThread(new CheckedRunnable() { public void realRun() throws InterruptedException { q.transfer(four); - assertTrue(!q.contains(four)); + assertFalse(q.contains(four)); assertEquals(1, q.size()); }}); diff --git a/jdk/test/java/util/concurrent/tck/PriorityBlockingQueueTest.java b/jdk/test/java/util/concurrent/tck/PriorityBlockingQueueTest.java index 088c389b2cc..aa826b80f1b 100644 --- a/jdk/test/java/util/concurrent/tck/PriorityBlockingQueueTest.java +++ b/jdk/test/java/util/concurrent/tck/PriorityBlockingQueueTest.java @@ -93,7 +93,7 @@ public class PriorityBlockingQueueTest extends JSR166TestCase { * Returns a new queue of given size containing consecutive * Integers 0 ... n - 1. */ - private PriorityBlockingQueue populatedQueue(int n) { + private static PriorityBlockingQueue populatedQueue(int n) { PriorityBlockingQueue q = new PriorityBlockingQueue(n); assertTrue(q.isEmpty()); @@ -445,7 +445,7 @@ public class PriorityBlockingQueueTest extends JSR166TestCase { } }}); - aboutToWait.await(); + await(aboutToWait); waitForThreadToEnterWaitState(t); t.interrupt(); awaitTermination(t); diff --git a/jdk/test/java/util/concurrent/tck/PriorityQueueTest.java b/jdk/test/java/util/concurrent/tck/PriorityQueueTest.java index c1564730cdf..1c3984dd197 100644 --- a/jdk/test/java/util/concurrent/tck/PriorityQueueTest.java +++ b/jdk/test/java/util/concurrent/tck/PriorityQueueTest.java @@ -42,7 +42,6 @@ import java.util.PriorityQueue; import java.util.Queue; import junit.framework.Test; -import junit.framework.TestSuite; public class PriorityQueueTest extends JSR166TestCase { public static void main(String[] args) { @@ -70,7 +69,7 @@ public class PriorityQueueTest extends JSR166TestCase { * Returns a new queue of given size containing consecutive * Integers 0 ... n - 1. */ - private PriorityQueue populatedQueue(int n) { + private static PriorityQueue populatedQueue(int n) { PriorityQueue q = new PriorityQueue<>(n); assertTrue(q.isEmpty()); for (int i = n - 1; i >= 0; i -= 2) diff --git a/jdk/test/java/util/concurrent/tck/RecursiveActionTest.java b/jdk/test/java/util/concurrent/tck/RecursiveActionTest.java index 01bd92770b7..132b8dad7b0 100644 --- a/jdk/test/java/util/concurrent/tck/RecursiveActionTest.java +++ b/jdk/test/java/util/concurrent/tck/RecursiveActionTest.java @@ -195,7 +195,7 @@ public class RecursiveActionTest extends JSR166TestCase { public FJException(Throwable cause) { super(cause); } } - // A simple recursive action for testing + /** A simple recursive action for testing. */ final class FibAction extends CheckedRecursiveAction { final int number; int result; @@ -213,7 +213,7 @@ public class RecursiveActionTest extends JSR166TestCase { } } - // A recursive action failing in base case + /** A recursive action failing in base case. */ static final class FailingFibAction extends RecursiveAction { final int number; int result; diff --git a/jdk/test/java/util/concurrent/tck/RecursiveTaskTest.java b/jdk/test/java/util/concurrent/tck/RecursiveTaskTest.java index ce13daa8e7b..49723adcff7 100644 --- a/jdk/test/java/util/concurrent/tck/RecursiveTaskTest.java +++ b/jdk/test/java/util/concurrent/tck/RecursiveTaskTest.java @@ -210,10 +210,10 @@ public class RecursiveTaskTest extends JSR166TestCase { public FJException() { super(); } } - // An invalid return value for Fib + /** An invalid return value for Fib. */ static final Integer NoResult = Integer.valueOf(-17); - // A simple recursive task for testing + /** A simple recursive task for testing. */ final class FibTask extends CheckedRecursiveTask { final int number; FibTask(int n) { number = n; } @@ -231,7 +231,7 @@ public class RecursiveTaskTest extends JSR166TestCase { } } - // A recursive action failing in base case + /** A recursive action failing in base case. */ final class FailingFibTask extends RecursiveTask { final int number; int result; diff --git a/jdk/test/java/util/concurrent/tck/StampedLockTest.java b/jdk/test/java/util/concurrent/tck/StampedLockTest.java index 65ef48d046b..5f44312c88c 100644 --- a/jdk/test/java/util/concurrent/tck/StampedLockTest.java +++ b/jdk/test/java/util/concurrent/tck/StampedLockTest.java @@ -518,7 +518,7 @@ public class StampedLockTest extends JSR166TestCase { lock.unlockWrite(s); }}); - aboutToLock.await(); + await(aboutToLock); waitForThreadToEnterWaitState(t); assertFalse(lock.isWriteLocked()); assertTrue(lock.isReadLocked()); @@ -777,7 +777,7 @@ public class StampedLockTest extends JSR166TestCase { lock.writeLockInterruptibly(); }}); - locked.await(); + await(locked); assertFalse(lock.validate(p)); assertEquals(0L, lock.tryOptimisticRead()); waitForThreadToEnterWaitState(t); diff --git a/jdk/test/java/util/concurrent/tck/SubmissionPublisherTest.java b/jdk/test/java/util/concurrent/tck/SubmissionPublisherTest.java index 102d1b5e3ef..ecd472f2cbe 100644 --- a/jdk/test/java/util/concurrent/tck/SubmissionPublisherTest.java +++ b/jdk/test/java/util/concurrent/tck/SubmissionPublisherTest.java @@ -519,7 +519,7 @@ public class SubmissionPublisherTest extends JSR166TestCase { s1.request = false; p.subscribe(s1); s1.awaitSubscribe(); - assertTrue(p.estimateMinimumDemand() == 0); + assertEquals(0, p.estimateMinimumDemand()); TestSubscriber s2 = new TestSubscriber(); p.subscribe(s2); p.submit(1); diff --git a/jdk/test/java/util/concurrent/tck/SynchronousQueueTest.java b/jdk/test/java/util/concurrent/tck/SynchronousQueueTest.java index 345ac9c7305..afa4f5c026c 100644 --- a/jdk/test/java/util/concurrent/tck/SynchronousQueueTest.java +++ b/jdk/test/java/util/concurrent/tck/SynchronousQueueTest.java @@ -596,7 +596,7 @@ public class SynchronousQueueTest extends JSR166TestCase { fail("timed out"); Thread.yield(); } - assertTrue(l.size() == 1); + assertEquals(1, l.size()); assertSame(one, l.get(0)); awaitTermination(t); } diff --git a/jdk/test/java/util/concurrent/tck/ThreadPoolExecutorSubclassTest.java b/jdk/test/java/util/concurrent/tck/ThreadPoolExecutorSubclassTest.java index 38862ceee5d..90065c65790 100644 --- a/jdk/test/java/util/concurrent/tck/ThreadPoolExecutorSubclassTest.java +++ b/jdk/test/java/util/concurrent/tck/ThreadPoolExecutorSubclassTest.java @@ -265,7 +265,7 @@ public class ThreadPoolExecutorSubclassTest extends JSR166TestCase { final Runnable task = new CheckedRunnable() { public void realRun() { done.countDown(); }}; p.execute(task); - assertTrue(done.await(LONG_DELAY_MS, MILLISECONDS)); + await(done); } } @@ -359,13 +359,13 @@ public class ThreadPoolExecutorSubclassTest extends JSR166TestCase { public void realRun() throws InterruptedException { threadStarted.countDown(); assertEquals(0, p.getCompletedTaskCount()); - threadProceed.await(); + await(threadProceed); threadDone.countDown(); }}); await(threadStarted); assertEquals(0, p.getCompletedTaskCount()); threadProceed.countDown(); - threadDone.await(); + await(threadDone); long startTime = System.nanoTime(); while (p.getCompletedTaskCount() != 1) { if (millisElapsedSince(startTime) > LONG_DELAY_MS) @@ -1953,7 +1953,7 @@ public class ThreadPoolExecutorSubclassTest extends JSR166TestCase { public void realRun() { done.countDown(); }}); - assertTrue(done.await(LONG_DELAY_MS, MILLISECONDS)); + await(done); } } diff --git a/jdk/test/java/util/concurrent/tck/ThreadPoolExecutorTest.java b/jdk/test/java/util/concurrent/tck/ThreadPoolExecutorTest.java index cf0b0971270..9cbb98562f6 100644 --- a/jdk/test/java/util/concurrent/tck/ThreadPoolExecutorTest.java +++ b/jdk/test/java/util/concurrent/tck/ThreadPoolExecutorTest.java @@ -45,7 +45,6 @@ import java.util.concurrent.Callable; import java.util.concurrent.CancellationException; import java.util.concurrent.CountDownLatch; import java.util.concurrent.ExecutionException; -import java.util.concurrent.Executors; import java.util.concurrent.ExecutorService; import java.util.concurrent.Future; import java.util.concurrent.FutureTask; @@ -118,7 +117,7 @@ public class ThreadPoolExecutorTest extends JSR166TestCase { final Runnable task = new CheckedRunnable() { public void realRun() { done.countDown(); }}; p.execute(task); - assertTrue(done.await(LONG_DELAY_MS, MILLISECONDS)); + await(done); } } @@ -212,13 +211,13 @@ public class ThreadPoolExecutorTest extends JSR166TestCase { public void realRun() throws InterruptedException { threadStarted.countDown(); assertEquals(0, p.getCompletedTaskCount()); - threadProceed.await(); + await(threadProceed); threadDone.countDown(); }}); await(threadStarted); assertEquals(0, p.getCompletedTaskCount()); threadProceed.countDown(); - threadDone.await(); + await(threadDone); long startTime = System.nanoTime(); while (p.getCompletedTaskCount() != 1) { if (millisElapsedSince(startTime) > LONG_DELAY_MS) @@ -301,6 +300,20 @@ public class ThreadPoolExecutorTest extends JSR166TestCase { } } + /** + * The default rejected execution handler is AbortPolicy. + */ + public void testDefaultRejectedExecutionHandler() { + final ThreadPoolExecutor p = + new ThreadPoolExecutor(1, 2, + LONG_DELAY_MS, MILLISECONDS, + new ArrayBlockingQueue(10)); + try (PoolCleaner cleaner = cleaner(p)) { + assertTrue(p.getRejectedExecutionHandler() + instanceof ThreadPoolExecutor.AbortPolicy); + } + } + /** * getRejectedExecutionHandler returns handler in constructor if not set */ @@ -1139,7 +1152,7 @@ public class ThreadPoolExecutorTest extends JSR166TestCase { await(done); }}; for (int i = 0; i < 2; ++i) - p.submit(Executors.callable(task)); + p.execute(task); for (int i = 0; i < 2; ++i) { try { p.execute(task); @@ -1955,7 +1968,7 @@ public class ThreadPoolExecutorTest extends JSR166TestCase { public void realRun() { done.countDown(); }}); - assertTrue(done.await(LONG_DELAY_MS, MILLISECONDS)); + await(done); } } @@ -2048,7 +2061,7 @@ public class ThreadPoolExecutorTest extends JSR166TestCase { } } // enough time to run all tasks - assertTrue(done.await(nTasks * SHORT_DELAY_MS, MILLISECONDS)); + await(done, nTasks * SHORT_DELAY_MS); } } diff --git a/jdk/test/java/util/concurrent/tck/ThreadTest.java b/jdk/test/java/util/concurrent/tck/ThreadTest.java index 92b2aca52a6..1cd9f0fbce4 100644 --- a/jdk/test/java/util/concurrent/tck/ThreadTest.java +++ b/jdk/test/java/util/concurrent/tck/ThreadTest.java @@ -76,7 +76,7 @@ public class ThreadTest extends JSR166TestCase { * setDefaultUncaughtExceptionHandler. */ public void testGetAndSetDefaultUncaughtExceptionHandler() { - assertEquals(null, Thread.getDefaultUncaughtExceptionHandler()); + assertNull(Thread.getDefaultUncaughtExceptionHandler()); // failure due to SecurityException is OK. // Would be nice to explicitly test both ways, but cannot yet. Thread.UncaughtExceptionHandler defaultHandler diff --git a/jdk/test/java/util/concurrent/tck/TreeSetTest.java b/jdk/test/java/util/concurrent/tck/TreeSetTest.java index a37922e525b..55b28d613d9 100644 --- a/jdk/test/java/util/concurrent/tck/TreeSetTest.java +++ b/jdk/test/java/util/concurrent/tck/TreeSetTest.java @@ -69,7 +69,7 @@ public class TreeSetTest extends JSR166TestCase { * Returns a new set of given size containing consecutive * Integers 0 ... n - 1. */ - private TreeSet populatedSet(int n) { + private static TreeSet populatedSet(int n) { TreeSet q = new TreeSet<>(); assertTrue(q.isEmpty()); for (int i = n - 1; i >= 0; i -= 2) @@ -84,7 +84,7 @@ public class TreeSetTest extends JSR166TestCase { /** * Returns a new set of first 5 ints. */ - private TreeSet set5() { + private static TreeSet set5() { TreeSet q = new TreeSet(); assertTrue(q.isEmpty()); q.add(one); diff --git a/jdk/test/java/util/concurrent/tck/TreeSubSetTest.java b/jdk/test/java/util/concurrent/tck/TreeSubSetTest.java index 37edc1fb04c..a0f2b96ee57 100644 --- a/jdk/test/java/util/concurrent/tck/TreeSubSetTest.java +++ b/jdk/test/java/util/concurrent/tck/TreeSubSetTest.java @@ -60,7 +60,7 @@ public class TreeSubSetTest extends JSR166TestCase { * Returns a new set of given size containing consecutive * Integers 0 ... n - 1. */ - private NavigableSet populatedSet(int n) { + private static NavigableSet populatedSet(int n) { TreeSet q = new TreeSet<>(); assertTrue(q.isEmpty()); @@ -79,7 +79,7 @@ public class TreeSubSetTest extends JSR166TestCase { /** * Returns a new set of first 5 ints. */ - private NavigableSet set5() { + private static NavigableSet set5() { TreeSet q = new TreeSet(); assertTrue(q.isEmpty()); q.add(one); @@ -94,7 +94,7 @@ public class TreeSubSetTest extends JSR166TestCase { return s; } - private NavigableSet dset5() { + private static NavigableSet dset5() { TreeSet q = new TreeSet(); assertTrue(q.isEmpty()); q.add(m1); diff --git a/jdk/test/java/util/concurrent/tck/VectorTest.java b/jdk/test/java/util/concurrent/tck/VectorTest.java index 78c236402f6..1878a78cc93 100644 --- a/jdk/test/java/util/concurrent/tck/VectorTest.java +++ b/jdk/test/java/util/concurrent/tck/VectorTest.java @@ -33,11 +33,9 @@ */ import java.util.Vector; -import java.util.Collection; import java.util.List; import junit.framework.Test; -import junit.framework.TestSuite; public class VectorTest extends JSR166TestCase { public static void main(String[] args) { diff --git a/jdk/test/java/util/jar/JarFile/mrjar/MultiReleaseJarAPI.java b/jdk/test/java/util/jar/JarFile/mrjar/MultiReleaseJarAPI.java index f0b35d06a94..3299f674adb 100644 --- a/jdk/test/java/util/jar/JarFile/mrjar/MultiReleaseJarAPI.java +++ b/jdk/test/java/util/jar/JarFile/mrjar/MultiReleaseJarAPI.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,9 +26,9 @@ * @bug 8132734 8144062 8165723 * @summary Test the extended API and the aliasing additions in JarFile that * support multi-release jar files - * @library /lib/testlibrary/java/util/jar /lib/testlibrary/ - * @build Compiler JarBuilder CreateMultiReleaseTestJars - * @build jdk.testlibrary.RandomFactory + * @library /lib/testlibrary/java/util/jar /test/lib + * @build jdk.test.lib.RandomFactory + * Compiler JarBuilder CreateMultiReleaseTestJars * @run testng MultiReleaseJarAPI */ @@ -45,7 +45,7 @@ import java.util.jar.JarFile; import java.util.zip.ZipEntry; import java.util.zip.ZipFile; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; import org.testng.Assert; import org.testng.annotations.AfterClass; diff --git a/jdk/test/java/util/logging/FileHandlerMaxLocksTest.java b/jdk/test/java/util/logging/FileHandlerMaxLocksTest.java index fef03b2ef89..4f19b5be789 100644 --- a/jdk/test/java/util/logging/FileHandlerMaxLocksTest.java +++ b/jdk/test/java/util/logging/FileHandlerMaxLocksTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,8 +28,9 @@ * "java.util.logging.FileHandler.maxLocks" which will be present in * "logging.properties" file with default value of 100. This property can be * overriden by specifying this property in the custom config file. - * @library /lib/testlibrary - * @build jdk.testlibrary.FileUtils + * @library /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @author rpatil * @run main/othervm FileHandlerMaxLocksTest */ @@ -40,7 +41,7 @@ import java.nio.file.Paths; import java.util.ArrayList; import java.util.List; import java.util.logging.FileHandler; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; public class FileHandlerMaxLocksTest { diff --git a/jdk/test/java/util/logging/modules/GetResourceBundleTest.java b/jdk/test/java/util/logging/modules/GetResourceBundleTest.java index 5c771b949e5..5167a21ee1d 100644 --- a/jdk/test/java/util/logging/modules/GetResourceBundleTest.java +++ b/jdk/test/java/util/logging/modules/GetResourceBundleTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,15 +30,17 @@ import org.testng.annotations.Test; import static java.nio.file.StandardCopyOption.REPLACE_EXISTING; import static jdk.testlibrary.ProcessTools.*; +import jdk.test.lib.compiler.CompilerUtils; import static org.testng.Assert.*; /** * @test * @bug 8129126 8136802 8137316 8137317 8136804 8139350 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler * java.logging - * @build GetResourceBundleTest CompilerUtils jdk.testlibrary.ProcessTools + * @build GetResourceBundleTest jdk.testlibrary.ProcessTools + * jdk.test.lib.compiler.CompilerUtils * @run testng GetResourceBundleTest * @summary Tests Logger.getLogger + logger.getResourceBundle in an named/unnamed module, * resources are in named and unnamed modules respectively. diff --git a/jdk/test/java/util/regex/PatternStreamTest.java b/jdk/test/java/util/regex/PatternStreamTest.java index 9809ea20aef..28d0eb06ccb 100644 --- a/jdk/test/java/util/regex/PatternStreamTest.java +++ b/jdk/test/java/util/regex/PatternStreamTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,7 @@ * @test * @bug 8016846 8024341 8071479 8145006 * @summary Unit tests stream and lambda-based methods on Pattern and Matcher - * @library ../stream/bootlib + * @library /lib/testlibrary/bootlib * @build java.base/java.util.stream.OpTestCase * @run testng/othervm PatternStreamTest */ diff --git a/jdk/test/java/util/regex/RegExTest.java b/jdk/test/java/util/regex/RegExTest.java index d60c1caaf3d..b61ea07e577 100644 --- a/jdk/test/java/util/regex/RegExTest.java +++ b/jdk/test/java/util/regex/RegExTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,8 +37,8 @@ * 6328855 6192895 6345469 6988218 6693451 7006761 8140212 8143282 8158482 * 8176029 * - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main RegExTest * @key randomness */ @@ -52,7 +52,7 @@ import java.nio.file.*; import java.util.*; import java.nio.CharBuffer; import java.util.function.Predicate; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * This is a test class created to check the operation of diff --git a/jdk/test/java/util/stream/boottest/TEST.properties b/jdk/test/java/util/stream/boottest/TEST.properties index 3c930e3afa3..565242e959b 100644 --- a/jdk/test/java/util/stream/boottest/TEST.properties +++ b/jdk/test/java/util/stream/boottest/TEST.properties @@ -1,4 +1,4 @@ # This file identifies root(s) of the test-ng hierarchy. TestNG.dirs = . -lib.dirs = /java/util/stream/bootlib +lib.dirs = /lib/testlibrary/bootlib diff --git a/jdk/test/java/util/stream/test/TEST.properties b/jdk/test/java/util/stream/test/TEST.properties index 4128f6afd75..2eb6c198177 100644 --- a/jdk/test/java/util/stream/test/TEST.properties +++ b/jdk/test/java/util/stream/test/TEST.properties @@ -2,7 +2,7 @@ TestNG.dirs = . -lib.dirs = /java/util/stream/bootlib +lib.dirs = /lib/testlibrary/bootlib # Tests that must run in othervm mode othervm.dirs= /java/util/stream diff --git a/jdk/test/java/util/stream/test/org/openjdk/tests/java/util/NullArgsTestCase.java b/jdk/test/java/util/stream/test/org/openjdk/tests/java/util/NullArgsTestCase.java deleted file mode 100644 index 5cae1ba7459..00000000000 --- a/jdk/test/java/util/stream/test/org/openjdk/tests/java/util/NullArgsTestCase.java +++ /dev/null @@ -1,70 +0,0 @@ -/* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ -package org.openjdk.tests.java.util; - -import org.testng.annotations.Test; - -import java.util.Arrays; -import java.util.function.Consumer; - -import static org.testng.Assert.fail; - -/** - * NullArgsTestCase -- Given a Consumer<Object[]>, and an Object[] array of args, call the block with the args, - * assert success, and then call the consumer N times, each time setting one of the args to null, and assert that - * all these throw NPE. - * - * Typically this would be combined with a DataProvider that serves up combinations of things to be tested, as in - * IteratorsNullTest. - */ -public abstract class NullArgsTestCase { - public final String name; - public final Consumer sink; - public final Object[] args; - - protected NullArgsTestCase(String name, Consumer sink, Object[] args) { - this.name = name; - this.sink = sink; - this.args = args; - } - - @Test - public void goodNonNull() { - sink.accept(args); - } - - @Test - public void throwWithNull() { - for (int i=0; i 255 chars long */ import java.io.*; import java.util.jar.*; -import java.util.zip.*; import java.util.Stack; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; public class ReadLongZipFileName { private static String entryName = "testFile.txt";; diff --git a/jdk/test/java/util/zip/ZipFile/ZipEntryFreeTest.java b/jdk/test/java/util/zip/ZipFile/ZipEntryFreeTest.java index 7695a339cc8..d5611558d27 100644 --- a/jdk/test/java/util/zip/ZipFile/ZipEntryFreeTest.java +++ b/jdk/test/java/util/zip/ZipFile/ZipEntryFreeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,8 +24,9 @@ /* @test * @bug 6907252 * @summary ZipFileInputStream Not Thread-Safe - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @run main ZipEntryFreeTest */ @@ -35,7 +36,7 @@ import java.util.Random; import java.util.Timer; import java.util.TimerTask; import java.util.zip.*; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; public class ZipEntryFreeTest extends Thread { diff --git a/jdk/test/javax/crypto/Cipher/ExampleVectors/CheckExampleVectors.java b/jdk/test/javax/crypto/Cipher/ExampleVectors/CheckExampleVectors.java new file mode 100644 index 00000000000..08cddef6bb8 --- /dev/null +++ b/jdk/test/javax/crypto/Cipher/ExampleVectors/CheckExampleVectors.java @@ -0,0 +1,248 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8006259 + * @summary Test several modes of operation using vectors from SP 800-38A + * @modules java.xml.bind + * @run main CheckExampleVectors + */ + +import java.io.*; +import java.security.*; +import java.util.*; +import java.util.function.*; +import javax.xml.bind.DatatypeConverter; +import javax.crypto.*; +import javax.crypto.spec.*; + +public class CheckExampleVectors { + + private enum Mode { + ECB, + CBC, + CFB1, + CFB8, + CFB128, + OFB, + CTR + } + + private enum Operation { + Encrypt, + Decrypt + } + + private static class Block { + private byte[] input; + private byte[] output; + + public Block() { + + } + public Block(String settings) { + String[] settingsParts = settings.split(","); + input = stringToBytes(settingsParts[0]); + output = stringToBytes(settingsParts[1]); + } + public byte[] getInput() { + return input; + } + public byte[] getOutput() { + return output; + } + } + + private static class TestVector { + private Mode mode; + private Operation operation; + private byte[] key; + private byte[] iv; + private List blocks = new ArrayList(); + + public TestVector(String settings) { + String[] settingsParts = settings.split(","); + mode = Mode.valueOf(settingsParts[0]); + operation = Operation.valueOf(settingsParts[1]); + key = stringToBytes(settingsParts[2]); + if (settingsParts.length > 3) { + iv = stringToBytes(settingsParts[3]); + } + } + + public Mode getMode() { + return mode; + } + public Operation getOperation() { + return operation; + } + public byte[] getKey() { + return key; + } + public byte[] getIv() { + return iv; + } + public void addBlock (Block b) { + blocks.add(b); + } + public Iterable getBlocks() { + return blocks; + } + } + + private static final String VECTOR_FILE_NAME = "NIST_800_38A_vectors.txt"; + private static final Mode[] REQUIRED_MODES = {Mode.ECB, Mode.CBC, Mode.CTR}; + private static Set supportedModes = new HashSet(); + + public static void main(String[] args) throws Exception { + checkAllProviders(); + checkSupportedModes(); + } + + private static byte[] stringToBytes(String v) { + if (v.equals("")) { + return null; + } + return DatatypeConverter.parseBase64Binary(v); + } + + private static String toModeString(Mode mode) { + return mode.toString(); + } + + private static int toCipherOperation(Operation op) { + switch (op) { + case Encrypt: + return Cipher.ENCRYPT_MODE; + case Decrypt: + return Cipher.DECRYPT_MODE; + } + + throw new RuntimeException("Unknown operation: " + op); + } + + private static void log(String str) { + System.out.println(str); + } + + private static void checkVector(String providerName, TestVector test) { + + String modeString = toModeString(test.getMode()); + String cipherString = "AES" + "/" + modeString + "/" + "NoPadding"; + log("checking: " + cipherString + " on " + providerName); + try { + Cipher cipher = Cipher.getInstance(cipherString, providerName); + SecretKeySpec key = new SecretKeySpec(test.getKey(), "AES"); + if (test.getIv() != null) { + IvParameterSpec iv = new IvParameterSpec(test.getIv()); + cipher.init(toCipherOperation(test.getOperation()), key, iv); + } + else { + cipher.init(toCipherOperation(test.getOperation()), key); + } + int blockIndex = 0; + for (Block curBlock : test.getBlocks()) { + byte[] blockOutput = cipher.update(curBlock.getInput()); + byte[] expectedBlockOutput = curBlock.getOutput(); + if (!Arrays.equals(blockOutput, expectedBlockOutput)) { + throw new RuntimeException("Blocks do not match at index " + + blockIndex); + } + blockIndex++; + } + log("success"); + supportedModes.add(test.getMode()); + } catch (NoSuchAlgorithmException ex) { + log("algorithm not supported"); + } catch (NoSuchProviderException | NoSuchPaddingException + | InvalidKeyException | InvalidAlgorithmParameterException ex) { + throw new RuntimeException(ex); + } + } + + private static boolean isComment(String line) { + return (line != null) && line.startsWith("//"); + } + + private static TestVector readVector(BufferedReader in) throws IOException { + String line; + while (isComment(line = in.readLine())) { + // skip comment lines + } + if (line == null || line.isEmpty()) { + return null; + } + + TestVector newVector = new TestVector(line); + String numBlocksStr = in.readLine(); + int numBlocks = Integer.parseInt(numBlocksStr); + for (int i = 0; i < numBlocks; i++) { + Block newBlock = new Block(in.readLine()); + newVector.addBlock(newBlock); + } + + return newVector; + } + + private static void checkAllProviders() throws IOException { + File dataFile = new File(System.getProperty("test.src", "."), + VECTOR_FILE_NAME); + BufferedReader in = new BufferedReader(new FileReader(dataFile)); + List allTests = new ArrayList<>(); + TestVector newTest; + while ((newTest = readVector(in)) != null) { + allTests.add(newTest); + } + + for (Provider provider : Security.getProviders()) { + checkProvider(provider.getName(), allTests); + } + } + + private static void checkProvider(String providerName, + List allVectors) + throws IOException { + + for (TestVector curVector : allVectors) { + checkVector(providerName, curVector); + } + } + + /* + * This method helps ensure that the test is working properly by + * verifying that the test was able to check the test vectors for + * some of the modes of operation. + */ + private static void checkSupportedModes() { + for (Mode curMode : REQUIRED_MODES) { + if (!supportedModes.contains(curMode)) { + throw new RuntimeException( + "Mode not supported by any provider: " + curMode); + } + } + + } + +} + diff --git a/jdk/test/javax/crypto/Cipher/ExampleVectors/NIST_800_38A_vectors.txt b/jdk/test/javax/crypto/Cipher/ExampleVectors/NIST_800_38A_vectors.txt new file mode 100644 index 00000000000..aca903e487f --- /dev/null +++ b/jdk/test/javax/crypto/Cipher/ExampleVectors/NIST_800_38A_vectors.txt @@ -0,0 +1,418 @@ +// Example vectors from NIST Special Publication 800-38A +// Recommentation for Block Cipher Modes of Operation +// +// format for each vector entry is as follows: +// mode,encrypt/decrypt,key,initialization vector +// number of blocks +// (for each block) input,output +// All key, IV, input, and output values are encoded in Base64 +// +ECB,Encrypt,K34VFiiu0qar9xWICc9PPA==, +4 +a8G+4i5An5bpPX4Rc5MXKg==,Otd7tA16NmConsrzJGbvlw== +ri2KVx4DrJyet2+sRa+OUQ==,9dPVhQO5aZ3nhYlalv26rw== +MMgcRqNc5BHl+8EZGgpS7w==,Q7HNf1mOziOIGwDj7QMGiA== +9p8kRd9PmxetK0F75mw3EA==,ewx4XiforT+CIyBxBHJd1A== +ECB,Decrypt,K34VFiiu0qar9xWICc9PPA==, +4 +Otd7tA16NmConsrzJGbvlw==,a8G+4i5An5bpPX4Rc5MXKg== +9dPVhQO5aZ3nhYlalv26rw==,ri2KVx4DrJyet2+sRa+OUQ== +Q7HNf1mOziOIGwDj7QMGiA==,MMgcRqNc5BHl+8EZGgpS7w== +ewx4XiforT+CIyBxBHJd1A==,9p8kRd9PmxetK0F75mw3EA== +ECB,Encrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7, +4 +a8G+4i5An5bpPX4Rc5MXKg==,vTNPHW5F8l/3EqIUVx+lzA== +ri2KVx4DrJyet2+sRa+OUQ==,l0EEhG0K0613NOyz7O5O7w== +MMgcRqNc5BHl+8EZGgpS7w==,73r9InDi5grc4LovrOZETg== +9p8kRd9PmxetK0F75mw3EA==,mktBunONbHL7FmkWA8GODg== +ECB,Decrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7, +4 +vTNPHW5F8l/3EqIUVx+lzA==,a8G+4i5An5bpPX4Rc5MXKg== +l0EEhG0K0613NOyz7O5O7w==,ri2KVx4DrJyet2+sRa+OUQ== +73r9InDi5grc4LovrOZETg==,MMgcRqNc5BHl+8EZGgpS7w== +mktBunONbHL7FmkWA8GODg==,9p8kRd9PmxetK0F75mw3EA== +ECB,Encrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=, +4 +a8G+4i5An5bpPX4Rc5MXKg==,8+7RvbXSoDwGS1p+PbGB+A== +ri2KVx4DrJyet2+sRa+OUQ==,WRzLENQQ7SbcW6dKMTYocA== +MMgcRqNc5BHl+8EZGgpS7w==,tu0huZym9PnxU+exvq/tHQ== +9p8kRd9PmxetK0F75mw3EA==,IzBLejn58/8GfY2PniTsxw== +ECB,Decrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=, +4 +8+7RvbXSoDwGS1p+PbGB+A==,a8G+4i5An5bpPX4Rc5MXKg== +WRzLENQQ7SbcW6dKMTYocA==,ri2KVx4DrJyet2+sRa+OUQ== +tu0huZym9PnxU+exvq/tHQ==,MMgcRqNc5BHl+8EZGgpS7w== +IzBLejn58/8GfY2PniTsxw==,9p8kRd9PmxetK0F75mw3EA== +CBC,Encrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,dkmrrIEZskbO6Y6bEukZfQ== +ri2KVx4DrJyet2+sRa+OUQ==,UIbLm1ByGe6V2xE6kXZ4sg== +MMgcRqNc5BHl+8EZGgpS7w==,c77WuOPBdDtxFuaeIiKVFg== +9p8kRd9PmxetK0F75mw3EA==,P/HKoWgfrAkSDsowdYbhpw== +CBC,Decrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +4 +dkmrrIEZskbO6Y6bEukZfQ==,a8G+4i5An5bpPX4Rc5MXKg== +UIbLm1ByGe6V2xE6kXZ4sg==,ri2KVx4DrJyet2+sRa+OUQ== +c77WuOPBdDtxFuaeIiKVFg==,MMgcRqNc5BHl+8EZGgpS7w== +P/HKoWgfrAkSDsowdYbhpw==,9p8kRd9PmxetK0F75mw3EA== +CBC,Encrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,TwIdskO8Yz1xeBg6n6Bx6A== +ri2KVx4DrJyet2+sRa+OUQ==,tNmtqa197fTl5zh2P2kUWg== +MMgcRqNc5BHl+8EZGgpS7w==,VxskIBL7euB/qbqsPfEC4A== +9p8kRd9PmxetK0F75mw3EA==,CLDieYhZiIHZIKnmT1YVzQ== +CBC,Decrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +4 +TwIdskO8Yz1xeBg6n6Bx6A==,a8G+4i5An5bpPX4Rc5MXKg== +tNmtqa197fTl5zh2P2kUWg==,ri2KVx4DrJyet2+sRa+OUQ== +VxskIBL7euB/qbqsPfEC4A==,MMgcRqNc5BHl+8EZGgpS7w== +CLDieYhZiIHZIKnmT1YVzQ==,9p8kRd9PmxetK0F75mw3EA== +CBC,Encrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,9YxMBNbl8bp3nqv7X3v71g== +ri2KVx4DrJyet2+sRa+OUQ==,nPxOln7bgI1nn3d7xnAsfQ== +MMgcRqNc5BHl+8EZGgpS7w==,OfIzaanZus+lMOJjBCMUYQ== +9p8kRd9PmxetK0F75mw3EA==,susF4sOb6fzabBkHjGqdGw== +CBC,Decrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +4 +9YxMBNbl8bp3nqv7X3v71g==,a8G+4i5An5bpPX4Rc5MXKg== +nPxOln7bgI1nn3d7xnAsfQ==,ri2KVx4DrJyet2+sRa+OUQ== +OfIzaanZus+lMOJjBCMUYQ==,MMgcRqNc5BHl+8EZGgpS7w== +susF4sOb6fzabBkHjGqdGw==,9p8kRd9PmxetK0F75mw3EA== +CFB1,Encrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +16 +AA==,AA== +AQ==,AQ== +AQ==,AQ== +AA==,AA== +AQ==,AQ== +AA==,AA== +AQ==,AQ== +AQ==,AA== +AQ==,AQ== +AQ==,AA== +AA==,AQ== +AA==,AQ== +AA==,AA== +AA==,AA== +AA==,AQ== +AQ==,AQ== +CFB1,Decrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +16 +AA==,AA== +AQ==,AQ== +AQ==,AQ== +AA==,AA== +AQ==,AQ== +AA==,AA== +AA==,AQ== +AA==,AQ== +AQ==,AQ== +AA==,AQ== +AQ==,AA== +AQ==,AA== +AA==,AA== +AA==,AA== +AQ==,AA== +AQ==,AQ== +CFB1,Encrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +16 +AA==,AQ== +AQ==,AA== +AQ==,AA== +AA==,AQ== +AQ==,AA== +AA==,AA== +AQ==,AQ== +AQ==,AQ== +AQ==,AA== +AQ==,AQ== +AA==,AA== +AA==,AQ== +AA==,AQ== +AA==,AA== +AA==,AA== +AQ==,AQ== +CFB1,Decrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +16 +AQ==,AA== +AA==,AQ== +AA==,AQ== +AQ==,AA== +AA==,AQ== +AA==,AA== +AQ==,AQ== +AQ==,AQ== +AA==,AQ== +AQ==,AQ== +AA==,AA== +AQ==,AA== +AQ==,AA== +AA==,AA== +AA==,AA== +AQ==,AQ== +CFB1,Encrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +16 +AA==,AQ== +AQ==,AA== +AQ==,AA== +AA==,AQ== +AQ==,AA== +AA==,AA== +AQ==,AA== +AQ==,AA== +AQ==,AA== +AQ==,AA== +AA==,AQ== +AA==,AA== +AA==,AQ== +AA==,AA== +AA==,AA== +AQ==,AQ== +CFB1,Decrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +16 +AQ==,AA== +AA==,AQ== +AA==,AQ== +AQ==,AA== +AA==,AQ== +AA==,AA== +AA==,AQ== +AA==,AQ== +AA==,AQ== +AA==,AQ== +AQ==,AA== +AA==,AA== +AQ==,AA== +AA==,AA== +AA==,AA== +AQ==,AQ== +CFB8,Encrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +18 +aw==,Ow== +wQ==,eQ== +vg==,Qg== +4g==,TA== +Lg==,nA== +QA==,DQ== +nw==,1A== +lg==,Ng== +6Q==,ug== +PQ==,zg== +fg==,ng== +EQ==,Dg== +cw==,1A== +kw==,WA== +Fw==,ag== +Kg==,Tw== +rg==,Mg== +LQ==,uQ== +CFB8,Decrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +18 +Ow==,aw== +eQ==,wQ== +Qg==,vg== +TA==,4g== +nA==,Lg== +DQ==,QA== +1A==,nw== +Ng==,lg== +ug==,6Q== +zg==,PQ== +ng==,fg== +Dg==,EQ== +1A==,cw== +WA==,kw== +ag==,Fw== +Tw==,Kg== +Mg==,rg== +uQ==,LQ== +CFB8,Encrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +18 +aw==,zQ== +wQ==,og== +vg==,Ug== +4g==,Hg== +Lg==,8A== +QA==,qQ== +nw==,BQ== +lg==,yg== +6Q==,RA== +PQ==,zQ== +fg==,BQ== +EQ==,fA== +cw==,vw== +kw==,DQ== +Fw==,Rw== +Kg==,oA== +rg==,Zw== +LQ==,ig== +CFB8,Decrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +18 +zQ==,aw== +og==,wQ== +Ug==,vg== +Hg==,4g== +8A==,Lg== +qQ==,QA== +BQ==,nw== +yg==,lg== +RA==,6Q== +zQ==,PQ== +BQ==,fg== +fA==,EQ== +vw==,cw== +DQ==,kw== +Rw==,Fw== +oA==,Kg== +Zw==,rg== +ig==,LQ== +CFB8,Encrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +18 +aw==,3A== +wQ==,Hw== +vg==,Gg== +4g==,hQ== +Lg==,IA== +QA==,pg== +nw==,TQ== +lg==,tQ== +6Q==,Xw== +PQ==,zA== +fg==,ig== +EQ==,xQ== +cw==,VA== +kw==,hA== +Fw==,Tg== +Kg==,iA== +rg==,lw== +LQ==,AA== +CFB8,Decrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +18 +3A==,aw== +Hw==,wQ== +Gg==,vg== +hQ==,4g== +IA==,Lg== +pg==,QA== +TQ==,nw== +tQ==,lg== +Xw==,6Q== +zA==,PQ== +ig==,fg== +xQ==,EQ== +VA==,cw== +hA==,kw== +Tg==,Fw== +iA==,Kg== +lw==,rg== +AA==,LQ== +CFB128,Encrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,Oz/ZLrctrSAzNEn46Dz7Sg== +ri2KVx4DrJyet2+sRa+OUQ==,yKZFN6CzqT/N482tnxzliw== +MMgcRqNc5BHl+8EZGgpS7w==,JnUfZ6PLsUCxgIzxh6T03w== +9p8kRd9PmxetK0F75mw3EA==,wEsFNXxdHA7qxMZvn/fy5g== +CFB128,Decrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +4 +Oz/ZLrctrSAzNEn46Dz7Sg==,a8G+4i5An5bpPX4Rc5MXKg== +yKZFN6CzqT/N482tnxzliw==,ri2KVx4DrJyet2+sRa+OUQ== +JnUfZ6PLsUCxgIzxh6T03w==,MMgcRqNc5BHl+8EZGgpS7w== +wEsFNXxdHA7qxMZvn/fy5g==,9p8kRd9PmxetK0F75mw3EA== +CFB128,Encrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,zcgNb93xjKs0wlkJyZpBdA== +ri2KVx4DrJyet2+sRa+OUQ==,Z85/f4EXNiGWGitwFx09eg== +MMgcRqNc5BHl+8EZGgpS7w==,Lh6KHdWbiLHI5g/tHvrEyQ== +9p8kRd9PmxetK0F75mw3EA==,wF+fnKmDT6BCro+6WEsJ/w== +CFB128,Decrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +4 +zcgNb93xjKs0wlkJyZpBdA==,a8G+4i5An5bpPX4Rc5MXKg== +Z85/f4EXNiGWGitwFx09eg==,ri2KVx4DrJyet2+sRa+OUQ== +Lh6KHdWbiLHI5g/tHvrEyQ==,MMgcRqNc5BHl+8EZGgpS7w== +wF+fnKmDT6BCro+6WEsJ/w==,9p8kRd9PmxetK0F75mw3EA== +CFB128,Encrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,3H6Ev9p5Fkt+zYSGmF04YA== +ri2KVx4DrJyet2+sRa+OUQ==,Of/tFDsoscgyETxjMeVAew== +MMgcRqNc5BHl+8EZGgpS7w==,3xATJBXlS5KhPtCoJnri+Q== +9p8kRd9PmxetK0F75mw3EA==,daOFdBq5zvggMWI9VbHkcQ== +CFB128,Decrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +4 +3H6Ev9p5Fkt+zYSGmF04YA==,a8G+4i5An5bpPX4Rc5MXKg== +Of/tFDsoscgyETxjMeVAew==,ri2KVx4DrJyet2+sRa+OUQ== +3xATJBXlS5KhPtCoJnri+Q==,MMgcRqNc5BHl+8EZGgpS7w== +daOFdBq5zvggMWI9VbHkcQ==,9p8kRd9PmxetK0F75mw3EA== +OFB,Encrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,Oz/ZLrctrSAzNEn46Dz7Sg== +ri2KVx4DrJyet2+sRa+OUQ==,d4lQjRaRjwP1PFLaxU7YJQ== +MMgcRqNc5BHl+8EZGgpS7w==,l0AFHpxf7PZDRPeoImDtzA== +9p8kRd9PmxetK0F75mw3EA==,MExlKPZZx3hmpRDZwdauXg== +OFB,Decrypt,K34VFiiu0qar9xWICc9PPA==,AAECAwQFBgcICQoLDA0ODw== +4 +Oz/ZLrctrSAzNEn46Dz7Sg==,a8G+4i5An5bpPX4Rc5MXKg== +d4lQjRaRjwP1PFLaxU7YJQ==,ri2KVx4DrJyet2+sRa+OUQ== +l0AFHpxf7PZDRPeoImDtzA==,MMgcRqNc5BHl+8EZGgpS7w== +MExlKPZZx3hmpRDZwdauXg==,9p8kRd9PmxetK0F75mw3EA== +OFB,Encrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,zcgNb93xjKs0wlkJyZpBdA== +ri2KVx4DrJyet2+sRa+OUQ==,/MKLjUxjg3wJ6BcAwRAEAQ== +MMgcRqNc5BHl+8EZGgpS7w==,jZqa6sD2WW9VnG1Nr1ml8g== +9p8kRd9PmxetK0F75mw3EA==,bZ8gCFfKbD6crFJL2azJKg== +OFB,Decrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,AAECAwQFBgcICQoLDA0ODw== +4 +zcgNb93xjKs0wlkJyZpBdA==,a8G+4i5An5bpPX4Rc5MXKg== +/MKLjUxjg3wJ6BcAwRAEAQ==,ri2KVx4DrJyet2+sRa+OUQ== +jZqa6sD2WW9VnG1Nr1ml8g==,MMgcRqNc5BHl+8EZGgpS7w== +bZ8gCFfKbD6crFJL2azJKg==,9p8kRd9PmxetK0F75mw3EA== +OFB,Encrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +4 +a8G+4i5An5bpPX4Rc5MXKg==,3H6Ev9p5Fkt+zYSGmF04YA== +ri2KVx4DrJyet2+sRa+OUQ==,T+vcZ0DSCzrIj2rYKk+wjQ== +MMgcRqNc5BHl+8EZGgpS7w==,catHoIbobu3znRxbupfECA== +9p8kRd9PmxetK0F75mw3EA==,ASYUHWfze+hTj1qL50DkhA== +OFB,Decrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,AAECAwQFBgcICQoLDA0ODw== +4 +3H6Ev9p5Fkt+zYSGmF04YA==,a8G+4i5An5bpPX4Rc5MXKg== +T+vcZ0DSCzrIj2rYKk+wjQ==,ri2KVx4DrJyet2+sRa+OUQ== +catHoIbobu3znRxbupfECA==,MMgcRqNc5BHl+8EZGgpS7w== +ASYUHWfze+hTj1qL50DkhA==,9p8kRd9PmxetK0F75mw3EA== +CTR,Encrypt,K34VFiiu0qar9xWICc9PPA==,8PHy8/T19vf4+fr7/P3+/w== +4 +a8G+4i5An5bpPX4Rc5MXKg==,h01hkbYg4yYb72hkmQ22zg== +ri2KVx4DrJyet2+sRa+OUQ==,mAb2a3lw/f+GFxh7uf/9/w== +MMgcRqNc5BHl+8EZGgpS7w==,WuTfPtvV015bTwkCDbA+qw== +9p8kRd9PmxetK0F75mw3EA==,HgMd2i++A9F5IXCg8wCc7g== +CTR,Decrypt,K34VFiiu0qar9xWICc9PPA==,8PHy8/T19vf4+fr7/P3+/w== +4 +h01hkbYg4yYb72hkmQ22zg==,a8G+4i5An5bpPX4Rc5MXKg== +mAb2a3lw/f+GFxh7uf/9/w==,ri2KVx4DrJyet2+sRa+OUQ== +WuTfPtvV015bTwkCDbA+qw==,MMgcRqNc5BHl+8EZGgpS7w== +HgMd2i++A9F5IXCg8wCc7g==,9p8kRd9PmxetK0F75mw3EA== +CTR,Encrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,8PHy8/T19vf4+fr7/P3+/w== +4 +a8G+4i5An5bpPX4Rc5MXKg==,GryTJBdSHKJPKwRZ/n5uCw== +ri2KVx4DrJyet2+sRa+OUQ==,CQM57Aqm+u/VzMLG9M6OlA== +MMgcRqNc5BHl+8EZGgpS7w==,Hjaya9HrxnDRvR1mViCr9w== +9p8kRd9PmxetK0F75mw3EA==,T3in9tKYCVhal9rsWMawUA== +CTR,Decrypt,jnOw99oOZFLIEPMrgJB55WL46tJSLGt7,8PHy8/T19vf4+fr7/P3+/w== +4 +GryTJBdSHKJPKwRZ/n5uCw==,a8G+4i5An5bpPX4Rc5MXKg== +CQM57Aqm+u/VzMLG9M6OlA==,ri2KVx4DrJyet2+sRa+OUQ== +Hjaya9HrxnDRvR1mViCr9w==,MMgcRqNc5BHl+8EZGgpS7w== +T3in9tKYCVhal9rsWMawUA==,9p8kRd9PmxetK0F75mw3EA== +CTR,Encrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,8PHy8/T19vf4+fr7/P3+/w== +4 +a8G+4i5An5bpPX4Rc5MXKg==,YB7DE3dXiaW3p/UEu/PSKA== +ri2KVx4DrJyet2+sRa+OUQ==,9EPjyk1itZrKhOmQysr1xQ== +MMgcRqNc5BHl+8EZGgpS7w==,Kwkw2qI96UzocBe6LYSYjQ== +9p8kRd9PmxetK0F75mw3EA==,38nFjbZ6raYTwt0IRXlBpg== +CTR,Decrypt,YD3rEBXKcb4rc67whX13gR81LAc7YQjXLZgQowkU3/Q=,8PHy8/T19vf4+fr7/P3+/w== +4 +YB7DE3dXiaW3p/UEu/PSKA==,a8G+4i5An5bpPX4Rc5MXKg== +9EPjyk1itZrKhOmQysr1xQ==,ri2KVx4DrJyet2+sRa+OUQ== +Kwkw2qI96UzocBe6LYSYjQ==,MMgcRqNc5BHl+8EZGgpS7w== +38nFjbZ6raYTwt0IRXlBpg==,9p8kRd9PmxetK0F75mw3EA== + diff --git a/jdk/test/javax/imageio/plugins/tiff/MultiPageTest/MultiPageTest.java b/jdk/test/javax/imageio/plugins/tiff/MultiPageTest/MultiPageTest.java index 823b9ea1bc4..e2eb71d6fec 100644 --- a/jdk/test/javax/imageio/plugins/tiff/MultiPageTest/MultiPageTest.java +++ b/jdk/test/javax/imageio/plugins/tiff/MultiPageTest/MultiPageTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,8 +23,7 @@ /** * @test - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib * * @bug 8145776 * @author a.stepanov @@ -33,6 +32,7 @@ * (number of pages, sizes, colors). Use -Dseed=X to set * the random generator seed. * + * @build jdk.test.lib.RandomFactory * @run main MultiPageTest * @key randomness */ @@ -47,7 +47,7 @@ import java.util.*; import javax.imageio.*; import javax.imageio.stream.*; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class MultiPageTest { diff --git a/jdk/test/javax/management/MBeanServer/NotifDeadlockTest.java b/jdk/test/javax/management/MBeanServer/NotifDeadlockTest.java index 4020addf222..1b7e0e83978 100644 --- a/jdk/test/javax/management/MBeanServer/NotifDeadlockTest.java +++ b/jdk/test/javax/management/MBeanServer/NotifDeadlockTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -77,7 +77,6 @@ public class NotifDeadlockTest { } } static MBeanServer mbs; - static boolean timedOut; /* This listener registers or unregisters the MBean called on2 when triggered. */ @@ -110,83 +109,48 @@ public class NotifDeadlockTest { }; t.start(); try { - t.join(2000); + t.join(); } catch (InterruptedException e) { e.printStackTrace(); // should not happen } - if (t.isAlive()) { - System.out.println("FAILURE: Wait timed out: " + - "probable deadlock"); - timedOut = true; - } } } } public static void main(String[] args) throws Exception { - boolean success = true; System.out.println("Test 1: in register notif, unregister an MBean"); - timedOut = false; mbs = MBeanServerFactory.createMBeanServer(); mbs.createMBean("javax.management.timer.Timer", on2); mbs.addNotificationListener(delName, new XListener(false), null, null); mbs.createMBean("javax.management.timer.Timer", on1); MBeanServerFactory.releaseMBeanServer(mbs); - if (timedOut) { - success = false; - Thread.sleep(500); - // wait for the spawned thread to complete its work, probably - } System.out.println("Test 1 completed"); System.out.println("Test 2: in unregister notif, unregister an MBean"); - timedOut = false; mbs = MBeanServerFactory.createMBeanServer(); mbs.createMBean("javax.management.timer.Timer", on1); mbs.createMBean("javax.management.timer.Timer", on2); mbs.addNotificationListener(delName, new XListener(false), null, null); mbs.unregisterMBean(on1); MBeanServerFactory.releaseMBeanServer(mbs); - if (timedOut) { - success = false; - Thread.sleep(500); - // wait for the spawned thread to complete its work, probably - } System.out.println("Test 2 completed"); System.out.println("Test 3: in register notif, register an MBean"); - timedOut = false; mbs = MBeanServerFactory.createMBeanServer(); mbs.addNotificationListener(delName, new XListener(true), null, null); mbs.createMBean("javax.management.timer.Timer", on1); MBeanServerFactory.releaseMBeanServer(mbs); - if (timedOut) { - success = false; - Thread.sleep(500); - // wait for the spawned thread to complete its work, probably - } System.out.println("Test 3 completed"); System.out.println("Test 4: in unregister notif, register an MBean"); - timedOut = false; mbs = MBeanServerFactory.createMBeanServer(); mbs.createMBean("javax.management.timer.Timer", on1); mbs.addNotificationListener(delName, new XListener(true), null, null); mbs.unregisterMBean(on1); MBeanServerFactory.releaseMBeanServer(mbs); - if (timedOut) { - success = false; - Thread.sleep(500); - // wait for the spawned thread to complete its work, probably - } System.out.println("Test 4 completed"); - if (success) - System.out.println("Test passed"); - else { - System.out.println("TEST FAILED: at least one subcase failed"); - System.exit(1); - } + System.out.println("Test passed"); } } diff --git a/jdk/test/javax/management/remote/mandatory/notif/NoPermToRemoveTest.java b/jdk/test/javax/management/remote/mandatory/notif/NoPermToRemoveTest.java new file mode 100644 index 00000000000..1af316f1b50 --- /dev/null +++ b/jdk/test/javax/management/remote/mandatory/notif/NoPermToRemoveTest.java @@ -0,0 +1,187 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + + /* + * @test + * @bug 6515161 + * @summary checks the behaviour of mbeanServerConnection.removeNotificationListener + * operation when there is a exception thrown during removal + * @modules java.management + * @run main NoPermToRemoveTest + */ + +import java.lang.management.ManagementFactory; +import java.security.AllPermission; +import java.security.CodeSource; +import java.security.Permission; +import java.security.PermissionCollection; +import java.security.Permissions; +import java.security.Policy; +import java.security.ProtectionDomain; +import java.util.concurrent.Semaphore; +import java.util.concurrent.TimeUnit; +import java.util.concurrent.atomic.AtomicInteger; +import javax.management.ListenerNotFoundException; +import javax.management.MBeanPermission; +import javax.management.MBeanServer; +import javax.management.MBeanServerConnection; +import javax.management.Notification; +import javax.management.NotificationBroadcasterSupport; +import javax.management.NotificationFilter; +import javax.management.NotificationListener; +import javax.management.ObjectName; +import javax.management.remote.JMXConnector; +import javax.management.remote.JMXConnectorFactory; +import javax.management.remote.JMXConnectorServer; +import javax.management.remote.JMXConnectorServerFactory; +import javax.management.remote.JMXServiceURL; + +public class NoPermToRemoveTest { + public static void main(String[] args) throws Exception { + Policy.setPolicy(new NoRemovePolicy()); + System.setSecurityManager(new SecurityManager()); + + JMXServiceURL url = new JMXServiceURL("service:jmx:rmi:///"); + MBeanServer mbs = ManagementFactory.getPlatformMBeanServer(); + ObjectName name = new ObjectName("foo:type=Sender"); + mbs.registerMBean(new Sender(), name); + JMXConnectorServer cs = JMXConnectorServerFactory.newJMXConnectorServer( + url, null, mbs); + cs.start(); + try { + JMXServiceURL addr = cs.getAddress(); + JMXConnector cc = JMXConnectorFactory.connect(addr); + MBeanServerConnection mbsc = cc.getMBeanServerConnection(); + SnoopListener listener = new SnoopListener(); + mbsc.addNotificationListener(name, listener, null, null); + mbsc.invoke(name, "send", null, null); + if (!listener.waitForNotification(60)) + throw new Exception("Did not receive expected notification"); + + try { + mbsc.removeNotificationListener(name, listener); + throw new Exception("RemoveNL did not get SecurityException"); + } catch (SecurityException e) { + System.out.println("removeNL got expected exception: " + e); + } + mbsc.invoke(name, "send", null, null); + if (!listener.waitForNotification(60)) { + int listenerCount = + (Integer) mbsc.getAttribute(name, "ListenerCount"); + System.out.println("Listener count: " + listenerCount); + if (listenerCount != 0) + throw new Exception("TEST FAILED"); + /* We did not receive the notification, but the MBean still + * has a listener coming from the connector server, which + * means the connector server still thinks there is a + * listener. If we retained the listener after the failing + * removeNL that would be OK, and if the listener were + * dropped by both client and server that would be OK too, + * but the inconsistency is not OK. + */ + } + cc.close(); + } finally { + cs.stop(); + } + } + + private static class SnoopListener implements NotificationListener { + private Semaphore sema = new Semaphore(0); + + public void handleNotification(Notification notification, Object handback) { + System.out.println("Listener got: " + notification); + sema.release(); + } + + boolean waitForNotification(int seconds) throws InterruptedException { + return sema.tryAcquire(seconds, TimeUnit.SECONDS); + } + } + + private static class NoRemovePolicy extends Policy { + public PermissionCollection getPermissions(CodeSource codesource) { + PermissionCollection pc = new Permissions(); + pc.add(new AllPermission()); + return pc; + } + + public void refresh() { + } + + public boolean implies(ProtectionDomain domain, Permission permission) { + if (!(permission instanceof MBeanPermission)) + return true; + MBeanPermission jmxp = (MBeanPermission) permission; + if (jmxp.getActions().contains("removeNotificationListener")) { + System.out.println("DENIED"); + return false; + } + return true; + } + } + + public static interface SenderMBean { + public void send(); + public int getListenerCount(); + } + + public static class Sender extends NotificationBroadcasterSupport + implements SenderMBean { + private AtomicInteger listenerCount = new AtomicInteger(); + + public void send() { + System.out.println("Sending notif"); + sendNotification(new Notification("type", this, 0L)); + } + + public synchronized int getListenerCount() { + return listenerCount.get(); + } + + public void removeNotificationListener( + NotificationListener listener, + NotificationFilter filter, + Object handback) throws ListenerNotFoundException { + System.out.println("Sender.removeNL(3)"); + super.removeNotificationListener(listener, filter, handback); + listenerCount.decrementAndGet(); + } + + public void addNotificationListener( + NotificationListener listener, + NotificationFilter filter, + Object handback) { + System.out.println("Sender.addNL(3)"); + super.addNotificationListener(listener, filter, handback); + listenerCount.incrementAndGet(); + } + + public void removeNotificationListener(NotificationListener listener) + throws ListenerNotFoundException { + System.out.println("Sender.removeNL(1)"); + super.removeNotificationListener(listener); + listenerCount.decrementAndGet(); + } + } +} diff --git a/jdk/test/javax/net/ssl/DTLS/DTLSIncorrectAppDataTest.java b/jdk/test/javax/net/ssl/DTLS/DTLSIncorrectAppDataTest.java index c19e58a73b6..47a9f4819b2 100644 --- a/jdk/test/javax/net/ssl/DTLS/DTLSIncorrectAppDataTest.java +++ b/jdk/test/javax/net/ssl/DTLS/DTLSIncorrectAppDataTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,7 @@ * @bug 8043758 * @summary Testing DTLS incorrect app data packages unwrapping. * @key randomness - * @library /sun/security/krb5/auto /lib/testlibrary /javax/net/ssl/TLSCommon + * @library /sun/security/krb5/auto /test/lib /javax/net/ssl/TLSCommon * @modules java.security.jgss * jdk.security.auth * java.security.jgss/sun.security.krb5:+open @@ -35,6 +35,7 @@ * java.security.jgss/sun.security.krb5.internal.crypto * java.security.jgss/sun.security.krb5.internal.ktab * java.base/sun.security.util + * @build jdk.test.lib.RandomFactory * @run main/othervm -Dtest.security.protocol=DTLS * -Dtest.mode=norm DTLSIncorrectAppDataTest * @run main/othervm -Dtest.security.protocol=DTLS @@ -49,7 +50,7 @@ import javax.net.ssl.SSLEngine; import javax.net.ssl.SSLEngineResult; import javax.net.ssl.SSLException; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * Testing DTLS incorrect app data packages unwrapping. Incorrect application diff --git a/jdk/test/javax/net/ssl/DTLS/DTLSRehandshakeWithCipherChangeTest.java b/jdk/test/javax/net/ssl/DTLS/DTLSRehandshakeWithCipherChangeTest.java index bfe5b7e9b2c..520a6590b46 100644 --- a/jdk/test/javax/net/ssl/DTLS/DTLSRehandshakeWithCipherChangeTest.java +++ b/jdk/test/javax/net/ssl/DTLS/DTLSRehandshakeWithCipherChangeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,7 @@ * @summary Testing DTLS engines re-handshaking with cipher change. New cipher * is taken randomly from the supporetd ciphers list. * @key randomness - * @library /sun/security/krb5/auto /lib/testlibrary /javax/net/ssl/TLSCommon + * @library /sun/security/krb5/auto /test/lib /javax/net/ssl/TLSCommon * @modules java.security.jgss * java.security.jgss/sun.security.krb5:+open * java.security.jgss/sun.security.krb5.internal:+open @@ -35,6 +35,7 @@ * java.security.jgss/sun.security.krb5.internal.crypto * java.security.jgss/sun.security.krb5.internal.ktab * java.base/sun.security.util + * @build jdk.test.lib.RandomFactory * @run main/othervm -Dtest.security.protocol=DTLS * DTLSRehandshakeWithCipherChangeTest */ diff --git a/jdk/test/javax/net/ssl/DTLS/DTLSSequenceNumberTest.java b/jdk/test/javax/net/ssl/DTLS/DTLSSequenceNumberTest.java index 1475f8b8f05..22fe13ab127 100644 --- a/jdk/test/javax/net/ssl/DTLS/DTLSSequenceNumberTest.java +++ b/jdk/test/javax/net/ssl/DTLS/DTLSSequenceNumberTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,7 @@ * @summary Testing DTLS records sequence number property support in application * data exchange. * @key randomness - * @library /sun/security/krb5/auto /lib/testlibrary /javax/net/ssl/TLSCommon + * @library /sun/security/krb5/auto /test/lib /javax/net/ssl/TLSCommon * @modules java.security.jgss * jdk.security.auth * java.security.jgss/sun.security.krb5:+open @@ -36,6 +36,7 @@ * java.security.jgss/sun.security.krb5.internal.crypto * java.security.jgss/sun.security.krb5.internal.ktab * java.base/sun.security.util + * @build jdk.test.lib.RandomFactory * @run main/othervm -Dtest.security.protocol=DTLS * -Dtest.mode=norm DTLSSequenceNumberTest * @run main/othervm -Dtest.security.protocol=DTLS @@ -51,7 +52,7 @@ import javax.net.ssl.SSLEngine; import javax.net.ssl.SSLEngineResult; import javax.net.ssl.SSLException; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * Testing DTLS records sequence number property support in application data diff --git a/jdk/test/javax/net/ssl/DTLSv10/DTLSv10IncorrectAppDataTest.java b/jdk/test/javax/net/ssl/DTLSv10/DTLSv10IncorrectAppDataTest.java index baec575c1cc..f15badec323 100644 --- a/jdk/test/javax/net/ssl/DTLSv10/DTLSv10IncorrectAppDataTest.java +++ b/jdk/test/javax/net/ssl/DTLSv10/DTLSv10IncorrectAppDataTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,7 @@ * @bug 8043758 * @summary Testing DTLS incorrect app data packages unwrapping. * @key randomness - * @library /sun/security/krb5/auto /lib/testlibrary /javax/net/ssl/TLSCommon /javax/net/ssl/DTLS + * @library /sun/security/krb5/auto /test/lib /javax/net/ssl/TLSCommon /javax/net/ssl/DTLS * @modules java.security.jgss * jdk.security.auth * java.security.jgss/sun.security.krb5:+open diff --git a/jdk/test/javax/net/ssl/DTLSv10/DTLSv10RehandshakeWithCipherChangeTest.java b/jdk/test/javax/net/ssl/DTLSv10/DTLSv10RehandshakeWithCipherChangeTest.java index f69afe69057..4fab3a839da 100644 --- a/jdk/test/javax/net/ssl/DTLSv10/DTLSv10RehandshakeWithCipherChangeTest.java +++ b/jdk/test/javax/net/ssl/DTLSv10/DTLSv10RehandshakeWithCipherChangeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,7 @@ * @summary Testing DTLS engines re-handshaking with cipher change. New cipher * is taken randomly from the supporetd ciphers list. * @key randomness - * @library /sun/security/krb5/auto /lib/testlibrary /javax/net/ssl/TLSCommon + * @library /sun/security/krb5/auto /test/lib /javax/net/ssl/TLSCommon * @modules java.security.jgss * java.security.jgss/sun.security.krb5:+open * java.security.jgss/sun.security.krb5.internal:+open @@ -35,6 +35,7 @@ * java.security.jgss/sun.security.krb5.internal.crypto * java.security.jgss/sun.security.krb5.internal.ktab * java.base/sun.security.util + * @build jdk.test.lib.RandomFactory * @run main/othervm -Dtest.security.protocol=DTLSv1.0 * DTLSv10RehandshakeWithCipherChangeTest */ diff --git a/jdk/test/javax/net/ssl/Stapling/SSLSocketWithStapling.java b/jdk/test/javax/net/ssl/Stapling/SSLSocketWithStapling.java index aaa8ce35396..c72186853ee 100644 --- a/jdk/test/javax/net/ssl/Stapling/SSLSocketWithStapling.java +++ b/jdk/test/javax/net/ssl/Stapling/SSLSocketWithStapling.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -367,9 +367,15 @@ public class SSLSocketWithStapling { throw tr.serverExc; } + // make sure getSoftFailExceptions is not empty + if (cliParams.revChecker.getSoftFailExceptions().isEmpty()) { + throw new Exception("No soft fail exceptions"); + } + System.out.println(" PASS"); System.out.println("=======================================\n"); + // Make OCSP responders accept connections intOcsp.acceptConnections(); rootOcsp.acceptConnections(); diff --git a/jdk/test/javax/net/ssl/TLS/TLSRehandshakeWithCipherChangeTest.java b/jdk/test/javax/net/ssl/TLS/TLSRehandshakeWithCipherChangeTest.java index 8221c8d1a2c..23da9a2ab5b 100644 --- a/jdk/test/javax/net/ssl/TLS/TLSRehandshakeWithCipherChangeTest.java +++ b/jdk/test/javax/net/ssl/TLS/TLSRehandshakeWithCipherChangeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,7 @@ * @summary Testing TLS engines re-handshaking with cipher change. New cipher * is taken randomly from the supporetd ciphers list. * @key randomness - * @library /sun/security/krb5/auto /lib/testlibrary /javax/net/ssl/TLSCommon + * @library /sun/security/krb5/auto /test/lib /javax/net/ssl/TLSCommon * @modules java.security.jgss * java.security.jgss/sun.security.krb5:+open * java.security.jgss/sun.security.krb5.internal:+open @@ -35,6 +35,7 @@ * java.security.jgss/sun.security.krb5.internal.crypto * java.security.jgss/sun.security.krb5.internal.ktab * java.base/sun.security.util + * @build jdk.test.lib.RandomFactory * @run main/othervm -Dtest.security.protocol=TLS TLSRehandshakeWithCipherChangeTest */ diff --git a/jdk/test/javax/net/ssl/TLSCommon/RehandshakeWithCipherChangeTest.java b/jdk/test/javax/net/ssl/TLSCommon/RehandshakeWithCipherChangeTest.java index 50e99f71a95..22b15994a33 100644 --- a/jdk/test/javax/net/ssl/TLSCommon/RehandshakeWithCipherChangeTest.java +++ b/jdk/test/javax/net/ssl/TLSCommon/RehandshakeWithCipherChangeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,7 @@ import javax.net.ssl.SSLEngine; import javax.net.ssl.SSLEngineResult; import javax.net.ssl.SSLException; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; /** * Testing SSLEngines re-handshaking with cipher change. New cipher is taken diff --git a/jdk/test/javax/net/ssl/TLSv1/TLSRehandshakeWithCipherChangeTest.java b/jdk/test/javax/net/ssl/TLSv1/TLSRehandshakeWithCipherChangeTest.java index cdbc16f5c46..65491312ca5 100644 --- a/jdk/test/javax/net/ssl/TLSv1/TLSRehandshakeWithCipherChangeTest.java +++ b/jdk/test/javax/net/ssl/TLSv1/TLSRehandshakeWithCipherChangeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,7 @@ * @summary Testing TLS engines re-handshaking with cipher change. New cipher * is taken randomly from the supporetd ciphers list. * @key randomness - * @library /sun/security/krb5/auto /lib/testlibrary /javax/net/ssl/TLSCommon + * @library /sun/security/krb5/auto /test/lib /javax/net/ssl/TLSCommon * @modules java.security.jgss * java.security.jgss/sun.security.krb5:+open * java.security.jgss/sun.security.krb5.internal:+open @@ -35,6 +35,7 @@ * java.security.jgss/sun.security.krb5.internal.crypto * java.security.jgss/sun.security.krb5.internal.ktab * java.base/sun.security.util + * @build jdk.test.lib.RandomFactory * @run main/othervm -Dtest.security.protocol=TLSv1 TLSRehandshakeWithCipherChangeTest */ diff --git a/jdk/test/javax/net/ssl/TLSv11/TLSRehandshakeWithCipherChangeTest.java b/jdk/test/javax/net/ssl/TLSv11/TLSRehandshakeWithCipherChangeTest.java index c42454a9043..bb12218ba7e 100644 --- a/jdk/test/javax/net/ssl/TLSv11/TLSRehandshakeWithCipherChangeTest.java +++ b/jdk/test/javax/net/ssl/TLSv11/TLSRehandshakeWithCipherChangeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,7 @@ * @summary Testing TLS engines re-handshaking with cipher change. New cipher * is taken randomly from the supporetd ciphers list. * @key randomness - * @library /sun/security/krb5/auto /lib/testlibrary /javax/net/ssl/TLSCommon + * @library /sun/security/krb5/auto /test/lib /javax/net/ssl/TLSCommon * @modules java.security.jgss * java.security.jgss/sun.security.krb5:+open * java.security.jgss/sun.security.krb5.internal:+open @@ -35,6 +35,7 @@ * java.security.jgss/sun.security.krb5.internal.crypto * java.security.jgss/sun.security.krb5.internal.ktab * java.base/sun.security.util + * @build jdk.test.lib.RandomFactory * @run main/othervm -Dtest.security.protocol=TLSv1.1 TLSRehandshakeWithCipherChangeTest */ diff --git a/jdk/test/javax/net/ssl/TLSv12/SignatureAlgorithms.java b/jdk/test/javax/net/ssl/TLSv12/SignatureAlgorithms.java index 8b51703df41..0533d31135e 100644 --- a/jdk/test/javax/net/ssl/TLSv12/SignatureAlgorithms.java +++ b/jdk/test/javax/net/ssl/TLSv12/SignatureAlgorithms.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ /* * @test - * @bug 8049321 + * @bug 8049321 8182143 * @summary Support SHA256WithDSA in JSSE * @run main/othervm SignatureAlgorithms PKIX "SHA-224,SHA-256" * TLS_DHE_DSS_WITH_AES_128_CBC_SHA @@ -434,21 +434,6 @@ public class SignatureAlgorithms { */ parseArguments(args); - - /* - * Ignore testing on Windows if only SHA-224 is available. - */ - if ((Security.getProvider("SunMSCAPI") != null) && - (disabledAlgorithms.contains("SHA-1")) && - (disabledAlgorithms.contains("SHA-256"))) { - - System.out.println( - "Windows system does not support SHA-224 algorithms yet. " + - "Ignore the testing"); - - return; - } - /* * Expose the target algorithms by diabling unexpected algorithms. */ diff --git a/jdk/test/javax/security/auth/login/modules/JaasModularClientTest.java b/jdk/test/javax/security/auth/login/modules/JaasModularClientTest.java index 20763ba4e45..b0bc45968df 100644 --- a/jdk/test/javax/security/auth/login/modules/JaasModularClientTest.java +++ b/jdk/test/javax/security/auth/login/modules/JaasModularClientTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,14 +32,15 @@ import java.lang.module.ModuleDescriptor; import java.util.ArrayList; import jdk.testlibrary.ProcessTools; import jdk.testlibrary.OutputAnalyzer; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; /** * @test * @bug 8078813 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @library /java/security/modules - * @build CompilerUtils JarUtils + * @build jdk.test.lib.compiler.CompilerUtils JarUtils * @summary Test custom JAAS module with all possible modular option. The test * includes different combination of JAAS client/login modules * interaction with or without service description. diff --git a/jdk/test/javax/security/auth/login/modules/JaasModularDefaultHandlerTest.java b/jdk/test/javax/security/auth/login/modules/JaasModularDefaultHandlerTest.java index 14dc31e14db..efdadc21bdd 100644 --- a/jdk/test/javax/security/auth/login/modules/JaasModularDefaultHandlerTest.java +++ b/jdk/test/javax/security/auth/login/modules/JaasModularDefaultHandlerTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,6 +30,7 @@ import java.util.Arrays; import java.io.IOException; import java.lang.module.ModuleDescriptor; import java.util.ArrayList; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.ProcessTools; import jdk.testlibrary.OutputAnalyzer; import org.testng.annotations.BeforeTest; @@ -37,9 +38,9 @@ import org.testng.annotations.BeforeTest; /** * @test * @bug 8151654 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @library /java/security/modules - * @build CompilerUtils JarUtils + * @build jdk.test.lib.compiler.CompilerUtils JarUtils * @summary Test custom JAAS callback handler with all possible modular option. * @run testng JaasModularDefaultHandlerTest */ diff --git a/jdk/test/javax/swing/ToolTipManager/7123767/bug7123767.java b/jdk/test/javax/swing/ToolTipManager/7123767/bug7123767.java index 1db5dc50d66..3ca2a713243 100644 --- a/jdk/test/javax/swing/ToolTipManager/7123767/bug7123767.java +++ b/jdk/test/javax/swing/ToolTipManager/7123767/bug7123767.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -38,8 +38,7 @@ * @key randomness * * @modules java.desktop/sun.awt - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib * * @run main/timeout=300 bug7123767 */ @@ -55,7 +54,7 @@ import java.util.ArrayList; import java.util.Collections; import java.util.Random; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class bug7123767 extends JFrame { diff --git a/jdk/test/jdk/internal/jline/extra/HistoryTest.java b/jdk/test/jdk/internal/jline/extra/HistoryTest.java index f8d3084b767..65f721d664b 100644 --- a/jdk/test/jdk/internal/jline/extra/HistoryTest.java +++ b/jdk/test/jdk/internal/jline/extra/HistoryTest.java @@ -23,6 +23,7 @@ /* * @test + * @bug 8178821 * @summary Test Completion * @modules jdk.internal.le/jdk.internal.jline * jdk.internal.le/jdk.internal.jline.console @@ -152,6 +153,15 @@ public class HistoryTest { complete.set(true); history.add("}"); previousSnippetAndAssert(history, "void test() { /*after full*/"); + nextSnippetAndAssert(history, ""); + + assertFalse(history.nextSnippet()); + + while (history.previousSnippet()) + ; + + while (history.nextSnippet()) + ; } private void previousAndAssert(EditingHistory history, String expected) { diff --git a/jdk/test/jdk/internal/ref/Cleaner/ExitOnThrow.java b/jdk/test/jdk/internal/ref/Cleaner/ExitOnThrow.java index aff92170577..881dc6969ef 100644 --- a/jdk/test/jdk/internal/ref/Cleaner/ExitOnThrow.java +++ b/jdk/test/jdk/internal/ref/Cleaner/ExitOnThrow.java @@ -27,8 +27,12 @@ * @library /test/lib * @modules java.base/jdk.internal.ref * java.base/jdk.internal.misc - * @build jdk.test.lib.* - * @build jdk.test.lib.process.* + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main ExitOnThrow * @summary Ensure that if a cleaner throws an exception then the VM exits */ diff --git a/jdk/test/jdk/internal/util/jar/TestVersionedStream.java b/jdk/test/jdk/internal/util/jar/TestVersionedStream.java index 1f043b2bc33..c7c0c8783b4 100644 --- a/jdk/test/jdk/internal/util/jar/TestVersionedStream.java +++ b/jdk/test/jdk/internal/util/jar/TestVersionedStream.java @@ -25,9 +25,10 @@ * @test * @bug 8163798 * @summary basic tests for multi-release jar versioned streams - * @library /lib/testlibrary + * @library /test/lib * @modules jdk.jartool/sun.tools.jar java.base/jdk.internal.util.jar - * @build jdk.testlibrary.FileUtils + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @run testng TestVersionedStream */ @@ -57,7 +58,7 @@ import java.util.stream.Collectors; import java.util.stream.Stream; import java.util.zip.ZipFile; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; public class TestVersionedStream { private final Path userdir; diff --git a/jdk/test/jdk/modules/incubator/DefaultImage.java b/jdk/test/jdk/modules/incubator/DefaultImage.java index dc2236351c8..91aad2fd089 100644 --- a/jdk/test/jdk/modules/incubator/DefaultImage.java +++ b/jdk/test/jdk/modules/incubator/DefaultImage.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,14 +25,13 @@ * @test * @bug 8170859 * @summary Ensure no incubator modules are resolved by default in the image - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build CompilerUtils + * @build jdk.test.lib.compiler.CompilerUtils * @run testng DefaultImage */ import java.io.ByteArrayOutputStream; -import java.io.IOException; import java.io.PrintStream; import java.lang.module.ModuleDescriptor; import java.lang.module.ModuleFinder; @@ -42,6 +41,7 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.util.function.Consumer; import java.util.stream.Stream; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; diff --git a/jdk/test/jdk/modules/incubator/ImageModules.java b/jdk/test/jdk/modules/incubator/ImageModules.java index 6b9c9ea1665..e569a175acc 100644 --- a/jdk/test/jdk/modules/incubator/ImageModules.java +++ b/jdk/test/jdk/modules/incubator/ImageModules.java @@ -25,10 +25,12 @@ * @test * @bug 8170859 * @summary Basic test for incubator modules in jmods and images - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @key intermittent * @modules jdk.compiler jdk.jartool jdk.jlink - * @build CompilerUtils + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils + * jdk.test.lib.compiler.CompilerUtils * @run testng/othervm ImageModules */ @@ -39,14 +41,14 @@ import java.io.PrintStream; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; -import java.util.ArrayList; import java.util.List; import java.util.function.Consumer; import java.util.spi.ToolProvider; import java.util.stream.Collectors; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.compiler.CompilerUtils; +import jdk.test.lib.util.FileUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.DataProvider; import org.testng.annotations.Test; diff --git a/jdk/test/jdk/modules/scenarios/automaticmodules/RunWithAutomaticModules.java b/jdk/test/jdk/modules/scenarios/automaticmodules/RunWithAutomaticModules.java index 56bd84b154d..cd218b9f75a 100644 --- a/jdk/test/jdk/modules/scenarios/automaticmodules/RunWithAutomaticModules.java +++ b/jdk/test/jdk/modules/scenarios/automaticmodules/RunWithAutomaticModules.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,9 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build RunWithAutomaticModules CompilerUtils JarUtils + * @build RunWithAutomaticModules jdk.test.lib.compiler.CompilerUtils JarUtils * jdk.testlibrary.ProcessTools * @run testng RunWithAutomaticModules * @summary Runs tests that make use of automatic modules @@ -35,6 +35,7 @@ import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.Test; diff --git a/jdk/test/jdk/modules/scenarios/container/ContainerTest.java b/jdk/test/jdk/modules/scenarios/container/ContainerTest.java index f56245413ac..a0fe776408d 100644 --- a/jdk/test/jdk/modules/scenarios/container/ContainerTest.java +++ b/jdk/test/jdk/modules/scenarios/container/ContainerTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,12 +23,12 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.jartool/sun.tools.jar * jdk.compiler * jdk.zipfs * java.se - * @build ContainerTest CompilerUtils jdk.testlibrary.* + * @build ContainerTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng ContainerTest * @summary Starts a simple container that uses dynamic configurations * and launches two applications in the same VM @@ -38,6 +38,7 @@ import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.BeforeTest; diff --git a/jdk/test/jdk/modules/scenarios/overlappingpackages/OverlappingPackagesTest.java b/jdk/test/jdk/modules/scenarios/overlappingpackages/OverlappingPackagesTest.java index 8dc2060bfee..fb36288aeec 100644 --- a/jdk/test/jdk/modules/scenarios/overlappingpackages/OverlappingPackagesTest.java +++ b/jdk/test/jdk/modules/scenarios/overlappingpackages/OverlappingPackagesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,10 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build OverlappingPackagesTest CompilerUtils jdk.testlibrary.* + * @build OverlappingPackagesTest jdk.testlibrary.* + * jdk.test.lib.compiler.CompilerUtils * @run testng OverlappingPackagesTest * @summary Basic test to ensure that startup fails if two or more modules * in the boot Layer have the same package @@ -36,6 +37,7 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.List; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.BeforeTest; diff --git a/jdk/test/jdk/security/jarsigner/Spec.java b/jdk/test/jdk/security/jarsigner/Spec.java index b36b90690df..1b3a12c7419 100644 --- a/jdk/test/jdk/security/jarsigner/Spec.java +++ b/jdk/test/jdk/security/jarsigner/Spec.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,17 +25,19 @@ * @test * @bug 8056174 * @summary Make sure JarSigner impl conforms to spec - * @library /lib/testlibrary + * @library /test/lib * @modules java.base/sun.security.tools.keytool * java.base/sun.security.provider.certpath * jdk.jartool * jdk.crypto.ec + * @build jdk.test.lib.util.JarUtils + * @run main Spec */ import com.sun.jarsigner.ContentSigner; import com.sun.jarsigner.ContentSignerParameters; import jdk.security.jarsigner.JarSigner; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; import sun.security.provider.certpath.X509CertPath; import java.io.File; diff --git a/jdk/test/lib/testlibrary/JavaToolUtils.java b/jdk/test/lib/testlibrary/JavaToolUtils.java deleted file mode 100644 index c9736bcf9a0..00000000000 --- a/jdk/test/lib/testlibrary/JavaToolUtils.java +++ /dev/null @@ -1,209 +0,0 @@ -/* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * by Oracle in the LICENSE file that accompanied this code. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -import java.io.BufferedReader; -import java.io.File; -import java.io.FileOutputStream; -import java.io.IOException; -import java.io.InputStreamReader; -import java.nio.file.Files; -import java.util.List; -import java.util.Objects; -import java.util.concurrent.TimeUnit; -import java.util.jar.Attributes; -import java.util.jar.JarEntry; -import java.util.jar.JarOutputStream; -import java.util.jar.Manifest; -import javax.tools.JavaCompiler; -import javax.tools.JavaFileObject; -import javax.tools.StandardJavaFileManager; -import javax.tools.ToolProvider; - -/** - * Utils class for compiling , creating jar file and executing a java command - * - * @author Raghu Nair - */ - -public class JavaToolUtils { - - public static final long DEFAULT_WAIT_TIME = 10000; - - private JavaToolUtils() { - } - - /** - * Takes a list of files and compile these files into the working directory. - * - * @param files - * @throws IOException - */ - public static void compileFiles(List files) throws IOException { - JavaCompiler compiler = ToolProvider.getSystemJavaCompiler(); - try (StandardJavaFileManager fileManager = compiler. - getStandardFileManager(null, null, null)) { - Iterable compilationUnit - = fileManager.getJavaFileObjectsFromFiles(files); - compiler.getTask(null, fileManager, null, null, null, - compilationUnit).call(); - } - } - - /** - * Create a jar file using the list of files provided. - * - * @param jar - * @param files - * @throws IOException - */ - public static void createJar(File jar, List files) - throws IOException { - Manifest manifest = new Manifest(); - manifest.getMainAttributes().put(Attributes.Name.MANIFEST_VERSION, - "1.0"); - try (JarOutputStream target = new JarOutputStream( - new FileOutputStream(jar), manifest)) { - for (File file : files) { - add(file, target); - } - } - } - - private static void add(File source, JarOutputStream target) - throws IOException { - Objects.requireNonNull(source, "source cannot be null"); - Objects.requireNonNull(target, "target cannot be null"); - // not tested against directories and from different path. - String name = source.getName(); - if (source.isDirectory()) { - if (!name.isEmpty()) { - if (!name.endsWith("/")) { - name += "/"; - } - JarEntry entry = new JarEntry(name); - entry.setTime(source.lastModified()); - target.putNextEntry(entry); - target.closeEntry(); - } - for (File nestedFile : source.listFiles()) { - add(nestedFile, target); - } - return; - } - System.out.println("Adding entry " + name); - JarEntry entry = new JarEntry(name); - entry.setTime(source.lastModified()); - target.putNextEntry(entry); - Files.copy(source.toPath(), target); - target.closeEntry(); - } - - /** - * Runs java command with provided arguments. Caller should not pass java - * command in the argument list. - * - * @param commands - * @param waitTime time to wait for the command to exit in milli seconds - * @return - * @throws Exception - */ - public static int runJava(List commands,long waitTime) - throws Exception { - String java = System.getProperty("java.home") + "/bin/java"; - commands.add(0, java); - String command = commands.toString().replace(",", " "); - System.out.println("Executing the following command \n" + command); - ProcessBuilder processBuilder = new ProcessBuilder(commands); - final Process process = processBuilder.start(); - BufferedReader errorStream = new BufferedReader( - new InputStreamReader(process.getErrorStream())); - BufferedReader outStream = new BufferedReader( - new InputStreamReader(process.getInputStream())); - String errorLine; - StringBuilder errors = new StringBuilder(); - String outLines; - while ((errorLine = errorStream.readLine()) != null) { - errors.append(errorLine).append("\n"); - } - while ((outLines = outStream.readLine()) != null) { - System.out.println(outLines); - } - errorLine = errors.toString(); - System.err.println(errorLine); - process.waitFor(waitTime, TimeUnit.MILLISECONDS); - int exitStatus = process.exitValue(); - if (exitStatus != 0 && errorLine != null && errorLine.isEmpty()) { - throw new RuntimeException(errorLine); - } - return exitStatus; - } - - /** - * Runs java command with provided arguments. Caller should not pass java - * command in the argument list. - * - * @param commands - * @return - * @throws Exception - */ - public static int runJava(List commands) throws Exception { - return runJava(commands, DEFAULT_WAIT_TIME); - } - - /** - * Run any command - * @param commands - * @return - * @throws Exception - */ - public static int runCommand(List commands) throws Exception { - String command = commands.toString().replace(",", " "); - System.out.println("Executing the following command \n" + command); - ProcessBuilder processBuilder = new ProcessBuilder(commands); - final Process process = processBuilder.start(); - BufferedReader errorStream = new BufferedReader( - new InputStreamReader(process.getErrorStream())); - BufferedReader outStream = new BufferedReader( - new InputStreamReader(process.getInputStream())); - String errorLine; - StringBuilder errors = new StringBuilder(); - String outLines; - while ((errorLine = errorStream.readLine()) != null) { - errors.append(errorLine).append("\n"); - } - while ((outLines = outStream.readLine()) != null) { - System.out.println(outLines); - } - errorLine = errors.toString(); - System.err.println(errorLine); - int exitStatus = process.exitValue(); - if (exitStatus != 0 && errorLine != null && errorLine.isEmpty()) { - throw new RuntimeException(errorLine); - } - return exitStatus; - } - - -} diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/SpliteratorOfIntDataBuilder.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/SpliteratorOfIntDataBuilder.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/SpliteratorOfIntDataBuilder.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/SpliteratorOfIntDataBuilder.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/SpliteratorTestHelper.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/SpliteratorTestHelper.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/SpliteratorTestHelper.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/SpliteratorTestHelper.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/CollectorOps.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/CollectorOps.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/CollectorOps.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/CollectorOps.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/DefaultMethodStreams.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/DefaultMethodStreams.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/DefaultMethodStreams.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/DefaultMethodStreams.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/DoubleStreamTestDataProvider.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/DoubleStreamTestDataProvider.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/DoubleStreamTestDataProvider.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/DoubleStreamTestDataProvider.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/DoubleStreamTestScenario.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/DoubleStreamTestScenario.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/DoubleStreamTestScenario.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/DoubleStreamTestScenario.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/FlagDeclaringOp.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/FlagDeclaringOp.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/FlagDeclaringOp.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/FlagDeclaringOp.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/IntStreamTestDataProvider.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/IntStreamTestDataProvider.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/IntStreamTestDataProvider.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/IntStreamTestDataProvider.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/IntStreamTestScenario.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/IntStreamTestScenario.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/IntStreamTestScenario.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/IntStreamTestScenario.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/IntermediateTestOp.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/IntermediateTestOp.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/IntermediateTestOp.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/IntermediateTestOp.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LambdaTestHelpers.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LambdaTestHelpers.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LambdaTestHelpers.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LambdaTestHelpers.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LambdaTestMode.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LambdaTestMode.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LambdaTestMode.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LambdaTestMode.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LoggingTestCase.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LoggingTestCase.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LoggingTestCase.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LoggingTestCase.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LongStreamTestDataProvider.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LongStreamTestDataProvider.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LongStreamTestDataProvider.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LongStreamTestDataProvider.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LongStreamTestScenario.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LongStreamTestScenario.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/LongStreamTestScenario.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/LongStreamTestScenario.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/OpTestCase.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/OpTestCase.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/OpTestCase.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/OpTestCase.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StatefulTestOp.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StatefulTestOp.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StatefulTestOp.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StatefulTestOp.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StatelessTestOp.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StatelessTestOp.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StatelessTestOp.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StatelessTestOp.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StreamOpFlagTestHelper.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StreamOpFlagTestHelper.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StreamOpFlagTestHelper.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StreamOpFlagTestHelper.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StreamTestDataProvider.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StreamTestDataProvider.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StreamTestDataProvider.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StreamTestDataProvider.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StreamTestScenario.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StreamTestScenario.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/StreamTestScenario.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/StreamTestScenario.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/TestData.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/TestData.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/TestData.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/TestData.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/TestFlagExpectedOp.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/TestFlagExpectedOp.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/TestFlagExpectedOp.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/TestFlagExpectedOp.java diff --git a/jdk/test/java/util/stream/bootlib/java.base/java/util/stream/ThrowableHelper.java b/jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/ThrowableHelper.java similarity index 100% rename from jdk/test/java/util/stream/bootlib/java.base/java/util/stream/ThrowableHelper.java rename to jdk/test/lib/testlibrary/bootlib/java.base/java/util/stream/ThrowableHelper.java diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/IOUtils.java b/jdk/test/lib/testlibrary/jdk/testlibrary/IOUtils.java deleted file mode 100644 index 4bfddd0485c..00000000000 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/IOUtils.java +++ /dev/null @@ -1,71 +0,0 @@ -/* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -/** - * Defines useful I/O methods. - */ -import java.io.IOException; -import java.io.InputStream; -import java.util.Arrays; - -public final class IOUtils { - - /* - * Prevent instantiation. - */ - private IOUtils() {} - - /** - * Read all bytes from in - * until EOF is detected. - * @param in input stream, must not be null - * @return bytes read - * @throws IOException Any IO error. - */ - public static byte[] readFully(InputStream is) throws IOException { - byte[] output = {}; - int pos = 0; - while (true) { - int bytesToRead; - if (pos >= output.length) { // Only expand when there's no room - bytesToRead = output.length + 1024; - if (output.length < pos + bytesToRead) { - output = Arrays.copyOf(output, pos + bytesToRead); - } - } else { - bytesToRead = output.length - pos; - } - int cc = is.read(output, pos, bytesToRead); - if (cc < 0) { - if (output.length != pos) { - output = Arrays.copyOf(output, pos); - } - break; - } - pos += cc; - } - return output; - } -} diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/JDKToolLauncher.java b/jdk/test/lib/testlibrary/jdk/testlibrary/JDKToolLauncher.java index cd3b7cea022..c19cb5df63a 100644 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/JDKToolLauncher.java +++ b/jdk/test/lib/testlibrary/jdk/testlibrary/JDKToolLauncher.java @@ -24,7 +24,6 @@ package jdk.testlibrary; import java.util.ArrayList; -import java.util.Arrays; import java.util.List; /** @@ -60,7 +59,6 @@ public class JDKToolLauncher { } else { executable = JDKToolFinder.getTestJDKTool(tool); } - vmArgs.addAll(Arrays.asList(ProcessTools.getPlatformSpecificVMArgs())); } /** diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/ProcessTools.java b/jdk/test/lib/testlibrary/jdk/testlibrary/ProcessTools.java index d4626fa804b..461977302ed 100644 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/ProcessTools.java +++ b/jdk/test/lib/testlibrary/jdk/testlibrary/ProcessTools.java @@ -259,23 +259,6 @@ public final class ProcessTools { return ProcessHandle.current().pid(); } - /** - * Get platform specific VM arguments (e.g. -d64 on 64bit Solaris) - * - * @return String[] with platform specific arguments, empty if there are - * none - */ - public static String[] getPlatformSpecificVMArgs() { - String osName = System.getProperty("os.name"); - String dataModel = System.getProperty("sun.arch.data.model"); - - if (osName.equals("SunOS") && dataModel.equals("64")) { - return new String[] { "-d64" }; - } - - return new String[] {}; - } - /** * Create ProcessBuilder using the java launcher from the jdk to be tested, * and with any platform specific arguments prepended. @@ -283,8 +266,7 @@ public final class ProcessTools { * @param command Arguments to pass to the java command. * @return The ProcessBuilder instance representing the java command. */ - public static ProcessBuilder createJavaProcessBuilder(String... command) - throws Exception { + public static ProcessBuilder createJavaProcessBuilder(String... command) { return createJavaProcessBuilder(false, command); } @@ -297,12 +279,11 @@ public final class ProcessTools { * @param command Arguments to pass to the java command. * @return The ProcessBuilder instance representing the java command. */ - public static ProcessBuilder createJavaProcessBuilder(boolean addTestVmAndJavaOptions, String... command) throws Exception { + public static ProcessBuilder createJavaProcessBuilder(boolean addTestVmAndJavaOptions, String... command) { String javapath = JDKToolFinder.getJDKTool("java"); ArrayList args = new ArrayList<>(); args.add(javapath); - Collections.addAll(args, getPlatformSpecificVMArgs()); if (addTestVmAndJavaOptions) { // -cp is needed to make sure the same classpath is used whether the test is diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/RandomFactory.java b/jdk/test/lib/testlibrary/jdk/testlibrary/RandomFactory.java index 0951d11031d..4cac61c1a0c 100644 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/RandomFactory.java +++ b/jdk/test/lib/testlibrary/jdk/testlibrary/RandomFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,12 @@ import java.util.SplittableRandom; * Factory class which generates and prints to STDOUT a long-valued seed * for use in initializing a PRNG. An instance of {@code Random} or * {@code SplittableRandom} may likewise be obtained. + * + * @deprecated This class is deprecated. Use the one from + * {@code /test/lib/jdk/test/lib} + * */ +@Deprecated public class RandomFactory { /** * Attempt to obtain the seed from the value of the "seed" property. diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/TimeLimitedRunner.java b/jdk/test/lib/testlibrary/jdk/testlibrary/TimeLimitedRunner.java deleted file mode 100644 index 5cc98ea8f8a..00000000000 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/TimeLimitedRunner.java +++ /dev/null @@ -1,86 +0,0 @@ -/* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary; - -import java.util.Objects; -import java.util.concurrent.Callable; - -/** - * Auxiliary class to run target w/ given timeout. - */ -public class TimeLimitedRunner implements Callable { - private final long stoptime; - private final long timeout; - private final double factor; - private final Callable target; - - /** - * @param timeout a timeout. zero means no time limitation - * @param factor a multiplier used to estimate next iteration time - * @param target a target to run - * @throws NullPointerException if target is null - * @throws IllegalArgumentException if timeout is negative or - factor isn't positive - */ - public TimeLimitedRunner(long timeout, double factor, - Callable target) { - Objects.requireNonNull(target, "target must not be null"); - if (timeout < 0) { - throw new IllegalArgumentException("timeout[" + timeout + "] < 0"); - } - if (factor <= 0d) { - throw new IllegalArgumentException("factor[" + factor + "] <= 0"); - } - this.stoptime = System.currentTimeMillis() + timeout; - this.timeout = timeout; - this.factor = factor; - this.target = target; - } - - /** - * Runs @{linkplan target} while it returns true and timeout isn't exceeded - */ - @Override - public Void call() throws Exception { - long maxDuration = 0L; - long iterStart = System.currentTimeMillis(); - if (timeout != 0 && iterStart > stoptime) { - return null; - } - while (target.call()) { - if (timeout != 0) { - long iterDuration = System.currentTimeMillis() - iterStart; - maxDuration = Math.max(maxDuration, iterDuration); - iterStart = System.currentTimeMillis(); - if (iterStart + (maxDuration * factor) > stoptime) { - System.out.println("Not enough time to continue execution. " - + "Interrupted."); - break; - } - } - } - return null; - } - -} diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/management/InputArguments.java b/jdk/test/lib/testlibrary/jdk/testlibrary/management/InputArguments.java deleted file mode 100644 index 7fc2f678490..00000000000 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/management/InputArguments.java +++ /dev/null @@ -1,88 +0,0 @@ -/* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package jdk.testlibrary.management; - -import java.lang.management.RuntimeMXBean; -import java.lang.management.ManagementFactory; -import java.util.List; - -/** - * This class provides access to the input arguments to the VM. - */ -public class InputArguments { - private static final List args; - - static { - RuntimeMXBean runtimeMxBean = ManagementFactory.getRuntimeMXBean(); - args = runtimeMxBean.getInputArguments(); - } - - /** - * Returns true if {@code arg} is an input argument to the VM. - * - * This is useful for checking boolean flags such as -XX:+UseSerialGC or - * -XX:-UsePerfData. - * - * @param arg The name of the argument. - * @return {@code true} if the given argument is an input argument, - * otherwise {@code false}. - */ - public static boolean contains(String arg) { - return args.contains(arg); - } - - /** - * Returns true if {@code prefix} is the start of an input argument to the - * VM. - * - * This is useful for checking if flags describing a quantity, such as - * -XX:+MaxMetaspaceSize=100m, is set without having to know the quantity. - * To check if the flag -XX:MaxMetaspaceSize is set, use - * {@code InputArguments.containsPrefix("-XX:MaxMetaspaceSize")}. - * - * @param prefix The start of the argument. - * @return {@code true} if the given argument is the start of an input - * argument, otherwise {@code false}. - */ - public static boolean hasArgStartingWith(String prefix) { - for (String arg : args) { - if (arg.startsWith(prefix)) { - return true; - } - } - return false; - } - - /** - * Get the string containing input arguments passed to the VM - */ - public static String getInputArguments() { - StringBuilder result = new StringBuilder(); - for (String arg : args) - result.append(arg).append(' '); - - return result.toString(); - } - -} diff --git a/jdk/test/sun/misc/SunMiscSignalTest.java b/jdk/test/sun/misc/SunMiscSignalTest.java index 33d4d3ac41c..056843e673c 100644 --- a/jdk/test/sun/misc/SunMiscSignalTest.java +++ b/jdk/test/sun/misc/SunMiscSignalTest.java @@ -46,7 +46,12 @@ import sun.misc.SignalHandler; * @library /test/lib * @modules jdk.unsupported * java.base/jdk.internal.misc - * @build jdk.test.lib.Platform jdk.test.lib.Utils + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run testng/othervm -Xrs -DXrs=true SunMiscSignalTest * @run testng/othervm SunMiscSignalTest * @summary sun.misc.Signal test diff --git a/jdk/test/sun/net/InetAddress/nameservice/dns/CNameTest.java b/jdk/test/sun/net/InetAddress/nameservice/dns/CNameTest.java new file mode 100644 index 00000000000..3836947eea4 --- /dev/null +++ b/jdk/test/sun/net/InetAddress/nameservice/dns/CNameTest.java @@ -0,0 +1,73 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import jdk.test.lib.process.ProcessTools; + +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.nio.file.StandardOpenOption; + +/** + * @test + * @bug 4763315 + * @modules java.naming + * @library /test/lib + * @build CanonicalName Lookup jdk.test.lib.process.* + * @run main/othervm/timeout=120 CNameTest + * @summary Test DNS provider's handling of CNAME records + */ +public class CNameTest { + private static final String HOST = "www-proxy.us.oracle.com"; + private static final String POLICY = "grant {" + System.lineSeparator() + + " permission java.net .SocketPermission \"${HOST}\", \"resolve\";" + + System.lineSeparator() + "};"; + + public static void main(String[] args) throws Exception { + // Prerequisite check + int rc = ProcessTools.executeTestJava("CanonicalName", HOST) + .outputTo(System.out) + .errorTo(System.out) + .getExitValue(); + if (rc != 0) { + System.out.println("DNS not configured or host doesn't" + + " resolve to CNAME record"); + return; + } + + // Tests - with & without security manager + Path policy = Paths.get(".", "java.policy"); + Files.write(policy, POLICY.getBytes(), StandardOpenOption.CREATE_NEW); + String[] opts = new String[]{ + "-Dsun.net.spi.nameservice.provider.1=dns,sun", + "-Djava.security.manager -Djava.security.policy=" + policy + }; + for (String opt : opts) { + ProcessTools.executeTestJava(opt, "Lookup", HOST) + .outputTo(System.out) + .errorTo(System.err) + .shouldHaveExitValue(0); + } + } +} + diff --git a/jdk/test/sun/net/InetAddress/nameservice/dns/cname.sh b/jdk/test/sun/net/InetAddress/nameservice/dns/cname.sh deleted file mode 100644 index a93f2652613..00000000000 --- a/jdk/test/sun/net/InetAddress/nameservice/dns/cname.sh +++ /dev/null @@ -1,81 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - - -# @test -# @bug 4763315 -# @modules java.naming -# @build CanonicalName Lookup -# @run shell/timeout=120 cname.sh -# @summary Test DNS provider's handling of CNAME records - - -# The host that we try to resolve - -HOST=www-proxy.us.oracle.com - -# fail gracefully if DNS is not configured or there -# isn't a CNAME record. - -CLASSPATH=${TESTCLASSES} -export CLASSPATH -JAVA="${TESTJAVA}/bin/java" - -sh -xc "$JAVA ${TESTVMOPTS} CanonicalName $HOST" 2>&1 -if [ $? != 0 ]; then - echo "DNS not configured or host doesn't resolve to CNAME record" - exit 0 -fi - -failures=0 - -go() { - echo '' - sh -xc "$JAVA ${TESTVMOPTS} $1 Lookup $2" 2>&1 - if [ $? != 0 ]; then failures=`expr $failures + 1`; fi -} - -# Tests - with & without security manager - -POLICY=java.policy -echo "grant {" > ${POLICY} -echo " permission java.net.SocketPermission \"${HOST}\", \"resolve\";" >> ${POLICY} -echo "};" >> ${POLICY} - -np="-Dsun.net.spi.nameservice.provider.1=dns,sun" -sm="-Djava.security.manager -Djava.security.policy=${POLICY}" - -go "" "$HOST" -go "$sm" "$HOST" - - -# -# Results -# -echo '' -if [ $failures -gt 0 ]; - then echo "$failures test(s) failed"; - else echo "All test(s) passed"; fi -exit $failures diff --git a/jdk/test/sun/net/ftp/MarkResetTest.java b/jdk/test/sun/net/ftp/MarkResetTest.java index 1f9e1bdec94..d3236fe5544 100644 --- a/jdk/test/sun/net/ftp/MarkResetTest.java +++ b/jdk/test/sun/net/ftp/MarkResetTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,15 +22,30 @@ */ /* - * - * run from MarkResetTest.sh + * @test + * @bug 4673103 + * @run main/othervm/timeout=140 MarkResetTest + * @summary URLConnection.getContent() hangs over FTP for DOC, PPT, XLS files */ -import java.io.*; -import java.net.*; -import java.util.regex.*; +import java.io.BufferedReader; +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.io.OutputStream; +import java.io.PrintWriter; +import java.net.InetAddress; +import java.net.ServerSocket; +import java.net.Socket; +import java.net.URL; +import java.net.URLConnection; +import java.nio.file.Files; +import java.nio.file.Paths; public class MarkResetTest { + private static final String FILE_NAME = "EncDec.doc"; /** * A class that simulates, on a separate, an FTP server. @@ -388,7 +403,9 @@ public class MarkResetTest { } public static void main(String[] args) throws Exception { - MarkResetTest test = new MarkResetTest(); + Files.copy(Paths.get(System.getProperty("test.src"), FILE_NAME), + Paths.get(".", FILE_NAME)); + new MarkResetTest(); } public MarkResetTest() { @@ -402,9 +419,8 @@ public class MarkResetTest { port = server.getPort(); } - String filename = "EncDec.doc"; - URL url = new URL("ftp://localhost:" + port + "/" + - filename); + + URL url = new URL("ftp://localhost:" + port + "/" + FILE_NAME); URLConnection con = url.openConnection(); System.out.println("getContent: " + con.getContent()); @@ -438,7 +454,7 @@ public class MarkResetTest { server.interrupt(); // Did we pass ? - if (len != (new File(filename)).length()) { + if (len != (new File(FILE_NAME)).length()) { throw new Exception("Failed to read the file correctly"); } System.out.println("PASSED: File read correctly"); diff --git a/jdk/test/sun/net/ftp/MarkResetTest.sh b/jdk/test/sun/net/ftp/MarkResetTest.sh deleted file mode 100644 index b673e5d4d68..00000000000 --- a/jdk/test/sun/net/ftp/MarkResetTest.sh +++ /dev/null @@ -1,55 +0,0 @@ -# -# Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4673103 -# @run shell/timeout=140 MarkResetTest.sh -# @summary URLConnection.getContent() hangs over FTP for DOC, PPT, XLS files - -OS=`uname -s` -case "$OS" in - SunOS | Linux | Darwin | AIX ) - PS=":" - FS="/" - ;; - CYGWIN* ) - PS=";" - FS="/" - ;; - Windows* ) - PS=";" - FS="\\" - ;; - * ) - echo "Unrecognized system!" - exit 1; - ;; -esac - -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}${FS}MarkResetTest.java - -# ftp server used by the test requires the file to be present -# in this directory -cp ${TESTSRC}${FS}EncDec.doc . - -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} MarkResetTest diff --git a/jdk/test/sun/net/www/protocol/file/DirPermissionDenied.java b/jdk/test/sun/net/www/protocol/file/DirPermissionDenied.java index 7ffe3a1d67c..a391428f329 100644 --- a/jdk/test/sun/net/www/protocol/file/DirPermissionDenied.java +++ b/jdk/test/sun/net/www/protocol/file/DirPermissionDenied.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,14 +21,36 @@ * questions. */ +/** + * @test + * @bug 6977851 + * @summary NPE from FileURLConnection.connect + * @library /test/lib + * @build DirPermissionDenied jdk.test.lib.process.* + * jdk.test.lib.util.FileUtils + * @run testng DirPermissionDenied + */ + +import java.io.IOException; +import java.net.MalformedURLException; import java.net.URL; import java.net.URLConnection; -import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import jdk.test.lib.process.ProcessTools; +import jdk.test.lib.util.FileUtils; +import org.testng.annotations.AfterTest; +import org.testng.annotations.Test; +import org.testng.annotations.BeforeTest; public class DirPermissionDenied { - public static void main(String[] args) throws Exception { - URL url = new URL("file:" + args[0]); + private static final Path TEST_DIR = Paths.get( + "DirPermissionDeniedDirectory"); + @Test + public void doTest() throws MalformedURLException { + URL url = new URL(TEST_DIR.toUri().toString()); try { URLConnection uc = url.openConnection(); uc.connect(); @@ -56,4 +78,20 @@ public class DirPermissionDenied { throw new RuntimeException("Failed " + e); } } + + @BeforeTest + public void setup() throws Throwable { + // mkdir and chmod "333" + Files.createDirectories(TEST_DIR); + ProcessTools.executeCommand("chmod", "333", TEST_DIR.toString()) + .outputTo(System.out) + .errorTo(System.out) + .shouldHaveExitValue(0); + } + + @AfterTest + public void tearDown() throws IOException { + FileUtils.deleteFileIfExistsWithRetry(TEST_DIR); + } } + diff --git a/jdk/test/sun/net/www/protocol/file/DirPermissionDenied.sh b/jdk/test/sun/net/www/protocol/file/DirPermissionDenied.sh deleted file mode 100644 index 1bceecfe7ca..00000000000 --- a/jdk/test/sun/net/www/protocol/file/DirPermissionDenied.sh +++ /dev/null @@ -1,45 +0,0 @@ -# -# Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# -# @test -# @bug 6977851 -# @summary NPE from FileURLConnection.connect -# @build DirPermissionDenied -# @run shell DirPermissionDenied.sh - -TESTDIR="${TESTCLASSES}/DirPermissionDeniedDirectory" -echo ${TESTDIR} - -rm -rf ${TESTDIR} -mkdir -p ${TESTDIR} -chmod 333 ${TESTDIR} - -$TESTJAVA/bin/java ${TESTVMOPTS} -classpath $TESTCLASSES DirPermissionDenied ${TESTDIR} -result=$? - -# Add back read access for user, otherwise not removable on some systems -chmod u+r ${TESTDIR} - -rm -rf ${TESTDIR} -exit $result diff --git a/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/B6216082.java b/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/B6216082.java index fbdad8c8953..62cbc93e492 100644 --- a/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/B6216082.java +++ b/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/B6216082.java @@ -31,9 +31,11 @@ * @bug 6216082 * @summary Redirect problem with HttpsURLConnection using a proxy * @modules java.base/sun.net.www - * @library .. /lib/testlibrary - * @build HttpCallback TestHttpsServer ClosedChannelList - * HttpTransaction TunnelProxy jdk.testlibrary.NetworkConfiguration + * @library .. /test/lib + * @build jdk.test.lib.NetworkConfiguration + * jdk.test.lib.Platform + * HttpCallback TestHttpsServer ClosedChannelList + * HttpTransaction TunnelProxy * @key intermittent * @run main/othervm B6216082 */ @@ -43,7 +45,7 @@ import java.net.*; import javax.net.ssl.*; import java.util.*; -import jdk.testlibrary.NetworkConfiguration; +import jdk.test.lib.NetworkConfiguration; public class B6216082 { static SimpleHttpTransaction httpTrans; diff --git a/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxy.java b/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxy.java index 8393a4ef4a2..eeb1150464e 100644 --- a/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxy.java +++ b/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxy.java @@ -39,6 +39,12 @@ import jdk.test.lib.process.ProcessTools; * that serves http POST method requests in secure channel, and a client * that makes https POST request through a proxy. * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @compile OriginServer.java ProxyTunnelServer.java * @run main/othervm PostThruProxy */ diff --git a/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxyWithAuth.java b/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxyWithAuth.java index daf75bc65dc..0c6c06facaf 100644 --- a/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxyWithAuth.java +++ b/jdk/test/sun/net/www/protocol/https/HttpsURLConnection/PostThruProxyWithAuth.java @@ -39,6 +39,12 @@ import jdk.test.lib.process.ProcessTools; * http POST method requests in secure channel, and a client that * makes https POST request through a proxy. * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @compile OriginServer.java ProxyTunnelServer.java * @run main/othervm -Djdk.http.auth.tunneling.disabledSchemes= PostThruProxyWithAuth */ diff --git a/jdk/test/sun/net/www/protocol/jar/B5105410.java b/jdk/test/sun/net/www/protocol/jar/B5105410.java index 365c2d0f743..7401e4ef766 100644 --- a/jdk/test/sun/net/www/protocol/jar/B5105410.java +++ b/jdk/test/sun/net/www/protocol/jar/B5105410.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,23 +21,43 @@ * questions. */ -import java.net.*; -import java.io.*; +/** + * @test + * @bug 5105410 + * @run main/othervm B5105410 + * @summary ZipFile$ZipFileInputStream doesn't close handle to zipfile + */ + +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.net.URL; +import java.net.URLConnection; +import java.nio.file.Files; +import java.nio.file.Paths; +import static java.nio.file.StandardCopyOption.REPLACE_EXISTING; public class B5105410 { public static void main (String[] args) throws Exception { - URL url = new URL ("jar:file:./foo2.jar!/bar.txt"); - URLConnection urlc = url.openConnection (); - urlc.setUseCaches (false); + setup(); + URL url = new URL("jar:file:./foo2.jar!/bar.txt"); + URLConnection urlc = url.openConnection(); + urlc.setUseCaches(false); InputStream is = urlc.getInputStream(); is.read(); is.close(); - File file = new File ("foo2.jar"); - if (!file.delete ()) { - throw new RuntimeException ("Could not delete foo2.jar"); + File file = new File("foo2.jar"); + if (!file.delete()) { + throw new RuntimeException("Could not delete foo2.jar"); } if (file.exists()) { - throw new RuntimeException ("foo2.jar still exists"); + throw new RuntimeException("foo2.jar still exists"); } } + + static void setup() throws IOException { + Files.copy(Paths.get(System.getProperty("test.src"), "foo2.jar"), + Paths.get(".", "foo2.jar"), REPLACE_EXISTING); + } } + diff --git a/jdk/test/sun/net/www/protocol/jar/B5105410.sh b/jdk/test/sun/net/www/protocol/jar/B5105410.sh deleted file mode 100644 index aa31a53ebc2..00000000000 --- a/jdk/test/sun/net/www/protocol/jar/B5105410.sh +++ /dev/null @@ -1,55 +0,0 @@ -#! /bin/sh - -# -# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @author Michael McMahon -# @bug 5105410 -# @summary ZipFile$ZipFileInputStream doesn't close handle to zipfile -# - -OS=`uname -s` -case "$OS" in - SunOS | Linux | Darwin | AIX ) - PS=":" - FS="/" - ;; - CYGWIN* ) - PS=";" - FS="/" - ;; - Windows* ) - PS=";" - FS="\\" - ;; - * ) - echo "Unrecognized system!" - exit 1; - ;; -esac - -cp ${TESTSRC}${FS}foo2.jar . -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d . ${TESTSRC}${FS}B5105410.java -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} B5105410 - diff --git a/jdk/test/sun/net/www/protocol/jar/B6449504.java b/jdk/test/sun/net/www/protocol/jar/B6449504.java index 0ef1e681ba0..8893380455f 100644 --- a/jdk/test/sun/net/www/protocol/jar/B6449504.java +++ b/jdk/test/sun/net/www/protocol/jar/B6449504.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,63 +24,72 @@ /** * @test * @bug 6449504 - * @run shell copyin.sh bar.jar - * @run main B6449504 caching - * @run main B6449504 no_caching + * @run main/othervm B6449504 caching + * @run main/othervm B6449504 no_caching * @summary REGRESSION: ZipException throws when try to read a XML file */ -import java.io.*; -import java.net.*; +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.net.JarURLConnection; +import java.net.URL; +import java.nio.file.Files; +import java.nio.file.Paths; +import java.nio.file.StandardCopyOption; public class B6449504 { public static void main (String[] args) throws Exception { - - boolean caching = args[0].equals ("caching"); - - String dirname = System.getProperty ("test.classes"); - File f = new File (dirname); + setup(); + boolean caching = args[0].equals("caching"); + String dirname = System.getProperty("test.classes"); + File f = new File(dirname); dirname = f.toURI().toString(); - String u = "jar:"+ dirname + "/bar.jar"; - URL url = new URL (u+"!/DoesNotExist.txt"); - System.out.println ("url = " + url); + String u = "jar:" + dirname + "/bar.jar"; + URL url = new URL(u + "!/DoesNotExist.txt"); + System.out.println("url = " + url); JarURLConnection j1 = (JarURLConnection)url.openConnection(); - URL url2 = new URL (u+"!/test.txt"); - System.out.println ("url2 = " + url2); + URL url2 = new URL(u + "!/test.txt"); + System.out.println("url2 = " + url2); JarURLConnection j2 = (JarURLConnection)url2.openConnection(); - j1.setUseCaches (caching); - j2.setUseCaches (caching); + j1.setUseCaches(caching); + j2.setUseCaches(caching); /* connecting to j2 opens the jar file but does not read it */ - j2.connect (); + j2.connect(); try { /* attempt to read a non-existing entry in the jar file * shows the bug, where the jar file is closed after the * attempt fails. */ - InputStream is = j1.getInputStream (); + InputStream is = j1.getInputStream(); } catch (IOException e) { - System.out.println ("Got expected exception from j1 "); + System.out.println("Got expected exception from j1 "); } /* If bug present, this will fail because we think the jar * is ready to be read, after the connect() above, but we * get a ZipException because it has been closed */ - InputStream is = j2.getInputStream (); - readAndClose (is); - System.out.println ("OK"); + InputStream is = j2.getInputStream(); + readAndClose(is); + System.out.println("OK"); } - static void readAndClose (InputStream is) throws IOException { + static void readAndClose(InputStream is) throws IOException { while (is.read() != -1) ; is.close(); } + static void setup() throws IOException { + Files.copy(Paths.get(System.getProperty("test.src"), "bar.jar"), + Paths.get(System.getProperty("test.classes"), "bar.jar"), + StandardCopyOption.REPLACE_EXISTING); + } } diff --git a/jdk/test/sun/net/www/protocol/jar/GetContentType.java b/jdk/test/sun/net/www/protocol/jar/GetContentType.java index aef0b5a41ac..81db100eeec 100644 --- a/jdk/test/sun/net/www/protocol/jar/GetContentType.java +++ b/jdk/test/sun/net/www/protocol/jar/GetContentType.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,18 +21,8 @@ * questions. */ -/* - * @test - * @bug 4274624 - * @summary Test JarURLConnection.getContentType would - * would return default "content/unknown" - * - * @build GetContentType - * @run shell getcontenttype.sh - */ - -import java.net.URL; import java.io.InputStream; +import java.net.URL; public class GetContentType { public static void main(String args[]) throws Exception { diff --git a/jdk/test/sun/net/www/protocol/jar/GetContentTypeTest.java b/jdk/test/sun/net/www/protocol/jar/GetContentTypeTest.java new file mode 100644 index 00000000000..16a59d65dc2 --- /dev/null +++ b/jdk/test/sun/net/www/protocol/jar/GetContentTypeTest.java @@ -0,0 +1,59 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 4274624 + * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * GetContentType GetContentTypeTest + * @run main/othervm GetContentTypeTest + * @summary Test JarURLConnection.getContentType would + * would return default "content/unknown" + */ + +import jdk.test.lib.JDKToolFinder; +import jdk.test.lib.process.ProcessTools; + +import java.io.File; +import java.nio.file.Path; +import java.nio.file.Paths; + +public class GetContentTypeTest { + public static void main(String[] args) throws Throwable { + Path resJar = Paths.get(System.getProperty("test.src"), + "resource.jar"); + Path classes = Paths.get(System.getProperty("test.classes")); + ProcessTools.executeCommand( + JDKToolFinder.getTestJDKTool("java"), + "-cp", resJar + File.pathSeparator + classes, "GetContentType") + .outputTo(System.out) + .errorTo(System.out) + .shouldHaveExitValue(0); + } +} diff --git a/jdk/test/sun/net/www/protocol/jar/copyin.sh b/jdk/test/sun/net/www/protocol/jar/copyin.sh deleted file mode 100644 index bae70d82de7..00000000000 --- a/jdk/test/sun/net/www/protocol/jar/copyin.sh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/ksh - -# -# Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -echo current directory is `pwd` -set -x -for i in $*; do - rm -f $TESTCLASSES/$i - cp $TESTSRC/$i $TESTCLASSES -done diff --git a/jdk/test/sun/net/www/protocol/jar/getcontenttype.sh b/jdk/test/sun/net/www/protocol/jar/getcontenttype.sh deleted file mode 100644 index 8a942998a70..00000000000 --- a/jdk/test/sun/net/www/protocol/jar/getcontenttype.sh +++ /dev/null @@ -1,51 +0,0 @@ -#! /bin/sh - -# -# Copyright (c) 1999, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# - -if [ x"$TESTJAVA" = x ]; then - TESTJAVA=$1 - shift -fi -if [ x"$TESTCLASSES" = x ]; then TESTCLASSES=.; fi -if [ x"$TESTSRC" = x ]; then TESTSRC=.; fi - -OS=`uname -s`; -# Set classpath separator -case "$OS" in - Windows* | CYGWIN* ) - SEP=";" - FS="\\" - ;; - - * ) - SEP=":" - FS="/" - ;; -esac - -# now start the test -${TESTJAVA}/bin/java ${TESTVMOPTS} -cp ${TESTSRC}${FS}resource.jar${SEP}${TESTCLASSES} GetContentType - diff --git a/jdk/test/sun/net/www/protocol/jar/jarbug/TestDriver.java b/jdk/test/sun/net/www/protocol/jar/jarbug/TestDriver.java new file mode 100644 index 00000000000..7867bc6f870 --- /dev/null +++ b/jdk/test/sun/net/www/protocol/jar/jarbug/TestDriver.java @@ -0,0 +1,93 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 4361044 4388202 4418643 4523159 4730642 + * @library /test/lib + * /lib/testlibrary + * @modules jdk.compiler + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * src.test.src.TestDriver JarUtils + * @summary various resource and classloading bugs related to jar files + * @run main/othervm TestDriver + */ + +import jdk.test.lib.JDKToolFinder; +import jdk.test.lib.compiler.CompilerUtils; +import jdk.test.lib.process.ProcessTools; + +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import static java.nio.file.StandardCopyOption.REPLACE_EXISTING; + +public class TestDriver { + public static void main(String[] args) throws Throwable { + Path srcDir = Paths.get(System.getProperty("test.src")); + Path targetDir = Paths.get(System.getProperty("user.dir")); + Path jar1SrcDir = srcDir.resolve("src").resolve("jar1"); + Path jar1TargetDir = targetDir.resolve("jar1"); + Path ectJar1Dir = srcDir.resolve("etc").resolve("jar1"); + Path jarFile = targetDir.resolve("jar1.jar"); + Path[] files= new Path[] { + Paths.get("res1.txt"), Paths.get("jar1", "bundle.properties") + }; + + // Copy files to target directory and change permission + for (Path file : files) { + Path dest = jar1TargetDir.resolve(file); + Files.createDirectories(dest.getParent()); + Files.copy(ectJar1Dir.resolve(file), dest, REPLACE_EXISTING); + } + + // Compile and build jar1.jar + ProcessTools.executeCommand("chmod", "-R", "u+w", "./jar1") + .outputTo(System.out) + .errorTo(System.out) + .shouldHaveExitValue(0); + CompilerUtils.compile(jar1SrcDir, jar1TargetDir); + JarUtils.createJarFile(jarFile, jar1TargetDir); + + // Compile test files + CompilerUtils.compile(srcDir.resolve("src").resolve("test"), targetDir); + + // Run tests + String java = JDKToolFinder.getTestJDKTool("java"); + String cp = targetDir.toString() + File.pathSeparator + jarFile; + String[] tests = new String[]{"TestBug4361044", "TestBug4523159"}; + for (String test : tests) { + ProcessTools.executeCommand(java, "-cp", cp, test) + .outputTo(System.out) + .errorTo(System.out) + .shouldHaveExitValue(0); + } + } +} diff --git a/jdk/test/sun/net/www/protocol/jar/jarbug/run.sh b/jdk/test/sun/net/www/protocol/jar/jarbug/run.sh deleted file mode 100644 index 32de6ee0f78..00000000000 --- a/jdk/test/sun/net/www/protocol/jar/jarbug/run.sh +++ /dev/null @@ -1,84 +0,0 @@ -#! /bin/sh - -# -# Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @bug 4361044 4388202 4418643 4523159 4730642 -# @summary various resource and classloading bugs related to jar files -#set -x -DEST=`pwd` - -OS=`uname -s` -case "$OS" in - SunOS | Linux | Darwin | AIX ) - PS=":" - FS="/" - CHMOD="${FS}bin${FS}chmod" - ;; - Windows* ) - PS=";" - FS="\\" - CHMOD="chmod" - ;; - CYGWIN* ) - PS=";" - FS="/" - CHMOD="chmod" - # - # javac does not like /cygdrive produced by `pwd`. - # - DEST=`cygpath -d ${DEST}` - ;; - * ) - echo "Unrecognized system!" - exit 1; - ;; -esac - -# -# build jar1 -# -mkdir -p ${DEST}${FS}jar1 -cd ${TESTSRC}${FS}etc${FS}jar1 -cp -r . ${DEST}${FS}jar1 -${CHMOD} -R u+w ${DEST}${FS}jar1 -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d ${DEST}${FS}jar1 \ - ${TESTSRC}${FS}src${FS}jar1${FS}LoadResourceBundle.java -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d ${DEST}${FS}jar1 \ - ${TESTSRC}${FS}src${FS}jar1${FS}GetResource.java -cd ${DEST}${FS}jar1 -${COMPILEJAVA}${FS}bin${FS}jar ${TESTTOOLVMOPTS} cfM jar1.jar jar1 res1.txt -mv jar1.jar .. -# -# build the test sources and run them -# -${COMPILEJAVA}${FS}bin${FS}javac ${TESTJAVACOPTS} ${TESTTOOLVMOPTS} -d ${DEST} ${TESTSRC}${FS}src${FS}test${FS}*.java -cd ${DEST} -${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} RunAllTests -result=$? -if [ "$result" -ne "0" ]; then - exit 1 -fi -rm -rf * -exit 0 diff --git a/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/TestBug4361044.java b/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/TestBug4361044.java index cd9fe24c099..26c8f8101b3 100644 --- a/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/TestBug4361044.java +++ b/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/TestBug4361044.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2007, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,9 +21,9 @@ * questions. */ -import java.io.*; -import java.net.*; -import java.util.jar.*; +import java.io.File; +import java.net.URL; +import java.net.URLClassLoader; /* * ResourceBundle from jar not found if jar exists in path @@ -38,40 +38,17 @@ import java.util.jar.*; public class TestBug4361044 extends JarTest { public void run(String[] args) throws Exception { - if (args.length == 0 ) { // execute the test in another vm. - System.out.println("Test: " + getClass().getName()); - Process process = Runtime.getRuntime().exec(javaCmd + " TestBug4361044 -test"); - - BufferedReader isReader = new BufferedReader(new InputStreamReader(process.getInputStream())); - BufferedReader esReader = new BufferedReader(new InputStreamReader(process.getErrorStream())); - Redirector outRedirector = new Redirector(isReader, System.out); - Redirector errRedirector = new Redirector(esReader, System.err); - - (new Thread(outRedirector)).start(); - (new Thread(errRedirector)).start(); - - process.waitFor(); - - // Delete any remaining files from the test - File testDir = new File(tmpdir + File.separator + getClass().getName()); - deleteRecursively(testDir); - - if (outRedirector.getHasReadData() || errRedirector.getHasReadData()) - throw new RuntimeException("Failed: No output should have been received from the process"); - - } else { // run the test. - File tmp = createTempDir(); - try { - File dir = new File(tmp, "dir!name"); - dir.mkdir(); - File testFile = copyResource(dir, "jar1.jar"); - URL[] urls = new URL[1]; - urls[0] = new URL("jar:" + testFile.toURL() + "!/"); - URLClassLoader loader = new URLClassLoader(urls); - loader.loadClass("jar1.LoadResourceBundle").newInstance(); - } finally { - deleteRecursively(tmp); - } + File tmp = createTempDir(); + try { + File dir = new File(tmp, "dir!name"); + dir.mkdir(); + File testFile = copyResource(dir, "jar1.jar"); + URL[] urls = new URL[1]; + urls[0] = new URL("jar:" + testFile.toURI().toURL() + "!/"); + URLClassLoader loader = new URLClassLoader(urls); + loader.loadClass("jar1.LoadResourceBundle").newInstance(); + } finally { + deleteRecursively(tmp); } } diff --git a/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/TestBug4523159.java b/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/TestBug4523159.java index 0af55342036..6983a5e0fe0 100644 --- a/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/TestBug4523159.java +++ b/jdk/test/sun/net/www/protocol/jar/jarbug/src/test/TestBug4523159.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2007, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,9 +21,12 @@ * questions. */ -import java.io.*; -import java.net.*; -import java.util.jar.*; +import java.io.File; +import java.net.JarURLConnection; +import java.net.URL; +import java.net.URLClassLoader; +import java.util.jar.JarEntry; +import java.util.jar.JarFile; /* * Issuing a getResourceAsStream() call will throw an exception if: @@ -40,53 +43,30 @@ import java.util.jar.*; public class TestBug4523159 extends JarTest { public void run(String[] args) throws Exception { - if (args.length == 0 ) { // execute the test in another vm. - System.out.println("Test: " + getClass().getName()); - Process process = Runtime.getRuntime().exec(javaCmd + " TestBug4523159 -test"); + File tmp = createTempDir(); + try { + File dir = new File(tmp, "dir!name"); + dir.mkdir(); + File testFile = copyResource(dir, "jar1.jar"); - BufferedReader isReader = new BufferedReader(new InputStreamReader(process.getInputStream())); - BufferedReader esReader = new BufferedReader(new InputStreamReader(process.getErrorStream())); - Redirector outRedirector = new Redirector(isReader, System.out); - Redirector errRedirector = new Redirector(esReader, System.err); - - (new Thread(outRedirector)).start(); - (new Thread(errRedirector)).start(); - - process.waitFor(); - - // Delete any remaining files from the test - File testDir = new File(tmpdir + File.separator + getClass().getName()); - deleteRecursively(testDir); - - if (outRedirector.getHasReadData() || errRedirector.getHasReadData()) - throw new RuntimeException("Failed: No output should have been received from the process"); - - } else { // run the test. - File tmp = createTempDir(); - try { - File dir = new File(tmp, "dir!name"); - dir.mkdir(); - File testFile = copyResource(dir, "jar1.jar"); - - // Case 1: direct access - URL url = new URL("jar:" + testFile.toURL() + "!/res1.txt"); - JarURLConnection conn = (JarURLConnection) url.openConnection(); - JarFile file = conn.getJarFile(); - JarEntry entry = conn.getJarEntry(); - byte[] buffer = readFully(file.getInputStream(entry)); - String str = new String(buffer); - if (!str.equals("This is jar 1\n")) { - throw(new Exception("resource content invalid")); - } - - // Case 2: indirect access - URL[] urls = new URL[1]; - urls[0] = new URL("jar:" + testFile.toURL() + "!/"); - URLClassLoader loader = new URLClassLoader(urls); - loader.loadClass("jar1.GetResource").newInstance(); - } finally { - deleteRecursively(tmp); + // Case 1: direct access + URL url = new URL("jar:" + testFile.toURI().toURL() + "!/res1.txt"); + JarURLConnection conn = (JarURLConnection) url.openConnection(); + JarFile file = conn.getJarFile(); + JarEntry entry = conn.getJarEntry(); + byte[] buffer = readFully(file.getInputStream(entry)); + String str = new String(buffer); + if (!str.equals("This is jar 1\n")) { + throw (new Exception("resource content invalid")); } + + // Case 2: indirect access + URL[] urls = new URL[1]; + urls[0] = new URL("jar:" + testFile.toURI().toURL() + "!/"); + URLClassLoader loader = new URLClassLoader(urls); + loader.loadClass("jar1.GetResource").newInstance(); + } finally { + deleteRecursively(tmp); } } diff --git a/jdk/test/sun/net/www/protocol/jrt/OtherResourcesTest.java b/jdk/test/sun/net/www/protocol/jrt/OtherResourcesTest.java new file mode 100644 index 00000000000..00ec82282e0 --- /dev/null +++ b/jdk/test/sun/net/www/protocol/jrt/OtherResourcesTest.java @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import jdk.test.lib.JDKToolFinder; +import static jdk.test.lib.process.ProcessTools.executeCommand; + +/** + * @test + * @bug 8142968 + * @summary Access a jrt:/ resource in an observable module that is not in + * the boot layer and hence not known to the built-in class loaders. + * This test is intended to run with --limit-modules. + * @library /test/lib + * @build OtherResources OtherResourcesTest + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.process.* + * @run main OtherResourcesTest + */ +public class OtherResourcesTest { + public static void main(String[] args) throws Throwable { + String classes = System.getProperty("test.classes"); + executeCommand(JDKToolFinder.getTestJDKTool("java"), + "--limit-modules", "java.base", + "-cp", classes, "OtherResources") + .outputTo(System.out) + .errorTo(System.out) + .shouldHaveExitValue(0); + } +} + diff --git a/jdk/test/sun/net/www/protocol/jrt/other_resources.sh b/jdk/test/sun/net/www/protocol/jrt/other_resources.sh deleted file mode 100644 index 79903759092..00000000000 --- a/jdk/test/sun/net/www/protocol/jrt/other_resources.sh +++ /dev/null @@ -1,45 +0,0 @@ -# -# Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -# @test -# @build OtherResources -# @run shell other_resources.sh -# @summary Access a jrt:/ resource in an observable module that is not in -# the boot layer and hence not known to the built-in class loaders. This -# test is a shell test because the run tag doesn't support --limit-modules. - -set -e - -if [ -z "$TESTJAVA" ]; then - if [ $# -lt 1 ]; then exit 1; fi - TESTJAVA="$1"; shift - COMPILEJAVA="${TESTJAVA}" - TESTSRC="`pwd`" - TESTCLASSES="`pwd`" -fi - -JAVA="$TESTJAVA/bin/java ${TESTVMOPTS}" -$JAVA --limit-modules java.base -cp $TESTCLASSES OtherResources - -exit 0 - diff --git a/jdk/test/sun/nio/cs/FindDecoderBugs.java b/jdk/test/sun/nio/cs/FindDecoderBugs.java index f21d7c0de2f..175a22c4723 100644 --- a/jdk/test/sun/nio/cs/FindDecoderBugs.java +++ b/jdk/test/sun/nio/cs/FindDecoderBugs.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ * @test * @bug 6380723 * @summary Decode many byte sequences in many ways (use -Dseed=X to set PRNG seed) - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main/timeout=1800 FindDecoderBugs * @author Martin Buchholz * @key randomness @@ -36,7 +36,7 @@ import java.util.*; import java.util.regex.*; import java.nio.*; import java.nio.charset.*; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class FindDecoderBugs { diff --git a/jdk/test/sun/nio/cs/FindEncoderBugs.java b/jdk/test/sun/nio/cs/FindEncoderBugs.java index 78ef3029522..77bb3ba094d 100644 --- a/jdk/test/sun/nio/cs/FindEncoderBugs.java +++ b/jdk/test/sun/nio/cs/FindEncoderBugs.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,8 @@ * @test * @bug 6233345 6381699 6381702 6381705 6381706 * @summary Encode many char sequences in many ways - * @library /lib/testlibrary/ - * @build jdk.testlibrary.* + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @run main/timeout=1200 FindEncoderBugs * @author Martin Buchholz * @key randomness @@ -36,7 +36,7 @@ import java.util.*; import java.util.regex.*; import java.nio.*; import java.nio.charset.*; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class FindEncoderBugs { diff --git a/jdk/test/sun/security/ec/SignatureOffsets.java b/jdk/test/sun/security/ec/SignatureOffsets.java index efd931a6dcb..3570258c861 100644 --- a/jdk/test/sun/security/ec/SignatureOffsets.java +++ b/jdk/test/sun/security/ec/SignatureOffsets.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,7 +34,8 @@ import java.security.SignatureException; * get random set of clear text data to sign. After the signature * generation, the test tries to verify signature with the above API * and passing in different signature offset (0, 33, 66, 99). - * @library /lib/testlibrary + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @compile ../../../java/security/Signature/Offsets.java * @run main SignatureOffsets SunEC NONEwithECDSA * @run main SignatureOffsets SunEC SHA1withECDSA diff --git a/jdk/test/sun/security/krb5/auto/KDC.java b/jdk/test/sun/security/krb5/auto/KDC.java index e47c3e9e5c1..633d0d05f1e 100644 --- a/jdk/test/sun/security/krb5/auto/KDC.java +++ b/jdk/test/sun/security/krb5/auto/KDC.java @@ -828,7 +828,9 @@ public class KDC { throw new KrbException(Krb5.KDC_ERR_SUMTYPE_NOSUPP); // TODO } Ticket t = new Ticket( - service, + System.getProperty("test.kdc.diff.sname") != null ? + new PrincipalName("xx" + service.toString()) : + service, new EncryptedData(skey, enc.asn1Encode(), KeyUsage.KU_TICKET) ); EncTGSRepPart enc_part = new EncTGSRepPart( diff --git a/jdk/test/sun/security/krb5/auto/ModuleName.java b/jdk/test/sun/security/krb5/auto/ModuleName.java index 499d35ac3a1..fb59d33789b 100644 --- a/jdk/test/sun/security/krb5/auto/ModuleName.java +++ b/jdk/test/sun/security/krb5/auto/ModuleName.java @@ -27,6 +27,12 @@ * @summary GSSContext type when jdk.security.jgss is not available * @library /test/lib * @compile -XDignore.symbol.file ModuleName.java + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main/othervm ModuleName */ diff --git a/jdk/test/sun/security/krb5/auto/ReplayCacheTestProc.java b/jdk/test/sun/security/krb5/auto/ReplayCacheTestProc.java index d138d928289..6b14f144841 100644 --- a/jdk/test/sun/security/krb5/auto/ReplayCacheTestProc.java +++ b/jdk/test/sun/security/krb5/auto/ReplayCacheTestProc.java @@ -26,6 +26,7 @@ * @bug 7152176 8168518 8172017 * @summary More krb5 tests * @library ../../../../java/security/testlibrary/ /test/lib + * @build jdk.test.lib.Platform * @run main/othervm/timeout=300 ReplayCacheTestProc */ diff --git a/hotspot/test/gc/arguments/TestExplicitGCInvokesConcurrentAndUnloadsClasses.java b/jdk/test/sun/security/krb5/auto/TicketSName.java similarity index 51% rename from hotspot/test/gc/arguments/TestExplicitGCInvokesConcurrentAndUnloadsClasses.java rename to jdk/test/sun/security/krb5/auto/TicketSName.java index 83f075760d6..458d478af14 100644 --- a/hotspot/test/gc/arguments/TestExplicitGCInvokesConcurrentAndUnloadsClasses.java +++ b/jdk/test/sun/security/krb5/auto/TicketSName.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,27 +22,37 @@ */ /* - * @test TestExplicitGCInvokesConcurrentAndUnloadsClasses - * @summary Test that the flag ExplicitGCInvokesConcurrentAndUnloadsClasses is deprecated - * @bug 8170388 - * @key gc - * @library /test/lib - * @modules java.base/jdk.internal.misc - * java.management - * @run driver TestExplicitGCInvokesConcurrentAndUnloadsClasses + * @test + * @bug 8178794 + * @summary krb5 client should ignore sname in incoming tickets + * @compile -XDignore.symbol.file TicketSName.java + * @run main/othervm -Dtest.kdc.diff.sname TicketSName */ -import jdk.test.lib.process.OutputAnalyzer; -import jdk.test.lib.process.ProcessTools; +import sun.security.jgss.GSSUtil; +import javax.security.auth.kerberos.KerberosTicket; + +public class TicketSName { -public class TestExplicitGCInvokesConcurrentAndUnloadsClasses { public static void main(String[] args) throws Exception { - ProcessBuilder pb = - ProcessTools.createJavaProcessBuilder("-XX:+ExplicitGCInvokesConcurrentAndUnloadsClasses", - "-Xlog:gc", - "-version"); - OutputAnalyzer output = new OutputAnalyzer(pb.start()); - output.shouldContain("ExplicitGCInvokesConcurrentAndUnloadsClasses was deprecated"); - output.shouldHaveExitValue(0); + + new OneKDC(null).writeJAASConf(); + + Context c, s; + c = Context.fromJAAS("client"); + s = Context.fromJAAS("server"); + + c.startAsClient(OneKDC.SERVER, GSSUtil.GSS_KRB5_MECH_OID); + s.startAsServer(GSSUtil.GSS_KRB5_MECH_OID); + + Context.handshake(c, s); + + String expected = OneKDC.SERVER + "@" + OneKDC.REALM; + if (!c.s().getPrivateCredentials(KerberosTicket.class) + .stream() + .anyMatch(t -> t.getServer().toString().equals(expected))) { + c.status(); + throw new Exception("no " + expected); + } } } diff --git a/jdk/test/sun/security/krb5/auto/rcache_usemd5.sh b/jdk/test/sun/security/krb5/auto/rcache_usemd5.sh index 0d9a7d7a129..59907d5c7bd 100644 --- a/jdk/test/sun/security/krb5/auto/rcache_usemd5.sh +++ b/jdk/test/sun/security/krb5/auto/rcache_usemd5.sh @@ -24,6 +24,7 @@ # @test # @bug 8168518 # @library ../../../../java/security/testlibrary/ /test/lib +# @build jdk.test.lib.Platform # @run main/othervm/timeout=300 -Djdk.krb5.rcache.useMD5=true # -Dtest.service=host ReplayCacheTestProc # @summary testing jdk.krb5.rcache.useMD5. This action is put in a separate diff --git a/jdk/test/sun/security/krb5/config/Include.java b/jdk/test/sun/security/krb5/config/Include.java index b253b8132db..ee741c58fdb 100644 --- a/jdk/test/sun/security/krb5/config/Include.java +++ b/jdk/test/sun/security/krb5/config/Include.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8029994 + * @bug 8029994 8177085 * @summary Support "include" and "includedir" in krb5.conf * @modules java.security.jgss/sun.security.krb5 * @compile -XDignore.symbol.file Include.java @@ -35,6 +35,7 @@ import sun.security.krb5.KrbException; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; +import java.util.Arrays; public class Include { public static void main(String[] args) throws Exception { @@ -43,13 +44,15 @@ public class Include { Path conf = Paths.get("krb5.conf"); // base krb5.conf - Path ifile = Paths.get("f"); // include f - Path idir = Paths.get("x"); // includedir fx - Path idirdir = Paths.get("x/xx"); // sub dir, will be ignored - Path idirdirfile = Paths.get("x/xx/ff"); // sub dir, will be ignored - Path idirfile1 = Paths.get("x/f1"); // one file - Path idirfile2 = Paths.get("x/f2"); // another file - Path idirfile3 = Paths.get("x/f.3"); // third file bad name + Path f = Paths.get("f"); // include + Path f2 = Paths.get("f2"); // f include f2 + Path d = Paths.get("d"); // includedir + Path dd = Paths.get("d/dd"); // sub dir, ignore + Path ddf = Paths.get("d/dd/ddf"); // file in sub dir, ignore + Path df1 = Paths.get("d/f1"); // one file in dir + Path df2 = Paths.get("d/f2"); // another file + Path df3 = Paths.get("d/f.3"); // third file bad name + Path df4 = Paths.get("d/f4.conf"); // fourth file // OK: The base file can be missing System.setProperty("java.security.krb5.conf", "no-such-file"); @@ -59,8 +62,8 @@ public class Include { // Write base file Files.write(conf, - ("include " + ifile.toAbsolutePath() + "\n" + - "includedir " + idir.toAbsolutePath() + "\n" + + ("include " + f.toAbsolutePath() + "\n" + + "includedir " + d.toAbsolutePath() + "\n" + krb5Conf + "base").getBytes() ); @@ -68,54 +71,63 @@ public class Include { tryReload(false); // Error: Only includedir exists - Files.createDirectory(idir); + Files.createDirectory(d); tryReload(false); // Error: Both exists, but include is a cycle - Files.write(ifile, + Files.write(f, ("include " + conf.toAbsolutePath() + "\n" + - krb5Conf + "incfile").getBytes()); + krb5Conf + "f").getBytes()); tryReload(false); - // Error: A good include exists, but no includedir - Files.delete(idir); - Files.write(ifile, (krb5Conf + "incfile").getBytes()); + // Error: A good include exists, but no includedir yet + Files.delete(d); + Files.write(f, (krb5Conf + "f").getBytes()); tryReload(false); // OK: Everything is set - Files.createDirectory(idir); + Files.createDirectory(d); tryReload(true); // Now OK + // make f include f2 + Files.write(f, + ("include " + f2.toAbsolutePath() + "\n" + + krb5Conf + "f").getBytes()); + Files.write(f2, (krb5Conf + "f2").getBytes()); // fx1 and fx2 will be loaded - Files.write(idirfile1, (krb5Conf + "incdir1").getBytes()); - Files.write(idirfile2, (krb5Conf + "incdir2").getBytes()); + Files.write(df1, (krb5Conf + "df1").getBytes()); + Files.write(df2, (krb5Conf + "df2").getBytes()); // fx3 and fxs (and file inside it) will be ignored - Files.write(idirfile3, (krb5Conf + "incdir3").getBytes()); - Files.createDirectory(idirdir); - Files.write(idirdirfile, (krb5Conf + "incdirdir").getBytes()); + Files.write(df3, (krb5Conf + "df3").getBytes()); + Files.createDirectory(dd); + Files.write(ddf, (krb5Conf + "ddf").getBytes()); + // fx4 will be loaded + Files.write(df4, (krb5Conf + "df4").getBytes()); // OK: All good files read tryReload(true); - String v = Config.getInstance().getAll("section", "key"); - // The order of files in includedir could be either - if (!v.equals("incfile incdir1 incdir2 base") && - !v.equals("incfile incdir2 incdir1 base")) { - throw new Exception(v); + String[] v = Config.getInstance().getAll("section", "key") .split(" "); + // v will contain f2, f, df[124], and base. + // Order of df[124] is not determined. Sort them first. + Arrays.sort(v, 2, 5); + String longv = Arrays.toString(v); + if (!longv.equals("[f2, f, df1, df2, df4, base]")) { + throw new Exception(longv); } // Error: include file not absolute Files.write(conf, - ("include " + ifile + "\n" + - "includedir " + idir.toAbsolutePath() + "\n" + + ("include " + f + "\n" + + "includedir " + d.toAbsolutePath() + "\n" + krb5Conf + "base").getBytes() ); tryReload(false); // Error: includedir not absolute Files.write(conf, - ("include " + ifile.toAbsolutePath() + "\n" + - "includedir " + idir + "\n" + + ("include " + f.toAbsolutePath() + "\n" + + "includedir " + d + "\n" + krb5Conf + "base").getBytes() ); tryReload(false); diff --git a/jdk/test/sun/security/mscapi/KeyStoreEmptyCertChain.java b/jdk/test/sun/security/mscapi/KeyStoreEmptyCertChain.java new file mode 100644 index 00000000000..d603df9f1c8 --- /dev/null +++ b/jdk/test/sun/security/mscapi/KeyStoreEmptyCertChain.java @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8172244 + * @summary Verify that no exception is thrown with empty cert chain + * in MSCAPI. + * @requires os.family == "windows" + * @modules java.base/sun.security.tools.keytool java.base/sun.security.x509 + * @run main/othervm --add-opens java.base/java.security=ALL-UNNAMED + * KeyStoreEmptyCertChain + */ + +import java.security.KeyStore; +import java.security.cert.Certificate; +import sun.security.x509.X500Name; +import sun.security.tools.keytool.CertAndKeyGen; +import java.security.KeyPairGenerator; +import java.security.KeyPair; +import java.security.PrivateKey; +import java.security.KeyStoreSpi; +import java.lang.reflect.*; + +public class KeyStoreEmptyCertChain { + + public static void main(String[] args) { + + try { + + KeyStore keyStore = KeyStore.getInstance("Windows-MY", "SunMSCAPI"); + keyStore.load(null, null); + + // Generate a certificate to use for testing + CertAndKeyGen gen = new CertAndKeyGen("RSA", "SHA256withRSA"); + gen.generate(2048); + Certificate cert = + gen.getSelfCertificate(new X500Name("CN=test"), 3600); + String alias = "JDK-8172244"; + char[] password = "password".toCharArray(); + KeyPairGenerator kpg = KeyPairGenerator.getInstance("RSA"); + + // generate a private key for the certificate + kpg.initialize(2048); + KeyPair keyPair = kpg.generateKeyPair(); + PrivateKey privKey = keyPair.getPrivate(); + // need to bypass checks to store the private key without the cert + Field spiField = KeyStore.class.getDeclaredField("keyStoreSpi"); + spiField.setAccessible(true); + KeyStoreSpi spi = (KeyStoreSpi) spiField.get(keyStore); + spi.engineSetKeyEntry(alias, privKey, password, new Certificate[0]); + keyStore.store(null, null); + + keyStore.getCertificateAlias(cert); + keyStore.deleteEntry(alias); + // test passes if no exception is thrown + } catch (Exception ex) { + throw new RuntimeException(ex); + } + } +} diff --git a/jdk/test/sun/security/mscapi/SignatureOffsets.java b/jdk/test/sun/security/mscapi/SignatureOffsets.java index 128cc00ca04..bff9620dc74 100644 --- a/jdk/test/sun/security/mscapi/SignatureOffsets.java +++ b/jdk/test/sun/security/mscapi/SignatureOffsets.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,7 +34,8 @@ import java.security.SignatureException; * get random set of clear text data to sign. After the signature * generation, the test tries to verify signature with the above API * and passing in different signature offset (0, 33, 66, 99). - * @library /lib/testlibrary + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @compile ../../../java/security/Signature/Offsets.java * @requires os.family == "windows" * @run main SignatureOffsets SunMSCAPI NONEwithRSA diff --git a/jdk/test/sun/security/pkcs11/rsa/TestKeyPairGenerator.java b/jdk/test/sun/security/pkcs11/rsa/TestKeyPairGenerator.java index 78e305e1880..9662db995d2 100644 --- a/jdk/test/sun/security/pkcs11/rsa/TestKeyPairGenerator.java +++ b/jdk/test/sun/security/pkcs11/rsa/TestKeyPairGenerator.java @@ -27,9 +27,9 @@ * @summary Verify that the RSA KeyPairGenerator works (use -Dseed=X to set PRNG seed) * @author Andreas Sterbenz * @library .. - * @library /lib/testlibrary - * @build jdk.testlibrary.* + * @library /test/lib * @modules jdk.crypto.cryptoki + * @build jdk.test.lib.RandomFactory * @run main/othervm -Djava.security.debug=sunpkcs11 TestKeyPairGenerator * @run main/othervm -Djava.security.debug=sunpkcs11 TestKeyPairGenerator * sm TestKeyPairGenerator.policy @@ -46,7 +46,7 @@ import java.security.Signature; import java.security.interfaces.RSAPrivateCrtKey; import java.security.interfaces.RSAPublicKey; import java.security.spec.RSAKeyGenParameterSpec; -import jdk.testlibrary.RandomFactory; +import jdk.test.lib.RandomFactory; public class TestKeyPairGenerator extends PKCS11Test { diff --git a/jdk/test/sun/security/rsa/SignatureOffsets.java b/jdk/test/sun/security/rsa/SignatureOffsets.java index db9dbb03698..c8700225853 100644 --- a/jdk/test/sun/security/rsa/SignatureOffsets.java +++ b/jdk/test/sun/security/rsa/SignatureOffsets.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,7 +34,8 @@ import java.security.SignatureException; * get random set of clear text data to sign. After the signature * generation, the test tries to verify signature with the above API * and passing in different signature offset (0, 33, 66, 99). - * @library /lib/testlibrary + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @compile ../../../java/security/Signature/Offsets.java * @run main SignatureOffsets SunRsaSign MD2withRSA * @run main SignatureOffsets SunRsaSign MD5withRSA diff --git a/jdk/test/sun/security/ssl/CertPathRestrictions/TLSRestrictions.java b/jdk/test/sun/security/ssl/CertPathRestrictions/TLSRestrictions.java index 2a6ffb2d135..fad928f5503 100644 --- a/jdk/test/sun/security/ssl/CertPathRestrictions/TLSRestrictions.java +++ b/jdk/test/sun/security/ssl/CertPathRestrictions/TLSRestrictions.java @@ -48,8 +48,15 @@ import jdk.test.lib.process.ProcessTools; /* * @test + * @bug 8165367 * @summary Verify the restrictions for certificate path on JSSE with custom trust store. * @library /test/lib + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @compile JSSEClient.java * @run main/othervm -Djava.security.debug=certpath TLSRestrictions DEFAULT * @run main/othervm -Djava.security.debug=certpath TLSRestrictions C1 diff --git a/jdk/test/sun/security/ssl/DHKeyExchange/DHEKeySizing.java b/jdk/test/sun/security/ssl/DHKeyExchange/DHEKeySizing.java index 3b449315e17..c00337789f0 100644 --- a/jdk/test/sun/security/ssl/DHKeyExchange/DHEKeySizing.java +++ b/jdk/test/sun/security/ssl/DHKeyExchange/DHEKeySizing.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,33 +31,44 @@ * @bug 6956398 * @summary make ephemeral DH key match the length of the certificate key * @run main/othervm + * DHEKeySizing TLS_DHE_RSA_WITH_AES_128_CBC_SHA false 1639 267 + * @run main/othervm -Djsse.enableFFDHE=false * DHEKeySizing SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA true 1255 75 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=matched + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=matched * DHEKeySizing SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA true 1255 75 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=legacy + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=legacy * DHEKeySizing SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA true 1255 75 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=1024 + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=1024 * DHEKeySizing SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA true 1255 75 * - * @run main/othervm + * @run main/othervm -Djsse.enableFFDHE=false * DHEKeySizing SSL_DH_anon_EXPORT_WITH_DES40_CBC_SHA true 229 75 * - * @run main/othervm + * @run main/othervm -Djsse.enableFFDHE=false * DHEKeySizing TLS_DHE_RSA_WITH_AES_128_CBC_SHA false 1383 139 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=legacy + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=legacy * DHEKeySizing TLS_DHE_RSA_WITH_AES_128_CBC_SHA false 1319 107 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=matched + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=matched * DHEKeySizing TLS_DHE_RSA_WITH_AES_128_CBC_SHA false 1639 267 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=1024 + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=1024 * DHEKeySizing TLS_DHE_RSA_WITH_AES_128_CBC_SHA false 1383 139 * - * @run main/othervm + * @run main/othervm -Djsse.enableFFDHE=false * DHEKeySizing SSL_DH_anon_WITH_RC4_128_MD5 false 357 139 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=legacy + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=legacy * DHEKeySizing SSL_DH_anon_WITH_RC4_128_MD5 false 293 107 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=matched + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=matched * DHEKeySizing SSL_DH_anon_WITH_RC4_128_MD5 false 357 139 - * @run main/othervm -Djdk.tls.ephemeralDHKeySize=1024 + * @run main/othervm -Djsse.enableFFDHE=false + * -Djdk.tls.ephemeralDHKeySize=1024 * DHEKeySizing SSL_DH_anon_WITH_RC4_128_MD5 false 357 139 */ diff --git a/jdk/test/sun/security/ssl/DHKeyExchange/UseStrongDHSizes.java b/jdk/test/sun/security/ssl/DHKeyExchange/UseStrongDHSizes.java new file mode 100644 index 00000000000..209db9d7461 --- /dev/null +++ b/jdk/test/sun/security/ssl/DHKeyExchange/UseStrongDHSizes.java @@ -0,0 +1,112 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +// +// SunJSSE does not support dynamic system properties, no way to re-use +// system properties in samevm/agentvm mode. +// + +/* + * @test + * @bug 8140436 + * @modules jdk.crypto.ec + * @library /javax/net/ssl/templates + * @summary Negotiated Finite Field Diffie-Hellman Ephemeral Parameters for TLS + * @run main/othervm UseStrongDHSizes 2048 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe2048 UseStrongDHSizes 2048 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe3072 UseStrongDHSizes 2048 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe4096 UseStrongDHSizes 2048 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe6144 UseStrongDHSizes 2048 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe8192 UseStrongDHSizes 2048 + * @run main/othervm UseStrongDHSizes 3072 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe3072 UseStrongDHSizes 3072 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe4096 UseStrongDHSizes 3072 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe6144 UseStrongDHSizes 3072 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe8192 UseStrongDHSizes 3072 + * @run main/othervm UseStrongDHSizes 4096 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe4096 UseStrongDHSizes 4096 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe6144 UseStrongDHSizes 4096 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe8192 UseStrongDHSizes 4096 + * @run main/othervm UseStrongDHSizes 6144 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe6144 UseStrongDHSizes 6144 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe8192 UseStrongDHSizes 6144 + * @run main/othervm UseStrongDHSizes 8192 + * @run main/othervm -Djdk.tls.namedGroups=ffdhe8192 UseStrongDHSizes 8192 + */ + +import java.io.InputStream; +import java.io.OutputStream; +import java.security.Security; +import javax.net.ssl.SSLSocket; + +public class UseStrongDHSizes extends SSLSocketTemplate { + /* + * Run the test case. + */ + public static void main(String[] args) throws Exception { + // reset the security property to make sure that the algorithms + // and keys used in this test are not disabled unexpectedly. + String constraint = "DH keySize < " + Integer.valueOf(args[0]); + Security.setProperty("jdk.tls.disabledAlgorithms", constraint); + Security.setProperty("jdk.certpath.disabledAlgorithms", ""); + + (new UseStrongDHSizes()).run(); + } + + @Override + protected void runServerApplication(SSLSocket socket) throws Exception { + String ciphers[] = { + "TLS_DHE_RSA_WITH_AES_128_CBC_SHA", + "TLS_DHE_DSS_WITH_AES_128_CBC_SHA", + "SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA", + "SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA"}; + + socket.setEnabledCipherSuites(ciphers); + socket.setWantClientAuth(true); + + InputStream sslIS = socket.getInputStream(); + OutputStream sslOS = socket.getOutputStream(); + + sslIS.read(); + sslOS.write(85); + sslOS.flush(); + } + + @Override + protected void runClientApplication(SSLSocket socket) throws Exception { + String ciphers[] = { + "TLS_DHE_RSA_WITH_AES_128_CBC_SHA", + "TLS_DHE_DSS_WITH_AES_128_CBC_SHA", + "SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA", + "SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA"}; + socket.setEnabledCipherSuites(ciphers); + socket.setUseClientMode(true); + + InputStream sslIS = socket.getInputStream(); + OutputStream sslOS = socket.getOutputStream(); + + sslOS.write(280); + sslOS.flush(); + sslIS.read(); + } +} diff --git a/jdk/test/sun/security/ssl/rsa/SignatureOffsets.java b/jdk/test/sun/security/ssl/rsa/SignatureOffsets.java index 8b07950eee8..9f3110cae21 100644 --- a/jdk/test/sun/security/ssl/rsa/SignatureOffsets.java +++ b/jdk/test/sun/security/ssl/rsa/SignatureOffsets.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,7 +34,8 @@ import java.security.SignatureException; * get random set of clear text data to sign. After the signature * generation, the test tries to verify signature with the above API * and passing in different signature offset (0, 33, 66, 99). - * @library /lib/testlibrary + * @library /test/lib + * @build jdk.test.lib.RandomFactory * @compile ../../../../java/security/Signature/Offsets.java * @run main SignatureOffsets SunJSSE MD2withRSA * @run main SignatureOffsets SunJSSE MD5withRSA diff --git a/jdk/test/sun/security/tools/jarsigner/AltProvider.java b/jdk/test/sun/security/tools/jarsigner/AltProvider.java index 2717ef9e22e..e2c8e093042 100644 --- a/jdk/test/sun/security/tools/jarsigner/AltProvider.java +++ b/jdk/test/sun/security/tools/jarsigner/AltProvider.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,14 +25,24 @@ * @test * @bug 4906940 8130302 * @summary -providerPath, -providerClass, -addprovider, and -providerArg - * @library /lib/testlibrary /test/lib + * @library /test/lib * @modules java.base/jdk.internal.misc + * @build jdk.test.lib.util.JarUtils + * jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @run main AltProvider */ import jdk.test.lib.JDKToolLauncher; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; +import jdk.test.lib.compiler.CompilerUtils; import java.nio.file.*; diff --git a/jdk/test/sun/security/tools/jarsigner/EntriesOrder.java b/jdk/test/sun/security/tools/jarsigner/EntriesOrder.java index 1b804bb9505..91eada85dd8 100644 --- a/jdk/test/sun/security/tools/jarsigner/EntriesOrder.java +++ b/jdk/test/sun/security/tools/jarsigner/EntriesOrder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,11 +25,9 @@ * @test * @bug 8031572 * @summary jarsigner -verify exits with 0 when a jar file is not properly signed - * @library /lib/testlibrary * @modules java.base/sun.security.tools.keytool * jdk.jartool/sun.security.tools.jarsigner * jdk.jartool/sun.tools.jar - * @build jdk.testlibrary.IOUtils * @run main EntriesOrder */ @@ -45,8 +43,6 @@ import java.util.jar.JarInputStream; import java.util.zip.ZipEntry; import java.util.zip.ZipOutputStream; -import jdk.testlibrary.IOUtils; - public class EntriesOrder { public static void main(String[] args) throws Exception { @@ -114,7 +110,7 @@ public class EntriesOrder { Enumeration jes = jf.entries(); while (jes.hasMoreElements()) { JarEntry je = jes.nextElement(); - IOUtils.readFully(jf.getInputStream(je)); + jf.getInputStream(je).readAllBytes(); Certificate[] certs = je.getCertificates(); if (certs != null && certs.length > 0) { cc++; @@ -146,7 +142,7 @@ public class EntriesOrder { while (true) { JarEntry je = jis.getNextJarEntry(); if (je == null) break; - IOUtils.readFully(jis); + jis.readAllBytes(); Certificate[] certs = je.getCertificates(); if (certs != null && certs.length > 0) { cc++; diff --git a/jdk/test/sun/security/tools/jarsigner/Options.java b/jdk/test/sun/security/tools/jarsigner/Options.java index e70903d06e3..bf736e47cfa 100644 --- a/jdk/test/sun/security/tools/jarsigner/Options.java +++ b/jdk/test/sun/security/tools/jarsigner/Options.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,16 +26,18 @@ * @bug 8056174 * @summary Make sure the jarsigner tool still works after it's modified to * be based on JarSigner API - * @library /lib/testlibrary + * @library /test/lib * @modules java.base/sun.security.tools.keytool * jdk.jartool/sun.security.tools.jarsigner * java.base/sun.security.pkcs * java.base/sun.security.x509 + * @build jdk.test.lib.util.JarUtils + * @run main Options */ import com.sun.jarsigner.ContentSigner; import com.sun.jarsigner.ContentSignerParameters; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; import sun.security.pkcs.PKCS7; import java.io.ByteArrayInputStream; diff --git a/jdk/test/sun/security/tools/jarsigner/TimestampCheck.java b/jdk/test/sun/security/tools/jarsigner/TimestampCheck.java index 928bc5aa199..dac7d43923f 100644 --- a/jdk/test/sun/security/tools/jarsigner/TimestampCheck.java +++ b/jdk/test/sun/security/tools/jarsigner/TimestampCheck.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -45,7 +45,7 @@ import java.util.jar.JarFile; import jdk.test.lib.SecurityTools; import jdk.testlibrary.*; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; import sun.security.pkcs.ContentInfo; import sun.security.pkcs.PKCS7; import sun.security.pkcs.PKCS9Attribute; @@ -68,6 +68,14 @@ import sun.security.x509.X500Name; * java.base/sun.security.tools.keytool * @library /lib/testlibrary * @library /test/lib + * @build jdk.test.lib.util.JarUtils + * jdk.test.lib.SecurityTools + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main/timeout=600 TimestampCheck */ public class TimestampCheck { @@ -557,7 +565,7 @@ public class TimestampCheck { } static void prepare() throws Exception { - jdk.testlibrary.JarUtils.createJar("old.jar", "A"); + JarUtils.createJar("old.jar", "A"); Files.deleteIfExists(Paths.get("tsks")); keytool("-alias ca -genkeypair -ext bc -dname CN=CA"); keytool("-alias old -genkeypair -dname CN=old"); diff --git a/jdk/test/sun/security/tools/jarsigner/TsacertOptionTest.java b/jdk/test/sun/security/tools/jarsigner/TsacertOptionTest.java index cfe23932f3f..79d9f1ad267 100644 --- a/jdk/test/sun/security/tools/jarsigner/TsacertOptionTest.java +++ b/jdk/test/sun/security/tools/jarsigner/TsacertOptionTest.java @@ -22,7 +22,7 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test @@ -36,6 +36,7 @@ import jdk.testlibrary.JarUtils; * java.base/sun.security.util * java.base/sun.security.x509 * java.management + * @build jdk.test.lib.util.JarUtils * @run main TsacertOptionTest */ public class TsacertOptionTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/Warning.java b/jdk/test/sun/security/tools/jarsigner/Warning.java index 70233634e0b..a2dfd582f95 100644 --- a/jdk/test/sun/security/tools/jarsigner/Warning.java +++ b/jdk/test/sun/security/tools/jarsigner/Warning.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,7 +22,7 @@ */ import jdk.testlibrary.JDKToolLauncher; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; import jdk.testlibrary.OutputAnalyzer; import jdk.testlibrary.ProcessTools; @@ -34,7 +34,9 @@ import java.util.Arrays; * @test * @bug 8024302 8026037 8130132 * @summary warnings, errors and -strict - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib + * @build jdk.test.lib.util.JarUtils + * @run main Warning */ public class Warning { diff --git a/jdk/test/sun/security/tools/jarsigner/multiRelease/MVJarSigningTest.java b/jdk/test/sun/security/tools/jarsigner/multiRelease/MVJarSigningTest.java index 6afeb274a28..4097c02e6c2 100644 --- a/jdk/test/sun/security/tools/jarsigner/multiRelease/MVJarSigningTest.java +++ b/jdk/test/sun/security/tools/jarsigner/multiRelease/MVJarSigningTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,13 @@ * @bug 8047305 8075618 * @summary Tests jarsigner tool and JarSigner API work with multi-release JAR files. * @library /test/lib - * @library /lib/testlibrary + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main MVJarSigningTest */ @@ -59,6 +65,7 @@ import java.util.zip.ZipOutputStream; import jdk.test.lib.JDKToolFinder; import jdk.test.lib.JDKToolLauncher; import jdk.test.lib.Utils; +import jdk.test.lib.compiler.CompilerUtils; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; @@ -74,7 +81,8 @@ public class MVJarSigningTest { private static final String KEYPASS = "changeit"; private static final String SIGNED_JAR = "Signed.jar"; private static final String POLICY_FILE = "SignedJar.policy"; - private static final String VERSION_MESSAGE = "I am running on version 9"; + private static final String VERSION = "" + Runtime.version().major(); + private static final String VERSION_MESSAGE = "I am running on version " + VERSION; public static void main(String[] args) throws Throwable { // compile java files in jarContent directory diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/AliasNotInStoreTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/AliasNotInStoreTest.java index d4f0a8ef390..dc19edb3571 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/AliasNotInStoreTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/AliasNotInStoreTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,14 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for aliasNotInStore warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main AliasNotInStoreTest */ public class AliasNotInStoreTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/BadExtendedKeyUsageTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/BadExtendedKeyUsageTest.java index 503b9c066aa..a2a081bf655 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/BadExtendedKeyUsageTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/BadExtendedKeyUsageTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,14 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for badExtendedKeyUsage warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main BadExtendedKeyUsageTest */ public class BadExtendedKeyUsageTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/BadKeyUsageTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/BadKeyUsageTest.java index 9f7cc362320..7a1e243c31b 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/BadKeyUsageTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/BadKeyUsageTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,14 +22,15 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for badKeyUsage warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ * @ignore until 8026393 is fixed + * @build jdk.test.lib.util.JarUtils * @run main BadKeyUsageTest */ public class BadKeyUsageTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/BadNetscapeCertTypeTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/BadNetscapeCertTypeTest.java index f198bfa8b2c..1dd605caebc 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/BadNetscapeCertTypeTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/BadNetscapeCertTypeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,7 +22,7 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; import java.nio.file.Files; import java.nio.file.Paths; @@ -32,7 +32,8 @@ import java.util.Base64; * @test * @bug 8024302 8026037 * @summary Test for badNetscapeCertType warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main BadNetscapeCertTypeTest */ public class BadNetscapeCertTypeTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/ChainNotValidatedTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/ChainNotValidatedTest.java index ab5ef7c9ee7..d46bc065af0 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/ChainNotValidatedTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/ChainNotValidatedTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,13 +24,14 @@ import java.io.File; import jdk.testlibrary.OutputAnalyzer; import jdk.testlibrary.ProcessTools; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for chainNotValidated warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main ChainNotValidatedTest */ public class ChainNotValidatedTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/HasExpiredCertTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/HasExpiredCertTest.java index 2c987d79ea7..99595905b66 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/HasExpiredCertTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/HasExpiredCertTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,14 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for hasExpiredCert warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main HasExpiredCertTest */ public class HasExpiredCertTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/HasExpiringCertTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/HasExpiringCertTest.java index a1d8bbe00e6..a991ebcba89 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/HasExpiringCertTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/HasExpiringCertTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,14 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for hasExpiringCert warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main HasExpiringCertTest */ public class HasExpiringCertTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/HasUnsignedEntryTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/HasUnsignedEntryTest.java index 5dbb63ac986..17653478891 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/HasUnsignedEntryTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/HasUnsignedEntryTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,14 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for hasUnsignedEntry warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main HasUnsignedEntryTest */ public class HasUnsignedEntryTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/MultipleWarningsTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/MultipleWarningsTest.java index c539ba4a6d6..07aa895ab3a 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/MultipleWarningsTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/MultipleWarningsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,14 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Checks if jarsigner prints appropriate warnings - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main MultipleWarningsTest */ public class MultipleWarningsTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/NoTimestampTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/NoTimestampTest.java index f69118c807c..ac506f42bb1 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/NoTimestampTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/NoTimestampTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,13 +23,14 @@ import java.util.Date; import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Checks warnings if -tsa and -tsacert options are not specified - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main NoTimestampTest */ public class NoTimestampTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/NotSignedByAliasTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/NotSignedByAliasTest.java index f309cf5233e..d4e8982f2f7 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/NotSignedByAliasTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/NotSignedByAliasTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,14 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for notSignedByAlias warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main NotSignedByAliasTest */ public class NotSignedByAliasTest extends Test { diff --git a/jdk/test/sun/security/tools/jarsigner/warnings/NotYetValidCertTest.java b/jdk/test/sun/security/tools/jarsigner/warnings/NotYetValidCertTest.java index 235170e14cd..937082c16a9 100644 --- a/jdk/test/sun/security/tools/jarsigner/warnings/NotYetValidCertTest.java +++ b/jdk/test/sun/security/tools/jarsigner/warnings/NotYetValidCertTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,13 +22,14 @@ */ import jdk.testlibrary.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; /** * @test * @bug 8024302 8026037 * @summary Test for notYetValidCert warning - * @library /lib/testlibrary ../ + * @library /lib/testlibrary /test/lib ../ + * @build jdk.test.lib.util.JarUtils * @run main NotYetValidCertTest */ public class NotYetValidCertTest extends Test { diff --git a/jdk/test/sun/security/tools/keytool/ImportPrompt.java b/jdk/test/sun/security/tools/keytool/ImportPrompt.java index 50bd690371e..ab61b04b93d 100644 --- a/jdk/test/sun/security/tools/keytool/ImportPrompt.java +++ b/jdk/test/sun/security/tools/keytool/ImportPrompt.java @@ -33,6 +33,14 @@ import java.security.KeyStore; * @bug 8172975 * @summary SecurityTools.keytool() needs to accept user input * @library /test/lib + * @build jdk.test.lib.SecurityTools + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @run main ImportPrompt */ public class ImportPrompt { diff --git a/jdk/test/sun/security/tools/keytool/PrintSSL.java b/jdk/test/sun/security/tools/keytool/PrintSSL.java index 2f4a4ff8b59..ea9c6147af3 100644 --- a/jdk/test/sun/security/tools/keytool/PrintSSL.java +++ b/jdk/test/sun/security/tools/keytool/PrintSSL.java @@ -26,6 +26,13 @@ * @bug 6480981 8160624 * @summary keytool should be able to import certificates from remote SSL server * @library /test/lib + * @build jdk.test.lib.SecurityTools + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main/othervm PrintSSL */ diff --git a/jdk/test/sun/security/tools/keytool/ReadJar.java b/jdk/test/sun/security/tools/keytool/ReadJar.java index 644033cc1fa..464936cfc07 100644 --- a/jdk/test/sun/security/tools/keytool/ReadJar.java +++ b/jdk/test/sun/security/tools/keytool/ReadJar.java @@ -26,14 +26,22 @@ * @bug 6890872 8168882 * @summary keytool -printcert to recognize signed jar files * @library /test/lib - * @library /lib/testlibrary + * @build jdk.test.lib.SecurityTools + * jdk.test.lib.util.JarUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * @run main ReadJar */ import java.nio.file.Files; import java.nio.file.Paths; import jdk.test.lib.SecurityTools; import jdk.test.lib.process.OutputAnalyzer; -import jdk.testlibrary.JarUtils; +import jdk.test.lib.util.JarUtils; public class ReadJar { diff --git a/jdk/test/sun/security/tools/keytool/WeakAlg.java b/jdk/test/sun/security/tools/keytool/WeakAlg.java index bb7ae777371..d570a79e800 100644 --- a/jdk/test/sun/security/tools/keytool/WeakAlg.java +++ b/jdk/test/sun/security/tools/keytool/WeakAlg.java @@ -30,6 +30,13 @@ * @modules java.base/sun.security.tools.keytool * java.base/sun.security.tools * java.base/sun.security.util + * @build jdk.test.lib.SecurityTools + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run main/othervm/timeout=600 -Duser.language=en -Duser.country=US WeakAlg */ diff --git a/jdk/test/sun/security/util/DerInputBuffer/TimeParsing.java b/jdk/test/sun/security/util/DerInputBuffer/TimeParsing.java index f49701a438c..e387f26d88e 100644 --- a/jdk/test/sun/security/util/DerInputBuffer/TimeParsing.java +++ b/jdk/test/sun/security/util/DerInputBuffer/TimeParsing.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2003, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 4558835 4915146 + * @bug 4558835 4915146 8181841 * @summary Verify timezone offset and fractional seconds are correctly parsed * @modules java.base/sun.security.util */ @@ -77,6 +77,10 @@ public class TimeParsing { private final static byte[] GEN_FRACT3_ZULU = {0x18, 0x13, 0x32, 0x30, 0x30, 0x31, 0x30, 0x38, 0x31, 0x30, 0x31, 0x37, 0x34, 0x33, 0x35, 0x31, 0x2e, 0x37, 0x36, 0x35, 0x5a}; + // 20010810174351.7654Z + private final static byte[] GEN_FRACT4_ZULU = + {0x18, 0x14, 0x32, 0x30, 0x30, 0x31, 0x30, 0x38, 0x31, 0x30, 0x31, 0x37, 0x34, 0x33, 0x35, 0x31, 0x2e, 0x37, 0x36, 0x35, 0x34, 0x5a}; + // 20010810184351.7+0100 private final static byte[] GEN_FRACT1_PLUS1 = {0x18, 0x15, 0x32, 0x30, 0x30, 0x31, 0x30, 0x38, 0x31, 0x30, 0x31, 0x38, 0x34, 0x33, 0x35, 0x31, 0x2e, 0x37, 0x2b, 0x30, 0x31, 0x30, 0x30}; @@ -89,10 +93,17 @@ public class TimeParsing { private final static byte[] GEN_FRACT3_PLUS1 = {0x18, 0x17, 0x32, 0x30, 0x30, 0x31, 0x30, 0x38, 0x31, 0x30, 0x31, 0x38, 0x34, 0x33, 0x35, 0x31, 0x2e, 0x37, 0x36, 0x35, 0x2b, 0x30, 0x31, 0x30, 0x30}; + // 20010810184351.7654+0100 + private final static byte[] GEN_FRACT4_PLUS1 = + {0x18, 0x18, 0x32, 0x30, 0x30, 0x31, 0x30, 0x38, 0x31, 0x30, 0x31, 0x38, 0x34, 0x33, 0x35, 0x31, 0x2e, 0x37, 0x36, 0x35, 0x34, 0x2b, 0x30, 0x31, 0x30, 0x30}; + // 20010810184351,765+0100 private final static byte[] GEN_FRACT3_COMMA_PLUS1 = {0x18, 0x17, 0x32, 0x30, 0x30, 0x31, 0x30, 0x38, 0x31, 0x30, 0x31, 0x38, 0x34, 0x33, 0x35, 0x31, 0x2c, 0x37, 0x36, 0x35, 0x2b, 0x30, 0x31, 0x30, 0x30}; + // 20010810184351,7654+0100 + private final static byte[] GEN_FRACT4_COMMA_PLUS1 = + {0x18, 0x18, 0x32, 0x30, 0x30, 0x31, 0x30, 0x38, 0x31, 0x30, 0x31, 0x38, 0x34, 0x33, 0x35, 0x31, 0x2c, 0x37, 0x36, 0x35, 0x34, 0x2b, 0x30, 0x31, 0x30, 0x30}; private static Date decodeUTC(byte[] b) throws IOException { DerInputStream derin = new DerInputStream(b); @@ -146,6 +157,8 @@ public class TimeParsing { checkGeneralized(d3, GEN_FRACT3_ZULU, "fractional seconds (Zulu)"); checkGeneralized(d3, GEN_FRACT3_PLUS1, "fractional seconds (+0100)"); checkGeneralized(d3, GEN_FRACT3_COMMA_PLUS1, "fractional seconds (+0100)"); + checkGeneralized(d3, GEN_FRACT4_ZULU, "fractional seconds (Zulu)"); + checkGeneralized(d3, GEN_FRACT4_PLUS1, "fractional seconds (+0100)"); + checkGeneralized(d3, GEN_FRACT4_COMMA_PLUS1, "fractional seconds (+0100)"); } - } diff --git a/jdk/test/sun/text/resources/LocaleData.cldr b/jdk/test/sun/text/resources/LocaleData.cldr index fbc696101d8..4b348430e19 100644 --- a/jdk/test/sun/text/resources/LocaleData.cldr +++ b/jdk/test/sun/text/resources/LocaleData.cldr @@ -8274,3 +8274,29 @@ FormatData/fi/DatePatterns/3=d.M.y # bug #8075173 FormatData/de/standalone.MonthAbbreviations/2=M\u00e4r + +# bug #8178872 +FormatData/pt_PT/latn.NumberElements/0=, +FormatData/pt_PT/latn.NumberElements/1=\u00a0 +FormatData/pt_AO/latn.NumberElements/0=, +FormatData/pt_AO/latn.NumberElements/1=\u00a0 +FormatData/pt_CH/latn.NumberElements/0=, +FormatData/pt_CH/latn.NumberElements/1=\u00a0 +FormatData/pt_CV/latn.NumberElements/0=, +FormatData/pt_CV/latn.NumberElements/1=\u00a0 +FormatData/pt_GQ/latn.NumberElements/0=, +FormatData/pt_GQ/latn.NumberElements/1=\u00a0 +FormatData/pt_MO/latn.NumberElements/0=, +FormatData/pt_MO/latn.NumberElements/1=\u00a0 +FormatData/pt_LU/latn.NumberElements/0=, +FormatData/pt_LU/latn.NumberElements/1=\u00a0 +FormatData/pt_MZ/latn.NumberElements/0=, +FormatData/pt_MZ/latn.NumberElements/1=\u00a0 +FormatData/pt_ST/latn.NumberElements/0=, +FormatData/pt_ST/latn.NumberElements/1=\u00a0 +FormatData/pt_TL/latn.NumberElements/0=, +FormatData/pt_TL/latn.NumberElements/1=\u00a0 +FormatData/kea/latn.NumberElements/0=, +FormatData/kea/latn.NumberElements/1=\u00a0 +FormatData/kea_CV/latn.NumberElements/0=, +FormatData/kea_CV/latn.NumberElements/1=\u00a0 diff --git a/jdk/test/sun/text/resources/LocaleDataTest.java b/jdk/test/sun/text/resources/LocaleDataTest.java index 690d9a2509b..3c900e318f8 100644 --- a/jdk/test/sun/text/resources/LocaleDataTest.java +++ b/jdk/test/sun/text/resources/LocaleDataTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,7 +37,7 @@ * 7003124 7085757 7028073 7171028 7189611 8000983 7195759 8004489 8006509 * 7114053 7074882 7040556 8008577 8013836 8021121 6192407 6931564 8027695 * 8017142 8037343 8055222 8042126 8074791 8075173 8080774 8129361 8134916 - * 8145136 8145952 8164784 8037111 8081643 7037368 + * 8145136 8145952 8164784 8037111 8081643 7037368 8178872 * @summary Verify locale data * @modules java.base/sun.util.resources * @modules jdk.localedata @@ -99,8 +99,15 @@ * LocaleNames/fr_FR/US=\u00c9tats-Unis * LocaleNames/fr_FR/FR=France * - * You can use language tag with '-' in locale field like this:

    - *        LocaleNames/sr-Latn/SR=Surinam
    + *    Second field which designates locale is in the form of:
    + *    1) Legacy locale notation using '_' as a locale component(language/country/variant) separator.
    + *    language is a mandatory component. country and variant are optional, however,
    + *    variant cannot exist without country. So for example, while "ja"/"ja_JP"/"ja_JP_JP" are valid,
    + *    "_JP"/"ja__JP" are invalid.
    + *
    + *    2) BCP47 language tag notation in which we can specify language tag with '-' as a subtag
    + *       separator. Language tag can be specified with '-' in locale field like this:
    + *       
    LocaleNames/sr-Latn/SR=Surinam
      *        FormatData/sr-Latn-BA/DayNames/2=utorak
    * * The command-line syntax of this test is @@ -276,16 +283,25 @@ public class LocaleDataTest throw new Exception("Malformed input file: \"" + key + "\" is missing locale name"); localeName = key.substring(oldIndex, index); boolean use_tag = localeName.indexOf("-") != -1; - if (use_tag == false && localeName.length() > 0) { - language = localeName.substring(0, 2); - if (localeName.length() > 3) { - country = localeName.substring(3, 5); - if (localeName.length() > 5) - variant = localeName.substring(6); + String[] locDetails = localeName.split("_"); + switch (locDetails.length) { + case 1: + language = locDetails[0]; + break; + case 2: + language = locDetails[0]; + country = locDetails[1]; + break; + case 3: + language = locDetails[0]; + country = locDetails[1]; + variant = locDetails[2]; + break; + default: + throw new Exception("locale not specified properly " + locDetails); } } - oldIndex = index + 1; index = key.indexOf("/", oldIndex); if (index == -1) diff --git a/jdk/test/sun/tools/jhsdb/AlternateHashingTest.java b/jdk/test/sun/tools/jhsdb/AlternateHashingTest.java new file mode 100644 index 00000000000..8333c669937 --- /dev/null +++ b/jdk/test/sun/tools/jhsdb/AlternateHashingTest.java @@ -0,0 +1,128 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8030750 + * @summary Test alternate hashing of strings in Serviceability Agent. + * @library /test/lib + * @library /lib/testlibrary + * @compile AlternateHashingTest.java + * @run main/timeout=240 AlternateHashingTest + */ + +import java.io.BufferedReader; +import java.io.OutputStream; +import java.io.InputStreamReader; +import java.io.IOException; +import java.util.Arrays; +import jdk.testlibrary.JDKToolLauncher; +import jdk.test.lib.apps.LingeredApp; +import jdk.test.lib.Platform; + +public class AlternateHashingTest { + + private static LingeredAppWithAltHashing theApp = null; + + /** + * + * @param vmArgs - tool arguments to launch jhsdb + * @return exit code of tool + */ + public static void launch(String expectedMessage, String cmd) throws IOException { + + System.out.println("Starting LingeredApp"); + try { + theApp = new LingeredAppWithAltHashing(); + LingeredApp.startApp(Arrays.asList("-Xmx256m"), theApp); + + System.out.println("Starting clhsdb against " + theApp.getPid()); + JDKToolLauncher launcher = JDKToolLauncher.createUsingTestJDK("jhsdb"); + launcher.addToolArg("clhsdb"); + launcher.addToolArg("--pid=" + Long.toString(theApp.getPid())); + + ProcessBuilder processBuilder = new ProcessBuilder(launcher.getCommand()); + processBuilder.redirectError(ProcessBuilder.Redirect.INHERIT); + Process toolProcess = processBuilder.start(); + + try (OutputStream out = toolProcess.getOutputStream()) { + out.write(cmd.getBytes()); + out.write("quit\n".getBytes()); + } + + boolean result = false; + try (BufferedReader reader = + new BufferedReader(new InputStreamReader(toolProcess.getInputStream()))) { + String line; + + while ((line = reader.readLine()) != null) { + line = line.trim(); + System.out.println(line); + + if (line.contains(expectedMessage)) { + result = true; + break; + } + } + } + + toolProcess.waitFor(); + + if (toolProcess.exitValue() != 0) { + throw new RuntimeException("FAILED CLHSDB terminated with non-zero exit code " + toolProcess.exitValue()); + } + + if (!result) { + throw new RuntimeException(cmd + " command output is missing the message " + expectedMessage); + } + + } catch (Exception ex) { + throw new RuntimeException("Test ERROR " + ex, ex); + } finally { + LingeredApp.stopApp(theApp); + } + } + + + public static void testAltHashing() throws IOException { + + launch("Stack in use by Java", "threads\n"); + } + + public static void main(String[] args) throws Exception { + + if (!Platform.shouldSAAttach()) { + // Silently skip the test if we don't have enough permissions to attach + System.err.println("Error! Insufficient permissions to attach - test skipped."); + return; + } + + + testAltHashing(); + + // The test throws RuntimeException on error. + // IOException is thrown if LingeredApp can't start because of some bad + // environment condition + System.out.println("Test PASSED"); + } +} diff --git a/jdk/test/sun/tools/jhsdb/HeapDumpTest.java b/jdk/test/sun/tools/jhsdb/HeapDumpTest.java index bc1d6553885..a36179eaaec 100644 --- a/jdk/test/sun/tools/jhsdb/HeapDumpTest.java +++ b/jdk/test/sun/tools/jhsdb/HeapDumpTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,6 +42,7 @@ import jdk.testlibrary.OutputAnalyzer; import jdk.testlibrary.ProcessTools; import jdk.test.lib.apps.LingeredApp; import jdk.test.lib.Platform; +import jdk.test.lib.hprof.parser.HprofReader; public class HeapDumpTest { @@ -93,6 +94,17 @@ public class HeapDumpTest { launch(expectedMessage, Arrays.asList(toolArgs)); } + public static void printStackTraces(String file) throws IOException { + try { + String output = HprofReader.getStack(file, 0); + if (!output.contains("LingeredAppWithExtendedChars.main")) { + throw new RuntimeException("'LingeredAppWithExtendedChars.main' missing from stdout/stderr"); + } + } catch (Exception ex) { + throw new RuntimeException("Test ERROR " + ex, ex); + } + } + public static void testHeapDump() throws IOException { File dump = new File("jhsdb.jmap.heap." + System.currentTimeMillis() + ".hprof"); @@ -106,6 +118,8 @@ public class HeapDumpTest { assertTrue(dump.exists() && dump.isFile(), "Could not create dump file " + dump.getAbsolutePath()); + printStackTraces(dump.getAbsolutePath()); + dump.delete(); } diff --git a/jdk/test/sun/tools/jhsdb/LingeredAppWithAltHashing.java b/jdk/test/sun/tools/jhsdb/LingeredAppWithAltHashing.java new file mode 100644 index 00000000000..492cb84c708 --- /dev/null +++ b/jdk/test/sun/tools/jhsdb/LingeredAppWithAltHashing.java @@ -0,0 +1,161 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +import jdk.test.lib.apps.LingeredApp; + +public class LingeredAppWithAltHashing extends LingeredApp { + + public static void main(String args[]) { + LingeredApp.main(args); + } + + // Following strings generate the same hashcode + + static final String str1 = "AaAaAaAaAaAaAa"; + static final String str2 = "AaAaAaAaAaAaBB"; + static final String str3 = "AaAaAaAaAaBBAa"; + static final String str4 = "AaAaAaAaAaBBBB"; + static final String str5 = "AaAaAaAaBBAaAa"; + static final String str6 = "AaAaAaAaBBAaBB"; + static final String str7 = "AaAaAaAaBBBBAa"; + static final String str8 = "AaAaAaAaBBBBBB"; + static final String str9 = "AaAaAaBBAaAaAa"; + static final String str10 = "AaAaAaBBAaAaBB"; + static final String str11 = "AaAaAaBBAaBBAa"; + static final String str12 = "AaAaAaBBAaBBBB"; + static final String str13 = "AaAaAaBBBBAaAa"; + static final String str14 = "AaAaAaBBBBAaBB"; + static final String str15 = "AaAaAaBBBBBBAa"; + static final String str16 = "AaAaAaBBBBBBBB"; + static final String str17 = "AaAaBBAaAaAaAa"; + static final String str18 = "AaAaBBAaAaAaBB"; + static final String str19 = "AaAaBBAaAaBBAa"; + static final String str20 = "AaAaBBAaAaBBBB"; + static final String str21 = "AaAaBBAaBBAaAa"; + static final String str22 = "AaAaBBAaBBAaBB"; + static final String str23 = "AaAaBBAaBBBBAa"; + static final String str24 = "AaAaBBAaBBBBBB"; + static final String str25 = "AaAaBBBBAaAaAa"; + static final String str26 = "AaAaBBBBAaAaBB"; + static final String str27 = "AaAaBBBBAaBBAa"; + static final String str28 = "AaAaBBBBAaBBBB"; + static final String str29 = "AaAaBBBBBBAaAa"; + static final String str30 = "AaAaBBBBBBAaBB"; + static final String str31 = "AaAaBBBBBBBBAa"; + static final String str32 = "AaAaBBBBBBBBBB"; + static final String str33 = "AaBBAaAaAaAaAa"; + static final String str34 = "AaBBAaAaAaAaBB"; + static final String str35 = "AaBBAaAaAaBBAa"; + static final String str36 = "AaBBAaAaAaBBBB"; + static final String str37 = "AaBBAaAaBBAaAa"; + static final String str38 = "AaBBAaAaBBAaBB"; + static final String str39 = "AaBBAaAaBBBBAa"; + static final String str40 = "AaBBAaAaBBBBBB"; + static final String str41 = "AaBBAaBBAaAaAa"; + static final String str42 = "AaBBAaBBAaAaBB"; + static final String str43 = "AaBBAaBBAaBBAa"; + static final String str44 = "AaBBAaBBAaBBBB"; + static final String str45 = "AaBBAaBBBBAaAa"; + static final String str46 = "AaBBAaBBBBAaBB"; + static final String str47 = "AaBBAaBBBBBBAa"; + static final String str48 = "AaBBAaBBBBBBBB"; + static final String str49 = "AaBBBBAaAaAaAa"; + static final String str50 = "AaBBBBAaAaAaBB"; + static final String str51 = "AaBBBBAaAaBBAa"; + static final String str52 = "AaBBBBAaAaBBBB"; + static final String str53 = "AaBBBBAaBBAaAa"; + static final String str54 = "AaBBBBAaBBAaBB"; + static final String str55 = "AaBBBBAaBBBBAa"; + static final String str56 = "AaBBBBAaBBBBBB"; + static final String str57 = "AaBBBBBBAaAaAa"; + static final String str58 = "AaBBBBBBAaAaBB"; + static final String str59 = "AaBBBBBBAaBBAa"; + static final String str60 = "AaBBBBBBAaBBBB"; + static final String str61 = "AaBBBBBBBBAaAa"; + static final String str62 = "AaBBBBBBBBAaBB"; + static final String str63 = "AaBBBBBBBBBBAa"; + static final String str64 = "AaBBBBBBBBBBBB"; + static final String str65 = "BBAaAaAaAaAaAa"; + static final String str66 = "BBAaAaAaAaAaBB"; + static final String str67 = "BBAaAaAaAaBBAa"; + static final String str68 = "BBAaAaAaAaBBBB"; + static final String str69 = "BBAaAaAaBBAaAa"; + static final String str70 = "BBAaAaAaBBAaBB"; + static final String str71 = "BBAaAaAaBBBBAa"; + static final String str72 = "BBAaAaAaBBBBBB"; + static final String str73 = "BBAaAaBBAaAaAa"; + static final String str74 = "BBAaAaBBAaAaBB"; + static final String str75 = "BBAaAaBBAaBBAa"; + static final String str76 = "BBAaAaBBAaBBBB"; + static final String str77 = "BBAaAaBBBBAaAa"; + static final String str78 = "BBAaAaBBBBAaBB"; + static final String str79 = "BBAaAaBBBBBBAa"; + static final String str80 = "BBAaAaBBBBBBBB"; + static final String str81 = "BBAaBBAaAaAaAa"; + static final String str82 = "BBAaBBAaAaAaBB"; + static final String str83 = "BBAaBBAaAaBBAa"; + static final String str84 = "BBAaBBAaAaBBBB"; + static final String str85 = "BBAaBBAaBBAaAa"; + static final String str86 = "BBAaBBAaBBAaBB"; + static final String str87 = "BBAaBBAaBBBBAa"; + static final String str88 = "BBAaBBAaBBBBBB"; + static final String str89 = "BBAaBBBBAaAaAa"; + static final String str90 = "BBAaBBBBAaAaBB"; + static final String str91 = "BBAaBBBBAaBBAa"; + static final String str92 = "BBAaBBBBAaBBBB"; + static final String str93 = "BBAaBBBBBBAaAa"; + static final String str94 = "BBAaBBBBBBAaBB"; + static final String str95 = "BBAaBBBBBBBBAa"; + static final String str96 = "BBAaBBBBBBBBBB"; + static final String str97 = "BBBBAaAaAaAaAa"; + static final String str98 = "BBBBAaAaAaAaBB"; + static final String str99 = "BBBBAaAaAaBBAa"; + static final String str100 = "BBBBAaAaAaBBBB"; + static final String str101 = "BBBBAaAaBBAaAa"; + static final String str102 = "BBBBAaAaBBAaBB"; + static final String str103 = "BBBBAaAaBBBBAa"; + static final String str104 = "BBBBAaAaBBBBBB"; + static final String str105 = "BBBBAaBBAaAaAa"; + static final String str106 = "BBBBAaBBAaAaBB"; + static final String str107 = "BBBBAaBBAaBBAa"; + static final String str108 = "BBBBAaBBAaBBBB"; + static final String str109 = "BBBBAaBBBBAaAa"; + static final String str110 = "BBBBAaBBBBAaBB"; + static final String str111 = "BBBBAaBBBBBBAa"; + static final String str112 = "BBBBAaBBBBBBBB"; + static final String str113 = "BBBBBBAaAaAaAa"; + static final String str114 = "BBBBBBAaAaAaBB"; + static final String str115 = "BBBBBBAaAaBBAa"; + static final String str116 = "BBBBBBAaAaBBBB"; + static final String str117 = "BBBBBBAaBBAaAa"; + static final String str118 = "BBBBBBAaBBAaBB"; + static final String str119 = "BBBBBBAaBBBBAa"; + static final String str120 = "BBBBBBAaBBBBBB"; + static final String str121 = "BBBBBBBBAaAaAa"; + static final String str122 = "BBBBBBBBAaAaBB"; + static final String str123 = "BBBBBBBBAaBBAa"; + static final String str124 = "BBBBBBBBAaBBBB"; + static final String str125 = "BBBBBBBBBBAaAa"; + static final String str126 = "BBBBBBBBBBAaBB"; + static final String str127 = "BBBBBBBBBBBBAa"; + static final String str128 = "BBBBBBBBBBBBBB"; + } diff --git a/jdk/test/sun/util/calendar/Bug8176160.java b/jdk/test/sun/util/calendar/Bug8176160.java new file mode 100644 index 00000000000..611cb236dca --- /dev/null +++ b/jdk/test/sun/util/calendar/Bug8176160.java @@ -0,0 +1,55 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + *@test + *@bug 8176160 + *@summary Make sure CalendarSystem.getEra(name) is consistent with getEras() + *@modules java.base/sun.util.calendar + *@run main/othervm Bug8176160 + */ + +import java.util.Arrays; +import java.util.List; +import sun.util.calendar.CalendarSystem; +import sun.util.calendar.Era; + +public class Bug8176160 { + + public static void main(String[] args) throws Exception { + List.of("gregorian", "japanese", "julian").stream() + .map(CalendarSystem::forName) + .forEach(cal -> { + Era[] eras = cal.getEras(); + if (eras != null) { + Arrays.stream(eras) + .forEach(era -> { + System.out.printf("cal: %s, era: %s\n", cal, era); + if (cal.getEra(era.getName()) != era) { + throw new RuntimeException("no match"); + } + }); + } + }); + } +} diff --git a/jdk/test/tools/jar/InputFilesTest.java b/jdk/test/tools/jar/InputFilesTest.java index 280cad57a58..3dc08293a76 100644 --- a/jdk/test/tools/jar/InputFilesTest.java +++ b/jdk/test/tools/jar/InputFilesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,9 +28,10 @@ * options with/without a --release option. Some input files are * duplicates that sometimes cause exceptions and other times do not, * demonstrating identical behavior to JDK 8 jar tool. - * @library /lib/testlibrary + * @library /test/lib * @modules jdk.jartool - * @build jdk.testlibrary.FileUtils + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @run testng InputFilesTest */ @@ -51,7 +52,7 @@ import java.util.spi.ToolProvider; import java.util.stream.Stream; import java.util.zip.ZipException; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; public class InputFilesTest { private static final ToolProvider JAR_TOOL = ToolProvider.findFirst("jar") diff --git a/jdk/test/tools/jar/ReleaseBeforeFiles.java b/jdk/test/tools/jar/ReleaseBeforeFiles.java index 56c27107a1b..4aaa8df7aa4 100644 --- a/jdk/test/tools/jar/ReleaseBeforeFiles.java +++ b/jdk/test/tools/jar/ReleaseBeforeFiles.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,9 +27,10 @@ * @summary test that both old style command line options and new gnu style * command line options work with the --release option whether or * not the --release option is preceded by a file name. - * @library /lib/testlibrary + * @library /test/lib * @modules jdk.jartool/sun.tools.jar - * @build jdk.testlibrary.FileUtils + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @run testng ReleaseBeforeFiles */ @@ -46,7 +47,7 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; public class ReleaseBeforeFiles { private Runnable onCompletion; diff --git a/jdk/test/tools/jar/compat/CLICompatibility.java b/jdk/test/tools/jar/compat/CLICompatibility.java index c31762eedc3..e32287d5690 100644 --- a/jdk/test/tools/jar/compat/CLICompatibility.java +++ b/jdk/test/tools/jar/compat/CLICompatibility.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -35,7 +35,7 @@ import java.util.jar.JarInputStream; import java.util.jar.JarOutputStream; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; import jdk.testlibrary.JDKToolFinder; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; @@ -49,8 +49,10 @@ import static org.testng.Assert.assertTrue; /* * @test * @bug 8170952 - * @library /lib/testlibrary - * @build jdk.testlibrary.FileUtils jdk.testlibrary.JDKToolFinder + * @library /lib/testlibrary /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils + * jdk.testlibrary.JDKToolFinder * @run testng CLICompatibility * @summary Basic test for compatibility of CLI options */ diff --git a/jdk/test/tools/jar/mmrjar/Basic.java b/jdk/test/tools/jar/mmrjar/Basic.java index a5b1eca0346..22a7a927357 100644 --- a/jdk/test/tools/jar/mmrjar/Basic.java +++ b/jdk/test/tools/jar/mmrjar/Basic.java @@ -29,8 +29,9 @@ * @modules java.base/jdk.internal.module * jdk.compiler * jdk.jartool - * @library /lib/testlibrary - * @build jdk.testlibrary.FileUtils + * @library /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @run testng Basic */ @@ -57,7 +58,7 @@ import java.util.stream.Stream; import java.util.zip.ZipFile; import jdk.internal.module.ModuleInfoExtender; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; public class Basic { private static final ToolProvider JAR_TOOL = ToolProvider.findFirst("jar") diff --git a/jdk/test/tools/jar/modularJar/Basic.java b/jdk/test/tools/jar/modularJar/Basic.java index a656a86b24b..183afdeb787 100644 --- a/jdk/test/tools/jar/modularJar/Basic.java +++ b/jdk/test/tools/jar/modularJar/Basic.java @@ -25,7 +25,6 @@ import java.io.*; import java.lang.module.ModuleDescriptor; import java.lang.reflect.Method; import java.nio.file.*; -import java.nio.file.attribute.BasicFileAttributes; import java.util.*; import java.util.function.Consumer; import java.util.jar.JarEntry; @@ -36,7 +35,7 @@ import java.util.regex.Pattern; import java.util.stream.Collectors; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; import jdk.testlibrary.JDKToolFinder; import org.testng.annotations.BeforeTest; import org.testng.annotations.DataProvider; @@ -48,10 +47,12 @@ import static java.lang.System.out; /* * @test * @bug 8167328 8171830 8165640 8174248 8176772 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler * jdk.jartool - * @build jdk.testlibrary.FileUtils jdk.testlibrary.JDKToolFinder + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils + * jdk.testlibrary.JDKToolFinder * @compile Basic.java * @run testng Basic * @summary Tests for plain Modular jars & Multi-Release Modular jars diff --git a/jdk/test/tools/jar/multiRelease/ApiValidatorTest.java b/jdk/test/tools/jar/multiRelease/ApiValidatorTest.java index 03b2e5d550f..6f17f895dab 100644 --- a/jdk/test/tools/jar/multiRelease/ApiValidatorTest.java +++ b/jdk/test/tools/jar/multiRelease/ApiValidatorTest.java @@ -24,18 +24,23 @@ /* * @test * @summary Tests for API validator. - * @library /test/lib /lib/testlibrary + * @library /test/lib * @modules java.base/jdk.internal.misc * jdk.compiler * jdk.jartool - * @build jdk.test.lib.JDKToolFinder jdk.test.lib.Utils jdk.test.lib.process.* - * @build jdk.testlibrary.FileUtils - * @build MRTestBase + * @build jdk.test.lib.util.FileUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * MRTestBase * @run testng/timeout=1200 ApiValidatorTest */ import jdk.test.lib.process.OutputAnalyzer; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; import org.testng.annotations.AfterMethod; import org.testng.annotations.BeforeMethod; import org.testng.annotations.DataProvider; @@ -421,4 +426,5 @@ public class ApiValidatorTest extends MRTestBase { javac(classes, sourceFiles); } -} \ No newline at end of file +} + diff --git a/jdk/test/tools/jar/multiRelease/Basic.java b/jdk/test/tools/jar/multiRelease/Basic.java index 80f37950591..d46ee791f4f 100644 --- a/jdk/test/tools/jar/multiRelease/Basic.java +++ b/jdk/test/tools/jar/multiRelease/Basic.java @@ -23,19 +23,24 @@ /* * @test - * @library /test/lib /lib/testlibrary + * @library /test/lib * @modules java.base/jdk.internal.misc * jdk.compiler * jdk.jartool - * @build jdk.test.lib.JDKToolFinder jdk.test.lib.Utils jdk.test.lib.process.* - * @build jdk.testlibrary.FileUtils - * @build MRTestBase + * @build jdk.test.lib.util.FileUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * MRTestBase * @run testng Basic */ import static org.testng.Assert.*; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; import org.testng.annotations.*; import java.io.File; diff --git a/jdk/test/tools/jar/multiRelease/Basic1.java b/jdk/test/tools/jar/multiRelease/Basic1.java index e01ce8fe2f8..9f86eb029cd 100644 --- a/jdk/test/tools/jar/multiRelease/Basic1.java +++ b/jdk/test/tools/jar/multiRelease/Basic1.java @@ -27,8 +27,13 @@ * @modules java.base/jdk.internal.misc * jdk.compiler * jdk.jartool - * @build jdk.test.lib.JDKToolFinder jdk.test.lib.Utils - * @build MRTestBase + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* + * MRTestBase * @run testng Basic1 */ diff --git a/jdk/test/tools/jar/multiRelease/RuntimeTest.java b/jdk/test/tools/jar/multiRelease/RuntimeTest.java index 930c07c9a60..e739dccabf4 100644 --- a/jdk/test/tools/jar/multiRelease/RuntimeTest.java +++ b/jdk/test/tools/jar/multiRelease/RuntimeTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,12 +25,14 @@ * @test * @summary Test Multi-Release jar usage in runtime * @library /test/lib - * @library /lib/testlibrary * @modules jdk.compiler - * @build jdk.test.lib.JDKToolFinder jdk.test.lib.JDKToolLauncher - * jdk.test.lib.process.OutputAnalyzer - * jdk.test.lib.process.ProcessTools - * CompilerUtils RuntimeTest + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run testng RuntimeTest */ @@ -41,6 +43,7 @@ import java.io.File; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; +import java.io.UncheckedIOException; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.net.URL; @@ -51,7 +54,10 @@ import java.nio.file.Paths; import java.nio.file.StandardCopyOption; import java.util.ArrayList; import java.util.Arrays; +import java.util.HashMap; import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; import java.util.stream.Stream; import org.testng.annotations.BeforeClass; @@ -60,37 +66,53 @@ import org.testng.annotations.Test; import jdk.test.lib.JDKToolFinder; import jdk.test.lib.JDKToolLauncher; +import jdk.test.lib.compiler.CompilerUtils; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; public class RuntimeTest { public static final int SUCCESS = 0; - private final String src = System.getProperty("test.src", "."); - private final String usr = System.getProperty("user.dir", "."); + private static final String src = System.getProperty("test.src", "."); + private static final String usr = System.getProperty("user.dir", "."); + + private static final Path srcFileRoot = Paths.get(src, "data", "runtimetest"); + private static final Path genFileRoot = Paths.get(usr, "data", "runtimetest"); + + private static final int OLD_RELEASE = 8; + private static final int CURRENT_RELEASE = Runtime.version().major(); + private static final int FUTURE_RELEASE = CURRENT_RELEASE + 1; + private static final String MRJAR_BOTH_RELEASES = "MV_BOTH.jar"; + private static final String MRJAR_CURRENT_RELEASE = "MV_ONLY_" + CURRENT_RELEASE + ".jar"; + private static final String NON_MRJAR_OLD_RELEASE = "NON_MV.jar"; + + private static final int[] versions = { OLD_RELEASE, CURRENT_RELEASE, FUTURE_RELEASE }; @DataProvider(name = "jarFiles") Object[][] jarFiles() { - return new Object[][] { { "MV_BOTH.jar", 9, 9, 9 }, - { "MV_ONLY_9.jar", 9, 9, 9 }, - { "NON_MV.jar", 8, 8, 8 } }; + return new Object[][]{ + { MRJAR_BOTH_RELEASES, CURRENT_RELEASE, CURRENT_RELEASE, CURRENT_RELEASE }, + { MRJAR_CURRENT_RELEASE, CURRENT_RELEASE, CURRENT_RELEASE, CURRENT_RELEASE }, + { NON_MRJAR_OLD_RELEASE, OLD_RELEASE, OLD_RELEASE, OLD_RELEASE } + }; } @BeforeClass protected void setUpTest() throws Throwable { + createJarSourceFiles(); compile(); Path classes = Paths.get("classes"); - jar("cfm", "MV_BOTH.jar", "manifest.txt", - "-C", classes.resolve("base").toString(), ".", - "--release", "9", "-C", classes.resolve("v9").toString(), ".", - "--release", "10", "-C", classes.resolve("v10").toString(), ".") + jar("cfm", MRJAR_BOTH_RELEASES, "manifest.txt", + "-C", classes.resolve("v" + OLD_RELEASE).toString(), ".", + "--release", "" + CURRENT_RELEASE, "-C", classes.resolve("v" + CURRENT_RELEASE).toString(), ".", + "--release", "" + FUTURE_RELEASE, "-C", classes.resolve("v" + FUTURE_RELEASE).toString(), ".") .shouldHaveExitValue(0); - jar("cfm", "MV_ONLY_9.jar", "manifest.txt", - "-C", classes.resolve("base").toString(), ".", - "--release", "9", "-C", classes.resolve("v9").toString(), ".") + jar("cfm", MRJAR_CURRENT_RELEASE, "manifest.txt", + "-C", classes.resolve("v" + OLD_RELEASE).toString(), ".", + "--release", "" + CURRENT_RELEASE, "-C", classes.resolve("v" + CURRENT_RELEASE).toString(), ".") .shouldHaveExitValue(0); - jar("cfm", "NON_MV.jar", "manifest.txt", - "-C", classes.resolve("base").toString(), ".") + jar("cfm", NON_MRJAR_OLD_RELEASE, "manifest.txt", + "-C", classes.resolve("v" + OLD_RELEASE).toString(), ".") .shouldHaveExitValue(0); } @@ -203,12 +225,37 @@ public class RuntimeTest { return ProcessTools.executeCommand(launcher.getCommand()); } + private static String platformPath(String p) { + return p.replace("/", File.separator); + } + + private static void createJarSourceFiles() throws IOException { + for (int ver : versions) { + Files.find(srcFileRoot, 3, (file, attrs) -> (file.toString().endsWith(".template"))) + .map(srcFileRoot::relativize) + .map(Path::toString) + .map(p -> p.replace(".template", "")) + .forEach(f -> { + try { + Path template = srcFileRoot.resolve(f + ".template"); + Path out = genFileRoot.resolve(platformPath("v" + ver + "/" + f)); + Files.createDirectories(out.getParent()); + List lines = Files.lines(template) + .map(s -> s.replaceAll("\\$version", String.valueOf(ver))) + .collect(Collectors.toList()); + Files.write(out, lines); + } catch (IOException x) { + throw new UncheckedIOException(x); + } + }); + } + } + private void compile() throws Throwable { - String[] vers = { "base", "v9", "v10" }; - for (String ver : vers) { - Path classes = Paths.get(usr, "classes", ver); + for (int ver : versions) { + Path classes = Paths.get(usr, "classes", "v" + ver); Files.createDirectories(classes); - Path source = Paths.get(src, "data", "runtimetest", ver); + Path source = genFileRoot.resolve("v" + ver); assertTrue(CompilerUtils.compile(source, classes)); Files.copy(source.resolve("versionResource"), classes.resolve("versionResource"), @@ -217,10 +264,10 @@ public class RuntimeTest { Path classes = Paths.get(usr, "classes", "test"); Files.createDirectory(classes); - Path source = Paths.get(src, "data", "runtimetest", "test"); + Path source = srcFileRoot.resolve("test"); assertTrue( - CompilerUtils.compile(source, classes, "-cp", "classes/base/")); - Files.copy(Paths.get(src, "data", "runtimetest", "manifest.txt"), + CompilerUtils.compile(source, classes, "-cp", "classes/v" + OLD_RELEASE)); + Files.copy(srcFileRoot.resolve("manifest.txt"), Paths.get(usr, "manifest.txt"), StandardCopyOption.REPLACE_EXISTING); } diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/base/versionResource b/jdk/test/tools/jar/multiRelease/data/runtimetest/base/versionResource deleted file mode 100644 index 301160a9306..00000000000 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/base/versionResource +++ /dev/null @@ -1 +0,0 @@ -8 \ No newline at end of file diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/base/testpackage/Helper.java b/jdk/test/tools/jar/multiRelease/data/runtimetest/testpackage/Helper.java.template similarity index 89% rename from jdk/test/tools/jar/multiRelease/data/runtimetest/base/testpackage/Helper.java rename to jdk/test/tools/jar/multiRelease/data/runtimetest/testpackage/Helper.java.template index 6028cf8090d..c547b004cfa 100644 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/base/testpackage/Helper.java +++ b/jdk/test/tools/jar/multiRelease/data/runtimetest/testpackage/Helper.java.template @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,7 +25,7 @@ package testpackage; public class Helper { - private static final int HELPER_VERSION = 8; + private static final int HELPER_VERSION = $version; public static int getHelperVersion() { return HELPER_VERSION; diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/base/testpackage/Main.java b/jdk/test/tools/jar/multiRelease/data/runtimetest/testpackage/Main.java.template similarity index 94% rename from jdk/test/tools/jar/multiRelease/data/runtimetest/base/testpackage/Main.java rename to jdk/test/tools/jar/multiRelease/data/runtimetest/testpackage/Main.java.template index 892bbe7329c..97702a7ea6c 100644 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/base/testpackage/Main.java +++ b/jdk/test/tools/jar/multiRelease/data/runtimetest/testpackage/Main.java.template @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ import java.io.InputStreamReader; public class Main { - private static final int MAIN_VERSION = 8; + private static final int MAIN_VERSION = $version; public static void main(String[] args) { System.out.println("Main version: " + getMainVersion()); diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/v10/testpackage/Main.java b/jdk/test/tools/jar/multiRelease/data/runtimetest/v10/testpackage/Main.java deleted file mode 100644 index de6fc15cbbd..00000000000 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/v10/testpackage/Main.java +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package testpackage; - -import java.io.BufferedReader; -import java.io.IOException; -import java.io.InputStream; -import java.io.InputStreamReader; - -public class Main { - - private static final int MAIN_VERSION = 10; - - public static void main(String[] args) { - System.out.println("Main version: " + getMainVersion()); - System.out.println("Helpers version: " + getHelperVersion()); - System.out.println("Resource version: " + getResourceVersion()); - } - - public static int getMainVersion() { - return MAIN_VERSION; - } - - public static int getHelperVersion() { - return testpackage.Helper.getHelperVersion(); - } - - public static int getResourceVersion() { - ClassLoader cl = Main.class.getClassLoader(); - InputStream ris = cl.getResourceAsStream("versionResource"); - if (ris == null) { - throw new Error("Test issue: resource versionResource" - + " cannot be loaded!"); - } - try (BufferedReader br = new BufferedReader(new InputStreamReader(ris))) { - return Integer.parseInt(br.readLine()); - } catch (IOException ioe) { - throw new Error("Unexpected issue", ioe); - } - } -} diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/v10/versionResource b/jdk/test/tools/jar/multiRelease/data/runtimetest/v10/versionResource deleted file mode 100644 index f599e28b8ab..00000000000 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/v10/versionResource +++ /dev/null @@ -1 +0,0 @@ -10 diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/v9/testpackage/Main.java b/jdk/test/tools/jar/multiRelease/data/runtimetest/v9/testpackage/Main.java deleted file mode 100644 index 7afcc0efc0e..00000000000 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/v9/testpackage/Main.java +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -package testpackage; - -import java.io.BufferedReader; -import java.io.IOException; -import java.io.InputStream; -import java.io.InputStreamReader; - -public class Main { - - private static final int MAIN_VERSION = 9; - - public static void main(String[] args) { - System.out.println("Main version: " + getMainVersion()); - System.out.println("Helpers version: " + getHelperVersion()); - System.out.println("Resource version: " + getResourceVersion()); - } - - public static int getMainVersion() { - return MAIN_VERSION; - } - - public static int getHelperVersion() { - return testpackage.Helper.getHelperVersion(); - } - - public static int getResourceVersion() { - ClassLoader cl = Main.class.getClassLoader(); - InputStream ris = cl.getResourceAsStream("versionResource"); - if (ris == null) { - throw new Error("Test issue: resource versionResource" - + " cannot be loaded!"); - } - try (BufferedReader br = new BufferedReader(new InputStreamReader(ris))) { - return Integer.parseInt(br.readLine()); - } catch (IOException ioe) { - throw new Error("Unexpected issue", ioe); - } - } -} diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/v9/versionResource b/jdk/test/tools/jar/multiRelease/data/runtimetest/v9/versionResource deleted file mode 100644 index ec635144f60..00000000000 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/v9/versionResource +++ /dev/null @@ -1 +0,0 @@ -9 diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/versionResource.template b/jdk/test/tools/jar/multiRelease/data/runtimetest/versionResource.template new file mode 100644 index 00000000000..f43b9c66740 --- /dev/null +++ b/jdk/test/tools/jar/multiRelease/data/runtimetest/versionResource.template @@ -0,0 +1 @@ +$version diff --git a/jdk/test/tools/jlink/basic/AllModulePath.java b/jdk/test/tools/jlink/basic/AllModulePath.java index 3053c34121a..2530184be49 100644 --- a/jdk/test/tools/jlink/basic/AllModulePath.java +++ b/jdk/test/tools/jlink/basic/AllModulePath.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,11 +24,11 @@ /* * @test * @summary jlink test of --add-module ALL-MODULE-PATH - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler * @build jdk.testlibrary.ProcessTools * jdk.testlibrary.OutputAnalyzer - * CompilerUtils + * jdk.test.lib.compiler.CompilerUtils * @run testng AllModulePath */ @@ -48,6 +48,7 @@ import java.util.stream.Collectors; import java.util.stream.Stream; import java.util.spi.ToolProvider; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.ProcessTools; import org.testng.annotations.BeforeClass; diff --git a/jdk/test/tools/jlink/basic/BasicTest.java b/jdk/test/tools/jlink/basic/BasicTest.java index ae49a01820c..94499f231ec 100644 --- a/jdk/test/tools/jlink/basic/BasicTest.java +++ b/jdk/test/tools/jlink/basic/BasicTest.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,13 +25,13 @@ * @test * @summary Basic test of jlink to create jmods and images * @author Andrei Eremeev - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules java.base/jdk.internal.module * jdk.jlink * jdk.compiler * @build jdk.testlibrary.ProcessTools * jdk.testlibrary.OutputAnalyzer - * JarUtils CompilerUtils + * JarUtils jdk.test.lib.compiler.CompilerUtils * @run main BasicTest */ @@ -45,6 +45,7 @@ import java.util.Collections; import java.util.List; import java.util.spi.ToolProvider; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.OutputAnalyzer; import jdk.testlibrary.ProcessTools; diff --git a/jdk/test/tools/jlink/bindservices/BindServices.java b/jdk/test/tools/jlink/bindservices/BindServices.java index b4ab4cc7784..c165e044fdf 100644 --- a/jdk/test/tools/jlink/bindservices/BindServices.java +++ b/jdk/test/tools/jlink/bindservices/BindServices.java @@ -33,6 +33,7 @@ import java.util.spi.ToolProvider; import java.util.stream.Collectors; import java.util.stream.Stream; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.BeforeTest; @@ -42,9 +43,10 @@ import static org.testng.Assert.*; /** * @test * @bug 8174826 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler jdk.jlink - * @build BindServices CompilerUtils jdk.testlibrary.ProcessTools + * @build BindServices jdk.testlibrary.ProcessTools + * jdk.test.lib.compiler.CompilerUtils * @run testng BindServices */ diff --git a/jdk/test/tools/jlink/bindservices/SuggestProviders.java b/jdk/test/tools/jlink/bindservices/SuggestProviders.java index d7e5b6c4ef6..9685f927f8d 100644 --- a/jdk/test/tools/jlink/bindservices/SuggestProviders.java +++ b/jdk/test/tools/jlink/bindservices/SuggestProviders.java @@ -32,6 +32,7 @@ import java.util.List; import java.util.spi.ToolProvider; import java.util.stream.Collectors; import java.util.stream.Stream; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; @@ -40,9 +41,9 @@ import static org.testng.Assert.*; /** * @test * @bug 8174826 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.charsets jdk.compiler jdk.jlink - * @build SuggestProviders CompilerUtils + * @build SuggestProviders jdk.test.lib.compiler.CompilerUtils * @run testng SuggestProviders */ diff --git a/jdk/test/tools/jlink/multireleasejar/JLinkMultiReleaseJarTest.java b/jdk/test/tools/jlink/multireleasejar/JLinkMultiReleaseJarTest.java index a61f592f55d..1841fed5181 100644 --- a/jdk/test/tools/jlink/multireleasejar/JLinkMultiReleaseJarTest.java +++ b/jdk/test/tools/jlink/multireleasejar/JLinkMultiReleaseJarTest.java @@ -29,9 +29,14 @@ * @library /test/lib * @modules java.base/jdk.internal.jimage * java.base/jdk.internal.module - * @build jdk.test.lib.process.* + * @build jdk.test.lib.Utils + * jdk.test.lib.Asserts + * jdk.test.lib.JDKToolFinder + * jdk.test.lib.JDKToolLauncher + * jdk.test.lib.Platform + * jdk.test.lib.process.* * @run testng JLinkMultiReleaseJarTest -*/ + */ import java.io.ByteArrayInputStream; import java.io.IOException; diff --git a/jdk/test/tools/jlink/plugins/ExcludeJmodSectionPluginTest.java b/jdk/test/tools/jlink/plugins/ExcludeJmodSectionPluginTest.java index 810a75178f2..072694f36f5 100644 --- a/jdk/test/tools/jlink/plugins/ExcludeJmodSectionPluginTest.java +++ b/jdk/test/tools/jlink/plugins/ExcludeJmodSectionPluginTest.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,10 +24,10 @@ /* * @test * @summary Test --no-man-pages and --no-header-files - * @library /lib/testlibrary + * @library /test/lib * @modules jdk.compiler * jdk.jlink - * @build CompilerUtils + * @build jdk.test.lib.compiler.CompilerUtils * @run testng ExcludeJmodSectionPluginTest */ @@ -48,6 +48,7 @@ import java.util.Set; import java.util.spi.ToolProvider; import java.util.stream.Collectors; import java.util.stream.Stream; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.DataProvider; diff --git a/jdk/test/tools/jlink/plugins/LegalFilePluginTest.java b/jdk/test/tools/jlink/plugins/LegalFilePluginTest.java index d5b3dfde4b4..7d49ae178fb 100644 --- a/jdk/test/tools/jlink/plugins/LegalFilePluginTest.java +++ b/jdk/test/tools/jlink/plugins/LegalFilePluginTest.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,10 +25,10 @@ * @test * @bug 8169925 * @summary Validate the license files deduplicated in the image - * @library /lib/testlibrary + * @library /test/lib * @modules jdk.compiler * jdk.jlink - * @build CompilerUtils + * @build jdk.test.lib.compiler.CompilerUtils * @run testng LegalFilePluginTest */ @@ -53,6 +53,7 @@ import java.util.Set; import java.util.spi.ToolProvider; import java.util.stream.Collectors; import java.util.stream.Stream; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.DataProvider; diff --git a/jdk/test/tools/jlink/plugins/SystemModuleDescriptors/CompiledVersionTest.java b/jdk/test/tools/jlink/plugins/SystemModuleDescriptors/CompiledVersionTest.java index 36f82a9ddc4..ca0584f2b93 100644 --- a/jdk/test/tools/jlink/plugins/SystemModuleDescriptors/CompiledVersionTest.java +++ b/jdk/test/tools/jlink/plugins/SystemModuleDescriptors/CompiledVersionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,7 +29,8 @@ import java.util.Arrays; import java.util.stream.Collectors; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.compiler.CompilerUtils; +import jdk.test.lib.util.FileUtils; import static jdk.testlibrary.ProcessTools.*; @@ -39,9 +40,12 @@ import static org.testng.Assert.*; /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler jdk.jlink - * @build CompiledVersionTest CompilerUtils jdk.testlibrary.FileUtils jdk.testlibrary.ProcessTools + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.util.FileUtils + * jdk.test.lib.Platform + * CompiledVersionTest jdk.testlibrary.ProcessTools * @run testng CompiledVersionTest */ diff --git a/jdk/test/tools/jlink/plugins/SystemModuleDescriptors/UserModuleTest.java b/jdk/test/tools/jlink/plugins/SystemModuleDescriptors/UserModuleTest.java index c8a221840b1..827b88be58e 100644 --- a/jdk/test/tools/jlink/plugins/SystemModuleDescriptors/UserModuleTest.java +++ b/jdk/test/tools/jlink/plugins/SystemModuleDescriptors/UserModuleTest.java @@ -23,7 +23,6 @@ import java.io.File; import java.io.IOException; -import java.lang.module.ModuleDescriptor; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; @@ -33,7 +32,8 @@ import java.util.spi.ToolProvider; import java.util.stream.Collectors; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.compiler.CompilerUtils; +import jdk.test.lib.util.FileUtils; import static jdk.testlibrary.ProcessTools.*; @@ -44,11 +44,14 @@ import static org.testng.Assert.*; /** * @test * @bug 8142968 8173381 8174740 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler jdk.jlink * @modules java.base/jdk.internal.module * @modules java.base/jdk.internal.org.objectweb.asm - * @build ModuleTargetHelper UserModuleTest CompilerUtils jdk.testlibrary.FileUtils jdk.testlibrary.ProcessTools + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.util.FileUtils + * jdk.test.lib.Platform + * ModuleTargetHelper UserModuleTest jdk.testlibrary.ProcessTools * @run testng UserModuleTest */ diff --git a/jdk/test/tools/jmod/JmodNegativeTest.java b/jdk/test/tools/jmod/JmodNegativeTest.java index 00d89a635e4..30205067b0e 100644 --- a/jdk/test/tools/jmod/JmodNegativeTest.java +++ b/jdk/test/tools/jmod/JmodNegativeTest.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,10 +23,12 @@ /* * @test - * @library /lib/testlibrary + * @library /test/lib * @modules jdk.compiler * jdk.jlink - * @build jdk.testlibrary.FileUtils CompilerUtils + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.util.FileUtils + * jdk.test.lib.Platform * @run testng JmodNegativeTest * @summary Negative tests for jmod */ @@ -41,7 +43,8 @@ import java.util.function.Consumer; import java.util.function.Supplier; import java.util.spi.ToolProvider; import java.util.zip.ZipOutputStream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; +import jdk.test.lib.compiler.CompilerUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.DataProvider; import org.testng.annotations.Test; diff --git a/jdk/test/tools/jmod/JmodTest.java b/jdk/test/tools/jmod/JmodTest.java index e578b2f360e..d6a80deaec7 100644 --- a/jdk/test/tools/jmod/JmodTest.java +++ b/jdk/test/tools/jmod/JmodTest.java @@ -1,5 +1,5 @@ /** - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,10 +25,12 @@ * @test * @bug 8142968 8166568 8166286 8170618 8168149 * @summary Basic test for jmod - * @library /lib/testlibrary + * @library /test/lib * @modules jdk.compiler * jdk.jlink - * @build jdk.testlibrary.FileUtils CompilerUtils + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.util.FileUtils + * jdk.test.lib.Platform * @run testng/othervm -Djava.io.tmpdir=. JmodTest */ @@ -40,9 +42,9 @@ import java.util.*; import java.util.function.Consumer; import java.util.regex.Pattern; import java.util.spi.ToolProvider; -import java.util.stream.Collectors; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.compiler.CompilerUtils; +import jdk.test.lib.util.FileUtils; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; diff --git a/jdk/test/tools/jmod/hashes/HashesTest.java b/jdk/test/tools/jmod/hashes/HashesTest.java index 10680927c19..867927685d4 100644 --- a/jdk/test/tools/jmod/hashes/HashesTest.java +++ b/jdk/test/tools/jmod/hashes/HashesTest.java @@ -25,13 +25,14 @@ * @test * @bug 8160286 * @summary Test the recording and checking of module hashes - * @library /lib/testlibrary + * @library /test/lib * @modules java.base/jdk.internal.misc * java.base/jdk.internal.module * jdk.compiler * jdk.jartool * jdk.jlink - * @build CompilerUtils ModuleInfoMaker + * @build jdk.test.lib.compiler.ModuleInfoMaker + * jdk.test.lib.compiler.CompilerUtils * @run testng HashesTest */ @@ -62,6 +63,8 @@ import jdk.internal.module.ModuleInfo; import jdk.internal.module.ModuleHashes; import jdk.internal.module.ModulePath; +import jdk.test.lib.compiler.ModuleInfoMaker; + import org.testng.annotations.Test; import static org.testng.Assert.*; @@ -382,7 +385,7 @@ public class HashesTest { makeModule(mn, null, deps); } - private void makeModule(String mn, ModuleDescriptor.Requires.Modifier mod, String... deps) + private void makeModule(String mn, ModuleDescriptor.Requires.Modifier mod, String... deps) throws IOException { if (mod != null && mod != TRANSITIVE && mod != STATIC) { @@ -390,23 +393,23 @@ public class HashesTest { } StringBuilder sb = new StringBuilder(); - sb.append("module " + mn + " {").append("\n"); - Arrays.stream(deps).forEach(req -> { - sb.append(" requires "); - if (mod != null) { - sb.append(mod.toString().toLowerCase()).append(" "); - } - sb.append(req + ";\n"); - }); + sb.append("module ") + .append(mn) + .append(" {") + .append("\n"); + Arrays.stream(deps) + .forEach(req -> { + sb.append(" requires "); + if (mod != null) { + sb.append(mod.toString().toLowerCase()) + .append(" "); + } + sb.append(req) + .append(";\n"); + }); sb.append("}\n"); builder.writeJavaFiles(mn, sb.toString()); - - compileModule(mn, srcDir); - } - - private void compileModule(String moduleName, Path src) throws IOException { - Path msrc = src.resolve(moduleName); - assertTrue(CompilerUtils.compile(msrc, mods, "--module-source-path", src.toString())); + builder.compile(mn, mods); } private void jmodHashModules(String moduleName, String hashModulesPattern) { diff --git a/jdk/test/tools/launcher/ChangeDataModel.java b/jdk/test/tools/launcher/ChangeDataModel.java index 31ee6f8cfe4..e6bc281ad62 100644 --- a/jdk/test/tools/launcher/ChangeDataModel.java +++ b/jdk/test/tools/launcher/ChangeDataModel.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,104 +23,57 @@ /** * @test - * @bug 4894330 4810347 6277269 8029388 + * @bug 4894330 4810347 6277269 8029388 8169646 * @compile -XDignore.symbol.file ChangeDataModel.java * @run main ChangeDataModel - * @summary Verify -d32 and -d64 options are accepted(rejected) on all platforms + * @summary Verify -d32, -d64 and -J prefixed data-model options are rejected on all platforms * @author Joseph D. Darcy, ksrini */ -import java.io.File; -import java.util.ArrayList; -import java.util.List; + +import java.util.Arrays; public class ChangeDataModel extends TestHelper { - private static final File TestJar = new File("test" + JAR_FILE_EXT); - private static final String OptionName = "Args"; - private static final File TestOptionJar = new File(OptionName + JAR_FILE_EXT); - private static final String OPT_PREFIX = "ARCH_OPT:"; - static void createTestJar() throws Exception { - String[] code = { - " public static void main(String argv[]) {", - " System.out.println(\"" + OPT_PREFIX + "-d\" + System.getProperty(\"sun.arch.data.model\", \"none\"));", - " }",}; - createJar(TestJar, code); - } public static void main(String... args) throws Exception { - createTestJar(); - createOptionsJar(); - - // verify if data model flag for default data model is accepted, also - // verify if the complimentary data model is rejected. - if (is32Bit) { - checkAcceptance(javaCmd, "-d32"); - checkRejection(javaCmd, "-d64"); - checkOption(javaCmd, "-d64"); - } else if (is64Bit) { - checkAcceptance(javaCmd, "-d64"); - checkRejection(javaCmd, "-d32"); - checkOption(javaCmd, "-d32"); - } else { - throw new Error("unsupported data model"); - } + new ChangeDataModel().run(args); } - static void checkAcceptance(String cmd, String dmodel) { - TestResult tr = doExec(cmd, dmodel, "-jar", TestJar.getAbsolutePath()); - if (!tr.contains(OPT_PREFIX + dmodel)) { + @Test + public void check32bitRejection() throws Exception { + checkRejection("-d32"); + } + + @Test + public void check64bitRejection() throws Exception { + checkRejection("-d64"); + } + + void checkRejection(String dmodel) throws Exception { + String expect = "Unrecognized option: " + dmodel; + String[] cmds1 = { + javaCmd, + dmodel, + "-version" + }; + checkRejection(expect, cmds1); + + String[] cmds2 = { + javacCmd, + "-J" + dmodel, + "-version" + }; + checkRejection(expect, cmds2); + } + + + void checkRejection(String expect, String... cmds) throws Exception { + TestResult tr = doExec(cmds); + tr.checkNegative(); + if (!tr.contains(expect)) { System.out.println(tr); - String message = "Data model flag " + dmodel + - " not accepted or had improper effect."; - throw new RuntimeException(message); + String error = "did not get " + "\'" + expect + "\'" + + "with options " + Arrays.asList(cmds); + throw new Exception(error); } } - - static void checkRejection(String cmd, String dmodel) { - TestResult tr = doExec(cmd, dmodel, "-jar", TestJar.getAbsolutePath()); - if (tr.contains(OPT_PREFIX + dmodel)) { - System.out.println(tr); - String message = "Data model flag " + dmodel + " was accepted."; - throw new RuntimeException(message); - } - } - - static void checkOption(String cmd, String dmodel) throws Exception { - TestResult tr = doExec(cmd, "-jar", TestOptionJar.getAbsolutePath(), dmodel); - verifyOption(tr, dmodel); - - tr = doExec(cmd, "-cp", ".", OptionName, dmodel); - verifyOption(tr, dmodel); - } - - static void verifyOption(TestResult tr, String dmodel) { - if (!tr.contains(OPT_PREFIX + dmodel)) { - System.out.println(tr); - String message = "app argument: " + dmodel + " not found."; - throw new RuntimeException(message); - } - if (!tr.isOK()) { - System.out.println(tr); - String message = "app argument: " + dmodel + " interpreted ?"; - throw new RuntimeException(message); - } - } - - static void createOptionsJar() throws Exception { - List code = new ArrayList<>(); - code.add("public class Args {"); - code.add(" public static void main(String argv[]) {"); - code.add(" for (String x : argv)"); - code.add(" System.out.println(\"" + OPT_PREFIX + "\" + x);"); - code.add(" }"); - code.add("}"); - File optionsJava = new File(OptionName + JAVA_FILE_EXT); - createFile(optionsJava, code); - File optionsClass = new File(OptionName + CLASS_FILE_EXT); - - compile(optionsJava.getName()); - createJar("cvfe", - TestOptionJar.getName(), - OptionName, - optionsClass.getName()); - } } diff --git a/jdk/test/tools/launcher/LauncherMessageTest.java b/jdk/test/tools/launcher/LauncherMessageTest.java index d83ad82acba..ff1ee640bf8 100644 --- a/jdk/test/tools/launcher/LauncherMessageTest.java +++ b/jdk/test/tools/launcher/LauncherMessageTest.java @@ -24,16 +24,18 @@ /** * @test * @bug 8167063 - * @library /lib/testlibrary - * @build jdk.testlibrary.FileUtils + * @library /test/lib + * @build jdk.test.lib.Platform + * jdk.test.lib.util.FileUtils * @run main LauncherMessageTest * @summary LauncherHelper should not throw JNI error for LinkageError */ + import java.io.File; import java.nio.file.Paths; import java.util.ArrayList; import java.util.List; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.util.FileUtils; public class LauncherMessageTest { diff --git a/jdk/test/tools/launcher/Test7029048.java b/jdk/test/tools/launcher/Test7029048.java index 1a32322c832..b9d70aee9f2 100644 --- a/jdk/test/tools/launcher/Test7029048.java +++ b/jdk/test/tools/launcher/Test7029048.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -193,7 +193,7 @@ public class Test7029048 extends TestHelper { if (isSolaris) { /* * Case 3: set the appropriate LLP_XX flag, - * java64 -d64, LLP_64 is relevant, LLP_32 is ignored + * java64 LLP_64 is relevant, LLP_32 is ignored */ env.clear(); env.put(LD_LIBRARY_PATH_64, dstServerDir.getAbsolutePath()); diff --git a/jdk/test/tools/launcher/modules/addexports/AddExportsTest.java b/jdk/test/tools/launcher/modules/addexports/AddExportsTest.java index c92824f39da..64505f8bcd1 100644 --- a/jdk/test/tools/launcher/modules/addexports/AddExportsTest.java +++ b/jdk/test/tools/launcher/modules/addexports/AddExportsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,9 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build AddExportsTest CompilerUtils jdk.testlibrary.* + * @build AddExportsTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng AddExportsTest * @summary Basic tests for java --add-exports */ @@ -34,6 +34,7 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.util.stream.Stream; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.OutputAnalyzer; import static jdk.testlibrary.ProcessTools.*; diff --git a/jdk/test/tools/launcher/modules/addexports/AddExportsTestWarningError.java b/jdk/test/tools/launcher/modules/addexports/AddExportsTestWarningError.java index 0a20fec711a..716e0bf0ec0 100644 --- a/jdk/test/tools/launcher/modules/addexports/AddExportsTestWarningError.java +++ b/jdk/test/tools/launcher/modules/addexports/AddExportsTestWarningError.java @@ -25,10 +25,11 @@ * @test * @bug 8168836 * @summary Basic argument validation for --add-exports - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build AddExportsTestWarningError CompilerUtils ModuleInfoMaker - * @build jdk.testlibrary.* + * @build jdk.test.lib.compiler.ModuleInfoMaker + * jdk.test.lib.compiler.CompilerUtils + * jdk.testlibrary.* * @run testng AddExportsTestWarningError */ @@ -40,6 +41,7 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.stream.Stream; +import jdk.test.lib.compiler.ModuleInfoMaker; import jdk.testlibrary.OutputAnalyzer; import static jdk.testlibrary.ProcessTools.*; @@ -48,7 +50,6 @@ import org.testng.annotations.DataProvider; import org.testng.annotations.Test; import static org.testng.Assert.*; - @Test public class AddExportsTestWarningError { diff --git a/jdk/test/tools/launcher/modules/addmods/AddModsTest.java b/jdk/test/tools/launcher/modules/addmods/AddModsTest.java index d60c2ea7446..9ca252342c6 100644 --- a/jdk/test/tools/launcher/modules/addmods/AddModsTest.java +++ b/jdk/test/tools/launcher/modules/addmods/AddModsTest.java @@ -23,10 +23,10 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.jlink/jdk.tools.jmod * jdk.compiler - * @build AddModsTest CompilerUtils jdk.testlibrary.* + * @build AddModsTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng AddModsTest * @summary Basic test for java --add-modules */ @@ -35,6 +35,7 @@ import java.io.File; import java.nio.file.Path; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.BeforeTest; diff --git a/jdk/test/tools/launcher/modules/addreads/AddReadsTest.java b/jdk/test/tools/launcher/modules/addreads/AddReadsTest.java index 6d0b4a7eaf6..09a1360b3e9 100644 --- a/jdk/test/tools/launcher/modules/addreads/AddReadsTest.java +++ b/jdk/test/tools/launcher/modules/addreads/AddReadsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,10 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build AddReadsTest CompilerUtils JarUtils jdk.testlibrary.* + * @build AddReadsTest JarUtils jdk.testlibrary.* + * jdk.test.lib.compiler.CompilerUtils * @run testng AddReadsTest * @summary Basic tests for java --add-reads */ @@ -33,6 +34,7 @@ import java.nio.file.Path; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.OutputAnalyzer; import static jdk.testlibrary.ProcessTools.*; diff --git a/jdk/test/tools/launcher/modules/addreads/AddReadsTestWarningError.java b/jdk/test/tools/launcher/modules/addreads/AddReadsTestWarningError.java index 6c9ee5634eb..d1c69378acf 100644 --- a/jdk/test/tools/launcher/modules/addreads/AddReadsTestWarningError.java +++ b/jdk/test/tools/launcher/modules/addreads/AddReadsTestWarningError.java @@ -25,10 +25,12 @@ * @test * @bug 8168836 * @summary Basic argument validation for --add-reads - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build AddReadsTestWarningError CompilerUtils ModuleInfoMaker + * @build jdk.test.lib.compiler.ModuleInfoMaker + * @build jdk.test.lib.compiler.CompilerUtils * @build jdk.testlibrary.* + * @build AddReadsTestWarningError * @run testng AddReadsTestWarningError */ @@ -40,6 +42,7 @@ import java.nio.file.Paths; import java.util.Arrays; import java.util.stream.Stream; +import jdk.test.lib.compiler.ModuleInfoMaker; import jdk.testlibrary.OutputAnalyzer; import static jdk.testlibrary.ProcessTools.*; @@ -48,7 +51,6 @@ import org.testng.annotations.DataProvider; import org.testng.annotations.Test; import static org.testng.Assert.*; - @Test public class AddReadsTestWarningError { diff --git a/jdk/test/tools/launcher/modules/basic/BasicTest.java b/jdk/test/tools/launcher/modules/basic/BasicTest.java index 3256f354c78..91629f659db 100644 --- a/jdk/test/tools/launcher/modules/basic/BasicTest.java +++ b/jdk/test/tools/launcher/modules/basic/BasicTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,11 +23,11 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler * jdk.jartool * jdk.jlink - * @build BasicTest CompilerUtils jdk.testlibrary.* + * @build BasicTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng BasicTest * @summary Basic test of starting an application as a module */ @@ -38,6 +38,7 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.util.spi.ToolProvider; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.ProcessTools; import org.testng.annotations.BeforeTest; diff --git a/jdk/test/tools/launcher/modules/classpath/JavaClassPathTest.java b/jdk/test/tools/launcher/modules/classpath/JavaClassPathTest.java index afac4220b13..cd26a99a196 100644 --- a/jdk/test/tools/launcher/modules/classpath/JavaClassPathTest.java +++ b/jdk/test/tools/launcher/modules/classpath/JavaClassPathTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,6 +30,7 @@ import java.util.List; import java.util.Map; import java.util.spi.ToolProvider; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.OutputAnalyzer; import org.testng.annotations.BeforeTest; import org.testng.annotations.DataProvider; @@ -42,10 +43,10 @@ import static jdk.testlibrary.ProcessTools.*; * @test * @bug 8168205 * @summary Test the default class path if -Djava.class.path is set - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler * jdk.jartool - * @build CompilerUtils jdk.testlibrary.* + * @build jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng JavaClassPathTest */ diff --git a/jdk/test/tools/launcher/modules/dryrun/DryRunTest.java b/jdk/test/tools/launcher/modules/dryrun/DryRunTest.java index afb1fbc78f1..2c4e7e1219e 100644 --- a/jdk/test/tools/launcher/modules/dryrun/DryRunTest.java +++ b/jdk/test/tools/launcher/modules/dryrun/DryRunTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,10 +24,11 @@ /** * @test * @bug 8159596 - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler * jdk.jartool - * @build DryRunTest CompilerUtils jdk.testlibrary.ProcessTools + * @build DryRunTest jdk.testlibrary.ProcessTools + * jdk.test.lib.compiler.CompilerUtils * @run testng DryRunTest * @summary Test java --dry-run */ @@ -39,13 +40,13 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.util.spi.ToolProvider; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.ProcessTools; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; import static org.testng.Assert.*; - @Test public class DryRunTest { diff --git a/jdk/test/tools/launcher/modules/limitmods/LimitModsTest.java b/jdk/test/tools/launcher/modules/limitmods/LimitModsTest.java index 208e36f9fa2..e898837c72e 100644 --- a/jdk/test/tools/launcher/modules/limitmods/LimitModsTest.java +++ b/jdk/test/tools/launcher/modules/limitmods/LimitModsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,9 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules java.desktop java.logging jdk.compiler - * @build LimitModsTest CompilerUtils jdk.testlibrary.* + * @build LimitModsTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng LimitModsTest * @summary Basic tests for java --limit-modules */ @@ -33,13 +33,13 @@ import java.nio.file.Path; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; import static org.testng.Assert.*; - @Test public class LimitModsTest { diff --git a/jdk/test/tools/launcher/modules/listmods/ListModsTest.java b/jdk/test/tools/launcher/modules/listmods/ListModsTest.java index 4fd8984842b..913f17ee8a9 100644 --- a/jdk/test/tools/launcher/modules/listmods/ListModsTest.java +++ b/jdk/test/tools/launcher/modules/listmods/ListModsTest.java @@ -23,9 +23,9 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules java.se - * @build ListModsTest CompilerUtils jdk.testlibrary.* + * @build ListModsTest jdk.test.lib.compiler.CompilerUtils jdk.testlibrary.* * @run testng ListModsTest * @summary Basic test for java --list-modules */ @@ -33,6 +33,7 @@ import java.nio.file.Path; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; import jdk.testlibrary.ProcessTools; import jdk.testlibrary.OutputAnalyzer; diff --git a/jdk/test/tools/launcher/modules/patch/basic/PatchTest.java b/jdk/test/tools/launcher/modules/patch/basic/PatchTest.java index 15457cf7664..e1ba5ba3840 100644 --- a/jdk/test/tools/launcher/modules/patch/basic/PatchTest.java +++ b/jdk/test/tools/launcher/modules/patch/basic/PatchTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,10 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build PatchTest CompilerUtils JarUtils jdk.testlibrary.* + * @build PatchTest JarUtils jdk.testlibrary.* + * jdk.test.lib.compiler.CompilerUtils * @run testng PatchTest * @summary Basic test for --patch-module */ @@ -37,13 +38,13 @@ import java.nio.file.Paths; import java.util.stream.Collectors; import java.util.stream.Stream; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; import static org.testng.Assert.*; - /** * Compiles and launches a test that uses --patch-module with two directories * of classes to override existing classes and add new classes to modules in diff --git a/jdk/test/tools/launcher/modules/patch/basic/PatchTestWarningError.java b/jdk/test/tools/launcher/modules/patch/basic/PatchTestWarningError.java index 2d5b14bb858..6bf6b97fb62 100644 --- a/jdk/test/tools/launcher/modules/patch/basic/PatchTestWarningError.java +++ b/jdk/test/tools/launcher/modules/patch/basic/PatchTestWarningError.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,10 @@ * @test * @bug 8168836 * @summary Basic argument validation for --patch-module - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build PatchTestWarningError CompilerUtils JarUtils jdk.testlibrary.* + * @build PatchTestWarningError JarUtils jdk.testlibrary.* + * jdk.test.lib.compiler.CompilerUtils * @run testng PatchTestWarningError */ @@ -38,6 +39,7 @@ import java.nio.file.Paths; import java.util.stream.Collectors; import java.util.stream.Stream; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.*; import org.testng.annotations.BeforeTest; diff --git a/jdk/test/tools/launcher/modules/patch/systemmodules/PatchSystemModules.java b/jdk/test/tools/launcher/modules/patch/systemmodules/PatchSystemModules.java index 4fa50c5b697..29acb1f77a4 100644 --- a/jdk/test/tools/launcher/modules/patch/systemmodules/PatchSystemModules.java +++ b/jdk/test/tools/launcher/modules/patch/systemmodules/PatchSystemModules.java @@ -25,9 +25,11 @@ * @test * @bug 8157068 8177844 * @summary Patch java.base and user module with ModuleHashes attribute - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build CompilerUtils + * @build jdk.test.lib.compiler.CompilerUtils + * jdk.test.lib.util.FileUtils + * jdk.test.lib.Platform * @run testng PatchSystemModules */ @@ -39,7 +41,8 @@ import java.util.ArrayList; import java.util.List; import java.util.stream.Stream; -import jdk.testlibrary.FileUtils; +import jdk.test.lib.compiler.CompilerUtils; +import jdk.test.lib.util.FileUtils; import jdk.testlibrary.JDKToolFinder; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; diff --git a/jdk/test/tools/launcher/modules/upgrademodulepath/UpgradeModulePathTest.java b/jdk/test/tools/launcher/modules/upgrademodulepath/UpgradeModulePathTest.java index 3655281427a..9ece8ee40a6 100644 --- a/jdk/test/tools/launcher/modules/upgrademodulepath/UpgradeModulePathTest.java +++ b/jdk/test/tools/launcher/modules/upgrademodulepath/UpgradeModulePathTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,9 +23,10 @@ /** * @test - * @library /lib/testlibrary + * @library /lib/testlibrary /test/lib * @modules jdk.compiler - * @build UpgradeModulePathTest CompilerUtils jdk.testlibrary.* + * @build UpgradeModulePathTest jdk.testlibrary.* + * jdk.test.lib.compiler.CompilerUtils * @run testng UpgradeModulePathTest * @summary Basic test for java --upgrade-module-path */ @@ -34,6 +35,7 @@ import java.io.File; import java.nio.file.Path; import java.nio.file.Paths; +import jdk.test.lib.compiler.CompilerUtils; import static jdk.testlibrary.ProcessTools.executeTestJava; import org.testng.annotations.BeforeTest; @@ -46,7 +48,6 @@ import static org.testng.Assert.*; * modue path. */ - @Test public class UpgradeModulePathTest { diff --git a/jdk/test/tools/schemagen/MultiReleaseJarTest.java b/jdk/test/tools/schemagen/MultiReleaseJarTest.java index e3b656378df..26aa230680a 100644 --- a/jdk/test/tools/schemagen/MultiReleaseJarTest.java +++ b/jdk/test/tools/schemagen/MultiReleaseJarTest.java @@ -25,18 +25,18 @@ * @test * @summary Test Multi-Release jar support in schemagen tool * @library /test/lib - * @library /lib/testlibrary * @modules jdk.compiler java.xml.ws * @build jdk.test.lib.JDKToolFinder jdk.test.lib.JDKToolLauncher * jdk.test.lib.process.OutputAnalyzer * jdk.test.lib.process.ProcessTools * jdk.test.lib.Utils - * CompilerUtils MultiReleaseJarTest + * jdk.test.lib.compiler.CompilerUtils MultiReleaseJarTest * @run testng MultiReleaseJarTest */ import jdk.test.lib.JDKToolLauncher; import jdk.test.lib.Utils; +import jdk.test.lib.compiler.CompilerUtils; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; import org.testng.annotations.BeforeClass; @@ -114,4 +114,5 @@ public class MultiReleaseJarTest { "--add-modules", "java.xml.ws")); } } -} \ No newline at end of file +} + diff --git a/jdk/test/tools/wsgen/MultiReleaseJarTest.java b/jdk/test/tools/wsgen/MultiReleaseJarTest.java index 294c413f3dd..c6953416d9b 100644 --- a/jdk/test/tools/wsgen/MultiReleaseJarTest.java +++ b/jdk/test/tools/wsgen/MultiReleaseJarTest.java @@ -25,18 +25,18 @@ * @test * @summary Test Multi-Release jar support in wsgen tool * @library /test/lib - * @library /lib/testlibrary * @modules jdk.compiler java.xml.ws * @build jdk.test.lib.JDKToolFinder jdk.test.lib.JDKToolLauncher * jdk.test.lib.process.OutputAnalyzer * jdk.test.lib.process.ProcessTools * jdk.test.lib.Utils - * CompilerUtils MultiReleaseJarTest + * jdk.test.lib.compiler.CompilerUtils MultiReleaseJarTest * @run testng MultiReleaseJarTest */ import jdk.test.lib.JDKToolLauncher; import jdk.test.lib.Utils; +import jdk.test.lib.compiler.CompilerUtils; import jdk.test.lib.process.OutputAnalyzer; import jdk.test.lib.process.ProcessTools; import org.testng.annotations.BeforeClass; @@ -117,4 +117,5 @@ public class MultiReleaseJarTest { "--add-modules", "java.xml.ws")); } } -} \ No newline at end of file +} + diff --git a/langtools/.hgtags b/langtools/.hgtags index b0dfd872ddc..fea2bdf102c 100644 --- a/langtools/.hgtags +++ b/langtools/.hgtags @@ -396,5 +396,35 @@ e5a42ddaf633fde14b983f740ae0e7e490741fd1 jdk-9+150 4f348bd05341581df84ff1510d5b3a9b5b488367 jdk-9+151 5b6f12de6f9167a582fa2c6ac54e69c591b09e68 jdk-9+152 03f48cd283f5dd6b7153fd7e0cf2df8582b14391 jdk-9+153 +b670e95106f5327a29e2e2c4f18ee48a8d36e481 jdk-10+0 6a9dd3d893b0a493a3e5d8d392815b5ee76a02d9 jdk-9+154 dfcfdb2db85f1bb434209f56ca557ea6f9830aa8 jdk-9+155 +6f91e41163bc09e9b3ec72e8d1185f39296ee5d4 jdk-9+156 +ce999290d1c31bf8b28c51b1890268cc73cd4722 jdk-10+1 +162b521af7bb097019a8afaa44e1f8069ce274eb jdk-9+157 +4eb737a8d439f49a197e8000de26c6580cb4d57b jdk-9+158 +39449d2a6398fee779630f041c55c0466f5fd2c0 jdk-9+159 +0f4fef68d2d84ad78b3aaf6eab2c07873aedf971 jdk-9+160 +2340259b31554a3761e9909953c8ab8ef124ac07 jdk-9+161 +440c45c2e8cee78f6883fa6f2505a781505f323c jdk-9+162 +24582dd2649a155876de89273975ebe1adb5f18c jdk-9+163 +c7f3df19667b093538c6eecb73dcb3fb531706b4 jdk-9+164 +98108b7d4cb6078773e2d27ad8471dc25d4d6124 jdk-9+165 +2a8b403a623320479705aad04ed8d78396661eb7 jdk-9+166 +657b68876fe39c6104c8a6350b746203edfd9da2 jdk-10+2 +e5689e13301ec65d8fba8ae7e581b1cb3bf5a391 jdk-10+3 +ef9180164e0847387519152d08bbcbcf9da0606d jdk-10+4 +6190dbeac954c5efd64201a8ab04d393330ff192 jdk-10+5 +2b33ceb2cee7ba561657ed69fcb14d6cf0543f3d jdk-10+6 +f260f1a2acf616509a4ee5a29bc7f2acca3853e3 jdk-9+167 +bc21e5ba6bf1538551093f57fa0f1a6571be05cc jdk-9+168 +0e522ff8b9f52a9d4929af9a6aa84110f4dcd81d jdk-9+169 +18355c879c69a33167f1862896738a7b9a4da729 jdk-9+170 +85581ae8a97f20fd2f817a71eb3cd7b04e492722 jdk-10+7 +6d9a33d72d0647f3981c9d9c636a6f1290689895 jdk-10+8 +a8e4d2286ebaf93c0f69fb4bbd399253f396db00 jdk-10+9 +aae59039c1f5701ae933c5eed30e75d6e3afaeee jdk-9+171 +48a87c3414d374e3a26ddb270318c9af10de4b32 jdk-10+10 +03669efa77f51852f5301623cad4a2e1bb4fb9f6 jdk-9+172 +daa70bfed35ecf0575884c954dc95135e0f94b29 jdk-10+11 +123eb0956a459bca29d0812c62fca50da563ee40 jdk-9+173 diff --git a/langtools/.jcheck/conf b/langtools/.jcheck/conf index 5c6f62dc12c..b2581358014 100644 --- a/langtools/.jcheck/conf +++ b/langtools/.jcheck/conf @@ -1 +1 @@ -project=jdk9 +project=jdk10 diff --git a/langtools/make/CompileInterim.gmk b/langtools/make/CompileInterim.gmk index 33a23802306..20b967a4074 100644 --- a/langtools/make/CompileInterim.gmk +++ b/langtools/make/CompileInterim.gmk @@ -1,5 +1,5 @@ # -# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -47,7 +47,8 @@ define SetupInterimModule $$(wildcard $(SUPPORT_OUTPUTDIR)/gensrc/$(strip $1)), \ EXCLUDES := sun com/sun/tools/jdeps com/sun/tools/javap \ com/sun/tools/jdeprscan, \ - EXCLUDE_FILES := module-info.java JavacToolProvider.java JavadocToolProvider.java, \ + EXCLUDE_FILES := module-info.java JavacToolProvider.java \ + JavadocToolProvider.java Standard.java, \ COPY := .gif .png .xml .css .js javax.tools.JavaCompilerTool, \ BIN := $(BUILDTOOLS_OUTPUTDIR)/override_modules/$(strip $1), \ ADD_JAVAC_FLAGS := -Xbootclasspath/p:$$(call PathList, \ diff --git a/langtools/make/build.properties b/langtools/make/build.properties index 4deb152a515..9ee717093c3 100644 --- a/langtools/make/build.properties +++ b/langtools/make/build.properties @@ -56,7 +56,7 @@ tool.javadoc.main.class=jdk.javadoc.internal.tool.Main tool.javap.main.class=com.sun.tools.javap.Main tool.javah.main.class=com.sun.tools.javah.Main tool.sjavac.main.class=com.sun.tools.sjavac.Main -tool.jshell.main.class=jdk.internal.jshell.tool.JShellTool +tool.jshell.main.class=jdk.internal.jshell.tool.JShellToolProvider #test configuration: jtreg.tests= diff --git a/langtools/make/build.xml b/langtools/make/build.xml index 864f2cbb90a..c39ff0e2761 100644 --- a/langtools/make/build.xml +++ b/langtools/make/build.xml @@ -89,16 +89,22 @@ - + + fs = project.getProperty("file.separator"); + path = project.getProperty("build.modules"); + mod = source.substr(source.lastIndexOf(fs)+1); + self.addMappedName(mod + "=\"" + path + fs + mod + "\""); + - + + fs = project.getProperty("file.separator"); + path = project.getProperty("build.modules"); + mod = source.substr(source.lastIndexOf(fs)+1); + self.addMappedName(mod + "=" + path + fs + mod); + @@ -341,7 +347,7 @@ - + @@ -360,7 +366,7 @@ failonerror="false" resultproperty="jtreg.@{name}.result" vmoptions="${coverage.options} @{extra.jvmargs} ${xpatch.noquotes.cmd}"> - + diff --git a/langtools/make/gendata/Gendata-jdk.compiler.gmk b/langtools/make/gendata/Gendata-jdk.compiler.gmk index ea7ba9bfff1..d37c94e70a4 100644 --- a/langtools/make/gendata/Gendata-jdk.compiler.gmk +++ b/langtools/make/gendata/Gendata-jdk.compiler.gmk @@ -25,10 +25,20 @@ include JarArchive.gmk include JavaCompilation.gmk +include Modules.gmk include SetupJavaCompilers.gmk ################################################################################ +# This is needed to properly setup DOCS_MODULES. +$(eval $(call ReadImportMetaData)) + +# Modules that should be visible for 9 - the documented modules: +CT_MODULES := $(DOCS_MODULES) + +# Get the complete module source path: +CT_MODULESOURCEPATH := $(call GetModuleSrcPath) + CT_DATA_DESCRIPTION ?= $(LANGTOOLS_TOPDIR)/make/data/symbols/symbols $(eval $(call SetupJavaCompilation, COMPILE_CREATE_SYMBOLS, \ @@ -41,6 +51,8 @@ $(eval $(call SetupJavaCompilation, COMPILE_CREATE_SYMBOLS, \ ifeq ($(BOOT_JDK_MODULAR), true) COMPILECREATESYMBOLS_ADD_EXPORTS := \ + --add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED \ + --add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED \ --add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED \ --add-exports=jdk.compiler/com.sun.tools.javac.jvm=ALL-UNNAMED \ --add-exports=jdk.jdeps/com.sun.tools.classfile=ALL-UNNAMED @@ -59,6 +71,14 @@ $(SUPPORT_OUTPUTDIR)/symbols/ct.sym-files/_the.symbols: \ build-ctsym \ $(CT_DATA_DESCRIPTION) \ $(@D) + $(MKDIR) $(@D)/9 + $(JAVA_SMALL) $(INTERIM_LANGTOOLS_ARGS) \ + $(COMPILECREATESYMBOLS_ADD_EXPORTS) \ + -classpath $(BUILDTOOLS_OUTPUTDIR)/create_symbols \ + build.tools.symbolgenerator.TransitiveDependencies \ + $(CT_MODULESOURCEPATH) \ + $(CT_MODULES) \ + >$(@D)/9/system-modules $(TOUCH) $@ # Can't generate ct.sym directly into modules libs as the SetupJarArchive macro @@ -66,7 +86,7 @@ $(SUPPORT_OUTPUTDIR)/symbols/ct.sym-files/_the.symbols: \ $(eval $(call SetupJarArchive, CREATE_CTSYM, \ DEPENDENCIES := $(SUPPORT_OUTPUTDIR)/symbols/ct.sym-files/_the.symbols, \ SRCS := $(SUPPORT_OUTPUTDIR)/symbols/ct.sym-files, \ - SUFFIXES := .sig, \ + SUFFIXES := .sig system-modules, \ JAR := $(SUPPORT_OUTPUTDIR)/symbols/ct.sym, \ )) diff --git a/langtools/make/intellij/runConfigurations/javadoc.xml b/langtools/make/intellij/runConfigurations/javadoc.xml index 9da56c34f10..4ca7b731c40 100644 --- a/langtools/make/intellij/runConfigurations/javadoc.xml +++ b/langtools/make/intellij/runConfigurations/javadoc.xml @@ -1,8 +1,8 @@ -
    * - *

    Migration Guide

    + *

    Migration Guide

    * *

    Many of the types in the old {@code com.sun.javadoc} API do not have equivalents in this * package. Instead, types in the {@code javax.lang.model} and {@code com.sun.source} APIs diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/api/JavadocTaskImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/api/JavadocTaskImpl.java index 42622c35630..91793289166 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/api/JavadocTaskImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/api/JavadocTaskImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,15 +25,20 @@ package jdk.javadoc.internal.api; +import java.util.ArrayList; import java.util.Collections; +import java.util.List; import java.util.Locale; +import java.util.Objects; import java.util.concurrent.atomic.AtomicBoolean; import javax.tools.DocumentationTool.DocumentationTask; import javax.tools.JavaFileObject; +import com.sun.tools.javac.main.Option; import com.sun.tools.javac.util.ClientCodeException; import com.sun.tools.javac.util.Context; +import com.sun.tools.javac.util.Options; import jdk.javadoc.internal.tool.Start; /** @@ -53,6 +58,7 @@ public class JavadocTaskImpl implements DocumentationTask { private Iterable options; private Iterable fileObjects; private Locale locale; + private List addModules = new ArrayList<>(); public JavadocTaskImpl(Context context, Class docletClass, Iterable options, Iterable fileObjects) { @@ -72,6 +78,16 @@ public class JavadocTaskImpl implements DocumentationTask { this.locale = locale; } + @Override + public void addModules(Iterable moduleNames) { + nullCheck(moduleNames); + if (used.get()) + throw new IllegalStateException(); + for (String name : moduleNames) { + addModules.add(name); + } + } + public Boolean call() { if (!used.getAndSet(true)) { initContext(); @@ -89,6 +105,12 @@ public class JavadocTaskImpl implements DocumentationTask { private void initContext() { //initialize compiler's default locale context.put(Locale.class, locale); + if (!addModules.isEmpty()) { + String names = String.join(",", addModules); + Options opts = Options.instance(context); + String prev = opts.get(Option.ADD_MODULES); + opts.put(Option.ADD_MODULES, (prev == null) ? names : prev + "," + names); + } } private static Iterable nullCheck(Iterable items) { diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractExecutableMemberWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractExecutableMemberWriter.java index 7ce394be641..c8d89e4a1c6 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractExecutableMemberWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractExecutableMemberWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -199,6 +199,7 @@ public abstract class AbstractExecutableMemberWriter extends AbstractMemberWrite */ protected void addParameters(ExecutableElement member, boolean includeAnnotations, Content htmltree, int indentSize) { + htmltree.addContent(Contents.ZERO_WIDTH_SPACE); htmltree.addContent("("); String sep = ""; List parameters = member.getParameters(); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractIndexWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractIndexWriter.java index fd7d811e142..2b06737c12e 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractIndexWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractIndexWriter.java @@ -79,7 +79,7 @@ public class AbstractIndexWriter extends HtmlDocletWriter { * @param path Path to the file which is getting generated. * @param indexbuilder Unicode based Index from {@link IndexBuilder} */ - protected AbstractIndexWriter(ConfigurationImpl configuration, + protected AbstractIndexWriter(HtmlConfiguration configuration, DocPath path, IndexBuilder indexbuilder) { super(configuration, path); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractMemberWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractMemberWriter.java index 3eefd0c0c48..3f73b6bdb71 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractMemberWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractMemberWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -66,7 +66,7 @@ import static javax.lang.model.element.Modifier.*; */ public abstract class AbstractMemberWriter { - protected final ConfigurationImpl configuration; + protected final HtmlConfiguration configuration; protected final Utils utils; protected final SubWriterHolderWriter writer; protected final Contents contents; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractModuleIndexWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractModuleIndexWriter.java index 4bdbfd70012..3f57cfe8885 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractModuleIndexWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractModuleIndexWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,7 @@ package jdk.javadoc.internal.doclets.formats.html; +import java.util.Collection; import java.util.Map; import java.util.Set; import java.util.SortedMap; @@ -66,7 +67,7 @@ public abstract class AbstractModuleIndexWriter extends HtmlDocletWriter { * @param configuration The current configuration * @param filename Name of the module index file to be generated. */ - public AbstractModuleIndexWriter(ConfigurationImpl configuration, + public AbstractModuleIndexWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); modules = configuration.modulePackages; @@ -101,7 +102,7 @@ public abstract class AbstractModuleIndexWriter extends HtmlDocletWriter { * @param tableSummary summary for the table * @param body the document tree to which the modules list will be added */ - protected abstract void addModulesList(Map> modules, String text, + protected abstract void addModulesList(Collection modules, String text, String tableSummary, Content body); /** @@ -173,7 +174,7 @@ public abstract class AbstractModuleIndexWriter extends HtmlDocletWriter { * @param body the document tree to which the index will be added */ protected void addIndex(Content body) { - addIndexContents(modules, "doclet.Module_Summary", + addIndexContents(configuration.modules, "doclet.Module_Summary", configuration.getText("doclet.Member_Table_Summary", configuration.getText("doclet.Module_Summary"), configuration.getText("doclet.modules")), body); @@ -201,7 +202,7 @@ public abstract class AbstractModuleIndexWriter extends HtmlDocletWriter { * @param tableSummary summary for the table * @param body the document tree to which the index contents will be added */ - protected void addIndexContents(Map> modules, String text, + protected void addIndexContents(Collection modules, String text, String tableSummary, Content body) { HtmlTree htmlTree = (configuration.allowTag(HtmlTag.NAV)) ? HtmlTree.NAV() diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractPackageIndexWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractPackageIndexWriter.java index 5b622355480..3faf2b1a188 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractPackageIndexWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractPackageIndexWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -64,7 +64,7 @@ public abstract class AbstractPackageIndexWriter extends HtmlDocletWriter { * @param configuration The current configuration * @param filename Name of the package index file to be generated. */ - public AbstractPackageIndexWriter(ConfigurationImpl configuration, + public AbstractPackageIndexWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); packages = configuration.packages; @@ -160,7 +160,7 @@ public abstract class AbstractPackageIndexWriter extends HtmlDocletWriter { htmlTree.addStyle(HtmlStyle.indexNav); HtmlTree ul = new HtmlTree(HtmlTag.UL); addAllClassesLink(ul); - if (configuration.showModules) { + if (configuration.showModules && configuration.modules.size() > 1) { addAllModulesLink(ul); } htmlTree.addContent(ul); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractTreeWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractTreeWriter.java index e0274248faf..ecf0bc7e207 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractTreeWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractTreeWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -66,7 +66,7 @@ public abstract class AbstractTreeWriter extends HtmlDocletWriter { * @param filename File to be generated. * @param classtree Tree built by {@link ClassTree}. */ - protected AbstractTreeWriter(ConfigurationImpl configuration, + protected AbstractTreeWriter(HtmlConfiguration configuration, DocPath filename, ClassTree classtree) { super(configuration, filename); this.classtree = classtree; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AllClassesFrameWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AllClassesFrameWriter.java index 47351de8004..d48e2b497ab 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AllClassesFrameWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AllClassesFrameWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -74,7 +74,7 @@ public class AllClassesFrameWriter extends HtmlDocletWriter { * @param filename Path to the file which is getting generated. * @param indexbuilder Unicode based Index from {@link IndexBuilder} */ - public AllClassesFrameWriter(ConfigurationImpl configuration, + public AllClassesFrameWriter(HtmlConfiguration configuration, DocPath filename, IndexBuilder indexbuilder) { super(configuration, filename); this.indexbuilder = indexbuilder; @@ -88,7 +88,7 @@ public class AllClassesFrameWriter extends HtmlDocletWriter { * @param indexBuilder IndexBuilder object for all classes index. * @throws DocFileIOException */ - public static void generate(ConfigurationImpl configuration, + public static void generate(HtmlConfiguration configuration, IndexBuilder indexBuilder) throws DocFileIOException { if (configuration.frames) { generate(configuration, indexBuilder, DocPaths.ALLCLASSES_FRAME, true); @@ -98,8 +98,8 @@ public class AllClassesFrameWriter extends HtmlDocletWriter { } } - private static void generate(ConfigurationImpl configuration, IndexBuilder indexBuilder, - DocPath fileName, boolean wantFrames) throws DocFileIOException { + private static void generate(HtmlConfiguration configuration, IndexBuilder indexBuilder, + DocPath fileName, boolean wantFrames) throws DocFileIOException { AllClassesFrameWriter allclassgen = new AllClassesFrameWriter(configuration, fileName, indexBuilder); allclassgen.buildAllClassesFile(wantFrames); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeWriterImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeWriterImpl.java index 5be296e2dd1..45f5de1997d 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeWriterImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeWriterImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,6 +27,7 @@ package jdk.javadoc.internal.doclets.formats.html; import java.util.List; +import javax.lang.model.element.ModuleElement; import javax.lang.model.element.PackageElement; import javax.lang.model.element.TypeElement; import javax.lang.model.type.TypeMirror; @@ -78,7 +79,7 @@ public class AnnotationTypeWriterImpl extends SubWriterHolderWriter * @param prevType the previous class that was documented. * @param nextType the next class being documented. */ - public AnnotationTypeWriterImpl(ConfigurationImpl configuration, + public AnnotationTypeWriterImpl(HtmlConfiguration configuration, TypeElement annotationType, TypeMirror prevType, TypeMirror nextType) { super(configuration, DocPath.forClass(configuration.utils, annotationType)); this.annotationType = annotationType; @@ -191,10 +192,21 @@ public class AnnotationTypeWriterImpl extends SubWriterHolderWriter bodyTree.addContent(HtmlConstants.START_OF_CLASS_DATA); HtmlTree div = new HtmlTree(HtmlTag.DIV); div.addStyle(HtmlStyle.header); + if (configuration.showModules) { + ModuleElement mdle = configuration.docEnv.getElementUtils().getModuleOf(annotationType); + Content typeModuleLabel = HtmlTree.SPAN(HtmlStyle.moduleLabelInType, contents.moduleLabel); + Content moduleNameDiv = HtmlTree.DIV(HtmlStyle.subTitle, typeModuleLabel); + moduleNameDiv.addContent(Contents.SPACE); + moduleNameDiv.addContent(getModuleLink(mdle, new StringContent(mdle.getQualifiedName()))); + div.addContent(moduleNameDiv); + } PackageElement pkg = utils.containingPackage(annotationType); if (!pkg.isUnnamed()) { - Content pkgNameContent = new StringContent(utils.getPackageName(pkg)); - Content pkgNameDiv = HtmlTree.DIV(HtmlStyle.subTitle, pkgNameContent); + Content typePackageLabel = HtmlTree.SPAN(HtmlStyle.packageLabelInType, contents.packageLabel); + Content pkgNameDiv = HtmlTree.DIV(HtmlStyle.subTitle, typePackageLabel); + pkgNameDiv.addContent(Contents.SPACE); + Content pkgNameContent = getPackageLink(pkg, new StringContent(utils.getPackageName(pkg))); + pkgNameDiv.addContent(pkgNameContent); div.addContent(pkgNameDiv); } LinkInfoImpl linkInfo = new LinkInfoImpl(configuration, diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassUseWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassUseWriter.java index 97cb1032a0b..4813dbc1fb9 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassUseWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassUseWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -112,7 +112,7 @@ public class ClassUseWriter extends SubWriterHolderWriter { * * @param filename the file to be generated. */ - public ClassUseWriter(ConfigurationImpl configuration, + public ClassUseWriter(HtmlConfiguration configuration, ClassUseMapper mapper, DocPath filename, TypeElement typeElement) { super(configuration, filename); @@ -177,7 +177,7 @@ public class ClassUseWriter extends SubWriterHolderWriter { * @param classtree the class tree hierarchy * @throws DocFileIOException if there is an error while generating the documentation */ - public static void generate(ConfigurationImpl configuration, ClassTree classtree) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration, ClassTree classtree) throws DocFileIOException { ClassUseMapper mapper = new ClassUseMapper(configuration, classtree); for (TypeElement aClass : configuration.getIncludedTypeElements()) { // If -nodeprecated option is set and the containing package is marked @@ -220,7 +220,7 @@ public class ClassUseWriter extends SubWriterHolderWriter { * * @throws DocFileIOException if there is a problem while generating the documentation */ - public static void generate(ConfigurationImpl configuration, ClassUseMapper mapper, + public static void generate(HtmlConfiguration configuration, ClassUseMapper mapper, TypeElement typeElement) throws DocFileIOException { ClassUseWriter clsgen; DocPath path = DocPath.forPackage(configuration.utils, typeElement) diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassWriterImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassWriterImpl.java index 85b2f3f2133..cbb0bfb590d 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassWriterImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassWriterImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -89,8 +89,8 @@ public class ClassWriterImpl extends SubWriterHolderWriter implements ClassWrite * @param nextClass the next class being documented. * @param classTree the class tree for the given class. */ - public ClassWriterImpl(ConfigurationImpl configuration, TypeElement typeElement, - TypeElement prevClass, TypeElement nextClass, ClassTree classTree) { + public ClassWriterImpl(HtmlConfiguration configuration, TypeElement typeElement, + TypeElement prevClass, TypeElement nextClass, ClassTree classTree) { super(configuration, DocPath.forClass(configuration.utils, typeElement)); this.typeElement = typeElement; configuration.currentTypeElement = typeElement; @@ -205,7 +205,7 @@ public class ClassWriterImpl extends SubWriterHolderWriter implements ClassWrite div.addStyle(HtmlStyle.header); if (configuration.showModules) { ModuleElement mdle = configuration.docEnv.getElementUtils().getModuleOf(typeElement); - Content classModuleLabel = HtmlTree.SPAN(HtmlStyle.moduleLabelInClass, contents.moduleLabel); + Content classModuleLabel = HtmlTree.SPAN(HtmlStyle.moduleLabelInType, contents.moduleLabel); Content moduleNameDiv = HtmlTree.DIV(HtmlStyle.subTitle, classModuleLabel); moduleNameDiv.addContent(Contents.SPACE); moduleNameDiv.addContent(getModuleLink(mdle, @@ -214,7 +214,7 @@ public class ClassWriterImpl extends SubWriterHolderWriter implements ClassWrite } PackageElement pkg = utils.containingPackage(typeElement); if (!pkg.isUnnamed()) { - Content classPackageLabel = HtmlTree.SPAN(HtmlStyle.packageLabelInClass, contents.packageLabel); + Content classPackageLabel = HtmlTree.SPAN(HtmlStyle.packageLabelInType, contents.packageLabel); Content pkgNameDiv = HtmlTree.DIV(HtmlStyle.subTitle, classPackageLabel); pkgNameDiv.addContent(Contents.SPACE); Content pkgNameContent = getPackageLink(pkg, diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstantsSummaryWriterImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstantsSummaryWriterImpl.java index 887d46fe868..dfa04ab89fe 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstantsSummaryWriterImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstantsSummaryWriterImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -61,7 +61,7 @@ public class ConstantsSummaryWriterImpl extends HtmlDocletWriter implements Cons /** * The configuration used in this run of the standard doclet. */ - ConfigurationImpl configuration; + HtmlConfiguration configuration; /** * The current class being documented. @@ -87,7 +87,7 @@ public class ConstantsSummaryWriterImpl extends HtmlDocletWriter implements Cons * @param configuration the configuration used in this run * of the standard doclet. */ - public ConstantsSummaryWriterImpl(ConfigurationImpl configuration) { + public ConstantsSummaryWriterImpl(HtmlConfiguration configuration) { super(configuration, DocPaths.CONSTANT_VALUES); this.configuration = configuration; constantsTableSummary = configuration.getText("doclet.Constants_Table_Summary", diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstructorWriterImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstructorWriterImpl.java index 612c2e0db06..9a4eb9f8a52 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstructorWriterImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstructorWriterImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -69,9 +69,9 @@ public class ConstructorWriterImpl extends AbstractExecutableMemberWriter public ConstructorWriterImpl(SubWriterHolderWriter writer, TypeElement typeElement) { super(writer, typeElement); - VisibleMemberMap visibleMemberMap = new VisibleMemberMap( + VisibleMemberMap visibleMemberMap = configuration.getVisibleMemberMap( typeElement, - VisibleMemberMap.Kind.CONSTRUCTORS, configuration); + VisibleMemberMap.Kind.CONSTRUCTORS); List constructors = visibleMemberMap.getMembers(typeElement); for (Element constructor : constructors) { if (utils.isProtected(constructor) || utils.isPrivate(constructor)) { @@ -169,11 +169,7 @@ public class ConstructorWriterImpl extends AbstractExecutableMemberWriter */ @Override public void setSummaryColumnStyleAndScope(HtmlTree thTree) { - if (foundNonPubConstructor) { - thTree.addStyle(HtmlStyle.colSecond); - } else { - thTree.addStyle(HtmlStyle.colFirst); - } + thTree.addStyle(HtmlStyle.colConstructorName); thTree.addAttr(HtmlAttr.SCOPE, "row"); } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/Contents.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/Contents.java index 0ed12a6216b..dc59ec5fb6d 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/Contents.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/Contents.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -48,6 +48,7 @@ import jdk.javadoc.internal.doclets.toolkit.util.DocletConstants; */ public class Contents { public static final Content SPACE = RawHtml.nbsp; + public static final Content ZERO_WIDTH_SPACE = RawHtml.zws; public final Content allClassesLabel; public final Content allImplementedInterfacesLabel; @@ -129,6 +130,7 @@ public class Contents { public final Content nextPackageLabel; public final Content noFramesLabel; public final Content noScriptMessage; + public final Content openModuleLabel; public final Content overridesLabel; public final Content overviewLabel; public final Content packageHierarchies; @@ -160,7 +162,7 @@ public class Contents { * @param configuration the configuration in which to find the * resources used to look up resource keys, and other details. */ - Contents(ConfigurationImpl configuration) { + Contents(HtmlConfiguration configuration) { this.resources = configuration.getResources(); allClassesLabel = getNonBreakContent("doclet.All_Classes"); @@ -243,6 +245,7 @@ public class Contents { nextPackageLabel = getNonBreakContent("doclet.Next_Package"); noFramesLabel = getNonBreakContent("doclet.No_Frames"); noScriptMessage = getContent("doclet.No_Script_Message"); + openModuleLabel = getContent("doclet.Open_Module"); overridesLabel = getContent("doclet.Overrides"); overviewLabel = getContent("doclet.Overview"); packageHierarchies = getContent("doclet.Package_Hierarchies"); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DeprecatedListWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DeprecatedListWriter.java index 21077435f1b..343224d4bdc 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DeprecatedListWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DeprecatedListWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -204,7 +204,7 @@ public class DeprecatedListWriter extends SubWriterHolderWriter { private EnumMap writerMap; - private ConfigurationImpl configuration; + private HtmlConfiguration configuration; /** * Constructor. @@ -213,7 +213,7 @@ public class DeprecatedListWriter extends SubWriterHolderWriter { * @param filename the file to be generated */ - public DeprecatedListWriter(ConfigurationImpl configuration, DocPath filename) { + public DeprecatedListWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); this.configuration = configuration; NestedClassWriterImpl classW = new NestedClassWriterImpl(this); @@ -260,7 +260,7 @@ public class DeprecatedListWriter extends SubWriterHolderWriter { * @param configuration the current configuration of the doclet. * @throws DocFileIOException if there is a problem writing the deprecated list */ - public static void generate(ConfigurationImpl configuration) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration) throws DocFileIOException { DocPath filename = DocPaths.DEPRECATED_LIST; DeprecatedListWriter depr = new DeprecatedListWriter(configuration, filename); depr.generateDeprecatedListFile( diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/FrameOutputWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/FrameOutputWriter.java index de340fe3e1f..21027c42f05 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/FrameOutputWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/FrameOutputWriter.java @@ -67,7 +67,7 @@ public class FrameOutputWriter extends HtmlDocletWriter { * @param configuration for this run * @param filename File to be generated. */ - public FrameOutputWriter(ConfigurationImpl configuration, DocPath filename) { + public FrameOutputWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); noOfPackages = configuration.packages.size(); } @@ -80,7 +80,7 @@ public class FrameOutputWriter extends HtmlDocletWriter { * @param configuration the configuration for this doclet * @throws DocFileIOException if there is a problem generating the frame file */ - public static void generate(ConfigurationImpl configuration) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration) throws DocFileIOException { FrameOutputWriter framegen = new FrameOutputWriter(configuration, DocPaths.INDEX); framegen.generateFrameFile(); } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HelpWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HelpWriter.java index 686179c577f..370584048b2 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HelpWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HelpWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -55,7 +55,7 @@ public class HelpWriter extends HtmlDocletWriter { * Constructor to construct HelpWriter object. * @param filename File to be generated. */ - public HelpWriter(ConfigurationImpl configuration, + public HelpWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); } @@ -68,7 +68,7 @@ public class HelpWriter extends HtmlDocletWriter { * * @throws DocFileIOException if there is a problem while generating the documentation */ - public static void generate(ConfigurationImpl configuration) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration) throws DocFileIOException { DocPath filename = DocPaths.HELP_DOC; HelpWriter helpgen = new HelpWriter(configuration, filename); helpgen.generateHelpFile(); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConfigurationImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlConfiguration.java similarity index 98% rename from langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConfigurationImpl.java rename to langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlConfiguration.java index 9543b1afbbd..6090ff9d46d 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConfigurationImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,7 +42,7 @@ import jdk.javadoc.doclet.Doclet; import jdk.javadoc.doclet.DocletEnvironment; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlVersion; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.Messages; import jdk.javadoc.internal.doclets.toolkit.Resources; @@ -77,7 +77,7 @@ import static javax.tools.Diagnostic.Kind.*; * @author Jamie Ho * @author Bhavesh Patel (Modified) */ -public class ConfigurationImpl extends Configuration { +public class HtmlConfiguration extends BaseConfiguration { /** * The build date. Note: For now, we will use @@ -240,9 +240,10 @@ public class ConfigurationImpl extends Configuration { * Constructor. Initializes resource for the * {@link com.sun.tools.doclets.internal.toolkit.util.MessageRetriever MessageRetriever}. */ - public ConfigurationImpl() { + public HtmlConfiguration(Doclet doclet) { + super(doclet); resources = new Resources(this, - Configuration.sharedResourceBundleName, + BaseConfiguration.sharedResourceBundleName, "jdk.javadoc.internal.doclets.formats.html.resources.standard"); messages = new Messages(this); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDoclet.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDoclet.java index d8f52ae6c12..d125f395238 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDoclet.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDoclet.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,6 @@ import javax.lang.model.element.ModuleElement; import javax.lang.model.element.PackageElement; import javax.lang.model.element.TypeElement; -import jdk.javadoc.doclet.Doclet.Option; import jdk.javadoc.doclet.DocletEnvironment; import jdk.javadoc.doclet.Reporter; import jdk.javadoc.internal.doclets.toolkit.AbstractDoclet; @@ -61,7 +60,7 @@ import jdk.javadoc.internal.doclets.toolkit.util.IndexBuilder; public class HtmlDoclet extends AbstractDoclet { public HtmlDoclet() { - configuration = new ConfigurationImpl(); + configuration = new HtmlConfiguration(this); } @Override // defined by Doclet @@ -72,7 +71,7 @@ public class HtmlDoclet extends AbstractDoclet { /** * The global configuration information for this run. */ - private final ConfigurationImpl configuration; + private final HtmlConfiguration configuration; private Messages messages; @@ -95,7 +94,7 @@ public class HtmlDoclet extends AbstractDoclet { * @return the configuration */ @Override // defined by AbstractDoclet - public ConfigurationImpl getConfiguration() { + public HtmlConfiguration getConfiguration() { return configuration; } @@ -271,14 +270,14 @@ public class HtmlDoclet extends AbstractDoclet { @Override // defined by AbstractDoclet protected void generateModuleFiles() throws DocletException { if (configuration.showModules) { - if (configuration.frames) { + if (configuration.frames && configuration.modules.size() > 1) { ModuleIndexFrameWriter.generate(configuration); } ModuleElement prevModule = null, nextModule; List mdles = new ArrayList<>(configuration.modulePackages.keySet()); int i = 0; for (ModuleElement mdle : mdles) { - if (configuration.frames) { + if (configuration.frames && configuration.modules.size() > 1) { ModulePackageIndexFrameWriter.generate(configuration, mdle); ModuleFrameWriter.generate(configuration, mdle); } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java index 432806b8844..9dbcff1bf8b 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -77,7 +77,7 @@ import jdk.javadoc.internal.doclets.formats.html.markup.RawHtml; import jdk.javadoc.internal.doclets.formats.html.markup.StringContent; import jdk.javadoc.internal.doclets.toolkit.AnnotationTypeWriter; import jdk.javadoc.internal.doclets.toolkit.ClassWriter; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.Messages; import jdk.javadoc.internal.doclets.toolkit.PackageSummaryWriter; @@ -94,9 +94,7 @@ import jdk.javadoc.internal.doclets.toolkit.util.DocletConstants; import jdk.javadoc.internal.doclets.toolkit.util.ImplementedMethods; import jdk.javadoc.internal.doclets.toolkit.util.Utils; -import static com.sun.source.doctree.AttributeTree.ValueKind.*; import static com.sun.source.doctree.DocTree.Kind.*; -import static jdk.javadoc.internal.doclets.formats.html.markup.HtmlDocWriter.CONTENT_TYPE; import static jdk.javadoc.internal.doclets.toolkit.util.CommentHelper.SPACER; @@ -141,7 +139,7 @@ public class HtmlDocletWriter extends HtmlDocWriter { /** * The global configuration information for this run. */ - public final ConfigurationImpl configuration; + public final HtmlConfiguration configuration; protected final Utils utils; @@ -180,7 +178,7 @@ public class HtmlDocletWriter extends HtmlDocWriter { * * @param path File to be generated. */ - public HtmlDocletWriter(ConfigurationImpl configuration, DocPath path) { + public HtmlDocletWriter(HtmlConfiguration configuration, DocPath path) { super(configuration, path); this.configuration = configuration; this.contents = configuration.contents; @@ -647,6 +645,13 @@ public class HtmlDocletWriter extends HtmlDocWriter { tree.addContent(fixedNavDiv); HtmlTree paddingDiv = HtmlTree.DIV(HtmlStyle.navPadding, Contents.SPACE); tree.addContent(paddingDiv); + HtmlTree scriptTree = HtmlTree.SCRIPT(); + String scriptCode = "\n"; + RawHtml scriptContent = new RawHtml(scriptCode.replace("\n", DocletConstants.NL)); + scriptTree.addContent(scriptContent); + tree.addContent(scriptTree); } else { subDiv.addContent(getMarkerAnchor(SectionName.SKIP_NAVBAR_BOTTOM)); tree.addContent(subDiv); @@ -2594,7 +2599,7 @@ public class HtmlDocletWriter extends HtmlDocWriter { * @return the configuration for this doclet. */ @Override - public Configuration configuration() { + public BaseConfiguration configuration() { return configuration; } } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/IndexRedirectWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/IndexRedirectWriter.java index 53a341b6875..e5eeaec06ff 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/IndexRedirectWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/IndexRedirectWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -39,8 +39,6 @@ import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException; import jdk.javadoc.internal.doclets.toolkit.util.DocPath; import jdk.javadoc.internal.doclets.toolkit.util.DocPaths; -import static jdk.javadoc.internal.doclets.formats.html.markup.HtmlDocWriter.CONTENT_TYPE; - /** * Writes an index.html file that tries to redirect to an alternate page. * The redirect uses JavaSCript, if enabled, falling back on @@ -50,7 +48,7 @@ import static jdk.javadoc.internal.doclets.formats.html.markup.HtmlDocWriter.CON */ public class IndexRedirectWriter extends HtmlDocletWriter { - public static void generate(ConfigurationImpl configuration) + public static void generate(HtmlConfiguration configuration) throws DocFileIOException { IndexRedirectWriter indexRedirect; DocPath filename = DocPaths.INDEX; @@ -58,7 +56,7 @@ public class IndexRedirectWriter extends HtmlDocletWriter { indexRedirect.generateIndexFile(); } - IndexRedirectWriter(ConfigurationImpl configuration, DocPath filename) { + IndexRedirectWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkFactoryImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkFactoryImpl.java index dbb476920be..03239fec947 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkFactoryImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkFactoryImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,15 +33,13 @@ import javax.lang.model.element.TypeElement; import javax.lang.model.type.TypeMirror; import jdk.javadoc.internal.doclets.formats.html.markup.ContentBuilder; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.util.DocPath; import jdk.javadoc.internal.doclets.toolkit.util.Utils; import jdk.javadoc.internal.doclets.toolkit.util.links.LinkFactory; import jdk.javadoc.internal.doclets.toolkit.util.links.LinkInfo; -import static jdk.javadoc.internal.doclets.formats.html.LinkInfoImpl.Kind.MEMBER_TYPE_PARAMS; - /** * A factory that returns a link given the information about it. * @@ -73,7 +71,7 @@ public class LinkFactoryImpl extends LinkFactory { */ @Override protected Content getClassLink(LinkInfo linkInfo) { - Configuration configuration = m_writer.configuration; + BaseConfiguration configuration = m_writer.configuration; Utils utils = configuration.utils; LinkInfoImpl classLinkInfo = (LinkInfoImpl) linkInfo; boolean noLabel = linkInfo.label == null || linkInfo.label.isEmpty(); @@ -198,7 +196,7 @@ public class LinkFactoryImpl extends LinkFactory { * @return the tool tip for the appropriate class. */ private String getClassToolTip(TypeElement typeElement, boolean isTypeLink) { - Configuration configuration = m_writer.configuration; + BaseConfiguration configuration = m_writer.configuration; Utils utils = configuration.utils; if (isTypeLink) { return configuration.getText("doclet.Href_Type_Param_Title", diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkInfoImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkInfoImpl.java index 30801a6bbc9..a76551c1c16 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkInfoImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkInfoImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -218,7 +218,7 @@ public class LinkInfoImpl extends LinkInfo { RECEIVER_TYPE } - public final ConfigurationImpl configuration; + public final HtmlConfiguration configuration; /** * The location of the link. @@ -247,7 +247,7 @@ public class LinkInfoImpl extends LinkInfo { * @param context the context of the link. * @param ee the member to link to. */ - public LinkInfoImpl(ConfigurationImpl configuration, Kind context, ExecutableElement ee) { + public LinkInfoImpl(HtmlConfiguration configuration, Kind context, ExecutableElement ee) { this.configuration = configuration; this.utils = configuration.utils; this.executableElement = ee; @@ -269,7 +269,7 @@ public class LinkInfoImpl extends LinkInfo { * @param context the context of the link. * @param typeElement the class to link to. */ - public LinkInfoImpl(ConfigurationImpl configuration, Kind context, TypeElement typeElement) { + public LinkInfoImpl(HtmlConfiguration configuration, Kind context, TypeElement typeElement) { this.configuration = configuration; this.utils = configuration.utils; this.typeElement = typeElement; @@ -283,7 +283,7 @@ public class LinkInfoImpl extends LinkInfo { * @param context the context of the link. * @param type the class to link to. */ - public LinkInfoImpl(ConfigurationImpl configuration, Kind context, TypeMirror type) { + public LinkInfoImpl(HtmlConfiguration configuration, Kind context, TypeMirror type) { this.configuration = configuration; this.utils = configuration.utils; this.type = type; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleFrameWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleFrameWriter.java index eba6062dbc5..dd4503d9e86 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleFrameWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleFrameWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,7 +32,6 @@ import javax.lang.model.element.PackageElement; import javax.lang.model.element.TypeElement; import javax.lang.model.util.ElementFilter; -import jdk.javadoc.doclet.DocletEnvironment; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlConstants; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag; @@ -75,7 +74,7 @@ public class ModuleFrameWriter extends HtmlDocletWriter { * @param configuration the configuration of the doclet. * @param moduleElement moduleElement under consideration. */ - public ModuleFrameWriter(ConfigurationImpl configuration, ModuleElement moduleElement) { + public ModuleFrameWriter(HtmlConfiguration configuration, ModuleElement moduleElement) { super(configuration, DocPaths.moduleTypeFrame(moduleElement)); this.mdle = moduleElement; if (configuration.getSpecifiedPackageElements().isEmpty()) { @@ -91,7 +90,7 @@ public class ModuleFrameWriter extends HtmlDocletWriter { * @param moduleElement The package for which "module_name-type-frame.html" is to be generated. * @throws DocFileIOException if there is a problem generating the module summary file */ - public static void generate(ConfigurationImpl configuration, ModuleElement moduleElement) + public static void generate(HtmlConfiguration configuration, ModuleElement moduleElement) throws DocFileIOException { ModuleFrameWriter mdlgen = new ModuleFrameWriter(configuration, moduleElement); String mdlName = moduleElement.getQualifiedName().toString(); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexFrameWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexFrameWriter.java index 592c2c496c7..c856609f891 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexFrameWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexFrameWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,7 @@ package jdk.javadoc.internal.doclets.formats.html; +import java.util.Collection; import java.util.Map; import java.util.Set; @@ -62,7 +63,7 @@ public class ModuleIndexFrameWriter extends AbstractModuleIndexWriter { * @param configuration the configuration object * @param filename Name of the module index file to be generated. */ - public ModuleIndexFrameWriter(ConfigurationImpl configuration, + public ModuleIndexFrameWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); } @@ -72,7 +73,7 @@ public class ModuleIndexFrameWriter extends AbstractModuleIndexWriter { * @throws DocFileIOException * @param configuration the configuration object */ - public static void generate(ConfigurationImpl configuration) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration) throws DocFileIOException { DocPath filename = DocPaths.MODULE_OVERVIEW_FRAME; ModuleIndexFrameWriter modulegen = new ModuleIndexFrameWriter(configuration, filename); modulegen.buildModuleIndexFile("doclet.Window_Overview", false); @@ -81,7 +82,7 @@ public class ModuleIndexFrameWriter extends AbstractModuleIndexWriter { /** * {@inheritDoc} */ - protected void addModulesList(Map> modules, String text, + protected void addModulesList(Collection modules, String text, String tableSummary, Content body) { Content heading = HtmlTree.HEADING(HtmlConstants.MODULE_HEADING, true, contents.modulesLabel); @@ -90,7 +91,7 @@ public class ModuleIndexFrameWriter extends AbstractModuleIndexWriter { : HtmlTree.DIV(HtmlStyle.indexContainer, heading); HtmlTree ul = new HtmlTree(HtmlTag.UL); ul.setTitle(contents.modulesLabel); - for (ModuleElement mdle: modules.keySet()) { + for (ModuleElement mdle: modules) { ul.addContent(getModuleLink(mdle)); } htmlTree.addContent(ul); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexWriter.java index 2d8317780a3..255bcef04ea 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ import java.util.*; import javax.lang.model.element.ModuleElement; import javax.lang.model.element.PackageElement; -import jdk.javadoc.internal.doclets.formats.html.markup.ContentBuilder; +import jdk.javadoc.internal.doclets.formats.html.markup.HtmlConstants; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTree; @@ -56,11 +56,16 @@ import jdk.javadoc.internal.doclets.toolkit.util.Group; public class ModuleIndexWriter extends AbstractModuleIndexWriter { /** - * Set representing the modules. + * Map representing the group of modules as specified on the command line. * * @see Group */ - private final SortedSet modules; + private final Map> groupModuleMap; + + /** + * List to store the order groups as specified on the command line. + */ + private final List groupList; /** * HTML tree for main tag. @@ -72,9 +77,10 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { * @param configuration the configuration object * @param filename the name of the generated file */ - public ModuleIndexWriter(ConfigurationImpl configuration, DocPath filename) { + public ModuleIndexWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); - modules = configuration.modules; + groupModuleMap = configuration.group.groupModules(configuration.modules); + groupList = configuration.group.getGroupList(); } /** @@ -83,7 +89,7 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { * @param configuration the current configuration of the doclet. * @throws DocFileIOException if there is a problem generating the module index page */ - public static void generate(ConfigurationImpl configuration) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration) throws DocFileIOException { DocPath filename = DocPaths.overviewSummary(configuration.frames); ModuleIndexWriter mdlgen = new ModuleIndexWriter(configuration, filename); mdlgen.buildModuleIndexFile("doclet.Window_Overview_Summary", true); @@ -96,11 +102,13 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { */ @Override protected void addIndex(Content body) { - if (modules != null && !modules.isEmpty()) { - addIndexContents(configuration.getText("doclet.Modules"), - configuration.getText("doclet.Member_Table_Summary", - configuration.getText("doclet.Module_Summary"), - configuration.getText("doclet.modules")), body); + for (String groupname : groupList) { + SortedSet list = groupModuleMap.get(groupname); + if (list != null && !list.isEmpty()) { + addIndexContents(list, + groupname, configuration.getText("doclet.Member_Table_Summary", + groupname, configuration.getText("doclet.modules")), body); + } } } @@ -111,7 +119,7 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { * @param tableSummary summary for the table * @param body the document tree to which the index contents will be added */ - protected void addIndexContents(String title, String tableSummary, Content body) { + protected void addIndexContents(Collection modules, String title, String tableSummary, Content body) { HtmlTree htmltree = (configuration.allowTag(HtmlTag.NAV)) ? HtmlTree.NAV() : new HtmlTree(HtmlTag.DIV); @@ -123,7 +131,7 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { } htmltree.addContent(ul); body.addContent(htmltree); - addModulesList(title, tableSummary, body); + addModulesList(modules, title, tableSummary, body); } /** @@ -133,15 +141,17 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { * @param tableSummary the summary of the table tag * @param body the content tree to which the module list will be added */ - protected void addModulesList(String text, String tableSummary, Content body) { + protected void addModulesList(Collection modules, String text, String tableSummary, Content body) { Content table = (configuration.isOutputHtml5()) ? HtmlTree.TABLE(HtmlStyle.overviewSummary, getTableCaption(new RawHtml(text))) : HtmlTree.TABLE(HtmlStyle.overviewSummary, tableSummary, getTableCaption(new RawHtml(text))); table.addContent(getSummaryTableHeader(moduleTableHeader, "col")); Content tbody = new HtmlTree(HtmlTag.TBODY); - addModulesList(tbody); + addModulesList(modules, tbody); table.addContent(tbody); - Content div = HtmlTree.DIV(HtmlStyle.contentContainer, table); + Content anchor = getMarkerAnchor(text); + Content div = HtmlTree.DIV(HtmlStyle.contentContainer, anchor); + div.addContent(table); if (configuration.allowTag(HtmlTag.MAIN)) { htmlTree.addContent(div); } else { @@ -154,7 +164,7 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { * * @param tbody the documentation tree to which the list will be added */ - protected void addModulesList(Content tbody) { + protected void addModulesList(Collection modules, Content tbody) { boolean altColor = true; for (ModuleElement mdle : modules) { if (!mdle.isUnnamed()) { @@ -183,19 +193,9 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { protected void addOverviewHeader(Content body) { addConfigurationTitle(body); if (!utils.getFullBody(configuration.overviewElement).isEmpty()) { - HtmlTree subTitleDiv = new HtmlTree(HtmlTag.DIV); - subTitleDiv.addStyle(HtmlStyle.subTitle); - addSummaryComment(configuration.overviewElement, subTitleDiv); - Content div = HtmlTree.DIV(HtmlStyle.header, subTitleDiv); - Content see = new ContentBuilder(); - see.addContent(contents.seeLabel); - see.addContent(" "); - Content descPara = HtmlTree.P(see); - Content descLink = getHyperLink(getDocLink( - SectionName.OVERVIEW_DESCRIPTION), - contents.descriptionLabel, "", ""); - descPara.addContent(descLink); - div.addContent(descPara); + HtmlTree div = new HtmlTree(HtmlTag.DIV); + div.addStyle(HtmlStyle.contentContainer); + addOverviewComment(div); if (configuration.allowTag(HtmlTag.MAIN)) { htmlTree.addContent(div); } else { @@ -213,27 +213,19 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { */ protected void addOverviewComment(Content htmltree) { if (!utils.getFullBody(configuration.overviewElement).isEmpty()) { - htmltree.addContent(getMarkerAnchor(SectionName.OVERVIEW_DESCRIPTION)); addInlineComment(configuration.overviewElement, htmltree); } } /** - * Adds the tag information as provided in the file specified by the - * "-overview" option on the command line. + * For HTML 5, add the htmlTree to the body. For HTML 4, do nothing. * * @param body the documentation tree to which the overview will be added */ @Override protected void addOverview(Content body) { - HtmlTree div = new HtmlTree(HtmlTag.DIV); - div.addStyle(HtmlStyle.contentContainer); - addOverviewComment(div); if (configuration.allowTag(HtmlTag.MAIN)) { - htmlTree.addContent(div); body.addContent(htmlTree); - } else { - body.addContent(div); } } @@ -278,9 +270,4 @@ public class ModuleIndexWriter extends AbstractModuleIndexWriter { protected void addModulePackagesList(Map> modules, String text, String tableSummary, Content body, ModuleElement mdle) { } - - @Override - protected void addModulesList(Map> modules, String text, - String tableSummary, Content body) { - } } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModulePackageIndexFrameWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModulePackageIndexFrameWriter.java index 28275956185..436a104be55 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModulePackageIndexFrameWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModulePackageIndexFrameWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,7 @@ package jdk.javadoc.internal.doclets.formats.html; import java.util.ArrayList; +import java.util.Collection; import java.util.List; import java.util.Map; import java.util.Set; @@ -64,7 +65,7 @@ public class ModulePackageIndexFrameWriter extends AbstractModuleIndexWriter { * @param configuration the configuration object * @param filename Name of the package index file to be generated. */ - public ModulePackageIndexFrameWriter(ConfigurationImpl configuration, DocPath filename) { + public ModulePackageIndexFrameWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); } @@ -74,7 +75,7 @@ public class ModulePackageIndexFrameWriter extends AbstractModuleIndexWriter { * @param configuration the configuration object * @param mdle the module being documented */ - public static void generate(ConfigurationImpl configuration, ModuleElement mdle) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration, ModuleElement mdle) throws DocFileIOException { DocPath filename = DocPaths.moduleFrame(mdle); ModulePackageIndexFrameWriter modpackgen = new ModulePackageIndexFrameWriter(configuration, filename); modpackgen.buildModulePackagesIndexFile("doclet.Window_Overview", false, mdle); @@ -175,7 +176,7 @@ public class ModulePackageIndexFrameWriter extends AbstractModuleIndexWriter { protected void addOverviewHeader(Content body) { } - protected void addModulesList(Map> modules, String text, + protected void addModulesList(Collection modules, String text, String tableSummary, Content body) { } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleWriterImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleWriterImpl.java index 16d7250557e..fb855bcda92 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleWriterImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleWriterImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,6 +25,7 @@ package jdk.javadoc.internal.doclets.formats.html; +import java.util.Collections; import java.util.EnumSet; import java.util.LinkedHashMap; import java.util.List; @@ -97,19 +98,19 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW = new TreeMap<>(utils.makeModuleComparator()); /** - * Map of additional modules and modifiers, transitive closure, required by this module. + * Map of indirect modules and modifiers, transitive closure, required by this module. */ - private final Map additionalModules + private final Map indirectModules = new TreeMap<>(utils.makeModuleComparator()); /** - * Map of packages exported by this module and the modules it's been exported to. + * Map of packages exported by this module and the modules it has been exported to. */ private final Map> exportedPackages = new TreeMap<>(utils.makePackageComparator()); /** - * Map of opened packages by this module and the modules it's been opened to. + * Map of opened packages by this module and the modules it has been opened to. */ private final Map> openedPackages = new TreeMap<>(utils.makePackageComparator()); @@ -120,15 +121,15 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW private final SortedSet concealedPackages = new TreeSet<>(utils.makePackageComparator()); /** - * Map of additional modules (transitive closure) and its exported packages. + * Map of indirect modules (transitive closure) and their exported packages. */ - private final Map> additionalPackages + private final Map> indirectPackages = new TreeMap<>(utils.makeModuleComparator()); /** - * Map of additional modules (transitive closure) and its open packages. + * Map of indirect modules (transitive closure) and their open packages. */ - private final Map> additionalOpenPackages + private final Map> indirectOpenPackages = new TreeMap<>(utils.makeModuleComparator()); /** @@ -180,7 +181,7 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW * @param prevModule Previous module in the sorted array. * @param nextModule Next module in the sorted array. */ - public ModuleWriterImpl(ConfigurationImpl configuration, + public ModuleWriterImpl(HtmlConfiguration configuration, ModuleElement mdle, ModuleElement prevModule, ModuleElement nextModule) { super(configuration, DocPaths.moduleSummary(mdle)); this.prevModule = prevModule; @@ -211,8 +212,10 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW Content annotationContent = new HtmlTree(HtmlTag.P); addAnnotationInfo(mdle, annotationContent); div.addContent(annotationContent); + Content label = mdle.isOpen() && (configuration.docEnv.getModuleMode() == ModuleMode.ALL) + ? contents.openModuleLabel : contents.moduleLabel; Content tHeading = HtmlTree.HEADING(HtmlConstants.TITLE_HEADING, true, - HtmlStyle.title, contents.moduleLabel); + HtmlStyle.title, label); tHeading.addContent(Contents.SPACE); Content moduleHead = new RawHtml(heading); tHeading.addContent(moduleHead); @@ -263,12 +266,12 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW CommentHelper ch = utils.getCommentHelper(mdle); // Get module dependencies using the module's transitive closure. Map dependentModules = utils.getDependentModules(mdle); - // Add all dependent modules to additional modules set. We will remove the modules, - // listed using the requires directive, from this set to come up with the table of additional + // Add all dependent modules to indirect modules set. We will remove the modules, + // listed using the requires directive, from this set to come up with the table of indirect // required modules. dependentModules.forEach((module, mod) -> { if (shouldDocument(module)) { - additionalModules.put(module, new StringContent(mod)); + indirectModules.put(module, new StringContent(mod)); } }); (ElementFilter.requiresIn(mdle.getDirectives())).forEach((directive) -> { @@ -277,19 +280,21 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW if (moduleMode == ModuleMode.ALL || directive.isTransitive()) { requires.put(m, new StringContent(utils.getModifiers(directive))); } else { - // For api mode, just keep the public requires in dependentModules for display of - // additional packages in the "Packages" section. + // For api mode, just keep the public requires in dependentModules for display of + // indirect packages in the "Packages" section. dependentModules.remove(m); - } - additionalModules.remove(m); + } + indirectModules.remove(m); } }); + // Get all packages for the module and put it in the concealed packages set. - (utils.getModulePackageMap().get(mdle)).forEach((pkg) -> { - if (shouldDocument(pkg)) { + utils.getModulePackageMap().getOrDefault(mdle, Collections.emptySet()).forEach((pkg) -> { + if (shouldDocument(pkg) && moduleMode == ModuleMode.ALL) { concealedPackages.add(pkg); } }); + // Get all exported packages for the module using the exports directive for the module. (ElementFilter.exportsIn(mdle.getDirectives())).forEach((directive) -> { PackageElement p = directive.getPackage(); @@ -304,7 +309,9 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW if (moduleMode == ModuleMode.ALL || mdleList.isEmpty()) { exportedPackages.put(p, mdleList); } - concealedPackages.remove(p); + if (moduleMode == ModuleMode.ALL) { + concealedPackages.remove(p); + } } }); // Get all opened packages for the module using the opens directive for the module. @@ -317,42 +324,47 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW mdleList.addAll(targetMdles); } // Qualified opens should not be displayed in the api mode. So if mdleList is empty, - // it's opened to all modules and hence can be added. + // it is opened to all modules and hence can be added. if (moduleMode == ModuleMode.ALL || mdleList.isEmpty()) { openedPackages.put(p, mdleList); } - concealedPackages.remove(p); + if (moduleMode == ModuleMode.ALL) { + concealedPackages.remove(p); + } } }); - // Remove all the exported and opened packages so we have just the concealed packages now. - concealedPackages.removeAll(exportedPackages.keySet()); - concealedPackages.removeAll(openedPackages.keySet()); // Get all the exported and opened packages, for the transitive closure of the module, to be displayed in - // the additional packages tables. + // the indirect packages tables. dependentModules.forEach((module, mod) -> { - SortedSet pkgList = new TreeSet<>(utils.makePackageComparator()); + SortedSet exportPkgList = new TreeSet<>(utils.makePackageComparator()); (ElementFilter.exportsIn(module.getDirectives())).forEach((directive) -> { PackageElement pkg = directive.getPackage(); if (shouldDocument(pkg)) { - pkgList.add(pkg); + // Qualified exports are not displayed in API mode + if (moduleMode == ModuleMode.ALL || directive.getTargetModules() == null) { + exportPkgList.add(pkg); + } } }); - // If none of the transitive modules have exported packages to be displayed, we should not be + // If none of the indirect modules have exported packages to be displayed, we should not be // displaying the table and so it should not be added to the map. - if (!pkgList.isEmpty()) { - additionalPackages.put(module, pkgList); + if (!exportPkgList.isEmpty()) { + indirectPackages.put(module, exportPkgList); } SortedSet openPkgList = new TreeSet<>(utils.makePackageComparator()); (ElementFilter.opensIn(module.getDirectives())).forEach((directive) -> { PackageElement pkg = directive.getPackage(); if (shouldDocument(pkg)) { - openPkgList.add(pkg); + // Qualified opens are not displayed in API mode + if (moduleMode == ModuleMode.ALL || directive.getTargetModules() == null) { + openPkgList.add(pkg); + } } }); - // If none of the transitive modules have opened packages to be displayed, we should not be + // If none of the indirect modules have opened packages to be displayed, we should not be // displaying the table and so it should not be added to the map. if (!openPkgList.isEmpty()) { - additionalOpenPackages.put(module, openPkgList); + indirectOpenPackages.put(module, openPkgList); } }); // Get all the services listed as uses directive. @@ -404,7 +416,7 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW * @param section set of elements * @return true if there are elements to be displayed */ - public boolean display(SortedSet section) { + public boolean display(Set section) { return section != null && !section.isEmpty(); } @@ -418,6 +430,25 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW return section != null && !section.isEmpty(); } + /* + * Returns true, in API mode, if at least one type element in + * the typeElements set is referenced by a javadoc tag in tagsMap. + */ + private boolean displayServices(Set typeElements, + Map tagsMap) { + return typeElements != null && + typeElements.stream().anyMatch((v) -> displayServiceDirective(v, tagsMap)); + } + + /* + * Returns true, in API mode, if the type element is referenced + * from a javadoc tag in tagsMap. + */ + private boolean displayServiceDirective(TypeElement typeElement, + Map tagsMap) { + return moduleMode == ModuleMode.ALL || tagsMap.containsKey(typeElement); + } + /** * Add the summary header. * @@ -468,31 +499,31 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW * {@inheritDoc} */ public void addModulesSummary(Content summaryContentTree) { - if (display(requires) || display(additionalModules)) { + if (display(requires) || display(indirectModules)) { HtmlTree li = new HtmlTree(HtmlTag.LI); li.addStyle(HtmlStyle.blockList); addSummaryHeader(HtmlConstants.START_OF_MODULES_SUMMARY, SectionName.MODULES, contents.navModules, li); if (display(requires)) { - String text = configuration.getText("doclet.Requires_Summary"); - String tableSummary = configuration.getText("doclet.Member_Table_Summary", - configuration.getText("doclet.Requires_Summary"), - configuration.getText("doclet.modules")); + String text = configuration.getText("doclet.Requires_Summary"); + String tableSummary = configuration.getText("doclet.Member_Table_Summary", + configuration.getText("doclet.Requires_Summary"), + configuration.getText("doclet.modules")); Content table = getTableHeader(text, tableSummary, HtmlStyle.requiresSummary, requiresTableHeader); Content tbody = new HtmlTree(HtmlTag.TBODY); addModulesList(requires, tbody); table.addContent(tbody); li.addContent(table); } - // Display additional modules table in both "api" and "all" mode. - if (display(additionalModules)) { - String amrText = configuration.getText("doclet.Additional_Modules_Required_Summary"); + // Display indirect modules table in both "api" and "all" mode. + if (display(indirectModules)) { + String amrText = configuration.getText("doclet.Indirect_Requires_Summary"); String amrTableSummary = configuration.getText("doclet.Member_Table_Summary", - configuration.getText("doclet.Additional_Modules_Required_Summary"), + configuration.getText("doclet.Indirect_Requires_Summary"), configuration.getText("doclet.modules")); Content amrTable = getTableHeader(amrText, amrTableSummary, HtmlStyle.requiresSummary, requiresTableHeader); Content amrTbody = new HtmlTree(HtmlTag.TBODY); - addModulesList(additionalModules, amrTbody); + addModulesList(indirectModules, amrTbody); amrTable.addContent(amrTbody); li.addContent(amrTable); } @@ -527,7 +558,7 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW public void addPackagesSummary(Content summaryContentTree) { if (display(exportedPackages) || display(openedPackages) || display(concealedPackages) - || display(additionalPackages) || display(additionalOpenPackages)) { + || display(indirectPackages) || display(indirectOpenPackages)) { HtmlTree li = new HtmlTree(HtmlTag.LI); li.addStyle(HtmlStyle.blockList); addSummaryHeader(HtmlConstants.START_OF_PACKAGES_SUMMARY, SectionName.PACKAGES, @@ -538,29 +569,29 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW if (display(exportedPackages) || display(openedPackages) || display(concealedPackages)) { addPackageSummary(tableSummary, li); } - if (display(additionalPackages)) { - String aepText = configuration.getText("doclet.Additional_Exported_Packages_Summary"); - String aepTableSummary = configuration.getText("doclet.Additional_Packages_Table_Summary", - configuration.getText("doclet.Additional_Exported_Packages_Summary"), + if (display(indirectPackages)) { + String aepText = configuration.getText("doclet.Indirect_Exports_Summary"); + String aepTableSummary = configuration.getText("doclet.Indirect_Packages_Table_Summary", + configuration.getText("doclet.Indirect_Exports_Summary"), configuration.getText("doclet.modules"), configuration.getText("doclet.packages")); Content aepTable = getTableHeader(aepText, aepTableSummary, HtmlStyle.packagesSummary, - additionalPackagesTableHeader); + indirectPackagesTableHeader); Content aepTbody = new HtmlTree(HtmlTag.TBODY); - addAdditionalPackages(aepTbody, additionalPackages); + addIndirectPackages(aepTbody, indirectPackages); aepTable.addContent(aepTbody); li.addContent(aepTable); } - if (display(additionalOpenPackages)) { - String aopText = configuration.getText("doclet.Additional_Opened_Packages_Summary"); - String aopTableSummary = configuration.getText("doclet.Additional_Packages_Table_Summary", - configuration.getText("doclet.Additional_Opened_Packages_Summary"), + if (display(indirectOpenPackages)) { + String aopText = configuration.getText("doclet.Indirect_Opens_Summary"); + String aopTableSummary = configuration.getText("doclet.Indirect_Packages_Table_Summary", + configuration.getText("doclet.Indirect_Opens_Summary"), configuration.getText("doclet.modules"), configuration.getText("doclet.packages")); Content aopTable = getTableHeader(aopText, aopTableSummary, HtmlStyle.packagesSummary, - additionalPackagesTableHeader); + indirectPackagesTableHeader); Content aopTbody = new HtmlTree(HtmlTag.TBODY); - addAdditionalPackages(aopTbody, additionalOpenPackages); + addIndirectPackages(aopTbody, indirectOpenPackages); aopTable.addContent(aopTbody); li.addContent(aopTable); } @@ -731,14 +762,14 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW } /** - * Add the additional packages for the module being documented. + * Add the indirect packages for the module being documented. * * @param tbody the content tree to which the table will be added - * @param ap additional packages to be added + * @param ip indirect packages to be added */ - public void addAdditionalPackages(Content tbody, Map> ap) { + public void addIndirectPackages(Content tbody, Map> ip) { boolean altColor = true; - for (Map.Entry> entry : ap.entrySet()) { + for (Map.Entry> entry : ip.entrySet()) { ModuleElement m = entry.getKey(); SortedSet pkgList = entry.getValue(); Content moduleLinkContent = getModuleLink(m, new StringContent(m.getQualifiedName())); @@ -763,27 +794,18 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW * {@inheritDoc} */ public void addServicesSummary(Content summaryContentTree) { - if (display(uses) || display(provides)) { + + boolean haveUses = displayServices(uses, usesTrees); + boolean haveProvides = displayServices(provides.keySet(), providesTrees); + + if (haveProvides || haveUses) { HtmlTree li = new HtmlTree(HtmlTag.LI); li.addStyle(HtmlStyle.blockList); addSummaryHeader(HtmlConstants.START_OF_SERVICES_SUMMARY, SectionName.SERVICES, contents.navServices, li); String text; String tableSummary; - if (display(uses)) { - text = configuration.getText("doclet.Uses_Summary"); - tableSummary = configuration.getText("doclet.Member_Table_Summary", - configuration.getText("doclet.Uses_Summary"), - configuration.getText("doclet.types")); - Content table = getTableHeader(text, tableSummary, HtmlStyle.usesSummary, usesTableHeader); - Content tbody = new HtmlTree(HtmlTag.TBODY); - addUsesList(tbody); - if (!tbody.isEmpty()) { - table.addContent(tbody); - li.addContent(table); - } - } - if (display(provides)) { + if (haveProvides) { text = configuration.getText("doclet.Provides_Summary"); tableSummary = configuration.getText("doclet.Member_Table_Summary", configuration.getText("doclet.Provides_Summary"), @@ -796,6 +818,19 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW li.addContent(table); } } + if (haveUses){ + text = configuration.getText("doclet.Uses_Summary"); + tableSummary = configuration.getText("doclet.Member_Table_Summary", + configuration.getText("doclet.Uses_Summary"), + configuration.getText("doclet.types")); + Content table = getTableHeader(text, tableSummary, HtmlStyle.usesSummary, usesTableHeader); + Content tbody = new HtmlTree(HtmlTag.TBODY); + addUsesList(tbody); + if (!tbody.isEmpty()) { + table.addContent(tbody); + li.addContent(table); + } + } HtmlTree ul = HtmlTree.UL(HtmlStyle.blockList, li); summaryContentTree.addContent(ul); } @@ -813,17 +848,13 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW HtmlTree tdSummary; Content description; for (TypeElement t : uses) { - // For each uses directive in the module declaration, if we are in the "api" mode and - // if there are service types listed using @uses javadoc tag, check if the service type in - // the uses directive is specified using the @uses tag. If not, we do not display the - // service type in the "api" mode. - if (moduleMode == ModuleMode.API && display(usesTrees) && !usesTrees.containsKey(t)) { + if (!displayServiceDirective(t, usesTrees)) { continue; } typeLinkContent = getLink(new LinkInfoImpl(configuration, LinkInfoImpl.Kind.PACKAGE, t)); thType = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, typeLinkContent); tdSummary = new HtmlTree(HtmlTag.TD); - tdSummary.addStyle(HtmlStyle.colLast); + tdSummary.addStyle(HtmlStyle.colLast); if (display(usesTrees)) { description = usesTrees.get(t); if (description != null) { @@ -832,9 +863,9 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW } addSummaryComment(t, tdSummary); HtmlTree tr = HtmlTree.TR(thType); - tr.addContent(tdSummary); - tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor); - tbody.addContent(tr); + tr.addContent(tdSummary); + tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor); + tbody.addContent(tr); altColor = !altColor; } } @@ -846,18 +877,13 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW */ public void addProvidesList(Content tbody) { boolean altColor = true; - TypeElement srv; SortedSet implSet; Content description; for (Map.Entry> entry : provides.entrySet()) { - srv = entry.getKey(); - // For each provides directive in the module declaration, if we are in the "api" mode and - // if there are service types listed using @provides javadoc tag, check if the service type in - // the provides directive is specified using the @provides tag. If not, we do not display the - // service type in the "api" mode. - if (moduleMode == ModuleMode.API && display(providesTrees) && !providesTrees.containsKey(srv)) { + TypeElement srv = entry.getKey(); + if (!displayServiceDirective(srv, providesTrees)) { continue; - } + } implSet = entry.getValue(); Content srvLinkContent = getLink(new LinkInfoImpl(configuration, LinkInfoImpl.Kind.PACKAGE, srv)); HtmlTree thType = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, srvLinkContent); @@ -972,12 +998,12 @@ public class ModuleWriterImpl extends HtmlDocletWriter implements ModuleSummaryW ? getHyperLink(SectionName.MODULE_DESCRIPTION, contents.navModuleDescription) : contents.navModuleDescription); addNavGap(liNav); - liNav.addContent((display(requires) || display(additionalModules)) + liNav.addContent((display(requires) || display(indirectModules)) ? getHyperLink(SectionName.MODULES, contents.navModules) : contents.navModules); addNavGap(liNav); liNav.addContent((display(exportedPackages) || display(openedPackages) || display(concealedPackages) - || display(additionalPackages) || display(additionalOpenPackages)) + || display(indirectPackages) || display(indirectOpenPackages)) ? getHyperLink(SectionName.PACKAGES, contents.navPackages) : contents.navPackages); addNavGap(liNav); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageFrameWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageFrameWriter.java index ec949e0d4c9..9905fc71e38 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageFrameWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageFrameWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,13 +30,12 @@ import java.util.*; import javax.lang.model.element.PackageElement; import javax.lang.model.element.TypeElement; -import jdk.javadoc.doclet.DocletEnvironment; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlConstants; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTree; import jdk.javadoc.internal.doclets.formats.html.markup.StringContent; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException; import jdk.javadoc.internal.doclets.toolkit.util.DocPath; @@ -79,7 +78,7 @@ public class PackageFrameWriter extends HtmlDocletWriter { * @param configuration the configuration of the doclet. * @param packageElement PackageElement under consideration. */ - public PackageFrameWriter(ConfigurationImpl configuration, PackageElement packageElement) { + public PackageFrameWriter(HtmlConfiguration configuration, PackageElement packageElement) { super(configuration, DocPath.forPackage(packageElement).resolve(DocPaths.PACKAGE_FRAME)); this.packageElement = packageElement; if (configuration.getSpecifiedPackageElements().isEmpty()) { @@ -96,7 +95,7 @@ public class PackageFrameWriter extends HtmlDocletWriter { * @param packageElement The package for which "pacakge-frame.html" is to be generated. * @throws DocFileIOException if there is a problem generating the package summary page */ - public static void generate(ConfigurationImpl configuration, PackageElement packageElement) + public static void generate(HtmlConfiguration configuration, PackageElement packageElement) throws DocFileIOException { PackageFrameWriter packgen = new PackageFrameWriter(configuration, packageElement); String pkgName = configuration.utils.getPackageName(packageElement); @@ -127,7 +126,7 @@ public class PackageFrameWriter extends HtmlDocletWriter { * @param contentTree the content tree to which the listing will be added */ protected void addClassListing(HtmlTree contentTree) { - Configuration config = configuration; + BaseConfiguration config = configuration; if (utils.isSpecified(packageElement)) { addClassKindListing(utils.getInterfaces(packageElement), contents.interfaces, contentTree); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexFrameWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexFrameWriter.java index 8c9087a1c21..9d89efc371c 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexFrameWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexFrameWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -60,7 +60,7 @@ public class PackageIndexFrameWriter extends AbstractPackageIndexWriter { * * @param filename Name of the package index file to be generated. */ - public PackageIndexFrameWriter(ConfigurationImpl configuration, DocPath filename) { + public PackageIndexFrameWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); } @@ -68,7 +68,7 @@ public class PackageIndexFrameWriter extends AbstractPackageIndexWriter { * Generate the package index file named "overview-frame.html". * @throws DocFileIOException */ - public static void generate(ConfigurationImpl configuration) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration) throws DocFileIOException { DocPath filename = DocPaths.OVERVIEW_FRAME; PackageIndexFrameWriter packgen = new PackageIndexFrameWriter(configuration, filename); packgen.buildPackageIndexFile("doclet.Window_Overview", false); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexWriter.java index cf5f1da6fbf..73b0638e740 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,11 +29,12 @@ import java.util.*; import javax.lang.model.element.PackageElement; -import jdk.javadoc.internal.doclets.formats.html.markup.ContentBuilder; +import jdk.javadoc.internal.doclets.formats.html.markup.HtmlConstants; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTree; import jdk.javadoc.internal.doclets.formats.html.markup.RawHtml; +import jdk.javadoc.internal.doclets.formats.html.markup.StringContent; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException; import jdk.javadoc.internal.doclets.toolkit.util.DocPath; @@ -82,7 +83,7 @@ public class PackageIndexWriter extends AbstractPackageIndexWriter { * @param filename the path of the page to be generated * @see Group */ - public PackageIndexWriter(ConfigurationImpl configuration, DocPath filename) { + public PackageIndexWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); groupPackageMap = configuration.group.groupPackages(packages); groupList = configuration.group.getGroupList(); @@ -94,7 +95,7 @@ public class PackageIndexWriter extends AbstractPackageIndexWriter { * @param configuration the current configuration of the doclet. * @throws DocFileIOException if there is a problem generating the package index page */ - public static void generate(ConfigurationImpl configuration) throws DocFileIOException { + public static void generate(HtmlConfiguration configuration) throws DocFileIOException { DocPath filename = DocPaths.overviewSummary(configuration.frames); PackageIndexWriter packgen = new PackageIndexWriter(configuration, filename); packgen.buildPackageIndexFile("doclet.Window_Overview_Summary", true); @@ -112,8 +113,8 @@ public class PackageIndexWriter extends AbstractPackageIndexWriter { SortedSet list = groupPackageMap.get(groupname); if (list != null && !list.isEmpty()) { addIndexContents(list, - groupname, configuration.getText("doclet.Member_Table_Summary", - groupname, configuration.getText("doclet.packages")), body); + groupname, configuration.getText("doclet.Member_Table_Summary", + groupname, configuration.getText("doclet.packages")), body); } } } @@ -131,7 +132,9 @@ public class PackageIndexWriter extends AbstractPackageIndexWriter { Content tbody = new HtmlTree(HtmlTag.TBODY); addPackagesList(packages, tbody); table.addContent(tbody); - Content div = HtmlTree.DIV(HtmlStyle.contentContainer, table); + Content anchor = getMarkerAnchor(text); + Content div = HtmlTree.DIV(HtmlStyle.contentContainer, anchor); + div.addContent(table); if (configuration.allowTag(HtmlTag.MAIN)) { htmlTree.addContent(div); } else { @@ -176,19 +179,9 @@ public class PackageIndexWriter extends AbstractPackageIndexWriter { protected void addOverviewHeader(Content body) { addConfigurationTitle(body); if (!utils.getFullBody(configuration.overviewElement).isEmpty()) { - HtmlTree subTitleDiv = new HtmlTree(HtmlTag.DIV); - subTitleDiv.addStyle(HtmlStyle.subTitle); - addSummaryComment(configuration.overviewElement, subTitleDiv); - Content div = HtmlTree.DIV(HtmlStyle.header, subTitleDiv); - Content descBody = new ContentBuilder(); - descBody.addContent(contents.seeLabel); - descBody.addContent(" "); - Content descPara = HtmlTree.P(descBody); - Content descLink = getHyperLink(getDocLink( - SectionName.OVERVIEW_DESCRIPTION), - contents.descriptionLabel, "", ""); - descPara.addContent(descLink); - div.addContent(descPara); + HtmlTree div = new HtmlTree(HtmlTag.DIV); + div.addStyle(HtmlStyle.contentContainer); + addOverviewComment(div); if (configuration.allowTag(HtmlTag.MAIN)) { htmlTree.addContent(div); } else { @@ -206,27 +199,19 @@ public class PackageIndexWriter extends AbstractPackageIndexWriter { */ protected void addOverviewComment(Content htmltree) { if (!utils.getFullBody(configuration.overviewElement).isEmpty()) { - htmltree.addContent(getMarkerAnchor(SectionName.OVERVIEW_DESCRIPTION)); addInlineComment(configuration.overviewElement, htmltree); } } /** - * Adds the tag information as provided in the file specified by the - * "-overview" option on the command line. + * For HTML 5, add the htmlTree to the body. For HTML 4, do nothing. * * @param body the documentation tree to which the overview will be added */ @Override protected void addOverview(Content body) { - HtmlTree div = new HtmlTree(HtmlTag.DIV); - div.addStyle(HtmlStyle.contentContainer); - addOverviewComment(div); if (configuration.allowTag(HtmlTag.MAIN)) { - htmlTree.addContent(div); body.addContent(htmlTree); - } else { - body.addContent(div); } } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageTreeWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageTreeWriter.java index f67e906a209..2226ea4d27d 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageTreeWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageTreeWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -75,7 +75,7 @@ public class PackageTreeWriter extends AbstractTreeWriter { * @param prev the previous package * @param next the next package */ - public PackageTreeWriter(ConfigurationImpl configuration, + public PackageTreeWriter(HtmlConfiguration configuration, DocPath path, PackageElement packageElement, PackageElement prev, PackageElement next) { @@ -98,7 +98,7 @@ public class PackageTreeWriter extends AbstractTreeWriter { * deprecated classe or interfaces. * @throws DocFileIOException if there is a problem generating the package tree page */ - public static void generate(ConfigurationImpl configuration, + public static void generate(HtmlConfiguration configuration, PackageElement pkg, PackageElement prev, PackageElement next, boolean noDeprecated) throws DocFileIOException { diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageUseWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageUseWriter.java index 726c64ff927..5ca2ac753fd 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageUseWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageUseWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -64,7 +64,7 @@ public class PackageUseWriter extends SubWriterHolderWriter { * * @param filename the file to be generated. */ - public PackageUseWriter(ConfigurationImpl configuration, + public PackageUseWriter(HtmlConfiguration configuration, ClassUseMapper mapper, DocPath filename, PackageElement pkgElement) { super(configuration, DocPath.forPackage(pkgElement).resolve(filename)); @@ -99,7 +99,7 @@ public class PackageUseWriter extends SubWriterHolderWriter { * @param pkgElement the package being documented. * @throws DocFileIOException if there is a problem generating the package use page */ - public static void generate(ConfigurationImpl configuration, + public static void generate(HtmlConfiguration configuration, ClassUseMapper mapper, PackageElement pkgElement) throws DocFileIOException { DocPath filename = DocPaths.PACKAGE_USE; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageWriterImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageWriterImpl.java index 75d46ca284e..d7c4da55794 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageWriterImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageWriterImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -99,7 +99,7 @@ public class PackageWriterImpl extends HtmlDocletWriter * @param prev Previous package in the sorted array. * @param next Next package in the sorted array. */ - public PackageWriterImpl(ConfigurationImpl configuration, + public PackageWriterImpl(HtmlConfiguration configuration, PackageElement packageElement, PackageElement prev, PackageElement next) { super(configuration, DocPath .forPackage(packageElement) @@ -127,7 +127,7 @@ public class PackageWriterImpl extends HtmlDocletWriter div.addStyle(HtmlStyle.header); if (configuration.showModules) { ModuleElement mdle = configuration.docEnv.getElementUtils().getModuleOf(packageElement); - Content classModuleLabel = HtmlTree.SPAN(HtmlStyle.moduleLabelInClass, contents.moduleLabel); + Content classModuleLabel = HtmlTree.SPAN(HtmlStyle.moduleLabelInPackage, contents.moduleLabel); Content moduleNameDiv = HtmlTree.DIV(HtmlStyle.subTitle, classModuleLabel); moduleNameDiv.addContent(Contents.SPACE); moduleNameDiv.addContent(getModuleLink(mdle, diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SerializedFormWriterImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SerializedFormWriterImpl.java index 3ff29ee873e..5c6d698a57a 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SerializedFormWriterImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SerializedFormWriterImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,8 +36,6 @@ import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTree; import jdk.javadoc.internal.doclets.formats.html.markup.StringContent; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.SerializedFormWriter; -import jdk.javadoc.internal.doclets.toolkit.SerializedFormWriter.SerialFieldWriter; -import jdk.javadoc.internal.doclets.toolkit.SerializedFormWriter.SerialMethodWriter; import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException; import jdk.javadoc.internal.doclets.toolkit.util.DocPaths; @@ -64,7 +62,7 @@ public class SerializedFormWriterImpl extends SubWriterHolderWriter /** * @param configuration the configuration data for the doclet */ - public SerializedFormWriterImpl(ConfigurationImpl configuration) { + public SerializedFormWriterImpl(HtmlConfiguration configuration) { super(configuration, DocPaths.SERIALIZED_FORM); visibleClasses = configuration.getIncludedTypeElements(); } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SingleIndexWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SingleIndexWriter.java index d5735fffe19..17321315d07 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SingleIndexWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SingleIndexWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -64,7 +64,7 @@ public class SingleIndexWriter extends AbstractIndexWriter { * @param filename Name of the index file to be generated. * @param indexbuilder Unicode based Index from {@link IndexBuilder} */ - public SingleIndexWriter(ConfigurationImpl configuration, + public SingleIndexWriter(HtmlConfiguration configuration, DocPath filename, IndexBuilder indexbuilder) { super(configuration, filename, indexbuilder); @@ -77,7 +77,7 @@ public class SingleIndexWriter extends AbstractIndexWriter { * @param indexbuilder IndexBuilder built by {@link IndexBuilder} * @throws DocFileIOException if there is a problem generating the index */ - public static void generate(ConfigurationImpl configuration, + public static void generate(HtmlConfiguration configuration, IndexBuilder indexbuilder) throws DocFileIOException { DocPath filename = DocPaths.INDEX_ALL; SingleIndexWriter indexgen = new SingleIndexWriter(configuration, diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SourceToHTMLConverter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SourceToHTMLConverter.java index 0a783498e65..f1a4e60b1ed 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SourceToHTMLConverter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SourceToHTMLConverter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -74,7 +74,7 @@ public class SourceToHTMLConverter { */ private static final String NEW_LINE = DocletConstants.NL; - private final ConfigurationImpl configuration; + private final HtmlConfiguration configuration; private final Messages messages; private final Utils utils; @@ -88,8 +88,8 @@ public class SourceToHTMLConverter { */ private DocPath relativePath = DocPath.empty; - private SourceToHTMLConverter(ConfigurationImpl configuration, DocletEnvironment rd, - DocPath outputdir) { + private SourceToHTMLConverter(HtmlConfiguration configuration, DocletEnvironment rd, + DocPath outputdir) { this.configuration = configuration; this.messages = configuration.getMessages(); this.utils = configuration.utils; @@ -106,8 +106,8 @@ public class SourceToHTMLConverter { * @throws DocFileIOException if there is a problem generating an output file * @throws SimpleDocletException if there is a problem reading a source file */ - public static void convertRoot(ConfigurationImpl configuration, DocletEnvironment docEnv, - DocPath outputdir) throws DocFileIOException, SimpleDocletException { + public static void convertRoot(HtmlConfiguration configuration, DocletEnvironment docEnv, + DocPath outputdir) throws DocFileIOException, SimpleDocletException { new SourceToHTMLConverter(configuration, docEnv, outputdir).generate(); } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SplitIndexWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SplitIndexWriter.java index 364d283b113..0dd7528e9e7 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SplitIndexWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SplitIndexWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -82,7 +82,7 @@ public class SplitIndexWriter extends AbstractIndexWriter { * @param prev the previous character that was indexed * @param next the next character to be indexed */ - public SplitIndexWriter(ConfigurationImpl configuration, + public SplitIndexWriter(HtmlConfiguration configuration, DocPath path, IndexBuilder indexbuilder, Collection elements, @@ -101,7 +101,7 @@ public class SplitIndexWriter extends AbstractIndexWriter { * @param indexbuilder IndexBuilder built by {@link IndexBuilder} * @throws DocFileIOException if there is a problem generating the index files */ - public static void generate(ConfigurationImpl configuration, + public static void generate(HtmlConfiguration configuration, IndexBuilder indexbuilder) throws DocFileIOException { DocPath path = DocPaths.INDEX_FILES; Set keys = new TreeSet<>(indexbuilder.getIndexMap().keySet()); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SubWriterHolderWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SubWriterHolderWriter.java index 4ad7d9325db..b196c0b8ce6 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SubWriterHolderWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SubWriterHolderWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -66,7 +66,7 @@ public abstract class SubWriterHolderWriter extends HtmlDocletWriter { */ protected HtmlTree mainTree = HtmlTree.MAIN(); - public SubWriterHolderWriter(ConfigurationImpl configuration, DocPath filename) { + public SubWriterHolderWriter(HtmlConfiguration configuration, DocPath filename) { super(configuration, filename); } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/TagletWriterImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/TagletWriterImpl.java index 32f3871286e..2ac4411b607 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/TagletWriterImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/TagletWriterImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -42,7 +42,7 @@ import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle; import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTree; import jdk.javadoc.internal.doclets.formats.html.markup.RawHtml; import jdk.javadoc.internal.doclets.formats.html.markup.StringContent; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.builders.SerializedFormBuilder; import jdk.javadoc.internal.doclets.toolkit.taglets.TagletWriter; @@ -68,7 +68,7 @@ import jdk.javadoc.internal.doclets.toolkit.util.Utils; public class TagletWriterImpl extends TagletWriter { private final HtmlDocletWriter htmlWriter; - private final ConfigurationImpl configuration; + private final HtmlConfiguration configuration; private final Utils utils; public TagletWriterImpl(HtmlDocletWriter htmlWriter, boolean isFirstSentence) { @@ -106,7 +106,7 @@ public class TagletWriterImpl extends TagletWriter { String desc = ch.getText(itt.getDescription()); String anchorName = htmlWriter.getName(tagText); - Content result = HtmlTree.A_ID(anchorName, new StringContent(tagText)); + Content result = HtmlTree.A_ID(HtmlStyle.searchTagResult, anchorName, new StringContent(tagText)); if (configuration.createindex && !tagText.isEmpty()) { SearchIndexItem si = new SearchIndexItem(); si.setLabel(tagText); @@ -438,7 +438,7 @@ public class TagletWriterImpl extends TagletWriter { /** * {@inheritDoc} */ - public Configuration configuration() { + public BaseConfiguration configuration() { return configuration; } } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/TreeWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/TreeWriter.java index cade70f9622..f2cab0d3787 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/TreeWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/TreeWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -74,7 +74,7 @@ public class TreeWriter extends AbstractTreeWriter { * @param filename String filename * @param classtree the tree being built. */ - public TreeWriter(ConfigurationImpl configuration, DocPath filename, ClassTree classtree) { + public TreeWriter(HtmlConfiguration configuration, DocPath filename, ClassTree classtree) { super(configuration, filename, classtree); packages = configuration.packages; classesOnly = packages.isEmpty(); @@ -88,7 +88,7 @@ public class TreeWriter extends AbstractTreeWriter { * @param classtree the class tree being documented. * @throws DocFileIOException if there is a problem generating the overview tree page */ - public static void generate(ConfigurationImpl configuration, + public static void generate(HtmlConfiguration configuration, ClassTree classtree) throws DocFileIOException { DocPath filename = DocPaths.OVERVIEW_TREE; TreeWriter treegen = new TreeWriter(configuration, filename, classtree); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/WriterFactoryImpl.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/WriterFactoryImpl.java index 55742f604af..30f4debde24 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/WriterFactoryImpl.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/WriterFactoryImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -45,8 +45,6 @@ import jdk.javadoc.internal.doclets.toolkit.WriterFactory; import jdk.javadoc.internal.doclets.toolkit.util.ClassTree; import jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap; -import static jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap.Kind.*; - /** * The factory that returns HTML writers. * @@ -59,8 +57,8 @@ import static jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap.Kind.*; */ public class WriterFactoryImpl implements WriterFactory { - private final ConfigurationImpl configuration; - public WriterFactoryImpl(ConfigurationImpl configuration) { + private final HtmlConfiguration configuration; + public WriterFactoryImpl(HtmlConfiguration configuration) { this.configuration = configuration; } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlDocWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlDocWriter.java index de06d5253a8..afe41f219ca 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlDocWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlDocWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,9 +31,9 @@ import javax.lang.model.element.ModuleElement; import javax.lang.model.element.PackageElement; import javax.lang.model.element.TypeElement; -import jdk.javadoc.internal.doclets.formats.html.ConfigurationImpl; +import jdk.javadoc.internal.doclets.formats.html.HtmlConfiguration; import jdk.javadoc.internal.doclets.formats.html.SectionName; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.Messages; import jdk.javadoc.internal.doclets.toolkit.util.DocFile; @@ -69,7 +69,7 @@ public abstract class HtmlDocWriter extends HtmlWriter { * @param configuration the configuration for this doclet * @param filename String file name. */ - public HtmlDocWriter(Configuration configuration, DocPath filename) { + public HtmlDocWriter(BaseConfiguration configuration, DocPath filename) { super(configuration, filename); this.pathToRoot = filename.parent().invert(); Messages messages = configuration.getMessages(); @@ -81,7 +81,7 @@ public abstract class HtmlDocWriter extends HtmlWriter { * Accessor for configuration. * @return the configuration for this doclet */ - public abstract Configuration configuration(); + public abstract BaseConfiguration configuration(); public Content getHyperLink(DocPath link, String label) { return getHyperLink(link, new StringContent(label), false, "", "", ""); @@ -318,7 +318,7 @@ public abstract class HtmlDocWriter extends HtmlWriter { * @param body the body content tree to be added to the HTML document * @throws DocFileIOException if there is an error writing the frames document */ - public void printFramesDocument(String title, ConfigurationImpl configuration, + public void printFramesDocument(String title, HtmlConfiguration configuration, HtmlTree body) throws DocFileIOException { Content htmlDocType = configuration.isOutputHtml5() ? DocType.HTML5 @@ -347,7 +347,7 @@ public abstract class HtmlDocWriter extends HtmlWriter { * @param configuration the configuration for this doclet * @return an HtmlTree for the lINK tag which provides the stylesheet location */ - public HtmlTree getStyleSheetProperties(ConfigurationImpl configuration) { + public HtmlTree getStyleSheetProperties(HtmlConfiguration configuration) { String stylesheetfile = configuration.stylesheetfile; DocPath stylesheet; if (stylesheetfile.isEmpty()) { diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlStyle.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlStyle.java index e6c262d7cfc..ad6c183448e 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlStyle.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlStyle.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -46,6 +46,7 @@ public enum HtmlStyle { bottomNav, circle, classUseContainer, + colConstructorName, colFirst, colLast, colSecond, @@ -78,7 +79,8 @@ public enum HtmlStyle { memberNameLabel, memberNameLink, memberSummary, - moduleLabelInClass, + moduleLabelInPackage, + moduleLabelInType, nameValue, navBarCell1Rev, navList, @@ -87,7 +89,7 @@ public enum HtmlStyle { overrideSpecifyLabel, overviewSummary, packageHierarchyLabel, - packageLabelInClass, + packageLabelInType, packagesSummary, paramLabel, providesSummary, @@ -97,6 +99,7 @@ public enum HtmlStyle { rightIframe, rowColor, searchTagLink, + searchTagResult, seeLabel, serializedFormContainer, simpleTagLabel, diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlTree.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlTree.java index b3ab27dadd3..46001936673 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlTree.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlTree.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -264,6 +264,21 @@ public class HtmlTree extends Content { return htmltree; } + /** + * Generates an HTML anchor tag with a style class, id attribute and a body. + * + * @param styleClass stylesheet class for the tag + * @param id id for the anchor tag + * @param body body for the anchor tag + * @return an HtmlTree object + */ + public static HtmlTree A_ID(HtmlStyle styleClass, String id, Content body) { + HtmlTree htmltree = A_ID(id, body); + if (styleClass != null) + htmltree.addStyle(styleClass); + return htmltree; + } + /** * Generates a CAPTION tag with some content. * diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlWriter.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlWriter.java index 706d7294e45..85490bdb9d5 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlWriter.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,14 +29,13 @@ import java.io.*; import java.util.*; import jdk.javadoc.doclet.DocletEnvironment.ModuleMode; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.Resources; import jdk.javadoc.internal.doclets.toolkit.util.DocFile; import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException; import jdk.javadoc.internal.doclets.toolkit.util.DocPath; import jdk.javadoc.internal.doclets.toolkit.util.DocletConstants; -import jdk.javadoc.internal.doclets.toolkit.util.ModulePackageTypes; import jdk.javadoc.internal.doclets.toolkit.util.TableTabTypes; @@ -63,7 +62,7 @@ public class HtmlWriter { /** * The configuration */ - protected Configuration configuration; + protected BaseConfiguration configuration; /** * Header for table displaying modules and description. @@ -88,7 +87,7 @@ public class HtmlWriter { /** * Header for tables displaying modules and exported packages. */ - protected final List additionalPackagesTableHeader; + protected final List indirectPackagesTableHeader; /** * Header for tables displaying types and description. @@ -121,7 +120,7 @@ public class HtmlWriter { * @param path The directory path to be created for this file * or null if none to be created. */ - public HtmlWriter(Configuration configuration, DocPath path) { + public HtmlWriter(BaseConfiguration configuration, DocPath path) { docFile = DocFile.createFileForOutput(configuration, path); this.configuration = configuration; @@ -136,18 +135,18 @@ public class HtmlWriter { packageTableHeader.add(resources.getText("doclet.Package")); packageTableHeader.add(resources.getText("doclet.Description")); requiresTableHeader = new ArrayList<>(); - requiresTableHeader.add(resources.getText("doclet.Modifier")); + requiresTableHeader.add(resources.getText("doclet.Modifier")); requiresTableHeader.add(resources.getText("doclet.Module")); requiresTableHeader.add(resources.getText("doclet.Description")); exportedPackagesTableHeader = new ArrayList<>(); exportedPackagesTableHeader.add(resources.getText("doclet.Package")); if (configuration.docEnv.getModuleMode() == ModuleMode.ALL) { - exportedPackagesTableHeader.add(resources.getText("doclet.Module")); + exportedPackagesTableHeader.add(resources.getText("doclet.Module")); } exportedPackagesTableHeader.add(resources.getText("doclet.Description")); - additionalPackagesTableHeader = new ArrayList<>(); - additionalPackagesTableHeader.add(resources.getText("doclet.Module")); - additionalPackagesTableHeader.add(resources.getText("doclet.Packages")); + indirectPackagesTableHeader = new ArrayList<>(); + indirectPackagesTableHeader.add(resources.getText("doclet.From")); + indirectPackagesTableHeader.add(resources.getText("doclet.Packages")); usesTableHeader = new ArrayList<>(); usesTableHeader.add(resources.getText("doclet.Type")); usesTableHeader.add(resources.getText("doclet.Description")); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/RawHtml.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/RawHtml.java index 0a2c3609a12..a374531f722 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/RawHtml.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/RawHtml.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,6 +47,8 @@ public class RawHtml extends Content { public static final Content nbsp = new RawHtml(" "); + public static final Content zws = new RawHtml("​"); + /** * Constructor to construct a RawHtml object. * diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/search.js b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/search.js index 6e4ea9bc6f9..37a49862690 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/search.js +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/search.js @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -86,7 +86,7 @@ $(function() { $(this).val(watermark).addClass('watermark'); } }); - $("#search").keydown(function() { + $("#search").on('click keydown', function() { if ($(this).val() == watermark) { $(this).val('').removeClass('watermark'); } @@ -169,11 +169,42 @@ $(function() { var tresult = new Array(); var mresult = new Array(); var tgresult = new Array(); + var secondaryresult = new Array(); var displayCount = 0; var exactMatcher = new RegExp("^" + $.ui.autocomplete.escapeRegex(request.term) + "$", "i"); camelCaseRegexp = ($.ui.autocomplete.escapeRegex(request.term)).split(/(?=[A-Z])/).join("([a-z0-9_$]*?)"); var camelCaseMatcher = new RegExp("^" + camelCaseRegexp); secondaryMatcher = new RegExp($.ui.autocomplete.escapeRegex(request.term), "i"); + + // Return the nested innermost name from the specified object + function nestedName(e) { + return e.l.substring(e.l.lastIndexOf(".") + 1); + } + + // Sort array items by short name (as opposed to fully qualified name). + // Additionally, sort by the nested type name, when present, + // as opposed to top level short name. + function sortAndConcatResults(a1, a2) { + var sortingKey; + var sortArray = function(e1, e2) { + var l = sortingKey(e1); + var m = sortingKey(e2); + if (l < m) + return -1; + if (l > m) + return 1; + return 0; + }; + sortingKey = function(e) { + return nestedName(e).toUpperCase(); + }; + a1.sort(sortArray); + a2.sort(sortArray); + a1 = a1.concat(a2); + a2.length = 0; + return a1; + } + if (moduleSearchIndex) { var mdleCount = 0; $.each(moduleSearchIndex, function(index, item) { @@ -184,10 +215,11 @@ $(function() { } else if (camelCaseMatcher.test(item.l)) { result.unshift(item); } else if (secondaryMatcher.test(item.l)) { - result.push(item); + secondaryresult.push(item); } }); displayCount = mdleCount; + result = sortAndConcatResults(result, secondaryresult); } if (packageSearchIndex) { var pCount = 0; @@ -203,42 +235,44 @@ $(function() { } else if (camelCaseMatcher.test(pkg)) { presult.unshift(item); } else if (secondaryMatcher.test(pkg)) { - presult.push(item); + secondaryresult.push(item); } }); - result = result.concat(presult); + result = result.concat(sortAndConcatResults(presult, secondaryresult)); displayCount = (pCount > displayCount) ? pCount : displayCount; } if (typeSearchIndex) { var tCount = 0; $.each(typeSearchIndex, function(index, item) { item[category] = catTypes; - if (exactMatcher.test(item.l)) { + var s = nestedName(item); + if (exactMatcher.test(s)) { tresult.unshift(item); tCount++; - } else if (camelCaseMatcher.test(item.l)) { + } else if (camelCaseMatcher.test(s)) { tresult.unshift(item); } else if (secondaryMatcher.test(item.p + "." + item.l)) { - tresult.push(item); + secondaryresult.push(item); } }); - result = result.concat(tresult); + result = result.concat(sortAndConcatResults(tresult, secondaryresult)); displayCount = (tCount > displayCount) ? tCount : displayCount; } if (memberSearchIndex) { var mCount = 0; $.each(memberSearchIndex, function(index, item) { item[category] = catMembers; - if (exactMatcher.test(item.l)) { + var s = nestedName(item); + if (exactMatcher.test(s)) { mresult.unshift(item); mCount++; - } else if (camelCaseMatcher.test(item.l)) { + } else if (camelCaseMatcher.test(s)) { mresult.unshift(item); } else if (secondaryMatcher.test(item.c + "." + item.l)) { - mresult.push(item); + secondaryresult.push(item); } }); - result = result.concat(mresult); + result = result.concat(sortAndConcatResults(mresult, secondaryresult)); displayCount = (mCount > displayCount) ? mCount : displayCount; } if (tagSearchIndex) { @@ -249,10 +283,10 @@ $(function() { tgresult.unshift(item); tgCount++; } else if (secondaryMatcher.test(item.l)) { - tgresult.push(item); + secondaryresult.push(item); } }); - result = result.concat(tgresult); + result = result.concat(sortAndConcatResults(tgresult, secondaryresult)); displayCount = (tgCount > displayCount) ? tgCount : displayCount; } displayCount = (displayCount > 500) ? displayCount : 500; @@ -312,4 +346,4 @@ $(function() { } } }); -}); \ No newline at end of file +}); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard.properties b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard.properties index 8990c4d2ef4..7ea09a3c793 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard.properties +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard.properties @@ -6,6 +6,7 @@ doclet.Window_Overview_Summary=Overview doclet.Element=Element doclet.Package=Package doclet.Module=Module +doclet.Open_Module=Open Module doclet.All_Packages=All Packages doclet.All_Modules=All Modules doclet.None=None @@ -191,9 +192,9 @@ doclet.ClassUse_No.usage.of.0=No usage of {0} doclet.Window_ClassUse_Header=Uses of {0} {1} doclet.ClassUse_Title=Uses of {0} doclet.navClassUse=Use -doclet.Error_in_packagelist=Error in using -group option: {0} {1} -doclet.Groupname_already_used=In -group option, groupname already used: {0} -doclet.Same_package_name_used=Package name format used twice: {0} +doclet.Error_in_grouplist=Bad -group option: {0} {1} +doclet.Groupname_already_used=In -group option, group name already used: {0} +doclet.Same_element_name_used=Element name or pattern used twice: {0} # option specifiers doclet.usage.d.parameters=\ @@ -273,9 +274,9 @@ doclet.usage.excludedocfilessubdir.description=\ Exclude any doc-files subdirectories with given name doclet.usage.group.parameters=\ - :.. + :... doclet.usage.group.description=\ - Group specified packages together in overview page + Group specified elements together in overview page doclet.usage.nocomment.description=\ Suppress description and tags, generate only declarations @@ -331,6 +332,9 @@ doclet.usage.charset.parameters=\ doclet.usage.charset.description=\ Charset for cross-platform viewing of generated documentation +doclet.usage.javafx.description=\ + Enable javafx functionality + doclet.usage.helpfile.parameters=\ doclet.usage.helpfile.description=\ diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard_ja.properties b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard_ja.properties index 13283667af4..e028cc669db 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard_ja.properties +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard_ja.properties @@ -3,10 +3,13 @@ doclet.Contents=\u30B3\u30F3\u30C6\u30F3\u30C4 doclet.Overview=\u6982\u8981 doclet.Window_Overview=\u6982\u8981\u30EA\u30B9\u30C8 doclet.Window_Overview_Summary=\u6982\u8981 +doclet.Element=\u8981\u7D20 doclet.Package=\u30D1\u30C3\u30B1\u30FC\u30B8 doclet.Module=\u30E2\u30B8\u30E5\u30FC\u30EB +doclet.Open_Module=\u30E2\u30B8\u30E5\u30FC\u30EB\u3092\u958B\u304F doclet.All_Packages=\u3059\u3079\u3066\u306E\u30D1\u30C3\u30B1\u30FC\u30B8 doclet.All_Modules=\u3059\u3079\u3066\u306E\u30E2\u30B8\u30E5\u30FC\u30EB +doclet.None=\u306A\u3057 doclet.Tree=\u968E\u5C64\u30C4\u30EA\u30FC doclet.Class_Hierarchy=\u30AF\u30E9\u30B9\u968E\u5C64 doclet.Window_Class_Hierarchy=\u30AF\u30E9\u30B9\u968E\u5C64 @@ -71,6 +74,8 @@ doclet.see.class_or_package_not_found=\u30BF\u30B0{0}: \u53C2\u7167\u304C\u898B\ doclet.see.class_or_package_not_accessible=\u30BF\u30B0{0}: \u53C2\u7167\u306B\u30A2\u30AF\u30BB\u30B9\u3067\u304D\u307E\u305B\u3093: {1} doclet.tag.invalid_usage=\u30BF\u30B0{0}\u306E\u4F7F\u7528\u65B9\u6CD5\u304C\u7121\u52B9\u3067\u3059 doclet.Deprecated_API=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044API +doclet.Deprecated_For_Removal=\u524A\u9664\u4E88\u5B9A\u306E\u975E\u63A8\u5968 +doclet.Deprecated_Modules=\u975E\u63A8\u5968\u30E2\u30B8\u30E5\u30FC\u30EB doclet.Deprecated_Packages=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u30D1\u30C3\u30B1\u30FC\u30B8 doclet.Deprecated_Classes=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u30AF\u30E9\u30B9 doclet.Deprecated_Enums=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u5217\u6319\u578B @@ -83,6 +88,8 @@ doclet.Deprecated_Constructors=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\ doclet.Deprecated_Methods=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u30E1\u30BD\u30C3\u30C9 doclet.Deprecated_Enum_Constants=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u5217\u6319\u578B\u5B9A\u6570 doclet.Deprecated_Annotation_Type_Members=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u6CE8\u91C8\u578B\u306E\u8981\u7D20 +doclet.deprecated_for_removal=\u524A\u9664\u4E88\u5B9A\u306E\u975E\u63A8\u5968 +doclet.deprecated_modules=\u975E\u63A8\u5968\u30E2\u30B8\u30E5\u30FC\u30EB doclet.deprecated_packages=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u30D1\u30C3\u30B1\u30FC\u30B8 doclet.deprecated_classes=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u30AF\u30E9\u30B9 doclet.deprecated_enums=\u63A8\u5968\u3055\u308C\u3066\u3044\u306A\u3044\u5217\u6319\u578B @@ -275,6 +282,8 @@ doclet.usage.tagletpath.description=\u30BF\u30B0\u30EC\u30C3\u30C8\u306E\u30D1\u doclet.usage.charset.parameters= doclet.usage.charset.description=\u751F\u6210\u3055\u308C\u308B\u30C9\u30AD\u30E5\u30E1\u30F3\u30C8\u306E\u30AF\u30ED\u30B9\u30D7\u30E9\u30C3\u30C8\u30D5\u30A9\u30FC\u30E0\u3067\u306E\u6587\u5B57\u30BB\u30C3\u30C8 +doclet.usage.javafx.description=javafx\u6A5F\u80FD\u3092\u6709\u52B9\u306B\u3057\u307E\u3059 + doclet.usage.helpfile.parameters= doclet.usage.helpfile.description=\u30D8\u30EB\u30D7\u30FB\u30EA\u30F3\u30AF\u306E\u30EA\u30F3\u30AF\u5148\u30D5\u30A1\u30A4\u30EB\u3092\u542B\u3081\u307E\u3059 @@ -295,6 +304,8 @@ doclet.usage.frames.description=\u751F\u6210\u3055\u308C\u305F\u51FA\u529B\u3067 doclet.usage.no-frames.description=\u751F\u6210\u3055\u308C\u305F\u51FA\u529B\u3067\u30D5\u30EC\u30FC\u30E0\u306E\u4F7F\u7528\u3092\u7121\u52B9\u306B\u3057\u307E\u3059 +doclet.usage.allow-script-in-comments.description=\u30AA\u30D7\u30B7\u30E7\u30F3\u304A\u3088\u3073\u30B3\u30E1\u30F3\u30C8\u3067JavaScript\u3092\u8A31\u53EF\u3057\u307E\u3059 + doclet.usage.xdocrootparent.parameters= doclet.usage.xdocrootparent.description=doc\u30B3\u30E1\u30F3\u30C8\u5185\u306E/..\u304C\u5F8C\u306B\u7D9A\u304F@docRoot\u306E\u3059\u3079\u3066\u3092\u3067\u7F6E\u63DB\u3057\u307E\u3059 diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard_zh_CN.properties b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard_zh_CN.properties index 949044a3d03..a3c25336f67 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard_zh_CN.properties +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/resources/standard_zh_CN.properties @@ -3,10 +3,13 @@ doclet.Contents=\u76EE\u5F55 doclet.Overview=\u6982\u89C8 doclet.Window_Overview=\u6982\u89C8\u5217\u8868 doclet.Window_Overview_Summary=\u6982\u89C8 +doclet.Element=\u5143\u7D20 doclet.Package=\u7A0B\u5E8F\u5305 doclet.Module=\u6A21\u5757 +doclet.Open_Module=\u6253\u5F00\u6A21\u5757 doclet.All_Packages=\u6240\u6709\u7A0B\u5E8F\u5305 doclet.All_Modules=\u5168\u90E8\u6A21\u5757 +doclet.None=\u65E0 doclet.Tree=\u6811 doclet.Class_Hierarchy=\u7C7B\u5206\u5C42\u7ED3\u6784 doclet.Window_Class_Hierarchy=\u7C7B\u5206\u5C42\u7ED3\u6784 @@ -71,6 +74,8 @@ doclet.see.class_or_package_not_found=\u6807\u8BB0{0}: \u627E\u4E0D\u5230\u5F15\ doclet.see.class_or_package_not_accessible=\u6807\u8BB0{0}: \u65E0\u6CD5\u8BBF\u95EE\u5F15\u7528: {1} doclet.tag.invalid_usage=\u6807\u8BB0 {0} \u7684\u7528\u6CD5\u65E0\u6548 doclet.Deprecated_API=\u5DF2\u8FC7\u65F6\u7684 API +doclet.Deprecated_For_Removal=\u5DF2\u8FC7\u65F6, \u5F85\u5220\u9664 +doclet.Deprecated_Modules=\u5DF2\u8FC7\u65F6\u6A21\u5757 doclet.Deprecated_Packages=\u5DF2\u8FC7\u65F6\u7A0B\u5E8F\u5305 doclet.Deprecated_Classes=\u5DF2\u8FC7\u65F6\u7684\u7C7B doclet.Deprecated_Enums=\u5DF2\u8FC7\u65F6\u7684\u679A\u4E3E @@ -83,6 +88,8 @@ doclet.Deprecated_Constructors=\u5DF2\u8FC7\u65F6\u7684\u6784\u9020\u5668 doclet.Deprecated_Methods=\u5DF2\u8FC7\u65F6\u7684\u65B9\u6CD5 doclet.Deprecated_Enum_Constants=\u5DF2\u8FC7\u65F6\u7684\u679A\u4E3E\u5E38\u91CF doclet.Deprecated_Annotation_Type_Members=\u5DF2\u8FC7\u65F6\u7684\u6CE8\u91CA\u7C7B\u578B\u5143\u7D20 +doclet.deprecated_for_removal=\u5DF2\u8FC7\u65F6, \u5F85\u5220\u9664 +doclet.deprecated_modules=\u5DF2\u8FC7\u65F6\u6A21\u5757 doclet.deprecated_packages=\u5DF2\u8FC7\u65F6\u7A0B\u5E8F\u5305 doclet.deprecated_classes=\u5DF2\u8FC7\u65F6\u7684\u7C7B doclet.deprecated_enums=\u5DF2\u8FC7\u65F6\u7684\u679A\u4E3E @@ -275,6 +282,8 @@ doclet.usage.tagletpath.description=Taglet \u7684\u8DEF\u5F84 doclet.usage.charset.parameters= doclet.usage.charset.description=\u7528\u4E8E\u8DE8\u5E73\u53F0\u67E5\u770B\u751F\u6210\u7684\u6587\u6863\u7684\u5B57\u7B26\u96C6 +doclet.usage.javafx.description=\u542F\u7528 javafx \u529F\u80FD + doclet.usage.helpfile.parameters= doclet.usage.helpfile.description=\u5305\u542B\u5E2E\u52A9\u94FE\u63A5\u6240\u94FE\u63A5\u5230\u7684\u6587\u4EF6 @@ -295,6 +304,8 @@ doclet.usage.frames.description=\u5141\u8BB8\u5728\u751F\u6210\u7684\u8F93\u51FA doclet.usage.no-frames.description=\u7981\u6B62\u5728\u751F\u6210\u7684\u8F93\u51FA\u4E2D\u4F7F\u7528\u5E27 +doclet.usage.allow-script-in-comments.description=\u5141\u8BB8\u5728\u9009\u9879\u548C\u6CE8\u91CA\u4E2D\u4F7F\u7528 JavaScript + doclet.usage.xdocrootparent.parameters= doclet.usage.xdocrootparent.description=\u5C06\u6587\u6863\u6CE8\u91CA\u4E2D\u51FA\u73B0\u7684\u6240\u6709\u540E\u8DDF /.. \u7684 @docRoot \u66FF\u6362\u4E3A\n diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/AbstractDoclet.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/AbstractDoclet.java index 118614c5b8c..0d8ae64b3bd 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/AbstractDoclet.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/AbstractDoclet.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,7 +34,7 @@ import javax.lang.model.element.TypeElement; import jdk.javadoc.doclet.Doclet; import jdk.javadoc.doclet.DocletEnvironment; -import jdk.javadoc.doclets.StandardDoclet; +import jdk.javadoc.doclet.StandardDoclet; import jdk.javadoc.internal.doclets.formats.html.HtmlDoclet; import jdk.javadoc.internal.doclets.toolkit.builders.AbstractBuilder; import jdk.javadoc.internal.doclets.toolkit.builders.BuilderFactory; @@ -64,7 +64,7 @@ public abstract class AbstractDoclet implements Doclet { /** * The global configuration information for this run. */ - private Configuration configuration; + private BaseConfiguration configuration; protected Messages messages; @@ -181,7 +181,7 @@ public abstract class AbstractDoclet implements Doclet { * * @return the configuration of the doclet. */ - public abstract Configuration getConfiguration(); + public abstract BaseConfiguration getConfiguration(); /** * Start the generation of files. Call generate methods in the individual diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Configuration.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/BaseConfiguration.java similarity index 94% rename from langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Configuration.java rename to langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/BaseConfiguration.java index d34323f94ef..e1ca4018e95 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Configuration.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/BaseConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,13 +26,13 @@ package jdk.javadoc.internal.doclets.toolkit; import java.io.*; +import java.lang.ref.*; import java.util.*; import javax.lang.model.element.Element; import javax.lang.model.element.ModuleElement; import javax.lang.model.element.PackageElement; import javax.lang.model.element.TypeElement; -import javax.lang.model.util.ElementFilter; import javax.lang.model.util.SimpleElementVisitor9; import javax.tools.JavaFileManager; import javax.tools.JavaFileObject; @@ -55,13 +55,15 @@ import jdk.javadoc.internal.doclets.toolkit.util.MetaKeywords; import jdk.javadoc.internal.doclets.toolkit.util.SimpleDocletException; import jdk.javadoc.internal.doclets.toolkit.util.TypeElementCatalog; import jdk.javadoc.internal.doclets.toolkit.util.Utils; +import jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap; import jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap.GetterSetter; +import jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap.Kind; import static javax.tools.Diagnostic.Kind.*; /** * Configure the output based on the options. Doclets should sub-class - * Configuration, to configure and add their own options. This class contains + * BaseConfiguration, to configure and add their own options. This class contains * all user options which are supported by the 1.1 doclet and the standard * doclet. * @@ -74,7 +76,11 @@ import static javax.tools.Diagnostic.Kind.*; * @author Atul Dambalkar. * @author Jamie Ho */ -public abstract class Configuration { +public abstract class BaseConfiguration { + /** + * The doclet that created this configuration. + */ + public final Doclet doclet; /** * The factory for builders. @@ -293,6 +299,8 @@ public abstract class Configuration { private List groups; + private final Map>> typeElementMemberCache; + public abstract Messages getMessages(); public abstract Resources getResources(); @@ -305,7 +313,7 @@ public abstract class Configuration { /** * This method should be defined in all those doclets (configurations), - * which want to derive themselves from this Configuration. This method + * which want to derive themselves from this BaseConfiguration. This method * can be used to finish up the options setup. * * @return true if successful and false otherwise @@ -343,13 +351,16 @@ public abstract class Configuration { "jdk.javadoc.internal.doclets.toolkit.resources.doclets"; /** * Constructs the configurations needed by the doclet. + * @param doclet the doclet that created this configuration */ - public Configuration() { + public BaseConfiguration(Doclet doclet) { + this.doclet = doclet; excludedDocFileDirs = new HashSet<>(); excludedQualifiers = new HashSet<>(); setTabWidth(DocletConstants.DEFAULT_TAB_STOP_LENGTH); metakeywords = new MetaKeywords(this); groups = new ArrayList<>(0); + typeElementMemberCache = new HashMap<>(); } private boolean initialized = false; @@ -442,6 +453,11 @@ public abstract class Configuration { } } + // add entries for modules which may not have exported packages + modules.forEach((ModuleElement mdle) -> { + modulePackages.computeIfAbsent(mdle, m -> Collections.emptySet()); + }); + modules.addAll(modulePackages.keySet()); showModules = !modules.isEmpty(); for (Set pkgs : modulePackages.values()) { @@ -507,7 +523,7 @@ public abstract class Configuration { return true; } }, - new Hidden(resources, "-javafx") { + new Option(resources, "--javafx -javafx") { @Override public boolean process(String opt, List args) { javafx = true; @@ -683,7 +699,11 @@ public abstract class Configuration { typeElementCatalog = new TypeElementCatalog(includedTypeElements, this); initTagletManager(customTagStrs); groups.stream().forEach((grp) -> { - group.checkPackageGroups(grp.value1, grp.value2); + if (showModules) { + group.checkModuleGroups(grp.value1, grp.value2); + } else { + group.checkPackageGroups(grp.value1, grp.value2); + } }); } @@ -1025,7 +1045,7 @@ public abstract class Configuration { */ public InputStream getBuilderXML() throws DocFileIOException { return builderXMLPath == null ? - Configuration.class.getResourceAsStream(DEFAULT_BUILDER_XML) : + BaseConfiguration.class.getResourceAsStream(DEFAULT_BUILDER_XML) : DocFile.createFileForInput(this, builderXMLPath).openInputStream(); } @@ -1066,11 +1086,14 @@ public abstract class Configuration { private final int argCount; protected Option(Resources resources, String name, int argCount) { - this(resources, "doclet.usage." + name.toLowerCase().replaceAll("^-+", ""), name, argCount); + this(resources, null, name, argCount); } protected Option(Resources resources, String keyBase, String name, int argCount) { this.names = name.trim().split("\\s+"); + if (keyBase == null) { + keyBase = "doclet.usage." + names[0].toLowerCase().replaceAll("^-+", ""); + } String desc = getOptionsMessage(resources, keyBase + ".description"); if (desc.isEmpty()) { this.description = ""; @@ -1116,7 +1139,7 @@ public abstract class Configuration { @Override public String toString() { - return names.toString(); + return Arrays.toString(names); } @Override @@ -1249,4 +1272,18 @@ public abstract class Configuration { public boolean isAllowScriptInComments() { return allowScriptInComments; } + + public VisibleMemberMap getVisibleMemberMap(TypeElement te, VisibleMemberMap.Kind kind) { + EnumMap> cacheMap = typeElementMemberCache + .computeIfAbsent(te, k -> new EnumMap<>(VisibleMemberMap.Kind.class)); + + Reference vmapRef = cacheMap.get(kind); + // recompute, if referent has been garbage collected + VisibleMemberMap vMap = vmapRef == null ? null : vmapRef.get(); + if (vMap == null) { + vMap = new VisibleMemberMap(te, kind, this); + cacheMap.put(kind, new SoftReference<>(vMap)); + } + return vMap; + } } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/CommentUtils.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/CommentUtils.java index d9f6c38f1bb..12a5d5501c8 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/CommentUtils.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/CommentUtils.java @@ -64,13 +64,13 @@ import jdk.javadoc.internal.doclets.toolkit.util.Utils; public class CommentUtils { - final Configuration configuration; + final BaseConfiguration configuration; final DocTreeFactory treeFactory; final HashMap dcTreesMap = new HashMap<>(); final DocTrees trees; final Elements elementUtils; - protected CommentUtils(Configuration configuration) { + protected CommentUtils(BaseConfiguration configuration) { this.configuration = configuration; trees = configuration.docEnv.getDocTrees(); treeFactory = trees.getDocTreeFactory(); @@ -110,7 +110,7 @@ public class CommentUtils { return (DocTree) text; } - public void setEnumValuesTree(Configuration config, Element e) { + public void setEnumValuesTree(BaseConfiguration config, Element e) { Utils utils = config.utils; String klassName = utils.getSimpleName(utils.getEnclosingTypeElement(e)); @@ -126,7 +126,7 @@ public class CommentUtils { dcTreesMap.put(e, new DocCommentDuo(null, docTree)); } - public void setEnumValueOfTree(Configuration config, Element e) { + public void setEnumValueOfTree(BaseConfiguration config, Element e) { List fullBody = new ArrayList<>(); fullBody.add(treeFactory.newTextTree(config.getText("doclet.enum_valueof_doc.fullbody"))); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Messages.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Messages.java index 689a45c9a34..684d2275ccc 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Messages.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Messages.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -43,7 +43,7 @@ import static javax.tools.Diagnostic.Kind.*; * Messages are reported to the doclet's {@link Reporter reporter}. */ public class Messages { - private final Configuration configuration; + private final BaseConfiguration configuration; private final Resources resources; private Reporter reporter; @@ -55,7 +55,7 @@ public class Messages { * the doclet's resources, reporter, and additional methods and state * used to filter out messages, if any, which should be suppressed. */ - public Messages(Configuration configuration) { + public Messages(BaseConfiguration configuration) { this.configuration = configuration; resources = configuration.getResources(); } @@ -155,7 +155,7 @@ public class Messages { } // Lazy init the reporter for now, until we can fix/improve - // the init of ConfigurationImpl in HtmlDoclet (and similar.) + // the init of HtmlConfiguration in HtmlDoclet (and similar.) private void initReporter() { if (reporter == null) { reporter = configuration.reporter; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Resources.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Resources.java index 7c1a1683bcf..8c0d3039538 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Resources.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/Resources.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -39,7 +39,7 @@ import java.util.ResourceBundle; * HTML doclet. */ public class Resources { - private final Configuration configuration; + private final BaseConfiguration configuration; private final String commonBundleName; private final String docletBundleName; @@ -58,7 +58,7 @@ public class Resources { * @param docletBundleName the name of the bundle containing the strings * specific to a particular format */ - public Resources(Configuration configuration, String commonBundleName, String docletBundleName) { + public Resources(BaseConfiguration configuration, String commonBundleName, String docletBundleName) { this.configuration = configuration; this.commonBundleName = commonBundleName; this.docletBundleName = docletBundleName; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/WorkArounds.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/WorkArounds.java index 50ffb6bafef..7dc42305340 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/WorkArounds.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/WorkArounds.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -46,7 +46,6 @@ import javax.lang.model.type.TypeMirror; import javax.lang.model.util.Elements; import javax.tools.FileObject; import javax.tools.JavaFileManager.Location; -import javax.tools.JavaFileObject; import com.sun.source.tree.CompilationUnitTree; import com.sun.source.util.JavacTask; @@ -62,7 +61,6 @@ import com.sun.tools.javac.code.Symbol.MethodSymbol; import com.sun.tools.javac.code.Symbol.ModuleSymbol; import com.sun.tools.javac.code.Symbol.PackageSymbol; import com.sun.tools.javac.code.Symbol.VarSymbol; -import com.sun.tools.javac.code.Symtab; import com.sun.tools.javac.comp.AttrContext; import com.sun.tools.javac.comp.Env; import com.sun.tools.javac.model.JavacElements; @@ -91,13 +89,13 @@ import static javax.lang.model.element.ElementKind.*; */ public class WorkArounds { - public final Configuration configuration; + public final BaseConfiguration configuration; public final ToolEnvironment toolEnv; public final Utils utils; private DocLint doclint; - public WorkArounds(Configuration configuration) { + public WorkArounds(BaseConfiguration configuration) { this.configuration = configuration; this.utils = this.configuration.utils; this.toolEnv = ((DocEnvImpl)this.configuration.docEnv).toolEnv; @@ -297,6 +295,33 @@ public class WorkArounds { return null; } + // TODO: the method jx.l.m.Elements::overrides does not check + // the return type, see JDK-8174840 until that is resolved, + // use a copy of the same method, with a return type check. + + // Note: the rider.overrides call in this method *must* be consistent + // with the call in overrideType(....), the method above. + public boolean overrides(ExecutableElement e1, ExecutableElement e2, TypeElement cls) { + MethodSymbol rider = (MethodSymbol)e1; + MethodSymbol ridee = (MethodSymbol)e2; + ClassSymbol origin = (ClassSymbol)cls; + + return rider.name == ridee.name && + + // not reflexive as per JLS + rider != ridee && + + // we don't care if ridee is static, though that wouldn't + // compile + !rider.isStatic() && + + // Symbol.overrides assumes the following + ridee.isMemberOf(origin, toolEnv.getTypes()) && + + // check access, signatures and check return types + rider.overrides(ridee, origin, toolEnv.getTypes(), true); + } + // TODO: jx.l.m ? public Location getLocationForModule(ModuleElement mdle) { ModuleSymbol msym = (ModuleSymbol)mdle; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AbstractBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AbstractBuilder.java index 07201af8f1e..232c8712660 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AbstractBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AbstractBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ import java.util.*; import javax.lang.model.element.PackageElement; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; import jdk.javadoc.internal.doclets.toolkit.Messages; @@ -65,7 +65,7 @@ public abstract class AbstractBuilder { /** * The configuration used in this run of the doclet. */ - final Configuration configuration; + final BaseConfiguration configuration; /** * Keep track of which packages we have seen for @@ -79,7 +79,7 @@ public abstract class AbstractBuilder { */ final LayoutParser layoutParser; - Context(Configuration configuration, + Context(BaseConfiguration configuration, Set containingPackagesSeen, LayoutParser layoutParser) { this.configuration = configuration; @@ -91,7 +91,7 @@ public abstract class AbstractBuilder { /** * The configuration used in this run of the doclet. */ - protected final Configuration configuration; + protected final BaseConfiguration configuration; protected final Messages messages; protected final Resources resources; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AbstractMemberBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AbstractMemberBuilder.java index 3bc2b1a1939..f0d11e9838d 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AbstractMemberBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AbstractMemberBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,7 +33,6 @@ import java.util.TreeSet; import javax.lang.model.element.Element; -import jdk.javadoc.internal.doclets.formats.html.ConfigurationImpl; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeFieldBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeFieldBuilder.java index 9026429b7c9..a5e61be42a3 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeFieldBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeFieldBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ import javax.lang.model.element.Element; import javax.lang.model.element.TypeElement; import jdk.javadoc.internal.doclets.toolkit.AnnotationTypeFieldWriter; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; import jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap; @@ -90,7 +90,7 @@ public class AnnotationTypeFieldBuilder extends AbstractMemberBuilder { super(context); this.typeElement = typeElement; this.writer = writer; - this.visibleMemberMap = new VisibleMemberMap(typeElement, memberType, configuration); + this.visibleMemberMap = configuration.getVisibleMemberMap(typeElement, memberType); this.members = this.visibleMemberMap.getMembers(typeElement); } @@ -193,7 +193,7 @@ public class AnnotationTypeFieldBuilder extends AbstractMemberBuilder { /** * Build the comments for the member. Do nothing if - * {@link Configuration#nocomment} is set to true. + * {@link BaseConfiguration#nocomment} is set to true. * * @param node the XML element that specifies which components to document * @param annotationDocTree the content tree to which the documentation will be added diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeRequiredMemberBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeRequiredMemberBuilder.java index 412f723ef16..1c368a2a623 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeRequiredMemberBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeRequiredMemberBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ import javax.lang.model.element.Element; import javax.lang.model.element.TypeElement; import jdk.javadoc.internal.doclets.toolkit.AnnotationTypeRequiredMemberWriter; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; import jdk.javadoc.internal.doclets.toolkit.util.VisibleMemberMap; @@ -91,7 +91,7 @@ public class AnnotationTypeRequiredMemberBuilder extends AbstractMemberBuilder { super(context); this.typeElement = typeElement; this.writer = writer; - this.visibleMemberMap = new VisibleMemberMap(typeElement, memberType, configuration); + this.visibleMemberMap = configuration.getVisibleMemberMap(typeElement, memberType); this.members = this.visibleMemberMap.getMembers(typeElement); } @@ -192,7 +192,7 @@ public class AnnotationTypeRequiredMemberBuilder extends AbstractMemberBuilder { /** * Build the comments for the member. Do nothing if - * {@link Configuration#nocomment} is set to true. + * {@link BaseConfiguration#nocomment} is set to true. * * @param node the XML element that specifies which components to document * @param annotationDocTree the content tree to which the documentation will be added diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/BuilderFactory.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/BuilderFactory.java index 2ca7ac25a0b..0a51c9102b7 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/BuilderFactory.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/BuilderFactory.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -35,7 +35,7 @@ import javax.lang.model.type.TypeMirror; import jdk.javadoc.internal.doclets.toolkit.AnnotationTypeWriter; import jdk.javadoc.internal.doclets.toolkit.ClassWriter; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.PropertyWriter; import jdk.javadoc.internal.doclets.toolkit.WriterFactory; import jdk.javadoc.internal.doclets.toolkit.util.ClassTree; @@ -56,7 +56,7 @@ public class BuilderFactory { /** * The current configuration of the doclet. */ - private final Configuration configuration; + private final BaseConfiguration configuration; /** * The factory to retrieve the required writers from. @@ -70,7 +70,7 @@ public class BuilderFactory { * @param configuration the configuration for the current doclet * being executed. */ - public BuilderFactory (Configuration configuration) { + public BuilderFactory (BaseConfiguration configuration) { this.configuration = configuration; this.writerFactory = configuration.getWriterFactory(); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstantsSummaryBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstantsSummaryBuilder.java index 75a01fa5c73..a1909f75f05 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstantsSummaryBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstantsSummaryBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -273,8 +273,8 @@ public class ConstantsSummaryBuilder extends AbstractBuilder { * @return true if the given package has constant fields to document. */ private boolean hasConstantField (TypeElement typeElement) { - VisibleMemberMap visibleMemberMapFields = new VisibleMemberMap(typeElement, - VisibleMemberMap.Kind.FIELDS, configuration); + VisibleMemberMap visibleMemberMapFields = configuration.getVisibleMemberMap(typeElement, + VisibleMemberMap.Kind.FIELDS); List fields = visibleMemberMapFields.getLeafMembers(); for (Element f : fields) { VariableElement field = (VariableElement)f; @@ -329,10 +329,10 @@ public class ConstantsSummaryBuilder extends AbstractBuilder { */ public ConstantFieldBuilder(TypeElement typeElement) { this.typeElement = typeElement; - visibleMemberMapFields = new VisibleMemberMap(typeElement, - VisibleMemberMap.Kind.FIELDS, configuration); - visibleMemberMapEnumConst = new VisibleMemberMap(typeElement, - VisibleMemberMap.Kind.ENUM_CONSTANTS, configuration); + visibleMemberMapFields = configuration.getVisibleMemberMap(typeElement, + VisibleMemberMap.Kind.FIELDS); + visibleMemberMapEnumConst = configuration.getVisibleMemberMap(typeElement, + VisibleMemberMap.Kind.ENUM_CONSTANTS); } /** diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstructorBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstructorBuilder.java index ee8076bb72f..c569fd92261 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstructorBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ConstructorBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ import javax.lang.model.element.Element; import javax.lang.model.element.ExecutableElement; import javax.lang.model.element.TypeElement; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.ConstructorWriter; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; @@ -94,11 +94,8 @@ public class ConstructorBuilder extends AbstractMemberBuilder { super(context); this.typeElement = typeElement; this.writer = writer; - visibleMemberMap = - new VisibleMemberMap( - typeElement, - VisibleMemberMap.Kind.CONSTRUCTORS, - configuration); + visibleMemberMap = configuration.getVisibleMemberMap(typeElement, + VisibleMemberMap.Kind.CONSTRUCTORS); constructors = visibleMemberMap.getMembers(typeElement); for (Element ctor : constructors) { if (utils.isProtected(ctor) || utils.isPrivate(ctor)) { @@ -195,7 +192,7 @@ public class ConstructorBuilder extends AbstractMemberBuilder { /** * Build the comments for the constructor. Do nothing if - * {@link Configuration#nocomment} is set to true. + * {@link BaseConfiguration#nocomment} is set to true. * * @param node the XML element that specifies which components to document * @param constructorDocTree the content tree to which the documentation will be added diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/EnumConstantBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/EnumConstantBuilder.java index ddb6619225e..227157056ba 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/EnumConstantBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/EnumConstantBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ import javax.lang.model.element.Element; import javax.lang.model.element.TypeElement; import javax.lang.model.element.VariableElement; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; import jdk.javadoc.internal.doclets.toolkit.EnumConstantWriter; @@ -89,11 +89,8 @@ public class EnumConstantBuilder extends AbstractMemberBuilder { super(context); this.typeElement = typeElement; this.writer = writer; - visibleMemberMap = - new VisibleMemberMap( - typeElement, - VisibleMemberMap.Kind.ENUM_CONSTANTS, - configuration); + visibleMemberMap = configuration.getVisibleMemberMap(typeElement, + VisibleMemberMap.Kind.ENUM_CONSTANTS); enumConstants = visibleMemberMap.getMembers(typeElement); } @@ -178,7 +175,7 @@ public class EnumConstantBuilder extends AbstractMemberBuilder { /** * Build the comments for the enum constant. Do nothing if - * {@link Configuration#nocomment} is set to true. + * {@link BaseConfiguration#nocomment} is set to true. * * @param node the XML element that specifies which components to document * @param enumConstantsTree the content tree to which the documentation will be added diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/FieldBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/FieldBuilder.java index ccb5671b9ab..f2f684ac16e 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/FieldBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/FieldBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ import javax.lang.model.element.Element; import javax.lang.model.element.TypeElement; import javax.lang.model.element.VariableElement; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; import jdk.javadoc.internal.doclets.toolkit.FieldWriter; @@ -90,11 +90,8 @@ public class FieldBuilder extends AbstractMemberBuilder { super(context); this.typeElement = typeElement; this.writer = writer; - visibleMemberMap = - new VisibleMemberMap( - typeElement, - VisibleMemberMap.Kind.FIELDS, - configuration); + visibleMemberMap = configuration.getVisibleMemberMap(typeElement, + VisibleMemberMap.Kind.FIELDS); fields = visibleMemberMap.getLeafMembers(); } @@ -179,7 +176,7 @@ public class FieldBuilder extends AbstractMemberBuilder { /** * Build the comments for the field. Do nothing if - * {@link Configuration#nocomment} is set to true. + * {@link BaseConfiguration#nocomment} is set to true. * * @param node the XML element that specifies which components to document * @param fieldDocTree the content tree to which the documentation will be added diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/LayoutParser.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/LayoutParser.java index f74751cb51b..8c806bdb70d 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/LayoutParser.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/LayoutParser.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ import java.util.*; import javax.xml.parsers.*; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException; import jdk.javadoc.internal.doclets.toolkit.util.SimpleDocletException; import org.xml.sax.*; @@ -56,11 +56,11 @@ public class LayoutParser extends DefaultHandler { */ private final Map xmlElementsMap; private XMLNode currentNode; - private final Configuration configuration; + private final BaseConfiguration configuration; private String currentRoot; private boolean isParsing; - private LayoutParser(Configuration configuration) { + private LayoutParser(BaseConfiguration configuration) { xmlElementsMap = new HashMap<>(); this.configuration = configuration; } @@ -71,7 +71,7 @@ public class LayoutParser extends DefaultHandler { * @param configuration the current configuration of the doclet. * @return an instance of the BuilderXML. */ - public static LayoutParser getInstance(Configuration configuration) { + public static LayoutParser getInstance(BaseConfiguration configuration) { return new LayoutParser(configuration); } @@ -95,7 +95,7 @@ public class LayoutParser extends DefaultHandler { } catch (IOException | ParserConfigurationException | SAXException e) { String message = (configuration.builderXMLPath == null) ? configuration.getResources().getText("doclet.exception.read.resource", - Configuration.DEFAULT_BUILDER_XML, e) + BaseConfiguration.DEFAULT_BUILDER_XML, e) : configuration.getResources().getText("doclet.exception.read.file", configuration.builderXMLPath, e); throw new SimpleDocletException(message, e); diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MemberSummaryBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MemberSummaryBuilder.java index 886c31ff9d4..c4c600fbc5f 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MemberSummaryBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MemberSummaryBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,6 +32,12 @@ import javax.lang.model.element.Element; import javax.lang.model.element.ExecutableElement; import javax.lang.model.element.TypeElement; import javax.lang.model.element.VariableElement; +import javax.lang.model.type.ArrayType; +import javax.lang.model.type.DeclaredType; +import javax.lang.model.type.ExecutableType; +import javax.lang.model.type.PrimitiveType; +import javax.lang.model.type.TypeMirror; +import javax.lang.model.util.SimpleTypeVisitor9; import com.sun.source.doctree.DocTree; import com.sun.source.doctree.DocTree.Kind; @@ -63,10 +69,6 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { */ public static final String NAME = "MemberSummary"; - /** - * The visible members for the given class. - */ - private final EnumMap visibleMemberMaps; /** * The member summary writers for the given class. */ @@ -88,14 +90,6 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { super(context); this.typeElement = typeElement; memberSummaryWriters = new EnumMap<>(VisibleMemberMap.Kind.class); - visibleMemberMaps = new EnumMap<>(VisibleMemberMap.Kind.class); - for (VisibleMemberMap.Kind kind : VisibleMemberMap.Kind.values()) { - visibleMemberMaps.put(kind, - new VisibleMemberMap( - typeElement, - kind, - configuration)); - } } /** @@ -111,7 +105,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { classWriter.getTypeElement()); WriterFactory wf = context.configuration.getWriterFactory(); for (VisibleMemberMap.Kind kind : VisibleMemberMap.Kind.values()) { - MemberSummaryWriter msw = builder.visibleMemberMaps.get(kind).noVisibleMembers() + MemberSummaryWriter msw = builder.getVisibleMemberMap(kind).noVisibleMembers() ? null : wf.getMemberSummaryWriter(classWriter, kind); builder.memberSummaryWriters.put(kind, msw); @@ -132,7 +126,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { annotationTypeWriter.getAnnotationTypeElement()); WriterFactory wf = context.configuration.getWriterFactory(); for (VisibleMemberMap.Kind kind : VisibleMemberMap.Kind.values()) { - MemberSummaryWriter msw = builder.visibleMemberMaps.get(kind).noVisibleMembers() + MemberSummaryWriter msw = builder.getVisibleMemberMap(kind).noVisibleMembers() ? null : wf.getMemberSummaryWriter(annotationTypeWriter, kind); builder.memberSummaryWriters.put(kind, msw); @@ -151,25 +145,25 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { /** * Return the specified visible member map. * - * @param type the type of visible member map to return. + * @param kind the kind of visible member map to return. * @return the specified visible member map. * @throws ArrayIndexOutOfBoundsException when the type is invalid. * @see VisibleMemberMap */ - public VisibleMemberMap getVisibleMemberMap(VisibleMemberMap.Kind type) { - return visibleMemberMaps.get(type); + public VisibleMemberMap getVisibleMemberMap(VisibleMemberMap.Kind kind) { + return configuration.getVisibleMemberMap(typeElement, kind); } /**. * Return the specified member summary writer. * - * @param type the type of member summary writer to return. + * @param kind the kind of member summary writer to return. * @return the specified member summary writer. * @throws ArrayIndexOutOfBoundsException when the type is invalid. * @see VisibleMemberMap */ - public MemberSummaryWriter getMemberSummaryWriter(VisibleMemberMap.Kind type) { - return memberSummaryWriters.get(type); + public MemberSummaryWriter getMemberSummaryWriter(VisibleMemberMap.Kind kind) { + return memberSummaryWriters.get(kind); } /** @@ -177,13 +171,13 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { * This information can be used for doclet specific documentation * generation. * - * @param type the type of members to return. + * @param kind the kind of elements to return. * @return a list of methods that will be documented. * @see VisibleMemberMap */ - public SortedSet members(VisibleMemberMap.Kind type) { + public SortedSet members(VisibleMemberMap.Kind kind) { TreeSet out = new TreeSet<>(comparator); - out.addAll(visibleMemberMaps.get(type).getLeafMembers()); + out.addAll(getVisibleMemberMap(kind).getLeafMembers()); return out; } @@ -198,7 +192,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { return !utils.getAnnotationMethods(typeElement).isEmpty(); } for (VisibleMemberMap.Kind kind : VisibleMemberMap.Kind.values()) { - VisibleMemberMap members = visibleMemberMaps.get(kind); + VisibleMemberMap members = getVisibleMemberMap(kind); if (!members.noVisibleMembers()) { return true; } @@ -216,7 +210,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.ENUM_CONSTANTS); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.ENUM_CONSTANTS); + getVisibleMemberMap(VisibleMemberMap.Kind.ENUM_CONSTANTS); addSummary(writer, visibleMemberMap, false, memberSummaryTree); } @@ -230,7 +224,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.ANNOTATION_TYPE_FIELDS); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.ANNOTATION_TYPE_FIELDS); + getVisibleMemberMap(VisibleMemberMap.Kind.ANNOTATION_TYPE_FIELDS); addSummary(writer, visibleMemberMap, false, memberSummaryTree); } @@ -244,7 +238,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.ANNOTATION_TYPE_MEMBER_OPTIONAL); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.ANNOTATION_TYPE_MEMBER_OPTIONAL); + getVisibleMemberMap(VisibleMemberMap.Kind.ANNOTATION_TYPE_MEMBER_OPTIONAL); addSummary(writer, visibleMemberMap, false, memberSummaryTree); } @@ -258,7 +252,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.ANNOTATION_TYPE_MEMBER_REQUIRED); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.ANNOTATION_TYPE_MEMBER_REQUIRED); + getVisibleMemberMap(VisibleMemberMap.Kind.ANNOTATION_TYPE_MEMBER_REQUIRED); addSummary(writer, visibleMemberMap, false, memberSummaryTree); } @@ -272,7 +266,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.FIELDS); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.FIELDS); + getVisibleMemberMap(VisibleMemberMap.Kind.FIELDS); addSummary(writer, visibleMemberMap, true, memberSummaryTree); } @@ -283,7 +277,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.PROPERTIES); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.PROPERTIES); + getVisibleMemberMap(VisibleMemberMap.Kind.PROPERTIES); addSummary(writer, visibleMemberMap, true, memberSummaryTree); } @@ -297,7 +291,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.INNER_CLASSES); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.INNER_CLASSES); + getVisibleMemberMap(VisibleMemberMap.Kind.INNER_CLASSES); addSummary(writer, visibleMemberMap, true, memberSummaryTree); } @@ -311,7 +305,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.METHODS); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.METHODS); + getVisibleMemberMap(VisibleMemberMap.Kind.METHODS); addSummary(writer, visibleMemberMap, true, memberSummaryTree); } @@ -325,7 +319,7 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { MemberSummaryWriter writer = memberSummaryWriters.get(VisibleMemberMap.Kind.CONSTRUCTORS); VisibleMemberMap visibleMemberMap = - visibleMemberMaps.get(VisibleMemberMap.Kind.CONSTRUCTORS); + getVisibleMemberMap(VisibleMemberMap.Kind.CONSTRUCTORS); addSummary(writer, visibleMemberMap, false, memberSummaryTree); } @@ -440,16 +434,10 @@ public class MemberSummaryBuilder extends AbstractMemberBuilder { if (null != setter) { VariableElement param = setter.getParameters().get(0); - String typeName = utils.getTypeName(param.asType(), false); - // Removal of type parameters and package information. - typeName = typeName.split("<")[0]; - if (typeName.contains(".")) { - typeName = typeName.substring(typeName.lastIndexOf(".") + 1); - } StringBuilder sb = new StringBuilder("#"); sb.append(utils.getSimpleName(setter)); if (!utils.isTypeVariable(param.asType())) { - sb.append("(").append(typeName).append(")"); + sb.append("(").append(utils.getTypeSignature(param.asType(), false, true)).append(")"); } blockTags.add(cmtutils.makeSeeTree(sb.toString(), setter)); } diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MethodBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MethodBuilder.java index ba0e88a287b..6d372fd68ef 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MethodBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MethodBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -32,8 +32,7 @@ import javax.lang.model.element.ExecutableElement; import javax.lang.model.element.TypeElement; import javax.lang.model.type.TypeMirror; -import jdk.javadoc.internal.doclets.formats.html.ConfigurationImpl; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; import jdk.javadoc.internal.doclets.toolkit.MethodWriter; @@ -94,10 +93,8 @@ public class MethodBuilder extends AbstractMemberBuilder { super(context); this.typeElement = typeElement; this.writer = writer; - visibleMemberMap = new VisibleMemberMap( - typeElement, - VisibleMemberMap.Kind.METHODS, - configuration); + visibleMemberMap = configuration.getVisibleMemberMap(typeElement, + VisibleMemberMap.Kind.METHODS); methods = visibleMemberMap.getLeafMembers(); } @@ -180,7 +177,7 @@ public class MethodBuilder extends AbstractMemberBuilder { /** * Build the comments for the method. Do nothing if - * {@link Configuration#nocomment} is set to true. + * {@link BaseConfiguration#nocomment} is set to true. * * @param node the XML element that specifies which components to document * @param methodDocTree the content tree to which the documentation will be added diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/PropertyBuilder.java b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/PropertyBuilder.java index 986924f61fb..7108c6739aa 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/PropertyBuilder.java +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/PropertyBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ import javax.lang.model.element.Element; import javax.lang.model.element.ExecutableElement; import javax.lang.model.element.TypeElement; -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; import jdk.javadoc.internal.doclets.toolkit.Content; import jdk.javadoc.internal.doclets.toolkit.DocletException; import jdk.javadoc.internal.doclets.toolkit.PropertyWriter; @@ -90,11 +90,8 @@ public class PropertyBuilder extends AbstractMemberBuilder { super(context); this.typeElement = typeElement; this.writer = writer; - visibleMemberMap = - new VisibleMemberMap( - typeElement, - VisibleMemberMap.Kind.PROPERTIES, - configuration); + visibleMemberMap = configuration.getVisibleMemberMap(typeElement, + VisibleMemberMap.Kind.PROPERTIES); properties = visibleMemberMap.getMembers(typeElement); } @@ -180,7 +177,7 @@ public class PropertyBuilder extends AbstractMemberBuilder { /** * Build the comments for the property. Do nothing if - * {@link Configuration#nocomment} is set to true. + * {@link BaseConfiguration#nocomment} is set to true. * * @param node the XML element that specifies which components to document * @param propertyDocTree the content tree to which the documentation will be added diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/resources/doclet.xml b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/resources/doclet.xml index 7a6c54d145a..3148605db46 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/resources/doclet.xml +++ b/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/resources/doclet.xml @@ -1,7 +1,7 @@ \n" + "\n" + "

     
    \n" + + "\n" + "
    ", ""); @@ -723,6 +727,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "\n" + "
     
    \n" + + "\n" + "
    \n" + "

    Deprecated API

    \n" + "

    Contents

    ", @@ -747,6 +755,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "
    ", "
  • \n" + "

    Package pkg

    "); @@ -761,6 +773,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
  • \n" + "
     
    \n" + + "\n" + "
    ", "
    \n" + "

    Class Hierarchy

    ", @@ -779,6 +795,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "
    "); // Negated test for src-html page @@ -797,6 +817,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "
    ", "
      \n" + "
    • \n" @@ -1005,6 +1029,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "
    ", "
    ", "
  • \n" @@ -1123,6 +1151,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "\n" + "
     
    \n" + + "\n" + "
    ", "
  • "); @@ -1136,6 +1168,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "\n" + "
     
    \n" + + "\n" + "
    \n" + "

    Deprecated API

    \n" + "

    Contents

    ", @@ -1160,6 +1196,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "
    ", "
  • \n" + "

    Package pkg

    "); @@ -1175,6 +1215,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
  • \n" + "
     
    \n" + + "\n" + "
    ", "

    Hierarchy For All Packages

    \n" + "Package Hierarchies:", @@ -1195,6 +1239,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "
    "); // Test for src-html page @@ -1213,6 +1261,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "
    ", "
      \n" + "
    • \n" @@ -1421,6 +1473,10 @@ public class TestHtmlVersion extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "
    ", "
    ", "
  • \n" diff --git a/langtools/test/jdk/javadoc/doclet/testIndentation/TestIndentation.java b/langtools/test/jdk/javadoc/doclet/testIndentation/TestIndentation.java index 69eb7a53925..4b1ae687de0 100644 --- a/langtools/test/jdk/javadoc/doclet/testIndentation/TestIndentation.java +++ b/langtools/test/jdk/javadoc/doclet/testIndentation/TestIndentation.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8011288 8062647 + * @bug 8011288 8062647 8175200 * @summary Erratic/inconsistent indentation of signatures * @library ../lib * @modules jdk.javadoc/jdk.javadoc.internal.tool @@ -46,7 +46,7 @@ public class TestIndentation extends JavadocTester { checkExit(Exit.OK); checkOutput("p/Indent.html", true, - "
    public <T> void m(T t1,",
    +                "
    public <T> void m​(T t1,",
                     "\n"
                     + "                  T t2)",
                     "\n"
    diff --git a/langtools/test/jdk/javadoc/doclet/testInterface/TestInterface.java b/langtools/test/jdk/javadoc/doclet/testInterface/TestInterface.java
    index a0ac81987bd..fe24c9c53d6 100644
    --- a/langtools/test/jdk/javadoc/doclet/testInterface/TestInterface.java
    +++ b/langtools/test/jdk/javadoc/doclet/testInterface/TestInterface.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -23,7 +23,7 @@
     
     /*
      * @test
    - * @bug      4682448 4947464 5029946 8025633 8026567 8035473 8139101
    + * @bug      4682448 4947464 5029946 8025633 8026567 8035473 8139101 8175200
      * @summary  Verify that the public modifier does not show up in the
      *           documentation for public methods, as recommended by the JLS.
      *           If A implements I and B extends A, B should be in the list of
    @@ -64,7 +64,7 @@ public class TestInterface extends JavadocTester {
             checkExit(Exit.OK);
     
             checkOutput("pkg/Interface.html", true,
    -                "
    int method()
    ", + "
    int method​()
    ", "
    static final int field
    ", // Make sure known implementing class list is correct and omits type parameters. "
    \n" @@ -119,7 +119,7 @@ public class TestInterface extends JavadocTester { + "
    "); checkOutput("pkg/Interface.html", false, - "public int method()", + "public int method​()", "public static final int field"); checkOutput("pkg/ClassWithStaticMethod.html", false, diff --git a/langtools/test/jdk/javadoc/doclet/testJavaFX/TestJavaFX.java b/langtools/test/jdk/javadoc/doclet/testJavaFX/TestJavaFX.java index c666c3384b6..e37083f7c59 100644 --- a/langtools/test/jdk/javadoc/doclet/testJavaFX/TestJavaFX.java +++ b/langtools/test/jdk/javadoc/doclet/testJavaFX/TestJavaFX.java @@ -23,7 +23,8 @@ /* * @test - * @bug 7112427 8012295 8025633 8026567 8061305 8081854 8150130 8162363 8167967 8172528 + * @bug 7112427 8012295 8025633 8026567 8061305 8081854 8150130 8162363 + * 8167967 8172528 8175200 8178830 * @summary Test of the JavaFX doclet features. * @author jvalenta * @library ../lib @@ -53,11 +54,11 @@ public class TestJavaFX extends JavadocTester { + "
    getRate(), \n" + "" + "setRate(double)
    ", - "
    public final void setRate(double value)
    \n" + "
    public final void setRate​(double value)
    \n" + "
    Sets the value of the property rate.
    \n" + "
    \n" + "
    Property description:
    ", - "
    public final double getRate()
    \n" + "
    public final double getRate​()
    \n" + "
    Gets the value of the property rate.
    \n" + "
    \n" + "
    Property description:
    ", @@ -77,7 +78,7 @@ public class TestJavaFX extends JavadocTester { "Property description:", "
  • ", + + "setTestMethodProperty​()", "\n" + "\n" + "\n" + + "​(java.util.List<T> foo)\n" + "\n" + "\n" + "\n" + "\n" + "\n" + + "betaProperty​()\n" + "\n" + "\n" + "\n" + "\n" + "\n" + + "deltaProperty​()\n" + "\n" + "\n" + "\n" + "\n" + "\n" + + "gammaProperty​()\n" + "" ); } /* * Force the doclet to emit a warning when processing a synthesized, - * DocComment, and ensure that the run succeeds. + * DocComment, and ensure that the run succeeds, using the newer + * --javafx flag. */ @Test void test4() { javadoc("-d", "out4", - "-javafx", + "--javafx", "-Xdoclint:none", "-sourcepath", testSrc, "-package", diff --git a/langtools/test/jdk/javadoc/doclet/testJavascript/TestJavascript.java b/langtools/test/jdk/javadoc/doclet/testJavascript/TestJavascript.java index 246265efcac..4b27ccd34a5 100644 --- a/langtools/test/jdk/javadoc/doclet/testJavascript/TestJavascript.java +++ b/langtools/test/jdk/javadoc/doclet/testJavascript/TestJavascript.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 4665566 4855876 7025314 8012375 8015997 8016328 8024756 8148985 8151921 + * @bug 4665566 4855876 7025314 8012375 8015997 8016328 8024756 8148985 8151921 8151743 * @summary Verify that the output has the right javascript. * @author jamieh * @library ../lib @@ -47,7 +47,11 @@ public class TestJavascript extends JavadocTester { checkExit(Exit.OK); checkOutput("pkg/C.html", true, - "Frames"); + "Frames", + ""); checkOutput("TestJavascript.html", true, "Frames"); @@ -119,5 +123,10 @@ public class TestJavascript extends JavadocTester { + " }\n" + " catch(err) {\n" + " }"); + + checkOutput("script.js", true, + "$(window).resize(function() {\n" + + " $('.navPadding').css('padding-top', $('.fixedNav').css(\"height\"));\n" + + " });"); } } diff --git a/langtools/test/jdk/javadoc/doclet/testLambdaFeature/TestLambdaFeature.java b/langtools/test/jdk/javadoc/doclet/testLambdaFeature/TestLambdaFeature.java index d303160e684..5591dfd1ffe 100644 --- a/langtools/test/jdk/javadoc/doclet/testLambdaFeature/TestLambdaFeature.java +++ b/langtools/test/jdk/javadoc/doclet/testLambdaFeature/TestLambdaFeature.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8004893 8022738 8029143 + * @bug 8004893 8022738 8029143 8175200 * @summary Make sure that the lambda feature changes work fine in * javadoc. * @author bpatel @@ -55,7 +55,7 @@ public class TestLambdaFeature extends JavadocTester { checkOutput("pkg/A.html", true, "", - "
    default void defaultMethod()
    ", + "
    default void defaultMethod​()
    ", "", - "
    default default void defaultMethod()
    "); + "
    default default void defaultMethod​()
    "); checkOutput("pkg/B.html", false, "", diff --git a/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/Check.java b/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/Check.java index cbf652281b9..4ec80f90465 100644 --- a/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/Check.java +++ b/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/Check.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,14 +24,14 @@ import java.util.EnumSet; import java.util.List; import java.util.Set; +import javax.lang.model.element.Element; import com.sun.source.doctree.DocTree; -import jdk.javadoc.doclet.taglet.Taglet; +import jdk.javadoc.doclet.Taglet; public class Check implements Taglet { private static final String TAG_NAME = "check"; - private static final String TAG_HEADER = "Check:"; private final EnumSet allowedSet = EnumSet.allOf(Location.class); @@ -45,6 +45,7 @@ public class Check implements Taglet { * * @return false since the tag is not an inline tag. */ + @Override public boolean isInlineTag() { return false; } @@ -54,29 +55,21 @@ public class Check implements Taglet { * * @return the name of this tag. */ + @Override public String getName() { return TAG_NAME; } /** - * Given the DocTree representation of this custom tag, return its string - * representation. - * - * @param tag the DocTree representing this custom tag. - */ - public String toString(DocTree tag) { - return "
    " + TAG_HEADER + ":
    " + - tag.toString() + "
    \n"; - } - - /** - * Given an array of DocTrees representing this custom tag, return its string + * Given a list of DocTrees representing this custom tag, return its string * representation. * * @param tags the array of tags representing this custom tag. + * @param element the declaration to which the enclosing comment belongs * @return null to test if the javadoc throws an exception or not. */ - public String toString(List tags) { + @Override + public String toString(List tags, Element element) { return null; } } diff --git a/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/TestLegacyTaglet.java b/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/TestLegacyTaglet.java index 685724cf149..84d3d3b2aed 100644 --- a/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/TestLegacyTaglet.java +++ b/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/TestLegacyTaglet.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 4638723 8015882 + * @bug 4638723 8015882 8176131 8176331 * @summary Test to ensure that the refactored version of the standard * doclet still works with Taglets that implement the 1.4.0 interface. * @author jamieh diff --git a/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/ToDoTaglet.java b/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/ToDoTaglet.java index 1a75f0510a7..bd779820305 100644 --- a/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/ToDoTaglet.java +++ b/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/ToDoTaglet.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,17 +24,17 @@ import java.util.EnumSet; import java.util.List; import java.util.Map; - import java.util.Set; +import javax.lang.model.element.Element; import com.sun.source.doctree.DocTree; import com.sun.source.doctree.TextTree; import com.sun.source.doctree.UnknownBlockTagTree; import com.sun.source.doctree.UnknownInlineTagTree; import com.sun.source.util.SimpleDocTreeVisitor; -import jdk.javadoc.doclet.taglet.Taglet; -import jdk.javadoc.doclet.taglet.Taglet.Location; -import static jdk.javadoc.doclet.taglet.Taglet.Location.*; +import jdk.javadoc.doclet.Taglet; +import jdk.javadoc.doclet.Taglet.Location; +import static jdk.javadoc.doclet.Taglet.Location.*; /** @@ -83,28 +83,16 @@ public class ToDoTaglet implements Taglet { return false; } - /** - * Given the DocTree representation of this custom - * tag, return its string representation. - * @param tag the DocTree representing this custom tag. - */ - public String toString(DocTree tag) { - - return "
    " + HEADER + "
    " - + "
    " + "" - + "setTestMethodProperty()" + "paused\n" @@ -87,10 +88,10 @@ public class TestJavaFX extends JavadocTester { + "title=\"class in pkg1\">C.BooleanProperty pausedProperty\n" + "
    Defines if paused. The second line.
    ", "

    isPaused

    \n" - + "
    public final double isPaused()
    \n" + + "
    public final double isPaused​()
    \n" + "
    Gets the value of the property paused.
    ", "

    setPaused

    \n" - + "
    public final void setPaused(boolean value)
    \n" + + "
    public final void setPaused​(boolean value)
    \n" + "
    Sets the value of the property paused.
    \n" + "
    \n" + "
    Property description:
    \n" @@ -98,7 +99,7 @@ public class TestJavaFX extends JavadocTester { + "
    Default value:
    \n" + "
    false
    ", "

    isPaused

    \n" - + "
    public final double isPaused()
    \n" + + "
    public final double isPaused​()
    \n" + "
    Gets the value of the property paused.
    \n" + "
    \n" + "
    Property description:
    \n" @@ -112,7 +113,7 @@ public class TestJavaFX extends JavadocTester { + "Timeline is expected to\n" + " be played. This is the second line.", "

    setRate

    \n" - + "
    public final void setRate(double value)
    \n" + + "
    public final void setRate​(double value)
    \n" + "
    Sets the value of the property rate.
    \n" + "
    \n" + "
    Property description:
    \n" @@ -123,7 +124,7 @@ public class TestJavaFX extends JavadocTester { + "
    Since:
    \n" + "
    JavaFX 8.0
    ", "

    getRate

    \n" - + "
    public final double getRate()
    \n" + + "
    public final double getRate​()
    \n" + "
    Gets the value of the property rate.
    \n" + "
    \n" + "
    Property description:
    \n" @@ -239,38 +240,39 @@ public class TestJavaFX extends JavadocTester { + "
    <T> java.lang.Object" + "alphaProperty" - + "(java.util.List<T> foo) 
    java.lang.Object" - + "betaProperty() 
    java.util.List<java.util.Set<? super java.lang.Object>>" + "" - + "deltaProperty() 
    java.util.List<java.lang.String>" - + "gammaProperty() default void
    " + "All Methods " + "" @@ -83,7 +83,7 @@ public class TestLambdaFeature extends JavadocTester { checkOutput("pkg/A.html", false, "
    default default voiddefault void
    " - + getText(tag) - + "
    \n"; - } - /** * Given an array of Tags representing this custom * tag, return its string representation. * @param tags the array of DocTrees representing this custom tag. + * @param element the declaration to which the enclosing comment belongs */ @Override - public String toString(List tags) { + public String toString(List tags, Element element) { if (tags.isEmpty()) { - return null; + return ""; } String result = "\n
    " + HEADER + "
    "; result += "\n" + "", // check the inherited from interfaces "

    Methods inherited from interface pkg1.PublicChild\n" + "

    "); + + checkOutput("pkg/PrivateParent.html", true, + "\n" + + ""); // Legacy anchor dimensions (6290760) checkOutput("pkg2/A.html", true, diff --git a/langtools/test/jdk/javadoc/doclet/testMemberSummary/pkg/PrivateParent.java b/langtools/test/jdk/javadoc/doclet/testMemberSummary/pkg/PrivateParent.java index a3fa4bd0f0b..86d671db7d4 100644 --- a/langtools/test/jdk/javadoc/doclet/testMemberSummary/pkg/PrivateParent.java +++ b/langtools/test/jdk/javadoc/doclet/testMemberSummary/pkg/PrivateParent.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,6 +24,12 @@ package pkg; class PrivateParent { + /** + * Test private constructor. + * @param i a test parameter. + */ + private PrivateParent(int i) { + } /** * Test to make sure the member summary inherits documentation diff --git a/langtools/test/jdk/javadoc/doclet/testMissingType/TestMissingType.java b/langtools/test/jdk/javadoc/doclet/testMissingType/TestMissingType.java new file mode 100644 index 00000000000..b544f7cb038 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testMissingType/TestMissingType.java @@ -0,0 +1,51 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8173804 + * @summary make sure doclet can handle missing types + * @library ../lib + * @modules jdk.javadoc/jdk.javadoc.internal.tool + * @build JavadocTester + * @run main TestMissingType + */ + +public class TestMissingType extends JavadocTester { + + public static void main(String... args) throws Exception { + TestMissingType tester = new TestMissingType(); + tester.runTests(); + } + + @Test + void test() { + javadoc("-d", "out", + "-use", + "-sourcepath", testSrc, + "p"); + checkExit(Exit.ERROR); + checkOutput(Output.STDERR, false, + "java.lang.UnsupportedOperationException: should not happen"); + } +} diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/v9/testpackage/Helper.java b/langtools/test/jdk/javadoc/doclet/testMissingType/p/MissingType.java similarity index 79% rename from jdk/test/tools/jar/multiRelease/data/runtimetest/v9/testpackage/Helper.java rename to langtools/test/jdk/javadoc/doclet/testMissingType/p/MissingType.java index 8d4517d0ee8..619b5848736 100644 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/v9/testpackage/Helper.java +++ b/langtools/test/jdk/javadoc/doclet/testMissingType/p/MissingType.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -20,14 +20,13 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ +package p; -package testpackage; - -public class Helper { - - private static final int HELPER_VERSION = 9; - - public static int getHelperVersion() { - return HELPER_VERSION; - } +public final class MissingType { + /** + * Do something with a missing type. + * + * @param out use the missing type + */ + public void encode(MissingMe out) {} } diff --git a/langtools/test/jdk/javadoc/doclet/testModules/TestIndirectExportsOpens.java b/langtools/test/jdk/javadoc/doclet/testModules/TestIndirectExportsOpens.java new file mode 100644 index 00000000000..182539b8395 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testModules/TestIndirectExportsOpens.java @@ -0,0 +1,207 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8178339 + * @summary Tests indirect exports and opens in the module summary page + * @modules jdk.javadoc/jdk.javadoc.internal.api + * jdk.javadoc/jdk.javadoc.internal.tool + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library ../lib /tools/lib + * @build toolbox.ToolBox toolbox.ModuleBuilder JavadocTester + * @run main TestIndirectExportsOpens + */ + +import java.nio.file.Path; +import java.nio.file.Paths; + +import toolbox.*; + +public class TestIndirectExportsOpens extends JavadocTester { + + public final ToolBox tb; + public static void main(String... args) throws Exception { + TestIndirectExportsOpens tester = new TestIndirectExportsOpens(); + tester.runTests(m -> new Object[] { Paths.get(m.getName()) }); + } + + public TestIndirectExportsOpens() { + tb = new ToolBox(); + } + + @Test + public void checkNoIndirects(Path base) throws Exception { + + ModuleBuilder mb0 = new ModuleBuilder(tb, "m") + .classes("package pm; public class A {}"); + Path p0 = mb0.write(base); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "a") + .requiresTransitive("m", p0) + .classes("package pa; public class NoOp {}") + .exports("pa"); + mb1.write(base); + + javadoc("-d", base.resolve("out-api").toString(), + "-quiet", + "--module-source-path", base.toString(), + "--expand-requires", "transitive", + "--module", "a"); + checkExit(Exit.OK); + verifyIndirectExports(false); + verifyIndirectOpens(false); + } + + @Test + public void checkExportsOpens(Path base) throws Exception { + + ModuleBuilder mb0 = new ModuleBuilder(tb, "m") + .classes("package pm; public class A {}") + .exports("pm") + .opens("pm"); + + Path p0 = mb0.write(base); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "a") + .requiresTransitive("m", p0) + .classes("package pa ; public class NoOp {}") + .exports("pa"); + mb1.write(base); + + javadoc("-d", base.resolve("out-api").toString(), + "-quiet", + "--module-source-path", base.toString(), + "--expand-requires", "transitive", + "--module", "a"); + checkExit(Exit.OK); + verifyIndirectExports(true); + verifyIndirectOpens(true); + } + + @Test + public void checkExportsToOpensTo(Path base) throws Exception { + + ModuleBuilder mb0 = new ModuleBuilder(tb, "m") + .classes("package pm; public class A {}") + .exportsTo("pm", "x") + .opensTo("pm", "x"); + + Path p0 = mb0.write(base); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "a") + .requiresTransitive("m", p0) + .classes("package pa ; public class NoOp {}") + .exports("pa"); + mb1.write(base); + + javadoc("-d", base.resolve("out-api").toString(), + "-quiet", + "--module-source-path", base.toString(), + "--expand-requires", "transitive", + "--module", "a"); + + checkExit(Exit.OK); + verifyIndirectExports(false); + verifyIndirectOpens(false); + } + + @Test + public void checkExportsToOpensToDetailMode(Path base) throws Exception { + + ModuleBuilder mb0 = new ModuleBuilder(tb, "m") + .classes("package exportsto; public class A {}") + .classes("package opensto; public class A {}") + .exportsTo("exportsto", "x") + .opensTo("opensto", "x"); + + Path p0 = mb0.write(base); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "a") + .requiresTransitive("m", p0) + .classes("package pa ; public class NoOp {}") + .exports("pa"); + mb1.write(base); + + javadoc("-d", base.resolve("out-detail").toString(), + "-quiet", + "--module-source-path", base.toString(), + "--expand-requires", "transitive", + "--show-module-contents", "all", + "--module", "a"); + + checkExit(Exit.OK); + + // In details mode all kinds of packages from java.base, + // could be listed in the indirects section, so just + // check for minimal expected strings. + checkOutput("a-summary.html", true, + "Indirect Exports table", + "\n" + + "\n" + + "\n"); + + checkOutput("a-summary.html", true, + "Indirect Opens table", + "\n" + + "\n" + + "\n"); + } + + void verifyIndirectExports(boolean present) { + verifyIndirects(present, false); + } + + void verifyIndirectOpens(boolean present) { + verifyIndirects(present, true); + } + + void verifyIndirects(boolean present, boolean opens) { + + String typeString = opens ? "Indirect Opens" : "Indirect Exports"; + + // Avoid false positives, just check for primary string absence. + if (!present) { + checkOutput("a-summary.html", false, typeString); + return; + } + + checkOutput("a-summary.html", present, + "
    "; diff --git a/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/UnderlineTaglet.java b/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/UnderlineTaglet.java index 56312516138..6f56ac11226 100644 --- a/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/UnderlineTaglet.java +++ b/langtools/test/jdk/javadoc/doclet/testLegacyTaglet/UnderlineTaglet.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,10 +24,11 @@ import java.util.EnumSet; import java.util.List; import java.util.Set; +import javax.lang.model.element.Element; import com.sun.source.doctree.DocTree; -import jdk.javadoc.doclet.taglet.Taglet; -import static jdk.javadoc.doclet.taglet.Taglet.Location.*; +import jdk.javadoc.doclet.Taglet; +import static jdk.javadoc.doclet.Taglet.Location.*; /** * A sample Inline Taglet representing {@underline ...}. The text @@ -69,20 +70,11 @@ public class UnderlineTaglet implements Taglet { /** * Given the DocTree representation of this custom * tag, return its string representation. - * @param tag he DocTree representation of this custom tag. + * @param tags the DocTree representation of this custom tag. + * @param element the declaration to which the enclosing comment belongs */ @Override - public String toString(DocTree tag) { - return "" + ToDoTaglet.getText(tag) + ""; - } - - /** - * This method should not be called since arrays of inline tags do not - * exist. Method {@link #tostring(DocTree)} should be used to convert this - * inline tag to a string. - */ - @Override - public String toString(List tags) { - return null; + public String toString(List tags, Element element) { + return "" + ToDoTaglet.getText(tags.get(0)) + ""; } } diff --git a/langtools/test/jdk/javadoc/doclet/testLiteralCodeInPre/TestLiteralCodeInPre.java b/langtools/test/jdk/javadoc/doclet/testLiteralCodeInPre/TestLiteralCodeInPre.java index bd34513110b..f91013c8754 100644 --- a/langtools/test/jdk/javadoc/doclet/testLiteralCodeInPre/TestLiteralCodeInPre.java +++ b/langtools/test/jdk/javadoc/doclet/testLiteralCodeInPre/TestLiteralCodeInPre.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8002387 8014636 8078320 + * @bug 8002387 8014636 8078320 8175200 * @summary Improve rendered HTML formatting for {@code} * @library ../lib * @modules jdk.javadoc/jdk.javadoc.internal.tool @@ -47,19 +47,19 @@ public class TestLiteralCodeInPre extends JavadocTester { checkExit(Exit.OK); checkOutput("pkg/Test.html", true, - "no_pre()\n" + "no_pre​()\n" + "
    abcdefghi
    ", - "no_pre_extra_whitespace()\n" + "no_pre_extra_whitespace​()\n" + "
    abc def ghi
    ", - "in_pre()\n" + "in_pre​()\n" + "
     abc def  ghi
    ", - "pre_after_text()\n" + "pre_after_text​()\n" + "
    xyz
     abc def  ghi
    ", - "after_pre()\n" + "after_pre​()\n" + "
    xyz
     pqr 
    abc def ghi
    ", - "back_in_pre()\n" + "back_in_pre​()\n" + "
    xyz
     pqr 
    mno
     abc def  ghi
    ", - "typical_usage_code()\n" + "typical_usage_code​()\n" + "
    Lorem ipsum dolor sit amet, consectetur adipiscing elit.\n" + " Example:
    \n"
                     + "   line 0 @Override\n"
    @@ -68,7 +68,7 @@ public class TestLiteralCodeInPre extends JavadocTester {
                     + "   line 3 }\n"
                     + " 
    \n" + " and so it goes.
    ", - "typical_usage_literal()\n" + "typical_usage_literal​()\n" + "
    Lorem ipsum dolor sit amet, consectetur adipiscing elit.\n" + " Example:
    \n"
                     + "   line 0 @Override\n"
    @@ -77,7 +77,7 @@ public class TestLiteralCodeInPre extends JavadocTester {
                     + "   line 3 }\n"
                     + " 
    \n" + " and so it goes.
    ", - "recommended_usage_literal()\n" + "recommended_usage_literal​()\n" + "
    Lorem ipsum dolor sit amet, consectetur adipiscing elit.\n" + " Example:
    \n"
                     + "   line 0 @Override\n"
    @@ -89,7 +89,7 @@ public class TestLiteralCodeInPre extends JavadocTester {
                     + " 
    \n"
                     + " id           \n"
                     + " 
    ", - "
    public void htmlAttrInPre1()
    \n" + "
    public void htmlAttrInPre1​()
    \n" + "
    More html tag outliers.\n" + "
    \n"
                     + " @Override\n"
    diff --git a/langtools/test/jdk/javadoc/doclet/testMemberInheritence/TestMemberInheritence.java b/langtools/test/jdk/javadoc/doclet/testMemberInheritence/TestMemberInheritence.java
    index 3ad67a283eb..62235eee870 100644
    --- a/langtools/test/jdk/javadoc/doclet/testMemberInheritence/TestMemberInheritence.java
    +++ b/langtools/test/jdk/javadoc/doclet/testMemberInheritence/TestMemberInheritence.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -23,7 +23,7 @@
     
     /*
      * @test
    - * @bug 4638588 4635809 6256068 6270645 8025633 8026567 8162363
    + * @bug 4638588 4635809 6256068 6270645 8025633 8026567 8162363 8175200
      * @summary Test to make sure that members are inherited properly in the Javadoc.
      *          Verify that inheritence labels are correct.
      * @author jamieh
    @@ -92,7 +92,7 @@ public class TestMemberInheritence extends JavadocTester {
                     "
    static java.time.Period" + "" - + "between(java.time.LocalDate startDateInclusive,\n" + + "between​(java.time.LocalDate startDateInclusive,\n" + " java.time.LocalDate endDateExclusive)" - + "returnTypeTest()", + + "returnTypeTest​()", // Check return type in member detail. "
    public "
    -                + "PublicChild returnTypeTest()
    "); + + "PublicChild returnTypeTest​()", + "
    " + + "PublicChild​()private " + + "PrivateParent​(int i)" + + "mexportsto
    mopensto
    \n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "
    " + typeString + " 
    FromPackages
    mpm
    \n"); + } + +} + diff --git a/langtools/test/jdk/javadoc/doclet/testModules/TestModuleServices.java b/langtools/test/jdk/javadoc/doclet/testModules/TestModuleServices.java new file mode 100644 index 00000000000..2d31c056316 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testModules/TestModuleServices.java @@ -0,0 +1,314 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8178067 + * @summary tests the module's services, such as provides and uses + * @modules jdk.javadoc/jdk.javadoc.internal.api + * jdk.javadoc/jdk.javadoc.internal.tool + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library ../lib /tools/lib + * @build toolbox.ToolBox toolbox.ModuleBuilder JavadocTester + * @run main TestModuleServices + */ + +import java.nio.file.Path; +import java.nio.file.Paths; + +import toolbox.*; + +public class TestModuleServices extends JavadocTester { + + public final ToolBox tb; + public static void main(String... args) throws Exception { + TestModuleServices tester = new TestModuleServices(); + tester.runTests(m -> new Object[] { Paths.get(m.getName()) }); + } + + public TestModuleServices() { + tb = new ToolBox(); + } + + @Test + public void checkUsesNoApiTagModuleModeDefault(Path base) throws Exception { + ModuleBuilder mb = new ModuleBuilder(tb, "m") + .comment("module m.\n@provides p1.A abc") // bogus tag + .uses("p1.A") + .uses("p1.B") + .exports("p1") + .classes("package p1; public class A {}") + .classes("package p1; public class B {}"); + mb.write(base); + + javadoc("-d", base.toString() + "/out", + "-quiet", + "--module-source-path", base.toString(), + "--module", "m"); + checkExit(Exit.OK); + + checkOutput("m-summary.html", false, + "

    Services

    "); + } + + @Test + public void checkUsesNoApiTagModuleModeAll(Path base) throws Exception { + ModuleBuilder mb = new ModuleBuilder(tb, "m") + .uses("p1.A") + .uses("p1.B") + .exports("p1") + .classes("package p1; public class A {}") + .classes("package p1; public class B {}"); + mb.write(base); + + javadoc("-d", base.toString() + "/out", + "-quiet", + "--show-module-contents", "all", + "--module-source-path", base.toString(), + "--module", "m"); + checkExit(Exit.OK); + + checkOutput("m-summary.html", true, + "

    Services

    "); + + checkOutput("m-summary.html", true, + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "
    Uses 
    TypeDescription
    A 
    B 
    \n"); + } + + @Test + public void checkUsesWithApiTagModuleModeDefault(Path base) throws Exception { + ModuleBuilder mb = new ModuleBuilder(tb, "m") + .comment("module m.\n@uses p1.A") + .uses("p1.A") + .uses("p1.B") + .exports("p1") + .classes("package p1; public class A {}") + .classes("package p1; public class B {}"); + mb.write(base); + + javadoc("-d", base.toString() + "/out", + "-quiet", + "--module-source-path", base.toString(), + "--module", "m"); + checkExit(Exit.OK); + + checkOutput("m-summary.html", true, + "

    Services

    "); + + checkOutput("m-summary.html", true, + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "
    Uses 
    TypeDescription
    A 
    \n"); + } + + @Test + public void checkProvidesNoApiTagModuleModeDefault(Path base) throws Exception { + ModuleBuilder mb = new ModuleBuilder(tb, "m") + .comment("module m.\n@uses p1.A") + .provides("p1.A", "p1.B") + .exports("p1") + .classes("package p1; public interface A {}") + .classes("package p1; public class B implements A {}") + .provides("p2.A", "p2.B") + .exports("p2") + .classes("package p2; public interface A {}") + .classes("package p2; public class B implements A {}"); + mb.write(base); + + javadoc("-d", base.toString() + "/out", + "-quiet", + "--module-source-path", base.toString(), + "--module", "m"); + + checkExit(Exit.OK); + + checkOutput("m-summary.html", false, + "

    Services

    "); + } + + @Test + public void checkProvidesNoApiTagModuleModeAll(Path base) throws Exception { + ModuleBuilder mb = new ModuleBuilder(tb, "m") + .comment("module m.\n@uses p1.A") // bogus uses tag + .provides("p1.A", "p1.B") + .exports("p1") + .classes("package p1; public interface A {}") + .classes("package p1; public class B implements A {}") + .provides("p2.A", "p2.B") + .exports("p2") + .classes("package p2; public interface A {}") + .classes("package p2; public class B implements A {}"); + mb.write(base); + + javadoc("-d", base.toString() + "/out", + "-quiet", + "--show-module-contents", "all", + "--module-source-path", base.toString(), + "--module", "m"); + + checkExit(Exit.OK); + + checkOutput("m-summary.html", true, + "

    Services

    "); + + checkOutput("m-summary.html", true, + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n"); + } + + @Test + public void checkProvidesWithApiTagModuleModeDefault(Path base) throws Exception { + ModuleBuilder mb = new ModuleBuilder(tb, "m") + .comment("module m.\n@provides p1.A abc") + .provides("p1.A", "p1.B") + .exports("p1") + .classes("package p1; public interface A {}") + .classes("package p1; public class B implements A {}") + .provides("p2.A", "p2.B") + .exports("p2") + .classes("package p2; public interface A {}") + .classes("package p2; public class B implements A {}"); + mb.write(base); + + javadoc("-d", base.toString() + "/out", + "-quiet", + "--module-source-path", base.toString(), + "--module", "m"); + + checkExit(Exit.OK); + + checkOutput("m-summary.html", true, + "

    Services

    "); + + checkOutput("m-summary.html", true, + "
    Provides 
    TypeDescription
    A 
    (Implementation(s): B)
    A 
    (Implementation(s): B)
    \n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "
    Provides 
    TypeDescription
    Aabc 
    \n"); + } + + @Test + public void checkUsesProvidesWithApiTagsModeDefault(Path base) throws Exception { + ModuleBuilder mb = new ModuleBuilder(tb, "m") + .comment("module m.\n@provides p1.A abc\n@uses p2.B def") + .provides("p1.A", "p1.B") + .exports("p1") + .classes("package p1; public interface A {}") + .classes("package p1; public class B implements A {}") + .provides("p2.A", "p2.B") + .uses("p2.B") + .exports("p2") + .classes("package p2; public interface A {}") + .classes("package p2; public class B implements A {}"); + mb.write(base); + + javadoc("-d", base.toString() + "/out", + "-quiet", + "--module-source-path", base.toString(), + "--module", "m"); + + checkExit(Exit.OK); + + checkOutput("m-summary.html", true, + "

    Services

    "); + + checkOutput("m-summary.html", true, + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "
    Provides 
    TypeDescription
    Aabc 
    ", + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "
    Uses 
    TypeDescription
    Bdef 
    \n"); + } + +} diff --git a/langtools/test/jdk/javadoc/doclet/testModules/TestModules.java b/langtools/test/jdk/javadoc/doclet/testModules/TestModules.java index 892b2462499..950211fad63 100644 --- a/langtools/test/jdk/javadoc/doclet/testModules/TestModules.java +++ b/langtools/test/jdk/javadoc/doclet/testModules/TestModules.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,9 @@ /* * @test - * @bug 8154119 8154262 8156077 8157987 8154261 8154817 8135291 8155995 8162363 8168766 8168688 8162674 8160196 + * @bug 8154119 8154262 8156077 8157987 8154261 8154817 8135291 8155995 8162363 + * 8168766 8168688 8162674 8160196 8175799 8174974 8176778 8177562 8175218 8175823 8166306 + * 8178043 * @summary Test modules support in javadoc. * @author bpatel * @library ../lib @@ -44,6 +46,7 @@ public class TestModules extends JavadocTester { @Test void testHtml4() { javadoc("-d", "out", "-use", + "-overview", testSrc("overview.html"), "--module-source-path", testSrc, "--module", "moduleA,moduleB", "testpkgmdlA", "testpkgmdlB"); @@ -65,6 +68,7 @@ public class TestModules extends JavadocTester { @Test void testHtml5() { javadoc("-d", "out-html5", "-html5", "-use", + "-overview", testSrc("overview.html"), "--module-source-path", testSrc, "--module", "moduleA,moduleB", "testpkgmdlA", "testpkgmdlB"); @@ -86,6 +90,7 @@ public class TestModules extends JavadocTester { @Test void testHtml4NoComment() { javadoc("-d", "out-nocomment", "-nocomment", "-use", + "-overview", testSrc("overview.html"), "--module-source-path", testSrc, "--module", "moduleA,moduleB", "testpkgmdlA", "testpkgmdlB"); @@ -103,6 +108,7 @@ public class TestModules extends JavadocTester { @Test void testHtml5NoComment() { javadoc("-d", "out-html5-nocomment", "-nocomment", "-html5", "-use", + "-overview", testSrc("overview.html"), "--module-source-path", testSrc, "--module", "moduleA,moduleB", "testpkgmdlA", "testpkgmdlB"); @@ -120,6 +126,7 @@ public class TestModules extends JavadocTester { @Test void testHtml4UnnamedModule() { javadoc("-d", "out-nomodule", "-use", + "-overview", testSrc("overview.html"), "-sourcepath", testSrc, "testpkgnomodule", "testpkgnomodule1"); checkExit(Exit.OK); @@ -136,6 +143,7 @@ public class TestModules extends JavadocTester { @Test void testHtml5UnnamedModule() { javadoc("-d", "out-html5-nomodule", "-html5", "-use", + "-overview", testSrc("overview.html"), "-sourcepath", testSrc, "testpkgnomodule", "testpkgnomodule1"); checkExit(Exit.OK); @@ -174,6 +182,19 @@ public class TestModules extends JavadocTester { checkNegatedModuleSummary(); } + /** + * Test generated module summary page of an aggregating module. + */ + @Test + void testAggregatorModuleSummary() { + javadoc("-d", "out-aggregatorModuleSummary", "-use", + "--module-source-path", testSrc, + "--expand-requires", "transitive", + "--module", "moduleT"); + checkExit(Exit.OK); + checkAggregatorModuleSummary(); + } + /** * Test generated module pages and pages with link to modules. */ @@ -181,11 +202,11 @@ public class TestModules extends JavadocTester { void testModuleFilesAndLinks() { javadoc("-d", "out-modulelinks", "--module-source-path", testSrc, - "--module", "moduleA", - "testpkgmdlA"); + "--module", "moduleA,moduleB", + "testpkgmdlA", "testpkgmdlB"); checkExit(Exit.OK); checkModuleFilesAndLinks(true); - checkNegatedOverviewFrame(); + checkOverviewFrame(true); } /** @@ -231,6 +252,8 @@ public class TestModules extends JavadocTester { checkModuleModeCommon(); checkModuleModeApi(true); checkModuleModeAll(false); + checkModuleFrameFiles(true); + checkAllModulesLink(true); } /** @@ -248,6 +271,108 @@ public class TestModules extends JavadocTester { checkModuleModeCommon(); checkModuleModeApi(false); checkModuleModeAll(true); + checkModuleFrameFiles(true); + checkAllModulesLink(true); + } + + /** + * Test generated module summary page of a module with no exported package. + */ + @Test + void testModuleSummaryNoExportedPkgAll() { + javadoc("-d", "out-ModuleSummaryNoExportedPkgAll", "-use", "--show-module-contents=all", + "-sourcepath", testSrc + "/moduleNoExport", + "--module", "moduleNoExport", + "testpkgmdlNoExport"); + checkExit(Exit.OK); + checkModuleSummaryNoExported(true); + } + + /** + * Test generated module summary page of a module with no exported package. + */ + @Test + void testModuleSummaryNoExportedPkgApi() { + javadoc("-d", "out-ModuleSummaryNoExportedPkgApi", "-use", + "-sourcepath", testSrc + "/moduleNoExport", + "--module", "moduleNoExport", + "testpkgmdlNoExport"); + checkExit(Exit.OK); + checkModuleSummaryNoExported(false); + } + + /** + * Test generated module pages for javadoc run for a single module having a single package. + */ + @Test + void testSingleModuleSinglePkg() { + javadoc("-d", "out-singlemod", + "--module-source-path", testSrc, + "--module", "moduleC", + "testpkgmdlC"); + checkExit(Exit.OK); + checkModuleFrameFiles(false); + } + + /** + * Test generated module pages for javadoc run for a single module having multiple packages. + */ + @Test + void testSingleModuleMultiplePkg() { + javadoc("-d", "out-singlemodmultiplepkg", "--show-module-contents=all", + "--module-source-path", testSrc, + "--module", "moduleB", + "testpkg2mdlB", "testpkgmdlB"); + checkExit(Exit.OK); + checkAllModulesLink(false); + } + + /** + * Test -group option for modules. The overview-summary.html page should group the modules accordingly. + */ + @Test + void testGroupOption() { + javadoc("-d", "out-group", "--show-module-contents=all", + "-tag", "regular:a:Regular Tag:", + "-tag", "moduletag:s:Module Tag:", + "--module-source-path", testSrc, + "-group", "Module Group A", "moduleA*", + "-group", "Module Group B & C", "moduleB*:moduleC*", + "-group", "Java SE Modules", "java*", + "--module", "moduleA,moduleB,moduleC,moduletags", + "moduleA/concealedpkgmdlA", "testpkgmdlA", "testpkg2mdlB", "testpkgmdlB", "testpkgmdlC", + "testpkgmdltags"); + checkExit(Exit.OK); + checkGroupOption(); + } + + /** + * Test -group option for unnamed modules. The overview-summary.html page should group the packages accordingly. + */ + @Test + void testUnnamedModuleGroupOption() { + javadoc("-d", "out-groupnomodule", "-use", + "-overview", testSrc("overview.html"), + "-sourcepath", testSrc, + "-group", "Package Group 0", "testpkgnomodule", + "-group", "Package Group 1", "testpkgnomodule1", + "testpkgnomodule", "testpkgnomodule1"); + checkExit(Exit.OK); + checkUnnamedModuleGroupOption(); + } + + /** + * Test -group option for a single module. + */ + @Test + void testGroupOptionSingleModule() { + javadoc("-d", "out-groupsinglemodule", "-use", + "--module-source-path", testSrc, + "-group", "Module Group B", "moduleB*", + "--module", "moduleB", + "testpkg2mdlB", "testpkgmdlB"); + checkExit(Exit.OK); + //checkOverviewSummaryPackages(); } void checkDescription(boolean found) { @@ -257,14 +382,35 @@ public class TestModules extends JavadocTester { + "\n" + "\n" + "
    This is a test description for the moduleA module. Search " - + "phrase search phrase.
    "); + + "phrase search phrase.
    "); checkOutput("moduleB-summary.html", found, "\n" + "\n" + "\n" + "\n" + "
    This is a test description for the moduleB module. Search " - + "word search_word with no description.
    "); + + "word search_word with no description."); + checkOutput("overview-summary.html", found, + "\n" + + "
    \n" + + "
    The overview summary page header.
    \n" + + "
    \n" + + "
    \n" + + "\n" + + "\n" + + "\n" + + ""); + checkOutput("overview-summary.html", false, + "
    Modules 
    \n" + + "
    \n" + + "
    \n" + + "
    The overview summary page header.
    \n" + + "
    \n" + + "
    \n" + + "\n" + + "\n" + + "\n" + + ""); } void checkNoDescription(boolean found) { @@ -274,7 +420,7 @@ public class TestModules extends JavadocTester { + "
  • \n" + "
      \n" + "
    • \n" - + ""); + + ""); checkOutput("moduleB-summary.html", found, "
      \n" + "
        \n" @@ -288,7 +434,7 @@ public class TestModules extends JavadocTester { checkOutput("moduleA-summary.html", found, "
        \n" + "
        Deprecated, for removal:" - + " This API element is subject to removal in a future version. \n" + + " This API element is subject to removal in a future version.\n" + "
        This module is deprecated.
        \n" + "
        \n" + "\n" @@ -296,7 +442,7 @@ public class TestModules extends JavadocTester { + "\n" + "\n" + "
        This is a test description for the moduleA module. Search " - + "phrase search phrase.
        "); + + "phrase search phrase.
      "); checkOutput("moduleB-summary.html", found, "
      \n" + "\n" @@ -304,7 +450,32 @@ public class TestModules extends JavadocTester { + "\n" + "\n" + "
      This is a test description for the moduleB module. Search " - + "word search_word with no description.
      "); + + "word search_word with no description."); + checkOutput("overview-summary.html", found, + "\n" + + "\n" + + "
      \n" + + "
      \n" + + "
      The overview summary page header.
      \n" + + "
      \n" + + "
  • Modules 
    \n" + + ""); + checkOutput("overview-summary.html", false, + "
    Modules 
    \n" + + "
    \n" + + "\n" + + "
    \n" + + "
    \n" + + "
    The overview summary page header.
    \n" + + "
    \n" + + "
    \n" + + "\n" + + "\n" + + "\n" + + ""); } void checkHtml5NoDescription(boolean found) { @@ -314,7 +485,7 @@ public class TestModules extends JavadocTester { + "
  • \n" + "
      \n" + "
    • \n" - + ""); + + ""); checkOutput("moduleB-summary.html", found, "
      \n" + "
        \n" @@ -381,7 +552,7 @@ public class TestModules extends JavadocTester { void checkOverviewSummaryModules() { checkOutput("overview-summary.html", true, - "
  • Modules 
    \n" + "
    \n" + "\n" + "\n" + "\n" @@ -398,19 +569,38 @@ public class TestModules extends JavadocTester { void checkOverviewSummaryPackages() { checkOutput("overview-summary.html", false, - "
    Modules 
    Module
    \n" + "
    \n" + "\n" + "\n" + "\n" + "\n" - + ""); + + "", + "
    Modules 
    ModuleDescription
    \n" + + "
    \n" + + "
    \n" + + "
    The overview summary page header.
    \n" + + "
    \n" + + "
    \n" + + "\n" + + "\n" + + "\n" + + ""); checkOutput("overview-summary.html", true, "
    Packages 
    \n" + "\n" + "\n" + "\n" + "\n" - + ""); + + "", + "\n" + + "
    \n" + + "
    The overview summary page header.
    \n" + + "
    \n" + + "
    Packages 
    PackageDescription
    \n" + + ""); } void checkHtml5OverviewSummaryModules() { @@ -437,14 +627,38 @@ public class TestModules extends JavadocTester { + "\n" + "\n" + "\n" - + ""); + + "", + "
    Packages 
    ModuleDescription
    \n" + + "
    \n" + + "
    \n" + + "
    \n" + + "
    \n" + + "
    The overview summary page header.
    \n" + + "
    \n" + + "
    \n" + + "\n" + + "\n" + + "\n" + + ""); checkOutput("overview-summary.html", true, "
    Packages 
    \n" + "\n" + "\n" + "\n" + "\n" - + ""); + + "", + "\n" + + "\n" + + "\n" + + "
    \n" + + "
    \n" + + "
    The overview summary page header.
    \n" + + "
    \n" + + "
    Packages 
    PackageDescription
    \n" + + ""); } void checkModuleSummary() { @@ -498,11 +712,7 @@ public class TestModules extends JavadocTester { + "\n" + "\n" + "", - "\n" - + "\n" - + "\n" - + "", - "\n" + "\n" + "\n" + "\n" + "\n" @@ -519,6 +729,32 @@ public class TestModules extends JavadocTester { + ""); } + void checkAggregatorModuleSummary() { + checkOutput("moduleT-summary.html", true, + "
    \n" + + "

    Module moduleT

    \n" + + "
    ", + "
    This is a test description for the moduleT module. " + + "Search phrase search phrase. " + + "Make sure there are no exported packages.
    ", + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + "\n" + + ""); + } + void checkNegatedModuleSummary() { checkOutput("moduleA-summary.html", false, "\n" @@ -552,18 +788,39 @@ public class TestModules extends JavadocTester { void checkModuleFilesAndLinks(boolean found) { checkFileAndOutput("testpkgmdlA/package-summary.html", found, "
  • Module
  • ", - "
    Module " + "
    Module " + "moduleA
    "); checkFileAndOutput("testpkgmdlA/TestClassInModuleA.html", found, "
  • Module
  • ", - "
    Module " + "
    Module " + "moduleA
    "); + checkFileAndOutput("testpkgmdlB/AnnotationType.html", found, + "
    Module " + + "moduleB
    ", + "
    " + + "Package testpkgmdlB
    "); checkFiles(found, "moduleA-frame.html", "moduleA-summary.html", "module-overview-frame.html"); } + void checkModuleFrameFiles(boolean found) { + checkFiles(found, + "moduleC-frame.html", + "moduleC-type-frame.html", + "module-overview-frame.html"); + checkFiles(true, + "moduleC-summary.html", + "allclasses-frame.html", + "allclasses-noframe.html"); + } + + void checkAllModulesLink(boolean found) { + checkOutput("overview-frame.html", found, + "
  • All Modules
  • "); + } + void checkModulesInSearch(boolean found) { checkOutput("index-all.html", found, "
    \n" @@ -584,7 +841,7 @@ public class TestModules extends JavadocTester { + "search_word - Search tag in moduleB\n" + "
     
    \n" + "
    "); -} + } void checkModuleModeCommon() { checkOutput("overview-summary.html", true, @@ -606,19 +863,6 @@ public class TestModules extends JavadocTester { checkOutput("moduleA-summary.html", true, "
  • Description | " + "Modules | Packages | Services
  • ", - "
    \n" - + "\n" - + "", - "
    Packages 
    TestClassInModuleBWith a test description for uses. 
    TestInterface2InModuleB 
    Opened Packages Opens 
    PackageDescription
    transitivemoduleA\n" + + "
    This is a test description for the moduleA module.
    \n" + + "
    transitivemoduleB\n" + + "
    This is a test description for the moduleB module.
    \n" + + "
    transitivemoduleB\n" - + "
    This is a test description for the moduleB module.
    \n" - + "
    \n" - + "", - "
    Additional Exported Packages 
    \n" - + "\n" - + "\n" - + "\n" - + "\n" - + "\n", "\n" + "\n"); checkOutput("moduleB-summary.html", true, @@ -627,15 +871,15 @@ public class TestModules extends JavadocTester { checkOutput("moduletags-summary.html", true, "
  • Description | Modules" + " | Packages | Services
  • ", - "
    Additional Opened Packages 
    ModulePackages
    moduleBtestpkgmdlB
    \n" - + "", + "
    Additional Modules Required 
    \n" + + "", "\n" + "\n" + "", - "
    Indirect Requires 
    transitivemoduleB\n" + "
    This is a test description for the moduleB module.
    \n" + "
    \n" - + "", + "
    Additional Exported Packages 
    \n" + + "", "\n" + "\n" + "\n" + "\n" + "", - "
    Indirect Exports 
    transitive staticmoduleA\n" @@ -647,16 +891,16 @@ public class TestModules extends JavadocTester { + "ModifierModuleDescription
    \n" - + "\n" + "
    Additional Modules Required 
    \n" + + "\n" + "\n" + "\n" + "\n" + "", - "
    Indirect Requires 
    ModifierModuleDescription
    \n" - + "\n" + "
    Additional Opened Packages 
    \n" + + "\n" + "\n" - + "\n" + + "\n" + "\n" + "\n", "\n" @@ -673,7 +917,7 @@ public class TestModules extends JavadocTester { "\n" + "", "
    Indirect Opens 
    ModuleFromPackages
    moduleBtestpkgmdlB 
    \n" - + "\n" + + "\n" + "\n" + "\n" + "\n" @@ -706,9 +950,9 @@ public class TestModules extends JavadocTester { + "\n" + "", "", + + "Concealed ", "\n" + "\n" + ""); @@ -730,10 +974,10 @@ public class TestModules extends JavadocTester { + "", ""); + + "Exports " + + "Opens "); checkOutput("moduleC-summary.html", found, - "\n" + "\n" + "\n" + "\n" + "\n" @@ -748,7 +992,7 @@ public class TestModules extends JavadocTester { void checkModuleDeprecation(boolean found) { checkOutput("moduleA-summary.html", found, "
    Deprecated, for removal:" - + " This API element is subject to removal in a future version. \n" + + " This API element is subject to removal in a future version.\n" + "
    This module is deprecated.
    \n" + "
    "); checkOutput("deprecated-list.html", found, @@ -778,19 +1022,71 @@ public class TestModules extends JavadocTester { + "

    "); checkOutput("moduleB-summary.html", false, "@AnnotationTypeUndocumented"); -} + } void checkOverviewFrame(boolean found) { checkOutput("index.html", !found, ""); checkOutput("index.html", found, ""); -} + } - void checkNegatedOverviewFrame() { - checkOutput("index.html", false, - ""); - checkOutput("index.html", false, - ""); + void checkModuleSummaryNoExported(boolean found) { + checkOutput("moduleNoExport-summary.html", found, + "\n" + + "\n" + + "\n" + + "", + ""); + } + + void checkGroupOption() { + checkOutput("overview-summary.html", true, + "
    Opened Packages Opens 
    PackageDescriptionAll Modules 
    All Packages " - + "Exported Packages" + + "Exports" + " " - + "Concealed Packages 
    concealedpkgmdlANone  
    (Implementation(s): TestClassInModuleB)
    All Packages " - + "Exported Packages " - + "Opened Packages Exported Packages Exports 
    PackageModule
    Concealed 
    \n" + + "", + "
    Module Group A 
    \n" + + "", + "
    Module Group B & C 
    \n" + + ""); + checkOutput("overview-summary.html", false, + "
    Other Modules 
    \n" + + "", + "Java SE Modules"); + } + + void checkUnnamedModuleGroupOption() { + checkOutput("overview-summary.html", true, + "
    Modules 
    \n" + + "\n" + + "", + "
    Package Group 0 
    \n" + + ""); + } + + void checkGroupOptionSingleModule() { + checkOutput("overview-summary.html", true, + "
    Package Group 1 
    \n" + + ""); + checkOutput("overview-summary.html", false, + "
    Module Group B 
    \n" + + ""); } } diff --git a/langtools/test/jdk/javadoc/doclet/testModules/moduleB/testpkgmdlB/AnnotationType.java b/langtools/test/jdk/javadoc/doclet/testModules/moduleB/testpkgmdlB/AnnotationType.java index 6f37a34d271..26da965efcb 100644 --- a/langtools/test/jdk/javadoc/doclet/testModules/moduleB/testpkgmdlB/AnnotationType.java +++ b/langtools/test/jdk/javadoc/doclet/testModules/moduleB/testpkgmdlB/AnnotationType.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,7 +28,7 @@ import java.lang.annotation.*; /** * This is a test annotation type. */ -@Documented public @interface AnnotationType { +@Documented @Target(ElementType.MODULE) public @interface AnnotationType { /** * The copyright holder. diff --git a/langtools/test/jdk/javadoc/doclet/testModules/moduleB/testpkgmdlB/AnnotationTypeUndocumented.java b/langtools/test/jdk/javadoc/doclet/testModules/moduleB/testpkgmdlB/AnnotationTypeUndocumented.java index 066551c3c0d..00bf360e2d1 100644 --- a/langtools/test/jdk/javadoc/doclet/testModules/moduleB/testpkgmdlB/AnnotationTypeUndocumented.java +++ b/langtools/test/jdk/javadoc/doclet/testModules/moduleB/testpkgmdlB/AnnotationTypeUndocumented.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -29,7 +29,7 @@ import java.lang.annotation.*; * This is a test annotation type this is not documented because it * is missing the @Documented tag. */ -public @interface AnnotationTypeUndocumented { +@Target(ElementType.MODULE) public @interface AnnotationTypeUndocumented { /** * The copyright holder. diff --git a/langtools/test/jdk/javadoc/doclet/testModules/moduleNoExport/module-info.java b/langtools/test/jdk/javadoc/doclet/testModules/moduleNoExport/module-info.java new file mode 100644 index 00000000000..cf29f0dafe1 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testModules/moduleNoExport/module-info.java @@ -0,0 +1,30 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * This is a test description for the moduleNoExport module. Make sure there are no exported packages. + */ +module moduleNoExport { +} diff --git a/langtools/test/jdk/javadoc/doclet/testModules/moduleNoExport/testpkgmdlNoExport/TestClassInModuleNoExport.java b/langtools/test/jdk/javadoc/doclet/testModules/moduleNoExport/testpkgmdlNoExport/TestClassInModuleNoExport.java new file mode 100644 index 00000000000..b4b69a8a4e5 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testModules/moduleNoExport/testpkgmdlNoExport/TestClassInModuleNoExport.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +package testpkgmdlNoExport; + +public class TestClassInModuleNoExport { + public void testMethodClassModuleNoExport() { } +} diff --git a/langtools/test/jdk/javadoc/doclet/testModules/moduleT/module-info.java b/langtools/test/jdk/javadoc/doclet/testModules/moduleT/module-info.java new file mode 100644 index 00000000000..653c11b2c0a --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testModules/moduleT/module-info.java @@ -0,0 +1,33 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * This is a test description for the moduleT module. Search phrase {@index "search phrase" with description}. Make sure there are no exported packages. + * + */ +module moduleT { + requires transitive moduleA; + requires transitive moduleB; +} diff --git a/langtools/test/jdk/javadoc/doclet/testModules/overview.html b/langtools/test/jdk/javadoc/doclet/testModules/overview.html new file mode 100644 index 00000000000..eda76316aaa --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testModules/overview.html @@ -0,0 +1,6 @@ + + + + The overview summary page header. + + diff --git a/langtools/test/jdk/javadoc/doclet/testNavigation/TestNavigation.java b/langtools/test/jdk/javadoc/doclet/testNavigation/TestNavigation.java index f8a50424202..2f219a7e3e1 100644 --- a/langtools/test/jdk/javadoc/doclet/testNavigation/TestNavigation.java +++ b/langtools/test/jdk/javadoc/doclet/testNavigation/TestNavigation.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 4131628 4664607 7025314 8023700 7198273 8025633 8026567 8081854 8150188 + * @bug 4131628 4664607 7025314 8023700 7198273 8025633 8026567 8081854 8150188 8151743 * @summary Make sure the Next/Prev Class links iterate through all types. * Make sure the navagation is 2 columns, not 3. * @author jamieh @@ -77,12 +77,20 @@ public class TestNavigation extends JavadocTester { "\n" + "\n" + "
     
    \n" + + "\n" + ""); checkOutput("pkg/package-summary.html", true, "\n" + "\n" + "
     
    \n" + + "\n" + "
    "); } @@ -98,6 +106,10 @@ public class TestNavigation extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "\n" + "\n" + ""); @@ -106,6 +118,10 @@ public class TestNavigation extends JavadocTester { "\n" + "\n" + "
     
    \n" + + "\n" + ""); } @@ -121,12 +137,20 @@ public class TestNavigation extends JavadocTester { "\n" + "\n" + "
     
    \n" + + "\n" + ""); checkOutput("pkg/package-summary.html", false, "\n" + "\n" + "
     
    \n" + + "\n" + "
    "); } @@ -142,6 +166,10 @@ public class TestNavigation extends JavadocTester { "\n" + "
    \n" + "
     
    \n" + + "\n" + "\n" + "\n" + ""); @@ -150,6 +178,10 @@ public class TestNavigation extends JavadocTester { "\n" + "\n" + "
     
    \n" + + "\n" + ""); } } diff --git a/langtools/test/jdk/javadoc/doclet/testNewLanguageFeatures/TestNewLanguageFeatures.java b/langtools/test/jdk/javadoc/doclet/testNewLanguageFeatures/TestNewLanguageFeatures.java index 048c310b0ea..e1003ca04f6 100644 --- a/langtools/test/jdk/javadoc/doclet/testNewLanguageFeatures/TestNewLanguageFeatures.java +++ b/langtools/test/jdk/javadoc/doclet/testNewLanguageFeatures/TestNewLanguageFeatures.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,6 +24,7 @@ /* * @test * @bug 4789689 4905985 4927164 4827184 4993906 5004549 7025314 7010344 8025633 8026567 8162363 + * 8175200 * @summary Run Javadoc on a set of source files that demonstrate new * language features. Check the output to ensure that the new * language features are properly documented. @@ -80,7 +81,7 @@ public class TestNewLanguageFeatures extends JavadocTester { "Overloaded valueOf() method has correct documentation.", "Overloaded values method has correct documentation.", "
    public static Coin" +
    -                " valueOf(java.lang.String name)
    \n" + + " valueOf​(java.lang.String name)\n" + "
    Returns the enum constant of this type with the specified name.\n" + "The string must match exactly an identifier used to declare an\n" + "enum constant in this type. (Extraneous whitespace characters are \n" + @@ -136,17 +137,17 @@ public class TestNewLanguageFeatures extends JavadocTester { + "title=\"type parameter in TypeParameters\">E[]\n" + "
    \n" + "\n" + "", + + "​(T t)", "" + + "​(T t)" ); // ClassUseTest2: > @@ -295,7 +296,7 @@ public class TestNewLanguageFeatures extends JavadocTester { "", + + "​(T t)", "", + + "​(T t)", "", "", + + "html#method-T-\">method​(T t)", "", "\n" + "", "", // and similarly one more "" ); diff --git a/langtools/test/jdk/javadoc/doclet/testProperty/TestProperty.java b/langtools/test/jdk/javadoc/doclet/testProperty/TestProperty.java new file mode 100644 index 00000000000..69eec3a504c --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testProperty/TestProperty.java @@ -0,0 +1,95 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176231 + * @summary Test JavaFX property. + * @library ../lib/ + * @modules jdk.javadoc/jdk.javadoc.internal.tool + * @build JavadocTester TestProperty + * @run main TestProperty + */ + +public class TestProperty extends JavadocTester { + + public static void main(String... args) throws Exception { + TestProperty tester = new TestProperty(); + tester.runTests(); + } + + @Test + void testArrays() { + javadoc("-d", "out", + "-javafx", + "-sourcepath", testSrc, + "pkg"); + checkExit(Exit.OK); + + checkOutput("pkg/MyClass.html", true, + "
    public final ObjectProperty"
    +                + "<MyObj> goodProperty
    \n" + + "
    This is an Object property where the " + + "Object is a single Object.
    \n" + + "
    \n" + + "
    See Also:
    \n" + + "
    getGood(), \n" + + "" + + "setGood(MyObj)
    \n" + + "
    ", + + "
    public final ObjectProperty"
    +                + "<MyObj[]> badProperty
    \n" + + "
    This is an Object property where the " + + "Object is an array.
    \n" + + "
    \n" + + "
    See Also:
    \n" + + "
    getBad(), \n" + + "" + + "setBad(MyObj[])
    \n" + + "
    " + ); + + checkOutput("pkg/MyClassT.html", true, + "
    public final ObjectProperty"
    +                + "<java.util.List<T>> "
    +                + "listProperty
    \n" + + "
    This is an Object property where the " + + "Object is a single List<T>.
    \n" + + "
    \n" + + "
    See Also:
    \n" + + "
    " + + "getList(), \n" + + "" + + "setList(List)
    \n" + + "
    " + ); + } +} + diff --git a/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyClass.java b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyClass.java new file mode 100644 index 00000000000..429977f221f --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyClass.java @@ -0,0 +1,71 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package pkg; + +/** + * Test program for javadoc properties. + */ +public class MyClass { + + private SimpleObjectProperty good + = new SimpleObjectProperty(); + + /** + * This is an Object property where the Object is a single Object. + * + * @return the good + */ + public final ObjectProperty goodProperty() { + return good; + } + + public final void setGood(MyObj good) { + } + + public final MyObj getGood() { + return good.get(); + } + + + private SimpleObjectProperty bad + = new SimpleObjectProperty(); + + /** + * This is an Object property where the Object is an array. + * + * @return the bad + */ + public final ObjectProperty badProperty() { + return bad; + } + + public final void setBad(MyObj[] bad) { + } + + public final MyObj[] getBad() { + return bad.get(); + } + +} + diff --git a/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyClassT.java b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyClassT.java new file mode 100644 index 00000000000..c428d5b1a2d --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyClassT.java @@ -0,0 +1,32 @@ +package pkg; + +import java.util.List; + +//import javafx.beans.property.*; + +/** + * Test program for javadoc properties. + */ +public class MyClassT { + + private SimpleObjectProperty> list + = new SimpleObjectProperty>(); + + /** + * This is an Object property where the Object is a single {@code List}. + * + * @return the list + */ + public final ObjectProperty> listProperty() { + return list; + } + + public final void setList(List list) { + } + + public final List getList() { + return list.get(); + } + + +} diff --git a/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyObj.java b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyObj.java new file mode 100644 index 00000000000..564f4c76702 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/MyObj.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package pkg; + +public class MyObj { +} + diff --git a/langtools/test/jdk/javadoc/doclet/testProperty/pkg/ObjectProperty.java b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/ObjectProperty.java new file mode 100644 index 00000000000..eecf8c336b8 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/ObjectProperty.java @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package pkg; + +public class ObjectProperty { } + diff --git a/langtools/test/jdk/javadoc/doclet/testProperty/pkg/SimpleObjectProperty.java b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/SimpleObjectProperty.java new file mode 100644 index 00000000000..3d64a9ee279 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testProperty/pkg/SimpleObjectProperty.java @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package pkg; + +public class SimpleObjectProperty { } + diff --git a/langtools/test/jdk/javadoc/doclet/testRepeatedAnnotations/TestRepeatedAnnotations.java b/langtools/test/jdk/javadoc/doclet/testRepeatedAnnotations/TestRepeatedAnnotations.java index 0979d25df8b..d3322396b5a 100644 --- a/langtools/test/jdk/javadoc/doclet/testRepeatedAnnotations/TestRepeatedAnnotations.java +++ b/langtools/test/jdk/javadoc/doclet/testRepeatedAnnotations/TestRepeatedAnnotations.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -61,22 +61,7 @@ public class TestRepeatedAnnotations extends JavadocTester { + "@RegContaineeNotDoc," + "@RegContaineeNotDoc})", - "@ContaineeSynthDoc " - + "@ContaineeSynthDoc " - + "@ContaineeSynthDoc", - "@ContainerSynthDoc(" - + "" - + "@ContaineeSynthDoc)", - "@ContaineeSynthDoc " - + "@ContaineeSynthDoc"); + + "title=\"annotation in pkg\">@RegContaineeNotDoc})"); checkOutput("pkg/D.html", true, "@RegDoc" @@ -88,7 +73,8 @@ public class TestRepeatedAnnotations extends JavadocTester { "@NonSynthDocContainer" + "(" - + "@RegArryDoc)"); + + "@RegArryDoc" + + "(y=1))"); checkOutput("pkg1/C.html", true, "TestEnum"); checkOutput("index-all.html", true, "
    class_test1 passes. Search tag" - + " SearchTagDeprecatedClass
    ", + + " SearchTagDeprecatedClass", "
    error_test3 passes. Search tag for\n" - + " method SearchTagDeprecatedMethod
    "); + + " method SearchTagDeprecatedMethod"); } void checkSplitIndex() { @@ -486,6 +486,16 @@ public class TestSearch extends JavadocTester { checkOutput("search.js", true, "camelCaseRegexp = ($.ui.autocomplete.escapeRegex(request.term)).split(/(?=[A-Z])/).join(\"([a-z0-9_$]*?)\");", "var camelCaseMatcher = new RegExp(\"^\" + camelCaseRegexp);", - "camelCaseMatcher.test(item.l)"); + "camelCaseMatcher.test(item.l)", + "var secondaryresult = new Array();", + "function nestedName(e) {", + "function sortAndConcatResults(a1, a2) {", + "if (exactMatcher.test(item.l)) {\n" + + " presult.unshift(item);", + "$(\"#search\").on('click keydown', function() {\n" + + " if ($(this).val() == watermark) {\n" + + " $(this).val('').removeClass('watermark');\n" + + " }\n" + + " });"); } } diff --git a/langtools/test/jdk/javadoc/doclet/testStylesheet/TestStylesheet.java b/langtools/test/jdk/javadoc/doclet/testStylesheet/TestStylesheet.java index c54e98cc11c..6c6d4bc7236 100644 --- a/langtools/test/jdk/javadoc/doclet/testStylesheet/TestStylesheet.java +++ b/langtools/test/jdk/javadoc/doclet/testStylesheet/TestStylesheet.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,8 @@ /* * @test - * @bug 4494033 7028815 7052425 8007338 8023608 8008164 8016549 8072461 8154261 8162363 8160196 + * @bug 4494033 7028815 7052425 8007338 8023608 8008164 8016549 8072461 8154261 8162363 8160196 8151743 8177417 + * 8175218 8176452 8181215 * @summary Run tests on doclet stylesheet. * @author jamieh * @library ../lib @@ -140,8 +141,8 @@ public class TestStylesheet extends JavadocTester { + ".usesSummary td.colFirst, .usesSummary th.colFirst,\n" + ".providesSummary td.colFirst, .providesSummary th.colFirst,\n" + ".memberSummary td.colFirst, .memberSummary th.colFirst,\n" - + ".memberSummary td.colSecond, .memberSummary th.colSecond,\n" - + ".typeSummary td.colFirst{\n" + + ".memberSummary td.colSecond, .memberSummary th.colSecond, .memberSummary th.colConstructorName,\n" + + ".typeSummary td.colFirst {\n" + " vertical-align:top;\n" + "}", ".overviewSummary td, .memberSummary td, .typeSummary td,\n" @@ -159,13 +160,48 @@ public class TestStylesheet extends JavadocTester { + " float:none;\n" + " display:inline;\n" + "}", - "@import url('resources/fonts/dejavu.css');"); + "@import url('resources/fonts/dejavu.css');", + ".navPadding {\n" + + " padding-top: 107px;\n" + + "}", + "a[name]:before, a[name]:target, a[id]:before, a[id]:target {\n" + + " content:\"\";\n" + + " display:inline-block;\n" + + " position:relative;\n" + + " padding-top:129px;\n" + + " margin-top:-129px;\n" + + "}\n" + + ".searchTagResult:before, .searchTagResult:target {\n" + + " color:red;\n" + + "}", + "a[href]:hover, a[href]:focus {\n" + + " text-decoration:none;\n" + + " color:#bb7a2a;\n" + + "}", + "td.colFirst a:link, td.colFirst a:visited,\n" + + "td.colSecond a:link, td.colSecond a:visited,\n" + + "th.colFirst a:link, th.colFirst a:visited,\n" + + "th.colSecond a:link, th.colSecond a:visited,\n" + + "th.colConstructorName a:link, th.colConstructorName a:visited,\n" + + ".constantValuesContainer td a:link, .constantValuesContainer td a:visited {\n" + + " font-weight:bold;\n" + + "}"); - // Test whether a link to the stylesheet file is inserted properly - // in the class documentation. checkOutput("pkg/A.html", true, + // Test whether a link to the stylesheet file is inserted properly + // in the class documentation. ""); + + "href=\"../stylesheet.css\" title=\"Style\">", + "
    Test comment for a class which has an " + + "anchor_with_name and\n" + + " an anchor_with_id.
    "); + + checkOutput("pkg/package-summary.html", true, + "
    "); checkOutput("index.html", true, ""); @@ -174,6 +210,23 @@ public class TestStylesheet extends JavadocTester { "* {\n" + " margin:0;\n" + " padding:0;\n" + + "}", + "a:active {\n" + + " text-decoration:none;\n" + + " color:#4A6782;\n" + + "}", + "a[name]:hover {\n" + + " text-decoration:none;\n" + + " color:#353833;\n" + + "}", + "td.colFirst a:link, td.colFirst a:visited,\n" + + "td.colSecond a:link, td.colSecond a:visited,\n" + + "th.colFirst a:link, th.colFirst a:visited,\n" + + "th.colSecond a:link, th.colSecond a:visited,\n" + + "th.colConstructorName a:link, th.colConstructorName a:visited,\n" + + "td.colLast a:link, td.colLast a:visited,\n" + + ".constantValuesContainer td a:link, .constantValuesContainer td a:visited {\n" + + " font-weight:bold;\n" + "}"); } } diff --git a/langtools/test/jdk/javadoc/doclet/testStylesheet/pkg/A.java b/langtools/test/jdk/javadoc/doclet/testStylesheet/pkg/A.java index 1392ef8c1b1..62942b7b7dc 100644 --- a/langtools/test/jdk/javadoc/doclet/testStylesheet/pkg/A.java +++ b/langtools/test/jdk/javadoc/doclet/testStylesheet/pkg/A.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,4 +23,8 @@ package pkg; +/** + * Test comment for a class which has an anchor_with_name and + * an anchor_with_id. + */ public class A {} diff --git a/langtools/test/jdk/javadoc/doclet/testSubTitle/TestSubTitle.java b/langtools/test/jdk/javadoc/doclet/testSubTitle/TestSubTitle.java index 810d5032b48..ecfc18bcc6e 100644 --- a/langtools/test/jdk/javadoc/doclet/testSubTitle/TestSubTitle.java +++ b/langtools/test/jdk/javadoc/doclet/testSubTitle/TestSubTitle.java @@ -23,7 +23,7 @@ /* * @test - * @bug 7010342 8150000 + * @bug 7010342 8150000 8174974 * @summary Test for correct sub title generation. * @author Bhavesh Patel * @library ../lib @@ -50,7 +50,7 @@ public class TestSubTitle extends JavadocTester { "
    This is the description of package pkg.
    "); checkOutput("pkg/C.html", true, - "
    " + + "
    " + "Package pkg
    "); checkOutput("pkg/package-summary.html", false, diff --git a/langtools/test/jdk/javadoc/doclet/testTypeAnnotations/TestTypeAnnotations.java b/langtools/test/jdk/javadoc/doclet/testTypeAnnotations/TestTypeAnnotations.java index 04f0fd659c0..aa1790381dc 100644 --- a/langtools/test/jdk/javadoc/doclet/testTypeAnnotations/TestTypeAnnotations.java +++ b/langtools/test/jdk/javadoc/doclet/testTypeAnnotations/TestTypeAnnotations.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8005091 8009686 8025633 8026567 6469562 8071982 8071984 8162363 + * @bug 8005091 8009686 8025633 8026567 6469562 8071982 8071984 8162363 8175200 * @summary Make sure that type annotations are displayed correctly * @author Bhavesh Patel * @library ../lib @@ -155,17 +155,17 @@ public class TestTypeAnnotations extends JavadocTester { checkOutput("typeannos/MtdDefaultScope.html", true, "
    public <T> @MRtnA java.lang.String"
    -                + " method()
    ", + + " method​()", // When JDK-8068737 is fixed, we should change the order "
    "
                     + "@MRtnA java.lang.String "
                     + "@MRtnB [] "
                     + "@MRtnA []"
    -                + " array2Deep()
    ", + + " array2Deep​()", "
    @MRtnA java.lang.String[][] array2()
    "); + + "typeannos\">@MRtnA java.lang.String[][] array2​()"); checkOutput("typeannos/MtdModifiedScoped.html", true, "
    public final @MRtnB java.lang.String>,@MRtnB java."
    -                + "lang.String> nestedMtdParameterized()
    "); + + "lang.String> nestedMtdParameterized​()"); // Test for type annotations on method type parameters (MethodTypeParameters.java). checkOutput("typeannos/UnscopedUnmodified.html", true, "
    <K extends @MTyParamA java.lang.String>"
    -                + " void methodExtends()
    ", + + " void methodExtends​()", "
    <K extends @MTyParamA "
                     + "MtdTyParameterized<@MTyParamB java.lang.String"
    -                + ">> void nestedExtends()
    "); + + ">> void nestedExtends​()"); checkOutput("typeannos/PublicModifiedMethods.html", true, "
    public final <K extends @MTyParamA "
    -                + "java.lang.String> void methodExtends()
    ", + + "java.lang.String> void methodExtends​()", "
    public final <K extends @MTyParamA "
    @@ -204,16 +204,16 @@ public class TestTypeAnnotations extends JavadocTester {
                     + "typeannos/MtdTyParameterized.html\" title=\"class in typeannos\">"
                     + "MtdTyParameterized<@MTyParamB java.lang.String"
    -                + ">> void dual()
    "); + + ">> void dual​()"); // Test for type annotations on parameters (Parameters.java). checkOutput("typeannos/Parameters.html", true, - "
    void unannotated(void unannotated​("
                     + "ParaParameterized<java.lang.String,java.lang.String>"
                     + " a)
    ", - "
    void nestedParaParameterized(void nestedParaParameterized​("
                     + "ParaParameterized<@ParamA  java.lang.String> a)
    ", // When JDK-8068737 is fixed, we should change the order - "
    void array2Deep(void array2Deep​(@ParamA java.lang.String "
                     + ""
                     + "@ParamB [] "
    @@ -236,34 +236,34 @@ public class TestTypeAnnotations extends JavadocTester {
     
             // Test for type annotations on throws (Throws.java).
             checkOutput("typeannos/ThrDefaultUnmodified.html", true,
    -                "
    void oneException()\n"
    +                "
    void oneException​()\n"
                     + "           throws @ThrA java.lang.Exception
    ", - "
    void twoExceptions()\n"
    +                "
    void twoExceptions​()\n"
                     + "            throws @ThrA java.lang.RuntimeException,\n"
                     + "                   @ThrA java.lang.Exception
    "); checkOutput("typeannos/ThrPublicModified.html", true, - "
    public final void oneException(java.lang.String a)\n"
    +                "
    public final void oneException​(java.lang.String a)\n"
                     + "                        throws @ThrA java.lang.Exception
    ", - "
    public final void twoExceptions(java.lang.String a)\n"
    +                "
    public final void twoExceptions​(java.lang.String a)\n"
                     + "                         throws @ThrA java.lang.RuntimeException,\n"
                     + "                                @ThrA java.lang.Exception
    "); checkOutput("typeannos/ThrWithValue.html", true, - "
    void oneException()\n"
    +                "
    void oneException​()\n"
                     + "           throws @ThrB("
                     + "\"m\") java.lang.Exception
    ", - "
    void twoExceptions()\n"
    +                "
    void twoExceptions​()\n"
                     + "            throws @ThrB("
                     + "\"m\") java.lang.RuntimeException,\n"
    @@ -275,12 +275,12 @@ public class TestTypeAnnotations extends JavadocTester {
                     "
    <K,"
                     + "@TyParaA V extends @TyParaA "
    -                + "java.lang.String> void secondAnnotated()
    " + + "java.lang.String> void secondAnnotated​()
    " ); // Test for type annotations on wildcard type (Wildcards.java). checkOutput("typeannos/BoundTest.html", true, - "
    void wcExtends(void wcExtends​(MyList<? extends @WldA"
                     + " java.lang.String> l)
    ", @@ -288,10 +288,10 @@ public class TestTypeAnnotations extends JavadocTester { "
    MyList<? super @WldA java.lang.String>"
    -                + " returnWcSuper()
    "); + + " returnWcSuper​()
    "); checkOutput("typeannos/BoundWithValue.html", true, - "
    void wcSuper(void wcSuper​(MyList<? super @WldB("
                     + "\"m\") java.lang."
    @@ -301,41 +301,41 @@ public class TestTypeAnnotations extends JavadocTester {
                     + "typeannos\">MyList<? extends @WldB("
                     + "\"m\") java.lang.String"
    -                + "> returnWcExtends()
    "); + + "> returnWcExtends​()
    "); // Test for receiver annotations (Receivers.java). checkOutput("typeannos/DefaultUnmodified.html", true, - "
    void withException(void withException​(@RcvrA "
                     + "DefaultUnmodified this)\n"
                     + "            throws java."
                     + "lang.Exception
    ", - "
    java.lang.String nonVoid(java.lang.String nonVoid​(@RcvrA @RcvrB"
                     + "(\"m\")"
                     + " DefaultUnmodified this)
    ", - "
    <T extends java.lang.Runnable> void accept("
    +                "
    <T extends java.lang.Runnable> void accept​("
                     + "@RcvrA DefaultUnmodified this,\n"
                     + "                                           T r)\n"
                     + "                                    throws java.lang.Exception
    "); checkOutput("typeannos/PublicModified.html", true, - "
    public final java.lang.String nonVoid(public final java.lang.String nonVoid​("
                     + "@RcvrA PublicModified this)
    ", "
    public final <T extends java.lang.Runnable> "
    -                + "void accept(@RcvrA PublicModified this,\n"
                     + "                                                        T r)\n"
                     + "                                                 throws java.lang.Exception
    "); checkOutput("typeannos/WithValue.html", true, - "
    <T extends java.lang.Runnable> void accept("
    +                "
    <T extends java.lang.Runnable> void accept​("
                     + "@RcvrB("
                     + "\"m\") WithValue this,\n"
    @@ -343,17 +343,17 @@ public class TestTypeAnnotations extends JavadocTester {
                     + "                                    throws java.lang.Exception
    "); checkOutput("typeannos/WithFinal.html", true, - "
    java.lang.String nonVoid(@RcvrB("
    -                + "\"m\") WithFinal"
    -                + " this)
    "); + "
    java.lang.String nonVoid​(@RcvrB(\"m\") "
    +                + ""
    +                + "WithFinal afield)
    "); checkOutput("typeannos/WithBody.html", true, - "
    void field(void field​(@RcvrA WithBody this)
    "); checkOutput("typeannos/Generic2.html", true, - "
    void test2(void test2​(@RcvrA Generic2<X> this)
    "); @@ -396,7 +396,7 @@ public class TestTypeAnnotations extends JavadocTester { + "\"../typeannos/RepConstructorB.html\" title=\"annotation in typeannos" + "\">@RepConstructorB @RepConstructorB\n" - + "RepeatingOnConstructor()
    ", + + "RepeatingOnConstructor​()
    ", "
    @RepConstructorA @RepConstructorB @RepConstructorB\n"
    -                + "RepeatingOnConstructor(int i,\n                       int j)
    ", + + "RepeatingOnConstructor​(int i,\n int j)
    ", "
    @RepAllContextsA @RepAllContextsB @RepAllContextsB\n"
    -                + "RepeatingOnConstructor(int i,\n                       int j,\n"
    +                + "RepeatingOnConstructor​(int i,\n                       int j,\n"
                     + "                       int k)
    ", - "
    RepeatingOnConstructor(RepeatingOnConstructor​(@RepParameterA @RepParameterA Inner"
    -                + "(java.lang.String parameter,\n     java.lang.String "
                     + "@RepTypeUseA @RepTypeUseA "
                     + "@RepTypeUseB ... vararg)",
     
    -                "Inner("
    +                "Inner​("
                     + "@RepTypeUseA @RepTypeUseA @RepTypeUseB (package private) java.lang.String\n
    \n" + + "​()" ); } diff --git a/langtools/test/jdk/javadoc/doclet/testUserTaglet/InfoTaglet.java b/langtools/test/jdk/javadoc/doclet/testUserTaglet/InfoTaglet.java new file mode 100644 index 00000000000..19d4ee837b7 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testUserTaglet/InfoTaglet.java @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.util.EnumSet; +import java.util.List; +import java.util.Set; +import javax.lang.model.element.Element; + +import jdk.javadoc.doclet.Doclet; +import jdk.javadoc.doclet.DocletEnvironment; +import jdk.javadoc.doclet.Taglet; +import static jdk.javadoc.doclet.Taglet.Location.*; + +import com.sun.source.doctree.DocTree; + +/** + * A taglet to test access to a taglet's context. + */ +public class InfoTaglet implements Taglet { + private DocletEnvironment env; + private Doclet doclet; + + @Override + public void init(DocletEnvironment env, Doclet doclet) { + this.env = env; + this.doclet = doclet; + } + + @Override + public Set getAllowedLocations() { + return EnumSet.of(TYPE); + } + + @Override + public boolean isInlineTag() { + return false; + } + + @Override + public String getName() { + return "info"; + } + + @Override + public String toString(List tags, Element element) { + // The content lines below are primarily to help verify the element + // and the values passed to init. + return "
    " + +"Info:\n" + + "
    " + + "
    " + + "
      \n" + + "
    • Element: " + element.getKind() + " " + element.getSimpleName() + "\n" + + "
    • Element supertypes: " + + env.getTypeUtils().directSupertypes(element.asType()) + "\n" + + "
    • Doclet: " + doclet.getClass() + "\n" + + "
    \n" + + "
    "; + } +} + diff --git a/langtools/test/jdk/javadoc/doclet/testUserTaglet/TestUserTaglet.java b/langtools/test/jdk/javadoc/doclet/testUserTaglet/TestUserTaglet.java new file mode 100644 index 00000000000..4451d5c6887 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testUserTaglet/TestUserTaglet.java @@ -0,0 +1,58 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176836 + * @summary Provide Taglet with context + * @library ../lib + * @modules jdk.javadoc/jdk.javadoc.internal.tool + * @build JavadocTester InfoTaglet + * @run main TestUserTaglet + */ + +public class TestUserTaglet extends JavadocTester { + + public static void main(String... args) throws Exception { + TestUserTaglet tester = new TestUserTaglet(); + tester.runTests(); + } + + @Test + void test() { + javadoc("-d", "out", + "-sourcepath", testSrc, + "-tagletpath", System.getProperty("test.class.path"), + "-taglet", "InfoTaglet", + "pkg"); + checkExit(Exit.OK); + + // The following checks verify that information was successfully + // derived from the context information available to the taglet. + checkOutput("pkg/C.html", true, + "
  • Element: CLASS C", + "
  • Element supertypes: [java.lang.Object]", + "
  • Doclet: class jdk.javadoc.internal.doclets.formats.html.HtmlDoclet" + ); + } +} diff --git a/langtools/test/jdk/javadoc/doclet/testUserTaglet/pkg/C.java b/langtools/test/jdk/javadoc/doclet/testUserTaglet/pkg/C.java new file mode 100644 index 00000000000..ea5259444c5 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testUserTaglet/pkg/C.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package pkg; + +/** @info */ +public class C { } + diff --git a/langtools/test/jdk/javadoc/doclet/testXOption/TestXOption.java b/langtools/test/jdk/javadoc/doclet/testXOption/TestXOption.java index 422c8402507..5997735974c 100644 --- a/langtools/test/jdk/javadoc/doclet/testXOption/TestXOption.java +++ b/langtools/test/jdk/javadoc/doclet/testXOption/TestXOption.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -61,6 +61,16 @@ public class TestXOption extends JavadocTester { } } + @Test + void testWithHelpExtraOption() { + javadoc("-d", "out1", + "-sourcepath", testSrc, + "--help-extra", + testSrc("TestXOption.java")); + checkExit(Exit.OK); + checkOutput(true); + } + @Test void testWithOption() { javadoc("-d", "out1", diff --git a/langtools/test/jdk/javadoc/tool/BadOptionsTest.java b/langtools/test/jdk/javadoc/tool/BadOptionsTest.java index 28ddf3b4257..ed0a9471415 100644 --- a/langtools/test/jdk/javadoc/tool/BadOptionsTest.java +++ b/langtools/test/jdk/javadoc/tool/BadOptionsTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8169676 + * @bug 8169676 8175055 * @summary boolean result of Option.process is often ignored * @modules jdk.compiler/com.sun.tools.javac.api * @modules jdk.compiler/com.sun.tools.javac.main @@ -37,20 +37,6 @@ import java.io.IOException; import java.nio.file.Path; import java.nio.file.Paths; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.HashSet; -import java.util.List; -import java.util.ListIterator; -import java.util.Locale; -import java.util.Objects; -import java.util.Set; - -import javax.lang.model.SourceVersion; - -import jdk.javadoc.doclet.Doclet; -import jdk.javadoc.doclet.DocletEnvironment; -import jdk.javadoc.doclet.Reporter; import toolbox.JavadocTask; import toolbox.ModuleBuilder; @@ -146,6 +132,25 @@ public class BadOptionsTest extends TestRunner { checkNotFound(result, "Exception", "at jdk.javadoc/"); } + @Test + public void testSourcePathAndModuleSourceConflict() throws IOException { + Path msrc = Paths.get("msrc"); + new ModuleBuilder(tb, "m1") + .exports("p1") + .classes("package p1; public class C1 { }") + .write(msrc); + Task.Result result = new JavadocTask(tb, Task.Mode.CMDLINE) + .options("-sourcepath", "src", + "--module-source-path", msrc.getFileName().toString(), + "--module", "m1") + .run(Task.Expect.FAIL) + .writeAll(); + checkFound(result.getOutput(Task.OutputKind.DIRECT), + "javadoc: cannot specify both --source-path and --module-source-path"); + checkFound(result.getOutput(Task.OutputKind.DIRECT), + "1 error"); + } + private void checkFound(String log, String... expect) { for (String e : expect) { if (!log.contains(e)) { diff --git a/langtools/test/jdk/javadoc/tool/CheckResourceKeys.java b/langtools/test/jdk/javadoc/tool/CheckResourceKeys.java index e1df11e793a..898a8fcf315 100644 --- a/langtools/test/jdk/javadoc/tool/CheckResourceKeys.java +++ b/langtools/test/jdk/javadoc/tool/CheckResourceKeys.java @@ -33,8 +33,6 @@ */ import java.io.*; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.*; import javax.tools.*; import com.sun.tools.classfile.*; @@ -265,7 +263,7 @@ public class CheckResourceKeys { * Get the set of keys from the javadoc resource bundles. */ Set getResourceKeys() { - Module jdk_javadoc = Layer.boot().findModule("jdk.javadoc").get(); + Module jdk_javadoc = ModuleLayer.boot().findModule("jdk.javadoc").get(); String[] names = { "jdk.javadoc.internal.doclets.formats.html.resources.standard", "jdk.javadoc.internal.doclets.toolkit.resources.doclets", diff --git a/langtools/test/jdk/javadoc/tool/EnsureNewOldDoclet.java b/langtools/test/jdk/javadoc/tool/EnsureNewOldDoclet.java index fe3b2f938ca..1dfc19fcd12 100644 --- a/langtools/test/jdk/javadoc/tool/EnsureNewOldDoclet.java +++ b/langtools/test/jdk/javadoc/tool/EnsureNewOldDoclet.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8035473 8154482 8154399 8159096 + * @bug 8035473 8154482 8154399 8159096 8176131 8176331 * @summary make sure the javadoc tool responds correctly to Xold, * old doclets and taglets. * @library /tools/lib @@ -40,6 +40,7 @@ import java.util.Map; import java.util.Set; import java.util.regex.Pattern; import java.util.stream.Collectors; +import javax.lang.model.element.Element; import com.sun.javadoc.Tag; import com.sun.source.doctree.DocTree; @@ -87,7 +88,7 @@ public class EnsureNewOldDoclet extends TestRunner { CLASS_NAME + "\\$OldTaglet.*"); final static String OLD_STDDOCLET = "com.sun.tools.doclets.standard.Standard"; - final static String NEW_STDDOCLET = "jdk.javadoc.doclets.StandardDoclet"; + final static String NEW_STDDOCLET = "jdk.javadoc.doclet.StandardDoclet"; public EnsureNewOldDoclet() throws Exception { @@ -186,7 +187,7 @@ public class EnsureNewOldDoclet extends TestRunner { "-tagletpath", testClasses, testSrc.toString()); - Task.Result tr = task.run(Task.Expect.FAIL, 1); + Task.Result tr = task.run(Task.Expect.FAIL, 1).writeAll(); //Task.Result tr = task.run(); List out = tr.getOutputLines(Task.OutputKind.STDOUT); List err = tr.getOutputLines(Task.OutputKind.STDERR); @@ -340,7 +341,7 @@ public class EnsureNewOldDoclet extends TestRunner { } } - public static class NewTaglet implements jdk.javadoc.doclet.taglet.Taglet { + public static class NewTaglet implements jdk.javadoc.doclet.Taglet { @Override public Set getAllowedLocations() { @@ -358,12 +359,7 @@ public class EnsureNewOldDoclet extends TestRunner { } @Override - public String toString(DocTree tag) { - return tag.toString(); - } - - @Override - public String toString(List tags) { + public String toString(List tags, Element element) { return tags.toString(); } diff --git a/langtools/test/jdk/javadoc/tool/IgnoreSourceErrors.java b/langtools/test/jdk/javadoc/tool/IgnoreSourceErrors.java new file mode 100644 index 00000000000..6c79492db05 --- /dev/null +++ b/langtools/test/jdk/javadoc/tool/IgnoreSourceErrors.java @@ -0,0 +1,96 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8175219 + * @summary test --ignore-errors works correctly + * @modules + * jdk.javadoc/jdk.javadoc.internal.api + * jdk.javadoc/jdk.javadoc.internal.tool + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library /tools/lib + * @build toolbox.ToolBox toolbox.TestRunner + * @run main IgnoreSourceErrors + */ + +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.nio.file.StandardOpenOption; +import java.util.Arrays; + +import toolbox.*; +import toolbox.Task.*; + +/** + * Dummy javadoc comment. + */ +public class IgnoreSourceErrors extends TestRunner { + + final ToolBox tb; + final Path testSrc; + + public IgnoreSourceErrors() throws IOException { + super(System.err); + tb = new ToolBox(); + testSrc = Paths.get("Foo.java"); + emitSample(testSrc); + } + + public static void main(String... args) throws Exception { + new IgnoreSourceErrors().runTests(); + } + + @Test + public void runIgnoreErrorsOffByDefault() throws Exception { + JavadocTask task = new JavadocTask(tb, Task.Mode.CMDLINE); + task.options(testSrc.toString()); + Task.Result result = task.run(Expect.FAIL); + String out = result.getOutput(OutputKind.DIRECT); + if (!out.contains("modifier static not allowed here")) { + throw new Exception("expected string not found \'modifier static not allowed here\'"); + } + } + + @Test + public void runIgnoreErrorsOn() throws Exception { + JavadocTask task = new JavadocTask(tb, Task.Mode.CMDLINE); + task.options("--ignore-source-errors", testSrc.toString()); + Task.Result result = task.run(Expect.SUCCESS); + String out = result.getOutput(OutputKind.DIRECT); + if (!out.contains("modifier static not allowed here")) { + throw new Exception("expected string not found \'modifier static not allowed here\'"); + } + } + + void emitSample(Path file) throws IOException { + String[] contents = { + "/** A java file with errors */", + "public static class Foo {}" + }; + Files.write(file, Arrays.asList(contents), StandardOpenOption.CREATE); + } +} diff --git a/langtools/test/jdk/javadoc/tool/ReleaseOption.java b/langtools/test/jdk/javadoc/tool/ReleaseOption.java index b2f07b19f64..766d198d37d 100644 --- a/langtools/test/jdk/javadoc/tool/ReleaseOption.java +++ b/langtools/test/jdk/javadoc/tool/ReleaseOption.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -47,7 +47,7 @@ public class ReleaseOption { } void run() { - doRunTest(OK, out -> out.contains("compiler.err.doesnt.exist: java.util.stream"), "--release", "7"); + doRunTest(ERROR, out -> out.contains("compiler.err.doesnt.exist: java.util.stream"), "--release", "7"); doRunTest(OK, out -> !out.contains("compiler.err.doesnt.exist: java.util.stream"), "--release", "8"); doRunTest(CMDERR, out -> true, "--release", "7", "-source", "7"); doRunTest(CMDERR, out -> true, "--release", "7", "-bootclasspath", "any"); diff --git a/langtools/test/jdk/javadoc/tool/T4696488.java b/langtools/test/jdk/javadoc/tool/T4696488.java index 12ef6df19b0..7b6544a7924 100644 --- a/langtools/test/jdk/javadoc/tool/T4696488.java +++ b/langtools/test/jdk/javadoc/tool/T4696488.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,7 +30,7 @@ * @run main T4696488 T4696488.java */ -import jdk.javadoc.internal.doclets.toolkit.Configuration; +import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration; public class T4696488 { @@ -49,7 +49,7 @@ public class T4696488 { } private static void assertAddTrailingFileSep(String input, String expectedOutput) { - String output = Configuration.addTrailingFileSep(input); + String output = BaseConfiguration.addTrailingFileSep(input); if (!expectedOutput.equals(output)) { throw new Error("expected " + expectedOutput + " but was " + output); } diff --git a/langtools/test/jdk/javadoc/tool/T6551367.java b/langtools/test/jdk/javadoc/tool/T6551367.java index 25047500766..025dffe6c57 100644 --- a/langtools/test/jdk/javadoc/tool/T6551367.java +++ b/langtools/test/jdk/javadoc/tool/T6551367.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,8 +37,6 @@ import java.io.File; import jdk.javadoc.doclet.DocletEnvironment; -import static jdk.javadoc.internal.tool.Main.execute; - public class T6551367 { public T6551367() {} public boolean run(DocletEnvironment root) { @@ -59,7 +57,7 @@ public class T6551367 { destDir.getAbsolutePath() }; - int rc = execute(array); + int rc = jdk.javadoc.internal.tool.Main.execute(array); if (rc != 0) throw new Error("unexpected exit from javadoc: " + rc); } diff --git a/langtools/test/jdk/javadoc/tool/api/basic/AddModulesTest.java b/langtools/test/jdk/javadoc/tool/api/basic/AddModulesTest.java new file mode 100644 index 00000000000..fcc71dae618 --- /dev/null +++ b/langtools/test/jdk/javadoc/tool/api/basic/AddModulesTest.java @@ -0,0 +1,142 @@ +/* + * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8173596 + * @summary DocumentationTool.DocumentationTask should support addModules + * @modules jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library /tools/lib + * @build APITest toolbox.JavacTask toolbox.ToolBox + * @run main AddModulesTest + */ + +import java.io.StringWriter; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.Arrays; + +import javax.tools.DocumentationTool; +import javax.tools.DocumentationTool.DocumentationTask; +import javax.tools.DocumentationTool.Location; +import javax.tools.JavaFileObject; +import javax.tools.StandardJavaFileManager; +import javax.tools.StandardLocation; +import javax.tools.ToolProvider; + +import toolbox.Assert; +import toolbox.JavacTask; +import toolbox.ToolBox; + +/** + * Tests for DocumentationTask.addModules method. + */ +public class AddModulesTest extends APITest { + public static void main(String... args) throws Exception { + new AddModulesTest().run(); + } + + private final ToolBox tb = new ToolBox(); + + /** + * Verify that addModules works as expected. + */ + @Test + public void testAddModules() throws Exception { + Path base = Paths.get("testAddModules"); + Path src = base.resolve("src"); + + // setup some utility modules + Path src_m1 = src.resolve("m1x"); + tb.writeJavaFiles(src_m1, + "module m1x { exports p1; }", + "package p1; public class C1 { }"); + Path src_m2 = src.resolve("m2x"); + tb.writeJavaFiles(src_m2, + "module m2x { exports p2; }", + "package p2; public class C2 { }"); + Path modules = base.resolve("modules"); + tb.createDirectories(modules); + + new JavacTask(tb) + .options("--module-source-path", src.toString()) + .outdir(modules) + .files(tb.findJavaFiles(src)) + .run() + .writeAll(); + + // now test access to the modules + Path src2 = base.resolve("src2"); + tb.writeJavaFiles(src2, + "public class Dummy { p1.C1 c1; p2.C2 c2; }"); + Path api = base.resolve("api"); + tb.createDirectories(api); + + DocumentationTool tool = ToolProvider.getSystemDocumentationTool(); + try (StandardJavaFileManager fm = tool.getStandardFileManager(null, null, null)) { + fm.setLocationFromPaths(StandardLocation.MODULE_PATH, Arrays.asList(modules)); + fm.setLocationFromPaths(Location.DOCUMENTATION_OUTPUT, Arrays.asList(api)); + Iterable files = fm.getJavaFileObjects(tb.findJavaFiles(src2)); + + for (boolean useOption : new boolean[] { false, true }) { + System.err.println("Use --add-modules option: " + useOption); + StringWriter sw = new StringWriter(); + DocumentationTask t = tool.getTask(sw, fm, null, null, null, files); + if (useOption) { + t.addModules(Arrays.asList("m1x", "m2x")); + } + String out; + boolean ok; + try { + ok = t.call(); + } finally { + out = sw.toString(); + System.err.println(out); + } + System.err.println("ok: " + ok); + boolean expectErrors = !useOption; + check(out, "package p1 is not visible", expectErrors); + check(out, "package p2 is not visible", expectErrors); + System.err.println(); + } + } + } + + void check(String out, String text, boolean expected) { + System.err.println("Checking for " + + (expected ? "expected" : "unexpected") + + " text: " + text); + + if (expected) { + if (!out.contains(text)) { + error("expected text not found: " + text); + } + } else { + if (out.contains(text)) { + error("unexpected text found: " + text); + } + } + } +} + diff --git a/langtools/test/jdk/javadoc/tool/api/basic/taglets/UnderlineTaglet.java b/langtools/test/jdk/javadoc/tool/api/basic/taglets/UnderlineTaglet.java index b6414721148..0cac9a34b6d 100644 --- a/langtools/test/jdk/javadoc/tool/api/basic/taglets/UnderlineTaglet.java +++ b/langtools/test/jdk/javadoc/tool/api/basic/taglets/UnderlineTaglet.java @@ -1,51 +1,37 @@ /* - * Copyright (c) 2002, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * - * Redistribution and use in source and binary forms, with or - * without modification, are permitted provided that the following - * conditions are met: + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. * - * -Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). * - * -Redistribution in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * - * Neither the name of Oracle nor the names of - * contributors may be used to endorse or promote products derived - * from this software without specific prior written permission. - * - * This software is provided "AS IS," without a warranty of any - * kind. ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND - * WARRANTIES, INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT, ARE HEREBY - * EXCLUDED. SUN AND ITS LICENSORS SHALL NOT BE LIABLE FOR ANY - * DAMAGES OR LIABILITIES SUFFERED BY LICENSEE AS A RESULT OF OR - * RELATING TO USE, MODIFICATION OR DISTRIBUTION OF THE SOFTWARE OR - * ITS DERIVATIVES. IN NO EVENT WILL SUN OR ITS LICENSORS BE LIABLE - * FOR ANY LOST REVENUE, PROFIT OR DATA, OR FOR DIRECT, INDIRECT, - * SPECIAL, CONSEQUENTIAL, INCIDENTAL OR PUNITIVE DAMAGES, HOWEVER - * CAUSED AND REGARDLESS OF THE THEORY OF LIABILITY, ARISING OUT OF - * THE USE OF OR INABILITY TO USE SOFTWARE, EVEN IF SUN HAS BEEN - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - * - * You acknowledge that Software is not designed, licensed or - * intended for use in the design, construction, operation or - * maintenance of any nuclear facility. + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. */ import java.util.EnumSet; import java.util.List; import java.util.Set; +import javax.lang.model.element.Element; import com.sun.source.doctree.DocTree; import com.sun.source.doctree.TextTree; import com.sun.source.doctree.UnknownBlockTagTree; import com.sun.source.doctree.UnknownInlineTagTree; import com.sun.source.util.SimpleDocTreeVisitor; -import jdk.javadoc.doclet.taglet.Taglet; +import jdk.javadoc.doclet.Taglet; /** * A sample Inline Taglet representing {@underline ...}. This tag can @@ -85,22 +71,13 @@ public class UnderlineTaglet implements Taglet { } /** - * Given the Tag representation of this custom + * Given the DocTree representation of this custom * tag, return its string representation. - * @param tag he Tag representation of this custom tag. + * @param tags the list of trees representing of this custom tag. + * @param element the declaration to which the enclosing comment belongs */ - public String toString(DocTree tag) { - return "" + getText(tag) + ""; - } - - /** - * This method should not be called since arrays of inline tags do not - * exist. Method {@link #tostring(Tag)} should be used to convert this - * inline tag to a string. - * @param tags the array of Tags representing of this custom tag. - */ - public String toString(List tags) { - return null; + public String toString(List tags, Element element) { + return "" + getText(tags.get(0)) + ""; } static String getText(DocTree dt) { diff --git a/langtools/test/jdk/javadoc/tool/badSuper/BadSuper.java b/langtools/test/jdk/javadoc/tool/badSuper/BadSuper.java index 4e77bc8ef2e..dfb2c45201e 100644 --- a/langtools/test/jdk/javadoc/tool/badSuper/BadSuper.java +++ b/langtools/test/jdk/javadoc/tool/badSuper/BadSuper.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -34,7 +34,7 @@ public class BadSuper { String srcpath = System.getProperty("test.src", "."); if (jdk.javadoc.internal.tool.Main.execute( - new String[] {"-d", "doc", "-sourcepath", srcpath, "p"}) != 0) - throw new Error("Javadoc encountered warnings or errors."); + new String[] {"-d", "doc", "-sourcepath", srcpath, "p"}) == 0) + throw new Error("Javadoc passed unexpectedly"); } } diff --git a/langtools/test/jdk/javadoc/tool/modules/CommandLineFiles.java b/langtools/test/jdk/javadoc/tool/modules/CommandLineFiles.java new file mode 100644 index 00000000000..006a6489f8d --- /dev/null +++ b/langtools/test/jdk/javadoc/tool/modules/CommandLineFiles.java @@ -0,0 +1,72 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8176539 + * @summary Test use case when all java files are listed + * @modules + * jdk.javadoc/jdk.javadoc.internal.api + * jdk.javadoc/jdk.javadoc.internal.tool + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library /tools/lib + * @build toolbox.ToolBox toolbox.TestRunner + * @run main CommandLineFiles + */ + +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.stream.Collectors; + +import toolbox.*; + +public class CommandLineFiles extends ModuleTestBase { + + public static void main(String... args) throws Exception { + new CommandLineFiles().runTests(); + } + + @Test + public void testExplicitJavaFiles(Path base) throws Exception { + Path src = Paths.get(base.toString(), "src"); + Path mpath = Paths.get(src. toString(), "m"); + + tb.writeJavaFiles(mpath, + "module m { exports p; }", + "package p; public class C { }"); + + List cmdList = new ArrayList<>(); + cmdList.add("--source-path"); + cmdList.add(mpath.toString()); + Arrays.asList(tb.findJavaFiles(src)).stream() + .map(Path::toString) + .collect(Collectors.toCollection(() -> cmdList)); + execTask(cmdList.toArray(new String[cmdList.size()])); + assertMessageNotPresent("warning:"); + } + +} diff --git a/langtools/test/jdk/javadoc/tool/modules/MissingSourceModules.java b/langtools/test/jdk/javadoc/tool/modules/MissingSourceModules.java new file mode 100644 index 00000000000..9da055a68b4 --- /dev/null +++ b/langtools/test/jdk/javadoc/tool/modules/MissingSourceModules.java @@ -0,0 +1,136 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176481 + * @summary Tests behavior of the tool, when modules are present as + * binaries. + * @modules + * jdk.javadoc/jdk.javadoc.internal.api + * jdk.javadoc/jdk.javadoc.internal.tool + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library /tools/lib + * @build toolbox.ToolBox toolbox.TestRunner + * @run main MissingSourceModules + */ + +import java.nio.file.Path; +import java.nio.file.Paths; + +import toolbox.*; + +public class MissingSourceModules extends ModuleTestBase { + + public static void main(String... args) throws Exception { + new MissingSourceModules().runTests(); + } + + @Test + public void testExplicitBinaryModuleOnModulePath(Path base) throws Exception { + Path modulePath = base.resolve("modules"); + + ModuleBuilder ma = new ModuleBuilder(tb, "ma"); + ma.comment("Module ma.") + .exports("pkg1") + .classes("package pkg1; /** Class A */ public class A { }") + .classes("package pkg1.pkg2; /** Class B */ public class B { }") + .build(modulePath); + + execNegativeTask("--module-path", modulePath.toString(), + "--module", "ma"); + assertMessagePresent("module ma not found."); + } + + @Test + public void testExplicitBinaryModuleOnLegacyPaths(Path base) throws Exception { + Path modulePath = base.resolve("modules"); + + ModuleBuilder ma = new ModuleBuilder(tb, "ma"); + ma.comment("Module ma.") + .exports("pkg1") + .classes("package pkg1; /** Class A */ public class A { }") + .classes("package pkg1.pkg2; /** Class B */ public class B { }") + .build(modulePath); + + Path mPath = Paths.get(modulePath.toString(), "ma"); + execNegativeTask("--source-path", mPath.toString(), + "--module", "ma"); + assertMessagePresent("module ma not found."); + + execNegativeTask("--class-path", mPath.toString(), + "--module", "ma"); + assertMessagePresent("module ma not found."); + } + + @Test + public void testImplicitBinaryRequiresModule(Path base) throws Exception { + Path src = base.resolve("src"); + Path modulePath = base.resolve("modules"); + + ModuleBuilder mb = new ModuleBuilder(tb, "mb"); + mb.comment("Module mb.") + .exports("pkgb") + .classes("package pkgb; /** Class A */ public class A { }") + .build(modulePath); + + ModuleBuilder ma = new ModuleBuilder(tb, "ma"); + ma.comment("Module ma.") + .exports("pkga") + .requires("mb", modulePath) + .classes("package pkga; /** Class A */ public class A { }") + .write(src); + + execTask("--module-path", modulePath.toString(), + "--module-source-path", src.toString(), + "--expand-requires", "all", + "--module", "ma"); + assertMessagePresent("module mb not found."); + } + + @Test + public void testImplicitBinaryTransitiveModule(Path base) throws Exception { + Path src = base.resolve("src"); + Path modulePath = base.resolve("modules"); + + ModuleBuilder mb = new ModuleBuilder(tb, "mb"); + mb.comment("Module mb.") + .exports("pkgb") + .classes("package pkgb; /** Class A */ public class A { }") + .build(modulePath); + + ModuleBuilder ma = new ModuleBuilder(tb, "ma"); + ma.comment("Module ma.") + .exports("pkga") + .requiresTransitive("mb", modulePath) + .classes("package pkga; /** Class A */ public class A { }") + .write(src); + + execTask("--module-path", modulePath.toString(), + "--module-source-path", src.toString(), + "--expand-requires", "transitive", + "--module", "ma"); + assertMessagePresent("module mb not found."); + } +} diff --git a/langtools/test/jdk/javadoc/tool/modules/ModuleTestBase.java b/langtools/test/jdk/javadoc/tool/modules/ModuleTestBase.java index b2fc0ceba9c..ff3cbfc490a 100644 --- a/langtools/test/jdk/javadoc/tool/modules/ModuleTestBase.java +++ b/langtools/test/jdk/javadoc/tool/modules/ModuleTestBase.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,7 @@ import java.io.StringWriter; import java.nio.file.Path; import java.nio.file.Paths; import java.util.Arrays; -import java.util.Collections; +import java.util.HashSet; import java.util.List; import java.util.Locale; import java.util.Set; @@ -158,6 +158,12 @@ public class ModuleTestBase extends TestRunner { } } + void checkTypesSelected(String... args) throws Exception { + for (String arg : args) { + checkDocletOutputPresent("Selected", ElementKind.CLASS, arg); + } + } + void checkMembersSelected(String... args) throws Exception { for (String arg : args) { checkDocletOutputPresent("Selected", ElementKind.METHOD, arg); @@ -180,10 +186,14 @@ public class ModuleTestBase extends TestRunner { assertPresent(regex, STDOUT); } - void assertErrorPresent(String regex) throws Exception { + void assertMessagePresent(String regex) throws Exception { assertPresent(regex, Task.OutputKind.DIRECT); } + void assertMessageNotPresent(String regex) throws Exception { + assertNotPresent(regex, Task.OutputKind.DIRECT); + } + void assertPresent(String regex, Task.OutputKind kind) throws Exception { List foundList = tb.grep(regex, currentTask.getOutputLines(kind)); if (foundList.isEmpty()) { @@ -192,6 +202,14 @@ public class ModuleTestBase extends TestRunner { } } + void assertNotPresent(String regex, Task.OutputKind kind) throws Exception { + List foundList = tb.grep(regex, currentTask.getOutputLines(kind)); + if (!foundList.isEmpty()) { + dumpDocletDiagnostics(); + throw new Exception(regex + " found in: " + kind); + } + } + void dumpDocletDiagnostics() { for (Task.OutputKind kind : Task.OutputKind.values()) { String output = currentTask.getOutput(kind); @@ -268,6 +286,17 @@ public class ModuleTestBase extends TestRunner { StringWriter sw = new StringWriter(); PrintWriter ps = new PrintWriter(sw); + DocletEnvironment docEnv = null; + + boolean hasDocComments = false; + + String hasDocComments(Element e) { + String comment = docEnv.getElementUtils().getDocComment(e); + return comment != null && !comment.isEmpty() + ? "hasDocComments" + : "noDocComments"; + } + // csv style output, for simple regex verification void printDataSet(String header, Set set) { for (Element e : set) { @@ -278,7 +307,12 @@ public class ModuleTestBase extends TestRunner { ps.print(FS); ps.print(e.getKind()); ps.print(FS); - ps.println(e.getQualifiedName()); + ps.print(e.getQualifiedName()); + if (hasDocComments) { + ps.print(FS); + ps.print(hasDocComments(e)); + } + ps.println(); return null; } @@ -287,7 +321,12 @@ public class ModuleTestBase extends TestRunner { ps.print(FS); ps.print(e.getKind()); ps.print(FS); - ps.println(e.getQualifiedName()); + ps.print(e.getQualifiedName()); + if (hasDocComments) { + ps.print(FS); + ps.print(hasDocComments(e)); + } + ps.println(); return null; } @@ -296,7 +335,12 @@ public class ModuleTestBase extends TestRunner { ps.print(FS); ps.print(ElementKind.CLASS); ps.print(FS); - ps.println(e.getQualifiedName()); + ps.print(e.getQualifiedName()); + if (hasDocComments) { + ps.print(FS); + ps.print(hasDocComments(e)); + } + ps.println(); return null; } @@ -326,7 +370,12 @@ public class ModuleTestBase extends TestRunner { ps.print(FS); ps.print(fqn); ps.print("."); - ps.println(e.getSimpleName()); + ps.print(e.getSimpleName()); + if (hasDocComments) { + ps.print(FS); + ps.print(hasDocComments(e)); + } + ps.println(); return null; } }.visit(e); @@ -335,6 +384,7 @@ public class ModuleTestBase extends TestRunner { @Override public boolean run(DocletEnvironment docenv) { + this.docEnv = docenv; ps.println("ModuleMode" + FS + docenv.getModuleMode()); printDataSet("Specified", docenv.getSpecifiedElements()); printDataSet("Included", docenv.getIncludedElements()); @@ -357,7 +407,9 @@ public class ModuleTestBase extends TestRunner { addEnclosedElements(docenv, result, me); } for (PackageElement pe : ElementFilter.packagesIn(elements)) { - addEnclosedElements(docenv, result, docenv.getElementUtils().getModuleOf(pe)); + ModuleElement mdle = docenv.getElementUtils().getModuleOf(pe); + if (mdle != null) + addEnclosedElements(docenv, result, mdle); addEnclosedElements(docenv, result, pe); } for (TypeElement te : ElementFilter.typesIn(elements)) { @@ -378,7 +430,45 @@ public class ModuleTestBase extends TestRunner { @Override public Set getSupportedOptions() { - return Collections.emptySet(); + Option[] options = { + new Option() { + private final List someOption = Arrays.asList( + "-hasDocComments" + ); + + @Override + public int getArgumentCount() { + return 0; + } + + @Override + public String getDescription() { + return "print disposition of doc comments on an element"; + } + + @Override + public Option.Kind getKind() { + return Option.Kind.STANDARD; + } + + @Override + public List getNames() { + return someOption; + } + + @Override + public String getParameters() { + return "flag"; + } + + @Override + public boolean process(String opt, List arguments) { + hasDocComments = true; + return true; + } + } + }; + return new HashSet<>(Arrays.asList(options)); } @Override diff --git a/langtools/test/jdk/javadoc/tool/modules/Modules.java b/langtools/test/jdk/javadoc/tool/modules/Modules.java index 2af3ba81d9d..adbe6e65e1b 100644 --- a/langtools/test/jdk/javadoc/tool/modules/Modules.java +++ b/langtools/test/jdk/javadoc/tool/modules/Modules.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8159305 8166127 + * @bug 8159305 8166127 8175860 8176481 * @summary Tests primarily the module graph computations. * @modules * jdk.javadoc/jdk.javadoc.internal.api @@ -38,6 +38,7 @@ import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; +import java.nio.file.Paths; import toolbox.*; import toolbox.Task.Expect; @@ -92,6 +93,29 @@ public class Modules extends ModuleTestBase { } + @Test + public void testMissingModuleWithSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path mod = src.resolve("m1"); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "m1"); + mb1.comment("The first module.") + .exports("m1pub") + .requires("m2") + .classes("package m1pub; /** Class A */ public class A {}") + .classes("package m1pro; /** Class B */ public class B {}") + .write(src); + + Path javafile = Paths.get(mod.toString(), "m1pub/A.java"); + + execNegativeTask("--source-path", mod.toString(), + javafile.toString()); + + assertMessagePresent("error: cannot access module-info"); + assertMessageNotPresent("error - fatal error encountered"); + + } + @Test public void testMultipleModulesAggregatedModuleOption(Path base) throws Exception { Path src = base.resolve("src"); @@ -150,7 +174,7 @@ public class Modules extends ModuleTestBase { // no module path execNegativeTask("--module-source-path", src.toString(), "--module", "m2"); - assertErrorPresent("error: module not found: m1"); + assertMessagePresent("error: module not found: m1"); } @Test @@ -189,7 +213,7 @@ public class Modules extends ModuleTestBase { execNegativeTask("--module-source-path", src.toString(), "--module-path", modulePath.toString(), "--module", "m2"); - assertErrorPresent("error: cannot find symbol"); + assertMessagePresent("error: cannot find symbol"); // dependency from module path ModuleBuilder mb3 = new ModuleBuilder(tb, "m3"); @@ -202,7 +226,7 @@ public class Modules extends ModuleTestBase { "--module-path", modulePath.toString(), "--upgrade-module-path", upgradePath.toString(), "--module", "m3"); - assertErrorPresent("Z.java:1: error: cannot find symbol"); + assertMessagePresent("Z.java:1: error: cannot find symbol"); } @Test @@ -268,7 +292,7 @@ public class Modules extends ModuleTestBase { "--module-path", modulePath.toString(), "--limit-modules", "java.base", "--module", "m2"); - assertErrorPresent("error: module not found: m1"); + assertMessagePresent("error: module not found: m1"); } @Test @@ -296,38 +320,6 @@ public class Modules extends ModuleTestBase { checkMembersSelected("pkg2.B.f"); } - @Test - public void testPatchModuleOption(Path base) throws Exception { - Path src = base.resolve("src"); - Path modulePath = base.resolve("modules"); - Path patchPath = base.resolve("patch"); - - ModuleBuilder mb1 = new ModuleBuilder(tb, "m1"); - mb1.comment("Module on module path.") - .exports("pkg1") - .classes("package pkg1; /** Class A */ public class A { }") - .build(modulePath); - - tb.writeJavaFiles(patchPath, "package pkg1; /** Class A */ public class A { public static int k; }"); - new JavacTask(tb) - .files(patchPath.resolve("pkg1/A.java")) - .run(); - - ModuleBuilder mb2 = new ModuleBuilder(tb, "m2"); - mb2.comment("The second module.") - .exports("pkg2") - .requires("m1") - .classes("package pkg2; /** Class B */ public class B { /** Field f */ public int f = pkg1.A.k; }") - .write(src); - execTask("--module-source-path", src.toString(), - "--patch-module", "m1=" + patchPath.toString(), - "--module-path", modulePath.toString(), - "--module", "m2"); - checkModulesSpecified("m2"); - checkPackagesIncluded("pkg2"); - checkMembersSelected("pkg2.B.f"); - } - @Test public void testAddReadsOption(Path base) throws Exception { Path src = base.resolve("src"); @@ -428,6 +420,7 @@ public class Modules extends ModuleTestBase { checkPackagesIncluded("p"); checkTypesIncluded("p.Main"); checkPackagesNotIncluded(".*open.*"); + assertMessageNotPresent("warning"); } @Test @@ -449,9 +442,46 @@ public class Modules extends ModuleTestBase { "--expand-requires", "transitive"); checkModulesSpecified("M", "N", "O"); + checkModulesNotSpecified("java.base"); checkModulesIncluded("M", "N", "O"); + checkModulesNotIncluded("java.base"); checkPackagesIncluded("p", "openN", "openO"); checkTypesIncluded("p.Main", "openN.N", "openO.O"); + assertMessageNotPresent("warning"); + } + + @Test + public void testExpandRequiresTransitiveWithMandated(Path base) throws Exception { + Path src = base.resolve("src"); + + createAuxiliaryModules(src); + + Path patchSrc = Paths.get(src.toString(), "patch"); + + new ModuleBuilder(tb, "M") + .comment("The M module.") + .requiresTransitive("N", src) + .requires("L", src) + .exports("p") + .classes("package p; public class Main { openO.O o; openN.N n; openL.L l; }") + .write(src); + + // build the patching module + tb.writeJavaFiles(patchSrc, "package pkg1;\n" + + "/** Class A */ public class A extends java.util.ArrayList { }"); + tb.writeJavaFiles(patchSrc, "package pkg1;\n" + + "/** Class B */ public class B { }"); + + execTask("--module-source-path", src.toString(), + "--patch-module", "java.base=" + patchSrc.toString(), + "--module", "M", + "--expand-requires", "transitive"); + + checkModulesSpecified("java.base", "M", "N", "O"); + checkModulesIncluded("java.base", "M", "N", "O"); + checkPackagesIncluded("p", "openN", "openO"); + checkTypesIncluded("p.Main", "openN.N", "openO.O"); + assertMessageNotPresent("warning"); } @Test @@ -473,13 +503,14 @@ public class Modules extends ModuleTestBase { "--module", "M", "--expand-requires", "all"); - checkModulesSpecified("M", "java.base", "N", "L", "O"); - checkModulesIncluded("M", "java.base", "N", "L", "O"); + checkModulesSpecified("M", "N", "L", "O"); + checkModulesIncluded("M", "N", "L", "O"); checkModulesNotIncluded("P", "J", "Q"); checkPackagesIncluded("p", "openN", "openL", "openO"); checkPackagesNotIncluded(".*openP.*", ".*openJ.*"); checkTypesIncluded("p.Main", "openN.N", "openL.L", "openO.O"); checkTypesNotIncluded(".*openP.*", ".*openJ.*"); + assertMessageNotPresent("warning"); } @Test @@ -501,7 +532,7 @@ public class Modules extends ModuleTestBase { "--module", "MIA", "--expand-requires", "all"); - assertErrorPresent("javadoc: error - module MIA not found."); + assertMessagePresent("javadoc: error - module MIA not found."); } @Test @@ -523,7 +554,53 @@ public class Modules extends ModuleTestBase { "--module", "M,N,L,MIA,O,P", "--expand-requires", "all"); - assertErrorPresent("javadoc: error - module MIA not found"); + assertMessagePresent("javadoc: error - module MIA not found"); + } + + @Test + public void testSingleModuleOptionWithSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path mod = createSimpleModule(src, "m1"); + execTask("--source-path", mod.toString(), + "--module", "m1"); + checkModulesSpecified("m1"); + checkPackagesIncluded("p"); + checkTypesIncluded("p.C"); + } + + @Test + public void testSingleModuleOptionWithMissingModuleInSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path mod = createSimpleModule(src, "m1"); + execNegativeTask("--source-path", mod.toString(), + "--module", "m2"); + assertMessagePresent("source path does not contain module m2"); + } + + @Test + public void testMultipleModuleOptionWithSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path mod = createSimpleModule(src, "m1"); + execNegativeTask("--source-path", mod.toString(), + "--module", "m1,m2,m3"); + assertMessagePresent("cannot use source path for multiple modules m1, m2, m3"); + } + + @Test + public void testSingleModuleOptionWithNoModuleOnSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path mod1 = Paths.get(src.toString(), "m1"); + execNegativeTask("--source-path", mod1.toString(), + "--module", "m1"); + assertMessagePresent("module m1 not found on source path"); + } + + Path createSimpleModule(Path src, String mname) throws IOException { + Path mpath = Paths.get(src.toString(), mname); + tb.writeJavaFiles(mpath, + "module " + mname + " { exports p; }", + "package p; public class C { }"); + return mpath; } void createAuxiliaryModules(Path src) throws IOException { @@ -538,7 +615,7 @@ public class Modules extends ModuleTestBase { new ModuleBuilder(tb, "L") .comment("The L module.") .exports("openL") - . requiresTransitive("P") + .requiresTransitive("P") .classes("package openL; /** Class L open */ public class L { }") .classes("package closedL; /** Class L closed */ public class L { }") .write(src); @@ -560,7 +637,7 @@ public class Modules extends ModuleTestBase { .write(src); new ModuleBuilder(tb, "P") - .comment("The O module.") + .comment("The P module.") .exports("openP") .requires("J") .classes("package openP; /** Class O open. */ public class O { openJ.J j; }") diff --git a/langtools/test/jdk/javadoc/tool/modules/PackageOptions.java b/langtools/test/jdk/javadoc/tool/modules/PackageOptions.java index 6335418aff5..d54a6662f7a 100644 --- a/langtools/test/jdk/javadoc/tool/modules/PackageOptions.java +++ b/langtools/test/jdk/javadoc/tool/modules/PackageOptions.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -180,7 +180,7 @@ public class PackageOptions extends ModuleTestBase { "--module", "m1", "-subpackages", "m1pub.pub1:pro"); - assertErrorPresent("javadoc: error - No source files for package pro"); + assertMessagePresent("javadoc: error - No source files for package pro"); } @Test diff --git a/langtools/test/jdk/javadoc/tool/modules/PatchModules.java b/langtools/test/jdk/javadoc/tool/modules/PatchModules.java new file mode 100644 index 00000000000..0cba257d6ae --- /dev/null +++ b/langtools/test/jdk/javadoc/tool/modules/PatchModules.java @@ -0,0 +1,209 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8175346 + * @summary Test patch module options + * @modules + * jdk.javadoc/jdk.javadoc.internal.api + * jdk.javadoc/jdk.javadoc.internal.tool + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library /tools/lib + * @build toolbox.ToolBox toolbox.TestRunner + * @run main PatchModules + */ + +import java.nio.file.Path; +import java.nio.file.Paths; + +import toolbox.*; + +public class PatchModules extends ModuleTestBase { + + public static void main(String... args) throws Exception { + new PatchModules().runTests(); + } + + // Case A.1, m2 augmenting m1 + @Test + public void testPatchModuleOption(Path base) throws Exception { + Path src = base.resolve("src"); + Path modulePath = base.resolve("modules"); + Path patchPath = base.resolve("patch"); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "m1"); + mb1.comment("Module on module path.") + .exports("pkg1") + .classes("package pkg1; /** Class A */ public class A { }") + .build(modulePath); + + tb.writeJavaFiles(patchPath, "package pkg1; /** Class A */ public class A { public static int k; }"); + new JavacTask(tb) + .files(patchPath.resolve("pkg1/A.java")) + .run(); + + ModuleBuilder mb2 = new ModuleBuilder(tb, "m2"); + mb2.comment("The second module.") + .exports("pkg2") + .requires("m1") + .classes("package pkg2; /** Class B */ public class B { /** Field f */ public int f = pkg1.A.k; }") + .write(src); + execTask("--module-source-path", src.toString(), + "--patch-module", "m1=" + patchPath.toString(), + "--module-path", modulePath.toString(), + "--module", "m2"); + checkModulesSpecified("m2"); + checkPackagesIncluded("pkg2"); + checkMembersSelected("pkg2.B.f"); + } + + // Case A.2: use package, source form of m1 augmenting binary form of m1 + @Test + public void testPatchModuleWithPackage(Path base) throws Exception { + Path modulePath = base.resolve("modules"); + Path moduleSrcPath = base.resolve("modulesSrc"); + + Path mpath = Paths.get(moduleSrcPath.toString(), "m1"); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "m1"); + mb1.comment("Module m1.") + .exports("pkg1") + .classes("package pkg1; /** Class A */ public class A { }") + .classes("package pkg1.pkg2; /** Class B */ public class B { }") + .build(modulePath); + + execTask("-hasDocComments", + "--module-path", modulePath.toString(), + "--add-modules", "m1", + "--patch-module", "m1=" + mpath.toString(), + "pkg1"); + checkTypesIncluded("pkg1.A hasDocComments"); + } + + // Case A.2: use subpackages, source form of m1 augmenting binary form of m1 + @Test + public void testPatchModuleWithSubPackages(Path base) throws Exception { + Path modulePath = base.resolve("modules"); + Path moduleSrcPath = base.resolve("modulesSrc"); + + Path mpath = Paths.get(moduleSrcPath.toString(), "m1"); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "m1"); + mb1.comment("Module m1.") + .exports("pkg1") + .classes("package pkg1; /** Class A */ public class A { }") + .classes("package pkg1.pkg2; /** Class B */ public class B { }") + .build(modulePath); + + execTask("-hasDocComments", + "--module-path", modulePath.toString(), + "--add-modules", "m1", + "--patch-module", "m1=" + mpath.toString(), + "-subpackages", "pkg1"); + checkTypesIncluded("pkg1.A hasDocComments"); + checkTypesIncluded("pkg1.pkg2.B hasDocComments"); + } + + // Case B.1: (jsr166) augment and override system module + @Test + public void testPatchModuleModifyingSystemModule(Path base) throws Exception { + Path patchSrc = base.resolve("patch"); + + // build the patching sources + tb.writeJavaFiles(patchSrc, "package java.util;\n" + + "/** Class Collection */\n" + + "public interface Collection {}"); + + tb.writeJavaFiles(patchSrc, "package java.util;\n" + + "/** Class MyCollection */\n" + + "public interface MyCollection extends Collection {}"); + + execTask("-hasDocComments", "--patch-module", "java.base=" + patchSrc.toString(), + "java.util"); + + checkPackagesSpecified("java.util"); + checkTypesIncluded("java.util.Collection hasDocComments", + "java.util.MyCollection hasDocComments"); + } + + // Case C.1: patch a user module's sources using source path + @Test + public void testPatchModuleUsingSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path patchSrc = base.resolve("patch"); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "m1"); + mb1.comment("Module m1.") + .exports("pkg1") + .classes("package pkg1; /** Class A */ public class A { }") + .write(src); + + // build the patching module + tb.writeJavaFiles(patchSrc, "package pkg1;\n" + + "/** Class A */ public class A extends java.util.ArrayList { }"); + tb.writeJavaFiles(patchSrc, "package pkg1;\n" + + "/** Class B */ public class B { }"); + + Path m1src = Paths.get(src.toString(), "m1"); + + execTask("--source-path", m1src.toString(), + "--patch-module", "m1=" + patchSrc.toString(), + "pkg1"); + + checkPackagesSpecified("pkg1"); + checkModulesIncluded("m1"); + checkTypesIncluded("pkg1.A", "pkg1.B"); + } + + // Case C.2: patch a user module's sources using module source path + @Test + public void testPatchModuleWithModuleSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path patchSrc = base.resolve("patch"); + + ModuleBuilder mb1 = new ModuleBuilder(tb, "m1"); + mb1.comment("Module on module-source-path.") + .exports("pkg1") + .classes("package pkg1; /** Class A */ public class A { }") + .write(src); + + // build the patching module + tb.writeJavaFiles(patchSrc, "package pkg1;\n" + + "/** Class A */ public class A extends java.util.ArrayList { }"); + tb.writeJavaFiles(patchSrc, "package pkg1;\n" + + "/** Class B */ public class B { }"); + + + execTask("--module-source-path", src.toString(), + "--add-modules", "m1", + "--patch-module", "m1=" + patchSrc.toString(), + "pkg1"); + + checkPackagesSpecified("pkg1"); + checkModulesIncluded("m1"); + checkTypesIncluded("pkg1.A", "pkg1.B"); + } + +} diff --git a/langtools/test/jdk/javadoc/tool/modules/ReleaseOptions.java b/langtools/test/jdk/javadoc/tool/modules/ReleaseOptions.java new file mode 100644 index 00000000000..5d8f9032413 --- /dev/null +++ b/langtools/test/jdk/javadoc/tool/modules/ReleaseOptions.java @@ -0,0 +1,99 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8175346 8175277 + * @summary Test release option interactions + * @modules + * jdk.javadoc/jdk.javadoc.internal.api + * jdk.javadoc/jdk.javadoc.internal.tool + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library /tools/lib + * @build toolbox.ToolBox toolbox.TestRunner + * @run main ReleaseOptions + */ + +import java.nio.file.Path; +import java.nio.file.Paths; + +import toolbox.*; + +public class ReleaseOptions extends ModuleTestBase { + + public static void main(String... args) throws Exception { + new ReleaseOptions().runTests(); + } + + @Test + public void testReleaseWithPatchModule(Path base) throws Exception { + Path src = Paths.get(base.toString(), "src"); + Path mpath = Paths.get(src. toString(), "m"); + + tb.writeJavaFiles(mpath, + "module m { exports p; }", + "package p; public class C { }"); + + Task.Result result = execNegativeTask("--release", "8", + "--patch-module", "m=" + mpath.toString(), + "p"); + assertMessagePresent(".*not allowed with target 1.8.*"); + assertMessageNotPresent(".*Exception*"); + assertMessageNotPresent(".java.lang.AssertionError.*"); + } + + @Test + public void testReleaseWithSourcepath(Path base) throws Exception { + Path src = Paths.get(base.toString(), "src"); + Path mpath = Paths.get(src. toString(), "m"); + + tb.writeJavaFiles(mpath, + "module m { exports p; }", + "package p; public class C { }"); + + Task.Result result = execNegativeTask("--release", "8", + "--source-path", mpath.toString(), + "--module", "m"); + assertMessagePresent(".*(use -source 9 or higher to enable modules).*"); + assertMessageNotPresent(".*Exception*"); + assertMessageNotPresent(".java.lang.AssertionError.*"); + } + + @Test + public void testReleaseWithModuleSourcepath(Path base) throws Exception { + Path src = Paths.get(base.toString(), "src"); + Path mpath = Paths.get(src.toString(), "m"); + + tb.writeJavaFiles(mpath, + "module m { exports p; }", + "package p; public class C { }"); + + Task.Result result = execNegativeTask("--release", "8", + "--module-source-path", src.toString(), + "--module", "m"); + assertMessagePresent(".*not allowed with target 1.8.*"); + assertMessageNotPresent(".*Exception*"); + assertMessageNotPresent(".java.lang.AssertionError.*"); + } +} diff --git a/langtools/test/jdk/javadoc/tool/outputRedirect/p/OutputRedirect.java b/langtools/test/jdk/javadoc/tool/outputRedirect/p/OutputRedirect.java index cbf1b106a7d..c959d913309 100644 --- a/langtools/test/jdk/javadoc/tool/outputRedirect/p/OutputRedirect.java +++ b/langtools/test/jdk/javadoc/tool/outputRedirect/p/OutputRedirect.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,6 @@ package p; import java.io.*; -import jdk.javadoc.internal.tool.Main; public class OutputRedirect { private static final PrintStream originalOutput = System.err; @@ -47,9 +46,9 @@ public class OutputRedirect { PrintWriter sink = new PrintWriter(new ByteArrayOutputStream()); // execute javadoc - int result = Main.execute(new String[] {"p"}, sink); + int result = jdk.javadoc.internal.tool.Main.execute(new String[] {"p"}, sink); - // test whether javadoc did any output to System.out + // tests whether javadoc wrote to System.out if (redirectedOutput.toByteArray().length > 0) { originalOutput.println("Test failed; here's what javadoc wrote on its standard output:"); originalOutput.println(redirectedOutput.toString()); diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/SampleApi.java b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/SampleApi.java index e8b4eedf8d4..84b0e2e93be 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/SampleApi.java +++ b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/SampleApi.java @@ -20,42 +20,135 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ - package sampleapi; -import java.io.File; -import java.io.FilenameFilter; +import com.sun.source.util.JavacTask; +import com.sun.tools.javac.api.JavacTaskImpl; +import com.sun.tools.javac.api.JavacTool; +import com.sun.tools.javac.util.Context; +import java.io.IOException; +import java.io.InputStream; +import java.io.UncheckedIOException; +import java.nio.file.Files; import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.ArrayList; +import java.util.List; +import java.util.Optional; +import static java.util.stream.Collectors.toList; +import javax.xml.parsers.DocumentBuilder; +import javax.xml.parsers.DocumentBuilderFactory; +import javax.xml.parsers.ParserConfigurationException; +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.w3c.dom.NodeList; +import org.xml.sax.SAXException; +import sampleapi.generator.ModuleGenerator; import sampleapi.generator.PackageGenerator; public class SampleApi { - PackageGenerator pkgGen = new PackageGenerator(); + private final Context ctx; + private final List modules = new ArrayList<>(); - public void generate(File resDir, File outDir) throws Fault { - FilenameFilter filter = (dir, name) -> { return name.endsWith(".xml"); }; - File[] resFiles = resDir.listFiles(filter); - for (File resFile : resFiles) { - pkgGen.processDataSet(resFile); - pkgGen.generate(outDir); - } + public SampleApi() { + JavacTool jt = JavacTool.create(); + JavacTask task = jt.getTask(null, null, null, null, null, null); + ctx = ((JavacTaskImpl) task).getContext(); } - public void generate(Path res, Path dir) throws Fault { - generate(res.toFile(), dir.toFile()); + public static SampleApi load(Path resDir) + throws ParserConfigurationException, IOException, SAXException { + SampleApi result = new SampleApi(); + System.out.println("Loading resources from " + resDir); + DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); + DocumentBuilder builder = factory.newDocumentBuilder(); + Files.list(resDir) + .peek(f -> System.out.println(f.getFileName())) + .filter(f -> f.getFileName().toString().endsWith(".xml")) + .peek(f -> System.out.println(f.getFileName())) + .forEach(resFile -> { + try (InputStream is = Files.newInputStream(resFile)) { + Document document = builder.parse(is); + NodeList moduleElements = document.getElementsByTagName("module"); + for (int i = 0; i < moduleElements.getLength(); i++) { + result.modules.add(ModuleGenerator + .load((Element) moduleElements.item(i))); + } + } catch (IOException ex) { + throw new UncheckedIOException(ex); + } catch (SAXException ex) { + throw new RuntimeException(ex); + } + }); + return result; } - public void generate(String res, String dir) throws Fault { - generate(new File(res), new File(dir)); + public Context getContext() { + return ctx; } - public static class Fault extends Exception { - public Fault(String msg) { - super(msg); - } - public Fault(String msg, Throwable th) { - super(msg, th); + public List getModules() { + return modules; + } + + + public void generate(Path outDir) { + //resolveIDs(modules); + modules.forEach(m -> { + try { + m.generate(outDir, this); + } catch (IOException ex) { + throw new UncheckedIOException(ex); + } + }); + } + + public void generate(String dir) + throws ParserConfigurationException, IOException, SAXException { + generate(Paths.get(dir)); + } + + public ModuleGenerator moduleById(String id) { + String real_id = getId(id); + return modules.stream() + .filter(m -> m.id.equals(real_id)) + .findAny().orElseThrow(() -> new IllegalStateException("No module with id: " + real_id)); + } + + public PackageGenerator packageById(String id) { + String real_id = getId(id); + return modules.stream() + .flatMap(m -> m.packages.stream()) + .filter(p -> p.id.equals(real_id)).findAny() + .orElseThrow(() -> new IllegalStateException("No package with id: " + real_id)); + } + + public String classById(String id) { + String real_id = getId(id); + return modules.stream() + .flatMap(m -> m.packages.stream()) + .peek(p -> System.out.println(p.packageName + " " + p.idBases.size())) + .flatMap(p -> p.idBases.entrySet().stream() + .filter(e -> e.getKey().equals(real_id)) + .map(e -> p.packageName + "." + e.getValue().name.toString()) + .peek(System.out::println)) + .findAny().orElseThrow(() -> new IllegalStateException("No class with id: " + id)); + } + + public boolean isId(String name) { + return name.startsWith("$"); + } + + public boolean isIdEqual(String name, String id) { + return isId(name) && getId(name).equals(id); + } + + public String getId(String name) { + if(!isId(name)) { + throw new IllegalStateException("Not an id: " + name); } + return name.substring(1); } } diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/SampleApiDefaultRunner.java b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/SampleApiDefaultRunner.java index 23459d5fec4..c77664c2103 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/SampleApiDefaultRunner.java +++ b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/SampleApiDefaultRunner.java @@ -23,9 +23,9 @@ package sampleapi; -import java.io.File; - -import sampleapi.SampleApi.Fault; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; public class SampleApiDefaultRunner { @@ -132,12 +132,12 @@ public class SampleApiDefaultRunner { return 1; } - File resDir = new File(resDirName); - File outDir = new File(outDirName); - outDir.mkdirs(); + Path resDir = Paths.get(resDirName); + Path outDir = Paths.get(outDirName); + Files.createDirectories(outDir); SampleApi apiGen = new SampleApi(); - apiGen.generate(resDir, outDir); + apiGen.load(resDir).generate(outDir); return 0; } diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/generator/ModuleGenerator.java b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/generator/ModuleGenerator.java new file mode 100644 index 00000000000..76345638fa1 --- /dev/null +++ b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/generator/ModuleGenerator.java @@ -0,0 +1,270 @@ +/* + * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +package sampleapi.generator; + +import com.sun.source.tree.ModuleTree.ModuleKind; +import com.sun.tools.javac.code.Symbol; +import com.sun.tools.javac.parser.Scanner; +import com.sun.tools.javac.parser.ScannerFactory; +import com.sun.tools.javac.parser.Tokens; +import com.sun.tools.javac.tree.JCTree; +import com.sun.tools.javac.tree.JCTree.JCDirective; +import com.sun.tools.javac.tree.JCTree.JCExpression; +import com.sun.tools.javac.tree.TreeMaker; +import com.sun.tools.javac.util.Context; +import com.sun.tools.javac.util.Names; +import com.sun.tools.javac.util.ListBuffer; +import java.io.IOException; +import java.io.OutputStream; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.List; +import java.util.ArrayList; +import org.w3c.dom.Element; +import org.w3c.dom.NodeList; + +import sampleapi.SampleApi; +import sampleapi.util.PoorDocCommentTable; + +import static com.sun.tools.javac.parser.Tokens.Comment.CommentStyle.JAVADOC; + +/** + * + * This class is responsible for loading module description from an XML and then generating the + * module-info.java. It is using {@link PackageGenerator} class for parsing content of the module. + */ +public class ModuleGenerator { + + private static final String UNNAMED = "UNNAMED"; + private static final String MODULE_INFO = "module-info.java"; + + public String name; + public String id; + public ModuleKind kind; + public final List exportss = new ArrayList<>(); + public final List openss = new ArrayList<>(); + public final List requiress = new ArrayList<>(); + public final List usess = new ArrayList<>(); + public final List providess = new ArrayList<>(); + public final List packages = new ArrayList<>(); + + private ModuleGenerator() { + } + + public static ModuleGenerator load(Element rootElement) { + ModuleGenerator result = new ModuleGenerator(); + result.name = rootElement.getAttribute("name"); + result.id = rootElement.getAttribute("id"); + String kind = rootElement.getAttribute("kind"); + result.kind = kind.isEmpty() ? ModuleKind.STRONG : + ModuleKind.valueOf(kind.toUpperCase()); + //exports + NodeList exportsList = rootElement.getElementsByTagName("exports"); + for (int i = 0; i < exportsList.getLength(); i++) { + Element exportsEl = (Element) exportsList.item(i); + Exports exports = new Exports(exportsEl.getAttribute("package")); + NodeList toList = exportsEl.getElementsByTagName("to"); + for (int j = 0; j < toList.getLength(); j++) { + Element toElement = (Element) toList.item(j); + exports.modules.add(toElement.getAttribute("module")); + } + result.exportss.add(exports); + } + //opens + NodeList opensList = rootElement.getElementsByTagName("opens"); + for (int i = 0; i < opensList.getLength(); i++) { + Element opensEl = (Element) opensList.item(i); + Opens opens = new Opens(opensEl.getAttribute("package")); + NodeList toList = opensEl.getElementsByTagName("to"); + for (int j = 0; j < toList.getLength(); j++) { + Element toElement = (Element) toList.item(j); + opens.modules.add(toElement.getAttribute("module")); + } + result.openss.add(opens); + } + //requires + NodeList requiresList = rootElement.getElementsByTagName("requires"); + for (int i = 0; i < requiresList.getLength(); i++) { + Element requiresEl = (Element) requiresList.item(i); + result.requiress.add(new Requires(requiresEl.getAttribute("module"), + Boolean.parseBoolean(requiresEl.getAttribute("transitive")), + Boolean.parseBoolean(requiresEl.getAttribute("static")))); + } + //uses + NodeList usesList = rootElement.getElementsByTagName("uses"); + for (int i = 0; i < usesList.getLength(); i++) { + Element usesEl = (Element) usesList.item(i); + result.usess.add(new Uses(usesEl.getAttribute("service"))); + } + //provides + NodeList providesList = rootElement.getElementsByTagName("provides"); + for (int i = 0; i < providesList.getLength(); i++) { + Element providesEl = (Element) providesList.item(i); + Provides provides = new Provides(providesEl.getAttribute("service")); + NodeList implList = providesEl.getElementsByTagName("implementation"); + for (int j = 0; j < implList.getLength(); j++) { + Element implElement = (Element) implList.item(j); + provides.implementations.add(implElement.getAttribute("class")); + } + result.providess.add(provides); + } + //packages + NodeList packagesList = rootElement.getElementsByTagName("package"); + for (int i = 0; i < packagesList.getLength(); i++) { + result.packages.add(PackageGenerator + .processDataSet((Element) packagesList.item(i))); + } + return result; + } + + public void generate(Path outDir, SampleApi api) throws IOException { + Files.createDirectories(outDir); + Path moduleSourceDir; + if (!name.equals(UNNAMED)) { + moduleSourceDir = outDir.resolve(name); + Files.createDirectory(moduleSourceDir); + generateModuleInfo(moduleSourceDir, api); + } else { + moduleSourceDir = outDir; + } + packages.forEach(pkg -> pkg.generate(moduleSourceDir)); + } + + private void generateModuleInfo(Path moduleSourceDir, SampleApi api) throws IOException { + TreeMaker make = TreeMaker.instance(api.getContext()); + Names names = Names.instance(api.getContext()); + JCTree.JCExpression modQual = make.QualIdent( + new Symbol.ModuleSymbol(names.fromString(name), null)); + ListBuffer exportsBuffer = new ListBuffer<>(); + exportss.forEach(e -> { + ListBuffer modulesBuffer = new ListBuffer<>(); + e.modules.stream() + .map(m -> api.isId(m) ? api.moduleById(m).name : m) + .forEach(m -> { + modulesBuffer.add(make.Ident( + names.fromString(m))); + }); + exportsBuffer.add(make.Exports( + make.Ident(names.fromString(api.isId(e.pkg) ? + api.packageById(e.pkg).packageName : e.pkg)), + (modulesBuffer.size() > 0) ? modulesBuffer.toList() : null)); + }); + openss.forEach(o -> { + ListBuffer modulesBuffer = new ListBuffer<>(); + o.modules.stream() + .map(m -> api.isId(m) ? api.moduleById(m).name : m) + .forEach(m -> { + modulesBuffer.add(make.Ident( + names.fromString(m))); + }); + exportsBuffer.add(make.Opens( + make.Ident(names.fromString(api.isId(o.pkg) ? + api.packageById(o.pkg).packageName : o.pkg)), + (modulesBuffer.size() > 0) ? modulesBuffer.toList() : null)); + }); + ListBuffer requiresBuffer = new ListBuffer<>(); + requiress.forEach(r -> requiresBuffer.add(make.Requires( + r.transitive, r.statc, + make.Ident(names.fromString(api.isId(r.module) + ? api.moduleById(r.module).name : r.module))))); + ListBuffer usesBuffer = new ListBuffer<>(); + usess.forEach(u -> usesBuffer + .add(make.Uses(make.Ident(names.fromString(api.isId(u.service) + ? api.classById(u.service) : u.service))))); + ListBuffer providesBuffer = new ListBuffer<>(); + providess.forEach(p -> { + ListBuffer implementationsBuffer = new ListBuffer<>(); + p.implementations.stream() + .map(c -> api.isId(c) ? api.classById(c) : c) + .forEach(i -> { + implementationsBuffer.add(make.Ident(names.fromString(i))); + }); + providesBuffer.add(make.Provides( + make.Ident(names.fromString(api.isId(p.service) ? + api.classById(p.service) : p.service)), + implementationsBuffer.toList())); + }); + ListBuffer fullList = new ListBuffer<>(); + fullList.addAll(exportsBuffer.toList()); + fullList.addAll(requiresBuffer.toList()); + fullList.addAll(usesBuffer.toList()); + fullList.addAll(providesBuffer.toList()); + JCTree.JCModuleDecl mod = make.ModuleDef( + make.Modifiers(0), //TODO how to support this? + kind, modQual, fullList.toList()); + ListBuffer top = new ListBuffer<>(); + top.add(mod); + JCTree.JCCompilationUnit compilationUnit = make.TopLevel(top.toList()); + try (OutputStream module_info = Files.newOutputStream(moduleSourceDir.resolve(MODULE_INFO))) { + module_info.write(compilationUnit.toString().getBytes()); + } + } + + + public static class Requires { + public String module; + public boolean transitive; + public boolean statc; + + private Requires(String module, boolean transitive, boolean statc) { + this.module = module; + this.transitive = transitive; + this.statc = this.statc; + } + } + + public static class Exports { + public final String pkg; + public final List modules = new ArrayList<>(); + + private Exports(String pkg) { + this.pkg = pkg; + } + } + + public static class Opens { + public final String pkg; + public final List modules = new ArrayList<>(); + + private Opens(String pkg) { + this.pkg = pkg; + } + } + + public static class Uses { + public final String service; + + private Uses(String service) { + this.service = service; + } + } + + public static class Provides { + public final String service; + public final List implementations = new ArrayList<>(); + + private Provides(String service) { + this.service = service; + } + } +} diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/generator/PackageGenerator.java b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/generator/PackageGenerator.java index cab0adea709..a0fcd71804f 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/generator/PackageGenerator.java +++ b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/generator/PackageGenerator.java @@ -25,17 +25,11 @@ package sampleapi.generator; import java.io.File; import java.io.FileWriter; -import java.io.InputStream; -import java.io.FileInputStream; import java.io.IOException; import java.util.ArrayList; import java.util.HashMap; import java.util.Map; import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.ParserConfigurationException; -import org.xml.sax.SAXException; -import org.w3c.dom.Document; import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c.dom.NodeList; @@ -56,18 +50,19 @@ import com.sun.tools.javac.code.Type; import com.sun.tools.javac.code.TypeTag; import com.sun.tools.javac.code.Symbol; import com.sun.tools.javac.code.Symtab; +import java.nio.file.Path; import sampleapi.util.*; -import sampleapi.SampleApi.Fault; public class PackageGenerator { - String packageName; + public String packageName; String packageDirName; + public String id; ArrayList topLevels; Map nameIndex; - Map idBases; + public Map idBases; Map idAnnos; TreeMaker make; @@ -92,48 +87,43 @@ public class PackageGenerator { boolean isDataSetProcessed = false; - public void processDataSet(File dsFile) throws Fault { - isDataSetProcessed = true; - topLevels = new ArrayList<>(); - nameIndex = new HashMap<>(); - idBases = new HashMap<>(); - idAnnos = new HashMap<>(); - fx = false; + public static PackageGenerator processDataSet(Element rootElement) { + PackageGenerator result = new PackageGenerator(); + result.isDataSetProcessed = true; + result.topLevels = new ArrayList<>(); + result.nameIndex = new HashMap<>(); + result.idBases = new HashMap<>(); + result.idAnnos = new HashMap<>(); + result.fx = false; - try { - InputStream is = new FileInputStream(dsFile); - - DocumentBuilder builder = factory.newDocumentBuilder(); - Document document = builder.parse(is); - - Element rootElement = document.getDocumentElement(); - if (!rootElement.getTagName().equals("package")) - throw new IllegalStateException("Unexpected tag name: " - + rootElement.getTagName()); - packageName = rootElement.getAttribute("name"); - fx = "fx".equals(rootElement.getAttribute("style")); - packageDirName = packageName.replace('.', '/'); - - // process nodes (toplevels) - NodeList nodeList = rootElement.getChildNodes(); - for (int i = 0; i < nodeList.getLength(); i++) { - Node node = nodeList.item(i); - - if (!(node instanceof Element)) - continue; - processTopLevel((Element) node); - } - } catch (ParserConfigurationException | SAXException | IOException e) { - throw new Fault("Error parsing dataset " + dsFile, e); + if (!rootElement.getTagName().equals("package")) { + throw new IllegalStateException("Unexpected tag name: " + + rootElement.getTagName()); } + result.packageName = rootElement.getAttribute("name"); + result.id = rootElement.getAttribute("id"); + result.fx = "fx".equals(rootElement.getAttribute("style")); + result.packageDirName = result.packageName.replace('.', '/'); + + // process nodes (toplevels) + NodeList nodeList = rootElement.getChildNodes(); + for (int i = 0; i < nodeList.getLength(); i++) { + Node node = nodeList.item(i); + + if (!(node instanceof Element)) { + continue; + } + result.processTopLevel((Element) node); + } + return result; } - public void generate(File outDir) throws Fault { + public void generate(Path outDir) { if (!isDataSetProcessed) - throw new Fault("No Data Set processed"); + throw new RuntimeException("No Data Set processed"); try { - File pkgDir = new File(outDir, packageDirName); + File pkgDir = new File(outDir.toFile(), packageDirName); pkgDir.mkdirs(); for (JCCompilationUnit decl : topLevels) { @@ -168,7 +158,7 @@ public class PackageGenerator { writer.flush(); writer.close(); } catch (IOException e) { - throw new Fault("Error writing output"); + throw new RuntimeException("Error writing output"); } } @@ -211,6 +201,7 @@ public class PackageGenerator { String baseName = baseTag.getAttribute("basename"); String typeParam = baseTag.getAttribute("tparam"); String baseId = baseTag.getAttribute("id"); + System.out.println("Found class id: " + baseId); long kindFlag = 0; switch (kind) { diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/util/SimpleMultiplier.java b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/util/SimpleMultiplier.java index 0e9760ee606..545e671c640 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/util/SimpleMultiplier.java +++ b/langtools/test/jdk/javadoc/tool/sampleapi/lib/sampleapi/util/SimpleMultiplier.java @@ -72,8 +72,8 @@ public class SimpleMultiplier { } public void initIterator() { + size = 1; if (!valueSpace.isEmpty()) { - size = 1; for (int i = 0; i < valueSpace.size(); i++) size *= valueSpace.get(i).size(); } diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/res/fx.xml b/langtools/test/jdk/javadoc/tool/sampleapi/res/fx.xml index d26177227bf..225df813896 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/res/fx.xml +++ b/langtools/test/jdk/javadoc/tool/sampleapi/res/fx.xml @@ -21,25 +21,27 @@ or visit www.oracle.com if you need additional information or have any questions. --> - - - - public - - + + + + public - int|boolean - - - public|protected|private - int|String - void - - - public|protected|private - int|int|String - - - - - + + + public + int|boolean + + + public|protected|private + int|String + void + + + public|protected|private + int|int|String + + + + + + diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/res/simple.xml b/langtools/test/jdk/javadoc/tool/sampleapi/res/simple.xml index b5a49159b9d..3d805fdd16d 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/res/simple.xml +++ b/langtools/test/jdk/javadoc/tool/sampleapi/res/simple.xml @@ -21,509 +21,512 @@ or visit www.oracle.com if you need additional information or have any questions. --> - - - - public - none|abstract - - - none|public - none|static - none|final - boolean|int|String - - - protected|private - String - - - public - none|int|int,boolean|int,String - - - public - String - NullPointerException - SampleException0 - - - public - void - int - - - public - int|boolean|String - - - public - void|int - none|int|Object,int - NullPointerException - ArithmeticException - - - - - - public - - - - public - int|boolean - - - public - none|int|int,boolean|int,String - - - public - int|boolean - - - - - - java.io.Serializable - public - - - - private|none|public - boolean|int|String - - - - - - java.io.Serializable - java.io.ObjectStreamField - public - - - String,Long,Boolean - - public - String|long|boolean - - - - - - java.io.Serializable - java.io.ObjectOutputStream - java.io.ObjectOutput - java.io.IOException - java.io.ObjectStreamException - public - - - - private - ObjectOutputStream - void - IOException - - - public - ObjectOutput - void - IOException - - - protected - none - Object - ObjectStreamException - - - public - Object - void - IOException - - - - - - java.io.Serializable - java.io.ObjectInputStream - java.io.ObjectInput - java.io.IOException - java.io.ObjectStreamException - public - - - - private - ObjectInputStream - void - IOException - ClassNotFoundException - - - public - ObjectInput - void - IOException - - - protected - none - Object - ObjectStreamException - - - public - Object - void - IOException - - - - - - public - - + + + + public + none|abstract - + + none|public + none|static + none|final + boolean|int|String + + + protected|private + String + + public - int + none|int|int,boolean|int,String + + + public + String + NullPointerException + SampleException0 + + + public + void + int + + + public + int|boolean|String + + + public + void|int + none|int|Object,int + NullPointerException + ArithmeticException + + + + + + public + + + + public + int|boolean + + + public + none|int|int,boolean|int,String + + + public + int|boolean + + + + + + java.io.Serializable + public + + + + private|none|public + boolean|int|String - + + + java.io.Serializable + java.io.ObjectStreamField public - static - - - public - static + - - public - void + String,Long,Boolean + + public + String|long|boolean + + + + + + java.io.Serializable + java.io.ObjectOutputStream + java.io.ObjectOutput + java.io.IOException + java.io.ObjectStreamException + public + + + + private + ObjectOutputStream + void + IOException + + + public + ObjectOutput + void + IOException + + + protected + none + Object + ObjectStreamException + + + public + Object + void + IOException + + + + + + java.io.Serializable + java.io.ObjectInputStream + java.io.ObjectInput + java.io.IOException + java.io.ObjectStreamException + public + + + + private + ObjectInputStream + void + IOException + ClassNotFoundException + + + public + ObjectInput + void + IOException + + + protected + none + Object + ObjectStreamException + + + public + Object + void + IOException + + + + + + public + + + public + + + public + int + + + + + public + static + + + public + static + + + public + void + + + + + + + + + public + + + + private + boolean|int|String + + + public + String + + + public + int|String + + + + + + public + + + + private + boolean|int|String + + + public + String + + + public + int|String + + + + + + public|none + + + public + void|int|Object - - - - - public - - - - private - boolean|int|String - - + public - String - - - public - int|String - - - + + + + public + int|boolean + + + public + int|boolean + + + - - public - - - - private - boolean|int|String - - + + java.util.List public - String - - - public - int|String - - - + + + public + void + T + + + public + T + int + + + public + List<T> + + + - - public|none - - + + java.util.Set + java.util.List + java.util.Map public - void|int|Object - - - + + + public + void + K,V + + + public + void + Map<K,V> + + + public + V + K + + + public + Set<V>|List<V> + + + public + Set<K>|List<K> + + + - - public - - - + + java.util.Set + java.util.List + java.util.Map public - int|boolean - - - public - int|boolean - - - + + + public + Set<M>|List<M> + Map<N,O> + + + public + Set<N>|List<N> + Map<M,O> + + + public + Set<O>|List<O> + Map<M,N> + + + - - java.util.List - public - - + + java.util.Set + java.util.List + java.util.Map + java.util.function.Supplier public - void - T - - - public - T - int - - - public - List<T> - - - + + + public + static + Set<? extends E>|List<? extends E> + + + public|private + static + Map<V,K> + + + public + static + void + E + + + public|private + static + X + Supplier<? extends X> + X + + + - - java.util.Set - java.util.List - java.util.Map - public - - + public - void - K,V - - - public - void - Map<K,V> - - - public - V - K - - - public - Set<V>|List<V> - - - public - Set<K>|List<K> - - - - - - java.util.Set - java.util.List - java.util.Map - public - - - public - Set<M>|List<M> - Map<N,O> - - - public - Set<N>|List<N> - Map<M,O> - - - public - Set<O>|List<O> - Map<M,N> - - - - - - java.util.Set - java.util.List - java.util.Map - java.util.function.Supplier - public - - - public - static - Set<? extends E>|List<? extends E> - - - public|private - static - Map<V,K> - - - public - static - void - E - - - public|private - static - X - Supplier<? extends X> - X - - - - - - public - - - - + + + + - - public - - - - - private - int|String - - + public - void|String - - - + + + + + private + int|String + + + public + void|String + + + - - Documented - + + Documented + - - Retention - - + + Retention + + - - Retention - - + + Retention + + - - Retention - - + + Retention + + - - Target - - + + Target + + - - Target - - + + Target + + - - Target - - + + Target + + - - java.lang.annotation.Documented - @documented - public - - - public - boolean|String - - - - - - java.lang.annotation.Retention - java.lang.annotation.RetentionPolicy - @reten-source|@reten-class|@reten-runtime - public - - - public - int - - - - - - java.lang.annotation.Retention - java.lang.annotation.RetentionPolicy - java.lang.annotation.Target - java.lang.annotation.ElementType - public - - @reten-source|@reten-class|@reten-runtime - @target-method|@target-field|@target-type + java.lang.annotation.Documented + @documented public - static public - String + boolean|String - - - - Deprecated - - - - SafeVarargs - - - - SuppressWarnings - - - - - public - - - @deprecated + + java.lang.annotation.Retention + java.lang.annotation.RetentionPolicy + @reten-source|@reten-class|@reten-runtime public - void - - - @safevarargs + + + public + int + + + + + + java.lang.annotation.Retention + java.lang.annotation.RetentionPolicy + java.lang.annotation.Target + java.lang.annotation.ElementType public - void|int - String... - - - @suppresswarnings + + + @reten-source|@reten-class|@reten-runtime + @target-method|@target-field|@target-type + public + static + + + public + String + + + + + + + + Deprecated + + + + SafeVarargs + + + + SuppressWarnings + + + + public - void - int|Object - - - - + + + @deprecated + public + void + + + @safevarargs + public + void|int + String... + + + @suppresswarnings + public + void + int|Object + + + + + + diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/res/sub.xml b/langtools/test/jdk/javadoc/tool/sampleapi/res/sub.xml index ff007c781ac..875b1aef683 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/res/sub.xml +++ b/langtools/test/jdk/javadoc/tool/sampleapi/res/sub.xml @@ -21,69 +21,72 @@ or visit www.oracle.com if you need additional information or have any questions. --> - + + + + + public + none|abstract + SInterface0 + + + public + int + + + public + int + SException0 + + + public + int + void + SException0 + + + - - public - none|abstract - SInterface0 - - + public - int - - - public - int - SException0 - - - public - int - void - SException0 - - - + + + + public + String + + + - - public - - - + public - String - - - + + + public + void + int + + + - - public - - + public - void - int - - - + + + + + - - public - - - - - - - - public - - + public - boolean - - - + + + public + boolean + + + - + + + diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/res/tiny.xml b/langtools/test/jdk/javadoc/tool/sampleapi/res/tiny.xml index 1bf631faa8c..1e33f8358f3 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/res/tiny.xml +++ b/langtools/test/jdk/javadoc/tool/sampleapi/res/tiny.xml @@ -21,51 +21,53 @@ or visit www.oracle.com if you need additional information or have any questions. --> - - - - public - none|abstract - - + + + + public - int - - - public - int - - - + none|abstract + + + public + int + + + public + int + + + - - public - - + public - void - int - - - + + + public + void + int + + + - - public - - - - - - - - - public - - + public - boolean - - - - - + + + + + + + + + public + + + public + boolean + + + + + + diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/res/tinysub.xml b/langtools/test/jdk/javadoc/tool/sampleapi/res/tinysub.xml index 99b181f4899..e4826e2998f 100644 --- a/langtools/test/jdk/javadoc/tool/sampleapi/res/tinysub.xml +++ b/langtools/test/jdk/javadoc/tool/sampleapi/res/tinysub.xml @@ -21,69 +21,71 @@ or visit www.oracle.com if you need additional information or have any questions. --> - + + + + + public + none|abstract + TSInterface0 + + + public + int + + + public + int + TSException0 + + + public + int + void + TSException0 + + + - - public - none|abstract - TSInterface0 - - + public - int - - - public - int - TSException0 - - - public - int - void - TSException0 - - - + + + + public + String + + + - - public - - - + public - String - - - + + + public + void + int + + + - - public - - + public - void - int - - - + + + + + - - public - - - - - - - - public - - + public - boolean - - - - - + + + public + boolean + + + + + + diff --git a/langtools/test/jdk/javadoc/tool/sampleapi/res/transitive.xml b/langtools/test/jdk/javadoc/tool/sampleapi/res/transitive.xml new file mode 100644 index 00000000000..22a79ea33dd --- /dev/null +++ b/langtools/test/jdk/javadoc/tool/sampleapi/res/transitive.xml @@ -0,0 +1,98 @@ + + + + + + + + + + + + + + + public + + + public + Object + + + + + + + public + + + Object + void + + + + + + + + + + + + + + + + + + + + + + + + public + none|abstract + SInterface0 + + + public + int + + + public + int + SException0 + + + public + int + void + SException0 + + + + + + diff --git a/langtools/test/jdk/javadoc/tool/treeapi/overview.html b/langtools/test/jdk/javadoc/tool/treeapi/overview.html index d825975f0be..145796c69e1 100644 --- a/langtools/test/jdk/javadoc/tool/treeapi/overview.html +++ b/langtools/test/jdk/javadoc/tool/treeapi/overview.html @@ -13,7 +13,7 @@ accompanied this code). You should have received a copy of the GNU General Public License version - along with this work; if not, write to the Free Software Foundation, + 2 along with this work; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA diff --git a/langtools/test/jdk/jshell/CommandCompletionTest.java b/langtools/test/jdk/jshell/CommandCompletionTest.java index 31559d9f379..535a9eb1c7e 100644 --- a/langtools/test/jdk/jshell/CommandCompletionTest.java +++ b/langtools/test/jdk/jshell/CommandCompletionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8144095 8164825 8169818 8153402 8165405 + * @bug 8144095 8164825 8169818 8153402 8165405 8177079 8178013 8167554 * @summary Test Command Completion * @modules jdk.compiler/com.sun.tools.javac.api * jdk.compiler/com.sun.tools.javac.main @@ -162,18 +162,22 @@ public class CommandCompletionTest extends ReplToolTesting { "/edit ", "/env ", "/exit ", "/help ", "/history ", "/imports ", "/list ", "/methods ", "/open ", "/reload ", "/reset ", - "/save ", "/set ", "/types ", "/vars ", "context ", "intro ", "shortcuts "), + "/save ", "/set ", "/types ", "/vars ", "context ", "intro ", "rerun ", "shortcuts "), a -> assertCompletion(a, "/? |", false, "/! ", "/- ", "/ ", "/? ", "/drop ", "/edit ", "/env ", "/exit ", "/help ", "/history ", "/imports ", "/list ", "/methods ", "/open ", "/reload ", "/reset ", - "/save ", "/set ", "/types ", "/vars ", "context ", "intro ", "shortcuts "), + "/save ", "/set ", "/types ", "/vars ", "context ", "intro ", "rerun ", "shortcuts "), a -> assertCompletion(a, "/help /s|", false, "/save ", "/set "), a -> assertCompletion(a, "/help /set |", false, "editor", "feedback", "format", "mode", "prompt", "start", "truncation"), - a -> assertCompletion(a, "/help /edit |", false) + a -> assertCompletion(a, "/help set |", false, + "editor", "feedback", "format", "mode", "prompt", "start", "truncation"), + a -> assertCompletion(a, "/help /edit |", false), + a -> assertCompletion(a, "/help dr|", false, + "drop ") ); } diff --git a/langtools/test/jdk/jshell/CompletionSuggestionTest.java b/langtools/test/jdk/jshell/CompletionSuggestionTest.java index 7873e438496..8ec12c05fd5 100644 --- a/langtools/test/jdk/jshell/CompletionSuggestionTest.java +++ b/langtools/test/jdk/jshell/CompletionSuggestionTest.java @@ -23,7 +23,7 @@ /* * @test - * @bug 8131025 8141092 8153761 8145263 8131019 + * @bug 8131025 8141092 8153761 8145263 8131019 8175886 8176184 8176241 * @summary Test Completion and Documentation * @library /tools/lib * @modules jdk.compiler/com.sun.tools.javac.api @@ -295,6 +295,10 @@ public class CompletionSuggestionTest extends KullaTesting { new HashSet<>(Arrays.asList("class"))); } + public void testImportStart() { + assertCompletionIncludesExcludes("import c|", Set.of("com"), Set.of()); + } + public void testBrokenClassFile() throws Exception { Compiler compiler = new Compiler(); Path testOutDir = Paths.get("CompletionTestBrokenClassFile"); diff --git a/langtools/test/jdk/jshell/DyingRemoteAgent.java b/langtools/test/jdk/jshell/DyingRemoteAgent.java index 1bf50e6f7e7..1eeb6c2b12a 100644 --- a/langtools/test/jdk/jshell/DyingRemoteAgent.java +++ b/langtools/test/jdk/jshell/DyingRemoteAgent.java @@ -22,6 +22,8 @@ */ import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; import jdk.jshell.JShell; import jdk.jshell.execution.JdiExecutionControlProvider; import jdk.jshell.execution.RemoteExecutionControl; @@ -45,6 +47,8 @@ class DyingRemoteAgent extends RemoteExecutionControl { pm.put(JdiExecutionControlProvider.PARAM_REMOTE_AGENT, DyingRemoteAgent.class.getName()); pm.put(JdiExecutionControlProvider.PARAM_HOST_NAME, host==null? "" : host); pm.put(JdiExecutionControlProvider.PARAM_LAUNCH, ""+isLaunch); + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); return JShell.builder() .executionEngine(ecp, pm) .build(); diff --git a/langtools/test/jdk/jshell/EditorTestBase.java b/langtools/test/jdk/jshell/EditorTestBase.java index 074b4a5bd14..927ebc6466e 100644 --- a/langtools/test/jdk/jshell/EditorTestBase.java +++ b/langtools/test/jdk/jshell/EditorTestBase.java @@ -73,7 +73,7 @@ public abstract class EditorTestBase extends ReplToolTesting { for (String edit : new String[] {"/ed", "/edit"}) { test(new String[]{"--no-startup"}, a -> assertCommandOutputStartsWith(a, edit + " 1", - "| No such snippet: 1"), + "| No snippet with id: 1"), a -> assertCommandOutputStartsWith(a, edit + " unknown", "| No such snippet: unknown") ); diff --git a/langtools/test/jdk/jshell/FileManagerTest.java b/langtools/test/jdk/jshell/FileManagerTest.java new file mode 100644 index 00000000000..9e4f063da9d --- /dev/null +++ b/langtools/test/jdk/jshell/FileManagerTest.java @@ -0,0 +1,114 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test 8173845 + * @summary test custom file managers + * @build KullaTesting TestingInputStream + * @run testng FileManagerTest + */ + + +import java.io.File; +import java.io.IOException; + +import java.util.Set; +import javax.tools.ForwardingJavaFileManager; +import javax.tools.JavaFileObject; +import javax.tools.JavaFileObject.Kind; +import javax.tools.StandardJavaFileManager; +import org.testng.annotations.BeforeMethod; +import org.testng.annotations.Test; + +import static org.testng.Assert.assertTrue; + +@Test +public class FileManagerTest extends KullaTesting { + + boolean encountered; + + class MyFileManager extends ForwardingJavaFileManager + implements StandardJavaFileManager { + + protected MyFileManager(StandardJavaFileManager fileManager) { + super(fileManager); + } + + @Override + public Iterable list(Location location, + String packageName, + Set kinds, + boolean recurse) + throws IOException { + //System.out.printf("list(%s, %s, %s, %b)\n", + // location, packageName, kinds, recurse); + if (packageName.equals("java.lang.reflect")) { + encountered = true; + } + return fileManager.list(location, packageName, kinds, recurse); + } + + @Override + public Iterable getJavaFileObjectsFromFiles(Iterable files) { + return fileManager.getJavaFileObjectsFromFiles(files); + } + + @Override + public Iterable getJavaFileObjects(File... files) { + return fileManager.getJavaFileObjects(files); + } + + @Override + public Iterable getJavaFileObjectsFromStrings(Iterable names) { + return fileManager.getJavaFileObjectsFromStrings(names); + } + + @Override + public Iterable getJavaFileObjects(String... names) { + return fileManager.getJavaFileObjects(names); + } + + @Override + public void setLocation(Location location, Iterable files) throws IOException { + fileManager.setLocation(location, files); + } + + @Override + public Iterable getLocation(Location location) { + return fileManager.getLocation(location); + } + + } + + @BeforeMethod + @Override + public void setUp() { + setUp(b -> b.fileManager(fm -> new MyFileManager(fm))); + } + + public void testSnippetMemberAssignment() { + assertEval("java.lang.reflect.Array.get(new String[1], 0) == null"); + assertTrue(encountered, "java.lang.reflect not encountered"); + } + +} diff --git a/langtools/test/jdk/jshell/GetResourceTest.java b/langtools/test/jdk/jshell/GetResourceTest.java new file mode 100644 index 00000000000..530c89423a7 --- /dev/null +++ b/langtools/test/jdk/jshell/GetResourceTest.java @@ -0,0 +1,164 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8179531 + * @summary Check that ClassLoader.getResource works as expected in the JShell agent. + * @modules jdk.jshell + * @build KullaTesting TestingInputStream + * @run testng GetResourceTest + */ + +import jdk.jshell.Snippet; +import static jdk.jshell.Snippet.Status.OVERWRITTEN; +import static jdk.jshell.Snippet.Status.VALID; +import org.testng.annotations.Test; + + +@Test +public class GetResourceTest extends KullaTesting { + + public void checkGetResource() { + assertEval("import java.util.Arrays;"); + assertEval("boolean match(byte[] data, byte[] snippet) {\n" + + " for (int i = 0; i < data.length - snippet.length; i++) {\n" + + " if (Arrays.equals(Arrays.copyOfRange(data, i, i + snippet.length), snippet)) {\n" + + " return true;\n" + + " }\n" + + " }\n" + + " return false;\n" + + "}"); + assertEval("boolean test() throws Exception {\n" + + " Class c = new Object() {}.getClass().getEnclosingClass();\n" + + " byte[] data = c.getClassLoader().getResource(c.getName().replace('.', '/') + \".class\").openStream().readAllBytes();\n" + + " return match(data, \"check text\".getBytes(\"UTF-8\"));\n" + + "}"); + assertEval("test()", "true"); + } + + public void checkRedefine() { + assertEval("import java.util.Arrays;"); + assertEval("boolean match(byte[] data, byte[] snippet) {\n" + + " for (int i = 0; i < data.length - snippet.length; i++) {\n" + + " if (Arrays.equals(Arrays.copyOfRange(data, i, i + snippet.length), snippet)) {\n" + + " return true;\n" + + " }\n" + + " }\n" + + " return false;\n" + + "}"); + Snippet testMethod = + methodKey(assertEval("boolean test() throws Exception {\n" + + " return false;\n" + + "}")); + assertEval("boolean test() throws Exception {\n" + + " Class c = new Object() {}.getClass().getEnclosingClass();\n" + + " byte[] data = c.getClassLoader().getResource(c.getName().replace('.', '/') + \".class\").openStream().readAllBytes();\n" + + " return match(data, \"updated variant\".getBytes(\"UTF-8\"));\n" + + "}", + IGNORE_VALUE, + null, + DiagCheck.DIAG_OK, + DiagCheck.DIAG_OK, + ste(MAIN_SNIPPET, VALID, VALID, false, null), + ste(testMethod, VALID, OVERWRITTEN, false, MAIN_SNIPPET)); + assertEval("test()", "true"); + } + + public void checkResourceSize() { + assertEval("import java.net.*;"); + assertEval("boolean test() throws Exception {\n" + + " Class c = new Object() {}.getClass().getEnclosingClass();" + + " URL url = c.getClassLoader().getResource(c.getName().replace('.', '/') + \".class\");\n" + + " URLConnection connection = url.openConnection();\n" + + " connection.connect();\n" + + " return connection.getContentLength() == connection.getInputStream().readAllBytes().length;\n" + + "}"); + assertEval("test()", "true"); + } + + public void checkTimestampCheck() { + assertEval("import java.net.*;"); + assertEval("import java.time.*;"); + assertEval("import java.time.format.*;"); + assertEval("long[] times(Class c) throws Exception {\n" + + " URL url = c.getClassLoader().getResource(c.getName().replace('.', '/') + \".class\");\n" + + " URLConnection connection = url.openConnection();\n" + + " connection.connect();\n" + + " return new long[] {connection.getDate(),\n" + + " connection.getLastModified()," + + " Instant.from(DateTimeFormatter.RFC_1123_DATE_TIME.parse(connection.getHeaderField(\"last-modified\"))).toEpochMilli()};\n" + + "}"); + Snippet testMethod = + methodKey(assertEval("long[] test() throws Exception {\n" + + " int i = 0;\n" + + " return times(new Object() {}.getClass().getEnclosingClass());\n" + + "}")); + assertEval("long[] orig = test();"); + long s = System.currentTimeMillis(); + while ((System.currentTimeMillis() - s) < 1000) { //ensure time change: + try { + Thread.sleep(1000); + } catch (InterruptedException ex) {} + } + assertEval("long[] test() throws Exception {\n" + + " int i = 1;\n" + + " return times(new Object() {}.getClass().getEnclosingClass());\n" + + "}", + IGNORE_VALUE, + null, + DiagCheck.DIAG_OK, + DiagCheck.DIAG_OK, + ste(MAIN_SNIPPET, VALID, VALID, false, null), + ste(testMethod, VALID, OVERWRITTEN, false, MAIN_SNIPPET)); + assertEval("long[] nue = test();"); + assertEval("orig[0] < nue[0]", "true"); + assertEval("orig[1] < nue[1]", "true"); + assertEval("orig[0] == orig[2]", "true"); + assertEval("nue[0] == nue[2]", "true"); + } + + public void checkFieldAccess() { + assertEval("import java.net.*;"); + assertEval("Class c = new Object() {}.getClass().getEnclosingClass();"); + assertEval("URL url = c.getClassLoader().getResource(c.getName().replace('.', '/') + \".class\");"); + assertEval("URLConnection connection = url.openConnection();"); + assertEval("connection.connect();"); + assertEval("connection.getHeaderFieldKey(0)", "\"content-length\""); + assertEval("connection.getHeaderFieldKey(1)", "\"date\""); + assertEval("connection.getHeaderFieldKey(2)", "\"last-modified\""); + assertEval("connection.getHeaderFieldKey(3)", "null"); + assertEval("connection.getHeaderField(0) != null", "true"); + assertEval("connection.getHeaderField(1) != null", "true"); + assertEval("connection.getHeaderField(2) != null", "true"); + assertEval("connection.getHeaderField(3) == null", "true"); + } + + public void checkGetResources() { + assertEval("import java.net.*;"); + assertEval("Class c = new Object() {}.getClass().getEnclosingClass();"); + assertEval("c.getClassLoader().getResources(c.getName().replace('.', '/') + \".class\").hasMoreElements()", "true"); + } + +} + diff --git a/langtools/test/jdk/jshell/HangingRemoteAgent.java b/langtools/test/jdk/jshell/HangingRemoteAgent.java index 1f83b7c45c7..e64f1c25ea3 100644 --- a/langtools/test/jdk/jshell/HangingRemoteAgent.java +++ b/langtools/test/jdk/jshell/HangingRemoteAgent.java @@ -22,6 +22,8 @@ */ import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; import jdk.jshell.JShell; import jdk.jshell.execution.JdiExecutionControlProvider; import jdk.jshell.execution.RemoteExecutionControl; @@ -59,6 +61,8 @@ class HangingRemoteAgent extends RemoteExecutionControl { pm.put(JdiExecutionControlProvider.PARAM_HOST_NAME, host==null? "" : host); pm.put(JdiExecutionControlProvider.PARAM_LAUNCH, ""+isLaunch); pm.put(JdiExecutionControlProvider.PARAM_TIMEOUT, ""+TIMEOUT); + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); return JShell.builder() .executionEngine(ecp, pm) .build(); diff --git a/langtools/test/jdk/jshell/HistoryTest.java b/langtools/test/jdk/jshell/HistoryTest.java index bc0557b6245..3c167f8e2f4 100644 --- a/langtools/test/jdk/jshell/HistoryTest.java +++ b/langtools/test/jdk/jshell/HistoryTest.java @@ -33,6 +33,8 @@ import java.lang.reflect.Field; import java.util.Locale; +import java.util.logging.Level; +import java.util.logging.Logger; import jdk.internal.jline.extra.EditingHistory; import org.testng.annotations.Test; import jdk.internal.jshell.tool.JShellTool; @@ -45,6 +47,8 @@ public class HistoryTest extends ReplToolTesting { @Override protected void testRawRun(Locale locale, String[] args) { + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); repl = ((JShellToolBuilder) builder(locale)) .rawTool(); try { diff --git a/langtools/test/jdk/jshell/HistoryUITest.java b/langtools/test/jdk/jshell/HistoryUITest.java new file mode 100644 index 00000000000..528b619f7fa --- /dev/null +++ b/langtools/test/jdk/jshell/HistoryUITest.java @@ -0,0 +1,84 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8178077 + * @summary Check the UI behavior of editing history. + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * jdk.jshell/jdk.internal.jshell.tool.resources:open + * jdk.jshell/jdk.jshell:open + * @library /tools/lib + * @build toolbox.ToolBox toolbox.JarTask toolbox.JavacTask + * @build Compiler UITesting + * @build HistoryUITest + * @run testng HistoryUITest + */ + +import org.testng.annotations.Test; + +@Test +public class HistoryUITest extends UITesting { + + public void testPrevNextSnippet() throws Exception { + doRunTest((inputSink, out) -> { + inputSink.write("void test1() {\nSystem.err.println(1);\n}\n"); + waitOutput(out, "\u0005"); + inputSink.write("void test2() {\nSystem.err.println(2);\n}\n"); + waitOutput(out, "\u0005"); + inputSink.write(CTRL_UP); + waitOutput(out, "^void test2\\(\\) \\{"); + inputSink.write(CTRL_UP); + waitOutput(out, "^" + clearOut("2() {") + "1\\(\\) \\{"); + inputSink.write(CTRL_DOWN); + waitOutput(out, "^" + clearOut("1() {") + "2\\(\\) \\{"); + inputSink.write(ENTER); + waitOutput(out, "^\n\u0006"); + inputSink.write(UP); + waitOutput(out, "^}"); + inputSink.write(UP); + waitOutput(out, "^" + clearOut("}") + "System.err.println\\(2\\);"); + inputSink.write(UP); + waitOutput(out, "^" + clearOut("System.err.println(2);") + "void test2\\(\\) \\{"); + inputSink.write(UP); + waitOutput(out, "^\u0007"); + inputSink.write(DOWN); + waitOutput(out, "^" + clearOut("void test2() {") + "System.err.println\\(2\\);"); + inputSink.write(DOWN); + waitOutput(out, "^" + clearOut("System.err.println(2);") + "}"); + inputSink.write(DOWN); + waitOutput(out, "^" + clearOut("}")); + inputSink.write(DOWN); + waitOutput(out, "^\u0007"); + }); + } + //where: + private static final String CTRL_UP = "\033[1;5A"; + private static final String CTRL_DOWN = "\033[1;5B"; + private static final String UP = "\033[A"; + private static final String DOWN = "\033[B"; + private static final String ENTER = "\n"; + +} diff --git a/langtools/test/jdk/jshell/JavadocTest.java b/langtools/test/jdk/jshell/JavadocTest.java index a43ef91aa6d..184921adf9a 100644 --- a/langtools/test/jdk/jshell/JavadocTest.java +++ b/langtools/test/jdk/jshell/JavadocTest.java @@ -23,7 +23,7 @@ /* * @test - * @bug 8131019 8169561 + * @bug 8131019 8169561 8174245 * @summary Test Javadoc * @library /tools/lib * @modules jdk.compiler/com.sun.tools.javac.api @@ -107,4 +107,51 @@ public class JavadocTest extends KullaTesting { addToClasspath(compiler.getClassDir()); } + public void testCollectionsMin() { + prepareJavaUtilZip(); + assertJavadoc("java.util.Collections.min(|", + "T java.util.Collections.min(java.util.Collection coll, java.util.Comparator comp)\n" + + " min comparator\n", + "T java.util.Collections.>min(java.util.Collection coll)\n" + + " min comparable\n"); + } + + private void prepareJavaUtilZip() { + String clazz = + "package java.util;\n" + + "/**Top level." + + " */\n" + + "public class Collections {\n" + + " /**\n" + + " * min comparable\n" + + " */\n" + + " public static > T min(Collection coll) {" + + " return null;\n" + + " }\n" + + " /**\n" + + " * min comparator\n" + + " */\n" + + " public static T min(Collection coll, Comparator comp) {\n" + + " return null;\n" + + " }\n" + + "}\n"; + + Path srcZip = Paths.get("src.zip"); + + try (JarOutputStream out = new JarOutputStream(Files.newOutputStream(srcZip))) { + out.putNextEntry(new JarEntry("java/util/Collections.java")); + out.write(clazz.getBytes()); + } catch (IOException ex) { + throw new IllegalStateException(ex); + } + + try { + Field availableSources = getAnalysis().getClass().getDeclaredField("availableSources"); + availableSources.setAccessible(true); + availableSources.set(getAnalysis(), Arrays.asList(srcZip)); + } catch (NoSuchFieldException | IllegalArgumentException | IllegalAccessException ex) { + throw new IllegalStateException(ex); + } + } + } diff --git a/langtools/test/jdk/jshell/JdiBadOptionLaunchExecutionControlTest.java b/langtools/test/jdk/jshell/JdiBadOptionLaunchExecutionControlTest.java index 8c7019119d6..199964abb0b 100644 --- a/langtools/test/jdk/jshell/JdiBadOptionLaunchExecutionControlTest.java +++ b/langtools/test/jdk/jshell/JdiBadOptionLaunchExecutionControlTest.java @@ -29,6 +29,8 @@ * @run testng JdiBadOptionLaunchExecutionControlTest */ +import java.util.logging.Level; +import java.util.logging.Logger; import org.testng.annotations.Test; import jdk.jshell.JShell; import static org.testng.Assert.assertTrue; @@ -42,6 +44,8 @@ public class JdiBadOptionLaunchExecutionControlTest { public void badOptionLaunchTest() { try { + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); JShell.builder() .executionEngine("jdi:launch(true)") .remoteVMOptions("-BadBadOption") diff --git a/langtools/test/jdk/jshell/JdiBadOptionListenExecutionControlTest.java b/langtools/test/jdk/jshell/JdiBadOptionListenExecutionControlTest.java index 79213e0dbe5..bdf05c7bd7f 100644 --- a/langtools/test/jdk/jshell/JdiBadOptionListenExecutionControlTest.java +++ b/langtools/test/jdk/jshell/JdiBadOptionListenExecutionControlTest.java @@ -29,6 +29,8 @@ * @run testng JdiBadOptionListenExecutionControlTest */ +import java.util.logging.Level; +import java.util.logging.Logger; import org.testng.annotations.Test; import jdk.jshell.JShell; import static org.testng.Assert.assertTrue; @@ -38,16 +40,18 @@ import static org.testng.Assert.fail; public class JdiBadOptionListenExecutionControlTest { private static final String EXPECTED_ERROR = - "Launching JShell execution engine threw: Failed remote listen:"; + "Unrecognized option: -BadBadOption"; public void badOptionListenTest() { try { + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); JShell.builder() .executionEngine("jdi") .remoteVMOptions("-BadBadOption") .build(); } catch (IllegalStateException ex) { - assertTrue(ex.getMessage().startsWith(EXPECTED_ERROR), ex.getMessage()); + assertTrue(ex.getMessage().contains(EXPECTED_ERROR), ex.getMessage()); return; } fail("Expected IllegalStateException"); diff --git a/langtools/test/jdk/jshell/JdiBogusHostListenExecutionControlTest.java b/langtools/test/jdk/jshell/JdiBogusHostListenExecutionControlTest.java index 6ef1a9ce879..cb4de099d20 100644 --- a/langtools/test/jdk/jshell/JdiBogusHostListenExecutionControlTest.java +++ b/langtools/test/jdk/jshell/JdiBogusHostListenExecutionControlTest.java @@ -29,6 +29,8 @@ * @run testng JdiBogusHostListenExecutionControlTest */ +import java.util.logging.Level; +import java.util.logging.Logger; import org.testng.annotations.Test; import jdk.jshell.JShell; import static org.testng.Assert.assertTrue; @@ -42,6 +44,8 @@ public class JdiBogusHostListenExecutionControlTest { public void badOptionListenTest() { try { + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); JShell.builder() .executionEngine("jdi:hostname(BattyRumbleBuckets-Snurfle-99-Blip)") .build(); diff --git a/langtools/test/jdk/jshell/KullaTesting.java b/langtools/test/jdk/jshell/KullaTesting.java index 1197d0399a0..a2ea8e159b0 100644 --- a/langtools/test/jdk/jshell/KullaTesting.java +++ b/langtools/test/jdk/jshell/KullaTesting.java @@ -30,7 +30,6 @@ import java.io.StringWriter; import java.lang.reflect.Method; import java.lang.module.Configuration; import java.lang.module.ModuleFinder; -import java.lang.reflect.Layer; import java.nio.file.Paths; import java.nio.file.Path; import java.util.ArrayList; @@ -211,11 +210,11 @@ public class KullaTesting { public ClassLoader createAndRunFromModule(String moduleName, Path modPath) { ModuleFinder finder = ModuleFinder.of(modPath); - Layer parent = Layer.boot(); + ModuleLayer parent = ModuleLayer.boot(); Configuration cf = parent.configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of(moduleName)); + .resolve(finder, ModuleFinder.of(), Set.of(moduleName)); ClassLoader scl = ClassLoader.getSystemClassLoader(); - Layer layer = parent.defineModulesWithOneLoader(cf, scl); + ModuleLayer layer = parent.defineModulesWithOneLoader(cf, scl); ClassLoader loader = layer.findLoader(moduleName); ClassLoader ccl = Thread.currentThread().getContextClassLoader(); Thread.currentThread().setContextClassLoader(loader); diff --git a/langtools/test/jdk/jshell/MergedTabShiftTabCommandTest.java b/langtools/test/jdk/jshell/MergedTabShiftTabCommandTest.java new file mode 100644 index 00000000000..4a7e49f2d3f --- /dev/null +++ b/langtools/test/jdk/jshell/MergedTabShiftTabCommandTest.java @@ -0,0 +1,127 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8177076 + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * jdk.jshell/jdk.internal.jshell.tool.resources:open + * jdk.jshell/jdk.jshell:open + * @library /tools/lib + * @build toolbox.ToolBox toolbox.JarTask toolbox.JavacTask + * @build Compiler UITesting + * @build MergedTabShiftTabCommandTest + * @run testng MergedTabShiftTabCommandTest + */ + +import java.util.regex.Pattern; + +import org.testng.annotations.Test; + +@Test +public class MergedTabShiftTabCommandTest extends UITesting { + + public void testCommand() throws Exception { + // set terminal height so that help output won't hit page breaks + System.setProperty("test.terminal.height", "1000000"); + + doRunTest((inputSink, out) -> { + inputSink.write("1\n"); + waitOutput(out, "\u0005"); + inputSink.write("/\011"); + waitOutput(out, ".*/edit.*/list.*\n\n" + Pattern.quote(getResource("jshell.console.see.synopsis")) + "\n\r\u0005/"); + inputSink.write("\011"); + waitOutput(out, ".*\n/edit\n" + Pattern.quote(getResource("help.edit.summary")) + + "\n.*\n/list\n" + Pattern.quote(getResource("help.list.summary")) + + ".*\n\n" + Pattern.quote(getResource("jshell.console.see.full.documentation")) + "\n\r\u0005/"); + inputSink.write("\011"); + waitOutput(out, "/!\n" + + Pattern.quote(getResource("help.bang")) + "\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.next.command.doc")) + "\n" + + "\r\u0005/"); + inputSink.write("\011"); + waitOutput(out, "/-\n" + + Pattern.quote(getResource("help.previous")) + "\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.next.command.doc")) + "\n" + + "\r\u0005/"); + + inputSink.write("ed\011"); + waitOutput(out, "edit $"); + + inputSink.write("\011"); + waitOutput(out, ".*-all.*" + + "\n\n" + Pattern.quote(getResource("jshell.console.see.synopsis")) + "\n\r\u0005/"); + inputSink.write("\011"); + waitOutput(out, Pattern.quote(getResource("help.edit.summary")) + "\n\n" + + Pattern.quote(getResource("jshell.console.see.full.documentation")) + "\n\r\u0005/edit "); + inputSink.write("\011"); + waitOutput(out, Pattern.quote(getResource("help.edit").replaceAll("\t", " "))); + + inputSink.write("\u0003/env \011"); + waitOutput(out, "\u0005/env -\n" + + "-add-exports -add-modules -class-path -module-path \n" + + "\r\u0005/env -"); + + inputSink.write("\011"); + waitOutput(out, "-add-exports -add-modules -class-path -module-path \n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.synopsis")) + "\n" + + "\r\u0005/env -"); + + inputSink.write("\011"); + waitOutput(out, Pattern.quote(getResource("help.env.summary")) + "\n\n" + + Pattern.quote(getResource("jshell.console.see.full.documentation")) + "\n" + + "\r\u0005/env -"); + + inputSink.write("\011"); + waitOutput(out, Pattern.quote(getResource("help.env").replaceAll("\t", " ")) + "\n" + + "\r\u0005/env -"); + + inputSink.write("\011"); + waitOutput(out, "-add-exports -add-modules -class-path -module-path \n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.synopsis")) + "\n" + + "\r\u0005/env -"); + + inputSink.write("\u0003/exit \011"); + waitOutput(out, Pattern.quote(getResource("help.exit.summary")) + "\n\n" + + Pattern.quote(getResource("jshell.console.see.full.documentation")) + "\n\r\u0005/exit "); + inputSink.write("\011"); + waitOutput(out, Pattern.quote(getResource("help.exit")) + "\n" + + "\r\u0005/exit "); + inputSink.write("\011"); + waitOutput(out, Pattern.quote(getResource("help.exit.summary")) + "\n\n" + + Pattern.quote(getResource("jshell.console.see.full.documentation")) + "\n\r\u0005/exit "); + inputSink.write("\u0003/doesnotexist\011"); + waitOutput(out, "\u0005/doesnotexist\n" + + Pattern.quote(getResource("jshell.console.no.such.command")) + "\n" + + "\n" + + "\r\u0005/doesnotexist"); + }); + } + +} diff --git a/langtools/test/jdk/jshell/MergedTabShiftTabExpressionTest.java b/langtools/test/jdk/jshell/MergedTabShiftTabExpressionTest.java new file mode 100644 index 00000000000..7eaab4d5f38 --- /dev/null +++ b/langtools/test/jdk/jshell/MergedTabShiftTabExpressionTest.java @@ -0,0 +1,250 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8177076 + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * jdk.jshell/jdk.internal.jshell.tool.resources:open + * jdk.jshell/jdk.jshell:open + * @library /tools/lib + * @build toolbox.ToolBox toolbox.JarTask toolbox.JavacTask + * @build Compiler UITesting + * @build MergedTabShiftTabExpressionTest + * @run testng/timeout=300 MergedTabShiftTabExpressionTest + */ + +import java.io.IOException; +import java.lang.reflect.Field; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.Arrays; +import java.util.jar.JarEntry; +import java.util.jar.JarOutputStream; +import java.util.regex.Pattern; + +import org.testng.annotations.Test; + +@Test +public class MergedTabShiftTabExpressionTest extends UITesting { + + public void testExpression() throws Exception { + Path classes = prepareZip(); + doRunTest((inputSink, out) -> { + inputSink.write("/env -class-path " + classes.toString() + "\n"); + waitOutput(out, Pattern.quote(getResource("jshell.msg.set.restore")) + "\n\u0005"); + inputSink.write("import jshelltest.*;\n"); + waitOutput(out, "\n\u0005"); + + //-> + inputSink.write("\011"); + waitOutput(out, getMessage("jshell.console.completion.all.completions.number", "[0-9]+")); + inputSink.write("\011"); + waitOutput(out, ".*String.*StringBuilder.*\n\r\u0005"); + + //new JShellTes + inputSink.write("new JShellTes\011"); + waitOutput(out, "t\nJShellTest\\( JShellTestAux\\( \n\r\u0005new JShellTest"); + + //new JShellTest + inputSink.write("\011"); + waitOutput(out, "JShellTest\\( JShellTestAux\\( \n" + + "\n" + + Pattern.quote(getResource("jshell.console.completion.current.signatures")) + "\n" + + "jshelltest.JShellTest\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.documentation")) + "\n" + + "\r\u0005new JShellTest"); + inputSink.write("\011"); + waitOutput(out, "jshelltest.JShellTest\n" + + "JShellTest 0\n" + + "\r\u0005new JShellTest"); + inputSink.write("\011"); + waitOutput(out, "JShellTest\\( JShellTestAux\\( \n" + + "\n" + + Pattern.quote(getResource("jshell.console.completion.current.signatures")) + "\n" + + "jshelltest.JShellTest\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.documentation")) + "\n" + + "\r\u0005new JShellTest"); + + //new JShellTest( + inputSink.write("(\011"); + waitOutput(out, "\\(\n" + + Pattern.quote(getResource("jshell.console.completion.current.signatures")) + "\n" + + "JShellTest\\(String str\\)\n" + + "JShellTest\\(String str, int i\\)\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.documentation")) + "\n" + + "\r\u0005new JShellTest\\("); + inputSink.write("\011"); + waitOutput(out, "JShellTest\\(String str\\)\n" + + "JShellTest 1\n" + + "1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.next.page")) + "\n" + + "\r\u0005new JShellTest\\("); + inputSink.write("\011"); + waitOutput(out, "1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.next.javadoc")) + "\n" + + "\r\u0005new JShellTest\\("); + inputSink.write("\011"); + waitOutput(out, "JShellTest\\(String str, int i\\)\n" + + "JShellTest 2\n" + + "\n" + + getMessage("jshell.console.completion.all.completions.number", "[0-9]+") + "\n" + + "\r\u0005new JShellTest\\("); + inputSink.write("\011"); + waitOutput(out, ".*String.*StringBuilder.*\n\r\u0005new JShellTest\\("); + + inputSink.write("\u0003String str = \"\";\nnew JShellTest("); + waitOutput(out, "\u0005new JShellTest\\("); + + inputSink.write("\011"); + waitOutput(out, "\n" + + "str \n" + + "\n" + + Pattern.quote(getResource("jshell.console.completion.current.signatures")) + "\n" + + "JShellTest\\(String str\\)\n" + + "JShellTest\\(String str, int i\\)\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.documentation")) + "\n" + + "\r\u0005new JShellTest\\("); + inputSink.write("\011"); + waitOutput(out, "JShellTest\\(String str\\)\n" + + "JShellTest 1\n" + + "1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.next.page")) + "\n" + + "\r\u0005new JShellTest\\("); + inputSink.write("\011"); + waitOutput(out, "1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n1\n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.next.javadoc")) + "\n" + + "\r\u0005new JShellTest\\("); + inputSink.write("\011"); + waitOutput(out, "JShellTest\\(String str, int i\\)\n" + + "JShellTest 2\n" + + "\n" + + getMessage("jshell.console.completion.all.completions.number", "[0-9]+") + "\n" + + "\r\u0005new JShellTest\\("); + inputSink.write("\011"); + waitOutput(out, ".*String.*StringBuilder.*\n\r\u0005new JShellTest\\("); + + inputSink.write("\u0003JShellTest t = new JShellTest\011"); + waitOutput(out, "\u0005JShellTest t = new JShellTest\n" + + "JShellTest\\( \n" + + "\n" + + Pattern.quote(getResource("jshell.console.completion.current.signatures")) + "\n" + + "jshelltest.JShellTest\n" + + "\n" + + Pattern.quote(getResource("jshell.console.completion.all.completions")) + "\n" + + "\r\u0005JShellTest t = new JShellTest"); + inputSink.write("\011"); + waitOutput(out, "JShellTest\\( JShellTestAux\\( \n" + + "\n" + + Pattern.quote(getResource("jshell.console.see.documentation")) + "\n" + + "\r\u0005JShellTest t = new JShellTest"); + + inputSink.write("\u0003JShellTest t = new \011"); + waitOutput(out, "\u0005JShellTest t = new \n" + + "JShellTest\\( \n" + + "\n" + + getMessage("jshell.console.completion.all.completions.number", "[0-9]+") + "\n" + + "\r\u0005JShellTest t = new "); + inputSink.write("\011"); + waitOutput(out, ".*String.*StringBuilder.*\n\r\u0005JShellTest t = new "); + + inputSink.write("\u0003class JShelX{}\n"); + inputSink.write("new JShel\011"); + waitOutput(out, "\u0005new JShel\n" + + "JShelX\\(\\) JShellTest\\( JShellTestAux\\( \n" + + "\r\u0005new JShel"); + + //no crash: + inputSink.write("\u0003new Stringbuil\011"); + waitOutput(out, "\u0005new Stringbuil\u0007"); + }); + } + + private Path prepareZip() { + String clazz1 = + "package jshelltest;\n" + + "/**JShellTest 0" + + " */\n" + + "public class JShellTest {\n" + + " /**JShellTest 1\n" + + " *

    1

    1

    1

    1

    1

    1

    1

    1

    1

    1\n" + + " *

    1

    1

    1

    1

    1

    1

    1

    1

    1

    1\n" + + " *

    1

    1

    1

    1

    1

    1

    1

    1

    1

    1\n" + + " */\n" + + " public JShellTest(String str) {}\n" + + " /**JShellTest 2" + + " */\n" + + " public JShellTest(String str, int i) {}\n" + + "}\n"; + + String clazz2 = + "package jshelltest;\n" + + "/**JShellTestAux 0" + + " */\n" + + "public class JShellTestAux {\n" + + " /**JShellTest 1" + + " */\n" + + " public JShellTestAux(String str) { }\n" + + " /**JShellTest 2" + + " */\n" + + " public JShellTestAux(String str, int i) { }\n" + + "}\n"; + + Path srcZip = Paths.get("src.zip"); + + try (JarOutputStream out = new JarOutputStream(Files.newOutputStream(srcZip))) { + out.putNextEntry(new JarEntry("jshelltest/JShellTest.java")); + out.write(clazz1.getBytes()); + out.putNextEntry(new JarEntry("jshelltest/JShellTestAux.java")); + out.write(clazz2.getBytes()); + } catch (IOException ex) { + throw new IllegalStateException(ex); + } + + compiler.compile(clazz1, clazz2); + + try { + Field availableSources = Class.forName("jdk.jshell.SourceCodeAnalysisImpl").getDeclaredField("availableSourcesOverride"); + availableSources.setAccessible(true); + availableSources.set(null, Arrays.asList(srcZip)); + } catch (NoSuchFieldException | IllegalArgumentException | IllegalAccessException | ClassNotFoundException ex) { + throw new IllegalStateException(ex); + } + + return compiler.getClassDir(); + } + //where: + private final Compiler compiler = new Compiler(); + +} diff --git a/langtools/test/jdk/jshell/MyExecutionControl.java b/langtools/test/jdk/jshell/MyExecutionControl.java index 15b0e94f5e2..8493638db57 100644 --- a/langtools/test/jdk/jshell/MyExecutionControl.java +++ b/langtools/test/jdk/jshell/MyExecutionControl.java @@ -29,6 +29,7 @@ import java.io.OutputStream; import java.net.ServerSocket; import java.net.Socket; import java.util.ArrayList; +import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; @@ -78,7 +79,7 @@ class MyExecutionControl extends JdiExecutionControl { + System.getProperty("path.separator") + System.getProperty("user.dir")); JdiInitiator jdii = new JdiInitiator(port, - opts, REMOTE_AGENT, true, null, TIMEOUT); + opts, REMOTE_AGENT, true, null, TIMEOUT, Collections.emptyMap()); VirtualMachine vm = jdii.vm(); Process process = jdii.process(); diff --git a/langtools/test/jdk/jshell/ReplToolTesting.java b/langtools/test/jdk/jshell/ReplToolTesting.java index 3f776eebb21..f165978425f 100644 --- a/langtools/test/jdk/jshell/ReplToolTesting.java +++ b/langtools/test/jdk/jshell/ReplToolTesting.java @@ -34,6 +34,8 @@ import java.util.Map; import java.util.function.Consumer; import java.util.function.Function; import java.util.function.Predicate; +import java.util.logging.Level; +import java.util.logging.Logger; import java.util.prefs.AbstractPreferences; import java.util.prefs.BackingStoreException; import java.util.regex.Matcher; @@ -72,27 +74,27 @@ public class ReplToolTesting { final static List START_UP_CMD_METHOD = Stream.of() .collect(toList()); final static List PRINTING_CMD_METHOD = Stream.of( - "| print (boolean)void", - "| print (char)void", - "| print (int)void", - "| print (long)void", - "| print (float)void", - "| print (double)void", - "| print (char s[])void", - "| print (String)void", - "| print (Object)void", - "| println ()void", - "| println (boolean)void", - "| println (char)void", - "| println (int)void", - "| println (long)void", - "| println (float)void", - "| println (double)void", - "| println (char s[])void", - "| println (String)void", - "| println (Object)void", - "| printf (Locale,String,Object...)void", - "| printf (String,Object...)void") + "| void print(boolean)", + "| void print(char)", + "| void print(int)", + "| void print(long)", + "| void print(float)", + "| void print(double)", + "| void print(char s[])", + "| void print(String)", + "| void print(Object)", + "| void println()", + "| void println(boolean)", + "| void println(char)", + "| void println(int)", + "| void println(long)", + "| void println(float)", + "| void println(double)", + "| void println(char s[])", + "| void println(String)", + "| void println(Object)", + "| void printf(java.util.Locale,String,Object...)", + "| void printf(String,Object...)") .collect(toList()); final static List START_UP = Collections.unmodifiableList( Stream.concat(START_UP_IMPORTS.stream(), START_UP_METHODS.stream()) @@ -152,6 +154,7 @@ public class ReplToolTesting { return s -> { List lines = Stream.of(s.split("\n")) .filter(l -> !l.isEmpty()) + .filter(l -> !l.startsWith("| ")) // error/unresolved info .collect(Collectors.toList()); assertEquals(lines.size(), set.size(), message + " : expected: " + set.keySet() + "\ngot:\n" + lines); for (String line : lines) { @@ -264,6 +267,8 @@ public class ReplToolTesting { } protected JavaShellToolBuilder builder(Locale locale) { + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); return JavaShellToolBuilder .builder() .in(cmdin, userin) @@ -664,7 +669,12 @@ public class ReplToolTesting { @Override public String toString() { - return String.format("%s %s", name, signature); + int i = signature.lastIndexOf(")") + 1; + if (i <= 0) { + return String.format("%s", name); + } else { + return String.format("%s %s%s", signature.substring(i), name, signature.substring(0, i)); + } } } diff --git a/langtools/test/jdk/jshell/StartOptionTest.java b/langtools/test/jdk/jshell/StartOptionTest.java index 2429a734446..0ea35afa9d9 100644 --- a/langtools/test/jdk/jshell/StartOptionTest.java +++ b/langtools/test/jdk/jshell/StartOptionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,7 +22,7 @@ */ /* - * @test 8151754 8080883 8160089 8170162 8166581 8172102 8171343 + * @test 8151754 8080883 8160089 8170162 8166581 8172102 8171343 8178023 * @summary Testing start-up options. * @modules jdk.compiler/com.sun.tools.javac.api * jdk.compiler/com.sun.tools.javac.main @@ -43,6 +43,8 @@ import java.util.HashMap; import java.util.Locale; import java.util.function.Consumer; +import java.util.logging.Level; +import java.util.logging.Logger; import org.testng.annotations.AfterMethod; import org.testng.annotations.BeforeMethod; import org.testng.annotations.Test; @@ -63,6 +65,8 @@ public class StartOptionTest { private InputStream cmdInStream; private JavaShellToolBuilder builder() { + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); return JavaShellToolBuilder .builder() .out(new PrintStream(cmdout), new PrintStream(console), new PrintStream(userout)) @@ -179,14 +183,11 @@ public class StartOptionTest { } public void testStartupFailedOption() throws Exception { - try { - builder().run("-R-hoge-foo-bar"); - } catch (IllegalStateException ex) { - String s = ex.getMessage(); - assertTrue(s.startsWith("Launching JShell execution engine threw: Failed remote"), s); - return; - } - fail("Expected IllegalStateException"); + start( + s -> assertEquals(s.trim(), "", "cmdout: "), + s -> assertEquals(s.trim(), "", "userout: "), + s -> assertTrue(s.contains("Unrecognized option: -hoge-foo-bar"), "cmderr: " + s), + "-R-hoge-foo-bar"); } public void testStartupUnknown() throws Exception { @@ -201,6 +202,14 @@ public class StartOptionTest { } } + public void testUnknownModule() throws Exception { + start( + s -> assertEquals(s.trim(), "", "cmdout: "), + s -> assertEquals(s.trim(), "", "userout: "), + s -> assertTrue(s.contains("rror") && s.contains("unKnown"), "cmderr: " + s), + "--add-modules", "unKnown"); + } + public void testFeedbackOptionConflict() throws Exception { start("", "Only one feedback option (--feedback, -q, -s, or -v) may be used.", "--feedback", "concise", "--feedback", "verbose"); diff --git a/langtools/test/jdk/jshell/ToolBasicTest.java b/langtools/test/jdk/jshell/ToolBasicTest.java index 389b3b5a89b..be5bce056c8 100644 --- a/langtools/test/jdk/jshell/ToolBasicTest.java +++ b/langtools/test/jdk/jshell/ToolBasicTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8143037 8142447 8144095 8140265 8144906 8146138 8147887 8147886 8148316 8148317 8143955 8157953 8080347 8154714 8166649 8167643 8170162 8172102 8165405 + * @bug 8143037 8142447 8144095 8140265 8144906 8146138 8147887 8147886 8148316 8148317 8143955 8157953 8080347 8154714 8166649 8167643 8170162 8172102 8165405 8174796 8174797 8175304 8167554 8180508 * @summary Tests for Basic tests for REPL tool * @modules jdk.compiler/com.sun.tools.javac.api * jdk.compiler/com.sun.tools.javac.main @@ -35,6 +35,7 @@ * @run testng/timeout=600 ToolBasicTest */ +import java.io.File; import java.io.IOException; import java.io.PrintWriter; import java.io.StringWriter; @@ -189,8 +190,8 @@ public class ToolBasicTest extends ReplToolTesting { public void testRerun() { test(false, new String[] {"--no-startup"}, - (a) -> assertCommand(a, "/0", "| No such command or snippet id: /0\n| Type /help for help."), - (a) -> assertCommand(a, "/5", "| No such command or snippet id: /5\n| Type /help for help.") + (a) -> assertCommand(a, "/0", "| No snippet with id: 0"), + (a) -> assertCommand(a, "/5", "| No snippet with id: 5") ); String[] codes = new String[] { "int a = 0;", // var @@ -251,9 +252,9 @@ public class ToolBasicTest extends ReplToolTesting { ); test(false, new String[] {"--no-startup"}, - (a) -> assertCommand(a, "/s1", "| No such command or snippet id: /s1\n| Type /help for help."), - (a) -> assertCommand(a, "/1", "| No such command or snippet id: /1\n| Type /help for help."), - (a) -> assertCommand(a, "/e1", "| No such command or snippet id: /e1\n| Type /help for help.") + (a) -> assertCommand(a, "/s1", "| No snippet with id: s1"), + (a) -> assertCommand(a, "/1", "| No snippet with id: 1"), + (a) -> assertCommand(a, "/e1", "| No snippet with id: e1") ); } @@ -272,23 +273,84 @@ public class ToolBasicTest extends ReplToolTesting { ); } - public void testClasspathJar() { + public void testEnvInStartUp() { + Compiler compiler = new Compiler(); + Path outDir = Paths.get("testClasspathDirectory"); + compiler.compile(outDir, "package pkg; public class A { public String toString() { return \"A\"; } }"); + Path classpath = compiler.getPath(outDir); + Path sup = compiler.getPath("startup.jsh"); + compiler.writeToFile(sup, + "int xxx;\n" + + "/env -class-path " + classpath + "\n" + + "int aaa = 735;\n" + ); + test( + (a) -> assertCommand(a, "/set start -retain " + sup, ""), + (a) -> assertCommand(a, "/reset", + "| Resetting state."), + (a) -> evaluateExpression(a, "pkg.A", "new pkg.A();", "A"), + (a) -> assertCommand(a, "aaa", "aaa ==> 735") + ); + test( + (a) -> assertCommandOutputContains(a, "/env", "--class-path"), + (a) -> assertCommandOutputContains(a, "xxx", "cannot find symbol", "variable xxx"), + (a) -> evaluateExpression(a, "pkg.A", "new pkg.A();", "A"), + (a) -> assertCommand(a, "aaa", "aaa ==> 735") + ); + } + + private String makeSimpleJar() { Compiler compiler = new Compiler(); Path outDir = Paths.get("testClasspathJar"); compiler.compile(outDir, "package pkg; public class A { public String toString() { return \"A\"; } }"); String jarName = "test.jar"; compiler.jar(outDir, jarName, "pkg/A.class"); - Path jarPath = compiler.getPath(outDir).resolve(jarName); + return compiler.getPath(outDir).resolve(jarName).toString(); + } + + public void testClasspathJar() { + String jarPath = makeSimpleJar(); test( (a) -> assertCommand(a, "/env --class-path " + jarPath, "| Setting new options and restoring state."), (a) -> evaluateExpression(a, "pkg.A", "new pkg.A();", "A") ); - test(new String[] { "--class-path", jarPath.toString() }, + test(new String[] { "--class-path", jarPath }, (a) -> evaluateExpression(a, "pkg.A", "new pkg.A();", "A") ); } + public void testClasspathUserHomeExpansion() { + String jarPath = makeSimpleJar(); + String tilde = "~" + File.separator; + test( + (a) -> assertCommand(a, "/env --class-path " + tilde + "forblato", + "| File '" + System.getProperty("user.home") + File.separator + + "forblato' for '--class-path' is not found."), + (a) -> assertCommand(a, "/env --class-path " + jarPath + File.pathSeparator + + tilde + "forblato", + "| File '" + System.getProperty("user.home") + File.separator + + "forblato' for '--class-path' is not found.") + ); + } + + public void testBadClasspath() { + String jarPath = makeSimpleJar(); + Compiler compiler = new Compiler(); + Path t1 = compiler.getPath("whatever/thing.zip"); + compiler.writeToFile(t1, ""); + Path t2 = compiler.getPath("whatever/thing.jmod"); + compiler.writeToFile(t2, ""); + test( + (a) -> assertCommand(a, "/env --class-path " + t1.toString(), + "| Invalid '--class-path' argument: " + t1.toString()), + (a) -> assertCommand(a, "/env --class-path " + jarPath + File.pathSeparator + t1.toString(), + "| Invalid '--class-path' argument: " + t1.toString()), + (a) -> assertCommand(a, "/env --class-path " + t2.toString(), + "| Invalid '--class-path' argument: " + t2.toString()) + ); + } + public void testModulePath() { Compiler compiler = new Compiler(); Path modsDir = Paths.get("mods"); @@ -304,6 +366,25 @@ public class ToolBasicTest extends ReplToolTesting { ); } + public void testModulePathUserHomeExpansion() { + String tilde = "~" + File.separatorChar; + test( + (a) -> assertCommand(a, "/env --module-path " + tilde + "snardugol", + "| File '" + System.getProperty("user.home") + + File.separatorChar + "snardugol' for '--module-path' is not found.") + ); + } + + public void testBadModulePath() { + Compiler compiler = new Compiler(); + Path t1 = compiler.getPath("whatever/thing.zip"); + compiler.writeToFile(t1, ""); + test( + (a) -> assertCommand(a, "/env --module-path " + t1.toString(), + "| Invalid '--module-path' argument: " + t1.toString()) + ); + } + public void testStartupFileOption() { Compiler compiler = new Compiler(); Path startup = compiler.getPath("StartupFileOption/startup.txt"); @@ -400,17 +481,19 @@ public class ToolBasicTest extends ReplToolTesting { public void testSave() throws IOException { Compiler compiler = new Compiler(); Path path = compiler.getPath("testSave.repl"); - List list = Arrays.asList( - "int a;", - "class A { public String toString() { return \"A\"; } }" - ); - test( - (a) -> assertVariable(a, "int", "a"), - (a) -> assertCommand(a, "()", null, null, null, "", ""), - (a) -> assertClass(a, "class A { public String toString() { return \"A\"; } }", "class", "A"), - (a) -> assertCommand(a, "/save " + path.toString(), "") - ); - assertEquals(Files.readAllLines(path), list); + { + List list = Arrays.asList( + "int a;", + "class A { public String toString() { return \"A\"; } }" + ); + test( + (a) -> assertVariable(a, "int", "a"), + (a) -> assertCommand(a, "()", null, null, null, "", ""), + (a) -> assertClass(a, "class A { public String toString() { return \"A\"; } }", "class", "A"), + (a) -> assertCommand(a, "/save " + path.toString(), "") + ); + assertEquals(Files.readAllLines(path), list); + } { List output = new ArrayList<>(); test( @@ -418,28 +501,47 @@ public class ToolBasicTest extends ReplToolTesting { (a) -> assertCommand(a, "()", null, null, null, "", ""), (a) -> assertClass(a, "class A { public String toString() { return \"A\"; } }", "class", "A"), (a) -> assertCommandCheckOutput(a, "/list -all", (out) -> - output.addAll(Stream.of(out.split("\n")) - .filter(str -> !str.isEmpty()) - .map(str -> str.substring(str.indexOf(':') + 2)) - .filter(str -> !str.startsWith("/")) - .collect(Collectors.toList()))), + output.addAll(Stream.of(out.split("\n")) + .filter(str -> !str.isEmpty()) + .map(str -> str.substring(str.indexOf(':') + 2)) + .filter(str -> !str.startsWith("/")) + .collect(Collectors.toList()))), (a) -> assertCommand(a, "/save -all " + path.toString(), "") ); assertEquals(Files.readAllLines(path), output); } - List output = new ArrayList<>(); - test( - (a) -> assertVariable(a, "int", "a"), - (a) -> assertCommand(a, "()", null, null, null, "", ""), - (a) -> assertClass(a, "class A { public String toString() { return \"A\"; } }", "class", "A"), - (a) -> assertCommandCheckOutput(a, "/history", (out) -> - output.addAll(Stream.of(out.split("\n")) - .filter(str -> !str.isEmpty()) - .collect(Collectors.toList()))), - (a) -> assertCommand(a, "/save -history " + path.toString(), "") - ); - output.add("/save -history " + path.toString()); - assertEquals(Files.readAllLines(path), output); + { + List output = new ArrayList<>(); + test( + (a) -> assertCommand(a, "int a;", null), + (a) -> assertCommand(a, "int b;", null), + (a) -> assertCommand(a, "int c;", null), + (a) -> assertClass(a, "class A { public String toString() { return \"A\"; } }", "class", "A"), + (a) -> assertCommandCheckOutput(a, "/list b c a A", (out) -> + output.addAll(Stream.of(out.split("\n")) + .filter(str -> !str.isEmpty()) + .map(str -> str.substring(str.indexOf(':') + 2)) + .filter(str -> !str.startsWith("/")) + .collect(Collectors.toList()))), + (a) -> assertCommand(a, "/save 2-3 1 4 " + path.toString(), "") + ); + assertEquals(Files.readAllLines(path), output); + } + { + List output = new ArrayList<>(); + test( + (a) -> assertVariable(a, "int", "a"), + (a) -> assertCommand(a, "()", null, null, null, "", ""), + (a) -> assertClass(a, "class A { public String toString() { return \"A\"; } }", "class", "A"), + (a) -> assertCommandCheckOutput(a, "/history", (out) -> + output.addAll(Stream.of(out.split("\n")) + .filter(str -> !str.isEmpty()) + .collect(Collectors.toList()))), + (a) -> assertCommand(a, "/save -history " + path.toString(), "") + ); + output.add("/save -history " + path.toString()); + assertEquals(Files.readAllLines(path), output); + } } public void testStartRetain() { @@ -571,6 +673,64 @@ public class ToolBasicTest extends ReplToolTesting { ); } + public void testRerunIdRange() { + Compiler compiler = new Compiler(); + Path startup = compiler.getPath("rangeStartup"); + String[] startupSources = new String[] { + "boolean go = false", + "void println(String s) { if (go) System.out.println(s); }", + "void println(int i) { if (go) System.out.println(i); }", + "println(\"s4\")", + "println(\"s5\")", + "println(\"s6\")" + }; + String[] sources = new String[] { + "frog", + "go = true", + "println(2)", + "println(3)", + "println(4)", + "querty" + }; + compiler.writeToFile(startup, startupSources); + test(false, new String[]{"--startup", startup.toString()}, + a -> assertCommandOutputStartsWith(a, sources[0], "| Error:"), + a -> assertCommand(a, sources[1], "go ==> true", "", null, "", ""), + a -> assertCommand(a, sources[2], "", "", null, "2\n", ""), + a -> assertCommand(a, sources[3], "", "", null, "3\n", ""), + a -> assertCommand(a, sources[4], "", "", null, "4\n", ""), + a -> assertCommandOutputStartsWith(a, sources[5], "| Error:"), + a -> assertCommand(a, "/3", "println(3)", "", null, "3\n", ""), + a -> assertCommand(a, "/s4", "println(\"s4\")", "", null, "s4\n", ""), + a -> assertCommandOutputStartsWith(a, "/e1", "frog\n| Error:"), + a -> assertCommand(a, "/2-4", + "println(2)\nprintln(3)\nprintln(4)", + "", null, "2\n3\n4\n", ""), + a -> assertCommand(a, "/s4-s6", + startupSources[3] + "\n" +startupSources[4] + "\n" +startupSources[5], + "", null, "s4\ns5\ns6\n", ""), + a -> assertCommand(a, "/s4-4", null, + "", null, "s4\ns5\ns6\n2\n3\n4\n", ""), + a -> assertCommandCheckOutput(a, "/e1-e2", + s -> { + assertTrue(s.trim().startsWith("frog\n| Error:"), + "Output: \'" + s + "' does not start with: " + "| Error:"); + assertTrue(s.trim().lastIndexOf("| Error:") > 10, + "Output: \'" + s + "' does not have second: " + "| Error:"); + }), + a -> assertCommand(a, "/4 s4 2", + "println(4)\nprintln(\"s4\")\nprintln(2)", + "", null, "4\ns4\n2\n", ""), + a -> assertCommand(a, "/s5 2-4 3", + "println(\"s5\")\nprintln(2)\nprintln(3)\nprintln(4)\nprintln(3)", + "", null, "s5\n2\n3\n4\n3\n", ""), + a -> assertCommand(a, "/2 ff", "| No such snippet: ff"), + a -> assertCommand(a, "/4-2", "| End of snippet range less than start: 4 - 2"), + a -> assertCommand(a, "/s5-s3", "| End of snippet range less than start: s5 - s3"), + a -> assertCommand(a, "/4-s5", "| End of snippet range less than start: 4 - s5") + ); + } + @Test(enabled = false) // TODO 8158197 public void testHeadlessEditPad() { String prevHeadless = System.getProperty("java.awt.headless"); diff --git a/langtools/test/jdk/jshell/ToolLocaleMessageTest.java b/langtools/test/jdk/jshell/ToolLocaleMessageTest.java index dc45091a0c0..6111320f1af 100644 --- a/langtools/test/jdk/jshell/ToolLocaleMessageTest.java +++ b/langtools/test/jdk/jshell/ToolLocaleMessageTest.java @@ -117,7 +117,6 @@ public class ToolLocaleMessageTest extends ReplToolTesting { (a) -> assertCommandFail(a, "/drop rats"), (a) -> assertCommandOK(a, "void dup() {}"), (a) -> assertCommandOK(a, "int dup"), - (a) -> assertCommandFail(a, "/drop dup"), (a) -> assertCommandFail(a, "/edit zebra", "zebra"), (a) -> assertCommandFail(a, "/list zebra", "zebra", "No such snippet: zebra"), (a) -> assertCommandFail(a, "/open", "/open"), diff --git a/langtools/test/jdk/jshell/ToolProviderTest.java b/langtools/test/jdk/jshell/ToolProviderTest.java index 1de4d459546..9a1b010db39 100644 --- a/langtools/test/jdk/jshell/ToolProviderTest.java +++ b/langtools/test/jdk/jshell/ToolProviderTest.java @@ -86,15 +86,6 @@ public class ToolProviderTest extends StartOptionTest { start("1 : String str = \"Hello \";" + "\n" + "Hello Hello", "", "--no-startup", fn, "-s"); } - @Override - public void testStartupFailedOption() throws Exception { - if (runShellServiceLoader("-R-hoge-foo-bar") == 0) { - fail("Expected tool failure"); - } else { - check(cmderr, s -> s.startsWith("Launching JShell execution engine threw: Failed remote"), "cmderr"); - } - } - @Override public void testShowVersion() throws Exception { start( diff --git a/langtools/test/jdk/jshell/ToolReloadTest.java b/langtools/test/jdk/jshell/ToolReloadTest.java index 770b0170542..13d583e51f5 100644 --- a/langtools/test/jdk/jshell/ToolReloadTest.java +++ b/langtools/test/jdk/jshell/ToolReloadTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,7 @@ /* * @test * @key intermittent - * @bug 8081845 8147898 8143955 8165405 + * @bug 8081845 8147898 8143955 8165405 8178023 * @summary Tests for /reload in JShell tool * @modules jdk.compiler/com.sun.tools.javac.api * jdk.compiler/com.sun.tools.javac.main @@ -40,6 +40,7 @@ import java.nio.file.Paths; import java.util.function.Function; import org.testng.annotations.Test; +import static org.testng.Assert.assertTrue; @Test @@ -92,8 +93,8 @@ public class ToolReloadTest extends ReplToolTesting { test(false, new String[]{"--no-startup"}, a -> assertVariable(a, "int", "a"), a -> dropVariable(a, "/dr 1", "int a = 0", "| dropped variable a"), - a -> assertMethod(a, "int b() { return 0; }", "()I", "b"), - a -> dropMethod(a, "/drop b", "b ()I", "| dropped method b()"), + a -> assertMethod(a, "int b() { return 0; }", "()int", "b"), + a -> dropMethod(a, "/drop b", "int b()", "| dropped method b()"), a -> assertClass(a, "class A {}", "class", "A"), a -> dropClass(a, "/dr A", "class A", "| dropped class A"), a -> assertCommand(a, "/reload", @@ -115,8 +116,8 @@ public class ToolReloadTest extends ReplToolTesting { test(false, new String[]{"--no-startup"}, a -> assertVariable(a, "int", "a"), a -> dropVariable(a, "/dr 1", "int a = 0", "| dropped variable a"), - a -> assertMethod(a, "int b() { return 0; }", "()I", "b"), - a -> dropMethod(a, "/drop b", "b ()I", "| dropped method b()"), + a -> assertMethod(a, "int b() { return 0; }", "()int", "b"), + a -> dropMethod(a, "/drop b", "int b()", "| dropped method b()"), a -> assertClass(a, "class A {}", "class", "A"), a -> dropClass(a, "/dr A", "class A", "| dropped class A"), a -> assertCommand(a, "/reload -quiet", @@ -199,6 +200,27 @@ public class ToolReloadTest extends ReplToolTesting { ); } + public void testEnvBadModule() { + test( + (a) -> assertVariable(a, "int", "x", "5", "5"), + (a) -> assertMethod(a, "int m(int z) { return z * z; }", + "(int)int", "m"), + (a) -> assertCommandCheckOutput(a, "/env --add-module unKnown", + s -> { + assertTrue(s.startsWith( + "| Setting new options and restoring state.\n" + + "| Restart failed:")); + assertTrue(s.contains("unKnown"), + "\"unKnown\" missing from: " + s); + assertTrue(s.contains("previous settings"), + "\"previous settings\" missing from: " + s); + }), + (a) -> evaluateExpression(a, "int", "m(x)", "25"), + (a) -> assertCommandCheckOutput(a, "/vars", assertVariables()), + (a) -> assertCommandCheckOutput(a, "/methods", assertMethods()) + ); + } + public void testReloadExitRestore() { test(false, new String[]{"--no-startup"}, (a) -> assertVariable(a, "int", "x", "5", "5"), diff --git a/langtools/test/jdk/jshell/ToolSimpleTest.java b/langtools/test/jdk/jshell/ToolSimpleTest.java index ff29a47a92f..647d0fdafcc 100644 --- a/langtools/test/jdk/jshell/ToolSimpleTest.java +++ b/langtools/test/jdk/jshell/ToolSimpleTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8153716 8143955 8151754 8150382 8153920 8156910 8131024 8160089 8153897 8167128 8154513 8170015 8170368 8172102 8172103 8165405 8173073 8173848 + * @bug 8153716 8143955 8151754 8150382 8153920 8156910 8131024 8160089 8153897 8167128 8154513 8170015 8170368 8172102 8172103 8165405 8173073 8173848 8174041 8173916 8174028 8174262 8174797 8177079 8180508 * @summary Simple jshell tool tests * @modules jdk.compiler/com.sun.tools.javac.api * jdk.compiler/com.sun.tools.javac.main @@ -37,6 +37,7 @@ import java.util.ArrayList; import java.util.List; import java.util.Locale; import java.util.function.Consumer; +import java.util.regex.Pattern; import java.util.stream.Collectors; import java.util.stream.Stream; @@ -202,7 +203,7 @@ public class ToolSimpleTest extends ReplToolTesting { @Test public void testUnknownCommand() { test((a) -> assertCommand(a, "/unknown", - "| No such command or snippet id: /unknown\n" + + "| Invalid command: /unknown\n" + "| Type /help for help.")); } @@ -211,6 +212,14 @@ public class ToolSimpleTest extends ReplToolTesting { test(after -> assertCommand(after, "/env --class-path", "| Argument to class-path missing.")); } + @Test + public void testInvalidClassPath() { + test( + a -> assertCommand(a, "/env --class-path snurgefusal", + "| File 'snurgefusal' for '--class-path' is not found.") + ); + } + @Test public void testNoArgument() { test( @@ -238,8 +247,8 @@ public class ToolSimpleTest extends ReplToolTesting { test(false, new String[]{"--no-startup"}, a -> assertVariable(a, "int", "a"), a -> dropVariable(a, "/drop 1", "int a = 0", "| dropped variable a"), - a -> assertMethod(a, "int b() { return 0; }", "()I", "b"), - a -> dropMethod(a, "/drop 2", "b ()I", "| dropped method b()"), + a -> assertMethod(a, "int b() { return 0; }", "()int", "b"), + a -> dropMethod(a, "/drop 2", "int b()", "| dropped method b()"), a -> assertClass(a, "class A {}", "class", "A"), a -> dropClass(a, "/drop 3", "class A", "| dropped class A"), a -> assertImport(a, "import java.util.stream.*;", "", "java.util.stream.*"), @@ -255,8 +264,8 @@ public class ToolSimpleTest extends ReplToolTesting { test(false, new String[]{"--no-startup"}, a -> assertVariable(a, "int", "a"), a -> dropVariable(a, "/drop a", "int a = 0", "| dropped variable a"), - a -> assertMethod(a, "int b() { return 0; }", "()I", "b"), - a -> dropMethod(a, "/drop b", "b ()I", "| dropped method b()"), + a -> assertMethod(a, "int b() { return 0; }", "()int", "b"), + a -> dropMethod(a, "/drop b", "int b()", "| dropped method b()"), a -> assertClass(a, "class A {}", "class", "A"), a -> dropClass(a, "/drop A", "class A", "| dropped class A"), a -> assertCommandCheckOutput(a, "/vars", assertVariables()), @@ -266,10 +275,26 @@ public class ToolSimpleTest extends ReplToolTesting { ); } + @Test + public void testDropRange() { + test(false, new String[]{"--no-startup"}, + a -> assertVariable(a, "int", "a"), + a -> assertMethod(a, "int b() { return 0; }", "()int", "b"), + a -> assertClass(a, "class A {}", "class", "A"), + a -> assertImport(a, "import java.util.stream.*;", "", "java.util.stream.*"), + a -> assertCommand(a, "for (int i = 0; i < 10; ++i) {}", ""), + a -> assertCommand(a, "/drop 3-5 b 1", + "| dropped class A\n" + + "| dropped method b()\n" + + "| dropped variable a\n"), + a -> assertCommand(a, "/list", "") + ); + } + @Test public void testDropNegative() { test(false, new String[]{"--no-startup"}, - a -> assertCommandOutputStartsWith(a, "/drop 0", "| No such snippet: 0"), + a -> assertCommandOutputStartsWith(a, "/drop 0", "| No snippet with id: 0"), a -> assertCommandOutputStartsWith(a, "/drop a", "| No such snippet: a"), a -> assertCommandCheckOutput(a, "/drop", assertStartsWith("| In the /drop argument, please specify an import, variable, method, or class to drop.")), @@ -284,27 +309,23 @@ public class ToolSimpleTest extends ReplToolTesting { @Test public void testAmbiguousDrop() { - Consumer check = s -> { - assertTrue(s.startsWith("| The argument references more than one import, variable, method, or class"), s); - int lines = s.split("\n").length; - assertEquals(lines, 5, "Expected 3 ambiguous keys, but found: " + (lines - 2) + "\n" + s); - }; test( a -> assertVariable(a, "int", "a"), a -> assertMethod(a, "int a() { return 0; }", "()int", "a"), a -> assertClass(a, "class a {}", "class", "a"), - a -> assertCommandCheckOutput(a, "/drop a", check), - a -> assertCommandCheckOutput(a, "/vars", assertVariables()), - a -> assertCommandCheckOutput(a, "/methods", assertMethods()), - a -> assertCommandCheckOutput(a, "/types", assertClasses()), - a -> assertCommandCheckOutput(a, "/imports", assertImports()) + a -> assertCommand(a, "/drop a", + "| dropped variable a\n" + + "| dropped method a()\n" + + "| dropped class a") ); test( a -> assertMethod(a, "int a() { return 0; }", "()int", "a"), a -> assertMethod(a, "double a(int a) { return 0; }", "(int)double", "a"), a -> assertMethod(a, "double a(double a) { return 0; }", "(double)double", "a"), - a -> assertCommandCheckOutput(a, "/drop a", check), - a -> assertCommandCheckOutput(a, "/methods", assertMethods()) + a -> assertCommand(a, "/drop a", + "| dropped method a()\n" + + "| dropped method a(int)\n" + + "| dropped method a(double)\n") ); } @@ -342,7 +363,9 @@ public class ToolSimpleTest extends ReplToolTesting { (a) -> assertHelp(a, "/help short", "shortcuts", ""), (a) -> assertHelp(a, "/? /li", "/list -all", "snippets"), (a) -> assertHelp(a, "/help /set prompt", "optionally contain '%s'", "quoted"), - (a) -> assertHelp(a, "/help /help", "/help ") + (a) -> assertHelp(a, "/help /help", "/help "), + (a) -> assertHelp(a, "/help li", "/list -start"), + (a) -> assertHelp(a, "/help fe", "/set feedback -retain") ); } @@ -392,12 +415,14 @@ public class ToolSimpleTest extends ReplToolTesting { String arg = "qqqq"; List startVarList = new ArrayList<>(START_UP); startVarList.add("int aardvark"); + startVarList.add("int weevil"); test( a -> assertCommandCheckOutput(a, "/list -all", s -> checkLineToList(s, START_UP)), a -> assertCommandOutputStartsWith(a, "/list " + arg, "| No such snippet: " + arg), a -> assertVariable(a, "int", "aardvark"), + a -> assertVariable(a, "int", "weevil"), a -> assertCommandOutputContains(a, "/list aardvark", "aardvark"), a -> assertCommandCheckOutput(a, "/list -start", s -> checkLineToList(s, START_UP)), @@ -405,6 +430,11 @@ public class ToolSimpleTest extends ReplToolTesting { s -> checkLineToList(s, startVarList)), a -> assertCommandOutputStartsWith(a, "/list s3", "s3 : import"), + a -> assertCommandCheckOutput(a, "/list 1-2 s3", + s -> { + assertTrue(Pattern.matches(".*aardvark.*\\R.*weevil.*\\R.*s3.*import.*", s.trim()), + "No match: " + s); + }), a -> assertCommandOutputStartsWith(a, "/list " + arg, "| No such snippet: " + arg) ); @@ -429,6 +459,8 @@ public class ToolSimpleTest extends ReplToolTesting { s -> checkLineToList(s, startVarList)), a -> assertCommandOutputStartsWith(a, "/vars -all", "| int aardvark = 0\n| int a = "), + a -> assertCommandOutputStartsWith(a, "/vars 1-4", + "| int aardvark = 0\n| int a = "), a -> assertCommandOutputStartsWith(a, "/vars f", "| This command does not accept the snippet 'f'"), a -> assertCommand(a, "/var " + arg, @@ -466,10 +498,50 @@ public class ToolSimpleTest extends ReplToolTesting { a -> assertCommandCheckOutput(a, "/methods print println printf", s -> checkLineToList(s, printingMethodList)), a -> assertCommandOutputStartsWith(a, "/methods g", - "| g ()void"), + "| void g()"), a -> assertCommandOutputStartsWith(a, "/methods f", - "| f ()int\n" + - "| f (int)void") + "| int f()\n" + + "| void f(int)") + ); + } + + @Test + public void testMethodsWithErrors() { + test(new String[]{"--no-startup"}, + a -> assertCommand(a, "double m(int x) { return x; }", + "| created method m(int)"), + a -> assertCommand(a, "GARBAGE junk() { return TRASH; }", + "| created method junk(), however, it cannot be referenced until class GARBAGE, and variable TRASH are declared"), + a -> assertCommand(a, "int w = 5;", + "w ==> 5"), + a -> assertCommand(a, "int tyer() { return w; }", + "| created method tyer()"), + a -> assertCommand(a, "String w = \"hi\";", + "w ==> \"hi\""), + a -> assertCommand(a, "/methods", + "| double m(int)\n" + + "| GARBAGE junk()\n" + + "| which cannot be referenced until class GARBAGE, and variable TRASH are declared\n" + + "| int tyer()\n" + + "| which cannot be invoked until this error is corrected: \n" + + "| incompatible types: java.lang.String cannot be converted to int\n" + + "| int tyer() { return w; }\n" + + "| ^\n") + ); + } + + @Test + public void testTypesWithErrors() { + test(new String[]{"--no-startup"}, + a -> assertCommand(a, "class C extends NONE { int x; }", + "| created class C, however, it cannot be referenced until class NONE is declared"), + a -> assertCommand(a, "class D { void m() { System.out.println(nada); } }", + "| created class D, however, it cannot be instantiated or its methods invoked until variable nada is declared"), + a -> assertCommand(a, "/types", + "| class C\n" + + "| which cannot be referenced until class NONE is declared\n" + + "| class D\n" + + "| which cannot be instantiated or its methods invoked until variable nada is declared\n") ); } diff --git a/langtools/test/jdk/jshell/UITesting.java b/langtools/test/jdk/jshell/UITesting.java new file mode 100644 index 00000000000..0fb5017a7ec --- /dev/null +++ b/langtools/test/jdk/jshell/UITesting.java @@ -0,0 +1,300 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.io.IOException; +import java.io.InputStream; +import java.io.OutputStream; +import java.io.OutputStreamWriter; +import java.io.PrintStream; +import java.io.Writer; +import java.text.MessageFormat; +import java.util.HashMap; +import java.util.Locale; +import java.util.ResourceBundle; +import java.util.logging.Level; +import java.util.logging.Logger; +import java.util.regex.Matcher; +import java.util.regex.Pattern; + +import jdk.jshell.JShell; +import jdk.jshell.tool.JavaShellToolBuilder; + +public class UITesting { + + protected void doRunTest(Test test) throws Exception { + // turn on logging of launch failures + Logger.getLogger("jdk.jshell.execution").setLevel(Level.ALL); + + PipeInputStream input = new PipeInputStream(); + StringBuilder out = new StringBuilder(); + PrintStream outS = new PrintStream(new OutputStream() { + @Override public void write(int b) throws IOException { + synchronized (out) { + System.out.print((char) b); + out.append((char) b); + out.notifyAll(); + } + } + @Override public void write(byte[] b, int off, int len) throws IOException { + synchronized (out) { + String data = new String(b, off, len); + System.out.print(data); + out.append(data); + out.notifyAll(); + } + } + }); + Thread runner = new Thread(() -> { + try { + JavaShellToolBuilder.builder() + .in(input, input) + .out(outS) + .err(outS) + .promptCapture(true) + .persistence(new HashMap<>()) + .locale(Locale.US) + .run("--no-startup"); + } catch (Exception ex) { + throw new IllegalStateException(ex); + } + }); + + Writer inputSink = new OutputStreamWriter(input.createOutput()) { + @Override + public void write(String str) throws IOException { + super.write(str); + flush(); + } + }; + + runner.start(); + + try { + waitOutput(out, "\u0005"); + test.test(inputSink, out); + } finally { + inputSink.write("\003\003/exit"); + + runner.join(1000); + if (runner.isAlive()) { + runner.stop(); + } + } + } + + protected interface Test { + public void test(Writer inputSink, StringBuilder out) throws Exception; + } + + private static final long TIMEOUT; + + static { + long factor; + + try { + factor = (long) Double.parseDouble(System.getProperty("test.timeout.factor", "1")); + } catch (NumberFormatException ex) { + factor = 1; + } + TIMEOUT = 60_000 * factor; + } + + protected void waitOutput(StringBuilder out, String expected) { + expected = expected.replaceAll("\n", System.getProperty("line.separator")); + Pattern expectedPattern = Pattern.compile(expected, Pattern.DOTALL); + synchronized (out) { + long s = System.currentTimeMillis(); + + while (true) { + Matcher m = expectedPattern.matcher(out); + if (m.find()) { + out.delete(0, m.end() + 1); + return ; + } + long e = System.currentTimeMillis(); + if ((e - s) > TIMEOUT) { + throw new IllegalStateException("Timeout waiting for: " + quote(expected) + ", actual output so far: " + quote(out.toString())); + } + try { + out.wait(TIMEOUT); + } catch (InterruptedException ex) { + ex.printStackTrace(); + } + } + } + } + + private String quote(String original) { + StringBuilder output = new StringBuilder(); + + for (char c : original.toCharArray()) { + if (c < 32) { + output.append(String.format("\\u%04X", (int) c)); + } else { + output.append(c); + } + } + + return output.toString(); + } + + protected String clearOut(String what) { + return backspace(what.length()) + space(what.length()) + backspace(what.length()); + } + + protected String backspace(int n) { + return fill(n, '\010'); + } + + protected String space(int n) { + return fill(n, ' '); + } + + private String fill(int n, char c) { + StringBuilder result = new StringBuilder(n); + + while (n-- > 0) + result.append(c); + + return result.toString(); + } + + private final ResourceBundle resources; + { + resources = ResourceBundle.getBundle("jdk.internal.jshell.tool.resources.l10n", Locale.US, JShell.class.getModule()); + } + + protected String getResource(String key) { + return resources.getString(key); + } + + protected String getMessage(String key, Object... args) { + return MessageFormat.format(resources.getString(key), args); + } + private static class PipeInputStream extends InputStream { + + private static final int INITIAL_SIZE = 128; + private int[] buffer = new int[INITIAL_SIZE]; + private int start; + private int end; + private boolean closed; + + @Override + public synchronized int read() throws IOException { + if (start == end && !closed) { + inputNeeded(); + } + while (start == end) { + if (closed) { + return -1; + } + try { + wait(); + } catch (InterruptedException ex) { + //ignore + } + } + try { + return buffer[start]; + } finally { + start = (start + 1) % buffer.length; + } + } + + @Override + public synchronized int read(byte[] b, int off, int len) throws IOException { + if (b == null) { + throw new NullPointerException(); + } else if (off < 0 || len < 0 || len > b.length - off) { + throw new IndexOutOfBoundsException(); + } else if (len == 0) { + return 0; + } + + int c = read(); + if (c == -1) { + return -1; + } + b[off] = (byte)c; + + int totalRead = 1; + while (totalRead < len && start != end) { + int r = read(); + if (r == (-1)) + break; + b[off + totalRead++] = (byte) r; + } + return totalRead; + } + + protected void inputNeeded() throws IOException {} + + private synchronized void write(int b) { + if (closed) { + throw new IllegalStateException("Already closed."); + } + int newEnd = (end + 1) % buffer.length; + if (newEnd == start) { + //overflow: + int[] newBuffer = new int[buffer.length * 2]; + int rightPart = (end > start ? end : buffer.length) - start; + int leftPart = end > start ? 0 : start - 1; + System.arraycopy(buffer, start, newBuffer, 0, rightPart); + System.arraycopy(buffer, 0, newBuffer, rightPart, leftPart); + buffer = newBuffer; + start = 0; + end = rightPart + leftPart; + newEnd = end + 1; + } + buffer[end] = b; + end = newEnd; + notifyAll(); + } + + @Override + public synchronized void close() { + closed = true; + notifyAll(); + } + + public OutputStream createOutput() { + return new OutputStream() { + @Override public void write(int b) throws IOException { + PipeInputStream.this.write(b); + } + @Override + public void write(byte[] b, int off, int len) throws IOException { + for (int i = 0 ; i < len ; i++) { + write(Byte.toUnsignedInt(b[off + i])); + } + } + @Override + public void close() throws IOException { + PipeInputStream.this.close(); + } + }; + } + + } + +} diff --git a/langtools/test/jdk/jshell/WrapperTest.java b/langtools/test/jdk/jshell/WrapperTest.java index 60fc1d6ac15..8debd466403 100644 --- a/langtools/test/jdk/jshell/WrapperTest.java +++ b/langtools/test/jdk/jshell/WrapperTest.java @@ -14,9 +14,9 @@ * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., start1 Franklin St, Fifth Floor, Boston, MA 02110-1length01 USA. + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * - * Please contact Oracle, start00 Oracle Parkway, Redwood Shores, CA 9406start USA + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ diff --git a/langtools/test/tools/doclint/ProvidesTest.java b/langtools/test/tools/doclint/ProvidesTest.java index d4ac7f4c9a7..db904d458d4 100644 --- a/langtools/test/tools/doclint/ProvidesTest.java +++ b/langtools/test/tools/doclint/ProvidesTest.java @@ -10,20 +10,20 @@ /** * Invalid use of provides in class documentation. * - * @provides UsesTest + * @provides NotFound */ public class ProvidesTest { /** * Invalid use of provides in field documentation * - * @provides UsesTest Test description. + * @provides NotFound Test description. */ public int invalid_param; /** * Invalid use of provides in method documentation * - * @provides UsesTest Test description. + * @provides NotFound Test description. */ public class InvalidParam { } } diff --git a/langtools/test/tools/doclint/ProvidesTest.out b/langtools/test/tools/doclint/ProvidesTest.out index 2dd75a72ee9..c88243a9dbf 100644 --- a/langtools/test/tools/doclint/ProvidesTest.out +++ b/langtools/test/tools/doclint/ProvidesTest.out @@ -1,28 +1,28 @@ ProvidesTest.java:13: error: invalid use of @provides - * @provides UsesTest + * @provides NotFound ^ ProvidesTest.java:13: error: service-type not found - * @provides UsesTest + * @provides NotFound ^ ProvidesTest.java:13: error: reference not found - * @provides UsesTest + * @provides NotFound ^ ProvidesTest.java:19: error: invalid use of @provides - * @provides UsesTest Test description. + * @provides NotFound Test description. ^ ProvidesTest.java:19: error: service-type not found - * @provides UsesTest Test description. + * @provides NotFound Test description. ^ ProvidesTest.java:19: error: reference not found - * @provides UsesTest Test description. + * @provides NotFound Test description. ^ ProvidesTest.java:26: error: invalid use of @provides - * @provides UsesTest Test description. + * @provides NotFound Test description. ^ ProvidesTest.java:26: error: service-type not found - * @provides UsesTest Test description. + * @provides NotFound Test description. ^ ProvidesTest.java:26: error: reference not found - * @provides UsesTest Test description. + * @provides NotFound Test description. ^ 9 errors diff --git a/langtools/test/tools/doclint/UsesTest.java b/langtools/test/tools/doclint/UsesTest.java index 6f15a9f64e6..9f203817d9d 100644 --- a/langtools/test/tools/doclint/UsesTest.java +++ b/langtools/test/tools/doclint/UsesTest.java @@ -10,20 +10,20 @@ /** * Invalid use of uses in class documentation. * - * @uses ProvidesTest + * @uses NotFound */ public class UsesTest { /** * Invalid use of uses in field documentation * - * @uses ProvidesTest Test description. + * @uses NotFound Test description. */ public int invalid_param; /** * Invalid use of uses in method documentation * - * @uses ProvidesTest Test description. + * @uses NotFound Test description. */ public class InvalidParam { } } diff --git a/langtools/test/tools/doclint/UsesTest.out b/langtools/test/tools/doclint/UsesTest.out index aa8aa454197..00a06db4438 100644 --- a/langtools/test/tools/doclint/UsesTest.out +++ b/langtools/test/tools/doclint/UsesTest.out @@ -1,28 +1,28 @@ UsesTest.java:13: error: invalid use of @uses - * @uses ProvidesTest + * @uses NotFound ^ UsesTest.java:13: error: service-type not found - * @uses ProvidesTest + * @uses NotFound ^ UsesTest.java:13: error: reference not found - * @uses ProvidesTest + * @uses NotFound ^ UsesTest.java:19: error: invalid use of @uses - * @uses ProvidesTest Test description. + * @uses NotFound Test description. ^ UsesTest.java:19: error: service-type not found - * @uses ProvidesTest Test description. + * @uses NotFound Test description. ^ UsesTest.java:19: error: reference not found - * @uses ProvidesTest Test description. + * @uses NotFound Test description. ^ UsesTest.java:26: error: invalid use of @uses - * @uses ProvidesTest Test description. + * @uses NotFound Test description. ^ UsesTest.java:26: error: service-type not found - * @uses ProvidesTest Test description. + * @uses NotFound Test description. ^ UsesTest.java:26: error: reference not found - * @uses ProvidesTest Test description. + * @uses NotFound Test description. ^ 9 errors diff --git a/langtools/test/tools/javac/6410653/T6410653.java b/langtools/test/tools/javac/6410653/T6410653.java index 338b77f8b85..632574c9327 100644 --- a/langtools/test/tools/javac/6410653/T6410653.java +++ b/langtools/test/tools/javac/6410653/T6410653.java @@ -31,7 +31,6 @@ */ import java.lang.reflect.Field; -import java.lang.reflect.Module; import java.io.File; import java.io.ByteArrayOutputStream; import javax.tools.*; diff --git a/langtools/test/tools/javac/6627362/T6627362.java b/langtools/test/tools/javac/6627362/T6627362.java index 28d178d4506..d2d7460f585 100644 --- a/langtools/test/tools/javac/6627362/T6627362.java +++ b/langtools/test/tools/javac/6627362/T6627362.java @@ -68,9 +68,9 @@ public class T6627362 { // compile and disassemble E.java, using modified Object.java, // check for reference to System.arraycopy File x = new File(testSrc, "x"); - String[] jcArgs = { "-d", ".", "-Xmodule:java.base", + String[] jcArgs = { "-d", ".", "--patch-module", "java.base=" + x.getAbsolutePath(), new File(x, "E.java").getPath(), - new File(x, "Object.java").getPath()}; + new File(new File(new File(x, "java"), "lang"), "Object.java").getPath()}; compile(jcArgs); String[] jpArgs = { "-classpath", ".", "-c", "E" }; diff --git a/langtools/test/tools/javac/6627362/x/Object.java b/langtools/test/tools/javac/6627362/x/java/lang/Object.java similarity index 100% rename from langtools/test/tools/javac/6627362/x/Object.java rename to langtools/test/tools/javac/6627362/x/java/lang/Object.java diff --git a/langtools/test/tools/javac/8002286/T8002286.out b/langtools/test/tools/javac/8002286/T8002286.out index dd533236d43..2843d58ece7 100644 --- a/langtools/test/tools/javac/8002286/T8002286.out +++ b/langtools/test/tools/javac/8002286/T8002286.out @@ -1,3 +1,2 @@ T8002286.java:8:22: compiler.err.cant.resolve.location.args: kindname.method, value, , , (compiler.misc.location: kindname.annotation, T8002286.Anno, null) -T8002286.java:8:11: compiler.err.cant.resolve.location.args: kindname.method, nonExistent, , , (compiler.misc.location: kindname.class, T8002286, null) -2 errors +1 error diff --git a/langtools/test/tools/javac/T4093617/T4093617.java b/langtools/test/tools/javac/T4093617/T4093617.java index 5162097a8cb..8fa7dfaca55 100644 --- a/langtools/test/tools/javac/T4093617/T4093617.java +++ b/langtools/test/tools/javac/T4093617/T4093617.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,6 +26,6 @@ * @bug 4093617 * @summary Object has no superclass * @author Peter von der Ah\u00e9 - * @compile/module=java.base/fail/ref=T4093617.out -XDrawDiagnostics Object.java + * @compile/module=java.base/fail/ref=T4093617.out -XDrawDiagnostics java/lang/Object.java */ diff --git a/langtools/test/tools/javac/T4093617/java.base/Object.java b/langtools/test/tools/javac/T4093617/java.base/java/lang/Object.java similarity index 100% rename from langtools/test/tools/javac/T4093617/java.base/Object.java rename to langtools/test/tools/javac/T4093617/java.base/java/lang/Object.java diff --git a/langtools/test/tools/javac/T5024091/T5024091.out b/langtools/test/tools/javac/T5024091/T5024091.out index c980b354a8b..85dc3aa000b 100644 --- a/langtools/test/tools/javac/T5024091/T5024091.out +++ b/langtools/test/tools/javac/T5024091/T5024091.out @@ -1,2 +1,2 @@ -T5024091.java:12:29: compiler.err.cant.access: java.lang.StringBuilder, user-selected completion failure by class name +T5024091.java:12:29: compiler.err.cant.access: java.lang.StringBuilder, (compiler.misc.user.selected.completion.failure) 1 error diff --git a/langtools/test/tools/javac/T6234077.out b/langtools/test/tools/javac/T6234077.out index 2a77ac7e7f7..930d00d452a 100644 --- a/langtools/test/tools/javac/T6234077.out +++ b/langtools/test/tools/javac/T6234077.out @@ -1,2 +1,2 @@ -T6234077.java:7:8: compiler.err.class.public.should.be.in.file: Foo +T6234077.java:7:8: compiler.err.class.public.should.be.in.file: kindname.class, Foo 1 error diff --git a/langtools/test/tools/javac/T6406771.java b/langtools/test/tools/javac/T6406771.java index a6ddd05ea4b..78d0e2c8c07 100644 --- a/langtools/test/tools/javac/T6406771.java +++ b/langtools/test/tools/javac/T6406771.java @@ -11,9 +11,9 @@ // Editing the imports and other leading text may affect the golden text in the tests field. // Also beware of scripts that auto-expand tabs to spaces. + + import java.io.*; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.*; import javax.annotation.processing.*; import javax.lang.model.*; diff --git a/langtools/test/tools/javac/T7008643/InlinedFinallyConfuseDebuggersTest.java b/langtools/test/tools/javac/T7008643/InlinedFinallyConfuseDebuggersTest.java index 9edfb58cc38..721e9f72002 100644 --- a/langtools/test/tools/javac/T7008643/InlinedFinallyConfuseDebuggersTest.java +++ b/langtools/test/tools/javac/T7008643/InlinedFinallyConfuseDebuggersTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -72,6 +72,7 @@ public class InlinedFinallyConfuseDebuggersTest { {9, 21}, //System.out.println("finally"); {10, 29}, {9, 32}, //System.out.println("finally"); + {10, 41}, //} {11, 43}, }; diff --git a/langtools/test/tools/javac/T8003967/DetectMutableStaticFields.java b/langtools/test/tools/javac/T8003967/DetectMutableStaticFields.java index a47dd2a9581..4a4c25da9fa 100644 --- a/langtools/test/tools/javac/T8003967/DetectMutableStaticFields.java +++ b/langtools/test/tools/javac/T8003967/DetectMutableStaticFields.java @@ -107,7 +107,7 @@ public class DetectMutableStaticFields { // by reflective lookup, to avoid explicit references that are not available // when running javac on JDK 8. ignore("com/sun/tools/javac/util/JDK9Wrappers$Configuration", - "resolveRequiresAndUsesMethod", "configurationClass"); + "resolveAndBindMethod", "configurationClass"); ignore("com/sun/tools/javac/util/JDK9Wrappers$Layer", "bootMethod", "defineModulesWithOneLoaderMethod", "configurationMethod", "layerClass"); ignore("com/sun/tools/javac/util/JDK9Wrappers$Module", diff --git a/langtools/test/tools/javac/T8173955/MessageForClassTest.java b/langtools/test/tools/javac/T8173955/MessageForClassTest.java new file mode 100644 index 00000000000..5d2e256550a --- /dev/null +++ b/langtools/test/tools/javac/T8173955/MessageForClassTest.java @@ -0,0 +1,8 @@ +/* + * @test /nodynamiccopyright/ + * @bug 8174027 + * @summary error message should adapt to the corresponding top level element + * @compile/fail/ref=MessageForClassTest.out -XDrawDiagnostics MessageForClassTest.java + */ + +public class MessageForClassTest_ {} diff --git a/langtools/test/tools/javac/T8173955/MessageForClassTest.out b/langtools/test/tools/javac/T8173955/MessageForClassTest.out new file mode 100644 index 00000000000..454fca69ee8 --- /dev/null +++ b/langtools/test/tools/javac/T8173955/MessageForClassTest.out @@ -0,0 +1,2 @@ +MessageForClassTest.java:8:8: compiler.err.class.public.should.be.in.file: kindname.class, MessageForClassTest_ +1 error diff --git a/langtools/test/tools/javac/T8173955/MessageForEnumTest.java b/langtools/test/tools/javac/T8173955/MessageForEnumTest.java new file mode 100644 index 00000000000..343ef77b070 --- /dev/null +++ b/langtools/test/tools/javac/T8173955/MessageForEnumTest.java @@ -0,0 +1,8 @@ +/* + * @test /nodynamiccopyright/ + * @bug 8174027 + * @summary error message should adapt to the corresponding top level element + * @compile/fail/ref=MessageForEnumTest.out -XDrawDiagnostics MessageForEnumTest.java + */ + +public enum MessageForEnumTest_ {} diff --git a/langtools/test/tools/javac/T8173955/MessageForEnumTest.out b/langtools/test/tools/javac/T8173955/MessageForEnumTest.out new file mode 100644 index 00000000000..ae9f60e1f0d --- /dev/null +++ b/langtools/test/tools/javac/T8173955/MessageForEnumTest.out @@ -0,0 +1,2 @@ +MessageForEnumTest.java:8:8: compiler.err.class.public.should.be.in.file: kindname.enum, MessageForEnumTest_ +1 error diff --git a/langtools/test/tools/javac/T8173955/MessageForInterfaceTest.java b/langtools/test/tools/javac/T8173955/MessageForInterfaceTest.java new file mode 100644 index 00000000000..563c58bedb5 --- /dev/null +++ b/langtools/test/tools/javac/T8173955/MessageForInterfaceTest.java @@ -0,0 +1,8 @@ +/* + * @test /nodynamiccopyright/ + * @bug 8174027 + * @summary error message should adapt to the corresponding top level element + * @compile/fail/ref=MessageForInterfaceTest.out -XDrawDiagnostics MessageForInterfaceTest.java + */ + +public interface MessageForInterfaceTest_ {} diff --git a/langtools/test/tools/javac/T8173955/MessageForInterfaceTest.out b/langtools/test/tools/javac/T8173955/MessageForInterfaceTest.out new file mode 100644 index 00000000000..88cd9cd18ae --- /dev/null +++ b/langtools/test/tools/javac/T8173955/MessageForInterfaceTest.out @@ -0,0 +1,2 @@ +MessageForInterfaceTest.java:8:8: compiler.err.class.public.should.be.in.file: kindname.interface, MessageForInterfaceTest_ +1 error diff --git a/langtools/test/tools/javac/T8175198/AnnotationsAndFormalParamsTest.java b/langtools/test/tools/javac/T8175198/AnnotationsAndFormalParamsTest.java new file mode 100644 index 00000000000..2dacafe9948 --- /dev/null +++ b/langtools/test/tools/javac/T8175198/AnnotationsAndFormalParamsTest.java @@ -0,0 +1,11 @@ +/* + * @test /nodynamiccopyright/ + * @bug 8175198 + * @summary Javac incorrectly allows receiver parameters in annotation methods + * @compile/fail/ref=AnnotationsAndFormalParamsTest.out -XDrawDiagnostics -Werror -Xlint:unchecked AnnotationsAndFormalParamsTest.java + */ + +@interface AnnotationsAndFormalParamsTest { + int value(int i); + int foo(AnnotationsAndFormalParamsTest this); +} diff --git a/langtools/test/tools/javac/T8175198/AnnotationsAndFormalParamsTest.out b/langtools/test/tools/javac/T8175198/AnnotationsAndFormalParamsTest.out new file mode 100644 index 00000000000..b0ea335e75c --- /dev/null +++ b/langtools/test/tools/javac/T8175198/AnnotationsAndFormalParamsTest.out @@ -0,0 +1,3 @@ +AnnotationsAndFormalParamsTest.java:9:19: compiler.err.intf.annotation.members.cant.have.params +AnnotationsAndFormalParamsTest.java:10:44: compiler.err.intf.annotation.members.cant.have.params +2 errors diff --git a/langtools/test/tools/javac/T8175235/InferenceRegressionTest01.java b/langtools/test/tools/javac/T8175235/InferenceRegressionTest01.java new file mode 100644 index 00000000000..3f72d45903b --- /dev/null +++ b/langtools/test/tools/javac/T8175235/InferenceRegressionTest01.java @@ -0,0 +1,43 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8175235 + * @summary type inference regression after JDK-8046685 + * @compile InferenceRegressionTest01.java + */ + +import java.util.function.Predicate; + +abstract class InferenceRegressionTest01 { + + void f(String r) { + a(r, c(o(p(s -> s.isEmpty())))); + } + + abstract U o(U u); + abstract Predicate c(Predicate xs); + abstract void a(S a, Predicate m); + abstract Predicate p(Predicate p); +} diff --git a/langtools/test/tools/javac/T8175235/InferenceRegressionTest02.java b/langtools/test/tools/javac/T8175235/InferenceRegressionTest02.java new file mode 100644 index 00000000000..dd4e14d453b --- /dev/null +++ b/langtools/test/tools/javac/T8175235/InferenceRegressionTest02.java @@ -0,0 +1,104 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8175235 + * @summary type inference regression after JDK-8046685 + * @library /tools/javac/lib + * @modules jdk.compiler/com.sun.source.util + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.code + * jdk.compiler/com.sun.tools.javac.file + * jdk.compiler/com.sun.tools.javac.tree + * jdk.compiler/com.sun.tools.javac.util + * @build DPrinter + * @run main InferenceRegressionTest02 + */ + +import java.io.*; +import java.net.URI; +import java.util.Arrays; + +import javax.tools.JavaCompiler; +import javax.tools.JavaFileObject; +import javax.tools.SimpleJavaFileObject; +import javax.tools.ToolProvider; + +import com.sun.source.tree.CompilationUnitTree; +import com.sun.source.util.JavacTask; +import com.sun.source.util.Trees; +import com.sun.tools.javac.api.JavacTrees; +import com.sun.tools.javac.file.JavacFileManager; +import com.sun.tools.javac.tree.JCTree; +import com.sun.tools.javac.util.Assert; +import com.sun.tools.javac.util.Context; + +public class InferenceRegressionTest02 { + public static void main(String... args) throws Exception { + new InferenceRegressionTest02().run(); + } + + void run() throws Exception { + Context context = new Context(); + JavacFileManager.preRegister(context); + Trees trees = JavacTrees.instance(context); + StringWriter strOut = new StringWriter(); + PrintWriter pw = new PrintWriter(strOut); + DPrinter dprinter = new DPrinter(pw, trees); + final JavaCompiler tool = ToolProvider.getSystemJavaCompiler(); + JavacTask ct = (JavacTask)tool.getTask(null, null, null, null, null, Arrays.asList(new JavaSource())); + Iterable elements = ct.parse(); + ct.analyze(); + Assert.check(elements.iterator().hasNext()); + dprinter.treeTypes(true).printTree("", (JCTree)elements.iterator().next()); + String output = strOut.toString(); + Assert.check(!output.contains("java.lang.Object"), "there shouldn't be any type instantiated to Object"); + } + + static class JavaSource extends SimpleJavaFileObject { + + String source = + "import java.util.function.*;\n" + + "import java.util.*;\n" + + "import java.util.stream.*;\n" + + + "class Foo {\n" + + " void test(List> ls) {\n" + + " Map> res = ls.stream()\n" + + " .collect(Collectors.groupingBy(Map.Entry::getKey,\n" + + " HashMap::new,\n" + + " Collectors.mapping(Map.Entry::getValue, Collectors.toSet())));\n" + + " }\n" + + "}"; + + public JavaSource() { + super(URI.create("myfo:/Foo.java"), JavaFileObject.Kind.SOURCE); + } + + @Override + public CharSequence getCharContent(boolean ignoreEncodingErrors) { + return source; + } + } +} diff --git a/langtools/test/tools/javac/T8175790/NPEDueToErroneousLambdaTest.java b/langtools/test/tools/javac/T8175790/NPEDueToErroneousLambdaTest.java new file mode 100644 index 00000000000..a6a02b07f14 --- /dev/null +++ b/langtools/test/tools/javac/T8175790/NPEDueToErroneousLambdaTest.java @@ -0,0 +1,29 @@ +/* + * @test /nodynamiccopyright/ + * @bug 8175790 + * @summary field JCVariableDecl.vartype can't be null after post attribution analysis + * @compile/fail/ref=NPEDueToErroneousLambdaTest.out -XDrawDiagnostics NPEDueToErroneousLambdaTest.java + */ + +import java.util.List; +import java.util.function.Function; + +public abstract class NPEDueToErroneousLambdaTest { + + interface R {} + interface A {} + interface S {} + + abstract Function p(final Function function); + abstract List t(Function function); + + public void f() { + t(p(new Function() { + public List apply(A a) throws Exception { + return t((Function)input -> { + return t(p((Function) i -> null), null); + }); + } + })); + } +} diff --git a/langtools/test/tools/javac/T8175790/NPEDueToErroneousLambdaTest.out b/langtools/test/tools/javac/T8175790/NPEDueToErroneousLambdaTest.out new file mode 100644 index 00000000000..867b3cd69e1 --- /dev/null +++ b/langtools/test/tools/javac/T8175790/NPEDueToErroneousLambdaTest.out @@ -0,0 +1,3 @@ +NPEDueToErroneousLambdaTest.java:22:33: compiler.err.override.meth.doesnt.throw: (compiler.misc.cant.implement: apply(NPEDueToErroneousLambdaTest.A), compiler.misc.anonymous.class: NPEDueToErroneousLambdaTest$1, apply(T), java.util.function.Function), java.lang.Exception +NPEDueToErroneousLambdaTest.java:24:32: compiler.err.cant.apply.symbol: kindname.method, t, java.util.function.Function, java.util.function.Function,compiler.misc.type.null, kindname.class, NPEDueToErroneousLambdaTest, (compiler.misc.infer.arg.length.mismatch: I,O) +2 errors diff --git a/langtools/test/tools/javac/T8175794/MissingReturnConstraintTest.java b/langtools/test/tools/javac/T8175794/MissingReturnConstraintTest.java new file mode 100644 index 00000000000..8ffef06b647 --- /dev/null +++ b/langtools/test/tools/javac/T8175794/MissingReturnConstraintTest.java @@ -0,0 +1,43 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8175794 + * @summary Type inference regression after JDK-8078093 + * @compile MissingReturnConstraintTest.java + */ + +import java.util.concurrent.ExecutorService; + +public abstract class MissingReturnConstraintTest { + void f(ExecutorService s) { + s.submit(() -> run(() -> {})); + } + + abstract void run(ThrowableRunnable action) throws E; + + public interface ThrowableRunnable { + void run() throws T; + } +} diff --git a/langtools/test/tools/javac/T8176714/FieldOverloadKindNotAssignedTest.java b/langtools/test/tools/javac/T8176714/FieldOverloadKindNotAssignedTest.java new file mode 100644 index 00000000000..e1e71343dc6 --- /dev/null +++ b/langtools/test/tools/javac/T8176714/FieldOverloadKindNotAssignedTest.java @@ -0,0 +1,104 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176714 + * @summary javac is wrongly assuming that field JCMemberReference.overloadKind has been assigned to + * @library /tools/javac/lib + * @modules jdk.compiler/com.sun.source.util + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.code + * jdk.compiler/com.sun.tools.javac.file + * jdk.compiler/com.sun.tools.javac.tree + * jdk.compiler/com.sun.tools.javac.util + * @build DPrinter + * @run main FieldOverloadKindNotAssignedTest + */ + +import java.net.URI; +import java.util.Arrays; + +import javax.tools.JavaCompiler; +import javax.tools.JavaFileObject; +import javax.tools.SimpleJavaFileObject; +import javax.tools.ToolProvider; + +import com.sun.source.tree.CompilationUnitTree; +import com.sun.source.util.JavacTask; +import com.sun.tools.javac.file.JavacFileManager; +import com.sun.tools.javac.tree.JCTree; +import com.sun.tools.javac.tree.JCTree.JCMemberReference; +import com.sun.tools.javac.tree.TreeScanner; +import com.sun.tools.javac.util.Assert; +import com.sun.tools.javac.util.Context; + +public class FieldOverloadKindNotAssignedTest { + public static void main(String... args) throws Exception { + new FieldOverloadKindNotAssignedTest().run(); + } + + void run() throws Exception { + Context context = new Context(); + JavacFileManager.preRegister(context); + final JavaCompiler tool = ToolProvider.getSystemJavaCompiler(); + JavacTask ct = (JavacTask)tool.getTask(null, null, null, null, null, Arrays.asList(new JavaSource())); + Iterable elements = ct.parse(); + ct.analyze(); + Assert.check(elements.iterator().hasNext()); + JCTree topLevel = (JCTree)elements.iterator().next(); + new TreeScanner() { + @Override + public void visitReference(JCMemberReference tree) { + Assert.check(tree.getOverloadKind() != null); + } + }.scan(topLevel); + } + + static class JavaSource extends SimpleJavaFileObject { + + String source = + "import java.util.function.*;\n" + + + "class Test {\n" + + " void m(Predicate psi) {}\n" + + " void m(Function fss) {}\n" + + + " void foo(boolean b) {\n" + + " m(b ? s -> false : Test::g);\n" + + " }\n" + + + " static boolean g(String s) { return false; }\n" + + " static boolean g(Integer i) { return false; }\n" + + "}"; + + public JavaSource() { + super(URI.create("myfo:/Foo.java"), JavaFileObject.Kind.SOURCE); + } + + @Override + public CharSequence getCharContent(boolean ignoreEncodingErrors) { + return source; + } + } +} diff --git a/jdk/test/java/io/Serializable/serialver/nested/Test.java b/langtools/test/tools/javac/T8176714/TimingOfMReferenceCheckingTest01.java similarity index 67% rename from jdk/test/java/io/Serializable/serialver/nested/Test.java rename to langtools/test/tools/javac/T8176714/TimingOfMReferenceCheckingTest01.java index 6136ae9cc61..5978b2fb460 100644 --- a/jdk/test/java/io/Serializable/serialver/nested/Test.java +++ b/langtools/test/tools/javac/T8176714/TimingOfMReferenceCheckingTest01.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,19 +22,21 @@ */ /* - * - * @bug 4312217 - * @summary To test the use of nested class specification using the '.' - * notation instead of the '$' notation. + * @test + * @bug 8176714 + * @summary javac is wrongly assuming that field JCMemberReference.overloadKind has been assigned to + * @compile TimingOfMReferenceCheckingTest01.java */ -package serialver; -import java.io.*; +import java.util.function.*; -public class Test implements Serializable { - public static class Test1 implements Serializable { - public static class Test2 implements Serializable{ - private static final long serialVersionUID = 100L; - } +public class TimingOfMReferenceCheckingTest01 { + void g(Consumer fzr, Z z) {} + + void test(boolean cond) { + g(cond ? this::m : this::m, ""); } + + void m(String s) {} + void m(Integer i) {} } diff --git a/langtools/test/tools/javac/T8176714/TimingOfMReferenceCheckingTest02.java b/langtools/test/tools/javac/T8176714/TimingOfMReferenceCheckingTest02.java new file mode 100644 index 00000000000..e9e8c9bacf8 --- /dev/null +++ b/langtools/test/tools/javac/T8176714/TimingOfMReferenceCheckingTest02.java @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176714 + * @summary javac is wrongly assuming that field JCMemberReference.overloadKind has been assigned to + * @compile TimingOfMReferenceCheckingTest02.java + */ + +import java.util.function.*; + +public class TimingOfMReferenceCheckingTest02 { + void g(Consumer fzr, Z z) {} + T f(T t) { return null; } + + void test(boolean cond) { + g(cond ? + f(cond ? + this::m : + this::m) : + this::m, ""); + } + + void m(String s) {} + void m(Integer i) {} +} diff --git a/langtools/test/tools/javac/T8180141/MissingLNTEntryForBreakContinueTest.java b/langtools/test/tools/javac/T8180141/MissingLNTEntryForBreakContinueTest.java new file mode 100644 index 00000000000..e032e93e8c2 --- /dev/null +++ b/langtools/test/tools/javac/T8180141/MissingLNTEntryForBreakContinueTest.java @@ -0,0 +1,184 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8180141 + * @summary Missing entry in LineNumberTable for break statement that jumps out of try-finally + * @modules jdk.jdeps/com.sun.tools.classfile + * jdk.compiler/com.sun.tools.javac.code + * jdk.compiler/com.sun.tools.javac.comp + * jdk.compiler/com.sun.tools.javac.file + * jdk.compiler/com.sun.tools.javac.main + * jdk.compiler/com.sun.tools.javac.tree + * jdk.compiler/com.sun.tools.javac.util + * @compile -g MissingLNTEntryForBreakContinueTest.java + * @run main MissingLNTEntryForBreakContinueTest + */ + +import java.io.File; +import java.net.URI; + +import javax.tools.JavaFileObject; +import javax.tools.SimpleJavaFileObject; + +import com.sun.tools.classfile.*; +import com.sun.tools.javac.comp.Attr; +import com.sun.tools.javac.comp.AttrContext; +import com.sun.tools.javac.comp.Env; +import com.sun.tools.javac.comp.Modules; +import com.sun.tools.javac.file.JavacFileManager; +import com.sun.tools.javac.main.JavaCompiler; +import com.sun.tools.javac.tree.JCTree; +import com.sun.tools.javac.util.Context; +import com.sun.tools.javac.util.List; + +import static com.sun.tools.javac.util.List.of; +import static com.sun.tools.javac.tree.JCTree.Tag.*; + +public class MissingLNTEntryForBreakContinueTest { + protected ReusableJavaCompiler tool; + Context context; + + MissingLNTEntryForBreakContinueTest() { + context = new Context(); + JavacFileManager.preRegister(context); + MyAttr.preRegister(context); + tool = new ReusableJavaCompiler(context); + } + + public static void main(String... args) throws Throwable { + new MissingLNTEntryForBreakContinueTest().test(); + } + + void test() throws Throwable { + testFor("1", "break"); + testFor("2", "continue"); + } + + void testFor(String id, String statement) throws Throwable { + JavaSource source = new JavaSource(id, statement); + tool.clear(); + List inputs = of(source); + try { + tool.compile(inputs); + } catch (Throwable ex) { + throw new AssertionError(ex); + } + File testClasses = new File("."); + File file = new File(testClasses, "Test" + id + ".class"); + ClassFile classFile = ClassFile.read(file); + for (Method m : classFile.methods) { + if (classFile.constant_pool.getUTF8Value(m.name_index).equals("foo")) { + Code_attribute code = (Code_attribute)m.attributes.get(Attribute.Code); + LineNumberTable_attribute lnt = (LineNumberTable_attribute)code.attributes.get(Attribute.LineNumberTable); + checkLNT(lnt, MyAttr.lineNumber); + } + } + } + + void checkLNT(LineNumberTable_attribute lnt, int lineToCheckFor) { + for (LineNumberTable_attribute.Entry e: lnt.line_number_table) { + if (e.line_number == lineToCheckFor) { + return; + } + } + throw new AssertionError("seek line number not found in the LNT for method foo()"); + } + + class JavaSource extends SimpleJavaFileObject { + String statement; + String id; + String template = + "class Test#Id {\n" + + " void foo(boolean condition) {\n" + + " while (true) {\n" + + " try {\n" + + " if (condition) {\n" + + " #STM;\n" + + " }\n" + + " } finally {\n" + + " System.out.println(\"finalizer\");\n" + + " }\n" + + " }\n" + + " }" + + "}"; + + JavaSource(String id, String statement) { + super(URI.create("myfo:/Test.java"), JavaFileObject.Kind.SOURCE); + this.statement = statement; + this.id = id; + } + + @Override + public CharSequence getCharContent(boolean ignoreEncodingErrors) { + return template.replace("#Id", id).replace("#STM", statement); + } + } + + /* this class has been set up to do not depend on a fixed line number, this Attr subclass will + * look for 'break' or 'continue' statements in order to find the actual line number they occupy. + * This way the test can find if that line number appears in the LNT generated for a given class. + */ + static class MyAttr extends Attr { + static int lineNumber; + + static void preRegister(Context context) { + context.put(attrKey, (com.sun.tools.javac.util.Context.Factory) c -> new MyAttr(c)); + } + + MyAttr(Context context) { + super(context); + } + + @Override + public com.sun.tools.javac.code.Type attribStat(JCTree tree, Env env) { + com.sun.tools.javac.code.Type result = super.attribStat(tree, env); + if (tree.hasTag(BREAK) || tree.hasTag(CONTINUE)) { + lineNumber = env.toplevel.lineMap.getLineNumber(tree.pos); + } + return result; + } + } + + static class ReusableJavaCompiler extends JavaCompiler { + ReusableJavaCompiler(Context context) { + super(context); + } + + @Override + protected void checkReusable() { + // do nothing + } + + @Override + public void close() { + //do nothing + } + + void clear() { + newRound(); + Modules.instance(context).newRound(); + } + } +} diff --git a/langtools/test/tools/javac/T8180660/MissingLNTEntryForFinalizerTest.java b/langtools/test/tools/javac/T8180660/MissingLNTEntryForFinalizerTest.java new file mode 100644 index 00000000000..49e4026fd07 --- /dev/null +++ b/langtools/test/tools/javac/T8180660/MissingLNTEntryForFinalizerTest.java @@ -0,0 +1,180 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8180141 + * @summary Missing entry in LineNumberTable for break statement that jumps out of try-finally + * @modules jdk.jdeps/com.sun.tools.classfile + * jdk.compiler/com.sun.tools.javac.code + * jdk.compiler/com.sun.tools.javac.comp + * jdk.compiler/com.sun.tools.javac.file + * jdk.compiler/com.sun.tools.javac.main + * jdk.compiler/com.sun.tools.javac.tree + * jdk.compiler/com.sun.tools.javac.util + * @compile -g MissingLNTEntryForFinalizerTest.java + * @run main MissingLNTEntryForFinalizerTest + */ + +import java.io.File; +import java.net.URI; + +import javax.tools.JavaFileObject; +import javax.tools.SimpleJavaFileObject; + +import com.sun.tools.classfile.*; +import com.sun.tools.javac.comp.Attr; +import com.sun.tools.javac.comp.AttrContext; +import com.sun.tools.javac.comp.Env; +import com.sun.tools.javac.comp.Modules; +import com.sun.tools.javac.file.JavacFileManager; +import com.sun.tools.javac.main.JavaCompiler; +import com.sun.tools.javac.tree.JCTree; +import com.sun.tools.javac.tree.JCTree.*; +import com.sun.tools.javac.util.Context; +import com.sun.tools.javac.util.List; + +import static com.sun.tools.javac.util.List.of; +import static com.sun.tools.javac.tree.JCTree.Tag.*; + +public class MissingLNTEntryForFinalizerTest { + protected ReusableJavaCompiler tool; + Context context; + + MissingLNTEntryForFinalizerTest() { + context = new Context(); + JavacFileManager.preRegister(context); + MyAttr.preRegister(context); + tool = new ReusableJavaCompiler(context); + } + + public static void main(String... args) throws Throwable { + new MissingLNTEntryForFinalizerTest().test(); + } + + void test() throws Throwable { + JavaSource source = new JavaSource("1"); + tool.clear(); + List inputs = of(source); + try { + tool.compile(inputs); + } catch (Throwable ex) { + throw new AssertionError(ex); + } + File testClasses = new File("."); + File file = new File(testClasses, "Test1.class"); + ClassFile classFile = ClassFile.read(file); + for (Method m : classFile.methods) { + if (classFile.constant_pool.getUTF8Value(m.name_index).equals("foo")) { + Code_attribute code = (Code_attribute)m.attributes.get(Attribute.Code); + LineNumberTable_attribute lnt = (LineNumberTable_attribute)code.attributes.get(Attribute.LineNumberTable); + checkLNT(lnt, MyAttr.lineNumber); + } + } + } + + void checkLNT(LineNumberTable_attribute lnt, int lineToCheckFor) { + for (LineNumberTable_attribute.Entry e: lnt.line_number_table) { + if (e.line_number == lineToCheckFor) { + return; + } + } + throw new AssertionError("seek line number not found in the LNT for method foo()"); + } + + class JavaSource extends SimpleJavaFileObject { + String id; + String template = + "import java.util.*;\n" + + "class Test#Id {\n" + + " void foo() {\n" + + " List l = null;\n" + + " String first = null;\n" + + " try {\n" + + " first = l.get(0);\n" + + " } finally {\n" + + " if (first != null) {\n" + + " System.out.println(\"finalizer\");\n" + + " }\n" + + " }\n" + + " }\n" + + "}"; + + JavaSource(String id) { + super(URI.create("myfo:/Test.java"), JavaFileObject.Kind.SOURCE); + this.id = id; + } + + @Override + public CharSequence getCharContent(boolean ignoreEncodingErrors) { + return template.replace("#Id", id); + } + } + + /* this class has been set up to do not depend on a fixed line number, this Attr subclass will + * look for 'break' or 'continue' statements in order to find the actual line number they occupy. + * This way the test can find if that line number appears in the LNT generated for a given class. + */ + static class MyAttr extends Attr { + static int lineNumber; + + static void preRegister(Context context) { + context.put(attrKey, (com.sun.tools.javac.util.Context.Factory) c -> new MyAttr(c)); + } + + MyAttr(Context context) { + super(context); + } + + @Override + public com.sun.tools.javac.code.Type attribStat(JCTree tree, Env env) { + com.sun.tools.javac.code.Type result = super.attribStat(tree, env); + if (tree.hasTag(TRY)) { + JCTry tryTree = (JCTry)tree; + lineNumber = env.toplevel.lineMap.getLineNumber(tryTree.finalizer.endpos); + } + return result; + } + } + + static class ReusableJavaCompiler extends JavaCompiler { + ReusableJavaCompiler(Context context) { + super(context); + } + + @Override + protected void checkReusable() { + // do nothing + } + + @Override + public void close() { + //do nothing + } + + void clear() { + newRound(); + Modules.instance(context).newRound(); + } + } +} diff --git a/langtools/test/tools/javac/T8181464/Anno.java b/langtools/test/tools/javac/T8181464/Anno.java new file mode 100644 index 00000000000..f5eb9652815 --- /dev/null +++ b/langtools/test/tools/javac/T8181464/Anno.java @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +@interface Anno { + Class value(); +} diff --git a/langtools/test/tools/javac/T8181464/Anno2.java b/langtools/test/tools/javac/T8181464/Anno2.java new file mode 100644 index 00000000000..fa7dc6bc98a --- /dev/null +++ b/langtools/test/tools/javac/T8181464/Anno2.java @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +@interface Anno2 { + String value(); +} diff --git a/langtools/test/tools/javac/T8181464/AnnoProcessor.java b/langtools/test/tools/javac/T8181464/AnnoProcessor.java new file mode 100644 index 00000000000..f122d13da89 --- /dev/null +++ b/langtools/test/tools/javac/T8181464/AnnoProcessor.java @@ -0,0 +1,36 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.util.Set; +import javax.annotation.processing.AbstractProcessor; +import javax.annotation.processing.RoundEnvironment; +import javax.annotation.processing.SupportedAnnotationTypes; +import javax.lang.model.element.TypeElement; + +@SupportedAnnotationTypes("*") +public class AnnoProcessor extends AbstractProcessor { + @Override + public boolean process(Set annotations, RoundEnvironment roundEnv) { + return false; + } +} diff --git a/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest1.java b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest1.java new file mode 100644 index 00000000000..2c547136e59 --- /dev/null +++ b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest1.java @@ -0,0 +1,11 @@ +/* @test /nodynamiccopyright/ + * @bug 8181464 + * @summary Invalid lambda in annotation causes NPE in Lint.augment + * @modules java.compiler + * jdk.compiler + * @compile Anno.java AnnoProcessor.java + * @compile/fail/ref=LambdaInAnnotationsCausesNPETest1.out -XDrawDiagnostics -processor AnnoProcessor -proc:only LambdaInAnnotationsCausesNPETest1.java + */ + +@Anno(value = x -> x) +class LambdaInAnnotationsCausesNPETest1 {} diff --git a/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest1.out b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest1.out new file mode 100644 index 00000000000..c0f241b3d9f --- /dev/null +++ b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest1.out @@ -0,0 +1,2 @@ +LambdaInAnnotationsCausesNPETest1.java:10:15: compiler.err.expression.not.allowable.as.annotation.value +1 error diff --git a/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest2.java b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest2.java new file mode 100644 index 00000000000..190a79d69ab --- /dev/null +++ b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest2.java @@ -0,0 +1,11 @@ +/* @test /nodynamiccopyright/ + * @bug 8181464 + * @summary Invalid lambda in annotation causes NPE in Lint.augment + * @modules java.compiler + * jdk.compiler + * @compile Anno.java AnnoProcessor.java + * @compile/fail/ref=LambdaInAnnotationsCausesNPETest2.out -XDrawDiagnostics -processor AnnoProcessor -proc:only LambdaInAnnotationsCausesNPETest2.java + */ + +@Anno(value = (String x) -> x) +class LambdaInAnnotationsCausesNPETest2 {} diff --git a/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest2.out b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest2.out new file mode 100644 index 00000000000..96cd8cf1983 --- /dev/null +++ b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest2.out @@ -0,0 +1,2 @@ +LambdaInAnnotationsCausesNPETest2.java:10:15: compiler.err.expression.not.allowable.as.annotation.value +1 error diff --git a/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest3.java b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest3.java new file mode 100644 index 00000000000..8fec5261ce3 --- /dev/null +++ b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest3.java @@ -0,0 +1,15 @@ +/* @test /nodynamiccopyright/ + * @bug 8181464 + * @summary Invalid lambda in annotation causes NPE in Lint.augment + * @modules java.compiler + * jdk.compiler + * @compile Anno2.java AnnoProcessor.java + * @compile/fail/ref=LambdaInAnnotationsCausesNPETest3.out -XDrawDiagnostics -processor AnnoProcessor -proc:only LambdaInAnnotationsCausesNPETest3.java + */ + +@Anno2(value = LambdaInAnnotationsCausesNPETest3.m(x -> x)) +class LambdaInAnnotationsCausesNPETest3 { + static String m(Class target) { + return null; + } +} diff --git a/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest3.out b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest3.out new file mode 100644 index 00000000000..c4c560908ff --- /dev/null +++ b/langtools/test/tools/javac/T8181464/LambdaInAnnotationsCausesNPETest3.out @@ -0,0 +1,2 @@ +LambdaInAnnotationsCausesNPETest3.java:10:51: compiler.err.expression.not.allowable.as.annotation.value +1 error diff --git a/langtools/test/tools/javac/annotations/neg/AnonSubclass.out b/langtools/test/tools/javac/annotations/neg/AnonSubclass.out index 48984a89f78..dd2661e0961 100644 --- a/langtools/test/tools/javac/annotations/neg/AnonSubclass.out +++ b/langtools/test/tools/javac/annotations/neg/AnonSubclass.out @@ -1,2 +1,2 @@ -AnonSubclass.java:10:15: compiler.err.prob.found.req: (compiler.misc.inconvertible.types: compiler.misc.anonymous.class: java.lang.Object, java.lang.String) +AnonSubclass.java:10:15: compiler.err.expression.not.allowable.as.annotation.value 1 error diff --git a/langtools/test/tools/javac/annotations/neg/Cycle1.out b/langtools/test/tools/javac/annotations/neg/Cycle1.out index 9b80cb31a62..e76f6986b92 100644 --- a/langtools/test/tools/javac/annotations/neg/Cycle1.out +++ b/langtools/test/tools/javac/annotations/neg/Cycle1.out @@ -1,2 +1,2 @@ -Cycle1.java:13:9: compiler.err.cyclic.annotation.element +Cycle1.java:13:9: compiler.err.cyclic.annotation.element: cycle1.Foo 1 error diff --git a/langtools/test/tools/javac/annotations/neg/Cycle2.out b/langtools/test/tools/javac/annotations/neg/Cycle2.out index 200b4c6c4e5..2e5dcb3ca4e 100644 --- a/langtools/test/tools/javac/annotations/neg/Cycle2.out +++ b/langtools/test/tools/javac/annotations/neg/Cycle2.out @@ -1,2 +1,2 @@ -Cycle2.java:13:9: compiler.err.cyclic.annotation.element +Cycle2.java:13:9: compiler.err.cyclic.annotation.element: cycle2.Bar 1 error diff --git a/langtools/test/tools/javac/annotations/neg/Cycle3.out b/langtools/test/tools/javac/annotations/neg/Cycle3.out index b9e33792940..02362fcf0da 100644 --- a/langtools/test/tools/javac/annotations/neg/Cycle3.out +++ b/langtools/test/tools/javac/annotations/neg/Cycle3.out @@ -1,2 +1,2 @@ -Cycle3.java:17:9: compiler.err.cyclic.annotation.element +Cycle3.java:17:9: compiler.err.cyclic.annotation.element: cycle3.A 1 error diff --git a/langtools/test/tools/javac/annotations/neg/Dup.out b/langtools/test/tools/javac/annotations/neg/Dup.out index 516dfcacc02..cc8a4a8a6f4 100644 --- a/langtools/test/tools/javac/annotations/neg/Dup.out +++ b/langtools/test/tools/javac/annotations/neg/Dup.out @@ -1,2 +1,2 @@ -Dup.java:11:1: compiler.err.duplicate.annotation.missing.container: Dup, java.lang.annotation.Repeatable +Dup.java:11:1: compiler.err.duplicate.annotation.missing.container: Dup 1 error diff --git a/langtools/test/tools/javac/annotations/neg/Z14.out b/langtools/test/tools/javac/annotations/neg/Z14.out index e0136bf9b67..ab0d2cadb67 100644 --- a/langtools/test/tools/javac/annotations/neg/Z14.out +++ b/langtools/test/tools/javac/annotations/neg/Z14.out @@ -1,2 +1,2 @@ -Z14.java:10:15: compiler.err.intf.annotation.cant.have.type.params +Z14.java:10:15: compiler.err.intf.annotation.cant.have.type.params: An 1 error diff --git a/langtools/test/tools/javac/annotations/neg/Z15.out b/langtools/test/tools/javac/annotations/neg/Z15.out index 587b6b62755..c9baea83212 100644 --- a/langtools/test/tools/javac/annotations/neg/Z15.out +++ b/langtools/test/tools/javac/annotations/neg/Z15.out @@ -1,2 +1,2 @@ -Z15.java:11:36: compiler.err.attribute.value.must.be.constant +Z15.java:11:36: compiler.err.expression.not.allowable.as.annotation.value 1 error diff --git a/langtools/test/tools/javac/annotations/neg/pkg/package-info.out b/langtools/test/tools/javac/annotations/neg/pkg/package-info.out index 11c16e592e3..c383621eb59 100644 --- a/langtools/test/tools/javac/annotations/neg/pkg/package-info.out +++ b/langtools/test/tools/javac/annotations/neg/pkg/package-info.out @@ -1,2 +1,2 @@ -package-info.java:11:20: compiler.err.prob.found.req: (compiler.misc.inconvertible.types: compiler.misc.anonymous.class: java.lang.Object, java.lang.String) +package-info.java:11:20: compiler.err.expression.not.allowable.as.annotation.value 1 error diff --git a/langtools/test/tools/javac/annotations/repeatingAnnotations/BaseAnnoAsContainerAnno.out b/langtools/test/tools/javac/annotations/repeatingAnnotations/BaseAnnoAsContainerAnno.out index 0d6975ac424..30bf1b8081a 100644 --- a/langtools/test/tools/javac/annotations/repeatingAnnotations/BaseAnnoAsContainerAnno.out +++ b/langtools/test/tools/javac/annotations/repeatingAnnotations/BaseAnnoAsContainerAnno.out @@ -1,2 +1,2 @@ -BaseAnnoAsContainerAnno.java:13:11: compiler.err.cyclic.annotation.element +BaseAnnoAsContainerAnno.java:13:11: compiler.err.cyclic.annotation.element: Foo 1 error diff --git a/langtools/test/tools/javac/annotations/repeatingAnnotations/CyclicAnnotation.out b/langtools/test/tools/javac/annotations/repeatingAnnotations/CyclicAnnotation.out index 84079dd77b4..e71ad9f66cd 100644 --- a/langtools/test/tools/javac/annotations/repeatingAnnotations/CyclicAnnotation.out +++ b/langtools/test/tools/javac/annotations/repeatingAnnotations/CyclicAnnotation.out @@ -1,2 +1,2 @@ -CyclicAnnotation.java:13:11: compiler.err.cyclic.annotation.element +CyclicAnnotation.java:13:11: compiler.err.cyclic.annotation.element: Baz 1 error diff --git a/langtools/test/tools/javac/annotations/repeatingAnnotations/DuplicateErrors.out b/langtools/test/tools/javac/annotations/repeatingAnnotations/DuplicateErrors.out index c38501ef58e..d0fd2d40195 100644 --- a/langtools/test/tools/javac/annotations/repeatingAnnotations/DuplicateErrors.out +++ b/langtools/test/tools/javac/annotations/repeatingAnnotations/DuplicateErrors.out @@ -1,3 +1,3 @@ -DuplicateErrors.java:34:1: compiler.err.duplicate.annotation.missing.container: Foo, java.lang.annotation.Repeatable -DuplicateErrors.java:35:1: compiler.err.duplicate.annotation.missing.container: Foo, java.lang.annotation.Repeatable +DuplicateErrors.java:34:1: compiler.err.duplicate.annotation.missing.container: Foo +DuplicateErrors.java:35:1: compiler.err.duplicate.annotation.missing.container: Foo 2 errors diff --git a/langtools/test/tools/javac/annotations/repeatingAnnotations/NoRepeatableAnno.out b/langtools/test/tools/javac/annotations/repeatingAnnotations/NoRepeatableAnno.out index 0aa681f92e7..30bc344e0ce 100644 --- a/langtools/test/tools/javac/annotations/repeatingAnnotations/NoRepeatableAnno.out +++ b/langtools/test/tools/javac/annotations/repeatingAnnotations/NoRepeatableAnno.out @@ -1,2 +1,2 @@ -NoRepeatableAnno.java:11:6: compiler.err.duplicate.annotation.missing.container: Foo, java.lang.annotation.Repeatable +NoRepeatableAnno.java:11:6: compiler.err.duplicate.annotation.missing.container: Foo 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/arrays/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/arrays/DuplicateTypeAnnotation.out index 4584096b71c..51dfb4a7f85 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/arrays/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/arrays/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:11:15: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:11:15: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/innertypeparams/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/innertypeparams/DuplicateTypeAnnotation.out index 902ec9e7488..477532697fb 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/innertypeparams/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/innertypeparams/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:11:20: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:11:20: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/newarray/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/newarray/DuplicateTypeAnnotation.out index 4c41849ccd8..e484a6481bb 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/newarray/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/newarray/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:11:32: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:11:32: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/parambounds/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/parambounds/DuplicateTypeAnnotation.out index b657485ff59..3038774b6a8 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/parambounds/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/parambounds/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:9:38: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:9:38: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/receiver/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/receiver/DuplicateTypeAnnotation.out index 2105831a5be..626b6ffb9c9 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/receiver/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/receiver/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:10:16: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:10:16: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/rest/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/rest/DuplicateTypeAnnotation.out index 904f7c119ab..d491572106d 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/rest/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/rest/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:11:12: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:11:12: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/typeArgs/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/typeArgs/DuplicateTypeAnnotation.out index 9dc12fd068f..9ff99f08e88 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/typeArgs/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/typeArgs/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:10:24: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:10:24: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/typeparams/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/typeparams/DuplicateTypeAnnotation.out index fe3d4300bd9..c4eaedaff60 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/typeparams/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/typeparams/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:9:28: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:9:28: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/wildcards/DuplicateTypeAnnotation.out b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/wildcards/DuplicateTypeAnnotation.out index 9dc12fd068f..9ff99f08e88 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/wildcards/DuplicateTypeAnnotation.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/failures/common/wildcards/DuplicateTypeAnnotation.out @@ -1,2 +1,2 @@ -DuplicateTypeAnnotation.java:10:24: compiler.err.duplicate.annotation.missing.container: A, java.lang.annotation.Repeatable +DuplicateTypeAnnotation.java:10:24: compiler.err.duplicate.annotation.missing.container: A 1 error diff --git a/langtools/test/tools/javac/annotations/typeAnnotations/newlocations/RepeatingTypeAnnotations.out b/langtools/test/tools/javac/annotations/typeAnnotations/newlocations/RepeatingTypeAnnotations.out index d914d564aff..20a73852f44 100644 --- a/langtools/test/tools/javac/annotations/typeAnnotations/newlocations/RepeatingTypeAnnotations.out +++ b/langtools/test/tools/javac/annotations/typeAnnotations/newlocations/RepeatingTypeAnnotations.out @@ -1,28 +1,28 @@ -RepeatingTypeAnnotations.java:39:25: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:41:25: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:42:25: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:50:31: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:52:24: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:61:21: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:63:38: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:65:24: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:72:21: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:77:28: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:79:21: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:79:36: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:81:19: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:85:19: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:85:34: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:89:18: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:89:33: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:93:19: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:93:35: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:97:19: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:97:34: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:101:37: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:101:26: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:101:56: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable -RepeatingTypeAnnotations.java:101:72: compiler.err.duplicate.annotation.missing.container: TA, java.lang.annotation.Repeatable +RepeatingTypeAnnotations.java:39:25: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:41:25: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:42:25: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:50:31: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:52:24: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:61:21: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:63:38: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:65:24: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:72:21: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:77:28: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:79:21: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:79:36: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:81:19: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:85:19: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:85:34: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:89:18: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:89:33: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:93:19: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:93:35: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:97:19: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:97:34: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:101:37: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:101:26: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:101:56: compiler.err.duplicate.annotation.missing.container: TA +RepeatingTypeAnnotations.java:101:72: compiler.err.duplicate.annotation.missing.container: TA - compiler.note.unchecked.filename: RepeatingTypeAnnotations.java - compiler.note.unchecked.recompile 25 errors diff --git a/langtools/test/tools/javac/api/T6265137.java b/langtools/test/tools/javac/api/T6265137.java index d29ae4a99e3..fd7f02d3ed3 100644 --- a/langtools/test/tools/javac/api/T6265137.java +++ b/langtools/test/tools/javac/api/T6265137.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -52,7 +52,7 @@ public class T6265137 { String srcdir = System.getProperty("test.src"); Iterable files = fm.getJavaFileObjectsFromFiles(Arrays.asList(new File(srcdir, "T6265137a.java"))); - javac.getTask(null, fm, dl, Arrays.asList("-target","9"), null, files).call(); + javac.getTask(null, fm, dl, Arrays.asList("-target","10"), null, files).call(); } } } diff --git a/langtools/test/tools/javac/api/T6395981.java b/langtools/test/tools/javac/api/T6395981.java index 30cd4cb3475..7ac2a2ce11d 100644 --- a/langtools/test/tools/javac/api/T6395981.java +++ b/langtools/test/tools/javac/api/T6395981.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 6395981 6458819 7025784 8028543 + * @bug 6395981 6458819 7025784 8028543 8028544 * @summary JavaCompilerTool and Tool must specify version of JLS and JVMS * @author Peter von der Ah\u00e9 * @modules java.compiler @@ -31,7 +31,7 @@ * @run main/fail T6395981 * @run main/fail T6395981 RELEASE_3 RELEASE_5 RELEASE_6 * @run main/fail T6395981 RELEASE_0 RELEASE_1 RELEASE_2 RELEASE_3 RELEASE_4 RELEASE_5 RELEASE_6 - * @run main T6395981 RELEASE_3 RELEASE_4 RELEASE_5 RELEASE_6 RELEASE_7 RELEASE_8 RELEASE_9 + * @run main T6395981 RELEASE_3 RELEASE_4 RELEASE_5 RELEASE_6 RELEASE_7 RELEASE_8 RELEASE_9 RELEASE_10 */ import java.util.EnumSet; diff --git a/langtools/test/tools/javac/api/TestClientCodeWrapper.java b/langtools/test/tools/javac/api/TestClientCodeWrapper.java index 177e621f96a..1314c37493d 100644 --- a/langtools/test/tools/javac/api/TestClientCodeWrapper.java +++ b/langtools/test/tools/javac/api/TestClientCodeWrapper.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -62,7 +62,7 @@ public class TestClientCodeWrapper extends JavacTestingAbstractProcessor { defaultFileManager = fm; for (Method m: getMethodsExcept(JavaFileManager.class, - "close", "getJavaFileForInput", "getLocationForModule", "getServiceLoader")) { + "close", "getJavaFileForInput", "getLocationForModule", "getServiceLoader", "contains")) { test(m); } @@ -407,9 +407,9 @@ public class TestClientCodeWrapper extends JavacTestingAbstractProcessor { } @Override - public Location getLocationForModule(Location location, JavaFileObject fo, String pkgName) throws IOException { + public Location getLocationForModule(Location location, JavaFileObject fo) throws IOException { throwUserExceptionIfNeeded(fileManagerMethod, "getLocationForModule"); - return super.getLocationForModule(location, fo, pkgName); + return super.getLocationForModule(location, fo); } @Override @@ -424,6 +424,12 @@ public class TestClientCodeWrapper extends JavacTestingAbstractProcessor { return super.listLocationsForModules(location); } + @Override + public boolean contains(Location location, FileObject fo) throws IOException { + throwUserExceptionIfNeeded(fileManagerMethod, "contains"); + return super.contains(location, fo); + } + public FileObject wrap(FileObject fo) { if (fileObjectMethod == null || fo == null) return fo; diff --git a/langtools/test/tools/javac/classreader/8171132/BadConstantValue.java b/langtools/test/tools/javac/classreader/8171132/BadConstantValue.java index aa2cdac6501..b49e0889475 100644 --- a/langtools/test/tools/javac/classreader/8171132/BadConstantValue.java +++ b/langtools/test/tools/javac/classreader/8171132/BadConstantValue.java @@ -17,6 +17,10 @@ * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. */ /* diff --git a/langtools/test/tools/javac/defaultMethods/private/PrivateInterfaceMethodProcessorTest.java b/langtools/test/tools/javac/defaultMethods/private/PrivateInterfaceMethodProcessorTest.java new file mode 100644 index 00000000000..f842213fe86 --- /dev/null +++ b/langtools/test/tools/javac/defaultMethods/private/PrivateInterfaceMethodProcessorTest.java @@ -0,0 +1,58 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8175184 + * @summary Annotation processor observes interface private methods as default methods + * @library /tools/javac/lib + * @modules java.compiler + * jdk.compiler + * @build JavacTestingAbstractProcessor PrivateInterfaceMethodProcessorTest + * @compile/process -processor PrivateInterfaceMethodProcessorTest -proc:only PrivateInterfaceMethodProcessorTest_I + */ + +import java.util.Set; +import javax.annotation.processing.*; +import javax.lang.model.element.*; +import static javax.lang.model.util.ElementFilter.*; + +interface PrivateInterfaceMethodProcessorTest_I { + private void foo() {} +} + +public class PrivateInterfaceMethodProcessorTest extends JavacTestingAbstractProcessor { + public boolean process(Set annotations, + RoundEnvironment roundEnv) { + if (!roundEnv.processingOver()) { + for (Element element : roundEnv.getRootElements()) { + for (ExecutableElement method : methodsIn(element.getEnclosedElements())) { + if (method.isDefault()) { + throw new AssertionError("Unexpected default method seen"); + } + } + } + } + return true; + } +} \ No newline at end of file diff --git a/langtools/test/tools/javac/diags/CheckExamples.java b/langtools/test/tools/javac/diags/CheckExamples.java index 0e52111d673..f27aca40ec5 100644 --- a/langtools/test/tools/javac/diags/CheckExamples.java +++ b/langtools/test/tools/javac/diags/CheckExamples.java @@ -39,8 +39,6 @@ */ import java.io.*; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.nio.file.*; import java.nio.file.attribute.BasicFileAttributes; import java.util.*; @@ -111,7 +109,7 @@ public class CheckExamples { } } - Module jdk_compiler = Layer.boot().findModule("jdk.compiler").get(); + Module jdk_compiler = ModuleLayer.boot().findModule("jdk.compiler").get(); ResourceBundle b = ResourceBundle.getBundle("com.sun.tools.javac.resources.compiler", jdk_compiler); Set resourceKeys = new TreeSet(b.keySet()); diff --git a/langtools/test/tools/javac/diags/CheckResourceKeys.java b/langtools/test/tools/javac/diags/CheckResourceKeys.java index 7178856cf3d..9ebe1f961fd 100644 --- a/langtools/test/tools/javac/diags/CheckResourceKeys.java +++ b/langtools/test/tools/javac/diags/CheckResourceKeys.java @@ -31,8 +31,6 @@ */ import java.io.*; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.*; import javax.tools.*; import com.sun.tools.classfile.*; @@ -395,7 +393,7 @@ public class CheckResourceKeys { * Get the set of keys from the javac resource bundles. */ Set getResourceKeys() { - Module jdk_compiler = Layer.boot().findModule("jdk.compiler").get(); + Module jdk_compiler = ModuleLayer.boot().findModule("jdk.compiler").get(); Set results = new TreeSet(); for (String name : new String[]{"javac", "compiler"}) { ResourceBundle b = diff --git a/langtools/test/tools/javac/diags/Example.java b/langtools/test/tools/javac/diags/Example.java index 72c4b64e382..8cadd96a4c3 100644 --- a/langtools/test/tools/javac/diags/Example.java +++ b/langtools/test/tools/javac/diags/Example.java @@ -24,8 +24,18 @@ import java.io.*; import java.net.URL; import java.net.URLClassLoader; +import java.nio.file.Files; +import java.nio.file.Path; import java.util.*; +import java.util.Map.Entry; +import java.util.jar.JarFile; +import java.util.jar.JarOutputStream; +import java.util.logging.Level; +import java.util.logging.Logger; import java.util.regex.*; +import java.util.stream.Collectors; +import java.util.zip.ZipEntry; + import javax.annotation.processing.Processor; import javax.tools.Diagnostic; import javax.tools.DiagnosticCollector; @@ -63,6 +73,7 @@ class Example implements Comparable { procFiles = new ArrayList(); srcPathFiles = new ArrayList(); moduleSourcePathFiles = new ArrayList(); + patchModulePathFiles = new ArrayList(); modulePathFiles = new ArrayList(); classPathFiles = new ArrayList(); additionalFiles = new ArrayList(); @@ -88,6 +99,9 @@ class Example implements Comparable { } else if (files == srcFiles && c.getName().equals("modulesourcepath")) { moduleSourcePathDir = c; findFiles(c, moduleSourcePathFiles); + } else if (files == srcFiles && c.getName().equals("patchmodule")) { + patchModulePathDir = c; + findFiles(c, patchModulePathFiles); } else if (files == srcFiles && c.getName().equals("additional")) { additionalFilesDir = c; findFiles(c, additionalFiles); @@ -206,9 +220,53 @@ class Example implements Comparable { File modulepathDir = new File(tempDir, "modulepath"); modulepathDir.mkdirs(); clean(modulepathDir); - List sOpts = Arrays.asList("-d", modulepathDir.getPath(), - "--module-source-path", new File(file, "modulepath").getAbsolutePath()); - new Jsr199Compiler(verbose).run(null, null, false, sOpts, modulePathFiles); + boolean hasModuleInfo = + modulePathFiles.stream() + .anyMatch(f -> f.getName().equalsIgnoreCase("module-info.java")); + Path modulePath = new File(file, "modulepath").toPath().toAbsolutePath(); + if (hasModuleInfo) { + //ordinary modules + List sOpts = + Arrays.asList("-d", modulepathDir.getPath(), + "--module-source-path", modulePath.toString()); + new Jsr199Compiler(verbose).run(null, null, false, sOpts, modulePathFiles); + } else { + //automatic modules: + Map> module2Files = + modulePathFiles.stream() + .map(f -> f.toPath()) + .collect(Collectors.groupingBy(p -> modulePath.relativize(p) + .getName(0) + .toString())); + for (Entry> e : module2Files.entrySet()) { + File scratchDir = new File(tempDir, "scratch"); + scratchDir.mkdirs(); + clean(scratchDir); + List sOpts = + Arrays.asList("-d", scratchDir.getPath()); + new Jsr199Compiler(verbose).run(null, + null, + false, + sOpts, + e.getValue().stream() + .map(p -> p.toFile()) + .collect(Collectors.toList())); + try (JarOutputStream jarOut = + new JarOutputStream(new FileOutputStream(new File(modulepathDir, e.getKey() + ".jar")))) { + Files.find(scratchDir.toPath(), Integer.MAX_VALUE, (p, attr) -> attr.isRegularFile()) + .forEach(p -> { + try (InputStream in = Files.newInputStream(p)) { + jarOut.putNextEntry(new ZipEntry(scratchDir.toPath() + .relativize(p) + .toString())); + jarOut.write(in.readAllBytes()); + } catch (IOException ex) { + throw new IllegalStateException(ex); + } + }); + } + } + } opts.add("--module-path"); opts.add(modulepathDir.getAbsolutePath()); } @@ -272,6 +330,16 @@ class Example implements Comparable { files.addAll(nonEmptySrcFiles); // srcFiles containing declarations } + if (patchModulePathDir != null) { + for (File mod : patchModulePathDir.listFiles()) { + opts.add("--patch-module"); + opts.add(mod.getName() + "=" + mod.getPath()); + } + files = new ArrayList<>(); + files.addAll(patchModulePathFiles); + files.addAll(nonEmptySrcFiles); // srcFiles containing declarations + } + if (additionalFiles.size() > 0) { List sOpts = Arrays.asList("-d", classesDir.getPath()); new Jsr199Compiler(verbose).run(null, null, false, sOpts, additionalFiles); @@ -343,9 +411,11 @@ class Example implements Comparable { List procFiles; File srcPathDir; File moduleSourcePathDir; + File patchModulePathDir; File additionalFilesDir; List srcPathFiles; List moduleSourcePathFiles; + List patchModulePathFiles; List modulePathFiles; List classPathFiles; List additionalFiles; diff --git a/langtools/test/tools/javac/diags/examples.not-yet.txt b/langtools/test/tools/javac/diags/examples.not-yet.txt index 5f88b42c880..850d300d8f7 100644 --- a/langtools/test/tools/javac/diags/examples.not-yet.txt +++ b/langtools/test/tools/javac/diags/examples.not-yet.txt @@ -1,10 +1,11 @@ compiler.err.already.annotated # internal compiler error? compiler.err.already.defined.this.unit # seems to be masked by compiler.err.duplicate.class -compiler.err.annotation.value.not.allowable.type # cannot happen: precluded by complete type-specific tests compiler.err.bad.functional.intf.anno # seems to be masked by compiler.err.annotation.type.not.applicable +compiler.err.annotation.value.not.allowable.type # should be detected in advance by the annotation value visitor compiler.err.cant.read.file # (apt.JavaCompiler?) compiler.err.cant.select.static.class.from.param.type compiler.err.dc.unterminated.string # cannot happen +compiler.err.file.patched.and.msp # needs the same dir on --module-source-path and --patch-module compiler.err.illegal.char.for.encoding compiler.err.invalid.repeatable.annotation # should not happen compiler.err.invalid.repeatable.annotation.invalid.value # "can't" happen @@ -55,6 +56,7 @@ compiler.misc.bad.type.annotation.value compiler.misc.base.membership # UNUSED compiler.misc.class.file.not.found # ClassReader compiler.misc.class.file.wrong.class +compiler.misc.exception.message # uncommon completion failure based on a string compiler.misc.fatal.err.cant.locate.ctor # Resolve, from Lower compiler.misc.fatal.err.cant.locate.field # Resolve, from Lower compiler.misc.fatal.err.cant.locate.meth # Resolve, from Lower @@ -93,6 +95,7 @@ compiler.misc.type.req.exact compiler.misc.unable.to.access.file # ClassFile compiler.misc.undecl.type.var # ClassReader compiler.misc.unicode.str.not.supported # ClassReader +compiler.misc.user.selected.completion.failure # manual completion failure compiler.misc.malformed.vararg.method # ClassReader compiler.misc.version.not.available # JavaCompiler; implies build error compiler.misc.where.description.captured diff --git a/langtools/test/tools/javac/diags/examples/ModuleInfoWithXModuleSourcePath/Extra.java b/langtools/test/tools/javac/diags/examples/AddExportsWithRelease.java similarity index 81% rename from langtools/test/tools/javac/diags/examples/ModuleInfoWithXModuleSourcePath/Extra.java rename to langtools/test/tools/javac/diags/examples/AddExportsWithRelease.java index cafc425479d..52d8c56e6ac 100644 --- a/langtools/test/tools/javac/diags/examples/ModuleInfoWithXModuleSourcePath/Extra.java +++ b/langtools/test/tools/javac/diags/examples/AddExportsWithRelease.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,9 +21,8 @@ * questions. */ -// key: compiler.err.module-info.with.xmodule.sourcepath -// options: -Xmodule:java.compiler +// key: compiler.err.add.exports.with.release +// options: --add-exports java.base/jdk.internal.misc=ALL-UNNAMED --release 9 -package javax.lang.model.element; - -public interface Extra {} +class AddExportsWithRelease { +} diff --git a/langtools/test/tools/javac/diags/examples/AddReadsWithRelease.java b/langtools/test/tools/javac/diags/examples/AddReadsWithRelease.java new file mode 100644 index 00000000000..3695353fa11 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/AddReadsWithRelease.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +// key: compiler.err.add.reads.with.release +// options: --add-reads java.base=java.compiler --release 9 + +class AddReadsWithRelease { +} diff --git a/langtools/test/tools/javac/diags/examples/AnnoValueMustBeClassLiteral.java b/langtools/test/tools/javac/diags/examples/AnnoValueMustBeClassLiteral.java index e36d7b46277..8dce57887fe 100644 --- a/langtools/test/tools/javac/diags/examples/AnnoValueMustBeClassLiteral.java +++ b/langtools/test/tools/javac/diags/examples/AnnoValueMustBeClassLiteral.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,7 @@ * questions. */ -// key: compiler.err.annotation.value.must.be.class.literal +// key: compiler.err.expression.not.allowable.as.annotation.value @interface Anno { Class value(); diff --git a/langtools/test/tools/javac/diags/examples/AnnotationMustBeConstant.java b/langtools/test/tools/javac/diags/examples/AnnotationMustBeConstant.java new file mode 100644 index 00000000000..b9b9fcda2e9 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/AnnotationMustBeConstant.java @@ -0,0 +1,37 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +// key: compiler.err.expression.not.allowable.as.annotation.value + +import java.util.function.*; + +@interface Anno { + String value(); +} + +@Anno(value = AnnotationMustBeConstant.m(x -> x)) +class AnnotationMustBeConstant { + static String m(Function f) { + return null; + } +} diff --git a/jdk/test/java/io/Serializable/serialver/classpath/Test.java b/langtools/test/tools/javac/diags/examples/AnnotationMustBeConstant2.java similarity index 80% rename from jdk/test/java/io/Serializable/serialver/classpath/Test.java rename to langtools/test/tools/javac/diags/examples/AnnotationMustBeConstant2.java index 3568a59d52b..954606615d0 100644 --- a/jdk/test/java/io/Serializable/serialver/classpath/Test.java +++ b/langtools/test/tools/javac/diags/examples/AnnotationMustBeConstant2.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,15 +21,13 @@ * questions. */ -/* - * - * @bug 4035147 - * @sumary Simple java class for test purposes - */ +// key: compiler.err.attribute.value.must.be.constant -package serialver; - -public class Test implements java.io.Serializable{ - int a; - int b; +@T(a = AnnotationMustBeConstant2.x) +@interface T { + int a(); +} + +class AnnotationMustBeConstant2 { + static int x; } diff --git a/langtools/test/tools/javac/diags/examples/AttrMustBeConstant.java b/langtools/test/tools/javac/diags/examples/AttrMustBeConstant.java index 5156fdf15ff..76305a7b932 100644 --- a/langtools/test/tools/javac/diags/examples/AttrMustBeConstant.java +++ b/langtools/test/tools/javac/diags/examples/AttrMustBeConstant.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,7 @@ * questions. */ -// key: compiler.err.attribute.value.must.be.constant +// key: compiler.err.expression.not.allowable.as.annotation.value @interface Anno { String value(); diff --git a/langtools/test/tools/javac/diags/examples/EnumAnnoValueMustBeEnumConst.java b/langtools/test/tools/javac/diags/examples/EnumAnnoValueMustBeEnumConst.java index ca7b5e39f3a..16ecfc2fde7 100644 --- a/langtools/test/tools/javac/diags/examples/EnumAnnoValueMustBeEnumConst.java +++ b/langtools/test/tools/javac/diags/examples/EnumAnnoValueMustBeEnumConst.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,7 @@ * questions. */ -// key: compiler.err.enum.annotation.must.be.enum.constant +// key: compiler.err.expression.not.allowable.as.annotation.value enum E { A, B, C } diff --git a/langtools/test/tools/javac/diags/examples/EnumAnnoValueMustBeEnumConst2.java b/langtools/test/tools/javac/diags/examples/EnumAnnoValueMustBeEnumConst2.java new file mode 100644 index 00000000000..e7e02c4539e --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/EnumAnnoValueMustBeEnumConst2.java @@ -0,0 +1,38 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +// key: compiler.err.enum.annotation.must.be.enum.constant + +enum E { + A, + B; + + public static final E e = A; +} + +@interface Anno { + E value(); +} + +@Anno(E.e) +class EnumAnnoValueMustBeEnumConstant { } diff --git a/langtools/test/tools/javac/diags/examples/FileShouldBeOnSourcePathOrPatchPath/FileShouldBeOnSourcePathOrModulePath.java b/langtools/test/tools/javac/diags/examples/FileShouldBeOnSourcePathOrPatchPath/FileShouldBeOnSourcePathOrModulePath.java new file mode 100644 index 00000000000..52b1e4dd16d --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/FileShouldBeOnSourcePathOrPatchPath/FileShouldBeOnSourcePathOrModulePath.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +//key: compiler.err.file.sb.on.source.or.patch.path.for.module + +public class FileShouldBeOnSourcePathOrModulePath { +} + diff --git a/langtools/test/tools/javac/diags/examples/ModuleInfoWithXmoduleClasspath/additional/module-info.java b/langtools/test/tools/javac/diags/examples/FileShouldBeOnSourcePathOrPatchPath/sourcepath/module-info.java similarity index 92% rename from langtools/test/tools/javac/diags/examples/ModuleInfoWithXmoduleClasspath/additional/module-info.java rename to langtools/test/tools/javac/diags/examples/FileShouldBeOnSourcePathOrPatchPath/sourcepath/module-info.java index 6faf7dbee92..c63ed483f51 100644 --- a/langtools/test/tools/javac/diags/examples/ModuleInfoWithXmoduleClasspath/additional/module-info.java +++ b/langtools/test/tools/javac/diags/examples/FileShouldBeOnSourcePathOrPatchPath/sourcepath/module-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,4 +21,5 @@ * questions. */ -module mod {} +module m { } + diff --git a/langtools/test/tools/javac/diags/examples/IllegalArgumentForOption/IllegalArgumentForOption.java b/langtools/test/tools/javac/diags/examples/IllegalArgumentForOption/IllegalArgumentForOption.java index 90c2c1fb79b..429fe7ed3e1 100644 --- a/langtools/test/tools/javac/diags/examples/IllegalArgumentForOption/IllegalArgumentForOption.java +++ b/langtools/test/tools/javac/diags/examples/IllegalArgumentForOption/IllegalArgumentForOption.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,7 +22,7 @@ */ // key: compiler.err.illegal.argument.for.option -// options: --module-path doesNotExist +// options: --module-source-path=abc*def // run: simple class X {} diff --git a/langtools/test/tools/javac/diags/examples/ModuleInfoWithXmoduleClasspath/ModuleInfoWithXmoduleClasspath.java b/langtools/test/tools/javac/diags/examples/ModuleInfoWithXmoduleClasspath/ModuleInfoWithXmoduleClasspath.java deleted file mode 100644 index a9ea8197d3b..00000000000 --- a/langtools/test/tools/javac/diags/examples/ModuleInfoWithXmoduleClasspath/ModuleInfoWithXmoduleClasspath.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -// key: compiler.err.module-info.with.xmodule.classpath -// options: -Xmodule:java.compiler - -package javax.lang.model.element; - -public interface ModuleInfoWithXModuleClasspath {} diff --git a/langtools/test/tools/javac/diags/examples/NoJavaLang.java b/langtools/test/tools/javac/diags/examples/NoJavaLang.java index 50258746972..330243dbc96 100644 --- a/langtools/test/tools/javac/diags/examples/NoJavaLang.java +++ b/langtools/test/tools/javac/diags/examples/NoJavaLang.java @@ -22,7 +22,7 @@ */ // key: compiler.misc.fatal.err.no.java.lang -// options: -source 8 -target 8 -Xbootclasspath: +// options: -source 8 -target 8 -Xbootclasspath: -classpath . // run: backdoor class NoJavaLang { } diff --git a/langtools/test/tools/javac/diags/examples/NoSuperclass.java b/langtools/test/tools/javac/diags/examples/NoSuperclass/NoSuperclass.java similarity index 85% rename from langtools/test/tools/javac/diags/examples/NoSuperclass.java rename to langtools/test/tools/javac/diags/examples/NoSuperclass/NoSuperclass.java index 9e86e1872e0..9fcc9076124 100644 --- a/langtools/test/tools/javac/diags/examples/NoSuperclass.java +++ b/langtools/test/tools/javac/diags/examples/NoSuperclass/NoSuperclass.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -22,12 +22,3 @@ */ // key: compiler.err.no.superclass -// options: -Xmodule:java.base - -package java.lang; - -class Object { - public Object() { - super(); - } -} diff --git a/langtools/test/tools/javac/diags/examples/NoSuperclass/patchmodule/java.base/java/lang/Object.java b/langtools/test/tools/javac/diags/examples/NoSuperclass/patchmodule/java.base/java/lang/Object.java new file mode 100644 index 00000000000..c42ff757105 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/NoSuperclass/patchmodule/java.base/java/lang/Object.java @@ -0,0 +1,30 @@ +/* + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package java.lang; + +class Object { + public Object() { + super(); + } +} diff --git a/langtools/test/tools/javac/diags/examples/PatchModuleWithRelease/PatchModuleWithRelease.java b/langtools/test/tools/javac/diags/examples/PatchModuleWithRelease/PatchModuleWithRelease.java new file mode 100644 index 00000000000..6f1b11e4bba --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/PatchModuleWithRelease/PatchModuleWithRelease.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +// key: compiler.err.patch.module.with.release +// options: --release 9 + +class PatchModuleWithRelease { +} diff --git a/langtools/test/tools/javac/diags/examples/PatchModuleWithRelease/patchmodule/java.base/java/lang/Test.java b/langtools/test/tools/javac/diags/examples/PatchModuleWithRelease/patchmodule/java.base/java/lang/Test.java new file mode 100644 index 00000000000..4c2f374a486 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/PatchModuleWithRelease/patchmodule/java.base/java/lang/Test.java @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package java.lang; + +class Test { +} diff --git a/langtools/test/tools/javac/diags/examples/RequiresAutomatic/module-info.java b/langtools/test/tools/javac/diags/examples/RequiresAutomatic/module-info.java new file mode 100644 index 00000000000..349b4f57dbf --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/RequiresAutomatic/module-info.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +//options: -Xlint:requires-automatic +//key: compiler.warn.requires.automatic +module RequiresAutomatic { + requires a; +} diff --git a/langtools/test/tools/javac/diags/examples/ModuleInfoWithXModuleSourcePath/module-info.java b/langtools/test/tools/javac/diags/examples/RequiresAutomatic/modulepath/a/A.java similarity index 91% rename from langtools/test/tools/javac/diags/examples/ModuleInfoWithXModuleSourcePath/module-info.java rename to langtools/test/tools/javac/diags/examples/RequiresAutomatic/modulepath/a/A.java index 79715268b7a..45d652e3604 100644 --- a/langtools/test/tools/javac/diags/examples/ModuleInfoWithXModuleSourcePath/module-info.java +++ b/langtools/test/tools/javac/diags/examples/RequiresAutomatic/modulepath/a/A.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,4 +21,4 @@ * questions. */ -module java.compiler {} +public class A {} diff --git a/langtools/test/tools/javac/diags/examples/RequiresTransitiveAutomatic/module-info.java b/langtools/test/tools/javac/diags/examples/RequiresTransitiveAutomatic/module-info.java new file mode 100644 index 00000000000..99948503a08 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/RequiresTransitiveAutomatic/module-info.java @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +//key: compiler.warn.requires.transitive.automatic +module RequiresTransitiveAutomatic { + requires transitive a; +} diff --git a/langtools/test/tools/javac/diags/examples/RequiresTransitiveAutomatic/modulepath/a/A.java b/langtools/test/tools/javac/diags/examples/RequiresTransitiveAutomatic/modulepath/a/A.java new file mode 100644 index 00000000000..45d652e3604 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/RequiresTransitiveAutomatic/modulepath/a/A.java @@ -0,0 +1,24 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +public class A {} diff --git a/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/ServiceImplNotPublic.java b/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/ServiceImplNotPublic.java new file mode 100644 index 00000000000..e7bdcd80fc6 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/ServiceImplNotPublic.java @@ -0,0 +1,24 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +// key: compiler.err.not.def.public diff --git a/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/example/ServiceImpl.java b/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/example/ServiceImpl.java new file mode 100644 index 00000000000..cb1b3b1b184 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/example/ServiceImpl.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package example; +class ServiceImpl implements example.SomeService { + public ServiceImpl() {} + public void foo() {} +} diff --git a/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/example/SomeService.java b/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/example/SomeService.java new file mode 100644 index 00000000000..f39627f3874 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/example/SomeService.java @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package example; +public interface SomeService { + public void foo(); +} diff --git a/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/module-info.java b/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/module-info.java new file mode 100644 index 00000000000..ec6405d3a12 --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/ServiceImplNotPublic/module-info.java @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +module m { + exports example; + provides example.SomeService with example.ServiceImpl; +} diff --git a/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/TooManyPatchedModules.java b/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/TooManyPatchedModules.java new file mode 100644 index 00000000000..f7bb6eee1ff --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/TooManyPatchedModules.java @@ -0,0 +1,24 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +// key: compiler.err.too.many.patched.modules diff --git a/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/patchmodule/java.compiler/p/C.java b/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/patchmodule/java.compiler/p/C.java new file mode 100644 index 00000000000..a92294c7deb --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/patchmodule/java.compiler/p/C.java @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +package p; + +class C {} diff --git a/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/patchmodule/jdk.compiler/p/C.java b/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/patchmodule/jdk.compiler/p/C.java new file mode 100644 index 00000000000..a92294c7deb --- /dev/null +++ b/langtools/test/tools/javac/diags/examples/TooManyPatchedModules/patchmodule/jdk.compiler/p/C.java @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +package p; + +class C {} diff --git a/langtools/test/tools/javac/doclint/NPEDuplicateClassNamesTest.java b/langtools/test/tools/javac/doclint/NPEDuplicateClassNamesTest.java new file mode 100644 index 00000000000..f55bf904952 --- /dev/null +++ b/langtools/test/tools/javac/doclint/NPEDuplicateClassNamesTest.java @@ -0,0 +1,97 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8174073 + * @summary NPE caused by link reference to class + * @modules jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library /tools/lib + * @build toolbox.JavacTask toolbox.TestRunner toolbox.ToolBox + * @run main NPEDuplicateClassNamesTest + */ + +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.Arrays; +import java.util.List; +import java.util.Objects; + +import toolbox.JavacTask; +import toolbox.Task; +import toolbox.TestRunner; +import toolbox.ToolBox; + +public class NPEDuplicateClassNamesTest extends TestRunner { + + public static void main(String... args) throws Exception { + NPEDuplicateClassNamesTest t = new NPEDuplicateClassNamesTest(); + t.runTests(); + } + + private final ToolBox tb = new ToolBox(); + private final String class1 = + "package com;\n" + + "/***/\n" + + "public class MyClass {}"; + private final String class2 = + "package com;\n" + + "/**\n" + + " * The following link tag causes a NullPointerException: {@link Requirements}. \n" + + " */\n" + + "public class MyClass {}"; + + NPEDuplicateClassNamesTest() throws IOException { + super(System.err); + } + + @Test + public void testDuplicateClassNames() throws IOException { + Path src = Paths.get("src"); + Path one = src.resolve("one"); + Path two = src.resolve("two"); + Path classes = Paths.get("classes"); + Files.createDirectories(classes); + tb.writeJavaFiles(one, class1); + tb.writeJavaFiles(two, class2); + + List expected = Arrays.asList( + "MyClass.java:5:8: compiler.err.duplicate.class: com.MyClass", + "MyClass.java:3:65: compiler.err.proc.messager: reference not found", + "2 errors"); + List output = new JavacTask(tb) + .outdir(classes) + .options("-XDrawDiagnostics", "-Xdoclint:all", "-XDdev") + .files(tb.findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!Objects.equals(output, expected)) { + throw new IllegalStateException("incorrect output; actual=" + output + "; expected=" + expected); + } + } +} diff --git a/langtools/test/tools/javac/fatalErrors/NoJavaLangTest.java b/langtools/test/tools/javac/fatalErrors/NoJavaLangTest.java index 6b93de44682..b200c4c0719 100644 --- a/langtools/test/tools/javac/fatalErrors/NoJavaLangTest.java +++ b/langtools/test/tools/javac/fatalErrors/NoJavaLangTest.java @@ -74,7 +74,7 @@ public class NoJavaLangTest { // test with bootclasspath, for as long as its around void testBootClassPath() { - String[] bcpOpts = { "-Xlint:-options", "-source", "8", "-bootclasspath", "." }; + String[] bcpOpts = { "-Xlint:-options", "-source", "8", "-bootclasspath", ".", "-classpath", "." }; test(bcpOpts, compilerErrorMessage); } diff --git a/langtools/test/tools/javac/file/ModuleAndPackageLocations.java b/langtools/test/tools/javac/file/ModuleAndPackageLocations.java index 5bd26779e8d..8c194253c40 100644 --- a/langtools/test/tools/javac/file/ModuleAndPackageLocations.java +++ b/langtools/test/tools/javac/file/ModuleAndPackageLocations.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /** * @test - * @bug 8171005 + * @bug 8171005 8175560 * @summary Verify behavior of JavaFileManager methods w.r.t. module/package oriented locations * @library /tools/lib * @modules java.compiler @@ -99,7 +99,7 @@ public class ModuleAndPackageLocations extends TestRunner { Location cOutput = fm.getLocationForModule(StandardLocation.SOURCE_OUTPUT, "c"); JavaFileObject testFO = fm.getJavaFileForOutput(cOutput, "test.Test", Kind.CLASS, null); testFO.openOutputStream().close(); - Location cOutput2 = fm.getLocationForModule(StandardLocation.SOURCE_OUTPUT, testFO, "test"); + Location cOutput2 = fm.getLocationForModule(StandardLocation.SOURCE_OUTPUT, testFO); if (cOutput != cOutput2) { throw new AssertionError("Unexpected location: " + cOutput2 + ", expected: " +cOutput); @@ -117,7 +117,6 @@ public class ModuleAndPackageLocations extends TestRunner { assertRefused(() -> fm.getJavaFileForOutput(StandardLocation.MODULE_SOURCE_PATH, "", Kind.SOURCE, null)); assertRefused(() -> fm.getLocationForModule(StandardLocation.SOURCE_PATH, "test")); JavaFileObject out = fm.getJavaFileForInput(StandardLocation.CLASS_OUTPUT, "test.Test", Kind.CLASS); - assertRefused(() -> fm.getLocationForModule(StandardLocation.SOURCE_PATH, out, "test")); assertRefused(() -> fm.inferBinaryName(StandardLocation.MODULE_PATH, out)); assertRefused(() -> fm.inferModuleName(StandardLocation.MODULE_SOURCE_PATH)); assertRefused(() -> fm.list(StandardLocation.MODULE_SOURCE_PATH, "test", EnumSet.allOf(Kind.class), false)); @@ -131,10 +130,10 @@ public class ModuleAndPackageLocations extends TestRunner { Path msp1 = msp.resolve("1"); Path msp2 = msp.resolve("2"); - Files.createDirectories(msp1.resolve("a")); + touch(msp1.resolve("a/module-info.java")); Files.createDirectories(msp1.resolve("b")); - Files.createDirectories(msp2.resolve("b")); - Files.createDirectories(msp2.resolve("c")); + touch(msp2.resolve("b/module-info.java")); + touch(msp2.resolve("c/module-info.java")); Path mp = base.resolve("mp"); Path mp1 = mp.resolve("1"); @@ -210,4 +209,4 @@ public class ModuleAndPackageLocations extends TestRunner { } JavaCompiler compiler = ToolProvider.getSystemJavaCompiler(); -} \ No newline at end of file +} diff --git a/langtools/test/tools/javac/file/SetLocationForModule.java b/langtools/test/tools/javac/file/SetLocationForModule.java new file mode 100644 index 00000000000..02483c990d1 --- /dev/null +++ b/langtools/test/tools/javac/file/SetLocationForModule.java @@ -0,0 +1,328 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8173914 + * @summary JavaFileManager.setLocationForModule + * @modules jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @library /tools/lib + * @build toolbox.JavacTask toolbox.TestRunner toolbox.ToolBox SetLocationForModule + * @run main SetLocationForModule + */ + + +import java.io.FileNotFoundException; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Objects; + +import javax.tools.JavaCompiler; +import javax.tools.JavaFileManager.Location; +import javax.tools.StandardJavaFileManager; +import javax.tools.StandardLocation; +import javax.tools.ToolProvider; + +import toolbox.JavacTask; +import toolbox.TestRunner; +import toolbox.TestRunner.Test; +import toolbox.ToolBox; + +public class SetLocationForModule extends TestRunner { + + public static void main(String... args) throws Exception { + new SetLocationForModule().runTests(m -> new Object[] { Paths.get(m.getName()) }); + } + + public SetLocationForModule() { + super(System.err); + } + + private final JavaCompiler comp = ToolProvider.getSystemJavaCompiler(); + private final ToolBox tb = new ToolBox(); + + @Test + public void testBasic(Path base) throws IOException { + try (StandardJavaFileManager fm = comp.getStandardFileManager(null, null, null)) { + Location[] locns = { + StandardLocation.SOURCE_PATH, + StandardLocation.CLASS_PATH, + StandardLocation.PLATFORM_CLASS_PATH, + }; + // set a value + Path out = Files.createDirectories(base.resolve("out")); + for (Location locn : locns) { + checkException("unsupported for location", + IllegalArgumentException.class, + "location is not an output location or a module-oriented location: " + locn, + () -> fm.setLocationForModule(locn, "m", List.of(out))); + } + } + } + + @Test + public void testModulePath(Path base) throws IOException { + try (StandardJavaFileManager fm = comp.getStandardFileManager(null, null, null)) { + Path src = base.resolve("src"); + Path src_m = src.resolve("m"); + tb.writeJavaFiles(src_m, "module m { }"); + + Location locn = StandardLocation.MODULE_PATH; + + Path modules1 = Files.createDirectories(base.resolve("modules1")); + new JavacTask(tb) + .outdir(modules1) + .options("--module-source-path", src.toString()) + .files(tb.findJavaFiles(src)) + .run(); + fm.setLocationFromPaths(locn, List.of(modules1)); + + Location m = fm.getLocationForModule(locn, "m"); + checkEqual("default setting", + fm.getLocationAsPaths(m), modules1.resolve("m")); + + Path override1 = Files.createDirectories(base.resolve("override1")); + fm.setLocationForModule(locn, "m", List.of(override1)); + checkEqual("override setting 1", + fm.getLocationAsPaths(m), override1); + + Path override2 = Files.createDirectories(base.resolve("override2")); + fm.setLocationFromPaths(m, List.of(override2)); + checkEqual("override setting 2", + fm.getLocationAsPaths(m), override2); + + Path modules2 = Files.createDirectories(base.resolve("modules2")); + fm.setLocationFromPaths(locn, List.of(modules2)); + + checkEqual("updated setting", + fm.getLocationAsPaths(m), modules2.resolve("m")); + } + } + + @Test + public void testModuleSourcePath(Path base) throws IOException { + try (StandardJavaFileManager fm = comp.getStandardFileManager(null, null, null)) { + + Location locn = StandardLocation.MODULE_SOURCE_PATH; + + Path src1 = Files.createDirectories(base.resolve("src1")); + Path src1_m = src1.resolve("m"); + tb.writeJavaFiles(src1_m, "module m { }"); +// fm.setLocationFromPaths(locn, List.of(src1)); + fm.handleOption("--module-source-path", List.of(src1.toString()).iterator()); + + Location m = fm.getLocationForModule(locn, "m"); + checkEqual("default setting", + fm.getLocationAsPaths(m), src1.resolve("m")); + + Path override1 = Files.createDirectories(base.resolve("override1")); + tb.writeJavaFiles(override1, "module m { }"); + fm.setLocationForModule(locn, "m", List.of(override1)); + checkEqual("override setting 1", + fm.getLocationAsPaths(m), override1); + + Path override2 = Files.createDirectories(base.resolve("override2")); + tb.writeJavaFiles(override2, "module m { }"); + fm.setLocationFromPaths(m, List.of(override2)); + checkEqual("override setting 2", + fm.getLocationAsPaths(m), override2); + + Path src2 = Files.createDirectories(base.resolve("src2")); + Path src2_m = src2.resolve("m"); + tb.writeJavaFiles(src2_m, "module m { }"); +// fm.setLocationFromPaths(locn, List.of(src2)); + fm.handleOption("--module-source-path", List.of(src2.toString()).iterator()); + + checkEqual("updated setting", + fm.getLocationAsPaths(m), src2.resolve("m")); + } + } + + @Test + public void testOutput(Path base) throws IOException { + try (StandardJavaFileManager fm = comp.getStandardFileManager(null, null, null)) { + Location locn = StandardLocation.CLASS_OUTPUT; + + Path out1 = Files.createDirectories(base.resolve("out1")); + fm.setLocationFromPaths(locn, List.of(out1)); + + Location m = fm.getLocationForModule(locn, "m"); + checkEqual("default setting", + fm.getLocationAsPaths(m), out1.resolve("m")); + + Path override1 = Files.createDirectories(base.resolve("override1")); + fm.setLocationForModule(locn, "m", List.of(override1)); + checkEqual("override setting 1", + fm.getLocationAsPaths(m), override1); + + Path override2 = Files.createDirectories(base.resolve("override2")); + fm.setLocationFromPaths(m, List.of(override2)); + checkEqual("override setting 2", + fm.getLocationAsPaths(m), override2); + + Path out2 = Files.createDirectories(base.resolve("out2")); + fm.setLocationFromPaths(locn, List.of(out2)); + + checkEqual("updated setting", + fm.getLocationAsPaths(m), out2.resolve("m")); + } + } + + @Test + public void testOutput_invalid(Path base) throws IOException { + try (StandardJavaFileManager fm = comp.getStandardFileManager(null, null, null)) { + Location locn = StandardLocation.CLASS_OUTPUT; + // set a top default + Path out1 = Files.createDirectories(base.resolve("out1")); + fm.setLocationFromPaths(locn, List.of(out1)); + // getLocnForModule + Location m = fm.getLocationForModule(locn, "m"); + checkEqual("default setting", + fm.getLocationAsPaths(m), out1.resolve("m")); + + checkException("empty arg list", + IllegalArgumentException.class, "empty path for directory", + () -> fm.setLocationFromPaths(m, Collections.emptyList())); + + Path out2 = Files.createDirectories(base.resolve("out2")); + checkException("empty arg list", + IllegalArgumentException.class, "path too long for directory", + () -> fm.setLocationFromPaths(m, List.of(out2, out2))); + + Path notExist = base.resolve("notExist"); + checkException("not exist", + FileNotFoundException.class, notExist + ": does not exist", + () -> fm.setLocationFromPaths(m, List.of(notExist))); + + Path file = Files.createFile(base.resolve("file.txt")); + checkException("not exist", + IOException.class, file + ": not a directory", + () -> fm.setLocationFromPaths(m, List.of(file))); + } + } + + @Test + public void testOutput_nested(Path base) throws IOException { + try (StandardJavaFileManager fm = comp.getStandardFileManager(null, null, null)) { + Location locn = StandardLocation.CLASS_OUTPUT; + + Path out1 = Files.createDirectories(base.resolve("out1")); + fm.setLocationForModule(locn, "m", List.of(out1)); + + Location m = fm.getLocationForModule(locn, "m"); + checkEqual("initial setting", + fm.getLocationAsPaths(m), out1); + + Path out2 = Files.createDirectories(base.resolve("out2")); + checkException("create nested module", + UnsupportedOperationException.class, "not supported for CLASS_OUTPUT[m]", + () -> fm.setLocationForModule(m, "x", List.of(out2))); + } + } + + @Test + public void testSystemModules(Path base) throws IOException { + try (StandardJavaFileManager fm = comp.getStandardFileManager(null, null, null)) { + Location locn = StandardLocation.SYSTEM_MODULES; + + Location javaCompiler = fm.getLocationForModule(locn, "java.compiler"); + // cannot easily verify default setting: could be jrt: or exploded image + + Path override1 = Files.createDirectories(base.resolve("override1")); + fm.setLocationForModule(locn, "java.compiler", List.of(override1)); + checkEqual("override setting 1", + fm.getLocationAsPaths(javaCompiler), override1); + + Path override2 = Files.createDirectories(base.resolve("override2")); + fm.setLocationFromPaths(javaCompiler, List.of(override2)); + checkEqual("override setting 2", + fm.getLocationAsPaths(javaCompiler), override2); + } + } + + @Test + public void testTemplate(Path base) { + // set a top default + // getLocnForModule + // set a value + // getLocnForModule + // reset + // getLocationForModule + } + + interface RunnableWithException { + public void run() throws Exception; + } + + void checkException(String message, + Class expectedException, String expectedMessage, + RunnableWithException r) { + try { + r.run(); + error(message + ": expected exception not thrown: " + expectedException); + } catch (Exception | Error t) { + if (expectedException.isAssignableFrom(t.getClass())) { + checkEqual("exception message", + t.getMessage(), expectedMessage); + + } else { + error(message + ": unexpected exception\n" + + "expect: " + expectedException + "\n" + + " found: " + t); + } + } + } + + void checkEqual(String message, Iterable found, Path... expect) { + List fList = asList(found); + List eList = List.of(expect); + if (!Objects.equals(fList, fList)) { + error(message + ": lists not equal\n" + + "expect: " + eList + "\n" + + " found: " + fList); + } + } + + void checkEqual(String message, String found, String expect) { + if (!Objects.equals(found, expect)) { + error(message + ": strings not equal\n" + + "expect: " + expect + "\n" + + " found: " + found); + } + } + + List asList(Iterable a) { + List list = new ArrayList<>(); + for (Path p : a) { + list.add(p); + } + return list; + } +} + diff --git a/langtools/test/tools/javac/file/SymLinkTest.java b/langtools/test/tools/javac/file/SymLinkTest.java new file mode 100644 index 00000000000..e2cdfaffd7a --- /dev/null +++ b/langtools/test/tools/javac/file/SymLinkTest.java @@ -0,0 +1,94 @@ +/* + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8178017 + * @summary JDK 9 change to symlink handling causes misleading + * class.public.should.be.in.file diagnostic + * @library /tools/lib + * @modules jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @build toolbox.JavacTask toolbox.TestRunner toolbox.ToolBox + * @run main SymLinkTest + */ + +import java.io.IOException; +import java.nio.file.FileSystemException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; + +import toolbox.JavacTask; +import toolbox.TestRunner; +import toolbox.TestRunner.Test; +import toolbox.ToolBox; + +public class SymLinkTest extends TestRunner { + public static void main(String... args) throws Exception { + new SymLinkTest().runTests(m -> new Object[] { Paths.get(m.getName()) }); + } + + private final ToolBox tb = new ToolBox(); + + public SymLinkTest() { + super(System.err); + } + + @Test + public void testgetKind(Path base) throws IOException { + test(base, "SOURCE"); + } + + @Test + public void testSymLink(Path base) throws IOException { + test(base, "SOURCE.java"); + } + + void test(Path base, String name) throws IOException { + Path file = base.resolve(name); + Path javaFile = base.resolve("HelloWorld.java"); + tb.writeFile(file, + "public class HelloWorld {\n" + + " public static void main(String... args) {\n" + + " System.err.println(\"Hello World!\");\n" + + " }\n" + + "}"); + + try { + Files.createSymbolicLink(javaFile, file.getFileName()); + } catch (FileSystemException fse) { + System.err.println("warning: test passes vacuously, sym-link could not be created"); + System.err.println(fse.getMessage()); + return; + } + + Path classes = Files.createDirectories(base.resolve("classes")); + new JavacTask(tb) + .outdir(classes) + .files(javaFile) + .run() + .writeAll(); + } +} + diff --git a/langtools/test/tools/javac/generics/6182950/T6182950b.out b/langtools/test/tools/javac/generics/6182950/T6182950b.out index 09284ef5b67..ee698503f0e 100644 --- a/langtools/test/tools/javac/generics/6182950/T6182950b.out +++ b/langtools/test/tools/javac/generics/6182950/T6182950b.out @@ -1,2 +1,2 @@ -T6182950b.java:15:16: compiler.err.name.clash.same.erasure.no.override: m(java.util.List), T6182950b.B, m(java.util.List), T6182950b.A, m(java.util.List), T6182950b.B +T6182950b.java:15:16: compiler.err.name.clash.same.erasure.no.override: m, java.util.List, T6182950b.B, m, java.util.List, T6182950b.A 1 error diff --git a/langtools/test/tools/javac/generics/6476118/T6476118a.java b/langtools/test/tools/javac/generics/6476118/T6476118a.java index 27af70085b1..68ddce533ca 100644 --- a/langtools/test/tools/javac/generics/6476118/T6476118a.java +++ b/langtools/test/tools/javac/generics/6476118/T6476118a.java @@ -1,6 +1,6 @@ /** * @test /nodynamiccopyright/ - * @bug 6476118 + * @bug 6476118 7170058 * @summary compiler bug causes runtime ClassCastException for generics overloading * @compile/fail/ref=T6476118a.out -XDrawDiagnostics T6476118a.java */ diff --git a/langtools/test/tools/javac/generics/6476118/T6476118a.out b/langtools/test/tools/javac/generics/6476118/T6476118a.out index 27f39aefecc..3e86d0fdcc3 100644 --- a/langtools/test/tools/javac/generics/6476118/T6476118a.out +++ b/langtools/test/tools/javac/generics/6476118/T6476118a.out @@ -1,2 +1,2 @@ -T6476118a.java:14:20: compiler.err.name.clash.same.erasure.no.override.1: compareTo(T6476118a.B), T6476118a.B, compareTo(java.lang.Object), T6476118a.A, compareTo(T), java.lang.Comparable +T6476118a.java:14:20: compiler.err.name.clash.same.erasure.no.override.1: class, B, compareTo, T6476118a.B, java.lang.Comparable, compareTo, java.lang.Object, T6476118a.A 1 error diff --git a/langtools/test/tools/javac/generics/6476118/T6476118b.java b/langtools/test/tools/javac/generics/6476118/T6476118b.java index a5026f3e6e7..84fe2b82733 100644 --- a/langtools/test/tools/javac/generics/6476118/T6476118b.java +++ b/langtools/test/tools/javac/generics/6476118/T6476118b.java @@ -1,6 +1,6 @@ /** * @test /nodynamiccopyright/ - * @bug 6476118 6533652 + * @bug 6476118 6533652 7170058 * @summary compiler bug causes runtime ClassCastException for generics overloading * @compile/fail/ref=T6476118b.out -XDrawDiagnostics T6476118b.java */ diff --git a/langtools/test/tools/javac/generics/6476118/T6476118b.out b/langtools/test/tools/javac/generics/6476118/T6476118b.out index eb38f323081..3eef57881b1 100644 --- a/langtools/test/tools/javac/generics/6476118/T6476118b.out +++ b/langtools/test/tools/javac/generics/6476118/T6476118b.out @@ -1,2 +1,2 @@ -T6476118b.java:12:20: compiler.err.name.clash.same.erasure.no.override.1: compareTo(T6476118b.B), T6476118b.B, compareTo(java.lang.Object), T6476118b, compareTo(T), java.lang.Comparable +T6476118b.java:12:20: compiler.err.name.clash.same.erasure.no.override.1: class, B, compareTo, T6476118b.B, java.lang.Comparable, compareTo, java.lang.Object, T6476118b 1 error diff --git a/langtools/test/tools/javac/generics/6476118/T6476118c.java b/langtools/test/tools/javac/generics/6476118/T6476118c.java index dd9ea289209..2ce716d6f94 100644 --- a/langtools/test/tools/javac/generics/6476118/T6476118c.java +++ b/langtools/test/tools/javac/generics/6476118/T6476118c.java @@ -1,6 +1,6 @@ /** * @test /nodynamiccopyright/ - * @bug 6476118 + * @bug 6476118 7170058 * @summary compiler bug causes runtime ClassCastException for generics overloading * @compile/fail/ref=T6476118c.out -XDrawDiagnostics T6476118c.java */ diff --git a/langtools/test/tools/javac/generics/6476118/T6476118c.out b/langtools/test/tools/javac/generics/6476118/T6476118c.out index 2e7cabe42b6..a09348658c6 100644 --- a/langtools/test/tools/javac/generics/6476118/T6476118c.out +++ b/langtools/test/tools/javac/generics/6476118/T6476118c.out @@ -1,3 +1,3 @@ -T6476118c.java:18:21: compiler.err.name.clash.same.erasure.no.override: foo(java.lang.Object), T6476118c.C, foo(T), T6476118c.A, foo(java.lang.Object), T6476118c.C -T6476118c.java:19:21: compiler.err.name.clash.same.erasure.no.override: foo(java.lang.Number), T6476118c.C, foo(T), T6476118c.B, foo(java.lang.Number), T6476118c.C +T6476118c.java:18:21: compiler.err.name.clash.same.erasure.no.override: foo, java.lang.Object, T6476118c.C, foo, java.lang.Integer, T6476118c.A +T6476118c.java:19:21: compiler.err.name.clash.same.erasure.no.override: foo, java.lang.Number, T6476118c.C, foo, java.lang.Integer, T6476118c.B 2 errors diff --git a/langtools/test/tools/javac/generics/6985719/T6985719a.out b/langtools/test/tools/javac/generics/6985719/T6985719a.out index 9948d6cf393..8b3f5f295bb 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719a.out +++ b/langtools/test/tools/javac/generics/6985719/T6985719a.out @@ -1,2 +1,2 @@ -T6985719a.java:14:5: compiler.err.name.clash.same.erasure.no.override: f(java.util.List), T6985719a.B, f(java.util.List), T6985719a.A +T6985719a.java:14:5: compiler.err.name.clash.same.erasure.no.override: f, java.util.List, T6985719a.B, f, java.util.List, T6985719a.A 1 error diff --git a/langtools/test/tools/javac/generics/6985719/T6985719b.out b/langtools/test/tools/javac/generics/6985719/T6985719b.out index ef2ab842aea..03edee92fcd 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719b.out +++ b/langtools/test/tools/javac/generics/6985719/T6985719b.out @@ -1,2 +1,2 @@ -T6985719b.java:14:14: compiler.err.name.clash.same.erasure.no.override: f(java.util.List), T6985719b.B, f(java.util.List), T6985719b.A +T6985719b.java:14:14: compiler.err.name.clash.same.erasure.no.override: f, java.util.List, T6985719b.B, f, java.util.List, T6985719b.A 1 error diff --git a/langtools/test/tools/javac/generics/6985719/T6985719c.java b/langtools/test/tools/javac/generics/6985719/T6985719c.java index 51e52c014d7..d35f1898b12 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719c.java +++ b/langtools/test/tools/javac/generics/6985719/T6985719c.java @@ -1,6 +1,6 @@ /* * @test /nodynamiccopyright/ - * @bug 6985719 + * @bug 6985719 7170058 * @summary Alike methods in interfaces (Inheritance and Overriding) * @author mcimadamore * @compile/fail/ref=T6985719c.out -XDrawDiagnostics T6985719c.java diff --git a/langtools/test/tools/javac/generics/6985719/T6985719c.out b/langtools/test/tools/javac/generics/6985719/T6985719c.out index 23d2ba7687c..1e7503a0d32 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719c.out +++ b/langtools/test/tools/javac/generics/6985719/T6985719c.out @@ -1,2 +1,2 @@ -T6985719c.java:14:5: compiler.err.name.clash.same.erasure.no.override: f(java.util.List), T6985719c.B, f(java.util.List), T6985719c.A +T6985719c.java:14:5: compiler.err.name.clash.same.erasure.no.override: f, java.util.List, T6985719c.B, f, java.util.List, T6985719c.A 1 error diff --git a/langtools/test/tools/javac/generics/6985719/T6985719d.java b/langtools/test/tools/javac/generics/6985719/T6985719d.java index df2d9409170..eced8573eb1 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719d.java +++ b/langtools/test/tools/javac/generics/6985719/T6985719d.java @@ -1,6 +1,6 @@ /* * @test /nodynamiccopyright/ - * @bug 6985719 + * @bug 6985719 7170058 * @summary Alike methods in interfaces (Inheritance and Overriding) * @author mcimadamore * @compile/fail/ref=T6985719d.out -XDrawDiagnostics T6985719d.java diff --git a/langtools/test/tools/javac/generics/6985719/T6985719d.out b/langtools/test/tools/javac/generics/6985719/T6985719d.out index c46439c4921..a3974cf5a0f 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719d.out +++ b/langtools/test/tools/javac/generics/6985719/T6985719d.out @@ -1,2 +1,2 @@ -T6985719d.java:14:14: compiler.err.name.clash.same.erasure.no.override: f(java.util.List), T6985719d.B, f(java.util.List), T6985719d.A +T6985719d.java:14:14: compiler.err.name.clash.same.erasure.no.override: f, java.util.List, T6985719d.B, f, java.util.List, T6985719d.A 1 error diff --git a/langtools/test/tools/javac/generics/6985719/T6985719e.out b/langtools/test/tools/javac/generics/6985719/T6985719e.out index ff6c47c6ab0..d7d1073dff4 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719e.out +++ b/langtools/test/tools/javac/generics/6985719/T6985719e.out @@ -1,2 +1,2 @@ -T6985719e.java:13:34: compiler.err.name.clash.same.erasure.no.override: f(java.util.List), T6985719e.B, f(java.util.List), T6985719e.A, f(java.util.List), T6985719e.B +T6985719e.java:13:34: compiler.err.name.clash.same.erasure.no.override: f, java.util.List, T6985719e.B, f, java.util.List, T6985719e.A 1 error diff --git a/langtools/test/tools/javac/generics/6985719/T6985719f.out b/langtools/test/tools/javac/generics/6985719/T6985719f.out index 192d8d6547b..fb65f2d0e7e 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719f.out +++ b/langtools/test/tools/javac/generics/6985719/T6985719f.out @@ -1,2 +1,2 @@ -T6985719f.java:13:39: compiler.err.name.clash.same.erasure.no.override: f(java.util.List), T6985719f.B, f(java.util.List), T6985719f.A, f(java.util.List), T6985719f.B +T6985719f.java:13:39: compiler.err.name.clash.same.erasure.no.override: f, java.util.List, T6985719f.B, f, java.util.List, T6985719f.A 1 error diff --git a/langtools/test/tools/javac/generics/6985719/T6985719g.java b/langtools/test/tools/javac/generics/6985719/T6985719g.java index df8afa01259..5d11e56d185 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719g.java +++ b/langtools/test/tools/javac/generics/6985719/T6985719g.java @@ -1,6 +1,6 @@ /* * @test /nodynamiccopyright/ - * @bug 6985719 + * @bug 6985719 7170058 * @summary Alike methods in interfaces (Inheritance and Overriding) * @author mcimadamore * @compile/fail/ref=T6985719g.out -XDrawDiagnostics T6985719g.java diff --git a/langtools/test/tools/javac/generics/6985719/T6985719g.out b/langtools/test/tools/javac/generics/6985719/T6985719g.out index a6caaebe8f0..9c241db4d16 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719g.out +++ b/langtools/test/tools/javac/generics/6985719/T6985719g.out @@ -1,2 +1,2 @@ -T6985719g.java:13:42: compiler.err.name.clash.same.erasure.no.override: f(java.util.List), T6985719g.B, f(java.util.List), T6985719g.A, f(java.util.List), T6985719g.B +T6985719g.java:13:42: compiler.err.name.clash.same.erasure.no.override: f, java.util.List, T6985719g.B, f, java.util.List, T6985719g.A 1 error diff --git a/langtools/test/tools/javac/generics/6985719/T6985719h.java b/langtools/test/tools/javac/generics/6985719/T6985719h.java index 9bcc1431197..767dc181c4a 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719h.java +++ b/langtools/test/tools/javac/generics/6985719/T6985719h.java @@ -1,6 +1,6 @@ /* * @test /nodynamiccopyright/ - * @bug 6985719 + * @bug 6985719 7170058 * @summary Alike methods in interfaces (Inheritance and Overriding) * @author mcimadamore * @compile/fail/ref=T6985719h.out -XDrawDiagnostics T6985719h.java diff --git a/langtools/test/tools/javac/generics/6985719/T6985719h.out b/langtools/test/tools/javac/generics/6985719/T6985719h.out index 00fc35db316..caab3e246d9 100644 --- a/langtools/test/tools/javac/generics/6985719/T6985719h.out +++ b/langtools/test/tools/javac/generics/6985719/T6985719h.out @@ -1,2 +1,2 @@ -T6985719h.java:13:56: compiler.err.name.clash.same.erasure.no.override: f(java.util.List), T6985719h.B, f(java.util.List), T6985719h.A, f(java.util.List), T6985719h.B +T6985719h.java:13:56: compiler.err.name.clash.same.erasure.no.override: f, java.util.List, T6985719h.B, f, java.util.List, T6985719h.A 1 error diff --git a/langtools/test/tools/javac/generics/7007615/T7007615.java b/langtools/test/tools/javac/generics/7007615/T7007615.java index 0c7fc62cb64..793c3426e1d 100644 --- a/langtools/test/tools/javac/generics/7007615/T7007615.java +++ b/langtools/test/tools/javac/generics/7007615/T7007615.java @@ -1,6 +1,6 @@ /* * @test /nodynamiccopyright/ - * @bug 7007615 + * @bug 7007615 7170058 * @summary java_util/generics/phase2/NameClashTest02 fails since jdk7/pit/b123. * @author mcimadamore * @compile/fail/ref=T7007615.out -XDrawDiagnostics T7007615.java diff --git a/langtools/test/tools/javac/generics/7007615/T7007615.out b/langtools/test/tools/javac/generics/7007615/T7007615.out index a6be00192ea..a7ebb9c56a1 100644 --- a/langtools/test/tools/javac/generics/7007615/T7007615.out +++ b/langtools/test/tools/javac/generics/7007615/T7007615.out @@ -1,3 +1,3 @@ -T7007615.java:21:14: compiler.err.name.clash.same.erasure.no.override: foo(java.lang.Number), T6985719a.DX, foo(T), T6985719a.AX, foo(java.lang.Number), T6985719a.DX -T7007615.java:22:14: compiler.err.name.clash.same.erasure.no.override: bar(T6985719a.BX), T6985719a.DX, bar(T6985719a.BX), T6985719a.BX, bar(T6985719a.BX), T6985719a.DX +T7007615.java:21:14: compiler.err.name.clash.same.erasure.no.override: foo, java.lang.Number, T6985719a.DX, foo, java.lang.Integer, T6985719a.AX +T7007615.java:22:14: compiler.err.name.clash.same.erasure.no.override: bar, T6985719a.BX, T6985719a.DX, bar, T6985719a.BX, T6985719a.BX 2 errors diff --git a/langtools/test/tools/javac/generics/7020657/T7020657neg.out b/langtools/test/tools/javac/generics/7020657/T7020657neg.out index 77e16bed6a2..76101c14e50 100644 --- a/langtools/test/tools/javac/generics/7020657/T7020657neg.out +++ b/langtools/test/tools/javac/generics/7020657/T7020657neg.out @@ -1,2 +1,2 @@ -T7020657neg.java:22:5: compiler.err.name.clash.same.erasure.no.override: get(java.util.List), T7020657neg.B, get(java.util.List), T7020657neg.A +T7020657neg.java:22:5: compiler.err.name.clash.same.erasure.no.override: get, java.util.List, T7020657neg.B, get, java.util.List, T7020657neg.A 1 error diff --git a/langtools/test/tools/javac/generics/7022054/T7022054neg1.out b/langtools/test/tools/javac/generics/7022054/T7022054neg1.out index 075f381a718..06ee8889982 100644 --- a/langtools/test/tools/javac/generics/7022054/T7022054neg1.out +++ b/langtools/test/tools/javac/generics/7022054/T7022054neg1.out @@ -1,2 +1,2 @@ -T7022054neg1.java:15:30: compiler.err.name.clash.same.erasure.no.override: m(X), T7022054neg1.B, m(java.lang.String), T7022054neg1.A, m(X), T7022054neg1.B +T7022054neg1.java:15:30: compiler.err.name.clash.same.erasure.no.override: m, X, T7022054neg1.B, m, java.lang.String, T7022054neg1.A 1 error diff --git a/langtools/test/tools/javac/generics/7022054/T7022054pos1.out b/langtools/test/tools/javac/generics/7022054/T7022054pos1.out index b7f41063ee6..5901cb41ace 100644 --- a/langtools/test/tools/javac/generics/7022054/T7022054pos1.out +++ b/langtools/test/tools/javac/generics/7022054/T7022054pos1.out @@ -1,2 +1,2 @@ -T7022054pos1.java:39:25: compiler.err.name.clash.same.erasure.no.override: m(java.lang.String), T7022054pos1.B, m(java.lang.String), T7022054pos1.A, m(java.lang.String), T7022054pos1.B +T7022054pos1.java:39:25: compiler.err.name.clash.same.erasure.no.override: m, java.lang.String, T7022054pos1.B, m, java.lang.String, T7022054pos1.A 1 error diff --git a/langtools/test/tools/javac/generics/7034019/T7034019c.out b/langtools/test/tools/javac/generics/7034019/T7034019c.out index 55845589a91..ee8cd13919c 100644 --- a/langtools/test/tools/javac/generics/7034019/T7034019c.out +++ b/langtools/test/tools/javac/generics/7034019/T7034019c.out @@ -1,3 +1,3 @@ -T7034019c.java:18:20: compiler.err.name.clash.same.erasure.no.override: foo(), T7034019c.B, foo(), T7034019c.A +T7034019c.java:18:20: compiler.err.name.clash.same.erasure.no.override: foo, , T7034019c.B, foo, , T7034019c.A T7034019c.java:20:14: compiler.err.ref.ambiguous: foo, kindname.method, foo(), T7034019c.B, kindname.method, foo(), T7034019c.A 2 errors diff --git a/langtools/test/tools/javac/generics/7034019/T7034019d.out b/langtools/test/tools/javac/generics/7034019/T7034019d.out index bfd6fa0b4fa..cbf9f843408 100644 --- a/langtools/test/tools/javac/generics/7034019/T7034019d.out +++ b/langtools/test/tools/javac/generics/7034019/T7034019d.out @@ -1,3 +1,3 @@ -T7034019d.java:18:21: compiler.err.name.clash.same.erasure.no.override: foo(), T7034019c.B, foo(), T7034019c.A +T7034019d.java:18:21: compiler.err.name.clash.same.erasure.no.override: foo, , T7034019c.B, foo, , T7034019c.A T7034019d.java:20:13: compiler.err.ref.ambiguous: foo, kindname.method, foo(), T7034019c.B, kindname.method, foo(), T7034019c.A 2 errors diff --git a/langtools/test/tools/javac/generics/ErasureClashCrash.java b/langtools/test/tools/javac/generics/ErasureClashCrash.java index 4d3b96db4da..4f9675bfc75 100644 --- a/langtools/test/tools/javac/generics/ErasureClashCrash.java +++ b/langtools/test/tools/javac/generics/ErasureClashCrash.java @@ -1,6 +1,6 @@ /* * @test /nodynamiccopyright/ - * @bug 4951670 + * @bug 4951670 7170058 * @summary javac crash with improper overrider * @author gafter * diff --git a/langtools/test/tools/javac/generics/ErasureClashCrash.out b/langtools/test/tools/javac/generics/ErasureClashCrash.out index 61859621f10..33dbde61207 100644 --- a/langtools/test/tools/javac/generics/ErasureClashCrash.out +++ b/langtools/test/tools/javac/generics/ErasureClashCrash.out @@ -1,2 +1,2 @@ -ErasureClashCrash.java:14:16: compiler.err.name.clash.same.erasure.no.override: compareTo(java.lang.Object), ErasureClashCrash, compareTo(T), Compar, compareTo(java.lang.Object), ErasureClashCrash +ErasureClashCrash.java:14:16: compiler.err.name.clash.same.erasure.no.override: compareTo, java.lang.Object, ErasureClashCrash, compareTo, ErasureClashCrash, Compar 1 error diff --git a/langtools/test/tools/javac/generics/T4757416.java b/langtools/test/tools/javac/generics/T4757416.java index 8689abfe3c5..e87178264f6 100644 --- a/langtools/test/tools/javac/generics/T4757416.java +++ b/langtools/test/tools/javac/generics/T4757416.java @@ -1,6 +1,6 @@ /* * @test /nodynamiccopyright/ - * @bug 4756416 + * @bug 4756416 7170058 * @summary generics: erasure clash not detected * @author gafter * diff --git a/langtools/test/tools/javac/generics/T4757416.out b/langtools/test/tools/javac/generics/T4757416.out index 46109db5c35..99703cfebd5 100644 --- a/langtools/test/tools/javac/generics/T4757416.out +++ b/langtools/test/tools/javac/generics/T4757416.out @@ -1,3 +1,3 @@ -T4757416.java:14:23: compiler.err.name.clash.same.erasure.no.override.1: id(java.lang.String), T4756416.D, id(A), T4756416.I, id(A), T4756416.C -T4757416.java:15:24: compiler.err.name.clash.same.erasure.no.override.1: id(java.lang.Integer), T4756416.D, id(A), T4756416.C, id(A), T4756416.I +T4757416.java:14:23: compiler.err.name.clash.same.erasure.no.override.1: class, D, id, java.lang.String, T4756416.C, id, java.lang.Integer, T4756416.I +T4757416.java:15:24: compiler.err.name.clash.same.erasure.no.override.1: class, D, id, java.lang.Integer, T4756416.I, id, java.lang.String, T4756416.C 2 errors diff --git a/langtools/test/tools/javac/generics/inference/8174249/T8174249a.java b/langtools/test/tools/javac/generics/inference/8174249/T8174249a.java new file mode 100644 index 00000000000..80ebfa48d75 --- /dev/null +++ b/langtools/test/tools/javac/generics/inference/8174249/T8174249a.java @@ -0,0 +1,54 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8174249 + * @summary Regression in generic method unchecked calls + * @compile T8174249a.java + */ + +import java.util.ArrayList; +import java.util.Collection; + +class T8174249a { + static T foo(Class c, Collection baz) { +return null; + } + + static void bar(String c) { } + + void test() { + // this works + bar(foo(String.class, new ArrayList())); + + // this works with a warning + String s = foo(String.class, new ArrayList()); + bar(s); + + // this causes an error on JDK9 but should work + bar(foo(String.class, new ArrayList())); + } +} diff --git a/langtools/test/tools/javac/generics/inference/8174249/T8174249b.java b/langtools/test/tools/javac/generics/inference/8174249/T8174249b.java new file mode 100644 index 00000000000..a7f175fc0d8 --- /dev/null +++ b/langtools/test/tools/javac/generics/inference/8174249/T8174249b.java @@ -0,0 +1,59 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8174249 + * @summary Regression in generic method unchecked calls + * @compile T8174249b.java + */ + +import java.util.*; + +class T8174249b { + + static void cs(Collection cs) {} + + void test1(Collection c) { + cs(rawCollection((Class)null)); + Collection cs1 = rawCollection((Class)null); + } + + void test2(Collection c) { + cs(rawCollection2((Class)null)); + Collection cs2 = rawCollection2((Class)null); + } + + void test3(Collection c) { + cs(rawCollection3((Class)null)); + Collection cs3 = rawCollection2((Class)null); + } + + Collection rawCollection(Class cs) { return null; } + + Collection rawCollection2(Class cs) { return null; } + + Collection rawCollection3(Class cs) { return null; } +} diff --git a/langtools/test/tools/javac/generics/inference/8176534/T8176534.java b/langtools/test/tools/javac/generics/inference/8176534/T8176534.java new file mode 100644 index 00000000000..3496c693b4d --- /dev/null +++ b/langtools/test/tools/javac/generics/inference/8176534/T8176534.java @@ -0,0 +1,18 @@ +/* + * @test /nodynamiccopyright/ + * @bug 8176534 + * @summary Missing check against target-type during applicability inference + * @compile/fail/ref=T8176534.out -Werror -Xlint:unchecked -XDrawDiagnostics T8176534.java + */ + +import java.util.*; + +abstract class T8176534 { + List f(Enumeration e) { + return newArrayList(forEnumeration(e)); + } + + abstract Iterator forEnumeration(Enumeration e); + abstract ArrayList newArrayList(Iterator xs); + abstract ArrayList newArrayList(Iterable xs); +} diff --git a/langtools/test/tools/javac/generics/inference/8176534/T8176534.out b/langtools/test/tools/javac/generics/inference/8176534/T8176534.out new file mode 100644 index 00000000000..4353b75cbe1 --- /dev/null +++ b/langtools/test/tools/javac/generics/inference/8176534/T8176534.out @@ -0,0 +1,8 @@ +T8176534.java:12:43: compiler.warn.unchecked.meth.invocation.applied: kindname.method, forEnumeration, java.util.Enumeration, java.util.Enumeration, kindname.class, T8176534 +T8176534.java:12:44: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), java.util.Enumeration, java.util.Enumeration +T8176534.java:12:28: compiler.warn.unchecked.meth.invocation.applied: kindname.method, newArrayList, java.util.Iterator, java.util.Iterator, kindname.class, T8176534 +T8176534.java:12:43: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), java.util.Iterator, java.util.Iterator +T8176534.java:12:28: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), java.util.ArrayList, java.util.List +- compiler.err.warnings.and.werror +1 error +5 warnings diff --git a/langtools/test/tools/javac/generics/inference/8176534/TestUncheckedCalls.java b/langtools/test/tools/javac/generics/inference/8176534/TestUncheckedCalls.java new file mode 100644 index 00000000000..ef7267cb916 --- /dev/null +++ b/langtools/test/tools/javac/generics/inference/8176534/TestUncheckedCalls.java @@ -0,0 +1,255 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import combo.ComboInstance; +import combo.ComboParameter; +import combo.ComboTask.Result; +import combo.ComboTestHelper; + +import javax.lang.model.element.Element; +import java.util.stream.Stream; + +/* + * @test + * @bug 8176534 + * @summary Missing check against target-type during applicability inference + * @library /tools/javac/lib + * @modules jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.code + * jdk.compiler/com.sun.tools.javac.comp + * jdk.compiler/com.sun.tools.javac.main + * jdk.compiler/com.sun.tools.javac.tree + * jdk.compiler/com.sun.tools.javac.util + * @build combo.ComboTestHelper + * + * @run main TestUncheckedCalls + */ +public class TestUncheckedCalls extends ComboInstance { + enum InputExpressionKind implements ComboParameter { + A("(A)null"), + A_STRING("(A)null"), + B("(B)null"), + B_STRING("(B)null"); + + String inputExpr; + + InputExpressionKind(String inputExpr) { + this.inputExpr = inputExpr; + } + + + @Override + public String expand(String optParameter) { + return inputExpr; + } + } + + enum TypeKind implements ComboParameter { + Z("Z"), + C_T("#C"), + C_STRING("#C"), + C("#C"); + + String typeTemplate; + + TypeKind(String typeTemplate) { + this.typeTemplate = typeTemplate; + } + + boolean hasTypeVars() { + return this == Z || this == C_T; + } + + @Override + public String expand(String className) { + return typeTemplate.replaceAll("#C", className); + } + } + + enum TypeVarsKind implements ComboParameter { + NONE("", "Object"), + Z_T(", T>", "Z"); + + String typeVarsTemplate; + String paramString; + + TypeVarsKind(String typeVarsTemplate, String paramString) { + this.typeVarsTemplate = typeVarsTemplate; + this.paramString = paramString; + } + + + @Override + public String expand(String className) { + if (className.equals("Z")) { + return paramString; + } else { + return typeVarsTemplate.replaceAll("#C", className); + } + } + } + + enum CallKind implements ComboParameter { + M("M(#{IN}, #{IN})"), + M_G("M(G(#{IN}, #{IN}), #{IN})"), + M_G_G("M(G(#{IN}, #{IN}), G(#{IN}, #{IN}))"); + + String callExpr; + + CallKind(String callExpr) { + this.callExpr = callExpr; + } + + + @Override + public String expand(String optParameter) { + return callExpr; + } + } + + enum DeclKind implements ComboParameter { + NONE(""), + ONE("#{TVARS[#M_IDX].I1} #{RET[#M_IDX].A} #M(#{ARG[#M_IDX].A} x1, #{TVARS[#M_IDX].Z} x2) { return null; }"), + TWO("#{TVARS[#M_IDX].I1} #{RET[#M_IDX].A} #M(#{ARG[#M_IDX].A} x1, #{TVARS[#M_IDX].Z} x2) { return null; }\n" + + " #{TVARS[#M_IDX].I2} #{RET[#M_IDX].B} #M(#{ARG[#M_IDX].B} x1, #{TVARS[#M_IDX].Z} x2) { return null; }"); + + String declTemplate; + + DeclKind(String declTemplate) { + this.declTemplate = declTemplate; + } + + @Override + public String expand(String methName) { + return declTemplate.replaceAll("#M_IDX", methName.equals("M") ? "0" : "1") + .replaceAll("#M", methName); + + } + } + + static final String sourceTemplate = + "class Test {\n" + + " interface I1 { }\n" + + " interface I2 { }\n" + + " static class A implements I1 { }\n" + + " static class B implements I2 { }\n" + + " #{DECL[0].M}\n" + + " #{DECL[1].G}\n" + + " void test() {\n" + + " #{CALL};\n" + + " }\n" + + "}\n"; + + public static void main(String... args) throws Exception { + new ComboTestHelper() + .withFilter(TestUncheckedCalls::arityFilter) + .withFilter(TestUncheckedCalls::declFilter) + .withFilter(TestUncheckedCalls::tvarFilter) + .withFilter(TestUncheckedCalls::inputExprFilter) + .withDimension("IN", (x, expr) -> x.inputExpressionKind = expr, InputExpressionKind.values()) + .withDimension("CALL", (x, expr) -> x.callKind = expr, CallKind.values()) + .withArrayDimension("DECL", (x, decl, idx) -> x.decls[idx] = x.new Decl(decl, idx), 2, DeclKind.values()) + .withArrayDimension("TVARS", (x, tvars, idx) -> x.typeVarsKinds[idx] = tvars, 2, TypeVarsKind.values()) + .withArrayDimension("RET", (x, ret, idx) -> x.returnKinds[idx] = ret, 2, TypeKind.values()) + .withArrayDimension("ARG", (x, arg, idx) -> x.argumentKinds[idx] = arg, 2, TypeKind.values()) + .run(TestUncheckedCalls::new); + } + + class Decl { + private DeclKind declKind; + private int index; + + Decl(DeclKind declKind, int index) { + this.declKind = declKind; + this.index = index; + } + + boolean hasKind(DeclKind declKind) { + return this.declKind == declKind; + } + + boolean isGeneric() { + return typeVarsKind() == TypeVarsKind.Z_T; + } + + TypeKind returnKind() { + return returnKinds[index]; + } + + TypeKind argumentsKind() { + return argumentKinds[index]; + } + + TypeVarsKind typeVarsKind() { + return typeVarsKinds[index]; + } + } + + CallKind callKind; + InputExpressionKind inputExpressionKind; + TypeKind[] returnKinds = new TypeKind[2]; + TypeKind[] argumentKinds = new TypeKind[2]; + TypeVarsKind[] typeVarsKinds = new TypeVarsKind[2]; + Decl[] decls = new Decl[2]; + + boolean arityFilter() { + return (callKind == CallKind.M || !decls[1].hasKind(DeclKind.NONE)) && + !decls[0].hasKind(DeclKind.NONE); + } + + boolean declFilter() { + return Stream.of(decls) + .filter(d -> d.hasKind(DeclKind.NONE)) + .flatMap(d -> Stream.of(d.returnKind(), d.argumentsKind(), d.typeVarsKind())) + .noneMatch(tk -> tk.ordinal() != 0); + } + + boolean tvarFilter() { + return Stream.of(decls) + .filter(d -> !d.hasKind(DeclKind.NONE)) + .filter(d -> !d.isGeneric()) + .flatMap(d -> Stream.of(d.returnKind(), d.argumentsKind())) + .noneMatch(TypeKind::hasTypeVars); + } + + boolean inputExprFilter() { + return (inputExpressionKind != InputExpressionKind.B && inputExpressionKind != InputExpressionKind.B_STRING) || + Stream.of(decls).allMatch(d -> d.declKind == DeclKind.TWO); + } + + @Override + public void doWork() throws Throwable { + check(newCompilationTask() + .withSourceFromTemplate(sourceTemplate) + .analyze()); + } + + void check(Result> result) { + if (result.hasErrors()) { + fail("compiler error:\n" + + result.compilationInfo()); + } + } +} diff --git a/langtools/test/tools/javac/generics/inference/8177097/T8177097a.java b/langtools/test/tools/javac/generics/inference/8177097/T8177097a.java new file mode 100644 index 00000000000..98bbd451be2 --- /dev/null +++ b/langtools/test/tools/javac/generics/inference/8177097/T8177097a.java @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8177097 + * @summary Generic method reference returning wildcard parameterized type does not compile + * @compile T8177097a.java + */ + +import java.util.Map; + +class T8177097a { + interface X { + Map apply(); + } + + void go(X x) { } + + static Map a() { + return null; + } + + void test() { + go(T8177097a::a); + } +} diff --git a/langtools/test/tools/javac/generics/inference/8177097/T8177097b.java b/langtools/test/tools/javac/generics/inference/8177097/T8177097b.java new file mode 100644 index 00000000000..a7d2b5ccfd6 --- /dev/null +++ b/langtools/test/tools/javac/generics/inference/8177097/T8177097b.java @@ -0,0 +1,48 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8177097 + * @summary Generic method reference returning wildcard parameterized type does not compile + * @compile T8177097b.java + */ + +import java.util.Map; + +class T8177097b { + interface X { + O apply(Class> m2); + } + + void go(X x) {} + + static I a(Class c) { return null; } + + + void test() { + go(T8177097b::a); + } +} diff --git a/langtools/test/tools/javac/generics/rawOverride/7157798/Test4.java b/langtools/test/tools/javac/generics/rawOverride/7157798/Test4.java index 8ff39c9ceac..b9ce99f9944 100644 --- a/langtools/test/tools/javac/generics/rawOverride/7157798/Test4.java +++ b/langtools/test/tools/javac/generics/rawOverride/7157798/Test4.java @@ -1,6 +1,6 @@ /** * @test /nodynamiccopyright/ - * @bug 7062745 7157798 + * @bug 7062745 7157798 7170058 * @summary Negative test of conflicting same-name methods inherited from multiple interfaces when parameter types not compatible * @compile/fail/ref=Test4.out -Werror -Xlint:unchecked -XDrawDiagnostics Test4.java */ diff --git a/langtools/test/tools/javac/generics/rawOverride/7157798/Test4.out b/langtools/test/tools/javac/generics/rawOverride/7157798/Test4.out index c4018ab0b3d..3b5a29ab2b8 100644 --- a/langtools/test/tools/javac/generics/rawOverride/7157798/Test4.out +++ b/langtools/test/tools/javac/generics/rawOverride/7157798/Test4.out @@ -1,6 +1,6 @@ -Test4.java:15:1: compiler.err.name.clash.same.erasure.no.override: m(java.util.Set), B, m(java.util.Set), A -Test4.java:17:1: compiler.err.name.clash.same.erasure.no.override: m(java.util.Set), C, m(java.util.Set), A -Test4.java:23:1: compiler.err.name.clash.same.erasure.no.override: m(java.util.Set), D, m(java.util.Set), A -Test4.java:25:1: compiler.err.name.clash.same.erasure.no.override: m(java.util.Set), D, m(java.util.Set), C -Test4.java:29:1: compiler.err.name.clash.same.erasure.no.override: m(java.util.Set), E, m(java.util.Set), D +Test4.java:15:1: compiler.err.name.clash.same.erasure.no.override: m, java.util.Set, B, m, java.util.Set, A +Test4.java:17:1: compiler.err.name.clash.same.erasure.no.override: m, java.util.Set, C, m, java.util.Set, A +Test4.java:23:1: compiler.err.name.clash.same.erasure.no.override: m, java.util.Set, D, m, java.util.Set, A +Test4.java:25:1: compiler.err.name.clash.same.erasure.no.override: m, java.util.Set, D, m, java.util.Set, C +Test4.java:29:1: compiler.err.name.clash.same.erasure.no.override: m, java.util.Set, E, m, java.util.Set, D 5 errors diff --git a/langtools/test/tools/javac/importChecks/NoImportedNoClasses.out b/langtools/test/tools/javac/importChecks/NoImportedNoClasses.out index 3e49e06f089..089130c10e0 100644 --- a/langtools/test/tools/javac/importChecks/NoImportedNoClasses.out +++ b/langtools/test/tools/javac/importChecks/NoImportedNoClasses.out @@ -1,2 +1,2 @@ -NoImportedNoClasses.java:10:1: compiler.err.cant.resolve.location: kindname.static, UNKNOWN, , , kindname.interface, java.lang.Runnable +NoImportedNoClasses.java:10:1: compiler.err.cant.resolve.location: kindname.static, UNKNOWN, null, null, (compiler.misc.location: kindname.interface, java.lang.Runnable, null) 1 error \ No newline at end of file diff --git a/langtools/test/tools/javac/lambda/T8175317.java b/langtools/test/tools/javac/lambda/T8175317.java new file mode 100644 index 00000000000..08d3ebeaf32 --- /dev/null +++ b/langtools/test/tools/javac/lambda/T8175317.java @@ -0,0 +1,31 @@ +/* + * @test /nodynamiccopyright/ + * @bug 8175317 + * @summary javac does not issue unchecked warnings when checking method reference return types + * @compile/fail/ref=T8175317.out -Werror -Xlint:unchecked -XDrawDiagnostics T8175317.java + */ + +import java.util.function.*; +import java.util.*; + +class T8175317 { + void m(Supplier> s) { } + + void testMethodLambda(List l) { + m(() -> l); + } + + void testAssignLambda(List l) { + Supplier> s = () -> l; + } + + void testMethodMref() { + m(this::g); + } + + void testAssignMref() { + Supplier> s = this::g; + } + + List g() { return null; } +} diff --git a/langtools/test/tools/javac/lambda/T8175317.out b/langtools/test/tools/javac/lambda/T8175317.out new file mode 100644 index 00000000000..74cdca632f7 --- /dev/null +++ b/langtools/test/tools/javac/lambda/T8175317.out @@ -0,0 +1,7 @@ +T8175317.java:15:10: compiler.warn.unchecked.meth.invocation.applied: kindname.method, m, java.util.function.Supplier>, java.util.function.Supplier>, kindname.class, T8175317 +T8175317.java:19:42: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), java.util.List, java.util.List +T8175317.java:23:10: compiler.warn.unchecked.meth.invocation.applied: kindname.method, m, java.util.function.Supplier>, java.util.function.Supplier>, kindname.class, T8175317 +T8175317.java:27:36: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), java.util.List, java.util.List +- compiler.err.warnings.and.werror +1 error +4 warnings diff --git a/langtools/test/tools/javac/lambda/funcInterfaces/NonSAM2.java b/langtools/test/tools/javac/lambda/funcInterfaces/NonSAM2.java index 2dd6b31800e..16f789ac8bd 100644 --- a/langtools/test/tools/javac/lambda/funcInterfaces/NonSAM2.java +++ b/langtools/test/tools/javac/lambda/funcInterfaces/NonSAM2.java @@ -1,6 +1,6 @@ /* * @test /nodynamiccopyright/ - * @bug 8003280 + * @bug 8003280 7170058 * @summary Add lambda tests * This test is for identifying a non-SAM type: Having more than one methods due to inheritance, and none of them has a subsignature of all other methods * @compile/fail/ref=NonSAM2.out -XDrawDiagnostics NonSAM2.java Helper.java diff --git a/langtools/test/tools/javac/lambda/funcInterfaces/NonSAM2.out b/langtools/test/tools/javac/lambda/funcInterfaces/NonSAM2.out index b44b64cbeb9..8360f7c4475 100644 --- a/langtools/test/tools/javac/lambda/funcInterfaces/NonSAM2.out +++ b/langtools/test/tools/javac/lambda/funcInterfaces/NonSAM2.out @@ -1,5 +1,5 @@ NonSAM2.java:13:1: compiler.err.types.incompatible.diff.ret: Bar1, Foo1, getAge(java.lang.String) -NonSAM2.java:15:1: compiler.err.name.clash.same.erasure.no.override: getOldest(java.util.List), C, getOldest(java.util.List), A -NonSAM2.java:17:1: compiler.err.name.clash.same.erasure.no.override: getOldest(java.util.List), D, getOldest(java.util.List), A -NonSAM2.java:21:1: compiler.err.name.clash.same.erasure.no.override: m(S), Bar2, m(T), Foo2 +NonSAM2.java:15:1: compiler.err.name.clash.same.erasure.no.override: getOldest, java.util.List, C, getOldest, java.util.List, A +NonSAM2.java:17:1: compiler.err.name.clash.same.erasure.no.override: getOldest, java.util.List, D, getOldest, java.util.List, A +NonSAM2.java:21:1: compiler.err.name.clash.same.erasure.no.override: m, T2, Bar2, m, T1, Foo2 4 errors diff --git a/langtools/test/tools/javac/lib/JavacTestingAbstractProcessor.java b/langtools/test/tools/javac/lib/JavacTestingAbstractProcessor.java index f253356f27b..6509542c1ba 100644 --- a/langtools/test/tools/javac/lib/JavacTestingAbstractProcessor.java +++ b/langtools/test/tools/javac/lib/JavacTestingAbstractProcessor.java @@ -21,8 +21,6 @@ * questions. */ -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.*; import javax.annotation.processing.*; import javax.lang.model.SourceVersion; @@ -102,7 +100,7 @@ public abstract class JavacTestingAbstractProcessor extends AbstractProcessor { protected void addExports(String moduleName, String... packageNames) { for (String packageName : packageNames) { try { - Layer layer = Layer.boot(); + ModuleLayer layer = ModuleLayer.boot(); Optional m = layer.findModule(moduleName); if (!m.isPresent()) throw new Error("module not found: " + moduleName); diff --git a/langtools/test/tools/javac/lib/combo/ComboTask.java b/langtools/test/tools/javac/lib/combo/ComboTask.java index ee20f78d424..568a1efc724 100644 --- a/langtools/test/tools/javac/lib/combo/ComboTask.java +++ b/langtools/test/tools/javac/lib/combo/ComboTask.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,9 +25,9 @@ package combo; import com.sun.source.tree.CompilationUnitTree; import com.sun.source.util.JavacTask; -import com.sun.source.util.TaskEvent.Kind; import com.sun.source.util.TaskListener; import com.sun.tools.javac.api.JavacTool; +import com.sun.tools.javac.util.Assert; import com.sun.tools.javac.util.List; import combo.ComboParameter.Resolver; @@ -36,11 +36,18 @@ import javax.tools.Diagnostic; import javax.tools.DiagnosticListener; import javax.tools.JavaFileObject; import javax.tools.SimpleJavaFileObject; + import java.io.IOException; import java.io.Writer; import java.net.URI; +import java.net.URL; +import java.net.URLClassLoader; +import java.util.ArrayList; +import java.util.function.Consumer; +import java.util.function.Function; import java.util.HashMap; import java.util.Map; +import java.util.Optional; import java.util.stream.Collectors; import java.util.stream.StreamSupport; @@ -183,6 +190,28 @@ public class ComboTask { return new Result<>(getTask().generate()); } + /** + * Parse, analyze, perform code generation for the sources associated with this task and finally + * executes them + */ + public Optional execute(Function executionFunc) throws IOException { + Result> generationResult = generate(); + Iterable jfoIterable = generationResult.get(); + if (generationResult.hasErrors()) { + // we have nothing else to do + return Optional.empty(); + } + java.util.List urlList = new ArrayList<>(); + for (JavaFileObject jfo : jfoIterable) { + String urlStr = jfo.toUri().toURL().toString(); + urlStr = urlStr.substring(0, urlStr.length() - jfo.getName().length()); + urlList.add(new URL(urlStr)); + } + return Optional.of( + executionFunc.apply( + new ExecutionTask(new URLClassLoader(urlList.toArray(new URL[urlList.size()]))))); + } + /** * Fork a new compilation task; if possible the compilation context from previous executions is * retained (see comments in ReusableContext as to when it's safe to do so); otherwise a brand @@ -214,6 +243,80 @@ public class ComboTask { return task; } + /** + * This class represents an execution task. It allows the execution of one or more classes previously + * added to a given class loader. This class uses reflection to execute any given static public method + * in any given class. It's not restricted to the execution of the {@code main} method + */ + public class ExecutionTask { + private ClassLoader classLoader; + private String methodName = "main"; + private Class[] parameterTypes = new Class[]{String[].class}; + private Object[] args = new String[0]; + private Consumer handler; + private Class c; + + private ExecutionTask(ClassLoader classLoader) { + this.classLoader = classLoader; + } + + /** + * Set the name of the class to be loaded. + */ + public ExecutionTask withClass(String className) { + Assert.check(className != null, "class name value is null, impossible to proceed"); + try { + c = classLoader.loadClass(className); + } catch (Throwable t) { + throw new IllegalStateException(t); + } + return this; + } + + /** + * Set the name of the method to be executed along with the parameter types to + * reflectively obtain the method. + */ + public ExecutionTask withMethod(String methodName, Class... parameterTypes) { + this.methodName = methodName; + this.parameterTypes = parameterTypes; + return this; + } + + /** + * Set the arguments to be passed to the method. + */ + public ExecutionTask withArguments(Object... args) { + this.args = args; + return this; + } + + /** + * Set a handler to handle any exception thrown. + */ + public ExecutionTask withHandler(Consumer handler) { + this.handler = handler; + return this; + } + + /** + * Executes the given method in the given class. Returns true if the execution was + * successful, false otherwise. + */ + public Object run() { + try { + java.lang.reflect.Method meth = c.getMethod(methodName, parameterTypes); + meth.invoke(null, (Object)args); + return true; + } catch (Throwable t) { + if (handler != null) { + handler.accept(t); + } + return false; + } + } + } + /** * This class is used to help clients accessing the results of a given compilation task. * Contains several helper methods to inspect diagnostics generated during the task execution. diff --git a/langtools/test/tools/javac/linenumbers/FinallyLineNumberTest.java b/langtools/test/tools/javac/linenumbers/FinallyLineNumberTest.java index 892d36589b2..51946f63884 100644 --- a/langtools/test/tools/javac/linenumbers/FinallyLineNumberTest.java +++ b/langtools/test/tools/javac/linenumbers/FinallyLineNumberTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -36,7 +36,6 @@ import com.sun.tools.classfile.Code_attribute; import com.sun.tools.classfile.LineNumberTable_attribute; import com.sun.tools.classfile.LineNumberTable_attribute.Entry; -import java.io.File; import java.io.IOException; public class FinallyLineNumberTest { @@ -46,13 +45,13 @@ public class FinallyLineNumberTest { if (lines == null) { throw new Exception("finally line number table could not be loaded"); } - if (lines.length != 4) { + if (lines.length != 5) { // Help debug System.err.println("LineTable error, got lines:"); for (Entry e : lines) { System.err.println(e.line_number); } - throw new Exception("finally line number table incorrect: length=" + lines.length + " expected length=4"); + throw new Exception("finally line number table incorrect: length=" + lines.length + " expected length=5"); } // return null line, for the load null operation @@ -71,11 +70,17 @@ public class FinallyLineNumberTest { throw new Exception("finally line number table incorrect: got=" + current + " expected=" + first); } - // finally line, for when exception is thrown + // for when exception is thrown current = lines[3].line_number; if (current != first + 2) { throw new Exception("finally line number table incorrect: got=" + current + " expected=" + (first + 2)); } + + // the '}' closing the finally block + current = lines[4].line_number; + if (current != first + 3) { + throw new Exception("finally line number table incorrect: got=" + current + " expected=" + (first + 3)); + } } static Entry[] findEntries() throws IOException, ConstantPoolException { diff --git a/langtools/test/tools/javac/linenumbers/NullCheckLineNumberTest.java b/langtools/test/tools/javac/linenumbers/NullCheckLineNumberTest.java new file mode 100644 index 00000000000..30c1a1c6b0e --- /dev/null +++ b/langtools/test/tools/javac/linenumbers/NullCheckLineNumberTest.java @@ -0,0 +1,87 @@ +/* + * @test /nodynamiccopyright/ + * @bug 8172880 + * @summary Wrong LineNumberTable for synthetic null checks + * @modules jdk.jdeps/com.sun.tools.classfile + */ + +import com.sun.tools.classfile.ClassFile; +import com.sun.tools.classfile.ConstantPoolException; +import com.sun.tools.classfile.Method; +import com.sun.tools.classfile.Attribute; +import com.sun.tools.classfile.Code_attribute; +import com.sun.tools.classfile.LineNumberTable_attribute; + +import java.io.IOException; +import java.util.AbstractMap.SimpleEntry; +import java.util.Arrays; +import java.util.List; +import java.util.Map.Entry; +import java.util.Objects; +import java.util.stream.Collectors; +import java.util.stream.Stream; + +public class NullCheckLineNumberTest { + + //test data: + static class Test { + + public Test() { + String a = "", b = null; + + Stream.of("x") + .filter(a::equals) + .filter(b::equals) + .count(); + } + + } + + public static void main(String[] args) throws Exception { + List actualEntries = findEntries(); + List expectedEntries = List.of( + new SimpleEntry<>(29, 0), + new SimpleEntry<>(30, 4), + new SimpleEntry<>(32, 9), + new SimpleEntry<>(33, 16), + new SimpleEntry<>(34, 32), + new SimpleEntry<>(35, 46), + new SimpleEntry<>(36, 52) + ); + if (!Objects.equals(actualEntries, expectedEntries)) { + error(String.format("Unexpected LineNumberTable: %s", actualEntries.toString())); + } + + try { + new Test(); + } catch (NullPointerException npe) { + if (Arrays.stream(npe.getStackTrace()) + .noneMatch(se -> se.getFileName().contains("NullCheckLineNumberTest") && + se.getLineNumber() == 34)) { + throw new AssertionError("Should go through line 34!"); + } + } + } + + static List findEntries() throws IOException, ConstantPoolException { + ClassFile self = ClassFile.read(NullCheckLineNumberTest.Test.class.getResourceAsStream("NullCheckLineNumberTest$Test.class")); + for (Method m : self.methods) { + if ("".equals(m.getName(self.constant_pool))) { + Code_attribute code_attribute = (Code_attribute)m.attributes.get(Attribute.Code); + for (Attribute at : code_attribute.attributes) { + if (Attribute.LineNumberTable.equals(at.getName(self.constant_pool))) { + return Arrays.stream(((LineNumberTable_attribute)at).line_number_table) + .map(e -> new SimpleEntry<> (e.line_number, e.start_pc)) + .collect(Collectors.toList()); + } + } + } + } + return null; + } + + static void error(String msg) { + throw new AssertionError(msg); + } + +} diff --git a/langtools/test/tools/javac/main/EnvVariableTest.java b/langtools/test/tools/javac/main/EnvVariableTest.java new file mode 100644 index 00000000000..0d44edcb72c --- /dev/null +++ b/langtools/test/tools/javac/main/EnvVariableTest.java @@ -0,0 +1,151 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8173308 + * @summary Check JDK_JAVA_OPTIONS parsing behavior + * @library /tools/lib + * @modules jdk.compiler/com.sun.tools.javac.main + * @build toolbox.ToolBox toolbox.TestRunner + * @run main EnvVariableTest + */ + +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.io.PrintStream; +import java.nio.file.Path; + +import toolbox.*; + +import com.sun.tools.javac.main.CommandLine; + +public class EnvVariableTest extends TestRunner { + final String testClasses; + final ToolBox tb; + final Path javaExePath; + final ExecTask task; + final PrintStream ostream; + final ByteArrayOutputStream baos; + + public EnvVariableTest() { + super(System.err); + ostream = System.err; + baos = new ByteArrayOutputStream(); + testClasses = System.getProperty("test.classes"); + tb = new ToolBox(); + javaExePath = tb.getJDKTool("java"); + task = new ExecTask(tb, javaExePath); + } + + public static void main(String... args) throws Exception { + EnvVariableTest t = new EnvVariableTest(); + t.runTests(); + } + + @Test + public void testDoubleQuote() throws Exception { + // white space quoted with double quotes + test("-version -cp \"c:\\\\java libs\\\\one.jar\" \n", + "-version", "-cp", "c:\\\\java libs\\\\one.jar"); + } + + @Test + public void testSingleQuote() throws Exception { + // white space quoted with single quotes + test("-version -cp \'c:\\\\java libs\\\\one.jar\' \n", + "-version", "-cp", "c:\\\\java libs\\\\one.jar"); + } + + @Test + public void testEscapeCharacters() throws Exception { + // escaped characters + test("escaped chars testing \"\\a\\b\\c\\f\\n\\r\\t\\v\\9\\6\\23\\82\\28\\377\\477\\278\\287\"", + "escaped", "chars", "testing", "\\a\\b\\c\\f\\n\\r\\t\\v\\9\\6\\23\\82\\28\\377\\477\\278\\287"); + } + + @Test + public void testMixedQuotes() throws Exception { + // more mixing of quote types + test("\"mix 'single quote' in double\" 'mix \"double quote\" in single' partial\"quote me\"this", + "mix 'single quote' in double", "mix \"double quote\" in single", "partialquote methis"); + } + + @Test + public void testWhiteSpaces() throws Exception { + // whitespace tests + test("line one #comment\n'line #2' #rest are comment\r\n#comment on line 3\fline 4 #comment to eof", + "line", "one", "#comment", "line #2", "#rest", "are", "comment", "#comment", "on", "line", + "3", "line", "4", "#comment", "to", "eof"); + } + + @Test + public void testMismatchedDoubleQuote() throws Exception { + // mismatched quote + test("This is an \"open quote \n across line\n\t, note for WS.", + "Exception: JDK_JAVAC_OPTIONS"); + } + + @Test + public void testMismatchedSingleQuote() throws Exception { + // mismatched quote + test("This is an \'open quote \n across line\n\t, note for WS.", + "Exception: JDK_JAVAC_OPTIONS"); + } + + void test(String full, String... expectedArgs) throws Exception { + task.envVar("JDK_JAVAC_OPTIONS", full); + task.args("--add-exports", "jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED", + "-cp", testClasses, "EnvVariableTest$Tester"); + Task.Result tr = task.run(Task.Expect.SUCCESS); + String expected = Tester.arrayToString(expectedArgs); + String in = tr.getOutput(Task.OutputKind.STDOUT); + System.err.println("Matching..."); + System.err.println("Obtained: " + in); + System.err.println("Expected: " + expected); + if (in.contains(expected)) { + System.err.println("....OK"); + return; + } + throw new Exception("Expected strings not found"); + } + + /** + * A tester class that is invoked to invoke the CommandLine class, and + * print the result. + */ + public static class Tester { + private static final String[] EMPTY_ARRAY = new String[0]; + static String arrayToString(String... args) { + return String.join(", ", args); + } + public static void main(String... args) throws IOException { + try { + String[] argv = CommandLine.parse("JDK_JAVAC_OPTIONS", EMPTY_ARRAY); + System.out.print(arrayToString(argv)); + } catch (CommandLine.UnmatchedQuote ex) { + System.out.print("Exception: " + ex.variableName); + } + } + } +} diff --git a/langtools/test/tools/javac/meth/BadPolySig.java b/langtools/test/tools/javac/meth/BadPolySig.java deleted file mode 100644 index f607f63c258..00000000000 --- a/langtools/test/tools/javac/meth/BadPolySig.java +++ /dev/null @@ -1,12 +0,0 @@ -/* - * @test - * @bug 8168774 - * @summary Polymorhic signature method check crashes javac - * @compile -Xmodule:java.base BadPolySig.java - */ - -package java.lang.invoke; - -class MethodHandle { - native Object m(); -} diff --git a/jdk/test/tools/jar/multiRelease/data/runtimetest/v10/testpackage/Helper.java b/langtools/test/tools/javac/meth/BadPolySig/BadPolySig.java similarity index 78% rename from jdk/test/tools/jar/multiRelease/data/runtimetest/v10/testpackage/Helper.java rename to langtools/test/tools/javac/meth/BadPolySig/BadPolySig.java index 7071b436757..2d366824685 100644 --- a/jdk/test/tools/jar/multiRelease/data/runtimetest/v10/testpackage/Helper.java +++ b/langtools/test/tools/javac/meth/BadPolySig/BadPolySig.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,13 +21,10 @@ * questions. */ -package testpackage; - -public class Helper { - - private static final int HELPER_VERSION = 10; - - public static int getHelperVersion() { - return HELPER_VERSION; - } -} +/* + * @test + * @bug 8168774 + * @summary Polymorhic signature method check crashes javac + * @modules jdk.compiler + * @compile/module=java.base java/lang/invoke/MethodHandle.java + */ diff --git a/langtools/test/tools/javac/meth/BadPolySig/java.base/java/lang/invoke/MethodHandle.java b/langtools/test/tools/javac/meth/BadPolySig/java.base/java/lang/invoke/MethodHandle.java new file mode 100644 index 00000000000..b748f3e5835 --- /dev/null +++ b/langtools/test/tools/javac/meth/BadPolySig/java.base/java/lang/invoke/MethodHandle.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package java.lang.invoke; + +class MethodHandle { + native Object m(); +} diff --git a/langtools/test/tools/javac/modules/AddLimitMods.java b/langtools/test/tools/javac/modules/AddLimitMods.java index 8c980bb8f86..55b5d82c158 100644 --- a/langtools/test/tools/javac/modules/AddLimitMods.java +++ b/langtools/test/tools/javac/modules/AddLimitMods.java @@ -293,7 +293,7 @@ public class AddLimitMods extends ModuleTestBase { } actual = new JavacTask(tb) - .options("-Xmodule:java.base", + .options("--patch-module", "java.base=" + cpSrc.toString(), "-XDrawDiagnostics", "--add-modules", "ALL-MODULE-PATH") .outdir(cpOut) @@ -418,13 +418,13 @@ public class AddLimitMods extends ModuleTestBase { " public static void main(String... args) throws Exception {\n"); for (Entry e : MODULES_TO_CHECK_TO_SAMPLE_CLASS.entrySet()) { - testClassNamed.append(" System.err.println(\"visible:" + e.getKey() + ":\" + java.lang.reflect.Layer.boot().findModule(\"" + e.getKey() + "\").isPresent());\n"); + testClassNamed.append(" System.err.println(\"visible:" + e.getKey() + ":\" + ModuleLayer.boot().findModule(\"" + e.getKey() + "\").isPresent());\n"); } testClassNamed.append(" Class cp = Class.forName(Test.class.getClassLoader().getUnnamedModule(), \"cp.CP\");\n"); testClassNamed.append(" cp.getDeclaredMethod(\"runMe\").invoke(null);\n"); - testClassNamed.append(" Class automatic = Class.forName(java.lang.reflect.Layer.boot().findModule(\"automatic\").get(), \"automatic.Automatic\");\n"); + testClassNamed.append(" Class automatic = Class.forName(ModuleLayer.boot().findModule(\"automatic\").get(), \"automatic.Automatic\");\n"); testClassNamed.append(" automatic.getDeclaredMethod(\"runMe\").invoke(null);\n"); testClassNamed.append(" }\n" + diff --git a/langtools/test/tools/javac/modules/AddModulesTest.java b/langtools/test/tools/javac/modules/AddModulesTest.java index 8aaba8ecb90..8856fc38f5f 100644 --- a/langtools/test/tools/javac/modules/AddModulesTest.java +++ b/langtools/test/tools/javac/modules/AddModulesTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,17 +23,27 @@ /* * @test + * @bug 8167975 8173596 * @summary Test the --add-modules option * @library /tools/lib * @modules jdk.compiler/com.sun.tools.javac.api * jdk.compiler/com.sun.tools.javac.main - * @build toolbox.ToolBox toolbox.JavacTask ModuleTestBase + * @build toolbox.Assert toolbox.ToolBox toolbox.JavacTask ModuleTestBase * @run main AddModulesTest */ import java.nio.file.Path; +import java.util.Arrays; +import javax.tools.JavaCompiler; +import javax.tools.JavaCompiler.CompilationTask; +import javax.tools.JavaFileObject; +import javax.tools.StandardJavaFileManager; +import javax.tools.StandardLocation; +import javax.tools.ToolProvider; + +import toolbox.Assert; import toolbox.JavacTask; import toolbox.Task; @@ -227,5 +237,46 @@ public class AddModulesTest extends ModuleTestBase { .run() .writeAll(); } + + @Test + public void testAddModulesAPI(Path base) throws Exception { + Path src = base.resolve("src"); + + // setup some utility modules + Path src_m1 = src.resolve("m1x"); + tb.writeJavaFiles(src_m1, + "module m1x { exports p1; }", + "package p1; public class C1 { }"); + Path src_m2 = src.resolve("m2x"); + tb.writeJavaFiles(src_m2, + "module m2x { exports p2; }", + "package p2; public class C2 { }"); + Path modules = base.resolve("modules"); + tb.createDirectories(modules); + + new JavacTask(tb) + .options("--module-source-path", src.toString()) + .outdir(modules) + .files(findJavaFiles(src)) + .run() + .writeAll(); + + // now test access to the modules + Path src2 = base.resolve("src2"); + tb.writeJavaFiles(src2, + "class Dummy { p1.C1 c1; p2.C2 c2; }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + JavaCompiler c = ToolProvider.getSystemJavaCompiler(); + try (StandardJavaFileManager fm = c.getStandardFileManager(null, null, null)) { + fm.setLocationFromPaths(StandardLocation.MODULE_PATH, Arrays.asList(modules)); + fm.setLocationFromPaths(StandardLocation.CLASS_OUTPUT, Arrays.asList(classes)); + Iterable files = fm.getJavaFileObjects(findJavaFiles(src2)); + CompilationTask t = c.getTask(null, fm, null, null, null, files); + t.addModules(Arrays.asList("m1x", "m2x")); + Assert.check(t.call()); + } + } } diff --git a/langtools/test/tools/javac/modules/AddReadsTest.java b/langtools/test/tools/javac/modules/AddReadsTest.java index d03cda631e1..32d023e1d8f 100644 --- a/langtools/test/tools/javac/modules/AddReadsTest.java +++ b/langtools/test/tools/javac/modules/AddReadsTest.java @@ -217,7 +217,7 @@ public class AddReadsTest extends ModuleTestBase { new JavacTask(tb) .options("--class-path", jar.toString(), "--add-reads", "java.base=ALL-UNNAMED", - "-Xmodule:java.base") + "--patch-module", "java.base=" + src) .outdir(classes) .files(src.resolve("impl").resolve("Impl.java")) .run() @@ -237,7 +237,7 @@ public class AddReadsTest extends ModuleTestBase { new JavacTask(tb) .options("--add-modules", "java.desktop", "--add-reads", "java.base=java.desktop", - "-Xmodule:java.base") + "--patch-module", "java.base=" + src) .outdir(classes) .files(findJavaFiles(src)) .run() @@ -304,7 +304,7 @@ public class AddReadsTest extends ModuleTestBase { new JavacTask(tb) .options("--add-reads", "m1x=ALL-UNNAMED", - "-Xmodule:m1x", + "--patch-module", "m1x=" + unnamedSrc, "--module-path", classes.toString()) .outdir(unnamedClasses) .files(findJavaFiles(unnamedSrc)) diff --git a/langtools/test/tools/javac/modules/AllDefaultTest.java b/langtools/test/tools/javac/modules/AllDefaultTest.java index f78b0f19209..77241cc3d24 100644 --- a/langtools/test/tools/javac/modules/AllDefaultTest.java +++ b/langtools/test/tools/javac/modules/AllDefaultTest.java @@ -23,7 +23,7 @@ /** * @test - * @bug 0000000 + * @bug 8164590 8170691 * @summary Test use of ALL-DEFAULT token * @library /tools/lib * @modules diff --git a/langtools/test/tools/javac/modules/AnnotationProcessing.java b/langtools/test/tools/javac/modules/AnnotationProcessing.java index 80a3eb8da83..600d3ade8fb 100644 --- a/langtools/test/tools/javac/modules/AnnotationProcessing.java +++ b/langtools/test/tools/javac/modules/AnnotationProcessing.java @@ -23,7 +23,7 @@ /** * @test - * @bug 8133884 8162711 8133896 8172158 8172262 8173636 + * @bug 8133884 8162711 8133896 8172158 8172262 8173636 8175119 * @summary Verify that annotation processing works. * @library /tools/lib * @modules @@ -37,10 +37,12 @@ import java.io.File; import java.io.IOException; import java.io.OutputStream; import java.io.Reader; +import java.io.UncheckedIOException; import java.io.Writer; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; +import java.util.ArrayList; import java.util.Arrays; import java.util.HashMap; import java.util.HashSet; @@ -49,6 +51,7 @@ import java.util.Map; import java.util.Objects; import java.util.Set; import java.util.concurrent.Callable; +import java.util.function.Consumer; import java.util.function.Function; import java.util.regex.Pattern; import java.util.stream.Collectors; @@ -527,53 +530,173 @@ public class AnnotationProcessing extends ModuleTestBase { tb.writeJavaFiles(m1, "module m1x { exports api1; }", - "package api1; public class Api { GenApi ga; impl.Impl i; }"); + "package api1; public class Api { }", + "package clash; public class C { }"); writeFile("1", m1, "api1", "api"); - writeFile("1", m1, "impl", "impl"); + writeFile("2", m1, "clash", "clash"); Path m2 = moduleSrc.resolve("m2x"); tb.writeJavaFiles(m2, "module m2x { requires m1x; exports api2; }", - "package api2; public class Api { api1.GenApi ga1; GenApi qa2; impl.Impl i;}"); + "package api2; public class Api { }", + "package clash; public class C { }"); - writeFile("2", m2, "api2", "api"); - writeFile("2", m2, "impl", "impl"); + writeFile("3", m2, "api2", "api"); + writeFile("4", m2, "clash", "api"); - for (FileType fileType : FileType.values()) { - if (Files.isDirectory(classes)) { - tb.cleanDirectory(classes); - } else { - Files.createDirectories(classes); + //passing testcases: + for (String module : Arrays.asList("", "m1x/")) { + for (String originating : Arrays.asList("", ", jlObject")) { + tb.writeJavaFiles(m1, + "package test; class Test { api1.Impl i; }"); + + //source: + runCompiler(base, + moduleSrc, + classes, + "createSource(() -> filer.createSourceFile(\"" + module + "api1.Impl\"" + originating + "), \"api1.Impl\", \"package api1; public class Impl {}\")", + "--module-source-path", moduleSrc.toString()); + assertFileExists(classes, "m1x", "api1", "Impl.class"); + + //class: + runCompiler(base, + moduleSrc, + classes, + "createClass(() -> filer.createClassFile(\"" + module + "api1.Impl\"" + originating + "), \"api1.Impl\", \"package api1; public class Impl {}\")", + "--module-source-path", moduleSrc.toString()); + assertFileExists(classes, "m1x", "api1", "Impl.class"); + + Files.delete(m1.resolve("test").resolve("Test.java")); + + //resource class output: + runCompiler(base, + moduleSrc, + classes, + "createSource(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, \"" + module + "api1\", \"impl\"" + originating + "), \"impl\", \"impl\")", + "--module-source-path", moduleSrc.toString()); + assertFileExists(classes, "m1x", "api1", "impl"); } - - new JavacTask(tb) - .options("-processor", MultiModeAPITestAP.class.getName(), - "--module-source-path", moduleSrc.toString(), - "-Afiletype=" + fileType.name()) - .outdir(classes) - .files(findJavaFiles(moduleSrc)) - .run() - .writeAll(); - - assertFileExists(classes, "m1x", "api1", "GenApi.class"); - assertFileExists(classes, "m1x", "impl", "Impl.class"); - assertFileExists(classes, "m1x", "api1", "gen1"); - assertFileExists(classes, "m2x", "api2", "GenApi.class"); - assertFileExists(classes, "m2x", "impl", "Impl.class"); - assertFileExists(classes, "m2x", "api2", "gen1"); } - } - enum FileType { - SOURCE, - CLASS; + //get resource module source path: + runCompiler(base, + m1, + classes, + "doReadResource(() -> filer.getResource(StandardLocation.MODULE_SOURCE_PATH, \"m1x/api1\", \"api\"), \"1\")", + "--module-source-path", moduleSrc.toString()); + + //can generate resources to the single root module: + runCompiler(base, + m1, + classes, + "createSource(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, \"m1x/impl\", \"impl\"), \"impl\", \"impl\")", + "--module-source-path", moduleSrc.toString()); + assertFileExists(classes, "m1x", "impl", "impl"); + + //check --default-module-for-created-files option: + for (String pack : Arrays.asList("clash", "doesnotexist")) { + tb.writeJavaFiles(m1, + "package test; class Test { " + pack + ".Pass i; }"); + runCompiler(base, + moduleSrc, + classes, + "createSource(() -> filer.createSourceFile(\"" + pack + ".Pass\")," + + " \"" + pack + ".Pass\"," + + " \"package " + pack + ";" + + " public class Pass { }\")", + "--module-source-path", moduleSrc.toString(), + "--default-module-for-created-files=m1x"); + assertFileExists(classes, "m1x", pack, "Pass.class"); + assertFileNotExists(classes, "m2x", pack, "Pass.class"); + + runCompiler(base, + moduleSrc, + classes, + "createClass(() -> filer.createClassFile(\"" + pack + ".Pass\")," + + " \"" + pack + ".Pass\"," + + " \"package " + pack + ";" + + " public class Pass { }\")", + "--module-source-path", moduleSrc.toString(), + "--default-module-for-created-files=m1x"); + assertFileExists(classes, "m1x", pack, "Pass.class"); + assertFileNotExists(classes, "m2x", pack, "Pass.class"); + + Files.delete(m1.resolve("test").resolve("Test.java")); + + runCompiler(base, + moduleSrc, + classes, + "createSource(() -> filer.createResource(StandardLocation.CLASS_OUTPUT," + + " \"" + pack + "\", \"impl\"), \"impl\", \"impl\")", + "--module-source-path", moduleSrc.toString(), + "--default-module-for-created-files=m1x"); + assertFileExists(classes, "m1x", pack, "impl"); + assertFileNotExists(classes, "m2x", pack, "impl"); + + runCompiler(base, + moduleSrc, + classes, + "doReadResource(() -> filer.getResource(StandardLocation.CLASS_OUTPUT," + + " \"" + pack + "\", \"resource\"), \"1\")", + p -> writeFile("1", p.resolve("m1x"), pack, "resource"), + "--module-source-path", moduleSrc.toString(), + "--default-module-for-created-files=m1x"); + } + + //wrong default module: + runCompiler(base, + moduleSrc, + classes, + "expectFilerException(() -> filer.createResource(StandardLocation.CLASS_OUTPUT," + + " \"clash\", \"impl\"))", + "--module-source-path", moduleSrc.toString(), + "--default-module-for-created-files=doesnotexist"); + + String[] failingCases = { + //must not generate to unnamed package: + "expectFilerException(() -> filer.createSourceFile(\"Fail\"))", + "expectFilerException(() -> filer.createClassFile(\"Fail\"))", + "expectFilerException(() -> filer.createSourceFile(\"m1x/Fail\"))", + "expectFilerException(() -> filer.createClassFile(\"m1x/Fail\"))", + + //cannot infer module name, package clash: + "expectFilerException(() -> filer.createSourceFile(\"clash.Fail\"))", + "expectFilerException(() -> filer.createClassFile(\"clash.Fail\"))", + "expectFilerException(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, \"clash\", \"impl\"))", + "expectFilerException(() -> filer.getResource(StandardLocation.CLASS_OUTPUT, \"clash\", \"impl\"))", + + //cannot infer module name, package does not exist: + "expectFilerException(() -> filer.createSourceFile(\"doesnotexist.Fail\"))", + "expectFilerException(() -> filer.createClassFile(\"doesnotexist.Fail\"))", + "expectFilerException(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, \"doesnotexist\", \"impl\"))", + "expectFilerException(() -> filer.getResource(StandardLocation.CLASS_OUTPUT, \"doesnotexist\", \"impl\"))", + + //cannot generate sources/classes to modules that are not root modules: + "expectFilerException(() -> filer.createSourceFile(\"java.base/fail.Fail\"))", + "expectFilerException(() -> filer.createClassFile(\"java.base/fail.Fail\"))", + + //cannot read from module locations if module not given and not inferable: + "expectFilerException(() -> filer.getResource(StandardLocation.SYSTEM_MODULES, \"fail\", \"Fail\"))", + + //wrong module given: + "expectException(() -> filer.getResource(StandardLocation.SYSTEM_MODULES, \"java.compiler/java.lang\", \"Object.class\"))", + }; + + for (String failingCode : failingCases) { + System.err.println("failing code: " + failingCode); + runCompiler(base, + moduleSrc, + classes, + failingCode, + "--module-source-path", moduleSrc.toString()); + } } public static abstract class GeneratingAP extends AbstractProcessor { - void createSource(CreateFileObject file, String name, String content) { + public void createSource(CreateFileObject file, String name, String content) { try (Writer out = file.create().openWriter()) { out.write(content); } catch (IOException ex) { @@ -581,7 +704,7 @@ public class AnnotationProcessing extends ModuleTestBase { } } - void createClass(CreateFileObject file, String name, String content) { + public void createClass(CreateFileObject file, String name, String content) { String fileNameStub = name.replace(".", File.separator); try (OutputStream out = file.create().openOutputStream()) { @@ -617,7 +740,7 @@ public class AnnotationProcessing extends ModuleTestBase { } } - void doReadResource(CreateFileObject file, String expectedContent) { + public void doReadResource(CreateFileObject file, String expectedContent) { try { StringBuilder actualContent = new StringBuilder(); @@ -636,11 +759,19 @@ public class AnnotationProcessing extends ModuleTestBase { } } + public void checkResourceExists(CreateFileObject file) { + try { + file.create().openInputStream().close(); + } catch (IOException ex) { + throw new IllegalStateException(ex); + } + } + public interface CreateFileObject { public FileObject create() throws IOException; } - void expectFilerException(Callable c) { + public void expectFilerException(Callable c) { try { c.call(); throw new AssertionError("Expected exception not thrown"); @@ -651,6 +782,17 @@ public class AnnotationProcessing extends ModuleTestBase { } } + public void expectException(Callable c) { + try { + c.call(); + throw new AssertionError("Expected exception not thrown"); + } catch (IOException ex) { + //expected + } catch (Exception ex) { + throw new IllegalStateException(ex); + } + } + @Override public SourceVersion getSupportedSourceVersion() { return SourceVersion.latest(); @@ -658,167 +800,220 @@ public class AnnotationProcessing extends ModuleTestBase { } - @SupportedAnnotationTypes("*") - @SupportedOptions({"filetype", "modulename"}) - public static final class MultiModeAPITestAP extends GeneratingAP { - - int round; - - @Override - public boolean process(Set annotations, RoundEnvironment roundEnv) { - if (round++ != 0) - return false; - - createClass("m1x", "api1.GenApi", "package api1; public class GenApi {}"); - createClass("m1x", "impl.Impl", "package impl; public class Impl {}"); - createClass("m2x", "api2.GenApi", "package api2; public class GenApi {}"); - createClass("m2x", "impl.Impl", "package impl; public class Impl {}"); - - createResource("m1x", "api1", "gen1"); - createResource("m2x", "api2", "gen1"); - - readResource("m1x", "api1", "api", "1"); - readResource("m1x", "impl", "impl", "1"); - readResource("m2x", "api2", "api", "2"); - readResource("m2x", "impl", "impl", "2"); - - Filer filer = processingEnv.getFiler(); - - expectFilerException(() -> filer.createSourceFile("fail.Fail")); - expectFilerException(() -> filer.createClassFile("fail.Fail")); - expectFilerException(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, "fail", "fail")); - expectFilerException(() -> filer.getResource(StandardLocation.MODULE_SOURCE_PATH, "fail", "fail")); - - //must not generate to unnamed package: - expectFilerException(() -> filer.createSourceFile("m1/Fail")); - expectFilerException(() -> filer.createClassFile("m1/Fail")); - - //cannot generate resources to modules that are not root modules: - expectFilerException(() -> filer.createSourceFile("java.base/fail.Fail")); - expectFilerException(() -> filer.createClassFile("java.base/fail.Fail")); - expectFilerException(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, "java.base/fail", "Fail")); - - return false; - } - - void createClass(String expectedModule, String name, String content) { - Filer filer = processingEnv.getFiler(); - FileType filetype = FileType.valueOf(processingEnv.getOptions().getOrDefault("filetype", "")); - - switch (filetype) { - case SOURCE: - createSource(() -> filer.createSourceFile(expectedModule + "/" + name), name, content); - break; - case CLASS: - createClass(() -> filer.createClassFile(expectedModule + "/" + name), name, content); - break; - default: - throw new AssertionError("Unexpected filetype: " + filetype); - } - } - - void createResource(String expectedModule, String pkg, String relName) { - try { - Filer filer = processingEnv.getFiler(); - - filer.createResource(StandardLocation.CLASS_OUTPUT, expectedModule + "/" + pkg, relName) - .openOutputStream() - .close(); - } catch (IOException ex) { - throw new IllegalStateException(ex); - } - } - - void readResource(String expectedModule, String pkg, String relName, String expectedContent) { - Filer filer = processingEnv.getFiler(); - - doReadResource(() -> filer.getResource(StandardLocation.MODULE_SOURCE_PATH, expectedModule + "/" + pkg, relName), - expectedContent); - } - - } - @Test - public void testGenerateInSingleNameModeAPI(Path base) throws Exception { + public void testGenerateSingleModule(Path base) throws Exception { Path classes = base.resolve("classes"); Files.createDirectories(classes); - Path m1 = base.resolve("module-src"); + Path src = base.resolve("module-src"); + Path m1 = src.resolve("m1x"); tb.writeJavaFiles(m1, - "module m1x { }"); + "module m1x { }", + "package test; class Test { impl.Impl i; }"); + Path m2 = src.resolve("m2x"); - writeFile("3", m1, "impl", "resource"); + tb.writeJavaFiles(m2, + "module m2x { }"); - new JavacTask(tb) - .options("-processor", SingleNameModeAPITestAP.class.getName(), - "-sourcepath", m1.toString()) - .outdir(classes) - .files(findJavaFiles(m1)) - .run() - .writeAll(); + for (String[] options : new String[][] {new String[] {"-sourcepath", m1.toString()}, + new String[] {"--module-source-path", src.toString()}}) { + String modulePath = options[0].equals("--module-source-path") ? "m1x" : ""; + //passing testcases: + for (String module : Arrays.asList("", "m1x/")) { + for (String originating : Arrays.asList("", ", jlObject")) { + tb.writeJavaFiles(m1, + "package test; class Test { impl.Impl i; }"); - assertFileExists(classes, "impl", "Impl1.class"); - assertFileExists(classes, "impl", "Impl2.class"); - assertFileExists(classes, "impl", "Impl3"); - assertFileExists(classes, "impl", "Impl4.class"); - assertFileExists(classes, "impl", "Impl5.class"); - assertFileExists(classes, "impl", "Impl6"); - assertFileExists(classes, "impl", "Impl7.class"); - assertFileExists(classes, "impl", "Impl8.class"); - assertFileExists(classes, "impl", "Impl9"); + //source: + runCompiler(base, + m1, + classes, + "createSource(() -> filer.createSourceFile(\"" + module + "impl.Impl\"" + originating + "), \"impl.Impl\", \"package impl; public class Impl {}\")", + options); + assertFileExists(classes, modulePath, "impl", "Impl.class"); + + //class: + runCompiler(base, + m1, + classes, + "createClass(() -> filer.createClassFile(\"" + module + "impl.Impl\"" + originating + "), \"impl.Impl\", \"package impl; public class Impl {}\")", + options); + assertFileExists(classes, modulePath, "impl", "Impl.class"); + + Files.delete(m1.resolve("test").resolve("Test.java")); + + //resource class output: + runCompiler(base, + m1, + classes, + "createSource(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, \"impl\", \"impl\"" + originating + "), \"impl\", \"impl\")", + options); + assertFileExists(classes, modulePath, "impl", "impl"); + } + } + } + + //get resource source path: + writeFile("1", m1, "impl", "resource"); + runCompiler(base, + m1, + classes, + "doReadResource(() -> filer.getResource(StandardLocation.SOURCE_PATH, \"impl\", \"resource\"), \"1\")", + "-sourcepath", m1.toString()); + //must not specify module when reading non-module oriented locations: + runCompiler(base, + m1, + classes, + "expectFilerException(() -> filer.getResource(StandardLocation.SOURCE_PATH, \"m1x/impl\", \"resource\"))", + "-sourcepath", m1.toString()); + + Files.delete(m1.resolve("impl").resolve("resource")); + + //can read resources from the system module path if module name given: + runCompiler(base, + m1, + classes, + "checkResourceExists(() -> filer.getResource(StandardLocation.SYSTEM_MODULES, \"java.base/java.lang\", \"Object.class\"))", + "-sourcepath", m1.toString()); + + //can read resources from the system module path if module inferable: + runCompiler(base, + m1, + classes, + "expectFilerException(() -> filer.getResource(StandardLocation.SYSTEM_MODULES, \"java.lang\", \"Object.class\"))", + "-sourcepath", m1.toString()); + + //cannot generate resources to modules that are not root modules: + runCompiler(base, + m1, + classes, + "expectFilerException(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, \"java.base/fail\", \"Fail\"))", + "--module-source-path", src.toString()); + + //can generate resources to the single root module: + runCompiler(base, + m1, + classes, + "createSource(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, \"impl\", \"impl\"), \"impl\", \"impl\")", + "--module-source-path", src.toString()); + assertFileExists(classes, "m1x", "impl", "impl"); + + String[] failingCases = { + //must not generate to unnamed package: + "expectFilerException(() -> filer.createSourceFile(\"Fail\"))", + "expectFilerException(() -> filer.createClassFile(\"Fail\"))", + "expectFilerException(() -> filer.createSourceFile(\"m1x/Fail\"))", + "expectFilerException(() -> filer.createClassFile(\"m1x/Fail\"))", + + //cannot generate sources/classes to modules that are not root modules: + "expectFilerException(() -> filer.createSourceFile(\"java.base/fail.Fail\"))", + "expectFilerException(() -> filer.createClassFile(\"java.base/fail.Fail\"))", + + //cannot specify module name for class output when not in the multi-module mode: + "expectFilerException(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, \"m1x/fail\", \"Fail\"))", + + //cannot read from module locations if module not given: + "expectFilerException(() -> filer.getResource(StandardLocation.SYSTEM_MODULES, \"fail\", \"Fail\"))", + + //wrong module given: + "expectException(() -> filer.getResource(StandardLocation.SYSTEM_MODULES, \"java.compiler/java.lang\", \"Object.class\"))", + }; + + for (String failingCode : failingCases) { + System.err.println("failing code: " + failingCode); + runCompiler(base, + m1, + classes, + failingCode, + "-sourcepath", m1.toString()); + } + + Files.delete(m1.resolve("module-info.java")); + tb.writeJavaFiles(m1, + "package test; class Test { }"); + + runCompiler(base, + m1, + classes, + "expectFilerException(() -> filer.createSourceFile(\"m1x/impl.Impl\"))", + "-sourcepath", m1.toString(), + "-source", "8"); + + runCompiler(base, + m1, + classes, + "expectFilerException(() -> filer.createClassFile(\"m1x/impl.Impl\"))", + "-sourcepath", m1.toString(), + "-source", "8"); } + private void runCompiler(Path base, Path src, Path classes, + String code, String... options) throws IOException { + runCompiler(base, src, classes, code, p -> {}, options); + } - @SupportedAnnotationTypes("*") - public static final class SingleNameModeAPITestAP extends GeneratingAP { - - int round; - - @Override - public synchronized void init(ProcessingEnvironment processingEnv) { - super.init(processingEnv); + private void runCompiler(Path base, Path src, Path classes, + String code, Consumer generateToClasses, + String... options) throws IOException { + Path apClasses = base.resolve("ap-classes"); + if (Files.exists(apClasses)) { + tb.cleanDirectory(apClasses); + } else { + Files.createDirectories(apClasses); } - - @Override - public boolean process(Set annotations, RoundEnvironment roundEnv) { - if (round++ != 0) - return false; - - Filer filer = processingEnv.getFiler(); - - createSource(() -> filer.createSourceFile("impl.Impl1"), "impl.Impl1", "package impl; class Impl1 {}"); - createClass(() -> filer.createClassFile("impl.Impl2"), "impl.Impl2", "package impl; class Impl2 {}"); - createSource(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, "impl", "Impl3"), "impl.Impl3", ""); - doReadResource(() -> filer.getResource(StandardLocation.SOURCE_PATH, "impl", "resource"), "3"); - - createSource(() -> filer.createSourceFile("m1x/impl.Impl4"), "impl.Impl4", "package impl; class Impl4 {}"); - createClass(() -> filer.createClassFile("m1x/impl.Impl5"), "impl.Impl5", "package impl; class Impl5 {}"); - createSource(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, "m1x/impl", "Impl6"), "impl.Impl6", ""); - doReadResource(() -> filer.getResource(StandardLocation.SOURCE_PATH, "m1x/impl", "resource"), "3"); - - TypeElement jlObject = processingEnv.getElementUtils().getTypeElement("java.lang.Object"); - - //"broken" originating element: - createSource(() -> filer.createSourceFile("impl.Impl7", jlObject), "impl.Impl7", "package impl; class Impl7 {}"); - createClass(() -> filer.createClassFile("impl.Impl8", jlObject), "impl.Impl8", "package impl; class Impl8 {}"); - createSource(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, "impl", "Impl9", jlObject), "impl.Impl9", ""); - - //must not generate to unnamed package: - expectFilerException(() -> filer.createSourceFile("Fail")); - expectFilerException(() -> filer.createClassFile("Fail")); - expectFilerException(() -> filer.createSourceFile("m1x/Fail")); - expectFilerException(() -> filer.createClassFile("m1x/Fail")); - - //cannot generate resources to modules that are not root modules: - expectFilerException(() -> filer.createSourceFile("java.base/fail.Fail")); - expectFilerException(() -> filer.createClassFile("java.base/fail.Fail")); - expectFilerException(() -> filer.createResource(StandardLocation.CLASS_OUTPUT, "java.base/fail", "Fail")); - - return false; + compileAP(apClasses, code); + if (Files.exists(classes)) { + tb.cleanDirectory(classes); + } else { + Files.createDirectories(classes); } + generateToClasses.accept(classes); + List opts = new ArrayList<>(); + opts.addAll(Arrays.asList(options)); + opts.add("-processorpath"); + opts.add(System.getProperty("test.class.path") + File.pathSeparator + apClasses.toString()); + opts.add("-processor"); + opts.add("AP"); + new JavacTask(tb) + .options(opts) + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll(); + } + private void compileAP(Path target, String code) { + String processorCode = + "import java.util.*;\n" + + "import javax.annotation.processing.*;\n" + + "import javax.lang.model.*;\n" + + "import javax.lang.model.element.*;\n" + + "import javax.lang.model.type.*;\n" + + "import javax.lang.model.util.*;\n" + + "import javax.tools.*;\n" + + "@SupportedAnnotationTypes(\"*\")\n" + + "public final class AP extends AnnotationProcessing.GeneratingAP {\n" + + "\n" + + " int round;\n" + + "\n" + + " @Override\n" + + " public boolean process(Set annotations, RoundEnvironment roundEnv) {\n" + + " if (round++ != 0)\n" + + " return false;\n" + + " Filer filer = processingEnv.getFiler();\n" + + " TypeElement jlObject = processingEnv.getElementUtils().getTypeElement(\"java.lang.Object\");\n" + + code + ";\n" + + " return false;\n" + + " }\n" + + " }\n"; + new JavacTask(tb) + .options("-classpath", System.getProperty("test.class.path")) + .sources(processorCode) + .outdir(target) + .run() + .writeAll(); } @Test @@ -1089,13 +1284,17 @@ public class AnnotationProcessing extends ModuleTestBase { } - private static void writeFile(String content, Path base, String... pathElements) throws IOException { - Path file = resolveFile(base, pathElements); + private static void writeFile(String content, Path base, String... pathElements) { + try { + Path file = resolveFile(base, pathElements); - Files.createDirectories(file.getParent()); + Files.createDirectories(file.getParent()); - try (Writer out = Files.newBufferedWriter(file)) { - out.append(content); + try (Writer out = Files.newBufferedWriter(file)) { + out.append(content); + } + } catch (IOException ex) { + throw new UncheckedIOException(ex); } } @@ -1286,6 +1485,35 @@ public class AnnotationProcessing extends ModuleTestBase { } + @Test + public void testWrongDefaultTargetModule(Path base) throws Exception { + Path src = base.resolve("src"); + + tb.writeJavaFiles(src, + "package test; public class Test { }"); + + Path classes = base.resolve("classes"); + + Files.createDirectories(classes); + + List log = new JavacTask(tb) + .options("--default-module-for-created-files=m!", + "-XDrawDiagnostics") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(OutputKind.DIRECT); + + List expected = Arrays.asList( + "- compiler.err.bad.name.for.option: --default-module-for-created-files, m!" + ); + + if (!log.equals(expected)) { + throw new AssertionError("Expected output not found."); + } + } + private static void assertNonNull(String msg, Object val) { if (val == null) { throw new AssertionError(msg); @@ -1312,6 +1540,14 @@ public class AnnotationProcessing extends ModuleTestBase { } } + private static void assertFileNotExists(Path base, String... pathElements) { + Path file = resolveFile(base, pathElements); + + if (Files.exists(file)) { + throw new AssertionError("Expected file: " + file + " exist, but it does not."); + } + } + static Path resolveFile(Path base, String... pathElements) { Path file = base; diff --git a/langtools/test/tools/javac/modules/AutomaticModules.java b/langtools/test/tools/javac/modules/AutomaticModules.java index fa7524d1786..75b03739437 100644 --- a/langtools/test/tools/javac/modules/AutomaticModules.java +++ b/langtools/test/tools/javac/modules/AutomaticModules.java @@ -23,7 +23,7 @@ /** * @test - * @bug 8155026 + * @bug 8155026 8178011 * @summary Test automatic modules * @library /tools/lib * @modules @@ -300,9 +300,8 @@ public class AutomaticModules extends ModuleTestBase { .writeAll() .getOutputLines(Task.OutputKind.DIRECT); - expected = Arrays.asList("Impl.java:1:47: compiler.err.package.not.visible: apiB, (compiler.misc.not.def.access.does.not.read: m1x, apiB, automaticB)", - "Impl.java:1:59: compiler.err.package.not.visible: m2x, (compiler.misc.not.def.access.does.not.read: m1x, m2x, m2x)", - "2 errors"); + expected = Arrays.asList("Impl.java:1:59: compiler.err.package.not.visible: m2x, (compiler.misc.not.def.access.does.not.read: m1x, m2x, m2x)", + "1 error"); if (!expected.equals(log)) { throw new Exception("expected output not found: " + log); @@ -310,7 +309,7 @@ public class AutomaticModules extends ModuleTestBase { } @Test - public void testDropTrailingVersion(Path base) throws Exception { + public void testWithTrailingVersion(Path base) throws Exception { Path legacySrc = base.resolve("legacy-src"); tb.writeJavaFiles(legacySrc, "package api; public class Api {}"); @@ -348,7 +347,7 @@ public class AutomaticModules extends ModuleTestBase { Files.createDirectories(classes); tb.writeJavaFiles(m, - "module m { requires test; }", + "module m { requires test1; }", "package impl; public class Impl { public void e(api.Api api) { } }"); new JavacTask(tb) @@ -358,4 +357,261 @@ public class AutomaticModules extends ModuleTestBase { .run() .writeAll(); } + + @Test + public void testMultipleAutomatic(Path base) throws Exception { + Path modulePath = base.resolve("module-path"); + + Files.createDirectories(modulePath); + + for (char c : new char[] {'A', 'B'}) { + Path automaticSrc = base.resolve("automaticSrc" + c); + tb.writeJavaFiles(automaticSrc, "package api" + c + "; public class Api {}"); + Path automaticClasses = base.resolve("automaticClasses" + c); + tb.createDirectories(automaticClasses); + + String automaticLog = new JavacTask(tb) + .outdir(automaticClasses) + .files(findJavaFiles(automaticSrc)) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!automaticLog.isEmpty()) + throw new Exception("expected output not found: " + automaticLog); + + Path automaticJar = modulePath.resolve("automatic" + c + "-1.0.jar"); + + new JarTask(tb, automaticJar) + .baseDir(automaticClasses) + .files("api" + c + "/Api.class") + .run(); + } + + Path src = base.resolve("src"); + + tb.writeJavaFiles(src.resolve("m1x"), + "package impl; public class Impl { apiA.Api a; apiB.Api b; }"); + + Path classes = base.resolve("classes"); + + Files.createDirectories(classes); + + List log = new JavacTask(tb) + .options("--module-path", modulePath.toString(), + "-XDrawDiagnostics") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + List expected = Arrays.asList("Impl.java:1:35: compiler.err.package.not.visible: apiA, (compiler.misc.not.def.access.does.not.read.from.unnamed: apiA, automaticA)", + "Impl.java:1:47: compiler.err.package.not.visible: apiB, (compiler.misc.not.def.access.does.not.read.from.unnamed: apiB, automaticB)", + "2 errors"); + + if (!expected.equals(log)) { + throw new Exception("expected output not found: " + log); + } + + new JavacTask(tb) + .options("--module-path", modulePath.toString(), + "--add-modules", "automaticA", + "-XDrawDiagnostics") + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll(); + } + + @Test + public void testLintRequireAutomatic(Path base) throws Exception { + Path modulePath = base.resolve("module-path"); + + Files.createDirectories(modulePath); + + for (char c : new char[] {'A', 'B'}) { + Path automaticSrc = base.resolve("automaticSrc" + c); + tb.writeJavaFiles(automaticSrc, "package api" + c + "; public class Api {}"); + Path automaticClasses = base.resolve("automaticClasses" + c); + tb.createDirectories(automaticClasses); + + String automaticLog = new JavacTask(tb) + .outdir(automaticClasses) + .files(findJavaFiles(automaticSrc)) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!automaticLog.isEmpty()) + throw new Exception("expected output not found: " + automaticLog); + + Path automaticJar = modulePath.resolve("automatic" + c + "-1.0.jar"); + + new JarTask(tb, automaticJar) + .baseDir(automaticClasses) + .files("api" + c + "/Api.class") + .run(); + } + + Path src = base.resolve("src"); + + tb.writeJavaFiles(src, + "module m1x {\n" + + " requires transitive automaticA;\n" + + " requires automaticB;\n" + + "}"); + + Path classes = base.resolve("classes"); + + Files.createDirectories(classes); + + List expected; + List log; + + log = new JavacTask(tb) + .options("--source-path", src.toString(), + "--module-path", modulePath.toString(), + "-XDrawDiagnostics", + "-Werror") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + expected = Arrays.asList("module-info.java:2:25: compiler.warn.requires.transitive.automatic", + "- compiler.err.warnings.and.werror", + "1 error", + "1 warning"); + + if (!expected.equals(log)) { + throw new Exception("expected output not found: " + log); + } + + log = new JavacTask(tb) + .options("--source-path", src.toString(), + "--module-path", modulePath.toString(), + "-Xlint:requires-automatic", + "-XDrawDiagnostics", + "-Werror") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + expected = Arrays.asList("module-info.java:2:25: compiler.warn.requires.transitive.automatic", + "module-info.java:3:14: compiler.warn.requires.automatic", + "- compiler.err.warnings.and.werror", + "1 error", + "2 warnings"); + + if (!expected.equals(log)) { + throw new Exception("expected output not found: " + log); + } + + log = new JavacTask(tb) + .options("--source-path", src.toString(), + "--module-path", modulePath.toString(), + "-Xlint:-requires-transitive-automatic,requires-automatic", + "-XDrawDiagnostics", + "-Werror") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + expected = Arrays.asList("module-info.java:2:25: compiler.warn.requires.automatic", + "module-info.java:3:14: compiler.warn.requires.automatic", + "- compiler.err.warnings.and.werror", + "1 error", + "2 warnings"); + + if (!expected.equals(log)) { + throw new Exception("expected output not found: " + log); + } + + new JavacTask(tb) + .options("--source-path", src.toString(), + "--module-path", modulePath.toString(), + "-Xlint:-requires-transitive-automatic", + "-XDrawDiagnostics", + "-Werror") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + tb.writeJavaFiles(src, + "@SuppressWarnings(\"requires-transitive-automatic\")\n" + + "module m1x {\n" + + " requires transitive automaticA;\n" + + " requires automaticB;\n" + + "}"); + + new JavacTask(tb) + .options("--source-path", src.toString(), + "--module-path", modulePath.toString(), + "-XDrawDiagnostics", + "-Werror") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + log = new JavacTask(tb) + .options("--source-path", src.toString(), + "--module-path", modulePath.toString(), + "-Xlint:requires-automatic", + "-XDrawDiagnostics", + "-Werror") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + expected = Arrays.asList("module-info.java:3:25: compiler.warn.requires.automatic", + "module-info.java:4:14: compiler.warn.requires.automatic", + "- compiler.err.warnings.and.werror", + "1 error", + "2 warnings"); + + if (!expected.equals(log)) { + throw new Exception("expected output not found: " + log); + } + + tb.writeJavaFiles(src, + "@SuppressWarnings(\"requires-automatic\")\n" + + "module m1x {\n" + + " requires transitive automaticA;\n" + + " requires automaticB;\n" + + "}"); + + log = new JavacTask(tb) + .options("--source-path", src.toString(), + "--module-path", modulePath.toString(), + "-Xlint:requires-automatic", + "-XDrawDiagnostics", + "-Werror") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + expected = Arrays.asList("module-info.java:3:25: compiler.warn.requires.transitive.automatic", + "- compiler.err.warnings.and.werror", + "1 error", + "1 warning"); + + if (!expected.equals(log)) { + throw new Exception("expected output not found: " + log); + } + } + } diff --git a/langtools/test/tools/javac/modules/XModuleTest.java b/langtools/test/tools/javac/modules/CompileModulePatchTest.java similarity index 53% rename from langtools/test/tools/javac/modules/XModuleTest.java rename to langtools/test/tools/javac/modules/CompileModulePatchTest.java index 2ddeacbb7ef..1ff40cdcc6c 100644 --- a/langtools/test/tools/javac/modules/XModuleTest.java +++ b/langtools/test/tools/javac/modules/CompileModulePatchTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,6 +23,7 @@ /* * @test + * @bug 8173777 * @summary tests for multi-module mode compilation * @library /tools/lib * @modules @@ -31,13 +32,15 @@ * jdk.compiler/com.sun.tools.javac.main * jdk.compiler/com.sun.tools.javac.processing * @build toolbox.ToolBox toolbox.JavacTask toolbox.ModuleBuilder ModuleTestBase - * @run main XModuleTest + * @run main CompileModulePatchTest */ +import java.nio.file.Files; import java.nio.file.Path; import java.util.Arrays; import java.util.List; import java.util.Set; +import java.util.stream.Collectors; import javax.annotation.processing.AbstractProcessor; import javax.annotation.processing.RoundEnvironment; @@ -54,14 +57,14 @@ import toolbox.ModuleBuilder; import toolbox.Task; import toolbox.Task.Expect; -public class XModuleTest extends ModuleTestBase { +public class CompileModulePatchTest extends ModuleTestBase { public static void main(String... args) throws Exception { - new XModuleTest().runTests(); + new CompileModulePatchTest().runTests(); } @Test - public void testCorrectXModule(Path base) throws Exception { + public void testCorrectModulePatch(Path base) throws Exception { //note: avoiding use of java.base, as that gets special handling on some places: Path src = base.resolve("src"); tb.writeJavaFiles(src, "package javax.lang.model.element; public interface Extra extends Element { }"); @@ -69,7 +72,7 @@ public class XModuleTest extends ModuleTestBase { tb.createDirectories(classes); String log = new JavacTask(tb) - .options("-Xmodule:java.compiler") + .options("--patch-module", "java.compiler=" + src.toString()) .outdir(classes) .files(findJavaFiles(src)) .run() @@ -81,23 +84,138 @@ public class XModuleTest extends ModuleTestBase { } @Test - public void testSourcePath(Path base) throws Exception { + public void testCorrectModulePatchMultiModule(Path base) throws Exception { //note: avoiding use of java.base, as that gets special handling on some places: Path src = base.resolve("src"); - tb.writeJavaFiles(src, "package javax.lang.model.element; public interface Extra extends Element, Other { }", "package javax.lang.model.element; interface Other { }"); + Path m1 = src.resolve("m1"); + tb.writeJavaFiles(m1, "package javax.lang.model.element; public interface Extra extends Element { }"); + Path m2 = src.resolve("m2"); + tb.writeJavaFiles(m2, "package com.sun.source.tree; public interface Extra extends Tree { }"); Path classes = base.resolve("classes"); tb.createDirectories(classes); String log = new JavacTask(tb) - .options("-Xmodule:java.compiler", "-sourcepath", src.toString()) + .options("--patch-module", "java.compiler=" + m1.toString(), + "--patch-module", "jdk.compiler=" + m2.toString(), + "--module-source-path", "dummy") .outdir(classes) - .files(src.resolve("javax/lang/model/element/Extra.java")) + .files(findJavaFiles(src)) .run() .writeAll() .getOutput(Task.OutputKind.DIRECT); if (!log.isEmpty()) throw new Exception("expected output not found: " + log); + + checkFileExists(classes, "java.compiler/javax/lang/model/element/Extra.class"); + checkFileExists(classes, "jdk.compiler/com/sun/source/tree/Extra.class"); + } + + @Test + public void testCorrectModulePatchMultiModule2(Path base) throws Exception { + //note: avoiding use of java.base, as that gets special handling on some places: + Path src = base.resolve("src"); + Path m1 = src.resolve("m1"); + tb.writeJavaFiles(m1, + "package javax.lang.model.element; public interface Extra extends Element { }"); + Path m2 = src.resolve("m2"); + tb.writeJavaFiles(m2, + "package com.sun.source.tree; public interface Extra extends Tree { }"); + Path msp = base.resolve("msp"); + Path m3 = msp.resolve("m3x"); + tb.writeJavaFiles(m3, + "module m3x { }", + "package m3; public class Test { }"); + Path m4 = msp.resolve("m4x"); + tb.writeJavaFiles(m4, + "module m4x { }", + "package m4; public class Test { }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + String log = new JavacTask(tb) + .options("--patch-module", "java.compiler=" + m1.toString(), + "--patch-module", "jdk.compiler=" + m2.toString(), + "--module-source-path", msp.toString()) + .outdir(classes) + .files(findJavaFiles(src, msp)) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.isEmpty()) + throw new Exception("expected output not found: " + log); + + checkFileExists(classes, "java.compiler/javax/lang/model/element/Extra.class"); + checkFileExists(classes, "jdk.compiler/com/sun/source/tree/Extra.class"); + checkFileExists(classes, "m3x/m3/Test.class"); + checkFileExists(classes, "m4x/m4/Test.class"); + } + + @Test + public void testPatchModuleModuleSourcePathConflict(Path base) throws Exception { + //note: avoiding use of java.base, as that gets special handling on some places: + Path src = base.resolve("src"); + Path m1 = src.resolve("m1x"); + tb.writeJavaFiles(m1, + "module m1x { }", + "package m1; public class Test { }"); + Path m2 = src.resolve("m2x"); + tb.writeJavaFiles(m2, + "module m2x { }", + "package m2; public class Test { }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + List log = new JavacTask(tb) + .options("--patch-module", "m1x=" + m2.toString(), + "--module-source-path", src.toString(), + "-XDrawDiagnostics") + .outdir(classes) + .files(findJavaFiles(src.resolve("m1x").resolve("m1"), + src.resolve("m2x").resolve("m2"))) + .run(Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + List expectedOut = Arrays.asList( + "Test.java:1:1: compiler.err.file.patched.and.msp: m1x, m2x", + "module-info.java:1:1: compiler.err.module.name.mismatch: m2x, m1x", + "- compiler.err.cant.access: m1x.module-info, (compiler.misc.cant.resolve.modules)", + "3 errors" + ); + + if (!expectedOut.equals(log)) + throw new Exception("expected output not found: " + log); + } + + @Test + public void testSourcePath(Path base) throws Exception { + //note: avoiding use of java.base, as that gets special handling on some places: + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "package javax.lang.model.element; public interface Extra extends Element, Other { }"); + Path srcPath = base.resolve("src-path"); + tb.writeJavaFiles(srcPath, "package javax.lang.model.element; interface Other { }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + List log = new JavacTask(tb) + .options("--patch-module", "java.compiler=" + src.toString(), + "-sourcepath", srcPath.toString(), + "-XDrawDiagnostics") + .outdir(classes) + .files(src.resolve("javax/lang/model/element/Extra.java")) + .run(Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + List expectedOut = Arrays.asList( + "Extra.java:1:75: compiler.err.cant.resolve: kindname.class, Other, , ", + "1 error" + ); + + if (!expectedOut.equals(log)) + throw new Exception("expected output not found: " + log); } @Test @@ -124,7 +242,7 @@ public class XModuleTest extends ModuleTestBase { tb.createDirectories(classes); List log = new JavacTask(tb) - .options("-Xmodule:java.compiler", + .options("--patch-module", "java.compiler=" + src.toString(), "--class-path", cpClasses.toString(), "-XDrawDiagnostics") .outdir(classes) @@ -142,117 +260,6 @@ public class XModuleTest extends ModuleTestBase { throw new Exception("expected output not found: " + log); } - @Test - public void testNoModuleInfoOnSourcePath(Path base) throws Exception { - //note: avoiding use of java.base, as that gets special handling on some places: - Path src = base.resolve("src"); - tb.writeJavaFiles(src, - "module java.compiler {}", - "package javax.lang.model.element; public interface Extra { }"); - Path classes = base.resolve("classes"); - tb.createDirectories(classes); - - List log = new JavacTask(tb) - .options("-XDrawDiagnostics", "-Xmodule:java.compiler") - .outdir(classes) - .files(findJavaFiles(src)) - .run(Task.Expect.FAIL) - .writeAll() - .getOutputLines(Task.OutputKind.DIRECT); - - List expected = Arrays.asList("Extra.java:1:1: compiler.err.module-info.with.xmodule.sourcepath", - "1 error"); - - if (!expected.equals(log)) - throw new Exception("expected output not found: " + log); - } - - @Test - public void testNoModuleInfoInClassOutput(Path base) throws Exception { - //note: avoiding use of java.base, as that gets special handling on some places: - Path srcMod = base.resolve("src-mod"); - tb.writeJavaFiles(srcMod, - "module mod {}"); - Path classes = base.resolve("classes"); - tb.createDirectories(classes); - - String logMod = new JavacTask(tb) - .options() - .outdir(classes) - .files(findJavaFiles(srcMod)) - .run() - .writeAll() - .getOutput(Task.OutputKind.DIRECT); - - if (!logMod.isEmpty()) - throw new Exception("unexpected output found: " + logMod); - - Path src = base.resolve("src"); - tb.writeJavaFiles(src, - "package javax.lang.model.element; public interface Extra { }"); - tb.createDirectories(classes); - - List log = new JavacTask(tb) - .options("-XDrawDiagnostics", "-Xmodule:java.compiler") - .outdir(classes) - .files(findJavaFiles(src)) - .run(Task.Expect.FAIL) - .writeAll() - .getOutputLines(Task.OutputKind.DIRECT); - - List expected = Arrays.asList("Extra.java:1:1: compiler.err.module-info.with.xmodule.classpath", - "1 error"); - - if (!expected.equals(log)) - throw new Exception("expected output not found: " + log); - } - - @Test - public void testModuleSourcePathXModule(Path base) throws Exception { - //note: avoiding use of java.base, as that gets special handling on some places: - Path src = base.resolve("src"); - tb.writeJavaFiles(src, "package javax.lang.model.element; public interface Extra extends Element { }"); - Path classes = base.resolve("classes"); - tb.createDirectories(classes); - - List log = new JavacTask(tb) - .options("-XDrawDiagnostics", "-Xmodule:java.compiler", "--module-source-path", src.toString()) - .outdir(classes) - .files(findJavaFiles(src)) - .run(Task.Expect.FAIL) - .writeAll() - .getOutputLines(Task.OutputKind.DIRECT); - - List expected = Arrays.asList("- compiler.err.xmodule.no.module.sourcepath"); - - if (!expected.equals(log)) - throw new Exception("expected output not found: " + log); - } - - @Test - public void testXModuleTooMany(Path base) throws Exception { - //note: avoiding use of java.base, as that gets special handling on some places: - Path src = base.resolve("src"); - tb.writeJavaFiles(src, "package javax.lang.model.element; public interface Extra extends Element { }"); - Path classes = base.resolve("classes"); - tb.createDirectories(classes); - - List log = new JavacTask(tb, Task.Mode.CMDLINE) - .options("-XDrawDiagnostics", "-Xmodule:java.compiler", "-Xmodule:java.compiler") - .outdir(classes) - .files(findJavaFiles(src)) - .run(Task.Expect.FAIL) - .writeAll() - .getOutputLines(Task.OutputKind.DIRECT); - - List expected = Arrays.asList("javac: option -Xmodule: can only be specified once", - "Usage: javac ", - "use --help for a list of possible options"); - - if (!expected.equals(log)) - throw new Exception("expected output not found: " + log); - } - @Test public void testWithModulePath(Path base) throws Exception { Path modSrc = base.resolve("modSrc"); @@ -266,7 +273,7 @@ public class XModuleTest extends ModuleTestBase { new JavacTask(tb, Task.Mode.CMDLINE) .options("--module-path", modules.toString(), - "-Xmodule:m1") + "--patch-module", "m1=" + src.toString()) .files(findJavaFiles(src)) .run() .writeAll(); @@ -282,7 +289,7 @@ public class XModuleTest extends ModuleTestBase { List log = new JavacTask(tb, Task.Mode.CMDLINE) .options("-XDrawDiagnostics", "--module-path", modules.toString(), - "-Xmodule:m1") + "--patch-module", "m1=" + src2.toString()) .files(findJavaFiles(src2)) .run(Task.Expect.FAIL) .writeAll() @@ -315,7 +322,7 @@ public class XModuleTest extends ModuleTestBase { new JavacTask(tb, Task.Mode.CMDLINE) .options("--module-path", modules.toString(), "--upgrade-module-path", upgrade.toString(), - "-Xmodule:m1") + "--patch-module", "m1=" + src.toString()) .files(findJavaFiles(src)) .run() .writeAll(); @@ -365,7 +372,7 @@ public class XModuleTest extends ModuleTestBase { tb.createDirectories(classes); String log = new JavacTask(tb) - .options("-Xmodule:m", + .options("--patch-module", "m=" + sourcePath.toString(), "--class-path", classPath.toString(), "--source-path", sourcePath.toString(), "--module-path", modulePath.toString(), @@ -419,4 +426,165 @@ public class XModuleTest extends ModuleTestBase { } } + @Test + public void testSingleModeIncremental(Path base) throws Exception { + //note: avoiding use of java.base, as that gets special handling on some places: + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "package javax.lang.model.element; public interface Extra extends Element { }", + "package javax.lang.model.element; public interface Extra2 extends Extra { }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + Thread.sleep(2000); //ensure newer timestamps on classfiles: + + new JavacTask(tb) + .options("--patch-module", "java.compiler=" + src.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + List log = new JavacTask(tb) + .options("--patch-module", "java.compiler=" + src.toString(), + "-verbose") + .outdir(classes) + .files(findJavaFiles(src.resolve("javax/lang/model/element/Extra2.java" + .replace("/", src.getFileSystem().getSeparator())))) + .run() + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT) + .stream() + .filter(l -> l.contains("parsing")) + .collect(Collectors.toList()); + + boolean parsesExtra2 = log.stream() + .anyMatch(l -> l.contains("Extra2.java")); + boolean parsesExtra = log.stream() + .anyMatch(l -> l.contains("Extra.java")); + + if (!parsesExtra2 || parsesExtra) { + throw new AssertionError("Unexpected output: " + log); + } + } + + @Test + public void testComplexMSPAndPatch(Path base) throws Exception { + //note: avoiding use of java.base, as that gets special handling on some places: + Path src1 = base.resolve("src1"); + Path src1ma = src1.resolve("ma"); + tb.writeJavaFiles(src1ma, + "module ma { exports ma; }", + "package ma; public class C1 { public static void method() { } }", + "package ma.impl; public class C2 { }"); + Path src1mb = src1.resolve("mb"); + tb.writeJavaFiles(src1mb, + "module mb { requires ma; }", + "package mb.impl; public class C2 { public static void method() { } }"); + Path src1mc = src1.resolve("mc"); + tb.writeJavaFiles(src1mc, + "module mc { }"); + Path classes1 = base.resolve("classes1"); + tb.createDirectories(classes1); + tb.cleanDirectory(classes1); + + new JavacTask(tb) + .options("--module-source-path", src1.toString()) + .files(findJavaFiles(src1)) + .outdir(classes1) + .run() + .writeAll(); + + //patching: + Path src2 = base.resolve("src2"); + Path src2ma = src2.resolve("ma"); + tb.writeJavaFiles(src2ma, + "package ma.impl; public class C2 { public static void extra() { ma.C1.method(); } }", + "package ma.impl; public class C3 { public void test() { C2.extra(); } }"); + Path src2mb = src2.resolve("mb"); + tb.writeJavaFiles(src2mb, + "package mb.impl; public class C3 { public void test() { C2.method(); ma.C1.method(); ma.impl.C2.extra(); } }"); + Path src2mc = src2.resolve("mc"); + tb.writeJavaFiles(src2mc, + "package mc.impl; public class C2 { public static void test() { } }", + //will require --add-reads ma: + "package mc.impl; public class C3 { public static void test() { ma.impl.C2.extra(); } }"); + Path src2mt = src2.resolve("mt"); + tb.writeJavaFiles(src2mt, + "module mt { requires ma; requires mb; }", + "package mt.impl; public class C2 { public static void test() { mb.impl.C2.method(); ma.impl.C2.extra(); } }", + "package mt.impl; public class C3 { public static void test() { C2.test(); mc.impl.C2.test(); } }"); + Path classes2 = base.resolve("classes2"); + tb.createDirectories(classes2); + tb.cleanDirectory(classes2); + + Thread.sleep(2000); //ensure newer timestamps on classfiles: + + new JavacTask(tb) + .options("--module-path", classes1.toString(), + "--patch-module", "ma=" + src2ma.toString(), + "--patch-module", "mb=" + src2mb.toString(), + "--add-exports", "ma/ma.impl=mb", + "--patch-module", "mc=" + src2mc.toString(), + "--add-reads", "mc=ma", + "--add-exports", "ma/ma.impl=mc", + "--add-exports", "ma/ma.impl=mt", + "--add-exports", "mb/mb.impl=mt", + "--add-exports", "mc/mc.impl=mt", + "--add-reads", "mt=mc", + "--module-source-path", src2.toString()) + .outdir(classes2) + .files(findJavaFiles(src2)) + .run() + .writeAll(); + + //incremental compilation (C2 mustn't be compiled, C3 must): + tb.writeJavaFiles(src2ma, + "package ma.impl; public class C3 { public void test() { ma.C1.method(); C2.extra(); } }"); + tb.writeJavaFiles(src2mt, + "package mt.impl; public class C3 { public static void test() { mc.impl.C2.test(); C2.test(); } }"); + + List log = new JavacTask(tb) + .options("--module-path", classes1.toString(), + "--patch-module", "ma=" + src2ma.toString(), + "--patch-module", "mb=" + src2mb.toString(), + "--add-exports", "ma/ma.impl=mb", + "--patch-module", "mc=" + src2mc.toString(), + "--add-reads", "mc=ma", + "--add-exports", "ma/ma.impl=mc", + "--add-exports", "ma/ma.impl=mt", + "--add-exports", "mb/mb.impl=mt", + "--add-exports", "mc/mc.impl=mt", + "--add-reads", "mt=mc", + "--module-source-path", src2.toString(), + "--add-modules", "mc", + "-verbose") + .outdir(classes2) + .files(src2ma.resolve("ma").resolve("impl").resolve("C3.java"), + src2mt.resolve("mt").resolve("impl").resolve("C3.java")) + .run() + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT) + .stream() + .filter(l -> l.contains("parsing")) + .collect(Collectors.toList()); + + boolean parsesC3 = log.stream() + .anyMatch(l -> l.contains("C3.java")); + boolean parsesC2 = log.stream() + .anyMatch(l -> l.contains("C2.java")); + + if (!parsesC3 || parsesC2) { + throw new AssertionError("Unexpected output: " + log); + } + } + + private void checkFileExists(Path dir, String path) { + Path toCheck = dir.resolve(path.replace("/", dir.getFileSystem().getSeparator())); + + if (!Files.exists(toCheck)) { + throw new AssertionError(toCheck.toString() + " does not exist!"); + } + } } diff --git a/langtools/test/tools/javac/modules/ContainsTest.java b/langtools/test/tools/javac/modules/ContainsTest.java new file mode 100644 index 00000000000..849a374b222 --- /dev/null +++ b/langtools/test/tools/javac/modules/ContainsTest.java @@ -0,0 +1,169 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8178518 + * @summary Add method JavaFileManager.contains + * @library /tools/lib + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @build toolbox.ToolBox toolbox.JarTask toolbox.JavacTask ModuleTestBase + * @run main ContainsTest + */ + +import java.io.IOException; +import java.nio.file.FileSystem; +import java.nio.file.FileSystems; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.EnumSet; +import java.util.List; + +import javax.tools.FileObject; +import javax.tools.JavaCompiler; +import javax.tools.JavaFileManager.Location; +import javax.tools.JavaFileObject; +import javax.tools.StandardJavaFileManager; +import javax.tools.StandardLocation; +import javax.tools.ToolProvider; + +import toolbox.JarTask; +import toolbox.JavacTask; + +public class ContainsTest extends ModuleTestBase { + public static void main(String... args) throws Exception { + ContainsTest t = new ContainsTest(); + t.runTests(); + } + + JavaCompiler javaCompiler = ToolProvider.getSystemJavaCompiler(); + + @Test + public void testSimplePath(Path base) throws IOException { + // Test that we can look up in directories in the default file system. + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "package p; class C { }"); + Path c = src.resolve("p/C.java"); + Path x = base.resolve("src2/p/C.java"); + try (StandardJavaFileManager fm = javaCompiler.getStandardFileManager(null, null, null)) { + fm.setLocationFromPaths(StandardLocation.SOURCE_PATH, List.of(src)); + checkContains(fm, StandardLocation.SOURCE_PATH, c, true); + checkContains(fm, StandardLocation.SOURCE_PATH, x, false); + } + } + + @Test + public void testJarPath(Path base) throws IOException { + // Test that we can look up in jar files on a search path. + // In this case, the path we look up must come from open file system + // as used by the file manager. + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "package p; class C { }"); + Path classes = Files.createDirectories(base.resolve("classes")); + new JavacTask(tb) + .options("-sourcepath", src.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll(); + + Path jar = base.resolve("classes.jar"); + new JarTask(tb).run("cf", jar.toString(), "-C", classes.toString(), "p"); + + Path c = src.resolve("p/C.java"); + Path x = base.resolve("src2/p/C.java"); + + try (StandardJavaFileManager fm = javaCompiler.getStandardFileManager(null, null, null)) { + fm.setLocationFromPaths(StandardLocation.CLASS_PATH, List.of(src, jar)); + + checkContains(fm, StandardLocation.CLASS_PATH, c, true); + checkContains(fm, StandardLocation.CLASS_PATH, x, false); + + JavaFileObject fo = fm.list(StandardLocation.CLASS_PATH, "p", + EnumSet.of(JavaFileObject.Kind.CLASS), false).iterator().next(); + + checkContains(fm, StandardLocation.CLASS_PATH, fo, true); + } + } + + @Test + public void testJarFSPath(Path base) throws IOException { + // Test that we can look up in non-default file systems on the search path, + // such as an open jar file system. + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "package p; class C { }"); + Path classes = Files.createDirectories(base.resolve("classes")); + new JavacTask(tb) + .options("-sourcepath", src.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll(); + + Path jar = base.resolve("classes.jar"); + new JarTask(tb).run("cf", jar.toString(), "-C", classes.toString(), "p"); + + Path c = src.resolve("p/C.java"); + Path x = base.resolve("src2/p/C.java"); + + try (FileSystem jarFS = FileSystems.newFileSystem(jar, null); + StandardJavaFileManager fm = javaCompiler.getStandardFileManager(null, null, null)) { + Path jarRoot = jarFS.getRootDirectories().iterator().next(); + fm.setLocationFromPaths(StandardLocation.CLASS_PATH, List.of(src, jarRoot)); + + checkContains(fm, StandardLocation.CLASS_PATH, c, true); + checkContains(fm, StandardLocation.CLASS_PATH, x, false); + + JavaFileObject fo = fm.list(StandardLocation.CLASS_PATH, "p", + EnumSet.of(JavaFileObject.Kind.CLASS), false).iterator().next(); + + checkContains(fm, StandardLocation.CLASS_PATH, fo, true); + checkContains(fm, StandardLocation.CLASS_PATH, jarRoot.resolve("p/C.class"), true); + } + } + + void checkContains(StandardJavaFileManager fm, Location l, Path p, boolean expect) throws IOException { + JavaFileObject fo = fm.getJavaFileObjects(p).iterator().next(); + checkContains(fm, l, fo, expect); + } + + void checkContains(StandardJavaFileManager fm, Location l, FileObject fo, boolean expect) throws IOException { + boolean found = fm.contains(l, fo); + if (found) { + if (expect) { + out.println("file found, as expected: " + l + " " + fo.getName()); + } else { + error("file not found: " + l + " " + fo.getName()); + } + } else { + if (expect) { + error("file found unexpectedly: " + l + " " + fo.getName()); + } else { + out.println("file not found, as expected: " + l + " " + fo.getName()); + } + } + } +} diff --git a/langtools/test/tools/javac/modules/ConvenientAccessErrorsTest.java b/langtools/test/tools/javac/modules/ConvenientAccessErrorsTest.java index 45c2d388a8b..3fed25a3ab5 100644 --- a/langtools/test/tools/javac/modules/ConvenientAccessErrorsTest.java +++ b/langtools/test/tools/javac/modules/ConvenientAccessErrorsTest.java @@ -23,7 +23,7 @@ /* * @test - * @bug 8169197 8172668 8173117 + * @bug 8169197 8172668 8173117 8175007 * @summary Check convenient errors are produced for inaccessible classes. * @library /tools/lib * @modules jdk.compiler/com.sun.tools.javac.api @@ -704,4 +704,44 @@ public class ConvenientAccessErrorsTest extends ModuleTestBase { throw new Exception("Expected names not generated: " + actual); } } + + @Test + public void testInaccessibleInVisible(Path base) throws Exception { + Path src = base.resolve("src"); + Path src_ma = src.resolve("ma"); + tb.writeJavaFiles(src_ma, + "module ma { exports ma; }", + "package ma; class NotApi { public static class Inner { } }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + new JavacTask(tb) + .outdir(classes) + .files(findJavaFiles(src_ma)) + .run() + .writeAll(); + + Path src_mb = src.resolve("mb"); + tb.writeJavaFiles(src_mb, + "module mb { requires ma; }", + "package mb.a; public class Test { ma.NotApi.Inner i1; mb.b.NotApi.Inner i2; }", + "package mb.b; class NotApi { public static class Inner { } }"); + + List log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--module-path", classes.toString()) + .outdir(classes) + .files(findJavaFiles(src_mb)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + List expected = Arrays.asList( + "Test.java:1:44: compiler.err.not.def.access.class.intf.cant.access: ma.NotApi.Inner, ma.NotApi", + "Test.java:1:66: compiler.err.not.def.access.class.intf.cant.access: mb.b.NotApi.Inner, mb.b.NotApi", + "2 errors"); + + if (!expected.equals(log)) + throw new Exception("expected output not found; actual: " + log); + } } diff --git a/langtools/test/tools/javac/modules/DirectiveVisitorTest.java b/langtools/test/tools/javac/modules/DirectiveVisitorTest.java new file mode 100644 index 00000000000..f28879844c5 --- /dev/null +++ b/langtools/test/tools/javac/modules/DirectiveVisitorTest.java @@ -0,0 +1,146 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +import java.io.PrintStream; +import java.nio.file.Path; +import java.util.EnumSet; +import java.util.List; +import java.util.Set; + +import javax.lang.model.element.ModuleElement; +import javax.lang.model.element.ModuleElement.Directive; +import javax.lang.model.element.ModuleElement.DirectiveKind; +import javax.lang.model.element.ModuleElement.DirectiveVisitor; +import javax.lang.model.element.ModuleElement.ExportsDirective; +import javax.lang.model.element.ModuleElement.OpensDirective; +import javax.lang.model.element.ModuleElement.ProvidesDirective; +import javax.lang.model.element.ModuleElement.RequiresDirective; +import javax.lang.model.element.ModuleElement.UsesDirective; +import javax.tools.JavaCompiler; +import javax.tools.JavaFileObject; +import javax.tools.StandardJavaFileManager; +import javax.tools.ToolProvider; + +import com.sun.source.util.JavacTask; + +/* + * @test + * @bug 8175118 + * @summary Add ModuleElement.DirectiveVisitor + * @library /tools/lib + * @modules jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * jdk.compiler/com.sun.tools.javac.util + * @build toolbox.ToolBox ModuleTestBase + * @run main DirectiveVisitorTest + */ + +public class DirectiveVisitorTest extends ModuleTestBase { + public static void main(String... args) throws Exception { + new DirectiveVisitorTest().runTests(); + } + + @Test + public void testVisitor(Path base) throws Exception { + Path src = base.resolve("src"); + Path src_m1 = src.resolve("m1x"); + tb.writeJavaFiles(src_m1, + "module m1x { " + + " requires m2x;" + + " exports p1;" + + " opens p2;" + + " uses p1.Service;" + + " provides p1.Service with p2.Impl;" + + "}", + "package p1; public interface Service { }", + "package p2; public class Impl implements p1.Service { }"); + Path src_m2 = src.resolve("m2x"); + tb.writeJavaFiles(src_m2, + "module m2x { }"); + + Path modules = base.resolve("modules"); + tb.createDirectories(modules); + + JavaCompiler javac = ToolProvider.getSystemJavaCompiler(); + try (StandardJavaFileManager fm = javac.getStandardFileManager(null, null, null)) { + Iterable files = fm.getJavaFileObjects(findJavaFiles(src)); + List options = List.of( + "--module-source-path", src.toString(), + "-d", modules.toString() + ); + JavacTask t = (JavacTask) javac.getTask(null, fm, null, options, null, files); + t.analyze(); + ModuleElement e = t.getElements().getModuleElement("m1x"); + Set kinds = EnumSet.allOf(DirectiveKind.class); + Visitor v = new Visitor(); + v.visit(e, kinds); + if (!kinds.equals(EnumSet.noneOf(DirectiveKind.class))) { + error("Some kinds not found: " + kinds); + } + } + } + + static class Visitor implements DirectiveVisitor> { + private final PrintStream out = System.err; + + public void visit(ModuleElement e, Set kinds) { + e.getDirectives().stream().forEach(d -> visit(d, kinds)); + } + + @Override + public Void visitRequires(RequiresDirective d, Set kinds) { + visitAny(d, kinds); + return null; + } + + @Override + public Void visitExports(ExportsDirective d, Set kinds) { + visitAny(d, kinds); + return null; + } + + @Override + public Void visitOpens(OpensDirective d, Set kinds) { + visitAny(d, kinds); + return null; + } + + @Override + public Void visitUses(UsesDirective d, Set kinds) { + visitAny(d, kinds); + return null; + } + + @Override + public Void visitProvides(ProvidesDirective d, Set kinds) { + visitAny(d, kinds); + return null; + } + + private void visitAny(Directive d, Set kinds) { + out.println("visit: " + d); + kinds.remove(d.getKind()); + } + } +} + diff --git a/langtools/test/tools/javac/modules/EdgeCases.java b/langtools/test/tools/javac/modules/EdgeCases.java index 841a43dfa0a..679bc1709e6 100644 --- a/langtools/test/tools/javac/modules/EdgeCases.java +++ b/langtools/test/tools/javac/modules/EdgeCases.java @@ -23,7 +23,7 @@ /* * @test - * @bug 8154283 8167320 8171098 8172809 8173068 8173117 + * @bug 8154283 8167320 8171098 8172809 8173068 8173117 8176045 8177311 * @summary tests for multi-module mode compilation * @library /tools/lib * @modules @@ -36,6 +36,7 @@ * @run main EdgeCases */ +import java.io.BufferedWriter; import java.io.Writer; import java.nio.file.Files; import java.nio.file.Path; @@ -67,10 +68,7 @@ import com.sun.source.tree.CompilationUnitTree; //import com.sun.source.util.JavacTask; // conflicts with toolbox.JavacTask import com.sun.tools.javac.api.JavacTaskImpl; import com.sun.tools.javac.code.Symbol.ModuleSymbol; -import com.sun.tools.javac.code.Symbol.PackageSymbol; import com.sun.tools.javac.code.Symtab; -import com.sun.tools.javac.processing.JavacProcessingEnvironment; -import com.sun.tools.javac.util.Context; import toolbox.JarTask; import toolbox.JavacTask; @@ -269,13 +267,22 @@ public class EdgeCases extends ModuleTestBase { Path classes = base.resolve("classes"); tb.createDirectories(classes); - new JavacTask(tb) + List log = new JavacTask(tb) .options("--source-path", src_m1.toString(), "-XDrawDiagnostics") .outdir(classes) .files(findJavaFiles(src_m1.resolve("test"))) .run(Task.Expect.FAIL) - .writeAll(); + .writeAll() + .getOutputLines(OutputKind.DIRECT); + + List expected = Arrays.asList( + "- compiler.err.cant.access: module-info, (compiler.misc.bad.source.file.header: module-info.java, (compiler.misc.file.does.not.contain.module))", + "1 error"); + + if (!expected.equals(log)) { + throw new AssertionError("Unexpected output: " + log); + } tb.writeJavaFiles(src_m1, "module m1x {}"); @@ -812,4 +819,180 @@ public class EdgeCases extends ModuleTestBase { } } + + @Test + public void testEmptyInExportedPackage(Path base) throws Exception { + Path src = base.resolve("src"); + Path m = src.resolve("m"); + tb.writeJavaFiles(m, + "module m { exports api; }"); + Path apiFile = m.resolve("api").resolve("Api.java"); + Files.createDirectories(apiFile.getParent()); + try (BufferedWriter w = Files.newBufferedWriter(apiFile)) { + w.write("//no package decl"); + } + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + List log; + List expected = + Arrays.asList("module-info.java:1:20: compiler.err.package.empty.or.not.found: api", + "1 error"); + + System.err.println("file explicitly specified:"); + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!expected.equals(log)) + throw new Exception("expected output not found: " + log); + + System.err.println("file not specified:"); + + tb.cleanDirectory(classes); + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(m.resolve("module-info.java"))) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!expected.equals(log)) + throw new Exception("expected output not found: " + log); + } + + @Test + public void testJustPackageInExportedPackage(Path base) throws Exception { + Path src = base.resolve("src"); + Path m = src.resolve("m"); + tb.writeJavaFiles(m, + "module m { exports api; }"); + Path apiFile = m.resolve("api").resolve("Api.java"); + Files.createDirectories(apiFile.getParent()); + try (BufferedWriter w = Files.newBufferedWriter(apiFile)) { + w.write("package api;"); + } + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + System.err.println("file explicitly specified:"); + + new JavacTask(tb) + .options("-XDrawDiagnostics", + "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll(); + + System.err.println("file not specified:"); + + tb.cleanDirectory(classes); + + new JavacTask(tb) + .options("-XDrawDiagnostics", + "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(m.resolve("module-info.java"))) + .run() + .writeAll(); + } + + @Test + public void testWrongPackageInExportedPackage(Path base) throws Exception { + Path src = base.resolve("src"); + Path m = src.resolve("m"); + tb.writeJavaFiles(m, + "module m { exports api; }"); + Path apiFile = m.resolve("api").resolve("Api.java"); + Files.createDirectories(apiFile.getParent()); + try (BufferedWriter w = Files.newBufferedWriter(apiFile)) { + w.write("package impl; public class Api { }"); + } + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + List log; + + List expected = + Arrays.asList("module-info.java:1:20: compiler.err.package.empty.or.not.found: api", + "1 error"); + + System.err.println("file explicitly specified:"); + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!expected.equals(log)) + throw new Exception("expected output not found: " + log); + + System.err.println("file not specified:"); + + tb.cleanDirectory(classes); + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(m.resolve("module-info.java"))) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!expected.equals(log)) + throw new Exception("expected output not found: " + log); + } + + @Test + public void testDependOnUnnamedAccessibility(Path base) throws Exception { + Path unnamedSrc = base.resolve("unnamed-src"); + tb.writeJavaFiles(unnamedSrc, + "package p1; public class First { public static p2.Second get() { return null; } }", + "package p2; public class Second { public void test() { } }"); + Path unnamedClasses = base.resolve("unnamed-classes"); + tb.createDirectories(unnamedClasses); + + System.err.println("compiling unnamed sources:"); + + new JavacTask(tb) + .outdir(unnamedClasses) + .files(findJavaFiles(unnamedSrc)) + .run() + .writeAll(); + + //test sources: + Path src = base.resolve("src"); + Path m = src.resolve("m"); + tb.writeJavaFiles(m, + "module m { }", + "package p; public class Test { { p1.First.get().test(); } }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + System.err.println("compiling test module:"); + + new JavacTask(tb) + .options("-classpath", unnamedClasses.toString(), + "--add-reads", "m=ALL-UNNAMED") + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll(); + } + } diff --git a/langtools/test/tools/javac/modules/EnvVarTest.java b/langtools/test/tools/javac/modules/EnvVarTest.java index eed5a03f385..dfa3d780867 100644 --- a/langtools/test/tools/javac/modules/EnvVarTest.java +++ b/langtools/test/tools/javac/modules/EnvVarTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,7 @@ /* * @test * @bug 8156962 - * @summary Tests use of _JAVAC_OPTIONS env variable + * @summary Tests use of JDK_JAVAC_OPTIONS env variable * @library /tools/lib * @modules jdk.compiler/com.sun.tools.javac.api * jdk.compiler/com.sun.tools.javac.main @@ -71,7 +71,7 @@ public class EnvVarTest extends ModuleTestBase { tb.out.println("test that addExports can be provided with env variable"); new JavacTask(tb, Mode.EXEC) - .envVar("_JAVAC_OPTIONS", "--add-exports jdk.compiler/com.sun.tools.javac.jvm=ALL-UNNAMED") + .envVar("JDK_JAVAC_OPTIONS", "--add-exports jdk.compiler/com.sun.tools.javac.jvm=ALL-UNNAMED") .outdir(classes) .files(findJavaFiles(src)) .run(Expect.SUCCESS) @@ -83,7 +83,7 @@ public class EnvVarTest extends ModuleTestBase { "--add-exports jdk.compiler/com.sun.tools.javac.jvm=ALL-UNNAMED"); new JavacTask(tb, Mode.EXEC) - .envVar("_JAVAC_OPTIONS", "@" + atFile) + .envVar("JDK_JAVAC_OPTIONS", "@" + atFile) .outdir(classes) .files(findJavaFiles(src)) .run(Expect.SUCCESS) diff --git a/langtools/test/tools/javac/modules/IncubatingTest.java b/langtools/test/tools/javac/modules/IncubatingTest.java index a839237c4e1..796d8df343f 100644 --- a/langtools/test/tools/javac/modules/IncubatingTest.java +++ b/langtools/test/tools/javac/modules/IncubatingTest.java @@ -122,14 +122,11 @@ public class IncubatingTest extends ModuleTestBase { "-XDrawDiagnostics") .outdir(testClasses) .files(findJavaFiles(testSrc)) - .run(Expect.FAIL) + .run(Expect.SUCCESS) .writeAll() .getOutputLines(Task.OutputKind.DIRECT); - expected = Arrays.asList( - "T.java:1:11: compiler.err.package.not.visible: api, (compiler.misc.not.def.access.does.not.read.from.unnamed: api, jdk.i)", - "1 error" - ); + expected = Arrays.asList(""); if (!expected.equals(log)) { throw new AssertionError("Unexpected output: " + log); diff --git a/langtools/test/tools/javac/modules/InheritRuntimeEnvironmentTest.java b/langtools/test/tools/javac/modules/InheritRuntimeEnvironmentTest.java index b4766d7f5d7..64b534a0c4b 100644 --- a/langtools/test/tools/javac/modules/InheritRuntimeEnvironmentTest.java +++ b/langtools/test/tools/javac/modules/InheritRuntimeEnvironmentTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -177,7 +177,7 @@ public class InheritRuntimeEnvironmentTest extends ModuleTestBase { Files.createDirectories(patch); new JavacTask(tb) - .options("-Xmodule:java.base") + .options("--patch-module", "java.base=" + patchSrc.toString()) .outdir(patch) .sourcepath(patchSrc) .files(findJavaFiles(patchSrc)) @@ -238,7 +238,7 @@ public class InheritRuntimeEnvironmentTest extends ModuleTestBase { Arrays.asList("--add-exports", "jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"); List files = Arrays.asList(findJavaFiles(src)); - String envName = "_JAVAC_OPTIONS"; + String envName = "JDK_JAVAC_OPTIONS"; String envValue = String.join(" ", testOpts); out.println(" javac:"); diff --git a/langtools/test/tools/javac/modules/LegacyXModuleTest.java b/langtools/test/tools/javac/modules/LegacyXModuleTest.java new file mode 100644 index 00000000000..36113364e06 --- /dev/null +++ b/langtools/test/tools/javac/modules/LegacyXModuleTest.java @@ -0,0 +1,85 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8178012 + * @summary tests for multi-module mode compilation + * @library /tools/lib + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @build toolbox.ToolBox toolbox.JavacTask toolbox.ModuleBuilder ModuleTestBase + * @run main LegacyXModuleTest + */ + +import java.nio.file.Path; +import java.util.Arrays; +import java.util.List; +import java.util.Objects; + +import toolbox.JavacTask; +import toolbox.Task; + +public class LegacyXModuleTest extends ModuleTestBase { + + public static void main(String... args) throws Exception { + new LegacyXModuleTest().runTests(); + } + + @Test + public void testLegacyXModule(Path base) throws Exception { + //note: avoiding use of java.base, as that gets special handling on some places: + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "package com.sun.tools.javac.comp; public class Extra { Modules modules; }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + new JavacTask(tb) + .options("-XD-Xmodule:jdk.compiler") + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + List log = new JavacTask(tb) + .options("-XD-Xmodule:java.compiler", + "-XD-Xmodule:jdk.compiler", + "-XDrawDiagnostics") + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + List actual = + Arrays.asList("Extra.java:1:56: compiler.err.cant.resolve.location: kindname.class, Modules, , , " + + "(compiler.misc.location: kindname.class, com.sun.tools.javac.comp.Extra, null)", + "1 error"); + + if (!Objects.equals(actual, log)) + throw new Exception("expected output not found: " + log); + } + +} diff --git a/langtools/test/tools/javac/modules/MOptionTest.java b/langtools/test/tools/javac/modules/MOptionTest.java index b48aa2f8aec..c6642ca93c9 100644 --- a/langtools/test/tools/javac/modules/MOptionTest.java +++ b/langtools/test/tools/javac/modules/MOptionTest.java @@ -23,7 +23,7 @@ /** * @test - * @bug 8146946 + * @bug 8146946 8176743 * @summary implement javac -m option * @library /tools/lib * @modules diff --git a/langtools/test/tools/javac/modules/ModuleInfoPatchPath.java b/langtools/test/tools/javac/modules/ModuleInfoPatchPath.java new file mode 100644 index 00000000000..a637fb9233d --- /dev/null +++ b/langtools/test/tools/javac/modules/ModuleInfoPatchPath.java @@ -0,0 +1,325 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8175057 + * @summary Verify that having module-info on patch path works correctly. + * @library /tools/lib + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.code + * jdk.compiler/com.sun.tools.javac.main + * jdk.compiler/com.sun.tools.javac.processing + * jdk.compiler/com.sun.tools.javac.util + * @build toolbox.ToolBox toolbox.JarTask toolbox.JavacTask ModuleTestBase + * @run main ModuleInfoPatchPath + */ + +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.List; + +import toolbox.JavacTask; +import toolbox.Task.OutputKind; + +public class ModuleInfoPatchPath extends ModuleTestBase { + + public static void main(String... args) throws Exception { + new ModuleInfoPatchPath().runTests(); + } + + @Test + public void testModuleInfoToModulePath(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "module m { exports api; }", + "package api; public class Api {}"); + Path patch = base.resolve("patch"); + tb.writeJavaFiles(patch, + "module m { requires java.compiler; exports api; }", + "package api; public class Api { public static javax.lang.model.element.Element element; }"); + Path classes = base.resolve("classes"); + Path mClasses = classes.resolve("m"); + tb.createDirectories(mClasses); + + System.err.println("Building the vanilla module..."); + + new JavacTask(tb) + .outdir(mClasses) + .files(findJavaFiles(src)) + .run() + .writeAll(); + + Path test = base.resolve("test"); + tb.writeJavaFiles(test, + "module test { requires m; }", + "package test; public class Test { private void test() { api.Api.element = null; } }"); + + Path testClasses = classes.resolve("test"); + tb.createDirectories(testClasses); + + System.err.println("Building patched module..."); + + new JavacTask(tb) + .options("--module-path", mClasses.toString(), + "--patch-module", "m=" + patch.toString()) + .outdir(testClasses) + .files(findJavaFiles(test)) + .run() + .writeAll(); + + Path patchClasses = classes.resolve("patch"); + tb.createDirectories(patchClasses); + + System.err.println("Building patch..."); + + new JavacTask(tb) + .outdir(patchClasses) + .files(findJavaFiles(patch)) + .run() + .writeAll(); + + tb.cleanDirectory(testClasses); + + Files.delete(patch.resolve("module-info.java")); + Files.copy(patchClasses.resolve("module-info.class"), patch.resolve("module-info.class")); + + System.err.println("Building patched module against binary patch..."); + + new JavacTask(tb) + .options("--module-path", mClasses.toString(), + "--patch-module", "m=" + patch.toString()) + .outdir(testClasses) + .files(findJavaFiles(test)) + .run() + .writeAll(); + } + + @Test + public void testModuleInfoToSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "module m { exports api; }", + "package api; public class Api {}", + "package test; public class Test { private void test() { api.Api.element = null; } }"); + Path patch = base.resolve("patch"); + tb.writeJavaFiles(patch, + "module m { requires java.compiler; exports api; }", + "package api; public class Api { public static javax.lang.model.element.Element element; }"); + Path classes = base.resolve("classes"); + Path mClasses = classes.resolve("m"); + tb.createDirectories(mClasses); + + System.err.println("Building patched module against source patch..."); + + new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "-sourcepath", src.toString()) + .outdir(mClasses) + .files(findJavaFiles(src.resolve("test"))) + .run() + .writeAll(); + + //incremental compilation: + List log; + + System.err.println("Incremental building of patched module against source patch, no module-info..."); + + log = new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "-sourcepath", src.toString(), + "-verbose") + .outdir(mClasses) + .files(findJavaFiles(src.resolve("test"))) + .run() + .writeAll() + .getOutputLines(OutputKind.DIRECT); + + if (log.stream().filter(line -> line.contains("[parsing started")).count() != 1) { + throw new AssertionError("incorrect number of parsing events."); + } + + System.err.println("Incremental building of patched module against source patch, with module-info..."); + + log = new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "-sourcepath", src.toString(), + "-verbose") + .outdir(mClasses) + .files(findJavaFiles(patch.resolve("module-info.java"), src.resolve("test"))) + .run() + .writeAll() + .getOutputLines(OutputKind.DIRECT); + + if (log.stream().filter(line -> line.contains("[parsing started")).count() != 2) { + throw new AssertionError("incorrect number of parsing events."); + } + + tb.cleanDirectory(mClasses); + + System.err.println("Building patched module against source patch with source patch on patch path..."); + + new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "-sourcepath", src.toString()) + .outdir(mClasses) + .files(findJavaFiles(src.resolve("test"), patch)) + .run() + .writeAll(); + + Path patchClasses = classes.resolve("patch"); + tb.createDirectories(patchClasses); + + System.err.println("Building patch..."); + + new JavacTask(tb) + .outdir(patchClasses) + .files(findJavaFiles(patch)) + .run() + .writeAll(); + + tb.cleanDirectory(mClasses); + + Files.delete(patch.resolve("module-info.java")); + Files.copy(patchClasses.resolve("module-info.class"), patch.resolve("module-info.class")); + + System.err.println("Building patched module against binary patch..."); + + new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "-sourcepath", src.toString()) + .outdir(mClasses) + .files(findJavaFiles(src.resolve("test"))) + .run() + .writeAll(); + + tb.cleanDirectory(mClasses); + + System.err.println("Building patched module against binary patch with source patch on patch path..."); + + new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "-sourcepath", src.toString()) + .outdir(mClasses) + .files(findJavaFiles(src.resolve("test"), patch)) + .run() + .writeAll(); + } + + @Test + public void testModuleInfoToModuleSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path m = src.resolve("m"); + tb.writeJavaFiles(m, + "module m { exports api; }", + "package api; public class Api {}", + "package test; public class Test { private void test() { api.Api.element = null; } }"); + Path patch = base.resolve("patch"); + tb.writeJavaFiles(patch, + "module m { requires java.compiler; exports api; }", + "package api; public class Api { public static javax.lang.model.element.Element element; }"); + Path classes = base.resolve("classes"); + Path mClasses = classes.resolve("m"); + tb.createDirectories(mClasses); + + System.err.println("Building patched module against source patch..."); + + new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "--module-source-path", src.toString()) + .outdir(mClasses) + .files(findJavaFiles(m.resolve("test"))) + .run() + .writeAll(); + + //incremental compilation: + + System.err.println("Incremental building of patched module against source patch..."); + + List log = new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "--module-source-path", src.toString(), + "-verbose") + .outdir(mClasses) + .files(findJavaFiles(m.resolve("test"))) + .run() + .writeAll() + .getOutputLines(OutputKind.DIRECT); + + if (log.stream().filter(line -> line.contains("[parsing started")).count() != 1) { + throw new AssertionError("incorrect number of parsing events."); + } + + tb.cleanDirectory(mClasses); + + System.err.println("Building patched module against source patch with source patch on patch path..."); + + new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "--module-source-path", src.toString()) + .outdir(mClasses) + .files(findJavaFiles(m.resolve("test"), patch)) + .run() + .writeAll(); + + Path patchClasses = classes.resolve("patch"); + tb.createDirectories(patchClasses); + + System.err.println("Building patch..."); + + new JavacTask(tb) + .outdir(patchClasses) + .files(findJavaFiles(patch)) + .run() + .writeAll(); + + tb.cleanDirectory(mClasses); + + Files.delete(patch.resolve("module-info.java")); + Files.copy(patchClasses.resolve("module-info.class"), patch.resolve("module-info.class")); + + System.err.println("Building patched module against binary patch..."); + + new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "--module-source-path", src.toString()) + .outdir(mClasses) + .files(findJavaFiles(m.resolve("test"))) + .run() + .writeAll(); + + tb.cleanDirectory(mClasses); + + System.err.println("Building patched module against binary patch with source patch on patch path..."); + + new JavacTask(tb) + .options("--patch-module", "m=" + patch.toString(), + "--module-source-path", src.toString()) + .outdir(mClasses) + .files(findJavaFiles(m.resolve("test"), patch)) + .run() + .writeAll(); + } + +} diff --git a/langtools/test/tools/javac/modules/ModuleInfoTest.java b/langtools/test/tools/javac/modules/ModuleInfoTest.java index 3d08be1cecc..6e083f901cf 100644 --- a/langtools/test/tools/javac/modules/ModuleInfoTest.java +++ b/langtools/test/tools/javac/modules/ModuleInfoTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -94,7 +94,7 @@ public class ModuleInfoTest extends ModuleTestBase { .writeAll() .getOutput(Task.OutputKind.DIRECT); - if (!log.contains("module-info.java:1:8: compiler.err.class.public.should.be.in.file: C")) + if (!log.contains("module-info.java:1:8: compiler.err.class.public.should.be.in.file: kindname.class, C")) throw new Exception("expected output not found"); } @@ -557,4 +557,187 @@ public class ModuleInfoTest extends ModuleTestBase { throw new Exception("expected output not found for: " + moduleInfo + "; actual: " + log); } } -} + + @Test + public void testMalformedModuleNames(Path base) throws Exception { + testMalformedName(base, "m1.package", "module-info.java:1:11: compiler.err.expected: token.identifier"); + testMalformedName(base, "m1/package", "module-info.java:1:10: compiler.err.expected: '{'"); + testMalformedName(base, "m1->long", "module-info.java:1:10: compiler.err.expected: '{'"); + testMalformedName(base, "m1::long", "module-info.java:1:10: compiler.err.expected: '{'"); + testMalformedName(base, "m1&long", "module-info.java:1:10: compiler.err.expected: '{'"); + testMalformedName(base, "m1%long", "module-info.java:1:10: compiler.err.expected: '{'"); + testMalformedName(base, "m1@long", "module-info.java:1:10: compiler.err.expected: '{'"); + testMalformedName(base, "@m1", "module-info.java:1:7: compiler.err.expected: token.identifier"); + testMalformedName(base, "!", "module-info.java:1:7: compiler.err.expected: token.identifier"); + testMalformedName(base, "m1#long", "module-info.java:1:10: compiler.err.illegal.char: #"); + testMalformedName(base, "m1\\long", "module-info.java:1:10: compiler.err.illegal.char: \\"); + testMalformedName(base, "module.", "module-info.java:1:15: compiler.err.expected: token.identifier"); + testMalformedName(base, ".module", "module-info.java:1:7: compiler.err.expected: token.identifier"); + testMalformedName(base, "1module", "module-info.java:1:7: compiler.err.expected: token.identifier"); + testMalformedName(base, "module module", "module-info.java:1:14: compiler.err.expected: '{'"); + } + + private void testMalformedName(Path base, String name, String expected) throws Exception { + Path src = base.resolve("src"); + Path src_m1 = src.resolve("m1"); + tb.writeJavaFiles(src_m1, "module " + name + " { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics", "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains(expected)) + throw new Exception("expected output not found. Name: " + name + " Expected: " + expected); + } + + @Test + public void testWrongOpensTransitiveFlag(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "module M { opens transitive p1; }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:28: compiler.err.expected: ';'")) + throw new Exception("expected output not found"); + } + + @Test + public void testWrongOpensStaticFlag(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "module M { opens static p1; }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:17: compiler.err.expected: token.identifier")) + throw new Exception("expected output not found"); + } + + @Test + public void testSeveralOpensDirectives(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "module M { opens opens p1; }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:23: compiler.err.expected: ';'")) + throw new Exception("expected output not found"); + } + + @Test + public void testUnknownDirective(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "module M { boolean p1; }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:11: compiler.err.expected: '}'")) + throw new Exception("expected output not found"); + } + + @Test + public void testUnknownModuleFlag(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "private module M { }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:9: compiler.err.mod.not.allowed.here: private")) + throw new Exception("expected output not found"); + } + + @Test + public void testDirectiveOnModuleDeclaration(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "opens module M { }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:1: compiler.err.expected.module.or.open")) + throw new Exception("expected output not found"); + } + + @Test + public void testTooOpenModule(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "open open module M { }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:6: compiler.err.expected.module")) + throw new Exception("expected output not found"); + } + + @Test + public void testEnumAsModuleFlag(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "enum module M { }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:12: compiler.err.expected: '{'")) + throw new Exception("expected output not found"); + } + + @Test + public void testClassInModule(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "module M { class B { } }", + "package p1; public class A { }"); + String log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("module-info.java:1:11: compiler.err.expected: '}'")) + throw new Exception("expected output not found"); + } +} \ No newline at end of file diff --git a/langtools/test/tools/javac/modules/ModulePathTest.java b/langtools/test/tools/javac/modules/ModulePathTest.java index 7315ad10e66..53123b25682 100644 --- a/langtools/test/tools/javac/modules/ModulePathTest.java +++ b/langtools/test/tools/javac/modules/ModulePathTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,6 +23,7 @@ /* * @test + * @bug 8142968 8174104 * @summary tests for --module-path * @library /tools/lib * @modules @@ -57,7 +58,7 @@ public class ModulePathTest extends ModuleTestBase { } @Test - public void testNotExistsOnPath(Path base) throws Exception { + public void testNotExistsOnPath_noWarn(Path base) throws Exception { Path src = base.resolve("src"); tb.writeJavaFiles(src, "class C { }"); @@ -65,11 +66,29 @@ public class ModulePathTest extends ModuleTestBase { .options("-XDrawDiagnostics", "--module-path", "doesNotExist") .files(findJavaFiles(src)) - .run(Task.Expect.FAIL) + .run(Task.Expect.SUCCESS) .writeAll() .getOutput(Task.OutputKind.DIRECT); - if (!log.contains("- compiler.err.illegal.argument.for.option: --module-path, doesNotExist")) + if (!log.isEmpty()) + throw new Exception("unexpected output"); + } + + @Test + public void testNotExistsOnPath_warn(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "class C { }"); + + String log = new JavacTask(tb, Task.Mode.CMDLINE) + .options("-XDrawDiagnostics", + "-Xlint:path", + "--module-path", "doesNotExist") + .files(findJavaFiles(src)) + .run(Task.Expect.SUCCESS) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + if (!log.contains("- compiler.warn.path.element.not.found: doesNotExist")) throw new Exception("expected output not found"); } diff --git a/langtools/test/tools/javac/modules/ModuleSourcePathTest.java b/langtools/test/tools/javac/modules/ModuleSourcePathTest.java index 68b490d484d..c351eb5204c 100644 --- a/langtools/test/tools/javac/modules/ModuleSourcePathTest.java +++ b/langtools/test/tools/javac/modules/ModuleSourcePathTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -37,11 +37,18 @@ import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; +import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.stream.Collectors; import java.util.stream.Stream; +import javax.tools.JavaCompiler; +import javax.tools.JavaFileManager.Location; +import javax.tools.StandardJavaFileManager; +import javax.tools.StandardLocation; +import javax.tools.ToolProvider; + import toolbox.JavacTask; import toolbox.Task; import toolbox.ToolBox; @@ -442,6 +449,76 @@ public class ModuleSourcePathTest extends ModuleTestBase { } } + @Test + public void setLocation(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src.resolve("m1x"), "module m1x { }", "package a; class A { }"); + Path modules = base.resolve("modules"); + tb.createDirectories(modules); + + JavaCompiler c = ToolProvider.getSystemJavaCompiler(); + try (StandardJavaFileManager fm = c.getStandardFileManager(null, null, null)) { + fm.setLocationFromPaths(StandardLocation.MODULE_SOURCE_PATH, List.of(src)); + new JavacTask(tb) + .options("-XDrawDiagnostics") + .fileManager(fm) + .outdir(modules) + .files(findJavaFiles(src)) + .run() + .writeAll(); + + checkFiles(modules.resolve("m1x/module-info.class"), modules.resolve("m1x/a/A.class")); + } + } + + @Test + public void getLocation_valid(Path base) throws Exception { + Path src1 = base.resolve("src1"); + tb.writeJavaFiles(src1.resolve("m1x"), "module m1x { }", "package a; class A { }"); + Path src2 = base.resolve("src2"); + tb.writeJavaFiles(src1.resolve("m2x"), "module m2x { }", "package b; class B { }"); + + JavaCompiler c = ToolProvider.getSystemJavaCompiler(); + try (StandardJavaFileManager fm = c.getStandardFileManager(null, null, null)) { + fm.setLocationFromPaths(StandardLocation.MODULE_SOURCE_PATH, List.of(src1, src2)); + checkLocation(fm.getLocationAsPaths(StandardLocation.MODULE_SOURCE_PATH), List.of(src1, src2)); + } + } + + @Test + public void getLocation_ISA(Path base) throws Exception { + Path src1 = base.resolve("src1"); + tb.writeJavaFiles(src1.resolve("m1x"), "module m1x { }", "package a; class A { }"); + Path src2 = base.resolve("src2"); + tb.writeJavaFiles(src2.resolve("m2x").resolve("extra"), "module m2x { }", "package b; class B { }"); + Path modules = base.resolve("modules"); + tb.createDirectories(modules); + + String FS = File.separator; + String PS = File.pathSeparator; + JavaCompiler c = ToolProvider.getSystemJavaCompiler(); + try (StandardJavaFileManager fm = c.getStandardFileManager(null, null, null)) { + fm.handleOption("--module-source-path", + List.of(src1 + PS + src2 + FS + "*" + FS + "extra").iterator()); + + try { + Iterable paths = fm.getLocationAsPaths(StandardLocation.MODULE_SOURCE_PATH); + out.println("result: " + asList(paths)); + throw new Exception("expected IllegalStateException not thrown"); + } catch (IllegalStateException e) { + out.println("Exception thrown, as expected: " + e); + } + + // even if we can't do getLocation for the MODULE_SOURCE_PATH, we should be able + // to do getLocation for the modules, which will additionally confirm the option + // was effective as intended. + Location locn1 = fm.getLocationForModule(StandardLocation.MODULE_SOURCE_PATH, "m1x"); + checkLocation(fm.getLocationAsPaths(locn1), List.of(src1.resolve("m1x"))); + Location locn2 = fm.getLocationForModule(StandardLocation.MODULE_SOURCE_PATH, "m2x"); + checkLocation(fm.getLocationAsPaths(locn2), List.of(src2.resolve("m2x").resolve("extra"))); + } + } + private void generateModules(Path base, String... paths) throws IOException { for (int i = 0; i < paths.length; i++) { String moduleName = "m" + i + "x"; @@ -455,8 +532,25 @@ public class ModuleSourcePathTest extends ModuleTestBase { private void checkFiles(Path... files) throws Exception { for (Path file : files) { if (!Files.exists(file)) { - throw new Exception("File not exists: " + file); + throw new Exception("File not found: " + file); } } } + + private void checkLocation(Iterable locn, List ref) throws Exception { + List list = asList(locn); + if (!list.equals(ref)) { + out.println("expect: " + ref); + out.println(" found: " + list); + throw new Exception("location not as expected"); + } + } + + private List asList(Iterable iter) { + List list = new ArrayList<>(); + for (T item : iter) { + list.add(item); + } + return list; + } } diff --git a/langtools/test/tools/javac/modules/ModuleTestBase.java b/langtools/test/tools/javac/modules/ModuleTestBase.java index 5d5f20de153..151cc9a1538 100644 --- a/langtools/test/tools/javac/modules/ModuleTestBase.java +++ b/langtools/test/tools/javac/modules/ModuleTestBase.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,7 +33,6 @@ import toolbox.ToolBox; */ public class ModuleTestBase extends TestRunner { protected ToolBox tb; - private int errors; ModuleTestBase() { super(System.err); diff --git a/langtools/test/tools/javac/modules/ModulesAndModuleSourcePathTest.java b/langtools/test/tools/javac/modules/ModulesAndModuleSourcePathTest.java index 1edc21de22a..b4c50d7e4c5 100644 --- a/langtools/test/tools/javac/modules/ModulesAndModuleSourcePathTest.java +++ b/langtools/test/tools/javac/modules/ModulesAndModuleSourcePathTest.java @@ -23,7 +23,7 @@ /** * @test - * @bug 8165102 + * @bug 8165102 8175560 * @summary incorrect message from javac * @library /tools/lib * @modules @@ -48,6 +48,27 @@ public class ModulesAndModuleSourcePathTest extends ModuleTestBase { @Test public void testModuleNotInModuleSrcPath(Path base) throws Exception { + Path src = base.resolve("src"); + Path m = src.resolve("m"); + Files.createDirectories(m); + Path extra = base.resolve("m"); + tb.writeJavaFiles(extra, "module m {}"); + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics", "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(extra)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + if (!log.contains("module-info.java:1:1: compiler.err.module.not.found.on.module.source.path")) + throw new Exception("expected output not found"); + } + + @Test + public void testModuleNotInPackageHierarchy(Path base) throws Exception { Path src = base.resolve("src"); Path m = src.resolve("m"); Path extra = m.resolve("extra"); diff --git a/langtools/test/tools/javac/modules/PatchModulesTest.java b/langtools/test/tools/javac/modules/PatchModulesTest.java index dde0c53a613..6543c868994 100644 --- a/langtools/test/tools/javac/modules/PatchModulesTest.java +++ b/langtools/test/tools/javac/modules/PatchModulesTest.java @@ -28,7 +28,7 @@ * @library /tools/lib * @modules * jdk.compiler/com.sun.tools.javac.api - * jdk.compiler/com.sun.tools.javac.file:+open + * jdk.compiler/com.sun.tools.javac.file * jdk.compiler/com.sun.tools.javac.main * @build toolbox.ToolBox toolbox.JavacTask toolbox.ModuleBuilder ModuleTestBase * @run main PatchModulesTest @@ -38,21 +38,26 @@ import java.io.File; import java.io.IOException; import java.io.PrintWriter; import java.io.StringWriter; -import java.lang.reflect.Field; +import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; +import java.util.AbstractMap.SimpleEntry; import java.util.List; import java.util.Map; +import java.util.Map.Entry; +import java.util.TreeMap; import java.util.stream.Collectors; +import java.util.stream.StreamSupport; +import javax.tools.JavaFileManager.Location; import javax.tools.JavaFileObject; import javax.tools.ToolProvider; +import javax.tools.StandardJavaFileManager; +import javax.tools.StandardLocation; import com.sun.source.util.JavacTask; import com.sun.tools.javac.api.JavacTool; -import com.sun.tools.javac.file.BaseFileManager; import com.sun.tools.javac.file.JavacFileManager; -import com.sun.tools.javac.file.Locations; import static java.util.Arrays.asList; @@ -115,21 +120,29 @@ public class PatchModulesTest extends ModuleTestBase { void test(List patches, boolean expectOK, String expect) throws Exception { JavacTool tool = (JavacTool) ToolProvider.getSystemJavaCompiler(); StringWriter sw = new StringWriter(); - try (PrintWriter pw = new PrintWriter(sw)) { - JavacFileManager fm = tool.getStandardFileManager(null, null, null); + try (PrintWriter pw = new PrintWriter(sw); + JavacFileManager fm = tool.getStandardFileManager(null, null, null)) { List opts = patches.stream() .map(p -> "--patch-module=" + p.replace(":", PS)) .collect(Collectors.toList()); Iterable files = fm.getJavaFileObjects("C.java"); JavacTask task = tool.getTask(pw, fm, null, opts, null, files); - Field locationsField = BaseFileManager.class.getDeclaredField("locations"); - locationsField.setAccessible(true); - Object locations = locationsField.get(fm); + Map> mod2Location = + StreamSupport.stream(fm.listLocationsForModules(StandardLocation.PATCH_MODULE_PATH) + .spliterator(), + false) + .flatMap(sl -> sl.stream()) + .collect(Collectors.groupingBy(l -> fm.inferModuleName(l))); - Field patchMapField = Locations.class.getDeclaredField("patchMap"); - patchMapField.setAccessible(true); - Map patchMap = (Map) patchMapField.get(locations); + Map> patchMap = mod2Location.entrySet() + .stream() + .map(e -> new SimpleEntry<>(e.getKey(), e.getValue().get(0))) + .map(e -> new SimpleEntry<>(e.getKey(), locationPaths(fm, e.getValue()))) + .collect(Collectors.toMap(Entry :: getKey, + Entry :: getValue, + (v1, v2) -> {throw new IllegalStateException();}, + TreeMap::new)); String found = patchMap.toString(); if (!found.equals(expect)) { @@ -150,5 +163,34 @@ public class PatchModulesTest extends ModuleTestBase { } } } + + static List locationPaths(StandardJavaFileManager fm, Location loc) { + return StreamSupport.stream(fm.getLocationAsPaths(loc).spliterator(), false) + .map(p -> p.toString()) + .collect(Collectors.toList()); + } + + @Test + public void testPatchWithSource(Path base) throws Exception { + Path patch = base.resolve("patch"); + tb.writeJavaFiles(patch, "package javax.lang.model.element; public interface Extra { }"); + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "module m { requires java.compiler; }", + "package test; public interface Test extends javax.lang.model.element.Extra { }"); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + new toolbox.JavacTask(tb) + .options("--patch-module", "java.compiler=" + patch.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll(); + + if (Files.exists(classes.resolve("javax"))) { + throw new AssertionError(); + } + } } diff --git a/langtools/test/tools/javac/modules/PoorChoiceForModuleNameTest.java b/langtools/test/tools/javac/modules/PoorChoiceForModuleNameTest.java index 9bb8f15fa0c..0987d710200 100644 --- a/langtools/test/tools/javac/modules/PoorChoiceForModuleNameTest.java +++ b/langtools/test/tools/javac/modules/PoorChoiceForModuleNameTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 8160181 + * @bug 8160181 8176572 * @summary Add lint warning for digits in module names * @library /tools/lib * @modules @@ -63,6 +63,22 @@ public class PoorChoiceForModuleNameTest extends ModuleTestBase { Path src_m3 = src.resolve("mango100"); tb.writeJavaFiles(src_m3, "@SuppressWarnings(\"module\") module mango100 { }"); + // Check that there is no warning at use site. + Path src_m4 = src.resolve("mangouser"); + tb.writeJavaFiles(src_m4, "module mangouser { requires mango19; }"); + + // Check that we warn about component names ending in digit also + Path src_m5 = src.resolve("mango1000.mangofruit.mangomodule"); + tb.writeJavaFiles(src_m5, "module mango1000.mangofruit.mangomodule { }"); + + // Check that we warn about component names ending in digit also + Path src_m6 = src.resolve("mangofruit.mango1000.mangomodule"); + tb.writeJavaFiles(src_m6, "module mangofruit.mango1000.mangomodule { }"); + + // Check that we warn about component names ending in digit also + Path src_m7 = src.resolve("mangomodule.mangofruit.mango1000"); + tb.writeJavaFiles(src_m7, "module mangomodule.mangofruit.mango1000 { }"); + Path classes = base.resolve("classes"); tb.createDirectories(classes); @@ -78,10 +94,12 @@ public class PoorChoiceForModuleNameTest extends ModuleTestBase { .getOutput(Task.OutputKind.DIRECT); if (!log.contains("module-info.java:1:8: compiler.warn.poor.choice.for.module.name: mango19") || + !log.contains("module-info.java:1:8: compiler.warn.poor.choice.for.module.name: mango1000") || + !log.contains("module-info.java:1:18: compiler.warn.poor.choice.for.module.name: mango1000") || + !log.contains("module-info.java:1:30: compiler.warn.poor.choice.for.module.name: mango1000") || !log.contains("- compiler.err.warnings.and.werror") || !log.contains("1 error") || - !log.contains("1 warning")) + !log.contains("4 warning")) throw new Exception("expected output not found: " + log); } } - diff --git a/langtools/test/tools/javac/modules/ProvidesTest.java b/langtools/test/tools/javac/modules/ProvidesTest.java index 0e92bb96934..07017981ff5 100644 --- a/langtools/test/tools/javac/modules/ProvidesTest.java +++ b/langtools/test/tools/javac/modules/ProvidesTest.java @@ -377,7 +377,7 @@ public class ProvidesTest extends ModuleTestBase { .writeAll() .getOutputLines(Task.OutputKind.DIRECT); - List expected = Arrays.asList("module-info.java:1:34: compiler.err.not.def.public.cant.access: p2.C2, p2", + List expected = Arrays.asList("module-info.java:1:34: compiler.err.not.def.public: p2.C2, p2", "1 error"); if (!output.containsAll(expected)) { throw new Exception("Expected output not found"); diff --git a/langtools/test/tools/javac/modules/SourceInSymlinkTest.java b/langtools/test/tools/javac/modules/SourceInSymlinkTest.java new file mode 100644 index 00000000000..00fcb867c57 --- /dev/null +++ b/langtools/test/tools/javac/modules/SourceInSymlinkTest.java @@ -0,0 +1,102 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8175990 + * @summary source in symbolic link + * @library /tools/lib + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @build toolbox.ToolBox toolbox.JarTask toolbox.JavacTask ModuleTestBase + * @run main SourceInSymlinkTest + */ + +import java.nio.file.*; +import javax.tools.*; + +import toolbox.JarTask; +import toolbox.JavacTask; +import toolbox.Task; +import toolbox.ToolBox; + +public class SourceInSymlinkTest extends ModuleTestBase { + public static void main(String... args) throws Exception { + SourceInSymlinkTest t = new SourceInSymlinkTest(); + t.runTests(); + } + + @Test + public void testModuleSourcePath(Path base) throws Exception { + Path src = base.resolve("src"); + Path src_m = src.resolve("m"); + tb.writeFile(src_m.resolve("module-info.java"), "module m { }"); + tb.writeJavaFiles(src_m, "package p; public class A{}"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + new JavacTask(tb) + .options("--module-source-path", src.toString()) + .outdir(classes) + .files(src_m.resolve("p/A.java")) + .run() + .writeAll(); + + checkFiles( + classes.resolve("m/module-info.class"), + classes.resolve("m/p/A.class")); + + // ok normal case works, now create a symlink to the source + Path lsrc = base.resolve("link"); + Path lsrc_m = src.resolve("m"); + Path lclasses = base.resolve("link-out"); + Files.createDirectories(lclasses); + try { + Files.createSymbolicLink(lsrc, Paths.get("src")); + } catch (FileSystemException fse) { + System.err.println("warning: test passes vacuously, sym-link could not be created"); + System.err.println(fse.getMessage()); + return; + } + new JavacTask(tb) + .options("--module-source-path", lsrc.toString()) + .outdir(lclasses) + .files(lsrc_m.resolve("p/A.java")) + .run() + .writeAll(); + + checkFiles( + lclasses.resolve("m/module-info.class"), + lclasses.resolve("m/p/A.class")); + + } + + void checkFiles(Path... files) throws Exception { + for (Path f: files) { + if (!Files.exists(f)) + throw new Exception("expected file not found: " + f); + } + } +} diff --git a/langtools/test/tools/javac/modules/SourcePathTest.java b/langtools/test/tools/javac/modules/SourcePathTest.java new file mode 100644 index 00000000000..05dc3d4260a --- /dev/null +++ b/langtools/test/tools/javac/modules/SourcePathTest.java @@ -0,0 +1,310 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8176327 + * @summary javac produces wrong module-info + * @library /tools/lib + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @build toolbox.ToolBox toolbox.JavacTask ModuleTestBase + * @run main SourcePathTest + */ + +import java.io.IOException; +import java.nio.file.FileVisitResult; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.SimpleFileVisitor; +import java.nio.file.attribute.BasicFileAttributes; +import java.util.ArrayList; +import java.util.List; + +import toolbox.JavacTask; +import toolbox.Task; + +public class SourcePathTest extends ModuleTestBase { + public static void main(String... args) throws Exception { + SourcePathTest t = new SourcePathTest(); + t.runTests(); + } + + @Test + public void test_unnamedModuleOnSourcePath_fileNotOnPath(Path base) throws IOException { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "package p; public class A { }"); + Path otherSrc = base.resolve("otherSrc"); + tb.writeJavaFiles(otherSrc, "package p2; public class B { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + new JavacTask(tb) + .options("-sourcepath", src.toString()) + .outdir(classes) + .files(findJavaFiles(otherSrc)) + .run() + .writeAll(); + + showFiles(classes); + } + + @Test + public void test_unnamedModuleOnSourcePath_fileOnPath(Path base) throws IOException { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, "package p; public class A { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + new JavacTask(tb) + .options("-sourcepath", src.toString()) + .outdir(classes) + .files(findJavaFiles(src)) + .run() + .writeAll(); + + showFiles(classes); + } + + @Test + public void test_namedModuleOnSourcePath_fileNotOnPath_1(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeFile(src.resolve("module-info.java"), "module m { exports p; }"); + tb.writeJavaFiles(src, "package p; public class A { }"); + Path otherSrc = base.resolve("otherSrc"); + tb.writeJavaFiles(otherSrc, "package p2; public class B { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics=true", "-sourcepath", src.toString()) + .outdir(classes) + .files(findJavaFiles(otherSrc)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + showFiles(classes); + checkOutputContains(log, + "B.java:1:1: compiler.err.file.sb.on.source.or.patch.path.for.module"); + } + + @Test + public void test_namedModuleOnSourcePath_fileNotOnPath_2(Path base) throws Exception { + // This is the original test case: + // the source path contains one module, but the file to be compiled appears to be + // in another module. + Path src = base.resolve("src"); + Path src_mA = src.resolve("mA"); + tb.writeJavaFiles(src_mA, + "module mA { exports p; }", + "package p; public class A { }"); + Path src_mB = src.resolve("mB"); + tb.writeJavaFiles(src_mB, + "module mA { exports p2; }", + "package p2; public class B { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics=true", "-sourcepath", src_mA.toString()) + .outdir(classes) + .files(findJavaFiles(src_mB.resolve("p2"))) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + showFiles(classes); + checkOutputContains(log, + "B.java:1:1: compiler.err.file.sb.on.source.or.patch.path.for.module"); + } + + @Test + public void test_namedModuleOnSourcePath_fileOnPath(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeFile(src.resolve("module-info.java"), "module m { exports p; }"); + tb.writeJavaFiles(src, "package p; public class A { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics=true", "-sourcepath", src.toString()) + .outdir(classes) + .files(findJavaFiles(src.resolve("p"))) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + showFiles(classes); + } + + @Test + public void test_namedModuleOnSourcePath_fileOnPatchPath(Path base) throws Exception { + // similar to test_namedModuleOnSourcePath_fileNotOnPath_1 + // except that other src directory is not put on the patch path + Path src = base.resolve("src"); + tb.writeFile(src.resolve("module-info.java"), "module m { exports p; }"); + tb.writeJavaFiles(src, "package p; public class A { }"); + Path otherSrc = base.resolve("otherSrc"); + tb.writeJavaFiles(otherSrc, "package p2; public class B { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics=true", + "-sourcepath", src.toString(), + "--patch-module", "m=" + otherSrc) + .outdir(classes) + .files(findJavaFiles(otherSrc)) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + showFiles(classes); + } + + /* + * The following tests are not for the source path, but they exercise similar test + * cases for the module source path. + */ + + @Test + public void test_moduleSourcePath_fileNotOnPath(Path base) throws Exception { + Path src = base.resolve("src"); + Path src_mA = src.resolve("mA"); + tb.writeJavaFiles(src_mA, + "module mA { exports p; }", + "package p; public class A { }"); + Path src_mB = src.resolve("mB"); + tb.writeJavaFiles(src_mB, + "module mB { exports p2; }", + "package p2; public class B { }"); + Path otherSrc = base.resolve("otherSrc"); + tb.writeJavaFiles(otherSrc, "package p3; public class C { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics=true", + "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(otherSrc)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + showFiles(classes); + checkOutputContains(log, + "C.java:1:1: compiler.err.not.in.module.on.module.source.path"); + } + + @Test + public void test_moduleSourcePath_fileOnPath(Path base) throws Exception { + Path src = base.resolve("src"); + Path src_mA = src.resolve("mA"); + tb.writeJavaFiles(src_mA, + "module mA { exports p; }", + "package p; public class A { }"); + Path src_mB = src.resolve("mB"); + tb.writeJavaFiles(src_mB, + "module mB { exports p2; }", + "package p2; public class B { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics=true", + "--module-source-path", src.toString()) + .outdir(classes) + .files(findJavaFiles(src_mB.resolve("p2"))) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + showFiles(classes); + + } + + @Test + public void test_moduleSourcePath_fileOnPatchPath(Path base) throws Exception { + // similar to test_moduleSourcePath_fileNotOnPath + // except that other src directory is not put on the patch path + Path src = base.resolve("src"); + Path src_mA = src.resolve("mA"); + tb.writeJavaFiles(src_mA, + "module mA { exports p; }", + "package p; public class A { }"); + Path src_mB = src.resolve("mB"); + tb.writeJavaFiles(src_mB, + "module mB { exports p2; }", + "package p2; public class B { }"); + Path otherSrc = base.resolve("otherSrc"); + tb.writeJavaFiles(otherSrc, "package p3; public class C { }"); + + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + String log = new JavacTask(tb) + .options("-XDrawDiagnostics=true", + "--module-source-path", src.toString(), + "--patch-module", "mA=" + otherSrc) + .outdir(classes) + .files(findJavaFiles(otherSrc)) + .run() + .writeAll() + .getOutput(Task.OutputKind.DIRECT); + + showFiles(classes); + } + + /** + * This method is primarily used to give visual confirmation that a test case + * generated files when the compilation succeeds and so generates no other output, + * such as error messages. + */ + List showFiles(Path dir) throws IOException { + List files = new ArrayList<>(); + Files.walkFileTree(dir, new SimpleFileVisitor() { + @Override + public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) + throws IOException { + if (Files.isRegularFile(file)) { + out.println("Found " + file); + files.add(file); + } + return FileVisitResult.CONTINUE; + } + }); + return files; + } +} + diff --git a/langtools/test/tools/javac/modules/T8158224/T8158224.java b/langtools/test/tools/javac/modules/T8158224/T8158224.java index 37f4553bbb8..4cb149d7a25 100644 --- a/langtools/test/tools/javac/modules/T8158224/T8158224.java +++ b/langtools/test/tools/javac/modules/T8158224/T8158224.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -25,8 +25,41 @@ * @test * @bug 8158224 * @summary NullPointerException in com.sun.tools.javac.comp.Modules.checkCyclicDependencies when module missing + * @library /tools/lib + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @build toolbox.ToolBox toolbox.JavacTask * @build Processor - * @compile/fail/ref=T8158224.out -XDrawDiagnostics -processor Processor mods/foo/module-info.java + * @run main T8158224 */ -// No code here, this file is just to host test description. +// previously: +// @compile/fail/ref=T8158224.out -XDrawDiagnostics -processor Processor mods/foo/module-info.java + +import java.util.List; +import toolbox.JavacTask; +import toolbox.Task; +import toolbox.ToolBox; + +public class T8158224 { + public static void main(String... args) throws Exception { + ToolBox tb = new ToolBox(); + + List log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "-processor", "Processor", + "-sourcepath", tb.testSrc + "/mods/foo", + "-classpath", tb.testClasses) + .files(tb.testSrc + "/mods/foo/module-info.java") + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!log.equals(List.of( + "module-info.java:4:14: compiler.err.module.not.found: nonexistent", + "1 error"))) { + throw new Exception("Expected output not found"); + } + } +} diff --git a/langtools/test/tools/javac/modules/T8158224/T8158224.out b/langtools/test/tools/javac/modules/T8158224/T8158224.out deleted file mode 100644 index 8690d80cfd1..00000000000 --- a/langtools/test/tools/javac/modules/T8158224/T8158224.out +++ /dev/null @@ -1,2 +0,0 @@ -module-info.java:4:14: compiler.err.module.not.found: nonexistent -1 error diff --git a/langtools/test/tools/javac/modules/T8159439/NPEForModuleInfoWithNonZeroSuperClassTest.out b/langtools/test/tools/javac/modules/T8159439/NPEForModuleInfoWithNonZeroSuperClassTest.out index 6ddc9de8a6c..d5ce62bc1bc 100644 --- a/langtools/test/tools/javac/modules/T8159439/NPEForModuleInfoWithNonZeroSuperClassTest.out +++ b/langtools/test/tools/javac/modules/T8159439/NPEForModuleInfoWithNonZeroSuperClassTest.out @@ -1,2 +1,2 @@ -- compiler.err.cant.access: mod.module-info, (compiler.misc.bad.class.file.header: module-info.class, (compiler.misc.module.info.invalid.super.class)) +- compiler.err.cant.access: .module-info, (compiler.misc.bad.class.file.header: module-info.class, (compiler.misc.module.name.mismatch: mod/module-info, )) 1 error diff --git a/langtools/test/tools/javac/modules/WrongErrorMessageForNestedServiceProviderTest.java b/langtools/test/tools/javac/modules/WrongErrorMessageForNestedServiceProviderTest.java new file mode 100644 index 00000000000..096405bb878 --- /dev/null +++ b/langtools/test/tools/javac/modules/WrongErrorMessageForNestedServiceProviderTest.java @@ -0,0 +1,181 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8174243 + * @summary incorrect error message for nested service provider + * @library /tools/lib + * @modules + * jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * @build toolbox.ToolBox toolbox.JavacTask ModuleTestBase + * @run main WrongErrorMessageForNestedServiceProviderTest + */ + +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.Arrays; +import java.util.List; + +import toolbox.JavacTask; +import toolbox.Task; +import toolbox.ToolBox; + +public class WrongErrorMessageForNestedServiceProviderTest extends ModuleTestBase { + public static void main(String... args) throws Exception { + WrongErrorMessageForNestedServiceProviderTest t = new WrongErrorMessageForNestedServiceProviderTest(); + t.runTests(); + } + + private static final String twoServicesModuleDef = + "module m {\n" + + " exports example;\n" + + " provides example.SomeService with example.ServiceImpl;\n" + + " provides example.SomeServiceOuter with example.Outer.ServiceImplOuter;\n" + + "}"; + + private static final String someServiceInt = + "package example;\n" + + "public interface SomeService {\n" + + " public void foo();\n" + + "}"; + + private static final String someServiceIntOuter = + "package example;\n" + + "public interface SomeServiceOuter {\n" + + " public void foo();\n" + + "}"; + + @Test + public void testPositive(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + twoServicesModuleDef, + someServiceInt, + someServiceIntOuter, + "package example;\n" + + "public class ServiceImpl implements example.SomeService {\n" + + " public ServiceImpl() {}\n" + + " public void foo() {}\n" + + "}", + + "package example;\n" + + "class Outer {\n" + + " public static class ServiceImplOuter implements example.SomeServiceOuter {\n" + + " public ServiceImplOuter() {}\n" + + " public void foo() {}\n" + + " }\n" + + "}"); + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + List output = new JavacTask(tb) + .outdir(classes) + .options("-Werror", "-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + List expected = Arrays.asList(""); + if (!output.containsAll(expected)) { + throw new Exception("Expected output not found"); + } + } + + @Test + public void testNegative(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + twoServicesModuleDef, + someServiceInt, + someServiceIntOuter, + + "package example;\n" + + "class ServiceImpl implements example.SomeService {\n" + + " public ServiceImpl() {}\n" + + " public void foo() {}\n" + + "}", + + "package example;\n" + + "class Outer {\n" + + " static class ServiceImplOuter implements example.SomeServiceOuter {\n" + + " public ServiceImplOuter() {}\n" + + " public void foo() {}\n" + + " }\n" + + "}"); + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + List output = new JavacTask(tb) + .outdir(classes) + .options("-Werror", "-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + List expected = Arrays.asList( + "module-info.java:3:46: compiler.err.not.def.public: example.ServiceImpl, example", + "module-info.java:4:57: compiler.err.not.def.public: example.Outer.ServiceImplOuter, example.Outer", + "2 errors"); + if (!output.containsAll(expected)) { + throw new Exception("Expected output not found"); + } + } + + @Test + public void testClassWrappedByPrivateClass(Path base) throws Exception { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "module m {\n" + + " exports example;\n" + + " provides example.SomeServiceOuter with example.Outer1.Outer2.ServiceImplOuter;\n" + + "}", + + someServiceIntOuter, + + "package example;\n" + + "class Outer1 {\n" + + " static private class Outer2 {\n" + + " public static class ServiceImplOuter implements example.SomeServiceOuter {\n" + + " public ServiceImplOuter() {}\n" + + " public void foo() {}\n" + + " }\n" + + " }\n" + + "}"); + Path classes = base.resolve("classes"); + Files.createDirectories(classes); + + List output = new JavacTask(tb) + .outdir(classes) + .options("-Werror", "-XDrawDiagnostics") + .files(findJavaFiles(src)) + .run(Task.Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + List expected = Arrays.asList(""); + if (!output.containsAll(expected)) { + throw new Exception("Expected output not found"); + } + } +} diff --git a/langtools/test/tools/javac/options/release/ReleaseOptionClashes.java b/langtools/test/tools/javac/options/release/ReleaseOptionClashes.java index e7e553c799c..c0a3b193c46 100644 --- a/langtools/test/tools/javac/options/release/ReleaseOptionClashes.java +++ b/langtools/test/tools/javac/options/release/ReleaseOptionClashes.java @@ -44,17 +44,19 @@ public class ReleaseOptionClashes { } void run() throws Exception { - doRunTest("-bootclasspath", "any"); - doRunTest("-Xbootclasspath:any"); - doRunTest("-Xbootclasspath/a:any"); - doRunTest("-Xbootclasspath/p:any"); - doRunTest("-endorseddirs", "any"); - doRunTest("-extdirs", "any"); - doRunTest("-source", "8"); - doRunTest("-target", "8"); + doRunTest("7", "-bootclasspath", "any"); + doRunTest("7", "-Xbootclasspath:any"); + doRunTest("7", "-Xbootclasspath/a:any"); + doRunTest("7", "-Xbootclasspath/p:any"); + doRunTest("7", "-endorseddirs", "any"); + doRunTest("7", "-extdirs", "any"); + doRunTest("7", "-source", "8"); + doRunTest("7", "-target", "8"); + doRunTest("9", "--system", "none"); + doRunTest("9", "--upgrade-module-path", "any"); } - void doRunTest(String... args) throws Exception { + void doRunTest(String release, String... args) throws Exception { System.out.println("Testing clashes for arguments: " + Arrays.asList(args)); Class log = Class.forName("com.sun.tools.javac.util.Log", true, cl); Field useRawMessages = log.getDeclaredField("useRawMessages"); @@ -62,7 +64,7 @@ public class ReleaseOptionClashes { useRawMessages.setBoolean(null, true); ByteArrayOutputStream out = new ByteArrayOutputStream(); List options = new ArrayList<>(); - options.addAll(Arrays.asList("--release", "7")); + options.addAll(Arrays.asList("--release", release)); options.addAll(Arrays.asList(args)); options.add(System.getProperty("test.src") + File.separator + "ReleaseOptionClashes.java"); compiler.run(null, null, out, options.toArray(new String[0])); diff --git a/langtools/test/tools/javac/options/release/ReleaseOptionUnsupported.java b/langtools/test/tools/javac/options/release/ReleaseOptionUnsupported.java new file mode 100644 index 00000000000..c25ae7279a7 --- /dev/null +++ b/langtools/test/tools/javac/options/release/ReleaseOptionUnsupported.java @@ -0,0 +1,313 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8178152 + * @summary Verify unsupported modules and module options handling. + * @library /tools/lib + * @modules jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main + * jdk.compiler/com.sun.tools.javac.jvm + * jdk.jdeps/com.sun.tools.classfile + * jdk.jdeps/com.sun.tools.javap + * @build toolbox.ToolBox toolbox.JarTask toolbox.JavacTask toolbox.JavapTask toolbox.TestRunner + * @run main ReleaseOptionUnsupported + */ + +import java.io.IOException; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.Arrays; +import java.util.List; + +import com.sun.tools.javac.jvm.Target; +import toolbox.JavacTask; +import toolbox.Task; +import toolbox.Task.Expect; +import toolbox.TestRunner; +import toolbox.ToolBox; + +public class ReleaseOptionUnsupported extends TestRunner { + + private final ToolBox tb = new ToolBox(); + + public ReleaseOptionUnsupported() { + super(System.err); + } + + public static void main(String... args) throws Exception { + new ReleaseOptionUnsupported().runTests(); + } + + @Test + public void testUnsafe(Path base) throws IOException { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "module m { requires jdk.unsupported; }", + "package test; public class Test { sun.misc.Unsafe unsafe; } "); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + List log; + List expected = Arrays.asList( + "Test.java:1:43: compiler.warn.sun.proprietary: sun.misc.Unsafe", + "1 warning" + ); + + log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!expected.equals(log)) { + throw new AssertionError("Unexpected output: " + log); + } + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--release", Target.DEFAULT.multiReleaseValue()) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!expected.equals(log)) { + throw new AssertionError("Unexpected output: " + log); + } + } + + @Test + public void testUnsafeUnnamed(Path base) throws IOException { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "package test; public class Test { sun.misc.Unsafe unsafe; } "); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + List log; + List expected = Arrays.asList( + "Test.java:1:43: compiler.warn.sun.proprietary: sun.misc.Unsafe", + "1 warning" + ); + + log = new JavacTask(tb) + .options("-XDrawDiagnostics") + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!expected.equals(log)) { + throw new AssertionError("Unexpected output: " + log); + } + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--release", Target.DEFAULT.multiReleaseValue()) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + if (!expected.equals(log)) { + throw new AssertionError("Unexpected output: " + log); + } + } + + @Test + public void testAddExports(Path base) throws IOException { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "module m { }", + "package test; public class Test { jdk.internal.misc.Unsafe unsafe; } "); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + new JavacTask(tb) + .options("-XDrawDiagnostics", + "--add-exports", "java.base/jdk.internal.misc=m") + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + List log; + List expected; + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--add-exports", "java.base/jdk.internal.misc=m", + "--release", Target.DEFAULT.multiReleaseValue()) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + expected = Arrays.asList( + "- compiler.err.add.exports.with.release: java.base", + "1 error" + ); + + if (!expected.equals(log)) { + throw new AssertionError("Unexpected output: " + log); + } + + //OK to add exports a package of a non-system module: + tb.writeJavaFiles(src, + "package test; public class Test { } "); + tb.createDirectories(classes); + + new JavacTask(tb) + .options("-XDrawDiagnostics", + "--add-exports", "m/test=ALL-UNNAMED", + "--release", Target.DEFAULT.multiReleaseValue()) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + } + + @Test + public void testAddReads(Path base) throws IOException { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "module m { }", + "package test; public class Test { } "); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + + new JavacTask(tb) + .options("-XDrawDiagnostics", + "--add-reads", "java.base=m") + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + List log; + List expected; + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--add-reads", "java.base=m", + "--release", Target.DEFAULT.multiReleaseValue()) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + expected = Arrays.asList( + "- compiler.err.add.reads.with.release: java.base", + "1 error" + ); + + if (!expected.equals(log)) { + throw new AssertionError("Unexpected output: " + log); + } + + //OK to add reads a package of a non-system module: + tb.createDirectories(classes); + + new JavacTask(tb) + .options("-XDrawDiagnostics", + "--add-reads", "m=java.base", + "--release", Target.DEFAULT.multiReleaseValue()) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + } + + @Test + public void testPatchModule(Path base) throws IOException { + Path src = base.resolve("src"); + tb.writeJavaFiles(src, + "module m { }", + "package test; public class Test { } "); + Path classes = base.resolve("classes"); + tb.createDirectories(classes); + Path patch = base.resolve("patch"); + tb.createDirectories(patch); + + new JavacTask(tb) + .options("-XDrawDiagnostics", + "--patch-module", "java.base=" + patch) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + List log; + List expected; + + log = new JavacTask(tb) + .options("-XDrawDiagnostics", + "--patch-module", "java.base=" + patch, + "--release", Target.DEFAULT.multiReleaseValue()) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.FAIL) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + + expected = Arrays.asList( + "- compiler.err.patch.module.with.release: java.base", + "1 error" + ); + + if (!expected.equals(log)) { + throw new AssertionError("Unexpected output: " + log); + } + + //OK to patch a non-system module: + tb.createDirectories(classes); + + new JavacTask(tb) + .options("-XDrawDiagnostics", + "--patch-module", "m=" + patch, + "--release", Target.DEFAULT.multiReleaseValue()) + .outdir(classes) + .files(tb.findJavaFiles(src)) + .run(Expect.SUCCESS) + .writeAll() + .getOutputLines(Task.OutputKind.DIRECT); + } + + protected void runTests() throws Exception { + runTests(m -> new Object[] { Paths.get(m.getName()) }); + } +} diff --git a/langtools/test/tools/javac/overload/T8176265.java b/langtools/test/tools/javac/overload/T8176265.java new file mode 100644 index 00000000000..ecd014744eb --- /dev/null +++ b/langtools/test/tools/javac/overload/T8176265.java @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176265 + * @summary Method overload resolution on a covariant base type doesn't work in 9 + * @compile T8176265.java + */ + +class T8176265 { + static class Sup { } + static class Sub extends Sup { } + + void method(Sup f) { } + void method(Sub f) { } + + + static void m(T8176265 test, Sub sz) { + test.method(sz); + } +} diff --git a/langtools/test/tools/javac/processing/StopAfterError/StopAfterError.java b/langtools/test/tools/javac/processing/StopAfterError/StopAfterError.java index 6e6876f6f4e..65127b01220 100644 --- a/langtools/test/tools/javac/processing/StopAfterError/StopAfterError.java +++ b/langtools/test/tools/javac/processing/StopAfterError/StopAfterError.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,7 +27,8 @@ * @summary If an error is produced by an annotation processor, the code should not be Attred, \ * unless requested * @modules jdk.compiler - * @compile StopAfterError.java + * @library /tools/javac/lib + * @build StopAfterError JavacTestingAbstractProcessor * @compile/fail/ref=StopAfterError.out -XDrawDiagnostics -processor StopAfterError StopAfterErrorAux.java * @compile/fail/ref=StopAfterError.out -XDshould-stop.ifError=PROCESS -XDrawDiagnostics -processor StopAfterError StopAfterErrorAux.java * @compile/fail/ref=StopAfterErrorContinue.out -XDshould-stop.ifError=ATTR -XDrawDiagnostics -processor StopAfterError StopAfterErrorAux.java @@ -42,8 +43,7 @@ import javax.lang.model.SourceVersion; import javax.lang.model.element.TypeElement; import javax.tools.Diagnostic.Kind; -@SupportedAnnotationTypes("*") -public class StopAfterError extends AbstractProcessor { +public class StopAfterError extends JavacTestingAbstractProcessor { @Override public boolean process(Set annotations, RoundEnvironment roundEnv) { @@ -52,10 +52,4 @@ public class StopAfterError extends AbstractProcessor { } return false; } - - @Override - public SourceVersion getSupportedSourceVersion() { - return SourceVersion.latestSupported(); - } - } diff --git a/langtools/test/tools/javac/processing/errors/EnsureAnnotationTypeMismatchException/Source.out b/langtools/test/tools/javac/processing/errors/EnsureAnnotationTypeMismatchException/Source.out index 4440550e4f7..c8cd72c4422 100644 --- a/langtools/test/tools/javac/processing/errors/EnsureAnnotationTypeMismatchException/Source.out +++ b/langtools/test/tools/javac/processing/errors/EnsureAnnotationTypeMismatchException/Source.out @@ -3,5 +3,5 @@ Generated.java:3:26: compiler.err.prob.found.req: (compiler.misc.inconvertible.t Generated.java:4:22: compiler.err.prob.found.req: (compiler.misc.inconvertible.types: java.lang.String, E) Generated.java:5:37: compiler.err.annotation.not.valid.for.type: int Generated.java:6:32: compiler.err.annotation.value.not.allowable.type -Generated.java:7:35: compiler.err.annotation.value.must.be.class.literal +Generated.java:7:35: compiler.err.expression.not.allowable.as.annotation.value 6 errors diff --git a/langtools/test/tools/javac/processing/errors/StopOnInapplicableAnnotations/Processor.java b/langtools/test/tools/javac/processing/errors/StopOnInapplicableAnnotations/Processor.java index 0a3b525510c..8ce1a9cc6d5 100644 --- a/langtools/test/tools/javac/processing/errors/StopOnInapplicableAnnotations/Processor.java +++ b/langtools/test/tools/javac/processing/errors/StopOnInapplicableAnnotations/Processor.java @@ -63,7 +63,7 @@ public class Processor extends AbstractProcessor { if (args.length != 1) throw new IllegalStateException("Must provide class name!"); String testContent = null; List sourcePath = new ArrayList<>(); - for (String sourcePaths : System.getProperty("test.src.path").split(":")) { + for (String sourcePaths : System.getProperty("test.src.path").split(File.pathSeparator)) { sourcePath.add(new File(sourcePaths)); } JavacFileManager fm = JavacTool.create().getStandardFileManager(null, null, null); diff --git a/langtools/test/tools/javac/processing/model/LocalClasses/LocalClassesModel.java b/langtools/test/tools/javac/processing/model/LocalClasses/LocalClassesModel.java index a75305771e7..d91a84d58d2 100644 --- a/langtools/test/tools/javac/processing/model/LocalClasses/LocalClassesModel.java +++ b/langtools/test/tools/javac/processing/model/LocalClasses/LocalClassesModel.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,8 @@ * @bug 8166700 * @summary Check that local classes originating in static initializer can be loaded properly. * @modules jdk.compiler - * @build LocalTest$1Local LocalTest$2Local LocalTest$3Local LocalTest$4Local LocalTest$5Local LocalTest + * @library /tools/javac/lib + * @build LocalTest$1Local LocalTest$2Local LocalTest$3Local LocalTest$4Local LocalTest$5Local LocalTest JavacTestingAbstractProcessor * @compile LocalClassesModel.java * @compile/process/ref=LocalClassesModel.out -processor LocalClassesModel LocalTest$1Local LocalTest$2Local LocalTest$3Local LocalTest$4Local LocalTest$5Local LocalTest */ @@ -42,8 +43,7 @@ import javax.lang.model.element.TypeElement; import javax.lang.model.element.VariableElement; import javax.lang.model.util.ElementFilter; -@SupportedAnnotationTypes("*") -public class LocalClassesModel extends AbstractProcessor { +public class LocalClassesModel extends JavacTestingAbstractProcessor { @Override public boolean process(Set annotations, RoundEnvironment roundEnv) { @@ -65,9 +65,4 @@ public class LocalClassesModel extends AbstractProcessor { return false; } - - @Override - public SourceVersion getSupportedSourceVersion() { - return SourceVersion.latestSupported(); - } } diff --git a/langtools/test/tools/javac/processing/model/TestSourceVersion.java b/langtools/test/tools/javac/processing/model/TestSourceVersion.java index 396fe10b1b9..27da94d6252 100644 --- a/langtools/test/tools/javac/processing/model/TestSourceVersion.java +++ b/langtools/test/tools/javac/processing/model/TestSourceVersion.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 7025809 8028543 6415644 + * @bug 7025809 8028543 6415644 8028544 8029942 * @summary Test latest, latestSupported, underscore as keyword, etc. * @author Joseph D. Darcy * @modules java.compiler @@ -44,8 +44,8 @@ public class TestSourceVersion { } private static void testLatestSupported() { - if (SourceVersion.latest() != RELEASE_9 || - SourceVersion.latestSupported() != RELEASE_9) + if (SourceVersion.latest() != RELEASE_10 || + SourceVersion.latestSupported() != RELEASE_10) throw new RuntimeException("Unexpected release value(s) found:\n" + "latest:\t" + SourceVersion.latest() + "\n" + "latestSupported:\t" + SourceVersion.latestSupported()); diff --git a/langtools/test/tools/javac/processing/model/nestedTypeVars/NestedTypeVars.java b/langtools/test/tools/javac/processing/model/nestedTypeVars/NestedTypeVars.java index 24a62099efb..1332866c4e8 100644 --- a/langtools/test/tools/javac/processing/model/nestedTypeVars/NestedTypeVars.java +++ b/langtools/test/tools/javac/processing/model/nestedTypeVars/NestedTypeVars.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,8 @@ /** * @test * @modules jdk.compiler - * @build NestedTypeVars + * @library /tools/javac/lib + * @build NestedTypeVars JavacTestingAbstractProcessor * @compile/process/ref=NestedTypeVars.out -processor NestedTypeVars Test$1L1$L2$1L3$L4$L5 Test$1L1$CCheck Test$1L1 Test$1CCheck Test$CCheck Test */ @@ -44,8 +45,7 @@ import javax.lang.model.type.TypeMirror; import javax.lang.model.type.TypeVariable; import javax.lang.model.util.ElementFilter; -@SupportedAnnotationTypes("*") -public class NestedTypeVars extends AbstractProcessor{ +public class NestedTypeVars extends JavacTestingAbstractProcessor { @Override public boolean process(Set annotations, RoundEnvironment roundEnv) { @@ -102,12 +102,6 @@ public class NestedTypeVars extends AbstractProcessor{ throw new IllegalStateException("Unexpected element: " + el + "(" + el.getKind() + ")"); } } - @Override - public SourceVersion getSupportedSourceVersion() { - return SourceVersion.latestSupported(); - } - - } class Test { diff --git a/langtools/test/tools/javac/processing/model/util/elements/TestAllFoos.java b/langtools/test/tools/javac/processing/model/util/elements/TestAllFoos.java new file mode 100644 index 00000000000..caff3b89744 --- /dev/null +++ b/langtools/test/tools/javac/processing/model/util/elements/TestAllFoos.java @@ -0,0 +1,93 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8173945 + * @summary Test Elements.getAll{Type, Package, Module}Elements + * @library /tools/javac/lib + * @modules java.compiler + * jdk.compiler + * @build JavacTestingAbstractProcessor TestAllFoos + * @compile -processor TestAllFoos -proc:only --release 8 --source-path modules/m1/pkg modules/m1/pkg/C.java + * @compile -processor TestAllFoos -proc:only --release 8 --source-path modules/m2/pkg modules/m2/pkg/C.java + */ +// @compile -processor TestAllFoos -proc:only --module-source-path modules -m m1,m2 + +import java.util.Set; +import static java.util.Objects.*; +import javax.annotation.processing.*; +import static javax.lang.model.SourceVersion.*; +import javax.lang.model.element.*; +import javax.lang.model.util.*; + +/** + * Test basic workings of Elements.getAll{Type, Package, Module}Elements under + * pre- and post-modules. + */ +public class TestAllFoos extends JavacTestingAbstractProcessor { + public boolean process(Set annotations, + RoundEnvironment roundEnv) { + if (!roundEnv.processingOver()) { + boolean expectModules = + (processingEnv.getSourceVersion().compareTo(RELEASE_9) >= 0); + + testSetSize(eltUtils.getAllTypeElements("java.lang.String"), 1); + testSetSize(eltUtils.getAllTypeElements("example.com"), 0); + + if (!expectModules) { + // Expect empty modules set, single package named "pkg" with one type "pkg.C". + testSetSize(eltUtils.getAllModuleElements(), 0); + testSetSize(eltUtils.getAllPackageElements("pkg"), 1); + testSetSize(eltUtils.getAllTypeElements("pkg.C"), 1); + } else { + Set modules = + requireNonNull(eltUtils.getAllModuleElements()); + + ModuleElement m1 = requireNonNull(eltUtils.getModuleElement("m1")); + ModuleElement m2 = requireNonNull(eltUtils.getModuleElement("m2")); + + if (!modules.contains(m1) || + !modules.contains(m2) || + !modules.contains(requireNonNull(eltUtils.getModuleElement("java.base")))) + throw new RuntimeException("Missing modules " + modules); + + // Expect two packages named "pkg" and two types named "pkg.C". + testSetSize(eltUtils.getAllPackageElements("pkg"), 2); + testSetSize(eltUtils.getAllTypeElements("pkg.C"), 2); + } + } + return true; + } + + /** + * Check the set argument against null and throw an exception if + * the set is not of the expected size. + */ + private static Set testSetSize(Set set, int expectedSize) { + requireNonNull(set); + if (set.size() != expectedSize) + throw new RuntimeException("Unexpected size of set " + set); + return set; + } +} diff --git a/langtools/test/tools/javac/processing/model/util/elements/modules/m1/module-info.java b/langtools/test/tools/javac/processing/model/util/elements/modules/m1/module-info.java new file mode 100644 index 00000000000..6897fc31e56 --- /dev/null +++ b/langtools/test/tools/javac/processing/model/util/elements/modules/m1/module-info.java @@ -0,0 +1,4 @@ +/* /nodynamiccopyright/ */ + +module m1 { +} diff --git a/langtools/test/tools/javac/processing/model/util/elements/modules/m1/pkg/C.java b/langtools/test/tools/javac/processing/model/util/elements/modules/m1/pkg/C.java new file mode 100644 index 00000000000..17c3c1a52c3 --- /dev/null +++ b/langtools/test/tools/javac/processing/model/util/elements/modules/m1/pkg/C.java @@ -0,0 +1,11 @@ +/* /nodynamiccopyright/ */ + +package pkg; + +/** + * A lovely description of class C of package pkg in module m1. + */ +public class C { + public C() {} + public static String foo() {return "foo";} +} diff --git a/langtools/test/tools/javac/processing/model/util/elements/modules/m1/pkg/package-info.java b/langtools/test/tools/javac/processing/model/util/elements/modules/m1/pkg/package-info.java new file mode 100644 index 00000000000..969f9cffe56 --- /dev/null +++ b/langtools/test/tools/javac/processing/model/util/elements/modules/m1/pkg/package-info.java @@ -0,0 +1,6 @@ +/* /nodynamiccopyright/ */ + +/** + * A lovely description of package pkg in module m1. + */ +package pkg; diff --git a/langtools/test/tools/javac/processing/model/util/elements/modules/m2/module-info.java b/langtools/test/tools/javac/processing/model/util/elements/modules/m2/module-info.java new file mode 100644 index 00000000000..aa297e558e4 --- /dev/null +++ b/langtools/test/tools/javac/processing/model/util/elements/modules/m2/module-info.java @@ -0,0 +1,4 @@ +/* /nodynamiccopyright/ */ + +module m2 { +} diff --git a/langtools/test/tools/javac/processing/model/util/elements/modules/m2/pkg/C.java b/langtools/test/tools/javac/processing/model/util/elements/modules/m2/pkg/C.java new file mode 100644 index 00000000000..d9f86606181 --- /dev/null +++ b/langtools/test/tools/javac/processing/model/util/elements/modules/m2/pkg/C.java @@ -0,0 +1,11 @@ +/* /nodynamiccopyright/ */ + +package pkg; + +/** + * A lovely description of class C of package pkg in module m2. + */ +public class C { + public C() {} + public static String bar() {return "bar";} +} diff --git a/langtools/test/tools/javac/processing/model/util/elements/modules/m2/pkg/package-info.java b/langtools/test/tools/javac/processing/model/util/elements/modules/m2/pkg/package-info.java new file mode 100644 index 00000000000..032700bf4e7 --- /dev/null +++ b/langtools/test/tools/javac/processing/model/util/elements/modules/m2/pkg/package-info.java @@ -0,0 +1,6 @@ +/* /nodynamiccopyright/ */ + +/** + * A lovely description of package pkg in module m2. + */ +package pkg; diff --git a/langtools/test/tools/javac/processing/model/util/types/TestPseudoTypeHandling.java b/langtools/test/tools/javac/processing/model/util/types/TestPseudoTypeHandling.java new file mode 100644 index 00000000000..5359d26e53f --- /dev/null +++ b/langtools/test/tools/javac/processing/model/util/types/TestPseudoTypeHandling.java @@ -0,0 +1,85 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8175335 + * @summary Test Types methods on module and package TypeMirrors + * @author Joseph D. Darcy + * @library /tools/javac/lib + * @modules jdk.compiler + * @build JavacTestingAbstractProcessor TestPseudoTypeHandling + * @compile -processor TestPseudoTypeHandling -proc:only TestPseudoTypeHandling.java + */ + +import java.util.*; +import java.util.function.*; +import static java.util.Objects.*; +import javax.annotation.processing.*; +import javax.lang.model.element.*; +import javax.lang.model.type.*; +import javax.lang.model.util.*; + +/** + * Test basic handling of module type. + */ +public class TestPseudoTypeHandling extends JavacTestingAbstractProcessor { + public boolean process(Set annotations, + RoundEnvironment roundEnv) { + if (!roundEnv.processingOver()) { + TypeMirror objectType = requireNonNull(eltUtils.getTypeElement("java.lang.Object")).asType(); + + List typeMirrorsToTest = + List.of(requireNonNull(eltUtils.getModuleElement("java.base")).asType(), + requireNonNull(eltUtils.getPackageElement("java.lang")).asType()); + + for (TypeMirror type : typeMirrorsToTest) { + expectException(t -> typeUtils.isSubtype(t, objectType), type); + expectException(t -> typeUtils.isSubtype(objectType, t), type); + + expectException(t -> typeUtils.isAssignable(t, objectType), type); + expectException(t -> typeUtils.isAssignable(objectType, t), type); + + expectException(t -> typeUtils.contains(t, objectType), type); + expectException(t -> typeUtils.contains(objectType, t), type); + + expectException(t -> typeUtils.capture(t), type); + expectException(t -> typeUtils.erasure(t), type); + + expectException(t -> typeUtils.getArrayType(t), type); + + expectException(t -> typeUtils.directSupertypes(t), type); + } + } + return true; + } + + void expectException(Consumer argument, TypeMirror type) { + try { + argument.accept(type); + throw new RuntimeException("Should not reach " + type.toString()); + } catch (IllegalArgumentException e) { + ; // Expected + } + } +} diff --git a/langtools/test/tools/javac/processing/warnings/TestSourceVersionWarnings.java b/langtools/test/tools/javac/processing/warnings/TestSourceVersionWarnings.java index 4e49da37fb1..5b9365ed1cb 100644 --- a/langtools/test/tools/javac/processing/warnings/TestSourceVersionWarnings.java +++ b/langtools/test/tools/javac/processing/warnings/TestSourceVersionWarnings.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -35,6 +35,7 @@ * @compile/ref=gold_unsp_warn.out -XDrawDiagnostics -processor TestSourceVersionWarnings -proc:only -ASourceVersion=RELEASE_6 -source 1.6 -Xlint:-options -Aunsupported HelloWorld.java * @compile/ref=gold_sv_none.out -XDrawDiagnostics -processor TestSourceVersionWarnings -proc:only -ASourceVersion=RELEASE_7 -source 1.7 -Xlint:-options HelloWorld.java * @compile/ref=gold_sv_none.out -XDrawDiagnostics -processor TestSourceVersionWarnings -proc:only -ASourceVersion=RELEASE_8 -source 1.8 -Xlint:-options HelloWorld.java + * @compile/ref=gold_sv_none.out -XDrawDiagnostics -processor TestSourceVersionWarnings -proc:only -ASourceVersion=RELEASE_9 -source 1.9 -Xlint:-options HelloWorld.java */ import java.util.Set; diff --git a/langtools/test/tools/javac/profiles/ProfileOptionTest.java b/langtools/test/tools/javac/profiles/ProfileOptionTest.java index af6a1183035..37c98fd715e 100644 --- a/langtools/test/tools/javac/profiles/ProfileOptionTest.java +++ b/langtools/test/tools/javac/profiles/ProfileOptionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -148,6 +148,7 @@ public class ProfileOptionTest { error("unexpected exception from compiler: " + ise); break; case JDK1_9: + case JDK1_10: if (p == Profile.DEFAULT) break; if (ise == null) diff --git a/langtools/test/tools/javac/redefineObject/Object1-test.java b/langtools/test/tools/javac/redefineObject/Object1-test.java index a654ecee5d5..dae9667452d 100644 --- a/langtools/test/tools/javac/redefineObject/Object1-test.java +++ b/langtools/test/tools/javac/redefineObject/Object1-test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,6 +27,6 @@ * @summary java.lang.Object can't be redefined without crashing javac * @author gafter * - * @compile/module=java.base/fail/ref=Object1.out -XDrawDiagnostics Object1.java + * @compile/module=java.base/fail/ref=Object1.out -XDrawDiagnostics java/lang/Object1.java */ diff --git a/langtools/test/tools/javac/redefineObject/Object2-test.java b/langtools/test/tools/javac/redefineObject/Object2-test.java index 59eb4b670df..8eb033b5cfa 100644 --- a/langtools/test/tools/javac/redefineObject/Object2-test.java +++ b/langtools/test/tools/javac/redefineObject/Object2-test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,5 +27,5 @@ * @summary java.lang.Object can't be redefined without crashing javac * @author gafter * - * @compile/module=java.base/fail/ref=Object2.out -XDrawDiagnostics Object2.java + * @compile/module=java.base/fail/ref=Object2.out -XDrawDiagnostics java/lang/Object2.java */ diff --git a/langtools/test/tools/javac/redefineObject/java.base/Object1.java b/langtools/test/tools/javac/redefineObject/java.base/java/lang/Object1.java similarity index 100% rename from langtools/test/tools/javac/redefineObject/java.base/Object1.java rename to langtools/test/tools/javac/redefineObject/java.base/java/lang/Object1.java diff --git a/langtools/test/tools/javac/redefineObject/java.base/Object2.java b/langtools/test/tools/javac/redefineObject/java.base/java/lang/Object2.java similarity index 100% rename from langtools/test/tools/javac/redefineObject/java.base/Object2.java rename to langtools/test/tools/javac/redefineObject/java.base/java/lang/Object2.java diff --git a/langtools/test/tools/javac/staticImport/ImportPrivate.out b/langtools/test/tools/javac/staticImport/ImportPrivate.out index ba382b905f8..8550e7c4503 100644 --- a/langtools/test/tools/javac/staticImport/ImportPrivate.out +++ b/langtools/test/tools/javac/staticImport/ImportPrivate.out @@ -1,3 +1,3 @@ -ImportPrivate.java:12:1: compiler.err.cant.resolve.location: kindname.static, m, , , kindname.class, importPrivate.A +ImportPrivate.java:12:1: compiler.err.cant.resolve.location: kindname.static, m, null, null, (compiler.misc.location: kindname.class, importPrivate.A, null) ImportPrivate.java:22:9: compiler.err.cant.resolve.location.args: kindname.method, m, , , (compiler.misc.location: kindname.class, importPrivate.MyTest, null) 2 errors diff --git a/langtools/test/tools/javac/synthesize/Main.java b/langtools/test/tools/javac/synthesize/Main.java index d92cff2a96e..bf430b8889c 100644 --- a/langtools/test/tools/javac/synthesize/Main.java +++ b/langtools/test/tools/javac/synthesize/Main.java @@ -92,12 +92,17 @@ public class Main File empty = new File("empty"); empty.mkdirs(); + // files to compile are in a separate directory from test to avoid + // confusing jtreg + File src = new File(testSrc, "src"); + List args = new ArrayList(); args.add("-classpath"); args.add("empty"); if (stdBootClassPath) { - args.add("-Xmodule:java.base"); + args.add("--patch-module"); + args.add("java.base=" + testSrc.getAbsolutePath()); } else { args.add("--system"); args.add("none"); @@ -108,9 +113,6 @@ public class Main args.add("-d"); args.add("."); - // files to compile are in a separate directory from test to avoid - // confusing jtreg - File src = new File(testSrc, "src"); for (String f: files) args.add(new File(src, f).getPath()); diff --git a/langtools/test/tools/javac/tree/ArrayTypeToString.java b/langtools/test/tools/javac/tree/ArrayTypeToString.java index a200f6d64c9..9de443a865b 100644 --- a/langtools/test/tools/javac/tree/ArrayTypeToString.java +++ b/langtools/test/tools/javac/tree/ArrayTypeToString.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -26,7 +26,8 @@ * @bug 8068737 * @summary Tests ArrayType.toString with type annotations present * @modules jdk.compiler/com.sun.tools.javac.code - * @build ArrayTypeToString + * @library /tools/javac/lib + * @build ArrayTypeToString JavacTestingAbstractProcessor * @compile/ref=ArrayTypeToString.out -XDaccessInternalAPI -XDrawDiagnostics -processor ArrayTypeToString -proc:only ArrayTypeToString.java */ @@ -54,8 +55,7 @@ import com.sun.tools.javac.code.Symbol.VarSymbol; } @SupportedAnnotationTypes("Foo") -@SupportedSourceVersion(SourceVersion.RELEASE_9) -public class ArrayTypeToString extends AbstractProcessor { +public class ArrayTypeToString extends JavacTestingAbstractProcessor { @Foo(0) String @Foo(1)[] @Foo(2)[] @Foo(3)[] field; public boolean process(Set tes, RoundEnvironment renv) { diff --git a/langtools/test/tools/javac/tree/TestPrettyDocComment.java b/langtools/test/tools/javac/tree/TestPrettyDocComment.java new file mode 100644 index 00000000000..52b9b0a9abc --- /dev/null +++ b/langtools/test/tools/javac/tree/TestPrettyDocComment.java @@ -0,0 +1,120 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8176470 + * @summary javac Pretty printer should include doc comment for modules + * @modules jdk.compiler + * @library /tools/lib + * @build toolbox.TestRunner + * @run main TestPrettyDocComment + */ + +import java.io.IOException; +import java.io.StringWriter; +import java.net.URI; +import java.util.List; + +import javax.tools.JavaFileObject; +import javax.tools.JavaCompiler; +import javax.tools.SimpleJavaFileObject; +import javax.tools.ToolProvider; + +import com.sun.source.tree.CompilationUnitTree; +import com.sun.source.util.JavacTask; + +import toolbox.TestRunner; + +public class TestPrettyDocComment extends TestRunner { + + public static void main(String... args) throws Exception { + TestPrettyDocComment t = new TestPrettyDocComment(); + t.runTests(); + } + + final JavaCompiler tool = ToolProvider.getSystemJavaCompiler(); + + TestPrettyDocComment() { + super(System.err); + } + + @Test + public void testModule() throws IOException { + test("module-info.java", "/** This is a module. */ module m { }"); + } + + @Test + public void testPackage() throws IOException { + test("package-info.java", "/** This is a package. */ package p;"); + } + + @Test + public void testClass() throws IOException { + test("C.java", "/** This is a class. */ class C { }"); + } + + @Test + public void testField() throws IOException { + test("C.java", "class C { /** This is a field. */ int f; }"); + } + + @Test + public void testMethod() throws IOException { + test("C.java", "class C { /** This is a method. */ void m() { } }"); + } + + void test(String name, String source) throws IOException { + JavaFileObject fo = new JavaSource(name, source); + StringWriter log = new StringWriter(); + JavacTask t = (JavacTask) tool.getTask(log, null, null, null, null, List.of(fo)); + Iterable trees = t.parse(); + String out = log.toString(); + if (!out.isEmpty()) { + System.err.println(log); + } + String pretty = trees.iterator().next().toString(); + System.err.println("Pretty: <<<"); + System.err.println(pretty); + System.err.println(">>>"); + + String commentText = source.replaceAll(".*\\Q/**\\E (.*) \\Q*/\\E.*", "$1"); + if (!pretty.contains(commentText)) { + error("expected text not found: " + commentText); + } + } + + static class JavaSource extends SimpleJavaFileObject { + final String source; + + public JavaSource(String name, String source) { + super(URI.create("myfo:/" + name), JavaFileObject.Kind.SOURCE); + this.source = source; + } + + @Override + public CharSequence getCharContent(boolean ignoreEncodingErrors) { + return source; + } + } +} diff --git a/langtools/test/tools/javac/tree/TreePosTest.java b/langtools/test/tools/javac/tree/TreePosTest.java index 835531fd669..2fbed6417e4 100644 --- a/langtools/test/tools/javac/tree/TreePosTest.java +++ b/langtools/test/tools/javac/tree/TreePosTest.java @@ -281,7 +281,7 @@ public class TreePosTest { JavacTool tool = JavacTool.create(); r.errors = 0; Iterable files = fm.getJavaFileObjects(file); - JavacTask task = tool.getTask(pw, fm, r, Collections.emptyList(), null, files); + JavacTask task = tool.getTask(pw, fm, r, List.of("-proc:none"), null, files); Iterable trees = task.parse(); pw.flush(); if (r.errors > 0) diff --git a/langtools/test/tools/javac/treeannotests/TestProcessor.java b/langtools/test/tools/javac/treeannotests/TestProcessor.java index 99fd780e463..2bc6d7eb5d3 100644 --- a/langtools/test/tools/javac/treeannotests/TestProcessor.java +++ b/langtools/test/tools/javac/treeannotests/TestProcessor.java @@ -21,8 +21,6 @@ * questions. */ -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.io.*; import java.util.*; import javax.annotation.processing.*; diff --git a/langtools/test/tools/javac/versions/Versions.java b/langtools/test/tools/javac/versions/Versions.java index f90f44935c9..9d6440038a0 100644 --- a/langtools/test/tools/javac/versions/Versions.java +++ b/langtools/test/tools/javac/versions/Versions.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 4981566 5028634 5094412 6304984 7025786 7025789 8001112 8028545 8000961 8030610 + * @bug 4981566 5028634 5094412 6304984 7025786 7025789 8001112 8028545 8000961 8030610 8028546 * @summary Check interpretation of -target and -source options * @modules java.compiler * jdk.compiler @@ -69,6 +69,7 @@ public class Versions { check("53.0", "-source 1.7"); check("53.0", "-source 1.8"); check("53.0", "-source 1.9"); + check("53.0", "-source 1.10"); check_source_target("50.0", "6", "6"); check_source_target("51.0", "6", "7"); @@ -80,6 +81,7 @@ public class Versions { check_source_target("53.0", "7", "9"); check_source_target("53.0", "8", "9"); check_source_target("53.0", "9", "9"); + check_source_target("53.0", "10", "10"); checksrc16("-source 1.6"); checksrc16("-source 6"); @@ -93,19 +95,26 @@ public class Versions { checksrc18("-source 8"); checksrc18("-source 1.8", "-target 1.8"); checksrc18("-source 8", "-target 8"); - checksrc19(); checksrc19("-source 1.9"); checksrc19("-source 9"); checksrc19("-source 1.9", "-target 1.9"); checksrc19("-source 9", "-target 9"); - checksrc19("-target 1.9"); - checksrc19("-target 9"); + + checksrc110(); + checksrc110("-source 1.10"); + checksrc110("-source 10"); + checksrc110("-source 1.10", "-target 1.10"); + checksrc110("-source 10", "-target 10"); + checksrc110("-target 1.10"); + checksrc110("-target 10"); fail("-source 7", "-target 1.6", "Base.java"); fail("-source 8", "-target 1.6", "Base.java"); fail("-source 8", "-target 1.7", "Base.java"); fail("-source 9", "-target 1.7", "Base.java"); fail("-source 9", "-target 1.8", "Base.java"); + fail("-source 10", "-target 1.7", "Base.java"); + fail("-source 10", "-target 1.8", "Base.java"); fail("-source 1.5", "-target 1.5", "Base.java"); fail("-source 1.4", "-target 1.4", "Base.java"); @@ -202,6 +211,11 @@ public class Versions { checksrc18(args); } + protected void checksrc110(String... args) { + printargs("checksrc110", args); + checksrc19(args); + } + protected void pass(String... args) { printargs("pass", args); diff --git a/langtools/test/tools/javac/warnings/VerifyLintDescriptions.java b/langtools/test/tools/javac/warnings/VerifyLintDescriptions.java index 04aaa8418b4..54472a3b682 100644 --- a/langtools/test/tools/javac/warnings/VerifyLintDescriptions.java +++ b/langtools/test/tools/javac/warnings/VerifyLintDescriptions.java @@ -30,8 +30,6 @@ * jdk.compiler/com.sun.tools.javac.util */ -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.ArrayList; import java.util.List; import java.util.Locale; @@ -42,7 +40,7 @@ import com.sun.tools.javac.util.Log.PrefixKind; public class VerifyLintDescriptions { public static void main(String... args) { - Layer boot = Layer.boot(); + ModuleLayer boot = ModuleLayer.boot(); Module jdk_compiler = boot.findModule("jdk.compiler").get(); ResourceBundle b = ResourceBundle.getBundle("com.sun.tools.javac.resources.javac", Locale.US, diff --git a/langtools/test/tools/javac/warnings/suppress/VerifySuppressWarnings.java b/langtools/test/tools/javac/warnings/suppress/VerifySuppressWarnings.java index 9d198b746cc..6171270a67e 100644 --- a/langtools/test/tools/javac/warnings/suppress/VerifySuppressWarnings.java +++ b/langtools/test/tools/javac/warnings/suppress/VerifySuppressWarnings.java @@ -66,7 +66,7 @@ public class VerifySuppressWarnings { if (args.length != 1) throw new IllegalStateException("Must provide class name!"); String testContent = null; List sourcePath = new ArrayList<>(); - for (String sourcePaths : System.getProperty("test.src.path").split(":")) { + for (String sourcePaths : System.getProperty("test.src.path").split(File.pathSeparator)) { sourcePath.add(new File(sourcePaths)); } JavacFileManager fm = JavacTool.create().getStandardFileManager(null, null, null); diff --git a/langtools/test/tools/javadoc/CheckResourceKeys.java b/langtools/test/tools/javadoc/CheckResourceKeys.java index 70a705e729c..aafd039487a 100644 --- a/langtools/test/tools/javadoc/CheckResourceKeys.java +++ b/langtools/test/tools/javadoc/CheckResourceKeys.java @@ -32,8 +32,6 @@ */ import java.io.*; -import java.lang.reflect.Layer; -import java.lang.reflect.Module; import java.util.*; import javax.tools.*; import com.sun.tools.classfile.*; @@ -229,7 +227,7 @@ public class CheckResourceKeys { * Get the set of keys from the javadoc resource bundles. */ Set getResourceKeys() { - Module jdk_javadoc = Layer.boot().findModule("jdk.javadoc").get(); + Module jdk_javadoc = ModuleLayer.boot().findModule("jdk.javadoc").get(); String[] names = { "com.sun.tools.doclets.formats.html.resources.standard", "com.sun.tools.doclets.internal.toolkit.resources.doclets", diff --git a/langtools/test/tools/javadoc/CompletionError.java b/langtools/test/tools/javadoc/CompletionError.java index f708cb1dec7..b0aab224a58 100644 --- a/langtools/test/tools/javadoc/CompletionError.java +++ b/langtools/test/tools/javadoc/CompletionError.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -27,8 +27,10 @@ * @summary Check that CompletionFailures for missing classes are not incorrectly passed to * the javadoc API clients. * @library /tools/lib - * @modules jdk.javadoc com.sun.tools.javac.api + * @modules jdk.compiler/com.sun.tools.javac.api + * jdk.compiler/com.sun.tools.javac.main * jdk.jdeps/com.sun.tools.javap + * @build toolbox.JavacTask toolbox.ToolBox * @run main CompletionError */ @@ -37,6 +39,9 @@ import java.io.File; import com.sun.javadoc.*; import com.sun.tools.javadoc.Main; +import toolbox.JavacTask; +import toolbox.ToolBox; + public class CompletionError extends Doclet { private static final String template = @@ -49,6 +54,9 @@ public class CompletionError extends Doclet " public String toString() { return null; }" + "}"; + private static final String testSrc = System.getProperty("test.src"); + private static final String testClassPath = System.getProperty("test.class.path"); + public static void main(String[] args) throws Exception { String[] templateParts = template.split("#"); int sources = templateParts.length / 2; @@ -75,8 +83,8 @@ public class CompletionError extends Doclet tb.deleteFiles("CompletionErrorMissing.class", "CompletionErrorIntfMissing.class", "CompletionErrorExcMissing.class"); // run javadoc: if (Main.execute("javadoc", "CompletionError", CompletionError.class.getClassLoader(), - "-classpath", ".", - System.getProperty("test.src", ".") + File.separatorChar + "CompletionError.java") != 0) + "-classpath", "." + File.pathSeparator + testClassPath, + new File(testSrc, "CompletionError.java").getPath()) != 0) throw new Error(); } } diff --git a/langtools/test/tools/javadoc/sampleapi/SampleApiTest.java b/langtools/test/tools/javadoc/sampleapi/SampleApiTest.java index 149d347cd55..c344895a612 100644 --- a/langtools/test/tools/javadoc/sampleapi/SampleApiTest.java +++ b/langtools/test/tools/javadoc/sampleapi/SampleApiTest.java @@ -30,6 +30,8 @@ * jdk.compiler/com.sun.tools.javac.parser * jdk.compiler/com.sun.tools.javac.tree * jdk.compiler/com.sun.tools.javac.util + * jdk.javadoc/jdk.javadoc.internal.tool + * @build sampleapi.SampleApiDefaultRunner * @run main SampleApiTest */ diff --git a/langtools/test/tools/javadoc/sampleapi/res/fx.xml b/langtools/test/tools/javadoc/sampleapi/res/fx.xml index 3416730b492..840dcbb34a8 100644 --- a/langtools/test/tools/javadoc/sampleapi/res/fx.xml +++ b/langtools/test/tools/javadoc/sampleapi/res/fx.xml @@ -1,6 +1,6 @@ - - - - public - - + + + + public - int|boolean - - - public|protected|private - int|String - void - - - public|protected|private - int|int|String - - - + + + public + int|boolean + + + public|protected|private + int|String + void + + + public|protected|private + int|int|String + + + - + + + diff --git a/langtools/test/tools/javadoc/sampleapi/res/simple.xml b/langtools/test/tools/javadoc/sampleapi/res/simple.xml index b5a49159b9d..ab5a4c16b2b 100644 --- a/langtools/test/tools/javadoc/sampleapi/res/simple.xml +++ b/langtools/test/tools/javadoc/sampleapi/res/simple.xml @@ -1,6 +1,6 @@ - + + + - - public - none|abstract - - - none|public - none|static - none|final - boolean|int|String - - - protected|private - String - - - public - none|int|int,boolean|int,String - - - public - String - NullPointerException - SampleException0 - - - public - void - int - - - public - int|boolean|String - - - public - void|int - none|int|Object,int - NullPointerException - ArithmeticException - - - - - - public - - - - public - int|boolean - - - public - none|int|int,boolean|int,String - - - public - int|boolean - - - - - - java.io.Serializable - public - - - - private|none|public - boolean|int|String - - - - - - java.io.Serializable - java.io.ObjectStreamField - public - - - String,Long,Boolean - - public - String|long|boolean - - - - - - java.io.Serializable - java.io.ObjectOutputStream - java.io.ObjectOutput - java.io.IOException - java.io.ObjectStreamException - public - - - - private - ObjectOutputStream - void - IOException - - - public - ObjectOutput - void - IOException - - - protected - none - Object - ObjectStreamException - - - public - Object - void - IOException - - - - - - java.io.Serializable - java.io.ObjectInputStream - java.io.ObjectInput - java.io.IOException - java.io.ObjectStreamException - public - - - - private - ObjectInputStream - void - IOException - ClassNotFoundException - - - public - ObjectInput - void - IOException - - - protected - none - Object - ObjectStreamException - - - public - Object - void - IOException - - - - - - public - - + public + none|abstract - + + none|public + none|static + none|final + boolean|int|String + + + protected|private + String + + public - int + none|int|int,boolean|int,String + + + public + String + NullPointerException + SampleException0 + + + public + void + int + + + public + int|boolean|String + + + public + void|int + none|int|Object,int + NullPointerException + ArithmeticException + + + + + + public + + + + public + int|boolean + + + public + none|int|int,boolean|int,String + + + public + int|boolean + + + + + + java.io.Serializable + public + + + + private|none|public + boolean|int|String - + + + java.io.Serializable + java.io.ObjectStreamField public - static - - - public - static + - - public - void + String,Long,Boolean + + public + String|long|boolean + + + + + + java.io.Serializable + java.io.ObjectOutputStream + java.io.ObjectOutput + java.io.IOException + java.io.ObjectStreamException + public + + + + private + ObjectOutputStream + void + IOException + + + public + ObjectOutput + void + IOException + + + protected + none + Object + ObjectStreamException + + + public + Object + void + IOException + + + + + + java.io.Serializable + java.io.ObjectInputStream + java.io.ObjectInput + java.io.IOException + java.io.ObjectStreamException + public + + + + private + ObjectInputStream + void + IOException + ClassNotFoundException + + + public + ObjectInput + void + IOException + + + protected + none + Object + ObjectStreamException + + + public + Object + void + IOException + + + + + + public + + + public + + + public + int + + + + + public + static + + + public + static + + + public + void + + + + + + + + + public + + + + private + boolean|int|String + + + public + String + + + public + int|String + + + + + + public + + + + private + boolean|int|String + + + public + String + + + public + int|String + + + + + + public|none + + + public + void|int|Object - - - - - public - - - - private - boolean|int|String - - + public - String - - - public - int|String - - - + + + + public + int|boolean + + + public + int|boolean + + + - - public - - - - private - boolean|int|String - - + + java.util.List public - String - - - public - int|String - - - + + + public + void + T + + + public + T + int + + + public + List<T> + + + - - public|none - - + + java.util.Set + java.util.List + java.util.Map public - void|int|Object - - - + + + public + void + K,V + + + public + void + Map<K,V> + + + public + V + K + + + public + Set<V>|List<V> + + + public + Set<K>|List<K> + + + - - public - - - + + java.util.Set + java.util.List + java.util.Map public - int|boolean - - - public - int|boolean - - - + + + public + Set<M>|List<M> + Map<N,O> + + + public + Set<N>|List<N> + Map<M,O> + + + public + Set<O>|List<O> + Map<M,N> + + + - - java.util.List - public - - + + java.util.Set + java.util.List + java.util.Map + java.util.function.Supplier public - void - T - - - public - T - int - - - public - List<T> - - - + + + public + static + Set<? extends E>|List<? extends E> + + + public|private + static + Map<V,K> + + + public + static + void + E + + + public|private + static + X + Supplier<? extends X> + X + + + - - java.util.Set - java.util.List - java.util.Map - public - - + public - void - K,V - - + + + + + + public - void - Map<K,V> - - - public - V - K - - - public - Set<V>|List<V> - - - public - Set<K>|List<K> - - - + + + + + private + int|String + + + public + void|String + + + - - java.util.Set - java.util.List - java.util.Map - public - - - public - Set<M>|List<M> - Map<N,O> - - - public - Set<N>|List<N> - Map<M,O> - - - public - Set<O>|List<O> - Map<M,N> - - - + + Documented + - - java.util.Set - java.util.List - java.util.Map - java.util.function.Supplier - public - - - public - static - Set<? extends E>|List<? extends E> - - - public|private - static - Map<V,K> - - - public - static - void - E - - - public|private - static - X - Supplier<? extends X> - X - - - + + Retention + + - - public - - - - - - - public - - - - - private - int|String - - - public - void|String - - - + + Retention + + - - Documented - + + Retention + + - - Retention - - + + Target + + - - Retention - - + + Target + + - - Retention - - + + Target + + - - Target - - - - - Target - - - - - Target - - - - - java.lang.annotation.Documented - @documented - public - - - public - boolean|String - - - - - - java.lang.annotation.Retention - java.lang.annotation.RetentionPolicy - @reten-source|@reten-class|@reten-runtime - public - - - public - int - - - - - - java.lang.annotation.Retention - java.lang.annotation.RetentionPolicy - java.lang.annotation.Target - java.lang.annotation.ElementType - public - - @reten-source|@reten-class|@reten-runtime - @target-method|@target-field|@target-type + java.lang.annotation.Documented + @documented public - static public - String + boolean|String - - - - Deprecated - - - - SafeVarargs - - - - SuppressWarnings - - - - - public - - - @deprecated + + java.lang.annotation.Retention + java.lang.annotation.RetentionPolicy + @reten-source|@reten-class|@reten-runtime public - void - - - @safevarargs + + + public + int + + + + + + java.lang.annotation.Retention + java.lang.annotation.RetentionPolicy + java.lang.annotation.Target + java.lang.annotation.ElementType public - void|int - String... - - - @suppresswarnings + + + @reten-source|@reten-class|@reten-runtime + @target-method|@target-field|@target-type + public + static + + + public + String + + + + + + + + Deprecated + + + + SafeVarargs + + + + SuppressWarnings + + + + public - void - int|Object - - - - + + + @deprecated + public + void + + + @safevarargs + public + void|int + String... + + + @suppresswarnings + public + void + int|Object + + + + + + diff --git a/langtools/test/tools/javadoc/sampleapi/res/sub.xml b/langtools/test/tools/javadoc/sampleapi/res/sub.xml index ff007c781ac..242ea7a9503 100644 --- a/langtools/test/tools/javadoc/sampleapi/res/sub.xml +++ b/langtools/test/tools/javadoc/sampleapi/res/sub.xml @@ -21,69 +21,72 @@ or visit www.oracle.com if you need additional information or have any questions. --> - + + + + + public + none|abstract + SInterface0 + + + public + int + + + public + int + SException0 + + + public + int + void + SException0 + + + - - public - none|abstract - SInterface0 - - + public - int - - - public - int - SException0 - - - public - int - void - SException0 - - - + + + + public + String + + + - - public - - - + public - String - - - + + + public + void + int + + + - - public - - + public - void - int - - - + + + + + - - public - - - - - - - - public - - + public - boolean - - - - - + + + public + boolean + + + + + + + diff --git a/langtools/test/tools/javadoc/sampleapi/res/tiny.xml b/langtools/test/tools/javadoc/sampleapi/res/tiny.xml index 9a0f49371a5..7c3eddc3671 100644 --- a/langtools/test/tools/javadoc/sampleapi/res/tiny.xml +++ b/langtools/test/tools/javadoc/sampleapi/res/tiny.xml @@ -1,6 +1,6 @@ - - - - public - none|abstract - - + + + + public - int - - - public - int - - - + none|abstract + + + public + int + + + public + int + + + - - public - - + public - void - int - - - + + + public + void + int + + + - - public - - - - - - - - - public - - + public - boolean - - - - - + + + + + + + + + public + + + public + boolean + + + + + + diff --git a/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestLoadExpected.csv b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestLoadExpected.csv index dd58eacd90c..5e80316ead0 100644 --- a/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestLoadExpected.csv +++ b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestLoadExpected.csv @@ -1,4 +1,4 @@ -#jdepr 1 +#jdepr1 METHOD,jdk/deprcases/members/ExampleAnnotation,name()Ljava/lang/String;,,false FIELD,jdk/deprcases/members/ExampleClass,field1,,false FIELD,jdk/deprcases/members/ExampleClass,field2,,false diff --git a/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestNotFound.java b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestNotFound.java new file mode 100644 index 00000000000..aaf9964c1fa --- /dev/null +++ b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestNotFound.java @@ -0,0 +1,111 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8168444 + * @summary Test of jdeprscan handling of primitives and primitive arrays. + * @modules jdk.jdeps/com.sun.tools.jdeprscan + * @run main jdk.jdeprscan.TestNotFound + */ + +package jdk.jdeprscan; + +import com.sun.tools.jdeprscan.Main; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.File; +import java.io.IOException; +import java.io.PrintStream; +import java.util.Scanner; + +public class TestNotFound { + + public static void main(String[] args) throws IOException { + final String SEP = File.separator; + final String TESTCLASSES = System.getProperty("test.classes"); + final String THISCLASS = + TESTCLASSES + SEP + "jdk" + SEP + "jdeprscan" + SEP + "TestNotFound.class"; + + ByteArrayOutputStream outBaos = new ByteArrayOutputStream(); + ByteArrayOutputStream errBaos = new ByteArrayOutputStream(); + boolean mainResult; + + // Causes 5 Methodrefs to be generated, thus 5 occurrences + // of the Target class not being found. But only one message + // should be emitted. + + Target.method1(); + Target.method2(); + Target.method3(); + Target.method4(); + Target.method5(); + + try (PrintStream out = new PrintStream(outBaos, false, "UTF-8"); + PrintStream err = new PrintStream(errBaos, false, "UTF-8")) { + // Call jdeprscan without the proper classpath, so Target isn't found. + // Result is checked below after output is dumped. + mainResult = Main.call(out, err, THISCLASS); + } + + byte[] outBytes = outBaos.toByteArray(); + byte[] errBytes = errBaos.toByteArray(); + ByteArrayInputStream outbais = new ByteArrayInputStream(outBytes); + ByteArrayInputStream errbais = new ByteArrayInputStream(errBytes); + + System.out.println("--- stdout ---"); + outbais.transferTo(System.out); + System.out.println("--- end stdout ---"); + + System.out.println("--- stderr ---"); + errbais.transferTo(System.out); + System.out.println("--- end stderr ---"); + + long errCount = new Scanner(new String(errBytes, "UTF-8")).findAll("error:").count(); + + System.out.println("mainResult = " + mainResult); + System.out.println("errCount = " + errCount); + + if (!mainResult) { + System.out.println("FAIL: mainResult should be true"); + } + + if (errCount != 1L) { + System.out.println("FAIL: errCount should equal 1"); + } + + if (!mainResult || errCount != 1L) { + throw new AssertionError("Test failed."); + } else { + System.out.println("Test passed."); + } + } + + static class Target { + static void method1() { } + static void method2() { } + static void method3() { } + static void method4() { } + static void method5() { } + } +} diff --git a/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestPrims.csv b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestPrims.csv new file mode 100644 index 00000000000..8eaf303fd73 --- /dev/null +++ b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestPrims.csv @@ -0,0 +1,18 @@ +#jdepr1 +CLASS,V,,,false +CLASS,Z,,,false +CLASS,B,,,false +CLASS,S,,,false +CLASS,C,,,false +CLASS,I,,,false +CLASS,J,,,false +CLASS,F,,,false +CLASS,D,,,false +CLASS,[Z,,,false +CLASS,[B,,,false +CLASS,[S,,,false +CLASS,[C,,,false +CLASS,[I,,,false +CLASS,[J,,,false +CLASS,[F,,,false +CLASS,[D,,,false diff --git a/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestPrims.java b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestPrims.java new file mode 100644 index 00000000000..f27abc0ec02 --- /dev/null +++ b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestPrims.java @@ -0,0 +1,145 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8168444 + * @summary Test of jdeprscan handling of primitives and primitive arrays. + * @modules jdk.jdeps/com.sun.tools.jdeprscan + * @build jdk.jdeprscan.TestPrims + * @run testng jdk.jdeprscan.TestPrims + */ + +package jdk.jdeprscan; + +import com.sun.tools.jdeprscan.Main; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.File; +import java.io.IOException; +import java.io.PrintStream; +import java.util.regex.Pattern; +import org.testng.annotations.Test; + +import static org.testng.Assert.assertFalse; +import static org.testng.Assert.assertTrue; + +public class TestPrims { + + @Test + public void test() throws IOException { + final String TESTSRC = System.getProperty("test.src"); + final String TESTCLASSPATH = System.getProperty("test.class.path"); + String CSV_FILE = TESTSRC + File.separator + "TestPrims.csv"; + + ByteArrayOutputStream outBaos = new ByteArrayOutputStream(); + ByteArrayOutputStream errBaos = new ByteArrayOutputStream(); + boolean mainResult; + + try (PrintStream out = new PrintStream(outBaos, false, "UTF-8"); + PrintStream err = new PrintStream(errBaos, false, "UTF-8")) { + mainResult = Main.call( + out, err, + "--class-path", TESTCLASSPATH, + "--Xload-csv", CSV_FILE, + "jdk.jdeprscan.TestPrims$Usage"); + // assertion is checked below after output is dumped + } + + byte[] outBytes = outBaos.toByteArray(); + byte[] errBytes = errBaos.toByteArray(); + ByteArrayInputStream outbais = new ByteArrayInputStream(outBytes); + ByteArrayInputStream errbais = new ByteArrayInputStream(errBytes); + + System.out.println("--- stdout ---"); + outbais.transferTo(System.out); + System.out.println("--- end stdout ---"); + + System.out.println("--- stderr ---"); + errbais.transferTo(System.out); + System.out.println("--- end stderr ---"); + + String outString = new String(outBytes, "UTF-8"); + String errString = new String(errBytes, "UTF-8"); + + // matches message "class uses deprecated class [I" + boolean outMatch = Pattern.compile("^class ").matcher(outString).find(); + + // matches message "error: cannot find class [I" + boolean errMatch = Pattern.compile("^error: ").matcher(errString).find(); + + if (!mainResult) { + System.out.println("FAIL: Main.call returned false"); + } + + if (outMatch) { + System.out.println("FAIL: stdout contains unexpected error message"); + } + + if (errMatch) { + System.out.println("FAIL: stderr contains unexpected error message"); + } + + assertTrue(mainResult && !outMatch && !errMatch); + } + + static class Usage { + void prims(boolean z, byte b, short s, char c, + int i, long j, float f, double d) { } + + void primsArrays(boolean[] z, byte[] b, short[] s, char[] c, + int[] i, long[] j, float[] f, double[] d) { } + + boolean zfield; + byte bfield; + short sfield; + char cfield; + int ifield; + long jfield; + float ffield; + double dfield; + + boolean[] azfield; + byte[] abfield; + short[] asfield; + char[] acfield; + int[] aifield; + long[] ajfield; + float[] affield; + double[] adfield; + + + Object[] clones() { + return new Object[] { + azfield.clone(), + abfield.clone(), + asfield.clone(), + acfield.clone(), + aifield.clone(), + ajfield.clone(), + affield.clone(), + adfield.clone() + }; + } + } +} diff --git a/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestRelease.java b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestRelease.java index d1c833e1684..c3c2d879431 100644 --- a/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestRelease.java +++ b/langtools/test/tools/jdeprscan/tests/jdk/jdeprscan/TestRelease.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -49,6 +49,7 @@ public class TestRelease { assertTrue(invoke("7")); assertTrue(invoke("8")); assertTrue(invoke("9")); + assertTrue(invoke("10")); } @Test diff --git a/langtools/test/tools/jdeps/MultiReleaseJar.java b/langtools/test/tools/jdeps/MultiReleaseJar.java index 0f4fd7cc405..c1ecb83d532 100644 --- a/langtools/test/tools/jdeps/MultiReleaseJar.java +++ b/langtools/test/tools/jdeps/MultiReleaseJar.java @@ -23,7 +23,7 @@ /* * @test - * @bug 8153654 + * @bug 8153654 8176333 * @summary Tests for jdeps tool with multi-release jar files * @modules jdk.jdeps/com.sun.tools.jdeps * @library mrjar mrjar/base mrjar/9 mrjar/10 mrjar/v9 mrjar/v10 @@ -67,7 +67,7 @@ public class MultiReleaseJar { checkResult(r, false, "Warning: Path does not exist: missing.jar"); r = run("jdeps -v Version.jar"); - checkResult(r, false, "the --multi-release option is not set"); + checkResult(r, false, "--multi-release option is not set"); r = run("jdeps --multi-release base -v Version.jar"); checkResult(r, true, @@ -105,7 +105,7 @@ public class MultiReleaseJar { checkResult(r, false, "Error: invalid argument for option: 9.1"); r = run("jdeps -v -R -cp Version.jar test/Main.class"); - checkResult(r, false, "the --multi-release option is not set"); + checkResult(r, false, "--multi-release option is not set"); r = run("jdeps -v -R -cp Version.jar -multi-release 9 test/Main.class"); checkResult(r, false, diff --git a/langtools/test/tools/jdeps/jdkinternals/RemovedJDKInternals.java b/langtools/test/tools/jdeps/jdkinternals/RemovedJDKInternals.java index 6611235d48f..b97c27dcd46 100644 --- a/langtools/test/tools/jdeps/jdkinternals/RemovedJDKInternals.java +++ b/langtools/test/tools/jdeps/jdkinternals/RemovedJDKInternals.java @@ -63,7 +63,7 @@ public class RemovedJDKInternals { Path sunMiscSrc = Paths.get(TEST_SRC, "patches", JDK_UNSUPPORTED); Path patchDir = PATCHES_DIR.resolve(JDK_UNSUPPORTED); assertTrue(CompilerUtils.compile(sunMiscSrc, patchDir, - "-Xmodule:" + JDK_UNSUPPORTED)); + "--patch-module", JDK_UNSUPPORTED + "=" + sunMiscSrc.toString())); // compile com.sun.image.codec.jpeg types Path codecSrc = Paths.get(TEST_SRC, "patches", "java.desktop"); diff --git a/langtools/test/tools/jdeps/modules/DotFileTest.java b/langtools/test/tools/jdeps/modules/DotFileTest.java new file mode 100644 index 00000000000..977268931ab --- /dev/null +++ b/langtools/test/tools/jdeps/modules/DotFileTest.java @@ -0,0 +1,130 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8173374 + * @summary Tests module dot graph + * @modules java.desktop + * java.sql + * jdk.jdeps/com.sun.tools.jdeps + * @run testng DotFileTest + */ + +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.Set; + +import java.util.regex.Matcher; +import java.util.regex.Pattern; +import java.util.spi.ToolProvider; +import java.util.stream.Collectors; + +import org.testng.annotations.DataProvider; +import org.testng.annotations.Test; + +import static org.testng.Assert.assertTrue; +import static org.testng.Assert.assertEquals; + +public class DotFileTest { + private static final ToolProvider JDEPS = ToolProvider.findFirst("jdeps") + .orElseThrow(() -> new RuntimeException("jdeps not found")); + + private static final Path DOTS_DIR = Paths.get("dots"); + private static final Path SPEC_DIR = Paths.get("spec"); + + @DataProvider(name = "modules") + public Object[][] modules() { + return new Object[][]{ + {"java.desktop", Set.of("java.datatransfer -> java.base", + "java.desktop -> java.datatransfer", + "java.desktop -> java.prefs", + "java.prefs -> java.xml", + "java.xml -> java.base" ) + }, + { "java.sql", Set.of("java.logging -> java.base", + "java.sql -> java.logging", + "java.sql -> java.xml", + "java.xml -> java.base" ) + } + }; + } + @DataProvider(name = "specVersion") + public Object[][] specVersion() { + return new Object[][]{ + {"java.desktop", Set.of("java.datatransfer -> java.base", + "java.desktop -> java.datatransfer", + "java.desktop -> java.xml", + "java.xml -> java.base") + }, + { "java.sql", Set.of("java.logging -> java.base", + "java.sql -> java.logging", + "java.sql -> java.xml", + "java.xml -> java.base" ) + } + }; + } + + @Test(dataProvider = "modules") + public void test(String name, Set edges) throws Exception { + String[] options = new String[] { + "-dotoutput", DOTS_DIR.toString(), + "-s", "-m", name + }; + assertTrue(JDEPS.run(System.out, System.out, options) == 0); + + Path path = DOTS_DIR.resolve(name + ".dot"); + assertTrue(Files.exists(path)); + Set lines = Files.readAllLines(path).stream() + .filter(l -> l.contains(" -> ")) + .map(this::split) + .collect(Collectors.toSet()); + assertEquals(lines, edges); + } + + @Test(dataProvider = "specVersion") + public void testAPIOnly(String name, Set edges) throws Exception { + String[] options = new String[]{ + "-dotoutput", SPEC_DIR.toString(), + "-s", "-apionly", + "-m", name + }; + assertTrue(JDEPS.run(System.out, System.out, options) == 0); + + Path path = SPEC_DIR.resolve(name + ".dot"); + assertTrue(Files.exists(path)); + Set lines = Files.readAllLines(path).stream() + .filter(l -> l.contains(" -> ")) + .map(this::split) + .collect(Collectors.toSet()); + assertEquals(lines, edges); + } + + static Pattern PATTERN = Pattern.compile(" *\"(\\S+)\" -> \"(\\S+)\" .*"); + String split(String line) { + Matcher pm = PATTERN.matcher(line); + assertTrue(pm.find()); + return String.format("%s -> %s", pm.group(1), pm.group(2)); + } +} diff --git a/langtools/test/tools/lib/toolbox/JavacTask.java b/langtools/test/tools/lib/toolbox/JavacTask.java index 1b0a6d92780..05327bdae66 100644 --- a/langtools/test/tools/lib/toolbox/JavacTask.java +++ b/langtools/test/tools/lib/toolbox/JavacTask.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -287,10 +287,13 @@ public class JavacTask extends AbstractTask { rc = runAPI(direct.pw); break; case CMDLINE: + if (fileManager != null) { + throw new IllegalStateException("file manager set in CMDLINE mode"); + } rc = runCommand(direct.pw); break; default: - throw new IllegalStateException(); + throw new IllegalStateException("unknown mode " + mode); } } catch (IOException e) { toolBox.out.println("Exception occurred: " + e); diff --git a/langtools/test/tools/lib/toolbox/ModuleBuilder.java b/langtools/test/tools/lib/toolbox/ModuleBuilder.java index f1ece37fce3..05bf58eafab 100644 --- a/langtools/test/tools/lib/toolbox/ModuleBuilder.java +++ b/langtools/test/tools/lib/toolbox/ModuleBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -45,6 +45,7 @@ public class ModuleBuilder { private String comment = ""; private List requires = new ArrayList<>(); private List exports = new ArrayList<>(); + private List opens = new ArrayList<>(); private List uses = new ArrayList<>(); private List provides = new ArrayList<>(); private List content = new ArrayList<>(); @@ -133,33 +134,6 @@ public class ModuleBuilder { return addDirective(exports, "exports " + pkg + ";"); } - /** - * Adds an unqualified "exports dynamic" directive to the declaration. - * @param pkg the name of the package to be exported - * @return this builder - */ - public ModuleBuilder exportsDynamic(String pkg) { - return addDirective(exports, "exports dynamic " + pkg + ";"); - } - - /** - * Adds an unqualified "exports private" directive to the declaration. - * @param pkg the name of the package to be exported - * @return this builder - */ - public ModuleBuilder exportsPrivate(String pkg) { - return addDirective(exports, "exports private " + pkg + ";"); - } - - /** - * Adds an unqualified "exports dynamic private" directive to the declaration. - * @param pkg the name of the package to be exported - * @return this builder - */ - public ModuleBuilder exportsDynamicPrivate(String pkg) { - return addDirective(exports, "exports dynamic private " + pkg + ";"); - } - /** * Adds a qualified "exports" directive to the declaration. * @param pkg the name of the package to be exported @@ -171,33 +145,22 @@ public class ModuleBuilder { } /** - * Adds a qualified "exports dynamic" directive to the declaration. - * @param pkg the name of the package to be exported - * @param module the name of the module to which it is to be exported + * Adds an unqualified "opens" directive to the declaration. + * @param pkg the name of the package to be opened * @return this builder */ - public ModuleBuilder exportsDynamicTo(String pkg, String module) { - return addDirective(exports, "exports dynamic " + pkg + " to " + module + ";"); + public ModuleBuilder opens(String pkg) { + return addDirective(opens, "opens " + pkg + ";"); } /** - * Adds a qualified "exports private" directive to the declaration. - * @param pkg the name of the package to be exported - * @param module the name of the module to which it is to be exported + * Adds a qualified "opens" directive to the declaration. + * @param pkg the name of the package to be opened + * @param module the name of the module to which it is to be opened * @return this builder */ - public ModuleBuilder exportsPrivateTo(String pkg, String module) { - return addDirective(exports, "exports private " + pkg + " to " + module + ";"); - } - - /** - * Adds a qualified "exports dynamic private" directive to the declaration. - * @param pkg the name of the package to be exported - * @param module the name of the module to which it is to be exported - * @return this builder - */ - public ModuleBuilder exportsDynamicPrivateTo(String pkg, String module) { - return addDirective(exports, "exports dynamic private " + pkg + " to " + module + ";"); + public ModuleBuilder opensTo(String pkg, String module) { + return addDirective(opens, "opens " + pkg + " to " + module + ";"); } /** @@ -247,11 +210,14 @@ public class ModuleBuilder { List sources = new ArrayList<>(); StringBuilder sb = new StringBuilder(); if (!comment.isEmpty()) { - sb.append("/**\n").append(comment.replace("\n", " *")).append(" */\n"); + sb.append("/**\n * ") + .append(comment.replace("\n", "\n * ")) + .append("\n */\n"); } sb.append("module ").append(name).append(" {\n"); requires.forEach(r -> sb.append(" " + r + "\n")); exports.forEach(e -> sb.append(" " + e + "\n")); + opens.forEach(o -> sb.append(" " + o + "\n")); uses.forEach(u -> sb.append(" " + u + "\n")); provides.forEach(p -> sb.append(" " + p + "\n")); sb.append("}"); diff --git a/make/Bundles.gmk b/make/Bundles.gmk index 1791818abc7..81321550e23 100644 --- a/make/Bundles.gmk +++ b/make/Bundles.gmk @@ -183,29 +183,17 @@ ifneq ($(filter product-bundles, $(MAKECMDGOALS)), ) $(JDK_SYMBOLS_EXCLUDE_PATTERN) \ $(JDK_EXTRA_EXCLUDES) \ $(SYMBOLS_EXCLUDE_PATTERN) \ - $(JDK_IMAGE_HOMEDIR)/demo/% $(JDK_IMAGE_HOMEDIR)/sample/% \ + $(JDK_IMAGE_HOMEDIR)/demo/% \ , \ $(ALL_JDK_FILES) \ ) - DEMOS_BUNDLE_FILES := \ - $(filter-out \ - $(JDK_SYMBOLS_EXCLUDE_PATTERN) \ - $(SYMBOLS_EXCLUDE_PATTERN) \ - , \ - $(filter \ - $(JDK_IMAGE_HOMEDIR)/demo/% $(JDK_IMAGE_HOMEDIR)/sample/% \ - $(JDK_IMAGE_HOMEDIR)/release \ - , \ - $(ALL_JDK_FILES) \ - ) \ - ) JDK_SYMBOLS_BUNDLE_FILES := \ $(filter \ $(JDK_SYMBOLS_EXCLUDE_PATTERN) \ $(SYMBOLS_EXCLUDE_PATTERN) \ , \ $(filter-out \ - $(JDK_IMAGE_HOMEDIR)/demo/% $(JDK_IMAGE_HOMEDIR)/sample/% \ + $(JDK_IMAGE_HOMEDIR)/demo/% \ , \ $(ALL_JDK_FILES) \ ) \ @@ -271,14 +259,6 @@ ifneq ($(filter product-bundles, $(MAKECMDGOALS)), ) PRODUCT_TARGETS += $(BUILD_JRE_SYMBOLS_BUNDLE) - $(eval $(call SetupBundleFile, BUILD_DEMOS_BUNDLE, \ - BUNDLE_NAME := $(DEMOS_BUNDLE_NAME), \ - FILES := $(DEMOS_BUNDLE_FILES), \ - BASE_DIRS := $(JDK_IMAGE_DIR), \ - SUBDIR := $(JDK_BUNDLE_SUBDIR), \ - )) - - PRODUCT_TARGETS += $(BUILD_DEMOS_BUNDLE) endif ################################################################################ diff --git a/make/CompileJavaModules.gmk b/make/CompileJavaModules.gmk index 0b54c856da4..090434a1607 100644 --- a/make/CompileJavaModules.gmk +++ b/make/CompileJavaModules.gmk @@ -85,7 +85,7 @@ endif ################################################################################ -java.compiler_ADD_JAVAC_FLAGS := -Xdoclint:all/protected,-reference '-Xdoclint/package:java.*,javax.*' +java.compiler_ADD_JAVAC_FLAGS := -Xdoclint:all/protected '-Xdoclint/package:java.*,javax.*' ################################################################################ @@ -95,7 +95,8 @@ java.datatransfer_COPY := flavormap.properties ################################################################################ java.desktop_ADD_JAVAC_FLAGS := -Xdoclint:all/protected,-reference \ - '-Xdoclint/package:java.*,javax.*' -Xlint:exports + '-Xdoclint/package:java.*,javax.*' -Xlint:exports \ + --doclint-format html4 java.desktop_COPY := .gif .png .wav .txt .xml .css .pf java.desktop_CLEAN := iio-plugin.properties cursors.properties @@ -247,7 +248,7 @@ java.management_ADD_JAVAC_FLAGS := -Xdoclint:all/protected,-reference '-Xdoclint ################################################################################ -java.management.rmi_ADD_JAVAC_FLAGS := -Xdoclint:all/protected,-reference '-Xdoclint/package:javax.*' +java.management.rmi_ADD_JAVAC_FLAGS := -Xdoclint:all/protected '-Xdoclint/package:javax.*' ################################################################################ @@ -461,14 +462,30 @@ jdk.internal.jvmstat_COPY := aliasmap # -parameters provides method's parameters information in class file, # JVMCI compilers make use of that information for various sanity checks. # Don't use Indy strings concatenation to have good JVMCI startup performance. +# The exports are needed since JVMCI is dynamically exported (see +# jdk.vm.ci.services.internal.ReflectionAccessJDK::openJVMCITo). -jdk.vm.ci_ADD_JAVAC_FLAGS := -parameters -Xlint:-exports -XDstringConcat=inline +jdk.internal.vm.ci_ADD_JAVAC_FLAGS := -parameters -Xlint:-exports -XDstringConcat=inline ################################################################################ -jdk.vm.compiler_ADD_JAVAC_FLAGS := -parameters -XDstringConcat=inline +jdk.internal.vm.compiler_ADD_JAVAC_FLAGS := -parameters -XDstringConcat=inline \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.aarch64=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.amd64=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code.site=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code.stack=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.common=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.aarch64=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.amd64=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.sparc=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.meta=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.runtime=jdk.internal.vm.compiler \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.sparc=jdk.internal.vm.compiler \ + # -jdk.vm.compiler_EXCLUDES += \ +jdk.internal.vm.compiler_EXCLUDES += \ org.graalvm.compiler.core.match.processor \ org.graalvm.compiler.nodeinfo.processor \ org.graalvm.compiler.options.processor \ @@ -502,7 +519,27 @@ jdk.vm.compiler_EXCLUDES += \ ################################################################################ -jdk.aot_ADD_JAVAC_FLAGS := -parameters -XDstringConcat=inline +# -parameters provides method's parameters information in class file, +# JVMCI compilers make use of that information for various sanity checks. +# Don't use Indy strings concatenation to have good JAOTC startup performance. +# The exports are needed since JVMCI is dynamically exported (see +# jdk.vm.ci.services.internal.ReflectionAccessJDK::openJVMCITo). + +jdk.aot_ADD_JAVAC_FLAGS := -parameters -XDstringConcat=inline \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.aarch64=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.amd64=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code.site=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.code.stack=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.common=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.aarch64=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.amd64=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.hotspot.sparc=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.meta=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.runtime=jdk.internal.vm.compiler,jdk.aot \ + --add-exports jdk.internal.vm.ci/jdk.vm.ci.sparc=jdk.internal.vm.compiler,jdk.aot \ + # ################################################################################ @@ -557,16 +594,16 @@ MODULESOURCEPATH := $(call GetModuleSrcPath) # Add imported modules to the modulepath MODULEPATH := $(call PathList, $(IMPORT_MODULES_CLASSES)) -ifeq ($(MODULE), jdk.vm.ci) - ## WORKAROUND jdk.vm.ci source structure issue +ifeq ($(MODULE), jdk.internal.vm.ci) + ## WORKAROUND jdk.internal.vm.ci source structure issue JVMCI_MODULESOURCEPATH := $(MODULESOURCEPATH) \ $(subst /$(MODULE)/,/*/, $(filter-out %processor/src, \ - $(wildcard $(HOTSPOT_TOPDIR)/src/jdk.vm.ci/share/classes/*/src))) + $(wildcard $(HOTSPOT_TOPDIR)/src/$(MODULE)/share/classes/*/src))) MODULESOURCEPATH := $(call PathList, $(JVMCI_MODULESOURCEPATH)) endif -ifeq ($(MODULE), jdk.vm.compiler) - ## WORKAROUND jdk.vm.compiler source structure issue +ifeq ($(MODULE), jdk.internal.vm.compiler) + ## WORKAROUND jdk.internal.vm.compiler source structure issue VM_COMPILER_MODULESOURCEPATH := $(MODULESOURCEPATH) \ $(subst /$(MODULE)/,/*/, $(filter-out %processor/src %test/src %jtt/src %bench/src %microbenchmarks/src, \ $(wildcard $(HOTSPOT_TOPDIR)/src/$(MODULE)/share/classes/*/src))) diff --git a/make/CreateJmods.gmk b/make/CreateJmods.gmk index fd502f116d9..7d4287e02d8 100644 --- a/make/CreateJmods.gmk +++ b/make/CreateJmods.gmk @@ -135,11 +135,9 @@ $(JMODS_DIR)/$(MODULE).jmod: $(DEPS) $(RM) $@ $(JMODS_TEMPDIR)/$(notdir $@) $(JMOD) create \ --module-version $(VERSION_SHORT) \ - --os-name $(REQUIRED_OS_NAME) \ - --os-arch $(OPENJDK_TARGET_CPU_LEGACY) \ - --os-version $(REQUIRED_OS_VERSION) \ + --target-platform '$(OPENJDK_MODULE_TARGET_PLATFORM)' \ --module-path $(JMODS_DIR) \ - --exclude '**{_the.*,*.diz,*.debuginfo,*.dSYM/**,*.dSYM,*.pdb,*.map}' \ + --exclude '**{_the.*,_*.marker,*.diz,*.debuginfo,*.dSYM/**,*.dSYM,*.pdb,*.map}' \ $(JMOD_FLAGS) $(JMODS_TEMPDIR)/$(notdir $@) $(MV) $(JMODS_TEMPDIR)/$(notdir $@) $@ diff --git a/make/Docs.gmk b/make/Docs.gmk new file mode 100644 index 00000000000..d75398272d0 --- /dev/null +++ b/make/Docs.gmk @@ -0,0 +1,564 @@ +# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Oracle designates this +# particular file as subject to the "Classpath" exception as provided +# by Oracle in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. +# + +default: all + +include $(SPEC) +include MakeBase.gmk +include Modules.gmk +include ProcessMarkdown.gmk +include ZipArchive.gmk +include $(JDK_TOPDIR)/make/Tools.gmk +include $(JDK_TOPDIR)/make/ModuleTools.gmk + +# This is needed to properly setup DOCS_MODULES. +$(eval $(call ReadImportMetaData)) + +################################################################################ +# Hook to include the corresponding custom file, if present. +$(eval $(call IncludeCustomExtension, , Docs.gmk)) + +################################################################################ +# This file generates all documentation for OpenJDK. +# +# We will generate API documentation for two different selections of the source +# code: "Java SE", which contains just the modules covered by the top-level +# module java.se.ee, and "JDK", which covers all of Java SE and also all +# other available modules that should be documented, including imported modules, +# if any. +# +# We will also generate separate, free-standing specifications from either +# markdown or existing html files. +# + +################################################################################ +# Javadoc settings + +# On top of the sources that was used to compile the JDK, we need some +# extra java.rmi sources that are used just for javadoc. +MODULES_SOURCE_PATH := $(call PathList, $(call GetModuleSrcPath) \ + $(SUPPORT_OUTPUTDIR)/rmic/* $(JDK_TOPDIR)/src/*/share/doc/stub) + +# URLs +JAVADOC_BASE_URL := http://www.oracle.com/pls/topic/lookup?ctx=javase9&id=homepage +BUG_SUBMIT_URL := http://bugreport.java.com/bugreport/ +COPYRIGHT_URL := {@docroot}/../legal/cpyr.html +LICENSE_URL := http://www.oracle.com/technetwork/java/javase/terms/license/java9speclicense.html +REDISTRIBUTION_URL := http://www.oracle.com/technetwork/java/redist-137594.html + +# In order to get a specific ordering it's necessary to specify the total +# ordering of tags as the tags are otherwise ordered in order of definition. +JAVADOC_TAGS := \ + -tag beaninfo:X \ + -tag revised:X \ + -tag since.unbundled:X \ + -tag spec:X \ + -tag specdefault:X \ + -tag Note:X \ + -tag ToDo:X \ + -tag 'apiNote:a:API Note:' \ + -tag 'implSpec:a:Implementation Requirements:' \ + -tag 'implNote:a:Implementation Note:' \ + -tag param \ + -tag return \ + -tag throws \ + -taglet build.tools.taglet.ModuleGraph \ + -tag since \ + -tag version \ + -tag serialData \ + -tag factory \ + -tag see \ + -tag 'jvms:a:See The Java™ Virtual Machine Specification:' \ + -tag 'jls:a:See The Java™ Language Specification:' \ + -taglet build.tools.taglet.ExtLink \ + -taglet build.tools.taglet.Incubating \ + -tagletpath $(BUILDTOOLS_OUTPUTDIR)/jdk_tools_classes \ + $(CUSTOM_JAVADOC_TAGS) \ + # + +# Which doclint checks to ignore +JAVADOC_DISABLED_DOCLINT := accessibility html missing syntax reference + +# The initial set of options for javadoc +JAVADOC_OPTIONS := -XDignore.symbol.file=true -use -keywords -notimestamp \ + -serialwarn -encoding ISO-8859-1 -breakiterator -splitIndex --system none \ + -html5 -javafx --expand-requires transitive + +# Should we add DRAFT stamps to the generated javadoc? +ifeq ($(VERSION_IS_GA), true) + IS_DRAFT := false +else + IS_DRAFT := true +endif + +################################################################################ +# General text snippets + +FULL_COMPANY_NAME := Oracle and/or its affiliates +COMPANY_ADDRESS := 500 Oracle Parkway
    Redwood Shores, CA 94065 USA + +JAVA_PLATFORM := Java™ Platform + +ifeq ($(IS_DRAFT), true) + DRAFT_MARKER_STR :=
    DRAFT $(VERSION_STRING) + ifeq ($(VERSION_BUILD), 0) + DRAFT_MARKER_TITLE := [ad-hoc build] + else + DRAFT_MARKER_TITLE := [build $(VERSION_BUILD)] + endif + DRAFT_TEXT := Please note that the specifications and other information \ + contained herein are not final and are subject to change. The \ + information is being made available to you solely for purpose of \ + evaluation. +endif + +JAVADOC_BOTTOM := \ + \ + Submit a bug or feature
    \ + For further API reference and developer documentation, see \ + Java SE \ + Documentation. That documentation contains more detailed, \ + developer-targeted descriptions, with conceptual overviews, definitions \ + of terms, workarounds, and working code examples.
    \ + Java is a trademark or registered trademark of $(FULL_COMPANY_NAME) in \ + the US and other countries.
    \ + Copyright \ + © 1993, $(COPYRIGHT_YEAR), $(FULL_COMPANY_NAME). \ + $(COMPANY_ADDRESS). All rights reserved. \ + Use is subject to license terms. Also see the \ + documentation redistribution policy. \ + $(DRAFT_MARKER_STR)
    + +JAVADOC_TOP := \ +
    $(DRAFT_TEXT)
    + +################################################################################ +# JDK javadoc titles/text snippets + +JDK_SHORT_NAME := JDK™ $(VERSION_SPECIFICATION) +JDK_LONG_NAME := Standard Edition Development Kit (JDK™) $(VERSION_SPECIFICATION) + +################################################################################ +# Java SE javadoc titles/text snippets + +JAVASE_SHORT_NAME := SE $(VERSION_SPECIFICATION) +JAVASE_LONG_NAME := Standard Edition $(VERSION_SPECIFICATION) + +################################################################################ +# Index page text titles/snippets + +JDK_INDEX_TITLE := $(JAVA_PLATFORM), $(JDK_LONG_NAME) Specification $(DRAFT_MARKER_TITLE) + +################################################################################ +# Functions + +# Helper function for creating a png file from a dot file generated by the +# GenGraphs tool. +# param 1: SetupJavadocGeneration namespace ($1) +# param 2: module name +# +define setup_gengraph_dot_to_png + $1_$2_DOT_SRC := $$($1_GENGRAPHS_DIR)/$2.dot + $1_$2_PNG_TARGET := $$($1_TARGET_DIR)/$2-graph.png + + # For each module needing a graph, create a png file from the dot file + # generated by the GenGraphs tool and store it in the target dir. + $$($1_$2_PNG_TARGET): $$($1_GENGRAPHS_MARKER) + $$(call MakeDir, $$(@D)) + $$(call ExecuteWithLog, $$($1_$2_DOT_SRC), \ + $$(DOT) -Tpng -o $$($1_$2_PNG_TARGET) $$($1_$2_DOT_SRC)) + + $1_MODULEGRAPH_TARGETS += $$($1_$2_PNG_TARGET) +endef + +# Helper function to create the overview.html file to use with the -overview +# javadoc option. +# Returns the filename as $1_OVERVIEW. +# +# param 1: SetupJavadocGeneration namespace ($1) +define create_overview_file + $1_OVERVIEW_TEXT := \ + \ + \ +

    This document is the API specification for $$($1_FULL_NAME).

    \ + # + ifneq ($$($1_GROUPS),) + $1_OVERVIEW_TEXT += \ +

    For an overview of the full specification, grouped by usage, see the $$(JAVA_PLATFORM), $$($1_LONG_NAME) Specification.

    \ +
    \ + # + $1_OVERVIEW_TEXT += $$(foreach g, $$($1_GROUPS), \ +
    $$($$g_GROUP_NAME)
    \ +
    $$($$g_GROUP_DESCRIPTION) \ + ) + $1_OVERVIEW_TEXT += \ +
    \ + # + endif + ifeq ($$(IS_DRAFT), true) + $1_OVERVIEW_TEXT += \ +

    $$(DRAFT_TEXT)

    \ + # + endif + $1_OVERVIEW_TEXT += \ + \ + # + + $1_OVERVIEW := $$(SUPPORT_OUTPUTDIR)/docs/$1-overview.html + + $1_OVERVIEW_VARDEPS_FILE := $$(call DependOnVariable, $1_OVERVIEW_TEXT, \ + $$($1_OVERVIEW).vardeps) + + $$($1_OVERVIEW): $$($1_OVERVIEW_VARDEPS_FILE) + $$(call LogInfo, Creating overview.html for $1) + $$(call MakeDir, $$(@D)) + $$(PRINTF) > $$@ '$$($1_OVERVIEW_TEXT)' +endef + +################################################################################ +# Setup make rules to create an API documentation collection, using javadoc and +# other tools if needed. +# +# Parameter 1 is the name of the rule. This name is used as variable prefix. +# Targets generated are returned as $1_JAVADOC_TARGETS and +# $1_MODULEGRAPH_TARGETS. Note that the index.html file will work as a "touch +# file" for all the magnitude of files that are generated by javadoc. +# +# Remaining parameters are named arguments. These include: +# MODULES - Modules to generate javadoc for +# GROUPS - Name of the groups to divide the modules into, if any +# SHORT_NAME - The short name of this documentation collection +# LONG_NAME - The long name of this documentation collection +# TARGET_DIR - Where to store the output +# +SetupApiDocsGeneration = $(NamedParamsMacroTemplate) +define SetupApiDocsGenerationBody + + # Figure out all modules, both specified and transitive indirect exports, that + # will be processed by javadoc. + $1_INDIRECT_EXPORTS := $$(call FindTransitiveIndirectDepsForModules, $$($1_MODULES)) + $1_ALL_MODULES := $$(sort $$($1_MODULES) $$($1_INDIRECT_EXPORTS)) + + ifeq ($$(ENABLE_FULL_DOCS), true) + # Tell the ModuleGraph taglet to generate html links to soon-to-be-created + # png files with module graphs. + $1_JAVA_ARGS += -DenableModuleGraph=true + endif + + # Always include tags and basic options + $1_OPTIONS := $$(JAVADOC_TAGS) $$(JAVADOC_OPTIONS) + + $1_OPTIONS += --module-source-path $$(MODULES_SOURCE_PATH) + $1_OPTIONS += --module $$(call CommaList, $$($1_MODULES)) + + # Create a string like "-Xdoclint:all,-syntax,-html,..." + $1_OPTIONS += -Xdoclint:all,$$(call CommaList, $$(addprefix -, \ + $$(JAVADOC_DISABLED_DOCLINT))) + + $1_FULL_NAME := $$(JAVA_PLATFORM), $$($1_LONG_NAME) \ + $$(DRAFT_MARKER_TITLE) + $1_DOC_TITLE := $$($1_FULL_NAME)
    API Specification + $1_WINDOW_TITLE := $$(subst ™,,$$(JAVA_PLATFORM) $$($1_SHORT_NAME)) \ + $$(DRAFT_MARKER_TITLE) + $1_HEADER_TITLE := $$(JAVA_PLATFORM)
    $$($1_SHORT_NAME)
    \ + $$(DRAFT_MARKER_STR) + + $1_OPTIONS += -doctitle '$$($1_DOC_TITLE)' + $1_OPTIONS += -windowtitle '$$($1_WINDOW_TITLE)' + $1_OPTIONS += -header '$$($1_HEADER_TITLE)' + $1_OPTIONS += -bottom '$$(JAVADOC_BOTTOM)' + ifeq ($$(IS_DRAFT), true) + $1_OPTIONS += -top '$$(JAVADOC_TOP)' + endif + + # Do not store debug level options in VARDEPS. + ifneq ($$(LOG_LEVEL), trace) + $1_LOG_OPTION += -quiet + else + $1_LOG_OPTION += -verbose + endif + + # Generate the overview.html file. This will return the filename in + # $1_OVERVIEW. + $$(eval $$(call create_overview_file,$1)) + $1_OPTIONS += -overview $$($1_OVERVIEW) + + $$(foreach g, $$($1_GROUPS), \ + $$(eval $1_OPTIONS += -group "$$($$g_GROUP_NAME)" "$$($$g_GROUP_MODULES)") \ + ) + + $1_VARDEPS := $$($1_JAVA_ARGS) $$($1_OPTIONS) $$(MODULES_SOURCE_PATH) \ + $$($1_ALL_MODULES) + $1_VARDEPS_FILE := $$(call DependOnVariable, $1_VARDEPS, \ + $$(SUPPORT_OUTPUTDIR)/docs/$1.vardeps) + + # Get a list of all files in all the source dirs for all included modules + $1_SOURCE_DEPS := $$(call CacheFind, $$(wildcard $$(foreach module, \ + $$($1_ALL_MODULES), $$(call FindModuleSrcDirs, $$(module))))) + + # Javadoc creates a lot of files but use index.html as a marker + $$($1_TARGET_DIR)/index.html: $$(BUILD_TOOLS_JDK) $$($1_VARDEPS_FILE) \ + $$($1_SOURCE_DEPS) $$($1_OVERVIEW) + $$(call LogWarn, Generating $1 javadoc for \ + $$(words $$($1_ALL_MODULES)) modules) + $$(call LogInfo, Javadoc modules: $$($1_ALL_MODULES)) + $$(call MakeDir, $$($1_TARGET_DIR)) + $$(call ExecuteWithLog, $$(SUPPORT_OUTPUTDIR)/docs/$1, \ + $$(JAVA) -Djava.awt.headless=true $$($1_JAVA_ARGS) \ + $$(NEW_JAVADOC) -d $$($1_TARGET_DIR) \ + $$(JAVADOC_TAGS) $$($1_OPTIONS) $$($1_LOG_OPTION)) + + $1_JAVADOC_TARGETS := $$($1_TARGET_DIR)/index.html + + ifeq ($$(ENABLE_FULL_DOCS), true) + # We have asked ModuleGraph to generate links to png files. Now we must + # produce the png files. + + # Locate which modules has the @moduleGraph tag in their module-info.java + $1_MODULES_NEEDING_GRAPH := $$(strip $$(foreach m, $$($1_ALL_MODULES), \ + $$(if $$(shell $$(GREP) -e @moduleGraph \ + $$(wildcard $$(addsuffix /module-info.java, \ + $$(call FindModuleSrcDirs, $$m)))), \ + $$m) \ + )) + + # First we run the GenGraph tool. It will query the module structure of the + # running JVM and output .dot files for all existing modules. + GENGRAPHS_PROPS := \ + $$(JDK_TOPDIR)/make/src/classes/build/tools/jigsaw/javadoc-graphs.properties + + $1_GENGRAPHS_DIR := $$(SUPPORT_OUTPUTDIR)/docs/$1-gengraphs + $1_GENGRAPHS_MARKER := $$($1_GENGRAPHS_DIR)/_gengraphs_run.marker + + $$($1_GENGRAPHS_MARKER): $$(BUILD_JIGSAW_TOOLS) $$(GENGRAPHS_PROPS) + $$(call LogInfo, Running gengraphs for $1 documentation) + $$(call MakeDir, $$($1_GENGRAPHS_DIR)) + $$(call ExecuteWithLog, $$($1_GENGRAPHS_DIR)/gengraphs, \ + $$(TOOL_GENGRAPHS) --spec --output $$($1_GENGRAPHS_DIR) \ + --dot-attributes $$(GENGRAPHS_PROPS) && \ + $$(TOUCH) $$($1_GENGRAPHS_MARKER)) + + # For each module needing a graph, create a png file from the dot file + # generated by the GenGraphs tool and store it in the target dir. + # They will depend on $1_GENGRAPHS_MARKER, and will be added to $1. + $$(foreach m, $$($1_MODULES_NEEDING_GRAPH), \ + $$(eval $$(call setup_gengraph_dot_to_png,$1,$$m)) \ + ) + endif +endef + +################################################################################ +# Setup generation of the JDK API documentation (javadoc + modulegraph) + +# Define the groups of the JDK API documentation +JavaSE_GROUP_NAME := Java SE +JavaSE_GROUP_MODULES := $(call ColonList, $(sort java.se.ee \ + $(call FindTransitiveIndirectDepsForModules, java.se.ee))) +JavaSE_GROUP_DESCRIPTION := \ + The Java Platform, Standard Edition ("Java SE") APIs define the core Java \ + platform for general-purpose computing. These APIs are in modules with \ + names starting with the string "java.". \ + # +JDK_GROUPS += JavaSE + +JDK_GROUP_NAME := JDK +JDK_GROUP_MODULES := jdk.* +JDK_GROUP_DESCRIPTION := \ + The Java Development Kit ("JDK") APIs define an implementation of the Java \ + SE Platform which may include platform-specific details. These APIs are in \ + modules with names starting with the string "jdk.". \ + # +JDK_GROUPS += JDK + +# If we are importing JavaFX, we need a JavaFX group. In an ideal world, this +# would have been abstracted away to a more proper generic handling of imported +# modules. +ifneq ($(findstring javafx., $(IMPORTED_MODULES)), ) + JavaFX_GROUP_NAME := JavaFX + JavaFX_GROUP_MODULES := javafx.* + JavaFX_GROUP_DESCRIPTION := \ + The JavaFX APIs define a set of user interface (UI) controls, graphics, \ + media, and web packages for developing rich client applications. These \ + APIs are in modules with names starting with the string "javafx.". \ + # + JDK_GROUPS += JavaFX +endif + +# All modules to have docs generated by docs-jdk-api target +JDK_MODULES := $(sort $(DOCS_MODULES)) + +$(eval $(call SetupApiDocsGeneration, JDK_API, \ + MODULES := $(JDK_MODULES), \ + GROUPS := $(JDK_GROUPS), \ + SHORT_NAME := $(JDK_SHORT_NAME), \ + LONG_NAME := $(JDK_LONG_NAME), \ + TARGET_DIR := $(DOCS_OUTPUTDIR)/api, \ +)) + +# Targets generated are returned in JDK_API_JAVADOC_TARGETS and +# JDK_API_MODULEGRAPH_TARGETS. + +################################################################################ +# Setup generation of the Java SE API documentation (javadoc + modulegraph) + +# The Java SE module scope is just java.se.ee and it's transitive indirect +# exports. +JAVASE_MODULES := java.se.ee + +$(eval $(call SetupApiDocsGeneration, JAVASE_API, \ + MODULES := $(JAVASE_MODULES), \ + SHORT_NAME := $(JAVASE_SHORT_NAME), \ + LONG_NAME := $(JAVASE_LONG_NAME), \ + TARGET_DIR := $(IMAGES_OUTPUTDIR)/javase-docs/api, \ +)) + +# Targets generated are returned in JAVASE_API_JAVADOC_TARGETS and +# JAVASE_API_MODULEGRAPH_TARGETS. + +################################################################################ + +JDK_INDEX_HTML := $(DOCS_OUTPUTDIR)/index.html +JDK_INDEX_TOOLS_DIR := $(TOOLS_CLASSES_DIR)/build/tools/docs + +$(JDK_INDEX_HTML): $(BUILD_JIGSAW_TOOLS) \ + $(JDK_INDEX_TOOLS_DIR)/docs-bundle-page.html \ + $(JDK_INDEX_TOOLS_DIR)/docs-module-groups.properties + $(call LogInfo, Generating docs bundle index page) + $(MKDIR) -p $(@D) + $(TOOL_GEN_DOCS_BUNDLE_PAGE) --title '$(JDK_INDEX_TITLE)' \ + --output $@ + +JDK_INDEX_TARGETS := $(JDK_INDEX_HTML) + +# Copy the global resources +GLOBAL_SPECS_RESOURCES_DIR := $(JDK_TOPDIR)/make/data/docs-resources/ +$(eval $(call SetupCopyFiles, COPY_GLOBAL_RESOURCES, \ + SRC := $(GLOBAL_SPECS_RESOURCES_DIR), \ + FILES := $(call CacheFind, $(GLOBAL_SPECS_RESOURCES_DIR)), \ + DEST := $(DOCS_OUTPUTDIR), \ +)) +JDK_INDEX_TARGETS += $(COPY_GLOBAL_RESOURCES) + +################################################################################ +# Copy JDK specs files + +# For all html documentation in $module/share/specs directories, copy it +# unmodified + +ALL_MODULES := $(call FindAllModules) +COPY_SPEC_FILTER := %.html %.gif %.jpg %.mib %.css + +$(foreach m, $(ALL_MODULES), \ + $(eval SPECS_$m := $(call FindModuleSpecsDirs, $m)) \ + $(foreach d, $(SPECS_$m), \ + $(if $(filter $(COPY_SPEC_FILTER), $(call CacheFind, $d)), \ + $(eval $(call SetupCopyFiles, COPY_$m, \ + SRC := $d, \ + FILES := $(filter $(COPY_SPEC_FILTER), $(call CacheFind, $d)), \ + DEST := $(DOCS_OUTPUTDIR)/specs/, \ + )) \ + $(eval JDK_SPECS_TARGETS += $(COPY_$m)) \ + ) \ + ) \ +) + +ifeq ($(ENABLE_FULL_DOCS), true) + # For all markdown files in $module/share/specs directories, convert them to + # html. + + GLOBAL_SPECS_DEFAULT_CSS_FILE := $(DOCS_OUTPUTDIR)/resources/jdk-default.css + + $(foreach m, $(ALL_MODULES), \ + $(eval SPECS_$m := $(call FindModuleSpecsDirs, $m)) \ + $(foreach d, $(SPECS_$m), \ + $(if $(filter %.md, $(call CacheFind, $d)), \ + $(eval $(call SetupProcessMarkdown, CONVERT_MARKDOWN_$m_$(patsubst $(TOPDIR)/%,%,$d), \ + SRC := $d, \ + FILES := $(filter %.md, $(call CacheFind, $d)), \ + DEST := $(DOCS_OUTPUTDIR)/specs/, \ + CSS := $(GLOBAL_SPECS_DEFAULT_CSS_FILE), \ + )) \ + ) \ + $(eval JDK_SPECS_TARGETS += $(CONVERT_MARKDOWN_$m_$(patsubst $(TOPDIR)/%,%,$d))) \ + ) \ + ) +endif + +# Special treatment for generated documentation + +JDWP_PROTOCOL := $(SUPPORT_OUTPUTDIR)/gensrc/jdk.jdi/jdwp-protocol.html +$(eval $(call SetupCopyFiles, COPY_JDWP_PROTOCOL, \ + FILES := $(JDWP_PROTOCOL), \ + DEST := $(DOCS_OUTPUTDIR)/specs/jdwp, \ +)) +JDK_SPECS_TARGETS += $(COPY_JDWP_PROTOCOL) + +# Get jvmti.html from the main jvm variant (all variants' jvmti.html are identical). +JVMTI_HTML := $(HOTSPOT_OUTPUTDIR)/variant-$(JVM_VARIANT_MAIN)/gensrc/jvmtifiles/jvmti.html +$(eval $(call SetupCopyFiles, COPY_JVMTI_HTML, \ + FILES := $(JVMTI_HTML), \ + DEST := $(DOCS_OUTPUTDIR)/specs, \ +)) +JDK_SPECS_TARGETS += $(COPY_JVMTI_HTML) + +################################################################################ +# Optional target which bundles all generated javadocs into a zip archive. + +JAVADOC_ZIP_NAME := jdk-$(VERSION_STRING)-docs.zip +JAVADOC_ZIP_FILE := $(OUTPUT_ROOT)/bundles/$(JAVADOC_ZIP_NAME) + +$(eval $(call SetupZipArchive, BUILD_JAVADOC_ZIP, \ + SRC := $(DOCS_OUTPUTDIR), \ + ZIP := $(JAVADOC_ZIP_FILE), \ + EXTRA_DEPS := $(JDK_API_JAVADOC_TARGETS) $(JDK_API_MODULEGRAPH_TARGETS) \ + $(JDK_SPECS_TARGETS), \ +)) + +ZIP_TARGETS += $(BUILD_JAVADOC_ZIP) + +################################################################################ + +docs-jdk-api-javadoc: $(JDK_API_JAVADOC_TARGETS) $(JDK_API_CUSTOM_TARGETS) + +docs-jdk-api-modulegraph: $(JDK_API_MODULEGRAPH_TARGETS) + +docs-javase-api-javadoc: $(JAVASE_API_JAVADOC_TARGETS) $(JAVASE_API_CUSTOM_TARGETS) + +docs-javase-api-modulegraph: $(JAVASE_API_MODULEGRAPH_TARGETS) + +docs-jdk-specs: $(JDK_SPECS_TARGETS) + +docs-jdk-index: $(JDK_INDEX_TARGETS) + +docs-zip: $(ZIP_TARGETS) + +all: docs-jdk-api-javadoc docs-jdk-api-modulegraph docs-javase-api-javadoc \ + docs-javase-api-modulegraph docs-jdk-specs docs-jdk-index docs-zip + +.PHONY: default all docs-jdk-api-javadoc docs-jdk-api-modulegraph \ + docs-javase-api-javadoc docs-javase-api-modulegraph docs-jdk-specs \ + docs-jdk-index docs-zip diff --git a/make/GenerateLinkOptData.gmk b/make/GenerateLinkOptData.gmk index 43e388ddab4..60c80ea47ca 100644 --- a/make/GenerateLinkOptData.gmk +++ b/make/GenerateLinkOptData.gmk @@ -49,7 +49,7 @@ TARGETS += $(CLASSLIST_JAR) LINK_OPT_DIR := $(SUPPORT_OUTPUTDIR)/link_opt CLASSLIST_FILE := $(LINK_OPT_DIR)/classlist -JLI_TRACE_FILE := $(LINK_OPT_DIR)/jli_trace.out +JLI_TRACE_FILE := $(LINK_OPT_DIR)/default_jli_trace.txt # If an external buildjdk has been supplied, we don't build a separate interim # image, so just use the external build jdk instead. @@ -69,7 +69,7 @@ $(CLASSLIST_FILE): $(INTERIM_IMAGE_DIR)/bin/java$(EXE_SUFFIX) $(CLASSLIST_JAR) # The jli trace is created by the same recipe as classlist. By declaring these # dependencies, make will correctly rebuild both jli trace and classlist -# incrementally using the single recpie above. +# incrementally using the single recipe above. $(CLASSLIST_FILE): $(JLI_TRACE_FILE) $(JLI_TRACE_FILE): $(INTERIM_IMAGE_DIR)/bin/java$(EXE_SUFFIX) $(CLASSLIST_JAR) @@ -83,6 +83,19 @@ $(eval $(call SetupCopyFiles, COPY_CLASSLIST, \ TARGETS += $(COPY_CLASSLIST) +# Copy the default_jli_trace.txt file into jdk.jlink +$(eval $(call SetupCopyFiles, COPY_JLI_TRACE, \ + FILES := $(JLI_TRACE_FILE), \ + DEST := $(JDK_OUTPUTDIR)/modules/jdk.jlink/jdk/tools/jlink/internal/plugins, \ +)) + +# Because of the single recipe for jli trace and classlist above, the +# COPY_JLI_TRACE rule needs to explicitly add the classlist file as a +# prerequisite. +$(COPY_JLI_TRACE): $(CLASSLIST_FILE) + +TARGETS += $(COPY_JLI_TRACE) + ################################################################################ all: $(TARGETS) diff --git a/make/Help.gmk b/make/Help.gmk index bd10fa2ccb7..4514eb08b8d 100644 --- a/make/Help.gmk +++ b/make/Help.gmk @@ -1,5 +1,5 @@ # -# Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -47,13 +47,17 @@ help: $(info $(_) # dependencies for the target. This is faster but may) $(info $(_) # result in incorrect build results!) $(info $(_) make docs # Create all docs) - $(info $(_) make docs-javadoc # Create just javadocs, depends on less than full docs) + $(info $(_) make docs-jdk-api # Create just JDK javadocs) $(info $(_) make profiles # Create complete jre compact profile images) $(info $(_) make bootcycle-images # Build images twice, second time with newly built JDK) $(info $(_) make install # Install the generated images locally) $(info $(_) make reconfigure # Rerun configure with the same arguments as last time) $(info $(_) make help # Give some help on using make) $(info $(_) make test # Run tests, default is all tests (see TEST below)) + $(info $(_) make run-test- # Run test, e.g. run-test-tier1) + $(info $(_) make run-test TEST= # Run test(s) given by TEST specification) + $(info $(_) make exploded-run-test TEST= # Run test(s) on the exploded image instead of) + $(info $(_) # the full jdk image) $(info ) $(info Targets for cleaning) $(info $(_) make clean # Remove all files generated by make, but not those) @@ -95,6 +99,8 @@ help: $(info $(_) # method is 'auto', 'ignore' or 'fail' (default)) $(info $(_) make test TEST= # Only run the given test or tests, e.g.) $(info $(_) # make test TEST="jdk_lang jdk_net") + $(info $(_) JTREG="OPT1=x;OPT2=y" # Control the JTREG test harness for run-test) + $(info $(_) GTEST="OPT1=x;OPT2=y" # Control the GTEST test harness for run-test) $(info ) $(if $(all_confs), $(info Available configurations in $(build_dir):) $(foreach var,$(all_confs),$(info * $(var))),\ $(info No configurations were found in $(build_dir).) $(info Run 'bash configure' to create a configuration.)) diff --git a/make/Images.gmk b/make/Images.gmk index 09740cb53d9..c8567bd0ee2 100644 --- a/make/Images.gmk +++ b/make/Images.gmk @@ -105,7 +105,7 @@ JLINK_ORDER_RESOURCES := **module-info.class JLINK_JLI_CLASSES := ifeq ($(ENABLE_GENERATE_CLASSLIST), true) JLINK_ORDER_RESOURCES += @$(SUPPORT_OUTPUTDIR)/link_opt/classlist - JLINK_JLI_CLASSES := --generate-jli-classes=@$(SUPPORT_OUTPUTDIR)/link_opt/jli_trace.out + JLINK_JLI_CLASSES := --generate-jli-classes=@$(SUPPORT_OUTPUTDIR)/link_opt/default_jli_trace.txt endif JLINK_ORDER_RESOURCES += \ /java.base/java/** \ @@ -309,34 +309,6 @@ ifneq ($(OPENJDK_TARGET_OS), windows) JDK_TARGETS += $(JDK_MAN_PAGE_LIST) endif # Windows -################################################################################ -# doc files - -JRE_DOC_LOCATION ?= $(JDK_TOPDIR) -JDK_DOC_LOCATION ?= $(JDK_TOPDIR) - -JRE_DOC_TARGETS := $(addprefix $(JRE_IMAGE_DIR)/, $(JRE_DOC_FILES)) -JDK_DOC_TARGETS := $(addprefix $(JDK_IMAGE_DIR)/, $(JDK_DOC_FILES)) - -# Processing license files from source area to image area -# These are modified to have the platform specific EOL chars. -define process-doc-file - $(call LogInfo, Processing $(patsubst $(OUTPUT_ROOT)/%,%,$@)) - $(MKDIR) -p $(@D) - $(RM) $@ - LC_ALL=C $(SED) 's/$$//g' $< > $@ - $(CHMOD) 444 $@ -endef - -$(JRE_IMAGE_DIR)/%: $(JRE_DOC_LOCATION)/% - $(process-doc-file) - -$(JDK_IMAGE_DIR)/%: $(JDK_DOC_LOCATION)/% - $(process-doc-file) - -JRE_TARGETS += $(JRE_DOC_TARGETS) -JDK_TARGETS += $(JDK_DOC_TARGETS) - ################################################################################ # src.zip @@ -375,17 +347,6 @@ ifneq ($(filter jdk, $(MAKECMDGOALS)), ) JDK_TARGETS += $(JDK_COPY_DEMOS) endif -################################################################################ -# /sample dir - -$(eval $(call SetupCopyFiles, COPY_SAMPLES, \ - SRC := $(SUPPORT_OUTPUTDIR)/sample/image, \ - DEST := $(JDK_IMAGE_DIR)/sample, \ - FILES := $(if $(wildcard $(SUPPORT_OUTPUTDIR)/sample/image), \ - $(call CacheFind,$(SUPPORT_OUTPUTDIR)/sample/image)))) - -JDK_TARGETS += $(COPY_SAMPLES) - ################################################################################ # Code coverage data files diff --git a/make/Init.gmk b/make/Init.gmk index 15d25b4136d..79779e1f119 100644 --- a/make/Init.gmk +++ b/make/Init.gmk @@ -1,5 +1,5 @@ # -# Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -51,7 +51,7 @@ ifeq ($(HAS_SPEC),) # Targets provided by Init.gmk. ALL_INIT_TARGETS := print-modules print-targets print-configuration \ - reconfigure pre-compare-build post-compare-build + print-tests reconfigure pre-compare-build post-compare-build # CALLED_TARGETS is the list of targets that the user provided, # or "default" if unspecified. @@ -66,7 +66,7 @@ ifeq ($(HAS_SPEC),) ifeq ($(CALLED_SPEC_TARGETS), ) ONLY_GLOBAL_TARGETS := true endif - ifneq ($(findstring qp, $(MAKEFLAGS)),) + ifeq ($(findstring p, $(MAKEFLAGS))$(findstring q, $(MAKEFLAGS)), pq) ONLY_GLOBAL_TARGETS := true endif @@ -117,7 +117,7 @@ ifeq ($(HAS_SPEC),) # Check that CONF_CHECK is valid. $(eval $(call ParseConfCheckOption)) - # Check that the LOG given is valid, and set LOG_LEVEL, LOG_NOFILE and MAKE_LOG_FLAGS. + # Check that the LOG given is valid, and set LOG_LEVEL, LOG_NOFILE, MAKE_LOG_VARS and MAKE_LOG_FLAGS. $(eval $(call ParseLogLevel)) # After this SPECS contain 1..N spec files (otherwise ParseConfAndSpec fails). @@ -171,7 +171,7 @@ ifeq ($(HAS_SPEC),) MAKE_INIT_WITH_SPEC_ARGUMENTS := ACTUAL_TOPDIR=$(topdir) \ USER_MAKE_VARS="$(USER_MAKE_VARS)" MAKE_LOG_FLAGS=$(MAKE_LOG_FLAGS) \ - LOG_LEVEL=$(LOG_LEVEL) LOG_NOFILE=$(LOG_NOFILE) LOG_CMDLINES=$(LOG_CMDLINES) \ + $(MAKE_LOG_VARS) \ INIT_TARGETS="$(INIT_TARGETS)" \ SEQUENTIAL_TARGETS="$(SEQUENTIAL_TARGETS)" \ PARALLEL_TARGETS="$(PARALLEL_TARGETS)" @@ -251,6 +251,11 @@ else # HAS_SPEC=true $(MAKE) $(MAKE_ARGS) -j 1 -f make/Main.gmk $(USER_MAKE_VARS) \ NO_RECIPES=true print-targets ) + print-tests: + ( cd $(TOPDIR) && \ + $(MAKE) $(MAKE_ARGS) -j 1 -f make/Main.gmk $(USER_MAKE_VARS) \ + NO_RECIPES=true print-tests ) + print-configuration: $(ECHO) $(CONFIGURE_COMMAND_LINE) @@ -310,7 +315,11 @@ else # HAS_SPEC=true $(call StopGlobalTimer) $(call ReportBuildTimes) endif + if test -f $(MAKESUPPORT_OUTPUTDIR)/exit-with-error ; then \ + exit 1 ; \ + fi $(PRINTF) "Finished building $(TARGET_DESCRIPTION)\n" $(BUILD_LOG_PIPE) + $(call ReportProfileTimes) endif on-failure: @@ -319,6 +328,7 @@ else # HAS_SPEC=true $(call ReportBuildTimes) $(call PrintFailureReports) $(call PrintBuildLogFailures) + $(call ReportProfileTimes) $(PRINTF) "Hint: If caused by a warning, try configure --disable-warnings-as-errors.\n\n" ifneq ($(COMPARE_BUILD), ) $(call CleanupCompareBuild) diff --git a/make/InitSupport.gmk b/make/InitSupport.gmk index 92b34d72f02..ecb8f8b073b 100644 --- a/make/InitSupport.gmk +++ b/make/InitSupport.gmk @@ -33,6 +33,11 @@ ifndef _INITSUPPORT_GMK _INITSUPPORT_GMK := 1 ifeq ($(HAS_SPEC),) + + # Include the corresponding closed file, if present. + # Normal hook mechanism cannot be used since we have no SPEC. + -include $(topdir)/closed/make/InitSupport.gmk + ############################################################################## # Helper functions for the initial part of Init.gmk, before the spec file is # loaded. Most of these functions provide parsing and setting up make options @@ -40,8 +45,8 @@ ifeq ($(HAS_SPEC),) ############################################################################## # Make control variables, handled by Init.gmk - INIT_CONTROL_VARIABLES := LOG CONF CONF_NAME SPEC JOBS TEST_JOBS CONF_CHECK \ - COMPARE_BUILD + INIT_CONTROL_VARIABLES += LOG CONF CONF_NAME SPEC JOBS TEST_JOBS CONF_CHECK \ + COMPARE_BUILD JTREG GTEST # All known make control variables MAKE_CONTROL_VARIABLES := $(INIT_CONTROL_VARIABLES) TEST JDK_FILTER @@ -153,6 +158,18 @@ ifeq ($(HAS_SPEC),) # If the "cmdline" argument is given, act on it and strip it away $$(eval $$(call ParseLogOption, cmdlines, LOG_CMDLINES)) + # If the "profile-to-log" argument is given, write shell times in build log + $$(eval $$(call ParseLogOption, profile-to-log, LOG_PROFILE_TIMES_LOG)) + + # If the "profile" argument is given, write shell times in separate log file + # IMPORTANT: $(ParseLogOption profile-to-log) should go first. Otherwise + # parsing of 'LOG=debug,profile-to-log,nofile' ends up in the following error: + # Error: LOG contains unknown option or log level: debug-to-log. + $$(eval $$(call ParseLogOption, profile, LOG_PROFILE_TIMES_FILE)) + + # Treat LOG=profile-to-log as if it were LOG=profile,profile-to-log + LOG_PROFILE_TIMES_FILE := $$(firstword $$(LOG_PROFILE_TIMES_FILE) $$(LOG_PROFILE_TIMES_LOG)) + LOG_LEVEL := $$(LOG) ifeq ($$(LOG_LEVEL),) @@ -170,7 +187,7 @@ ifeq ($(HAS_SPEC),) MAKE_LOG_FLAGS := else $$(info Error: LOG contains unknown option or log level: $$(LOG).) - $$(info LOG can be [,[...]] where is nofile | cmdlines) + $$(info LOG can be [,[...]] where is nofile | cmdlines | profile | profile-to-log) $$(info and is warn | info | debug | trace) $$(error Cannot continue) endif @@ -304,7 +321,7 @@ ifeq ($(HAS_SPEC),) @( cd $$(topdir) && \ $$(MAKE) $$(MAKE_LOG_FLAGS) -r -R -f $$(topdir)/make/Main.gmk \ -I $$(topdir)/make/common SPEC=$(strip $2) NO_RECIPES=true \ - LOG_LEVEL=$$(LOG_LEVEL) \ + $$(MAKE_LOG_VARS) \ create-main-targets-include ) # Now include main-targets.gmk. This will define ALL_MAIN_TARGETS. @@ -329,7 +346,7 @@ else # $(HAS_SPEC)=true # Define basic logging setup BUILD_LOG := $(OUTPUT_ROOT)/build.log - BUILD_TRACE_LOG := $(OUTPUT_ROOT)/build-trace-time.log + BUILD_PROFILE_LOG := $(OUTPUT_ROOT)/build-profile.log BUILD_LOG_PIPE := > >($(TEE) -a $(BUILD_LOG)) 2> >($(TEE) -a $(BUILD_LOG) >&2) && wait @@ -489,15 +506,16 @@ else # $(HAS_SPEC)=true define RotateLogFiles $(RM) $(BUILD_LOG).old 2> /dev/null && \ $(MV) $(BUILD_LOG) $(BUILD_LOG).old 2> /dev/null || true - $(if $(findstring trace, $(LOG_LEVEL)), \ - $(RM) $(BUILD_TRACE_LOG).old 2> /dev/null && \ - $(MV) $(BUILD_TRACE_LOG) $(BUILD_TRACE_LOG).old 2> /dev/null || true \ + $(if $(findstring true, $(LOG_PROFILE_TIMES_FILE)), \ + $(RM) $(BUILD_PROFILE_LOG).old 2> /dev/null && \ + $(MV) $(BUILD_PROFILE_LOG) $(BUILD_PROFILE_LOG).old 2> /dev/null || true \ ) endef define PrepareFailureLogs $(RM) -r $(MAKESUPPORT_OUTPUTDIR)/failure-logs 2> /dev/null && \ $(MKDIR) -p $(MAKESUPPORT_OUTPUTDIR)/failure-logs + $(RM) $(MAKESUPPORT_OUTPUTDIR)/exit-with-error 2> /dev/null endef # Remove any javac server logs and port files. This @@ -552,6 +570,22 @@ else # $(HAS_SPEC)=true $(BUILD_LOG_PIPE) endef + define ReportProfileTimes + $(if $(findstring true, $(LOG_PROFILE_TIMES_LOG)), \ + [ ! -f $(BUILD_PROFILE_LOG) ] || \ + { $(ECHO) Begin $(notdir $(BUILD_PROFILE_LOG)) && \ + $(CAT) $(BUILD_PROFILE_LOG) && \ + $(ECHO) End $(notdir $(BUILD_PROFILE_LOG)); \ + } \ + $(BUILD_LOG_PIPE) + ) + endef + endif # HAS_SPEC +MAKE_LOG_VARS = $(foreach v, \ + LOG_LEVEL LOG_NOFILE LOG_CMDLINES LOG_PROFILE_TIMES_LOG LOG_PROFILE_TIMES_FILE, \ + $v=$($v) \ +) + endif # _INITSUPPORT_GMK diff --git a/make/Javadoc.gmk b/make/Javadoc.gmk deleted file mode 100644 index aa2a8b96d8b..00000000000 --- a/make/Javadoc.gmk +++ /dev/null @@ -1,754 +0,0 @@ -# Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# This code is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License version 2 only, as -# published by the Free Software Foundation. Oracle designates this -# particular file as subject to the "Classpath" exception as provided -# by Oracle in the LICENSE file that accompanied this code. -# -# This code is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# version 2 for more details (a copy is included in the LICENSE file that -# accompanied this code). -# -# You should have received a copy of the GNU General Public License version -# 2 along with this work; if not, write to the Free Software Foundation, -# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -# -# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -# or visit www.oracle.com if you need additional information or have any -# questions. -# - -default: all - -include $(SPEC) -include MakeBase.gmk -include $(JDK_TOPDIR)/make/Tools.gmk - -################################################################################ - -# List of all possible directories for javadoc to look for sources -# Allow custom to overwrite. -JAVADOC_SOURCE_DIRS = \ - $(SUPPORT_OUTPUTDIR)/gensrc/* \ - $(addsuffix /*, $(IMPORT_MODULES_SRC)) \ - $(JDK_TOPDIR)/src/*/$(OPENJDK_TARGET_OS)/classes \ - $(JDK_TOPDIR)/src/*/$(OPENJDK_TARGET_OS_TYPE)/classes \ - $(JDK_TOPDIR)/src/*/share/classes \ - $(HOTSPOT_TOPDIR)/src/*/share/classes \ - $(LANGTOOLS_TOPDIR)/src/*/share/classes \ - $(NASHORN_TOPDIR)/src/*/share/classes \ - $(CORBA_TOPDIR)/src/*/share/classes \ - $(JAXP_TOPDIR)/src/*/share/classes \ - $(JAXWS_TOPDIR)/src/*/share/classes \ - $(SUPPORT_OUTPUTDIR)/rmic/* \ - $(JDK_TOPDIR)/src/*/share/doc/stub \ - # - -# Should we use -Xdocrootparent? Allow custom to overwrite. -DOCROOTPARENT_FLAG = TRUE - -# URLs -JAVADOC_BASE_URL := http://docs.oracle.com/javase/$(VERSION_SPECIFICATION)/docs -BUG_SUBMIT_URL := http://bugreport.java.com/bugreport/ - -################################################################################ -# Text snippets - -FULL_COMPANY_NAME := Oracle and/or its affiliates -COMPANY_ADDRESS := 500 Oracle Parkway
    Redwood Shores, CA 94065 USA -BUG_SUBMIT_LINE := Submit a bug or feature - -COMMON_BOTTOM_TEXT := $(BUG_SUBMIT_LINE)
    Java is a trademark or registered \ - trademark of $(FULL_COMPANY_NAME) in the US and other countries. - -CORE_BOTTOM_COPYRIGHT_URL := {@docroot}/../legal/cpyr.html -CORE_BOTTOM_TEXT := \ - $(BUG_SUBMIT_LINE) \ -
    For further API reference and developer documentation, see \ - Java SE \ - Documentation. That documentation contains more detailed, \ - developer-targeted descriptions, with conceptual overviews, definitions of \ - terms, workarounds, and working code examples. - -ifeq ($(VERSION_IS_GA), true) - DRAFT_MARKER := - DRAFT_WINDOW_TITLE_MARKER := - EARLYACCESS_TOP := -else - # We need a draft format when not building the GA version. - DRAFT_MARKER :=
    DRAFT $(VERSION_STRING) - ifeq ($(VERSION_BUILD), 0) - DRAFT_WINDOW_TITLE_MARKER := $(SPACE)[ad-hoc build] - else - DRAFT_WINDOW_TITLE_MARKER := $(SPACE)[build $(VERSION_BUILD)] - endif - EARLYACCESS_TOP := \ -
    Please note that the specifications \ - and other information contained herein are not final and are subject to \ - change. The information is being made available to you solely for \ - purpose of evaluation.
    -endif - -################################################################################ -# Special treatment for the core package list. All separate "small" javadoc -# invocation needs to be able to see the core package list. - -ALL_PKG_DIRS := $(dir $(filter %.java, $(call CacheFind, \ - $(wildcard $(JAVADOC_SOURCE_DIRS))))) -ALL_SRC_PREFIXES := $(addsuffix /%, $(wildcard $(JAVADOC_SOURCE_DIRS))) -ALL_PKG_DIRNAMES := $(foreach prefix, $(ALL_SRC_PREFIXES), \ - $(patsubst $(prefix),%, $(filter $(prefix), $(ALL_PKG_DIRS)))) -ALL_PACKAGES := $(sort $(subst /,., $(patsubst %/, %, $(ALL_PKG_DIRNAMES)))) - -# Core packages are all packages beginning with java, javax or org, except a few -# excludes. -JAVA_PACKAGES := $(filter java.%, $(ALL_PACKAGES)) -JAVAX_PACKAGES := $(filter javax.%, $(ALL_PACKAGES)) -ORG_PACKAGES := $(filter org.%, $(ALL_PACKAGES)) - -# Allow custom makefile to add more excluded packages -CORE_EXCLUDED_PACKAGES += \ - java.awt.dnd.peer \ - java.awt.peer \ - javax.smartcardio \ - org.jcp.xml.dsig.internal% \ - org.w3c.dom.css \ - org.w3c.dom.html \ - org.w3c.dom.stylesheets \ - org.w3c.dom.xpath \ - org.graalvm.compiler.% \ - # - -CORE_PACKAGES := $(filter-out $(CORE_EXCLUDED_PACKAGES), \ - $(JAVA_PACKAGES) $(JAVAX_PACKAGES) $(ORG_PACKAGES)) - -CORE_PACKAGES_LIST_DIR := $(SUPPORT_OUTPUTDIR)/docs/core-packages -CORE_PACKAGES_LIST_FILE := $(CORE_PACKAGES_LIST_DIR)/package-list - -CORE_PACKAGES_VARDEPS_FILE := $(call DependOnVariable, CORE_PACKAGES, \ - $(CORE_PACKAGES_LIST_FILE).vardeps) - -$(CORE_PACKAGES_LIST_FILE): $(CORE_PACKAGES_VARDEPS_FILE) - $(call MakeDir, $(@D)) - $(eval $(call ListPathsSafely, CORE_PACKAGES, $@)) - -################################################################################ -# Support functions for SetupJavadocGeneration - -# Generate the text used in the -bottom argument. -# Note that COPYRIGHT_YEAR is the current year (from spec.gmk) -# Arguments: -# arg 1: first copyright year -# arg 2: copyright url (optional) -# arg 3: free-form text snippet (optional) -define GenerateBottom - $(if $(strip $3), $(strip $3))
    $(if \ - $(strip $2),Copyright,Copyright) \ - © $(strip $1), $(COPYRIGHT_YEAR), $(FULL_COMPANY_NAME). \ - $(COMPANY_ADDRESS). All rights reserved.
    -endef - -# Speed up finding by filling cache -$(eval $(call FillCacheFind, $(wildcard $(JAVADOC_SOURCE_DIRS)))) - -# In order to get a specific ordering it's necessary to specify the total -# ordering of tags as the tags are otherwise ordered in order of definition. -DEFAULT_JAVADOC_TAGS := \ - -tag beaninfo:X \ - -tag revised:X \ - -tag since.unbundled:X \ - -tag spec:X \ - -tag specdefault:X \ - -tag Note:X \ - -tag ToDo:X \ - -tag 'apiNote:a:API Note:' \ - -tag 'implSpec:a:Implementation Requirements:' \ - -tag 'implNote:a:Implementation Note:' \ - -tag param \ - -tag return \ - -tag throws \ - -tag since \ - -tag version \ - -tag serialData \ - -tag factory \ - -tag see \ - -tag 'jvms:a:See The Java™ Virtual Machine Specification:' \ - -tag 'jls:a:See The Java™ Language Specification:' \ - -taglet build.tools.taglet.Incubating \ - -tagletpath $(BUILDTOOLS_OUTPUTDIR)/jdk_tools_classes \ - # - -DEFAULT_JAVADOC_OPTIONS := -XDignore.symbol.file=true -use -keywords -notimestamp \ - -serialwarn -encoding ISO-8859-1 -breakiterator --system none - -################################################################################ -# Setup make rules for running javadoc. -# -# Parameter 1 is the name of the rule. This name is used as variable prefix, -# and the targets generated are listed in a variable by that name. Note that -# the index.html file will work as a "touch file" for all the magnitude of -# files that are generated by javadoc. -# -# Remaining parameters are named arguments. These include: -# MODULES - Modules to include -# PACKAGES - Packages to include -# IS_CORE - Set to TRUE for the Core API package which needs special treatment -# API_ROOT - Where to base the documentation (jre or jdk) -# DEST_DIR - A directory relative to the API root -# OVERVIEW - Path to a html overview file -# TITLE - Default title to use for the more specific versions below -# WINDOW_TITLE - Title to use in -windowtitle. Computed from TITLE if empty. -# HEADER_TITLE - Title to use in -header. Computed from TITLE if empty. -# DOC_TITLE - Title to use in -doctitle. Computed from TITLE if empty. -# FIRST_COPYRIGHT_YEAR - First year this bundle was introduced -# DISABLED_DOCLINT - Doclint warnings to exclude. -# DOCLINT_PACKAGES - Optional -Xdoclint/package value -# SPLIT_INDEX - Enable -splitIndex (split index-all.html if it is too large) -# BOTTOM_COPYRIGHT_URL - Copyright URL to use in -bottom -# BOTTOM_TEXT - Extra text to use in -bottom -# EXTRA_TOP - Additional -top data -# -SetupJavadocGeneration = $(NamedParamsMacroTemplate) -define SetupJavadocGenerationBody - ifeq ($$($1_IS_CORE), TRUE) - $1_JAVA := $$(JAVA) - $1_OUTPUT_DIRNAME := api - else - $1_JAVA := $$(JAVA_SMALL) - $1_OUTPUT_DIRNAME := $$($1_API_ROOT)/api/$$($1_DEST_DIR) - - # Compute a relative path to core root. - # The non-core api javadocs need to be able to access the root of the core - # api directory, so for jdk/api or jre/api to get to the core api/ - # directory we would use this - $1_RELATIVE_CORE_DIR := $$(call DirToDotDot, $$($1_OUTPUT_DIRNAME))/api - - # We need to tell javadoc the directory in which to find the core package-list - $1_OPTIONS += -linkoffline $$($1_RELATIVE_CORE_DIR) $$(CORE_PACKAGES_LIST_DIR) - - $1_DEPS += $(CORE_PACKAGES_LIST_FILE) - endif - - $1_OPTIONS += --add-modules $$(call CommaList, $$($1_MODULES)) - - ifneq ($$($1_DISABLED_DOCLINT), ) - # Create a string like ",-syntax,-html" - $1_DOCLINT_EXCEPTIONS := ,$$(call CommaList, $$(addprefix -, $$($1_DISABLED_DOCLINT))) - endif - $1_OPTIONS += -Xdoclint:all$$($1_DOCLINT_EXCEPTIONS) - - ifneq ($$($1_DOCLINT_PACKAGES), ) - $1_OPTIONS += -Xdoclint/package:$$(call CommaList, $$($1_DOCLINT_PACKAGES)) - endif - - ifeq ($$($1_DOC_TITLE), ) - $1_DOC_TITLE := $$($1_TITLE) - endif - $1_OPTIONS += -doctitle '$$($1_DOC_TITLE)' - - ifeq ($$($1_WINDOW_TITLE), ) - $1_WINDOW_TITLE := $$(strip $$(subst ™,, $$($1_TITLE))) - endif - $1_OPTIONS += -windowtitle '$$($1_WINDOW_TITLE)$$(DRAFT_WINDOW_TITLE_MARKER)' - - ifeq ($$($1_HEADER_TITLE), ) - $1_HEADER_TITLE := $$(strip $$(subst ™,, $$($1_TITLE))) - endif - $1_OPTIONS += -header '$$($1_HEADER_TITLE)$$(DRAFT_MARKER)' - - ifneq ($$($1_EXTRA_TOP), ) - $1_OPTIONS += -top '$$($1_EXTRA_TOP)' - endif - - ifeq ($$($1_BOTTOM_TEXT), ) - $1_BOTTOM_TEXT := $(COMMON_BOTTOM_TEXT) - endif - $1_BOTTOM := $$(call GenerateBottom, $$($1_FIRST_COPYRIGHT_YEAR), \ - $$($1_BOTTOM_COPYRIGHT_URL), $$($1_BOTTOM_TEXT)) - $1_OPTIONS += -bottom '$$($1_BOTTOM)$$(DRAFT_MARKER)' - - ifneq ($$($1_OVERVIEW), ) - $1_OPTIONS += -overview $$($1_OVERVIEW) - $1_DEPS += $$($1_OVERVIEW) - endif - - ifneq ($$($1_SPLIT_INDEX), ) - $1_OPTIONS += -splitIndex - endif - - ifneq ($$($DOCROOTPARENT_FLAG), ) - $1_OPTIONS += -Xdocrootparent $(JAVADOC_BASE_URL) - endif - - $1_VARDEPS := $$($1_OPTIONS) $$($1_PACKAGES) - $1_VARDEPS_FILE := $$(call DependOnVariable, $1_VARDEPS, \ - $$(SUPPORT_OUTPUTDIR)/docs/$1.vardeps) - - # Do not store debug level options in VARDEPS. - ifneq ($$(LOG_LEVEL), trace) - $1_OPTIONS += -quiet - else - $1_OPTIONS += -verbose - endif - - $1_PACKAGE_DEPS := $$(call CacheFind, $$(wildcard $$(foreach p, \ - $$(subst .,/,$$(strip $$($1_PACKAGES))), \ - $$(addsuffix /$$p, $$(wildcard $$(JAVADOC_SOURCE_DIRS)))))) - - # If there are many packages, use an @-file... - ifneq ($$(word 17, $$($1_PACKAGES)), ) - $1_PACKAGES_FILE := $$(SUPPORT_OUTPUTDIR)/docs/$1.packages - $1_PACKAGES_ARG := @$$($1_PACKAGES_FILE) - else - $1_PACKAGES_ARG := $$($1_PACKAGES) - endif - - # The index.html which is a marker for all the output from javadoc. - $1_INDEX_FILE := $$(JAVADOC_OUTPUTDIR)/$$($1_OUTPUT_DIRNAME)/index.html - - # Rule for actually running javadoc - $$($1_INDEX_FILE): $(BUILD_TOOLS_JDK) $$($1_VARDEPS_FILE) $$($1_PACKAGE_DEPS) $$($1_DEPS) - $$(call LogWarn, Generating Javadoc from $$(words $$($1_PACKAGES)) package(s) for $$($1_OUTPUT_DIRNAME)) - $$(call MakeDir, $$(@D)) - ifneq ($$($1_PACKAGES_FILE), ) - $$(eval $$(call ListPathsSafely, $1_PACKAGES, $$($1_PACKAGES_FILE))) - endif - $$(call ExecuteWithLog, $$(SUPPORT_OUTPUTDIR)/docs/$1.javadoc, \ - $$($1_JAVA) -Djava.awt.headless=true $(NEW_JAVADOC) -d $$(@D) \ - $$(DEFAULT_JAVADOC_TAGS) $$(DEFAULT_JAVADOC_OPTIONS) \ - --module-source-path $$(call PathList, $$(JAVADOC_SOURCE_DIRS)) \ - $$($1_OPTIONS) $$($1_PACKAGES_ARG)) - - # The output returned will be the index.html file - $1 := $$($1_INDEX_FILE) -endef - -################################################################################ - -$(eval $(call SetupJavadocGeneration, coredocs, \ - MODULES := java.se.ee, \ - PACKAGES := $(CORE_PACKAGES), \ - IS_CORE := TRUE, \ - OVERVIEW := $(JDK_TOPDIR)/src/java.base/share/classes/overview-core.html, \ - WINDOW_TITLE := Java Platform SE $(VERSION_SPECIFICATION), \ - HEADER_TITLE := Java™ Platform
    Standard Ed. $(VERSION_SPECIFICATION), \ - DOC_TITLE := Java™ Platform$(COMMA) Standard Edition \ - $(VERSION_SPECIFICATION)
    API Specification, \ - FIRST_COPYRIGHT_YEAR := 1993, \ - DISABLED_DOCLINT := accessibility html missing syntax, \ - DOCLINT_PACKAGES := -org.omg.* jdk.internal.logging.*, \ - SPLIT_INDEX := TRUE, \ - BOTTOM_COPYRIGHT_URL := $(CORE_BOTTOM_COPYRIGHT_URL), \ - BOTTOM_TEXT := $(CORE_BOTTOM_TEXT), \ - EXTRA_TOP := $(EARLYACCESS_TOP), \ -)) - -TARGETS += $(coredocs) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, docletapi, \ - MODULES := jdk.javadoc, \ - PACKAGES := \ - jdk.javadoc.doclet \ - jdk.javadoc.doclet.taglet \ - jdk.javadoc.doclets, \ - API_ROOT := jdk, \ - DEST_DIR := javadoc/doclet, \ - TITLE := Doclet API, \ - FIRST_COPYRIGHT_YEAR := 1993, \ -)) - -TARGETS += $(docletapi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, old-docletapi, \ - MODULES := jdk.javadoc, \ - PACKAGES := com.sun.javadoc, \ - API_ROOT := jdk, \ - DEST_DIR := javadoc/old/doclet, \ - TITLE := Doclet API, \ - FIRST_COPYRIGHT_YEAR := 1993, \ -)) - -TARGETS += $(old-docletapi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, tagletapi, \ - MODULES := jdk.javadoc, \ - PACKAGES := com.sun.tools.doclets, \ - API_ROOT := jdk, \ - DEST_DIR := javadoc/old/taglet, \ - TITLE := Taglet API, \ - FIRST_COPYRIGHT_YEAR := 1993, \ -)) - -TARGETS += $(tagletapi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, domapi, \ - MODULES := \ - java.xml \ - jdk.xml.dom, \ - PACKAGES := \ - org.w3c.dom \ - org.w3c.dom.bootstrap \ - org.w3c.dom.ls \ - org.w3c.dom.ranges \ - org.w3c.dom.traversal \ - org.w3c.dom.html \ - org.w3c.dom.stylesheets \ - org.w3c.dom.css \ - org.w3c.dom.events \ - org.w3c.dom.views, \ - API_ROOT := jre, \ - DEST_DIR := plugin/dom, \ - TITLE := Common DOM API, \ - FIRST_COPYRIGHT_YEAR := 2005, \ - DISABLED_DOCLINT := accessibility html missing, \ - SPLIT_INDEX := TRUE, \ -)) - -TARGETS += $(domapi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, jdi, \ - MODULES := jdk.jdi, \ - PACKAGES := \ - com.sun.jdi \ - com.sun.jdi.event \ - com.sun.jdi.request \ - com.sun.jdi.connect \ - com.sun.jdi.connect.spi, \ - API_ROOT := jdk, \ - DEST_DIR := jpda/jdi, \ - OVERVIEW := $(JDK_TOPDIR)/src/jdk.jdi/share/classes/jdi-overview.html, \ - TITLE := Java™ Debug Interface, \ - FIRST_COPYRIGHT_YEAR := 1999, \ - DISABLED_DOCLINT := accessibility missing syntax, \ - SPLIT_INDEX := TRUE, \ -)) - -TARGETS += $(jdi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, jaas, \ - MODULES := jdk.security.auth, \ - PACKAGES := \ - com.sun.security.auth \ - com.sun.security.auth.callback \ - com.sun.security.auth.login \ - com.sun.security.auth.module, \ - API_ROOT := jre, \ - DEST_DIR := security/jaas/spec, \ - OVERVIEW := $(JDK_TOPDIR)/src/jdk.security.auth/share/classes/jaas-overview.html, \ - TITLE := Java™ Authentication and Authorization Service, \ - FIRST_COPYRIGHT_YEAR := 1998, \ - DISABLED_DOCLINT := missing, \ -)) - -TARGETS += $(jaas) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, jgss, \ - MODULES := jdk.security.jgss, \ - PACKAGES := com.sun.security.jgss, \ - API_ROOT := jre, \ - DEST_DIR := security/jgss/spec, \ - OVERVIEW := $(JDK_TOPDIR)/src/java.security.jgss/share/classes/jgss-overview.html, \ - TITLE := Java™ GSS-API Utilities, \ - FIRST_COPYRIGHT_YEAR := 2000, \ -)) - -TARGETS += $(jgss) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, smartcardio, \ - MODULES := java.smartcardio, \ - PACKAGES := javax.smartcardio, \ - API_ROOT := jre, \ - DEST_DIR := security/smartcardio/spec, \ - TITLE := Java™ Smart Card I/O, \ - FIRST_COPYRIGHT_YEAR := 2005, \ -)) - -TARGETS += $(smartcardio) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, httpserver, \ - MODULES := jdk.httpserver, \ - PACKAGES := \ - com.sun.net.httpserver \ - com.sun.net.httpserver.spi, \ - API_ROOT := jre, \ - DEST_DIR := net/httpserver/spec, \ - TITLE := Java™ HTTP Server, \ - FIRST_COPYRIGHT_YEAR := 2005, \ - DISABLED_DOCLINT := accessibility missing syntax, \ -)) - -TARGETS += $(httpserver) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, httpclient, \ - MODULES := jdk.incubator.httpclient, \ - PACKAGES := \ - jdk.incubator.http, \ - API_ROOT := jre, \ - DEST_DIR := incubator/httpclient/spec, \ - TITLE := Java™ HTTP Client API (incubator module), \ - FIRST_COPYRIGHT_YEAR := 2015, \ - DISABLED_DOCLINT := accessibility missing syntax, \ -)) - -TARGETS += $(httpclient) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, jsobject, \ - MODULES := jdk.jsobject, \ - PACKAGES := netscape.javascript, \ - API_ROOT := jre, \ - DEST_DIR := plugin/jsobject, \ - FIRST_COPYRIGHT_YEAR := 1993, \ - TITLE := Java™ JSObject Doc, \ -)) - -TARGETS += $(jsobject) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, mgmt, \ - MODULES := jdk.management, \ - PACKAGES := com.sun.management, \ - API_ROOT := jre, \ - DEST_DIR := management/extension, \ - OVERVIEW := $(JDK_TOPDIR)/src/java.management/share/classes/mgmt-overview.html, \ - TITLE := Monitoring and Management Interface for the Java™ Platform, \ - FIRST_COPYRIGHT_YEAR := 2003, \ - DISABLED_DOCLINT := accessibility missing reference, \ -)) - -TARGETS += $(mgmt) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, attach, \ - MODULES := jdk.attach, \ - PACKAGES := \ - com.sun.tools.attach \ - com.sun.tools.attach.spi, \ - API_ROOT := jdk, \ - DEST_DIR := attach/spec, \ - TITLE := Attach API, \ - FIRST_COPYRIGHT_YEAR := 2005, \ - DISABLED_DOCLINT := reference, \ -)) - -TARGETS += $(attach) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, jconsole, \ - MODULES := jdk.jconsole, \ - PACKAGES := com.sun.tools.jconsole, \ - API_ROOT := jdk, \ - DEST_DIR := jconsole/spec, \ - TITLE := JConsole API, \ - FIRST_COPYRIGHT_YEAR := 2006, \ -)) - -TARGETS += $(jconsole) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, jshellapi, \ - MODULES := jdk.jshell, \ - PACKAGES := \ - jdk.jshell \ - jdk.jshell.spi \ - jdk.jshell.execution \ - jdk.jshell.tool, \ - API_ROOT := jdk, \ - DEST_DIR := jshell, \ - TITLE := JShell API, \ - FIRST_COPYRIGHT_YEAR := 2015, \ - SPLIT_INDEX := TRUE, \ -)) - -TARGETS += $(jshellapi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, treeapi, \ - MODULES := jdk.compiler, \ - PACKAGES := \ - com.sun.source.doctree \ - com.sun.source.tree \ - com.sun.source.util, \ - API_ROOT := jdk, \ - DEST_DIR := javac/tree, \ - TITLE := Compiler Tree API, \ - FIRST_COPYRIGHT_YEAR := 2005, \ - SPLIT_INDEX := TRUE, \ -)) - -TARGETS += $(treeapi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, nashornapi, \ - MODULES := jdk.scripting.nashorn, \ - PACKAGES := \ - jdk.nashorn.api.scripting \ - jdk.nashorn.api.tree, \ - API_ROOT := jdk, \ - DEST_DIR := nashorn, \ - TITLE := Nashorn API, \ - FIRST_COPYRIGHT_YEAR := 2014, \ - SPLIT_INDEX := TRUE, \ -)) - -TARGETS += $(nashornapi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, dynalinkapi, \ - MODULES := jdk.dynalink, \ - PACKAGES := \ - jdk.dynalink \ - jdk.dynalink.beans \ - jdk.dynalink.linker \ - jdk.dynalink.linker.support \ - jdk.dynalink.support, \ - API_ROOT := jdk, \ - DEST_DIR := dynalink, \ - TITLE := Dynalink API, \ - FIRST_COPYRIGHT_YEAR := 2015, \ -)) - -TARGETS += $(dynalinkapi) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, sctp, \ - MODULES := jdk.sctp, \ - PACKAGES := com.sun.nio.sctp, \ - API_ROOT := jre, \ - DEST_DIR := nio/sctp/spec, \ - TITLE := SCTP API, \ - FIRST_COPYRIGHT_YEAR := 2009, \ -)) - -TARGETS += $(sctp) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, jaccess, \ - MODULES := jdk.accessibility, \ - PACKAGES := com.sun.java.accessibility.util, \ - API_ROOT := jre, \ - DEST_DIR := accessibility/jaccess/spec, \ - TITLE := JACCESS API, \ - FIRST_COPYRIGHT_YEAR := 2002, \ -)) - -TARGETS += $(jaccess) - -################################################################################ - -$(eval $(call SetupJavadocGeneration, jdknet, \ - MODULES := jdk.net, \ - PACKAGES := jdk.net, \ - API_ROOT := jre, \ - DEST_DIR := net/socketoptions/spec, \ - TITLE := jdk.net API, \ - FIRST_COPYRIGHT_YEAR := 2014, \ - DISABLED_DOCLINT := missing, \ -)) - -TARGETS += $(jdknet) - -################################################################################ -# Copy JDWP html file - -JDWP_HTML := $(SUPPORT_OUTPUTDIR)/gensrc/jdk.jdi/jdwp-protocol.html - -$(eval $(call SetupCopyFiles, COPY_JDWP_HTML, \ - FILES := $(JDWP_HTML), \ - DEST := $(JAVADOC_OUTPUTDIR)/platform/jpda/jdwp, \ -)) - -COPY_TARGETS += $(COPY_JDWP_HTML) - -################################################################################ -# Copy JVMTI html file - -# Pick jvmti.html from any jvm variant, they are all the same. -JVMTI_HTML := $(firstword \ - $(wildcard $(HOTSPOT_OUTPUTDIR)/variant-*/gensrc/jvmtifiles/jvmti.html)) - -$(eval $(call SetupCopyFiles, COPY_JVMTI_HTML, \ - FILES := $(JVMTI_HTML), \ - DEST := $(JAVADOC_OUTPUTDIR)/platform/jvmti, \ -)) - -COPY_TARGETS += $(COPY_JVMTI_HTML) - -################################################################################ -# Optional target which bundles all generated javadocs into a zip archive. - -JAVADOC_ARCHIVE_NAME := jdk-$(VERSION_STRING)-docs.zip -JAVADOC_ARCHIVE_ASSEMBLY_DIR := $(SUPPORT_OUTPUTDIR)/docs/zip-docs -JAVADOC_ARCHIVE_DIR := $(OUTPUT_ROOT)/bundles -JAVADOC_ARCHIVE := $(JAVADOC_ARCHIVE_DIR)/$(JAVADOC_ARCHIVE_NAME) - -$(JAVADOC_ARCHIVE): $(TARGETS) $(COPY_TARGETS) - $(call LogInfo, Compressing javadoc to single $(JAVADOC_ARCHIVE_NAME)) - $(MKDIR) -p $(JAVADOC_ARCHIVE_DIR) - $(RM) -r $(JAVADOC_ARCHIVE_ASSEMBLY_DIR) - $(MKDIR) -p $(JAVADOC_ARCHIVE_ASSEMBLY_DIR) - all_roots=`$(FIND) $(JAVADOC_OUTPUTDIR) | $(GREP) index.html | grep -v old/doclet`; \ - pushd $(JAVADOC_ARCHIVE_ASSEMBLY_DIR); \ - for index_file in $${all_roots} ; do \ - target_dir=`dirname $${index_file}`; \ - name=`$(ECHO) $${target_dir} | $(SED) "s;/spec;;" | $(SED) "s;.*/;;"`; \ - $(LN) -s $${target_dir} $${name}; \ - done; \ - $(ZIPEXE) -q -r $(JAVADOC_ARCHIVE) * ; \ - popd ; - -ZIP_TARGETS += $(JAVADOC_ARCHIVE) - -################################################################################ - -# Hook to include the corresponding custom file, if present. -$(eval $(call IncludeCustomExtension, , Javadoc.gmk)) - -################################################################################ - -docs-javadoc: $(BUILD_TOOLS_JDK) $(TARGETS) - -docs-copy: $(COPY_TARGETS) - -docs-zip: $(ZIP_TARGETS) - -all: docs-javadoc docs-copy docs-zip - -.PHONY: default all docs-javadoc docs-copy docs-zip diff --git a/make/Main.gmk b/make/Main.gmk index 22f43c2317d..23e5b086fcf 100644 --- a/make/Main.gmk +++ b/make/Main.gmk @@ -1,5 +1,5 @@ # -# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -43,6 +43,7 @@ include $(SRC_ROOT)/make/MainSupport.gmk # Load the vital tools for all the makefiles. include $(SRC_ROOT)/make/common/MakeBase.gmk include $(SRC_ROOT)/make/common/Modules.gmk +include $(SRC_ROOT)/make/common/FindTests.gmk # Declare ALL_TARGETS as an immediate variable. This variable is a list of all # valid top level targets. It's used to declare them all as PHONY and to @@ -271,15 +272,15 @@ ALL_TARGETS += $(HOTSPOT_VARIANT_TARGETS) $(HOTSPOT_VARIANT_GENSRC_TARGETS) \ $(HOTSPOT_VARIANT_LIBS_TARGETS) hotspot-jsig hotspot-ide-project ################################################################################ -# Build demos and samples targets +# Build demos targets demos-jdk: +($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f CompileDemos.gmk) -samples-jdk: - +($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f CopySamples.gmk) +test-image-demos-jdk: + +($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f CompileDemos.gmk images) -ALL_TARGETS += demos-jdk samples-jdk +ALL_TARGETS += demos-jdk test-image-demos-jdk ################################################################################ # Jigsaw specific data and analysis targets. @@ -362,16 +363,35 @@ ALL_TARGETS += store-source-revision create-source-revision-tracker bootcycle-im ################################################################################ # Docs targets -docs-javadoc: - +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Javadoc.gmk docs-javadoc) +# If building full docs, to complete docs-*-api we need both the javadoc and +# modulegraph targets. +docs-jdk-api-javadoc: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Docs.gmk docs-jdk-api-javadoc) -docs-copy: - +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Javadoc.gmk docs-copy) +docs-jdk-api-modulegraph: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Docs.gmk docs-jdk-api-modulegraph) + +docs-javase-api-javadoc: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Docs.gmk docs-javase-api-javadoc) + +docs-javase-api-modulegraph: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Docs.gmk docs-javase-api-modulegraph) + +docs-jdk-specs: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Docs.gmk docs-jdk-specs) + +docs-jdk-index: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Docs.gmk docs-jdk-index) docs-zip: - +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Javadoc.gmk docs-zip) + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f Docs.gmk docs-zip) -ALL_TARGETS += docs-javadoc docs-copy docs-zip +update-build-docs: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f UpdateBuildDocs.gmk) + +ALL_TARGETS += docs-jdk-api-javadoc docs-jdk-api-modulegraph \ + docs-javase-api-javadoc docs-javase-api-modulegraph docs-jdk-specs \ + docs-jdk-index docs-zip update-build-docs ################################################################################ # Cross compilation support @@ -422,6 +442,27 @@ endif ALL_TARGETS += $(INTERIM_JMOD_TARGETS) interim-image generate-link-opt-data +################################################################################ +# Generate test names for all JTReg test groups +# + +define DeclareRunTestRecipe + run-test-$1: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f RunTests.gmk run-test TEST="$1") + + exploded-run-test-$1: + +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) -f RunTests.gmk run-test \ + TEST="$1" JDK_IMAGE_DIR=$(JDK_OUTPUTDIR)) + +endef + +# ALL_NAMED_TESTS is defined in FindTests.gmk +$(foreach t, $(ALL_NAMED_TESTS), $(eval $(call DeclareRunTestRecipe,$t))) +ALL_TEST_TARGETS := $(addprefix run-test-, $(ALL_NAMED_TESTS)) +ALL_EXPLODED_TEST_TARGETS := $(addprefix exploded-run-test-, $(ALL_NAMED_TESTS)) + +ALL_TARGETS += $(ALL_TEST_TARGETS) $(ALL_EXPLODED_TEST_TARGETS) + ################################################################################ # Build tests # @@ -446,6 +487,13 @@ test-image-jdk-jtreg-native: +($(CD) $(JDK_TOPDIR)/make/test && $(MAKE) $(MAKE_ARGS) -f JtregNative.gmk \ test-image-jdk-jtreg-native) +run-test: + +($(CD) $(TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f RunTests.gmk run-test TEST="$(TEST)") + +exploded-run-test: + +($(CD) $(TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f RunTests.gmk run-test \ + TEST="$(TEST)" JDK_IMAGE_DIR=$(JDK_OUTPUTDIR)) + ifeq ($(BUILD_GTEST), true) test-image-hotspot-gtest: +($(CD) $(HOTSPOT_TOPDIR)/make/test && $(MAKE) $(MAKE_ARGS) -f GtestImage.gmk) @@ -474,7 +522,8 @@ endif ALL_TARGETS += prepare-test-image build-test-hotspot-jtreg-native \ test-image-hotspot-jtreg-native build-test-jdk-jtreg-native \ test-image-jdk-jtreg-native build-test-lib build-test-failure-handler \ - test-failure-handler test-image-failure-handler test-image-hotspot-gtest + test-failure-handler test-image-failure-handler test-image-hotspot-gtest \ + run-test exploded-run-test ################################################################################ # Run tests @@ -597,6 +646,7 @@ else # jdk libs, even though they don't need to. To avoid warnings, make sure they # aren't built until after libjava and libjvm are available to link to. demos-jdk: java.base-libs exploded-image-optimize + test-image-demos-jdk: demos-jdk # Declare dependency from -java to -gensrc $(foreach m, $(GENSRC_MODULES), $(eval $m-java: $m-gensrc)) @@ -633,16 +683,16 @@ else # in javadoc. java.desktop-gensrc-jdk: java.base-gensrc - # The annotation processing for jdk.vm.ci and jdk.vm.compiler needs classes - # from the current JDK. - jdk.vm.ci-gensrc-hotspot: $(addsuffix -java, \ - $(call FindTransitiveDepsForModule, jdk.vm.ci)) - jdk.vm.compiler-gensrc-hotspot: $(addsuffix -java, \ - $(call FindTransitiveDepsForModule, jdk.vm.compiler)) + # The annotation processing for jdk.internal.vm.ci and jdk.internal.vm.compiler + # needs classes from the current JDK. + jdk.internal.vm.ci-gensrc-hotspot: $(addsuffix -java, \ + $(call FindTransitiveDepsForModule, jdk.internal.vm.ci)) + jdk.internal.vm.compiler-gensrc-hotspot: $(addsuffix -java, \ + $(call FindTransitiveDepsForModule, jdk.internal.vm.compiler)) - # For jdk.vm.compiler, the gensrc step is generating a module-info.java.extra + # For jdk.internal.vm.compiler, the gensrc step is generating a module-info.java.extra # file to be processed by the gensrc-moduleinfo target. - jdk.vm.compiler-gensrc-moduleinfo: jdk.vm.compiler-gensrc-hotspot + jdk.internal.vm.compiler-gensrc-moduleinfo: jdk.internal.vm.compiler-gensrc-hotspot # Explicitly add dependencies for special targets java.base-java: unpack-sec @@ -654,8 +704,7 @@ else # When creating a BUILDJDK, we don't need to add hashes to java.base, thus # we don't need to depend on all other jmods ifneq ($(CREATING_BUILDJDK), true) - java.base-jmod: jrtfs-jar $(filter-out java.base-jmod \ - $(addsuffix -jmod, $(call FindAllUpgradeableModules)), $(JMOD_TARGETS)) + java.base-jmod: jrtfs-jar $(filter-out java.base-jmod, $(JMOD_TARGETS)) endif # Building java.base-jmod requires all of hotspot to be built. @@ -728,12 +777,12 @@ else generate-link-opt-data: buildtools-jdk # The generated classlist needs to go into java.base-jmod. - java.base-jmod jdk-image jre-image: generate-link-opt-data + java.base-jmod jdk.jlink-jmod jdk-image jre-image: generate-link-opt-data endif release-file: create-source-revision-tracker - jdk-image: jmods zip-source demos samples release-file + jdk-image: jmods zip-source demos release-file jre-image: jmods release-file symbols-image: $(LIBS_TARGETS) $(LAUNCHER_TARGETS) @@ -749,15 +798,31 @@ else bootcycle-images: jdk-image - docs-javadoc: $(GENSRC_TARGETS) rmic + docs-jdk-api-javadoc: $(GENSRC_TARGETS) rmic - # The gensrc step for jdk.jdi creates an html file that is used by docs-copy. - docs-copy: hotspot-$(JVM_VARIANT_MAIN)-gensrc jdk.jdi-gensrc + docs-javase-api-javadoc: $(GENSRC_TARGETS) rmic - docs-zip: docs-javadoc docs-copy + docs-jdk-api-modulegraph: exploded-image buildtools-modules + + docs-javase-api-modulegraph: exploded-image buildtools-modules + + # The gensrc steps for hotspot and jdk.jdi create html spec files. + docs-jdk-specs: hotspot-$(JVM_VARIANT_MAIN)-gensrc jdk.jdi-gensrc \ + docs-jdk-index + + docs-jdk-index: exploded-image buildtools-modules + + docs-zip: docs-jdk test: jdk-image test-image + run-test: jdk-image test-image + exploded-run-test: exploded-image test-image + + # Declare dependency for all generated test targets + $(foreach t, $(ALL_TEST_TARGETS), $(eval $t: jdk-image test-image)) + $(foreach t, $(ALL_EXPLODED_TEST_TARGETS), $(eval $t: exploded-image test-image)) + create-buildjdk-copy: jdk.jlink-java java.base-gendata \ $(addsuffix -java, $(INTERIM_IMAGE_MODULES)) @@ -857,8 +922,6 @@ java.base: hotspot demos: demos-jdk -samples: samples-jdk - # The "exploded image" is a locally runnable JDK in $(BUILD_OUTPUT)/jdk. exploded-image-base: $(ALL_MODULES) exploded-image: exploded-image-base release-file @@ -870,6 +933,22 @@ endif create-buildjdk: create-buildjdk-copy create-buildjdk-interim-image +docs-jdk-api: docs-jdk-api-javadoc +docs-javase-api: docs-javase-api-javadoc + +# If we're building full docs, we must also generate the module graphs to +# get non-broken api documentation. +ifeq ($(ENABLE_FULL_DOCS), true) + docs-jdk-api: docs-jdk-api-modulegraph + docs-javase-api: docs-javase-api-modulegraph +endif + +docs-jdk: docs-jdk-api docs-jdk-specs docs-jdk-index +docs-javase: docs-javase-api + +# alias for backwards compatibility +docs-javadoc: docs-jdk-api + mac-bundles: mac-bundles-jdk # The $(BUILD_OUTPUT)/images directory contain the resulting deliverables, @@ -901,11 +980,12 @@ ifeq ($(OPENJDK_TARGET_OS), macosx) endif # This target builds the documentation image -docs-image: docs-javadoc docs-copy +docs-image: docs-jdk # This target builds the test image test-image: prepare-test-image test-image-hotspot-jtreg-native \ - test-image-jdk-jtreg-native test-image-failure-handler test-image-hotspot-gtest + test-image-jdk-jtreg-native test-image-failure-handler test-image-hotspot-gtest \ + test-image-demos-jdk # all-images builds all our deliverables as images. all-images: product-images test-image docs-image @@ -915,9 +995,10 @@ all-bundles: product-bundles test-bundles docs-bundles ALL_TARGETS += buildtools hotspot hotspot-libs hotspot-gensrc gensrc gendata \ copy java rmic libs launchers jmods \ - jdk.jdwp.agent-gensrc $(ALL_MODULES) demos samples \ + jdk.jdwp.agent-gensrc $(ALL_MODULES) demos \ exploded-image-base exploded-image \ - create-buildjdk mac-bundles product-images \ + create-buildjdk docs-jdk-api docs-javase-api docs-jdk docs-javase \ + docs-javadoc mac-bundles product-images \ profiles profiles-images \ docs-image test-image all-images \ all-bundles @@ -1032,6 +1113,9 @@ print-targets: print-modules: @$(ECHO) $(sort $(ALL_MODULES)) +print-tests: + @$(ECHO) $(sort $(ALL_NAMED_TESTS)) + create-main-targets-include: $(call LogInfo, Generating main target list) @$(ECHO) ALL_MAIN_TARGETS := $(sort $(ALL_TARGETS)) > \ diff --git a/make/ReleaseFile.gmk b/make/ReleaseFile.gmk index b57cb7be780..0f4d080a07e 100644 --- a/make/ReleaseFile.gmk +++ b/make/ReleaseFile.gmk @@ -48,6 +48,8 @@ define create-info-file $(call info-file-item, "SUN_ARCH_ABI", "$(JDK_ARCH_ABI_PROP_NAME)")) $(call info-file-item, "SOURCE", "$(strip $(SOURCE_REVISION))") $(call info-file-item, "IMPLEMENTOR", "$(COMPANY_NAME)") + $(call info-file-item, "OS_NAME", "$(RELEASE_FILE_OS_NAME)") + $(call info-file-item, "OS_ARCH", "$(RELEASE_FILE_OS_ARCH)") endef # Param 1 - The file containing the MODULES list diff --git a/make/RunTests.gmk b/make/RunTests.gmk new file mode 100644 index 00000000000..fa21f305e13 --- /dev/null +++ b/make/RunTests.gmk @@ -0,0 +1,491 @@ +# +# Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Oracle designates this +# particular file as subject to the "Classpath" exception as provided +# by Oracle in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. +# + +default: all + +include $(SPEC) +include MakeBase.gmk +include FindTests.gmk + +# We will always run multiple tests serially +.NOTPARALLEL: + +# Hook to include the corresponding custom file, if present. +$(eval $(call IncludeCustomExtension, , RunTests.gmk)) + +TEST_RESULTS_DIR := $(BUILD_OUTPUT)/test-results +TEST_SUPPORT_DIR := $(BUILD_OUTPUT)/test-support + + +################################################################################ +# Parse control variables +################################################################################ + +$(eval $(call ParseKeywordVariable, JTREG, \ + KEYWORDS := JOBS TIMEOUT TEST_MODE ASSERT VERBOSE RETAIN MAX_MEM, \ + STRING_KEYWORDS := OPTIONS JAVA_OPTIONS VM_OPTIONS, \ +)) + +ifneq ($(JTREG), ) + # Inform the user + $(info Running tests using JTREG control variable '$(JTREG)') +endif + +$(eval $(call ParseKeywordVariable, GTEST, \ + KEYWORDS := REPEAT, \ + STRING_KEYWORDS := OPTIONS, \ +)) + +ifneq ($(GTEST), ) + # Inform the user + $(info Running tests using GTEST control variable '$(GTEST)') +endif + + +################################################################################ +# Component-specific Jtreg settings +################################################################################ + +ifeq ($(TEST_JOBS), 0) + # If TEST_JOBS is not specified, hotspot fallback default is + # min(num_cores / 2, 12). + hotspot_JTREG_JOBS := $(shell $(EXPR) $(NUM_CORES) / 2) + ifeq ($(hotspot_JTREG_JOBS), 0) + hotspot_JTREG_JOBS := 1 + else ifeq ($(shell $(EXPR) $(hotspot_JTREG_JOBS) \> 12), 1) + hotspot_JTREG_JOBS := 12 + endif +endif + +hotspot_JTREG_MAX_MEM := 0 +hotspot_JTREG_ASSERT := false +hotspot_JTREG_NATIVEPATH := $(TEST_IMAGE_DIR)/hotspot/jtreg/native +jdk_JTREG_NATIVEPATH := $(TEST_IMAGE_DIR)/jdk/jtreg/native + + +################################################################################ +# Parse test selection +# +# The user has given a test selection in the TEST variable. We must parse it +# and determine what that means in terms of actual calls to the test framework. +# +# The parse functions take as argument a test specification as given by the +# user, and returns a fully qualified test descriptor if it was a match, or +# nothing if not. A single test specification can result in multiple test +# descriptors being returned. A valid test descriptor must always be accepted +# and returned identically. +################################################################################ + +# Helper function to determine if a test specification is a Gtest test +# +# It is a Gtest test if it is either "gtest", or "gtest:" followed by an optional +# test filter string. +define ParseGtestTestSelection + $(if $(filter gtest%, $1), \ + $(if $(filter gtest, $1), \ + gtest:all \ + , \ + $(if $(filter gtest:, $1), \ + gtest:all \ + , \ + $1 \ + ) \ + ) \ + ) +endef + +# Helper function to determine if a test specification is a Jtreg test +# +# It is a Jtreg test if it optionally begins with jtreg:, and then is either +# an unspecified group name (possibly prefixed by :), or a group in a +# specified /test directory, or a path to a test or test directory, +# either absolute or relative to TOPDIR. +define ParseJtregTestSelection + $(eval TEST_NAME := $(strip $(patsubst jtreg:%, %, $1))) \ + $(if $(or $(findstring :, $(TEST_NAME)), $(findstring /, $(TEST_NAME))), , \ + $(eval TEST_NAME := :$(TEST_NAME)) \ + ) \ + $(if $(findstring :, $(TEST_NAME)), \ + $(if $(filter :%, $(TEST_NAME)), \ + $(foreach component, $(JTREG_COMPONENTS), \ + $(if $(filter $(patsubst :%, %, $(TEST_NAME)), \ + $($(component)_JTREG_TEST_GROUPS)), \ + jtreg:$(component)/test:$(patsubst :%,%,$(TEST_NAME)) \ + ) \ + ) \ + , \ + $(eval COMPONENT := $(word 1, $(subst /, $(SPACE), $(TEST_NAME)))) \ + $(eval GROUP := $(word 2, $(subst :, $(SPACE), $(TEST_NAME)))) \ + $(if $(filter $(COMPONENT), $(JTREG_COMPONENTS)), \ + $(if $(filter $(GROUP), $($(COMPONENT)_JTREG_TEST_GROUPS)), \ + jtreg:$(TEST_NAME) \ + ) \ + ) \ + ) \ + , \ + $(if $(filter /%, $(TEST_NAME)), \ + $(if $(wildcard $(TEST_NAME)), \ + jtreg:$(TEST_NAME) \ + ) \ + , \ + $(if $(wildcard $(TOPDIR)/$(TEST_NAME)), \ + jtreg:$(TEST_NAME) \ + ) \ + ) \ + ) +endef + +ifeq ($(TEST), ) + $(info No test selection given in TEST!) + $(info Please use e.g. 'run-test TEST=tier1' or 'run-test-tier1') + $(info See common/doc/testing.[md|html] for help) + $(error Cannot continue) +endif + +# Now intelligently convert the test selection given by the user in TEST +# into a list of fully qualified test descriptors of the tests to run. +TESTS_TO_RUN := +$(foreach test, $(TEST), \ + $(eval PARSED_TESTS := $(call ParseCustomTestSelection, $(test))) \ + $(if $(strip $(PARSED_TESTS)), , \ + $(eval PARSED_TESTS += $(call ParseGtestTestSelection, $(test))) \ + ) \ + $(if $(strip $(PARSED_TESTS)), , \ + $(eval PARSED_TESTS += $(call ParseJtregTestSelection, $(test))) \ + ) \ + $(if $(strip $(PARSED_TESTS)), , \ + $(eval UNKNOWN_TEST := $(test)) \ + ) \ + $(eval TESTS_TO_RUN += $(PARSED_TESTS)) \ +) + +ifneq ($(UNKNOWN_TEST), ) + $(info Unknown test selection: '$(UNKNOWN_TEST)') + $(info See common/doc/testing.[md|html] for help) + $(error Cannot continue) +endif + +TESTS_TO_RUN := $(strip $(TESTS_TO_RUN)) + + +# Present the result of our parsing to the user +$(info Test selection '$(TEST)', will run:) +$(foreach test, $(TESTS_TO_RUN), $(info * $(test))) + + +################################################################################ +# Functions for setting up rules for running the selected tests +# +# The SetupRun*Test functions all have the same interface: +# +# Parameter 1 is the name of the rule. This is the test id, based on the test +# descriptor, and this is also used as variable prefix, and the targets +# generated are listed in a variable by that name. +# +# Remaining parameters are named arguments. Currently this is only: +# TEST -- The properly formatted fully qualified test descriptor +# +# After the rule named by the test id has been executed, the following +# variables will be available: +# testid_TOTAL - the total number of tests run +# testid_PASSED - the number of successful tests +# testid_FAILED - the number of failed tests +# testid_ERROR - the number of tests was neither successful or failed +# +################################################################################ + +### Rules for Gtest + +SetupRunGtestTest = $(NamedParamsMacroTemplate) +define SetupRunGtestTestBody + $1_TEST_RESULTS_DIR := $$(TEST_RESULTS_DIR)/$1 + $1_TEST_SUPPORT_DIR := $$(TEST_SUPPORT_DIR)/$1 + + $1_TEST_NAME := $$(strip $$(patsubst gtest:%, %, $$($1_TEST))) + ifneq ($$($1_TEST_NAME), all) + $1_GTEST_FILTER := --gtest_filter=$$($1_TEST_NAME)* + endif + + ifneq ($$(GTEST_REPEAT), ) + $1_GTEST_REPEAT :=--gtest_repeat=$$(GTEST_REPEAT) + endif + + run-test-$1: + $$(call LogWarn) + $$(call LogWarn, Running test '$$($1_TEST)') + $$(call MakeDir, $$($1_TEST_RESULTS_DIR) $$($1_TEST_SUPPORT_DIR)) + $$(call ExecuteWithLog, $$($1_TEST_SUPPORT_DIR)/gtest, \ + $$(FIXPATH) $$(TEST_IMAGE_DIR)/hotspot/gtest/server/gtestLauncher \ + -jdk $(JDK_IMAGE_DIR) $$($1_GTEST_FILTER) \ + --gtest_output=xml:$$($1_TEST_RESULTS_DIR)/gtest.xml \ + $$($1_GTEST_REPEAT) $$(GTEST_OPTIONS) \ + > >($(TEE) $$($1_TEST_RESULTS_DIR)/gtest.txt) || true ) + + $1_RESULT_FILE := $$($1_TEST_RESULTS_DIR)/gtest.txt + + parse-test-$1: run-test-$1 + $$(call LogWarn, Finished running test '$$($1_TEST)') + $$(call LogWarn, Test report is stored in $$(strip \ + $$(subst $$(TOPDIR)/, , $$($1_TEST_RESULTS_DIR)))) + $$(eval $1_TOTAL := $$(shell $$(AWK) '/==========.* tests? from .* \ + test cases? ran/ { print $$$$2 }' $$($1_RESULT_FILE))) + $$(eval $1_PASSED := $$(shell $$(AWK) '/\[ PASSED \] .* tests?./ \ + { print $$$$4 }' $$($1_RESULT_FILE))) + $$(eval $1_FAILED := $$(shell $$(AWK) '/\[ FAILED \] .* tests?, \ + listed below/ { print $$$$4 }' $$($1_RESULT_FILE))) + $$(if $$($1_FAILED), , $$(eval $1_FAILED := 0)) + $$(eval $1_ERROR := $$(shell \ + $$(EXPR) $$($1_TOTAL) - $$($1_PASSED) - $$($1_FAILED))) + + $1: run-test-$1 parse-test-$1 + + TARGETS += $1 +endef + +################################################################################ + +### Rules for Jtreg + +# Helper function for SetupRunJtregTest. Set a JTREG_* variable from, in order: +# 1) Specified by user on command line +# 2) Component-specific default +# 3) Generic default +# +# Note: No spaces are allowed around the arguments. +# Arg $1 The test ID (i.e. $1 in SetupRunJtregTest) +# Arg $2 Base variable, e.g. JTREG_JOBS +# Arg $3 The default value (optional) +define SetJtregValue + ifneq ($$($2), ) + $1_$2 := $$($2) + else + ifneq ($$($$($1_COMPONENT)_$2), ) + $1_$2 := $$($$($1_COMPONENT)_$2) + else + ifneq ($3, ) + $1_$2 := $3 + endif + endif + endif +endef + +SetupRunJtregTest = $(NamedParamsMacroTemplate) +define SetupRunJtregTestBody + $1_TEST_RESULTS_DIR := $$(TEST_RESULTS_DIR)/$1 + $1_TEST_SUPPORT_DIR := $$(TEST_SUPPORT_DIR)/$1 + + $1_TEST_NAME := $$(strip $$(patsubst jtreg:%, %, $$($1_TEST))) + $1_COMPONENT := $$(firstword $$(subst /, $$(SPACE), $$($1_TEST_NAME))) + + ifeq ($$(JT_HOME), ) + $$(info Error: jtreg framework is not found.) + $$(info Please run configure using --with-jtreg.) + $$(error Cannot continue) + endif + + # Unfortunately, we need different defaults for some JTREG values, + # depending on what component we're running. + + # Convert JTREG_foo into $1_JTREG_foo with a suitable value. + $$(eval $$(call SetJtregValue,$1,JTREG_TEST_MODE,agentvm)) + $$(eval $$(call SetJtregValue,$1,JTREG_ASSERT,true)) + $$(eval $$(call SetJtregValue,$1,JTREG_MAX_MEM,512m)) + $$(eval $$(call SetJtregValue,$1,JTREG_NATIVEPATH)) + $$(eval $$(call SetJtregValue,$1,JTREG_BASIC_OPTIONS)) + + ifneq ($(TEST_JOBS), 0) + # User has specified TEST_JOBS, use that as fallback default + $$(eval $$(call SetJtregValue,$1,JTREG_JOBS,$$(TEST_JOBS))) + else + # Use JOBS as default (except for hotspot) + $$(eval $$(call SetJtregValue,$1,JTREG_JOBS,$$(JOBS))) + endif + + ifeq ($$(shell $$(EXPR) $$($1_JTREG_JOBS) \> 50), 1) + # Until CODETOOLS-7901892 is fixed, JTreg cannot handle more than 50 jobs + $1_JTREG_JOBS := 50 + endif + + # Make sure MaxRAMFraction is high enough to not cause OOM or swapping since + # we may end up with a lot of JVM's + $1_JTREG_MAX_RAM_FRACTION := $$(shell $$(EXPR) $$($1_JTREG_JOBS) \* 4) + + JTREG_TIMEOUT ?= 4 + JTREG_VERBOSE ?= fail,error,summary + JTREG_RETAIN ?= fail,error + + ifneq ($$($1_JTREG_MAX_MEM), 0) + $1_JTREG_BASIC_OPTIONS += -vmoption:-Xmx$$($1_JTREG_MAX_MEM) + $1_JTREG_LAUNCHER_OPTIONS += -Xmx$$($1_JTREG_MAX_MEM) + endif + + $1_JTREG_BASIC_OPTIONS += -$$($1_JTREG_TEST_MODE) \ + -verbose:$$(JTREG_VERBOSE) -retain:$$(JTREG_RETAIN) \ + -concurrency:$$($1_JTREG_JOBS) -timeoutFactor:$$(JTREG_TIMEOUT) \ + -vmoption:-XX:MaxRAMFraction=$$($1_JTREG_MAX_RAM_FRACTION) + + $1_JTREG_BASIC_OPTIONS += -automatic -keywords:\!ignore -ignore:quiet + + # Some tests needs to find a boot JDK using the JDK8_HOME variable. + $1_JTREG_BASIC_OPTIONS += -e:JDK8_HOME=$$(BOOT_JDK) + + $1_JTREG_BASIC_OPTIONS += \ + $$(addprefix -javaoption:, $$(JTREG_JAVA_OPTIONS)) \ + $$(addprefix -vmoption:, $$(JTREG_VM_OPTIONS)) \ + # + + ifeq ($$($1_JTREG_ASSERT), true) + $1_JTREG_BASIC_OPTIONS += -ea -esa + endif + + ifneq ($$($1_JTREG_NATIVEPATH), ) + $1_JTREG_BASIC_OPTIONS += -nativepath:$$($1_JTREG_NATIVEPATH) + endif + + run-test-$1: + $$(call LogWarn) + $$(call LogWarn, Running test '$$($1_TEST)') + $$(call MakeDir, $$($1_TEST_RESULTS_DIR) $$($1_TEST_SUPPORT_DIR)) + $$(call ExecuteWithLog, $$($1_TEST_SUPPORT_DIR)/jtreg, \ + $$(JAVA) $$($1_JTREG_LAUNCHER_OPTIONS) \ + -Dprogram=jtreg -jar $$(JT_HOME)/lib/jtreg.jar \ + $$($1_JTREG_BASIC_OPTIONS) \ + -testjdk:$$(JDK_IMAGE_DIR) \ + -dir:$$(TOPDIR) \ + -reportDir:$$($1_TEST_RESULTS_DIR) \ + -workDir:$$($1_TEST_SUPPORT_DIR) \ + $$(JTREG_OPTIONS) \ + $$($1_TEST_NAME) || true ) + + $1_RESULT_FILE := $$($1_TEST_RESULTS_DIR)/text/stats.txt + + parse-test-$1: run-test-$1 + $$(call LogWarn, Finished running test '$$($1_TEST)') + $$(call LogWarn, Test report is stored in $$(strip \ + $$(subst $$(TOPDIR)/, , $$($1_TEST_RESULTS_DIR)))) + $$(eval $1_PASSED := $$(shell $$(AWK) '{ gsub(/[,;]/, ""); \ + for (i=1; i<=NF; i++) { if ($$$$i == "passed:") \ + print $$$$(i+1) } }' $$($1_RESULT_FILE))) + $$(if $$($1_PASSED), , $$(eval $1_PASSED := 0)) + $$(eval $1_FAILED := $$(shell $$(AWK) '{gsub(/[,;]/, ""); \ + for (i=1; i<=NF; i++) { if ($$$$i == "failed:") \ + print $$$$(i+1) } }' $$($1_RESULT_FILE))) + $$(if $$($1_FAILED), , $$(eval $1_FAILED := 0)) + $$(eval $1_ERROR := $$(shell $$(AWK) '{gsub(/[,;]/, ""); \ + for (i=1; i<=NF; i++) { if ($$$$i == "error:") \ + print $$$$(i+1) } }' $$($1_RESULT_FILE))) + $$(if $$($1_ERROR), , $$(eval $1_ERROR := 0)) + $$(eval $1_TOTAL := $$(shell \ + $$(EXPR) $$($1_PASSED) + $$($1_FAILED) + $$($1_ERROR))) + + $1: run-test-$1 parse-test-$1 + + TARGETS += $1 +endef + + +################################################################################ +# Setup and execute make rules for all selected tests +################################################################################ + +# Helper function to determine which handler to use for the given test +UseGtestTestHandler = \ + $(if $(filter gtest:%, $1), true) + +UseJtregTestHandler = \ + $(if $(filter jtreg:%, $1), true) + +# Now process each test to run and setup a proper make rule +$(foreach test, $(TESTS_TO_RUN), \ + $(eval TEST_ID := $(shell $(ECHO) $(strip $(test)) | \ + $(TR) -cs '[a-z][A-Z][0-9]\n' '_')) \ + $(eval ALL_TEST_IDS += $(TEST_ID)) \ + $(if $(call UseCustomTestHandler, $(test)), \ + $(eval $(call SetupRunCustomTest, $(TEST_ID), \ + TEST := $(test), \ + )) \ + ) \ + $(if $(call UseGtestTestHandler, $(test)), \ + $(eval $(call SetupRunGtestTest, $(TEST_ID), \ + TEST := $(test), \ + )) \ + ) \ + $(if $(call UseJtregTestHandler, $(test)), \ + $(eval $(call SetupRunJtregTest, $(TEST_ID), \ + TEST := $(test), \ + )) \ + ) \ +) + +# Sort also removes duplicates, so if there is any we'll get fewer words. +ifneq ($(words $(ALL_TEST_IDS)), $(words $(sort $(ALL_TEST_IDS)))) + $(error Duplicate test specification) +endif + + +################################################################################ +# The main target for RunTests.gmk +################################################################################ + +# The SetupRun*Test functions have populated TARGETS. + +TEST_FAILURE := false + +run-test: $(TARGETS) + # Print a table of the result of all tests run and their result + $(ECHO) + $(ECHO) ============================== + $(ECHO) Test summary + $(ECHO) ============================== + $(PRINTF) "%2s %-49s %5s %5s %5s %5s %2s\n" " " TEST \ + TOTAL PASS FAIL ERROR " " + $(foreach test, $(TESTS_TO_RUN), \ + $(eval TEST_ID := $(shell $(ECHO) $(strip $(test)) | \ + $(TR) -cs '[a-z][A-Z][0-9]\n' '_')) \ + $(if $(filter $($(TEST_ID)_PASSED), $($(TEST_ID)_TOTAL)), \ + $(PRINTF) "%2s %-49s %5d %5d %5d %5d %2s\n" " " "$(test)" \ + $($(TEST_ID)_TOTAL) $($(TEST_ID)_PASSED) $($(TEST_ID)_FAILED) \ + $($(TEST_ID)_ERROR) " " $(NEWLINE) \ + , \ + $(PRINTF) "%2s %-49s %5d %5d %5d %5d %2s\n" ">>" "$(test)" \ + $($(TEST_ID)_TOTAL) $($(TEST_ID)_PASSED) $($(TEST_ID)_FAILED) \ + $($(TEST_ID)_ERROR) "<<" $(NEWLINE) \ + $(eval TEST_FAILURE := true) \ + ) \ + ) + $(ECHO) ============================== + $(if $(filter true, $(TEST_FAILURE)), \ + $(ECHO) TEST FAILURE $(NEWLINE) \ + $(TOUCH) $(MAKESUPPORT_OUTPUTDIR)/exit-with-error \ + , \ + $(ECHO) TEST SUCCESS \ + ) + $(ECHO) + +################################################################################ + +all: run-test + +.PHONY: default all run-test $(TARGETS) diff --git a/make/UpdateBuildDocs.gmk b/make/UpdateBuildDocs.gmk new file mode 100644 index 00000000000..e1008c42e93 --- /dev/null +++ b/make/UpdateBuildDocs.gmk @@ -0,0 +1,71 @@ +# +# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Oracle designates this +# particular file as subject to the "Classpath" exception as provided +# by Oracle in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. +# + +default: all + +include $(SPEC) +include MakeBase.gmk +include ProcessMarkdown.gmk + +################################################################################ +# This makefile updates the generated build html documentation. +# +################################################################################ + +ifeq ($(PANDOC), ) + $(info No pandoc executable was detected by configure) + $(error Cannot continue) +endif + +GLOBAL_SPECS_DEFAULT_CSS_FILE := $(JDK_TOPDIR)/make/data/docs-resources/specs/resources/jdk-default.css + +################################################################################ + +DOCS_DIR := $(TOPDIR)/common/doc + +$(eval $(call SetupProcessMarkdown, building, \ + FILES := $(DOCS_DIR)/building.md, \ + DEST := $(DOCS_DIR), \ + CSS := $(GLOBAL_SPECS_DEFAULT_CSS_FILE), \ +)) +TARGETS += $(building) + +$(eval $(call SetupProcessMarkdown, testing, \ + FILES := $(DOCS_DIR)/testing.md, \ + DEST := $(DOCS_DIR), \ + CSS := $(GLOBAL_SPECS_DEFAULT_CSS_FILE), \ + OPTIONS := --toc, \ +)) +TARGETS += $(testing) + +################################################################################ + +$(eval $(call IncludeCustomExtension, , UpdateBuildDocs.gmk)) + +################################################################################ + +all: $(TARGETS) + +.PHONY: all default diff --git a/make/common/FindTests.gmk b/make/common/FindTests.gmk new file mode 100644 index 00000000000..8394e546ac3 --- /dev/null +++ b/make/common/FindTests.gmk @@ -0,0 +1,77 @@ +# +# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Oracle designates this +# particular file as subject to the "Classpath" exception as provided +# by Oracle in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. +# + +ifndef _FIND_TESTS_GMK +_FIND_TESTS_GMK := 1 + +# Hook to include the corresponding custom file, if present. +$(eval $(call IncludeCustomExtension, , common/FindTests.gmk)) + +# JTREG_COMPONENTS might have been set by a custom extension +JTREG_COMPONENTS += hotspot jdk langtools nashorn jaxp + +################################################################################ +# Find the Jtreg test groups for the given component. +# +# Parameter 1 is the name of the component. This name is used as variable prefix. +# +# After this macro has been evaluated, the following variables are defined for +# the component: +# JTREG_TESTROOT - The path to the root of the test directory +# JTREG_GROUP_FILES - The file(s) containing the group definitions +# JTREG_TEST_GROUPS - The name of the test groups that the component defines +# +FindJtregGroups = $(NamedParamsMacroTemplate) +define FindJtregGroupsBody + $1_JTREG_TESTROOT := $$(TOPDIR)/$1/test + ifneq ($$(wildcard $$($1_JTREG_TESTROOT)), ) + $1_JTREG_GROUP_FILENAMES := $$(shell $$(SED) -n -e 's/\[\(.*\)\]/\1/g' \ + -e 's/^groups\w*=//p' $$($1_JTREG_TESTROOT)/TEST.ROOT) + $1_JTREG_GROUP_FILES := $$(addprefix $$($1_JTREG_TESTROOT)/, \ + $$($1_JTREG_GROUP_FILENAMES)) + $1_JTREG_TEST_GROUPS := $$(strip $$(shell $$(SED) -n \ + -e 's/\([^ ]*\)\w*=.*/\1/gp' $$(wildcard $$($1_JTREG_GROUP_FILES)) \ + | $$(SORT) -u)) + endif +endef + +# Configure definitions for all available test components +$(foreach component, $(JTREG_COMPONENTS), \ + $(eval $(call FindJtregGroups, $(component)))) + +# Create a list of all available Jtreg test groups in all components +JTREG_TEST_GROUPS += $(sort $(foreach component, $(JTREG_COMPONENTS), \ + $($(component)_JTREG_TEST_GROUPS))) + +# Add Jtreg test groups to list of named tests (test groups, test list, etc) +# ALL_NAMED_TESTS might have been set by a custom extension +ALL_NAMED_TESTS += $(JTREG_TEST_GROUPS) + +# Add Gtest +ALL_NAMED_TESTS += gtest + +################################################################################ + +endif # _FIND_TESTS_GMK diff --git a/make/common/MakeBase.gmk b/make/common/MakeBase.gmk index dce01ffa060..3a8a900321d 100644 --- a/make/common/MakeBase.gmk +++ b/make/common/MakeBase.gmk @@ -355,17 +355,28 @@ FindAllReposRel = \ ################################################################################ define SetupLogging + ifeq ($$(LOG_PROFILE_TIMES_FILE), true) + ifeq ($$(IS_GNU_TIME), yes) + SHELL := $$(BASH) $$(SRC_ROOT)/common/bin/shell-profiler.sh \ + gnutime $$(TIME) \ + $$(OUTPUT_ROOT)/build-profile.log $$(SHELL) + else ifneq ($$(FLOCK), ) + SHELL := $$(BASH) $$(SRC_ROOT)/common/bin/shell-profiler.sh \ + flock $$(FLOCK) \ + $$(OUTPUT_ROOT)/build-profile.log $$(SHELL) + endif + endif + ifeq ($$(LOG_LEVEL), trace) + SHELL_NO_RECURSE := $$(SHELL) # Shell redefinition trick inspired by http://www.cmcrossroads.com/ask-mr-make/6535-tracing-rule-execution-in-gnu-make # For each target executed, will print # Building (from ) ( newer) # but with a limit of 20 on , to avoid cluttering logs too much # (and causing a crash on Cygwin). - # Default shell seems to always be /bin/sh. Must override with bash to get this to work on Solaris. - # Only use time if it's GNU time which supports format and output file. - WRAPPER_SHELL := $$(BASH) $$(SRC_ROOT)/common/bin/shell-tracer.sh $$(if $$(findstring yes,$$(IS_GNU_TIME)),$$(TIME),-) $$(OUTPUT_ROOT)/build-trace-time.log $$(SHELL) - SHELL = $$(warning $$(if $$@,Building $$@,Running shell command) $$(if $$<, (from $$<))$$(if $$?, ($$(wordlist 1, 20, $$?) $$(if $$(wordlist 21, 22, $$?), ... [in total $$(words $$?) files]) newer)))$$(WRAPPER_SHELL) + SHELL = $$(warning $$(if $$@,Building $$@,Running shell command) $$(if $$<, (from $$<))$$(if $$?, ($$(wordlist 1, 20, $$?) $$(if $$(wordlist 21, 22, $$?), ... [in total $$(words $$?) files]) newer)))$$(SHELL_NO_RECURSE) -x endif + # The warn level can never be turned off LogWarn = $$(info $$(strip $$1)) LOG_WARN := @@ -672,9 +683,9 @@ ifneq ($(DISABLE_CACHE_FIND), true) # Param 1 - Dirs to find in # Param 2 - (optional) specialization. Normally "-a \( ... \)" expression. define CacheFind - $(if $(filter-out $(addsuffix /%,- $(FIND_CACHE_DIRS)) $(FIND_CACHE_DIRS),$1), \ - $(shell $(FIND) $1 \( -type f -o -type l \) $2), \ - $(filter $(addsuffix /%,$(patsubst %/,%,$1)) $1,$(FIND_CACHE))) + $(if $(filter-out $(addsuffix /%,- $(FIND_CACHE_DIRS)) $(FIND_CACHE_DIRS),$1), \ + $(if $(wildcard $1), $(shell $(FIND) $1 \( -type f -o -type l \) $2)), \ + $(filter $(addsuffix /%,$(patsubst %/,%,$1)) $1,$(FIND_CACHE))) endef else @@ -754,6 +765,55 @@ define SetupCopyFilesBody endef +################################################################################ +# Parse a multiple-keyword variable, like FOO="KEYWORD1=val1;KEYWORD2=val2;..." +# These will be converted into a series of variables like FOO_KEYWORD1=val1, +# FOO_KEYWORD2=val2, etc. Unknown keywords will cause an error. +# +# Parameter 1 is the name of the rule, and is also the name of the variable. +# +# Remaining parameters are named arguments. These include: +# KEYWORDS A list of valid keywords +# STRING_KEYWORDS A list of valid keywords, processed as string. This means +# that '%20' will be replaced by ' ' to allow for multi-word strings. +# +ParseKeywordVariable = $(NamedParamsMacroTemplate) +define ParseKeywordVariableBody + ifneq ($$($1), ) + # To preserve spaces, substitute them with a hopefully unique pattern + # before splitting and then re-substitute spaces back. + $1_MANGLED := $$(subst $$(SPACE),||||,$$($1)) + $$(foreach mangled_part, $$(subst ;, , $$($1_MANGLED)), \ + $$(eval mangled_part_eval := $$(call DoubleDollar, $$(mangled_part))) \ + $$(eval part := $$$$(subst ||||,$$$$(SPACE),$$$$(mangled_part_eval))) \ + $$(eval $1_NO_MATCH := true) \ + $$(foreach keyword, $$($1_KEYWORDS), \ + $$(eval keyword_eval := $$(call DoubleDollar, $$(keyword))) \ + $$(if $$(filter $$(keyword)=%, $$(part)), \ + $$(eval $(strip $1)_$$$$(keyword_eval) := $$$$(strip $$$$(patsubst $$$$(keyword_eval)=%, %, $$$$(part)))) \ + $$(eval $1_NO_MATCH := ) \ + ) \ + ) \ + $$(foreach keyword, $$($1_STRING_KEYWORDS), \ + $$(eval keyword_eval := $$(call DoubleDollar, $$(keyword))) \ + $$(if $$(filter $$(keyword)=%, $$(part)), \ + $$(eval $(strip $1)_$$$$(keyword_eval) := $$$$(strip $$$$(subst %20, , $$$$(patsubst $$$$(keyword_eval)=%, %, $$$$(part))))) \ + $$(eval $1_NO_MATCH := ) \ + ) \ + ) \ + $$(if $$($1_NO_MATCH), \ + $$(if $$(filter $$(part), $$($1_KEYWORDS) $$($1_STRING_KEYWORDS)), \ + $$(info Keyword $$(part) for $1 needs to be assigned a value.) \ + , \ + $$(info $$(part) is not a valid keyword for $1.) \ + $$(info Valid keywords: $$($1_KEYWORDS) $$($1_STRING_KEYWORDS).) \ + ) \ + $$(error Cannot continue) \ + ) \ + ) + endif +endef + ################################################################################ # ShellQuote # @@ -763,6 +823,22 @@ endef ShellQuote = \ $(SQUOTE)$(subst $(SQUOTE),$(SQUOTE)\$(SQUOTE)$(SQUOTE),$(strip $1))$(SQUOTE) +################################################################################ +# FixPath +# +# On Windows, converts a path from cygwin/unix style (e.g. /bin/foo) into +# "mixed mode" (e.g. c:/cygwin/bin/foo). On other platforms, return the path +# unchanged. +# This is normally not needed since we use the FIXPATH prefix for command lines, +# but might be needed in certain circumstances. +ifeq ($(OPENJDK_TARGET_OS), windows) + FixPath = \ + $(shell $(CYGPATH) -m $1) +else + FixPath = \ + $1 +endif + ################################################################################ # Write to and read from file @@ -901,6 +977,17 @@ CommaList = \ $(subst $(COMMA)$(COMMA),$(COMMA),$(subst $(SPACE),$(COMMA),$(strip $1))) \ ) +################################################################################ +# Converts a space separated list to a colon separated list. +# +# Replacing double-colon with a single colon is to workaround the issue with +# some version of make on windows that doesn't substitute spaces with one colon +# properly. +ColonList = \ + $(strip \ + $(subst ::,:,$(subst $(SPACE),:,$(strip $1))) \ + ) + ################################################################################ # Hook to include the corresponding custom file, if present. diff --git a/make/common/Modules.gmk b/make/common/Modules.gmk index 4ceb4513623..d65adcd6aef 100644 --- a/make/common/Modules.gmk +++ b/make/common/Modules.gmk @@ -40,6 +40,7 @@ PLATFORM_MODULES := JRE_TOOL_MODULES := UPGRADEABLE_MODULES := AGGREGATOR_MODULES := +DOCS_MODULES := # Hook to include the corresponding custom file, if present. $(eval $(call IncludeCustomExtension, , common/Modules.gmk)) @@ -58,12 +59,12 @@ BOOT_MODULES += \ java.security.sasl \ java.xml \ jdk.httpserver \ + jdk.internal.vm.ci \ jdk.management \ jdk.management.agent \ jdk.net \ jdk.sctp \ jdk.unsupported \ - jdk.vm.ci \ # # to be deprivileged @@ -78,11 +79,14 @@ UPGRADEABLE_MODULES += \ java.xml.bind \ java.xml.ws \ java.xml.ws.annotation \ + jdk.internal.vm.compiler \ # # Modules explicitly declared as not being upgradeable even though they require # an upgradeable module. -NON_UPGRADEABLE_MODULES += +NON_UPGRADEABLE_MODULES += \ + jdk.aot \ + # AGGREGATOR_MODULES += \ java.se \ @@ -96,7 +100,6 @@ PLATFORM_MODULES += \ PLATFORM_MODULES += \ java.compiler \ - jdk.incubator.httpclient \ java.scripting \ java.security.jgss \ java.smartcardio \ @@ -105,10 +108,10 @@ PLATFORM_MODULES += \ java.xml.crypto \ jdk.accessibility \ jdk.charsets \ - jdk.crypto.ec \ jdk.crypto.cryptoki \ - jdk.desktop \ + jdk.crypto.ec \ jdk.dynalink \ + jdk.incubator.httpclient \ jdk.jsobject \ jdk.localedata \ jdk.naming.dns \ @@ -119,18 +122,65 @@ PLATFORM_MODULES += \ jdk.zipfs \ # +ifeq ($(OPENJDK_TARGET_OS), windows) + PLATFORM_MODULES += jdk.crypto.mscapi +endif + +ifeq ($(OPENJDK_TARGET_OS), solaris) + PLATFORM_MODULES += jdk.crypto.ucrypto +endif + JRE_TOOL_MODULES += \ jdk.jdwp.agent \ jdk.pack \ jdk.scripting.nashorn.shell \ # -ifeq ($(OPENJDK_TARGET_OS), windows) - PLATFORM_MODULES += jdk.crypto.mscapi -endif -ifeq ($(OPENJDK_TARGET_OS), solaris) - PLATFORM_MODULES += jdk.crypto.ucrypto -endif +################################################################################ + +# DOCS_MODULES defines the root modules for javadoc generation. +# All of their `require transitive` modules directly and indirectly will be included. +DOCS_MODULES += \ + java.se.ee \ + java.smartcardio \ + jdk.accessibility \ + jdk.attach \ + jdk.charsets \ + jdk.compiler \ + jdk.crypto.cryptoki \ + jdk.crypto.ec \ + jdk.dynalink \ + jdk.editpad \ + jdk.hotspot.agent \ + jdk.httpserver \ + jdk.incubator.httpclient \ + jdk.jartool \ + jdk.javadoc \ + jdk.jcmd \ + jdk.jconsole \ + jdk.jdeps \ + jdk.jdi \ + jdk.jdwp.agent \ + jdk.jlink \ + jdk.jsobject \ + jdk.jshell \ + jdk.jstatd \ + jdk.localedata \ + jdk.management \ + jdk.management.agent \ + jdk.naming.dns \ + jdk.naming.rmi \ + jdk.net \ + jdk.pack \ + jdk.policytool \ + jdk.rmic \ + jdk.scripting.nashorn \ + jdk.sctp \ + jdk.security.auth \ + jdk.security.jgss \ + jdk.xml.dom \ + jdk.zipfs \ + # # These modules are included in the interim image which is used to run profiling # before building the real images. @@ -147,7 +197,7 @@ endif # Filter out Graal specific modules if Graal build is disabled ifeq ($(INCLUDE_GRAAL), false) - MODULES_FILTER += jdk.vm.compiler + MODULES_FILTER += jdk.internal.vm.compiler endif ################################################################################ @@ -182,6 +232,8 @@ ifneq ($(OPENJDK_TARGET_OS), $(OPENJDK_TARGET_OS_TYPE)) endif SRC_SUBDIRS += share/classes +SPEC_SUBDIRS += share/specs + # Find all module-info.java files for the current build target platform and # configuration. # Param 1 - Module to find for, set to * for finding all @@ -234,6 +286,12 @@ FindModuleSrcDirs = \ $(addsuffix /$(strip $1), $(GENERATED_SRC_DIRS) $(IMPORT_MODULES_SRC)) \ $(foreach sub, $(SRC_SUBDIRS), $(addsuffix /$(strip $1)/$(sub), $(TOP_SRC_DIRS))))) +# Find all specs dirs for a particular module +# $1 - Module to find specs dirs for +FindModuleSpecsDirs = \ + $(strip $(wildcard \ + $(foreach sub, $(SPEC_SUBDIRS), $(addsuffix /$(strip $1)/$(sub), $(TOP_SRC_DIRS))))) + # Construct the complete module source path GetModuleSrcPath = \ $(call PathList, \ @@ -241,7 +299,8 @@ GetModuleSrcPath = \ $(foreach sub, $(SRC_SUBDIRS), $(addsuffix /*/$(sub), $(TOP_SRC_DIRS)))) ################################################################################ -# Extract module dependencies from module-info.java files. +# Extract module dependencies from module-info.java files, both normal +# dependencies ("requires"), and indirect exports ("requires transitive"). MODULE_DEPS_MAKEFILE := $(MAKESUPPORT_OUTPUTDIR)/module-deps.gmk @@ -255,25 +314,39 @@ $(MODULE_DEPS_MAKEFILE): $(MODULE_INFOS) \ ( $(PRINTF) "DEPS_$(call GetModuleNameFromModuleInfo, $m) :=" && \ $(NAWK) -v MODULE=$(call GetModuleNameFromModuleInfo, $m) '\ BEGIN { if (MODULE != "java.base") printf(" java.base"); } \ - /requires/ { sub(/;/, ""); \ - sub(/requires/, ""); \ - sub(/transitive/, ""); \ - sub(/\/\/.*/, ""); \ - sub(/\/\*.*\*\//, ""); \ - gsub(/^ +\*.*/, ""); \ - gsub(/ /, ""); \ - printf(" %s", $$0) } \ - END { printf("\n") }' $m \ + /^ *requires/ { sub(/;/, ""); \ + sub(/requires/, ""); \ + sub(/transitive/, ""); \ + sub(/\/\/.*/, ""); \ + sub(/\/\*.*\*\//, ""); \ + gsub(/^ +\*.*/, ""); \ + gsub(/ /, ""); \ + printf(" %s", $$0) } \ + END { printf("\n") }' $m && \ + $(PRINTF) "TRANSITIVE_MODULES_$(call GetModuleNameFromModuleInfo, $m) :=" && \ + $(NAWK) -v MODULE=$(call GetModuleNameFromModuleInfo, $m) '\ + BEGIN { if (MODULE != "java.base") printf(" java.base"); } \ + /^ *requires *transitive/ { \ + sub(/;/, ""); \ + sub(/requires/, ""); \ + sub(/transitive/, ""); \ + sub(/\/\/.*/, ""); \ + sub(/\/\*.*\*\//, ""); \ + gsub(/^ +\*.*/, ""); \ + gsub(/ /, ""); \ + printf(" %s", $$0) } \ + END { printf("\n") }' $m \ ) >> $@ $(NEWLINE)) -include $(MODULE_DEPS_MAKEFILE) -# Param 1: Module to find deps for +# Find dependencies ("requires") for a given module. +# Param 1: Module to find dependencies for. FindDepsForModule = \ $(DEPS_$(strip $1)) -# Finds transitive dependencies in 3 levels. -# Param 1: Module to find transitive deps for +# Find dependencies ("requires") transitively in 3 levels for a given module. +# Param 1: Module to find dependencies for. FindTransitiveDepsForModule = \ $(sort $(call FindDepsForModule, $1) \ $(foreach m, $(call FindDepsForModule, $1), \ @@ -281,6 +354,30 @@ FindTransitiveDepsForModule = \ $(foreach n, $(call FindDepsForModule, $m), \ $(call FindDepsForModule, $n)))) +# Find dependencies ("requires") transitively in 3 levels for a set of modules. +# Param 1: List of modules to find dependencies for. +FindTransitiveDepsForModules = \ + $(sort $(foreach m, $1, $(call FindTransitiveDepsForModule, $m))) + +# Find indirect exported modules ("requires transitive") for a given module . +# Param 1: Module to find indirect exported modules for. +FindIndirectExportsForModule = \ + $(TRANSITIVE_MODULES_$(strip $1)) + +# Finds indirect exported modules transitively in 3 levels for a given module. +# Param 1: Module to find indirect exported modules for. +FindTransitiveIndirectDepsForModule = \ + $(sort $(call FindIndirectExportsForModule, $1) \ + $(foreach m, $(call FindIndirectExportsForModule, $1), \ + $(call FindIndirectExportsForModule, $m) \ + $(foreach n, $(call FindIndirectExportsForModule, $m), \ + $(call FindIndirectExportsForModule, $n)))) + +# Finds indirect exported modules transitively in 3 levels for a set of modules. +# Param 1: List of modules to find indirect exported modules for. +FindTransitiveIndirectDepsForModules = \ + $(sort $(foreach m, $1, $(call FindTransitiveIndirectDepsForModule, $m))) + # Upgradeable modules are those that are either defined as upgradeable or that # require an upradeable module. FindAllUpgradeableModules = \ @@ -329,6 +426,10 @@ define ReadSingleImportMetaData else ifeq ($$(classloader), ext) PLATFORM_MODULES += $1 endif + ifneq ($$(include_in_docs), false) + # defaults to true if unspecified + DOCS_MODULES += $1 + endif else # Default to include in all JRE_MODULES += $1 diff --git a/make/common/NativeCompilation.gmk b/make/common/NativeCompilation.gmk index ae0cc2068de..28911884d04 100644 --- a/make/common/NativeCompilation.gmk +++ b/make/common/NativeCompilation.gmk @@ -165,6 +165,7 @@ endif WINDOWS_SHOWINCLUDE_SED_PATTERN := \ -e '/^Note: including file:/!d' \ -e 's|Note: including file: *||' \ + -e 's|\r||g' \ -e 's|\\|/|g' \ -e 's|^\([a-zA-Z]\):|$(UNIX_PATH_PREFIX)/\1|g' \ -e '\|$(TOPDIR)|I !d' \ diff --git a/make/common/ProcessMarkdown.gmk b/make/common/ProcessMarkdown.gmk new file mode 100644 index 00000000000..fe4d30e75cf --- /dev/null +++ b/make/common/ProcessMarkdown.gmk @@ -0,0 +1,103 @@ +# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Oracle designates this +# particular file as subject to the "Classpath" exception as provided +# by Oracle in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. +# + +ifeq (,$(_MAKEBASE_GMK)) + $(error You must include MakeBase.gmk prior to including ProcessMarkdown.gmk) +endif + +# Helper function for SetupProcessMarkdown +# $1: The $1 from SetupProcessMarkdown +# $2: The name of the current source file, relative to $1_SRC +define ProcessMarkdown + $1_$2_OUTPUT_FILE := $$($1_DEST)/$$(basename $2).html + $1_$2_TARGET_DIR := $$(dir $$($1_$2_OUTPUT_FILE)) + ifneq ($$($1_CSS), ) + ifneq ($$(findstring http:/, $$($1_CSS)), ) + $1_$2_CSS_OPTION := --css '$$($1_CSS)' + else + $1_$2_CSS := $$(strip $$(call RelativePath, $$($1_CSS), $$($1_$2_TARGET_DIR))) + $1_$2_CSS_OPTION := --css '$$($1_$2_CSS)' + endif + endif + $1_$2_OPTIONS = $$(shell $$(GREP) _pandoc-options_: $$($1_SRC)/$2 | $$(CUT) -d : -f 2-) + $1_$2_MARKER := $$(subst /,_,$1_$2) + + $1_$2_VARDEPS := $$($1_OPTIONS) $$($1_CSS) + $1_$2_VARDEPS_FILE := $$(call DependOnVariable, $1_$2_VARDEPS, \ + $$(SUPPORT_OUTPUTDIR)/markdown/$$($1_$2_MARKER).vardeps) + +$$($1_$2_OUTPUT_FILE): $$($1_SRC)/$2 $$($1_$2_VARDEPS_FILE) + $$(call LogInfo, Converting $2 to html) + $$(call MakeDir, $$($1_$2_TARGET_DIR) $$(SUPPORT_OUTPUTDIR)/markdown) + $$(call ExecuteWithLog, $$(SUPPORT_OUTPUTDIR)/markdown/$$($1_$2_MARKER), \ + $$(PANDOC) $$($1_OPTIONS) -f markdown -t html5 --standalone \ + $$($1_$2_CSS_OPTION) $$($1_$2_OPTIONS) '$$<' -o '$$@') + ifneq ($$(findstring $$(LOG_LEVEL), debug trace),) + TOO_LONG_LINES=`$$(GREP) -E -e '^.{80}.+$$$$' $$<` || true ; \ + if [ "x$$$$TOO_LONG_LINES" != x ]; then \ + $$(ECHO) "Warning: Unsuitable markdown in $$<:" ; \ + $$(ECHO) "The following lines are longer than 80 characters:" ; \ + $$(GREP) -E -n -e '^.{80}.+$$$$' $$< || true ; \ + fi + endif + + $1 += $$($1_$2_OUTPUT_FILE) +endef + +################################################################################ +# Setup make rules for converting a markdown file to html. +# +# Parameter 1 is the name of the rule. This name is used as variable prefix, +# and the targets generated are listed in a variable by that name. +# +# Remaining parameters are named arguments. These include: +# SRC : Source root dir (defaults to dir of first file) +# DEST : Dest root dir +# FILES : List of files to copy with absolute paths, or path relative to SRC. +# Must be in SRC. +# OPTIONS : Additional options to pandoc +# +SetupProcessMarkdown = $(NamedParamsMacroTemplate) +define SetupProcessMarkdownBody + ifeq ($$($1_FILES), ) + $$(error FILES is missing in SetupProcessMarkdown $1) + endif + + ifeq ($$($1_DEST), ) + $$(error DEST is missing in SetupProcessMarkdown $1) + endif + + # Default SRC to the dir of the first file. + ifeq ($$($1_SRC), ) + $1_SRC := $$(dir $$(firstword $$($1_FILES))) + endif + + # Remove any trailing slash from SRC and DEST + $1_SRC := $$(patsubst %/,%,$$($1_SRC)) + $1_DEST := $$(patsubst %/,%,$$($1_DEST)) + + $$(foreach f, $$(patsubst $$($1_SRC)/%,%,$$($1_FILES)), \ + $$(eval $$(call ProcessMarkdown,$1,$$f)) \ + ) +endef diff --git a/make/common/SetupJavaCompilers.gmk b/make/common/SetupJavaCompilers.gmk index 5ac4b86fe23..f38d2f56360 100644 --- a/make/common/SetupJavaCompilers.gmk +++ b/make/common/SetupJavaCompilers.gmk @@ -32,7 +32,7 @@ DISABLE_WARNINGS := -Xlint:all,-deprecation,-removal,-unchecked,-rawtypes,-cast, # If warnings needs to be non-fatal for testing purposes use a command like: # make JAVAC_WARNINGS="-Xlint:all -Xmaxwarns 10000" -JAVAC_WARNINGS := -Xlint:all,-removal -Werror +JAVAC_WARNINGS := -Xlint:all -Werror # The BOOT_JAVAC setup uses the boot jdk compiler to compile the tools # and the interim javac, to be run by the boot jdk. @@ -69,7 +69,7 @@ $(eval $(call SetupJavaCompiler,GENERATE_OLDBYTECODE, \ $(eval $(call SetupJavaCompiler,GENERATE_JDKBYTECODE, \ JVM := $(JAVA_JAVAC), \ JAVAC := $(NEW_JAVAC), \ - FLAGS := -source 9 -target 9 \ + FLAGS := -source 10 -target 10 --doclint-format html5 \ -encoding ascii -XDignore.symbol.file=true $(JAVAC_WARNINGS), \ SERVER_DIR := $(SJAVAC_SERVER_DIR), \ SERVER_JVM := $(SJAVAC_SERVER_JAVA))) @@ -79,7 +79,7 @@ $(eval $(call SetupJavaCompiler,GENERATE_JDKBYTECODE, \ $(eval $(call SetupJavaCompiler,GENERATE_JDKBYTECODE_NOWARNINGS, \ JVM := $(JAVA_JAVAC), \ JAVAC := $(NEW_JAVAC), \ - FLAGS := -source 9 -target 9 \ + FLAGS := -source 10 -target 10 \ -encoding ascii -XDignore.symbol.file=true $(DISABLE_WARNINGS), \ SERVER_DIR := $(SJAVAC_SERVER_DIR), \ SERVER_JVM := $(SJAVAC_SERVER_JAVA))) diff --git a/make/devkit/createGraphvizBundle.sh b/make/devkit/createGraphvizBundle.sh new file mode 100644 index 00000000000..290e68c382c --- /dev/null +++ b/make/devkit/createGraphvizBundle.sh @@ -0,0 +1,63 @@ +#!/bin/bash -e +# +# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Oracle designates this +# particular file as subject to the "Classpath" exception as provided +# by Oracle in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. +# +# Create a bundle in the current directory, containing what's needed to run +# the 'dot' program from the graphviz suite by the OpenJDK build. + +TMPDIR=`mktemp -d -t graphvizbundle-XXXX` +trap "rm -rf \"$TMPDIR\"" EXIT + +ORIG_DIR=`pwd` +cd "$TMPDIR" +GRAPHVIZ_VERSION=2.38.0-1 +PACKAGE_VERSION=1.1 +TARGET_PLATFORM=linux_x64 +BUNDLE_NAME=graphviz-$TARGET_PLATFORM-$GRAPHVIZ_VERSION+$PACKAGE_VERSION.tar.gz +wget http://www.graphviz.org/pub/graphviz/stable/redhat/el6/x86_64/os/graphviz-$GRAPHVIZ_VERSION.el6.x86_64.rpm +wget http://www.graphviz.org/pub/graphviz/stable/redhat/el6/x86_64/os/graphviz-libs-$GRAPHVIZ_VERSION.el6.x86_64.rpm +wget http://www.graphviz.org/pub/graphviz/stable/redhat/el6/x86_64/os/graphviz-plugins-core-$GRAPHVIZ_VERSION.el6.x86_64.rpm +wget http://www.graphviz.org/pub/graphviz/stable/redhat/el6/x86_64/os/graphviz-plugins-x-$GRAPHVIZ_VERSION.el6.x86_64.rpm +wget http://public-yum.oracle.com/repo/OracleLinux/OL6/latest/x86_64/getPackage/libtool-ltdl-2.2.6-15.5.el6.x86_64.rpm + +mkdir graphviz +cd graphviz +for rpm in ../*.rpm; do + rpm2cpio $rpm | cpio --extract --make-directories +done + +cat > dot << EOF +#!/bin/bash +# Get an absolute path to this script +this_script_dir=\`dirname \$0\` +this_script_dir=\`cd \$this_script_dir > /dev/null && pwd\` +export LD_LIBRARY_PATH="\$this_script_dir/usr/lib64:\$LD_LIBRARY_PATH" +exec \$this_script_dir/usr/bin/dot "\$@" +EOF +chmod +x dot +export LD_LIBRARY_PATH="$TMPDIR/graphviz/usr/lib64:$LD_LIBRARY_PATH" +# create config file +./dot -c +tar -cvzf ../$BUNDLE_NAME * +cp ../$BUNDLE_NAME "$ORIG_DIR" diff --git a/make/devkit/createPandocBundle.sh b/make/devkit/createPandocBundle.sh new file mode 100644 index 00000000000..0badfa8ffda --- /dev/null +++ b/make/devkit/createPandocBundle.sh @@ -0,0 +1,73 @@ +#!/bin/bash -e +# +# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Oracle designates this +# particular file as subject to the "Classpath" exception as provided +# by Oracle in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA +# or visit www.oracle.com if you need additional information or have any +# questions. +# +# Create a bundle in the current directory, containing what's needed to run +# the 'pandoc' program by the OpenJDK build. + +TMPDIR=`mktemp -d -t pandocbundle-XXXX` +trap "rm -rf \"$TMPDIR\"" EXIT + +ORIG_DIR=`pwd` +cd "$TMPDIR" +PANDOC_VERSION=1.17.2 +FULL_PANDOC_VERSION=1.17.2-1 +PACKAGE_VERSION=1.0 +TARGET_PLATFORM=linux_x64 +BUNDLE_NAME=pandoc-$TARGET_PLATFORM-$PANDOC_VERSION+$PACKAGE_VERSION.tar.gz + +wget https://github.com/jgm/pandoc/releases/download/$PANDOC_VERSION/pandoc-$FULL_PANDOC_VERSION-amd64.deb + +mkdir pandoc +cd pandoc +ar p ../pandoc-$FULL_PANDOC_VERSION-amd64.deb data.tar.gz | tar xz +cd .. + +# Pandoc depends on libgmp.so.10, which in turn depends on libc. No readily +# available precompiled binaries exists which match the requirement of +# support for older linuxes (glibc 2.12), so we'll compile it ourselves. + +LIBGMP_VERSION=6.1.2 + +wget https://gmplib.org/download/gmp/gmp-$LIBGMP_VERSION.tar.xz +mkdir gmp +cd gmp +tar xf ../gmp-$LIBGMP_VERSION.tar.xz +cd gmp-$LIBGMP_VERSION +./configure --prefix=$TMPDIR/pandoc/usr +make +make install +cd ../.. + +cat > pandoc/pandoc << EOF +#!/bin/bash +# Get an absolute path to this script +this_script_dir=\`dirname \$0\` +this_script_dir=\`cd \$this_script_dir > /dev/null && pwd\` +export LD_LIBRARY_PATH="\$this_script_dir/usr/lib:\$LD_LIBRARY_PATH" +exec \$this_script_dir/usr/bin/pandoc "\$@" +EOF +chmod +x pandoc/pandoc +tar -cvzf ../$BUNDLE_NAME pandoc +cp ../$BUNDLE_NAME "$ORIG_DIR" diff --git a/nashorn/.hgtags b/nashorn/.hgtags index 22c28403722..93dd2eb3c38 100644 --- a/nashorn/.hgtags +++ b/nashorn/.hgtags @@ -387,5 +387,35 @@ ace1d994bca775d6545a4c874ae73d1dfc9ec18b jdk-9+150 2a0437036a64853334e538044eb68d2df70075fa jdk-9+151 ddc52e72757086a75a54371e8e7f56a3f89f1e55 jdk-9+152 19aaaf2d02b7d6986538cd9a8c46901ecb50eebf jdk-9+153 +a84b49cfee63716975535abae2865ffef4dd6474 jdk-10+0 a84b49cfee63716975535abae2865ffef4dd6474 jdk-9+154 f9bb37a817b3cd3b758a60f3c68258a6554eb382 jdk-9+155 +d577398d31111be4bdaa08008247cf4242eaea94 jdk-9+156 +ac893c3a86ddeda4bed2573037175a2913ec570e jdk-10+1 +f6070efba6af0dc003e24ca736426c93e99ee96a jdk-9+157 +13ae2480a4c395026b3aa1739e0f9895dc8b25d9 jdk-9+158 +d75af059cff651c1b5cccfeb4c9ea8d054b28cfd jdk-9+159 +9d4dbb8cbe7ce321c6e9e34dc9e0974760710907 jdk-9+160 +d6ef419af865dccf1e5be8047b0aba09286ffa93 jdk-9+161 +2cd29b339692524de64d049b329873facaff9727 jdk-9+162 +5e5e436543daea0c174d878d5e3ff8dd791e538a jdk-9+163 +b473fab09baab51a06ffba02eb06c7f5ee8578f7 jdk-9+164 +e36e62d3ea53c316f295b37bcc19867fbf510235 jdk-9+165 +5b2e7b2101c0048ba9f1df722e56611f523fdfe8 jdk-9+166 +47277bbced66869e17899eee7ac197b78a5c69b8 jdk-10+2 +a76a5e1c9d0b94541826e2121f5754aaa78f0376 jdk-10+3 +e6bc0ad505e65c884a66c42cc92b24371ccf971d jdk-10+4 +59278e0c6ccd7cc6d2427c29e8c3446fc2af0e26 jdk-10+5 +0c5f25cc0d1b89664d1517a256b805e2a97116a4 jdk-10+6 +e118c818dbf84d15191414c453b77c089116fdc0 jdk-9+167 +0f81cde5a1f75786f381dbfb59b9afbab70174c7 jdk-9+168 +131e250080158e57ce45130560f5f987b92642b5 jdk-9+169 +550bfc15779f8f339610793867fdc251125811b5 jdk-9+170 +7e9cb37e6d6edbe56fdf4d510e5110f797823f09 jdk-10+7 +edb825e2dfb140c8e57a61b5d45de19edebccccf jdk-10+8 +d7d69c89088aec56d13bbff81a6f0a8b68ca75f4 jdk-10+9 +fc416270a776409b74006262dd0a9f5f5ff31555 jdk-9+171 +f381e171bec90afee95dc2920793754b58b6f705 jdk-10+10 +c8d6b740f0f7ec834b4157bf0d4523e8bbddb3f0 jdk-9+172 +ae0c4f1560e41e94a843e9933558d0223575869d jdk-10+11 +fa8e4de50e821eed876388c84f7129a6739268be jdk-9+173 diff --git a/nashorn/.jcheck/conf b/nashorn/.jcheck/conf index 5c6f62dc12c..b2581358014 100644 --- a/nashorn/.jcheck/conf +++ b/nashorn/.jcheck/conf @@ -1 +1 @@ -project=jdk9 +project=jdk10 diff --git a/nashorn/make/project.properties b/nashorn/make/project.properties index e47ed11ccb3..5626838f560 100644 --- a/nashorn/make/project.properties +++ b/nashorn/make/project.properties @@ -37,7 +37,8 @@ javac.target=1.9 javadoc.option=\ -tag "implSpec:a:Implementation Requirements:" \ - -tag "implNote:a:Implementation Note:" + -tag "implNote:a:Implementation Note:" \ + -tag "moduleGraph:a:Module Graph" # nashorn version information nashorn.version=0.1 diff --git a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/StandardOperation.java b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/StandardOperation.java index e5acb1b55a0..7b7865d8ed7 100644 --- a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/StandardOperation.java +++ b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/StandardOperation.java @@ -95,8 +95,8 @@ public enum StandardOperation implements Operation { /** * Get the value from a namespace defined on an object. Call sites with this * operation should have a signature of - * (receiver, name)→value or - * (receiver)→value when used with {@link NamedOperation}, with + * (receiver, name)→value or + * (receiver)→value when used with {@link NamedOperation}, with * all parameters and return type being of any type (either primitive or * reference). This operation must always be used as part of a {@link NamespaceOperation}. */ @@ -104,21 +104,21 @@ public enum StandardOperation implements Operation { /** * Set the value in a namespace defined on an object. Call sites with this * operation should have a signature of - * (receiver, name, value)→void or - * (receiver, value)→void when used with {@link NamedOperation}, + * (receiver, name, value)→void or + * (receiver, value)→void when used with {@link NamedOperation}, * with all parameters and return type being of any type (either primitive * or reference). This operation must always be used as part of a {@link NamespaceOperation}. */ SET, /** * Call a callable object. Call sites with this operation should have a - * signature of (callable, receiver, arguments...)→value, + * signature of (callable, receiver, arguments...)→value, * with all parameters and return type being of any type (either primitive or * reference). Typically, the callables are presumed to be methods of an object, so * an explicit receiver value is always passed to the callable before the arguments. * If a callable has no concept of a receiver, it is free to ignore the value of the * receiver argument. - * The CALL operation is allowed to be used with a + * The {@code CALL} operation is allowed to be used with a * {@link NamedOperation} even though it does not take a name. Using it with * a named operation won't affect its signature; the name is solely meant to * be used as a diagnostic description for error messages. @@ -126,9 +126,9 @@ public enum StandardOperation implements Operation { CALL, /** * Call a constructor object. Call sites with this operation should have a - * signature of (constructor, arguments...)→value, with all + * signature of (constructor, arguments...)→value, with all * parameters and return type being of any type (either primitive or - * reference). The NEW operation is allowed to be used with a + * reference). The {@code NEW} operation is allowed to be used with a * {@link NamedOperation} even though it does not take a name. Using it with * a named operation won't affect its signature; the name is solely meant to * be used as a diagnostic description for error messages. diff --git a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/beans/CallerSensitiveDynamicMethod.java b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/beans/CallerSensitiveDynamicMethod.java index 016873489d5..6d12e2f2fd8 100644 --- a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/beans/CallerSensitiveDynamicMethod.java +++ b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/beans/CallerSensitiveDynamicMethod.java @@ -92,7 +92,6 @@ import java.lang.reflect.Executable; import java.lang.reflect.Member; import java.lang.reflect.Method; import java.lang.reflect.Modifier; -import java.lang.reflect.Module; import java.security.AccessControlContext; import java.security.AccessController; import java.security.PrivilegedAction; diff --git a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/beans/CheckRestrictedPackage.java b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/beans/CheckRestrictedPackage.java index 2427cc63205..22ce67ee968 100644 --- a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/beans/CheckRestrictedPackage.java +++ b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/beans/CheckRestrictedPackage.java @@ -84,7 +84,6 @@ package jdk.dynalink.beans; import java.lang.reflect.Modifier; -import java.lang.reflect.Module; import java.security.AccessControlContext; import java.security.AccessController; import java.security.PrivilegedAction; diff --git a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/linker/GuardingTypeConverterFactory.java b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/linker/GuardingTypeConverterFactory.java index f5db5fc3616..dda73197c91 100644 --- a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/linker/GuardingTypeConverterFactory.java +++ b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/linker/GuardingTypeConverterFactory.java @@ -108,8 +108,8 @@ public interface GuardingTypeConverterFactory { * language's objects to Java interfaces and classes by generating adapters * for them. *

    - * The type of the invocation is (sourceType)→targetType, while the - * type of the guard is (sourceType)→boolean. You are allowed to + * The type of the invocation is (sourceType)→targetType, while the + * type of the guard is (sourceType)→boolean. You are allowed to * return unconditional invocations (with no guard) if the source type is * specific to your runtime and your runtime only. *

    Note that this method will never be invoked for diff --git a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/linker/support/Lookup.java b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/linker/support/Lookup.java index b996821d8f3..d9de82e0b4e 100644 --- a/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/linker/support/Lookup.java +++ b/nashorn/src/jdk.dynalink/share/classes/jdk/dynalink/linker/support/Lookup.java @@ -89,7 +89,6 @@ import java.lang.invoke.MethodType; import java.lang.reflect.Constructor; import java.lang.reflect.Executable; import java.lang.reflect.Field; -import java.lang.reflect.Module; import java.lang.reflect.Method; /** diff --git a/nashorn/src/jdk.dynalink/share/classes/module-info.java b/nashorn/src/jdk.dynalink/share/classes/module-info.java index 9e9fcbc3d20..3faffbd7f7a 100644 --- a/nashorn/src/jdk.dynalink/share/classes/module-info.java +++ b/nashorn/src/jdk.dynalink/share/classes/module-info.java @@ -216,6 +216,9 @@ * language runtime B gets passed to code from language runtime A, the linker * from B will get a chance to link the call site in A when it encounters the * object from B. + * + * @moduleGraph + * @since 9 */ module jdk.dynalink { requires java.logging; diff --git a/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Main.java b/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Main.java index d792738cfa4..2821111d69a 100644 --- a/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Main.java +++ b/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Main.java @@ -281,8 +281,7 @@ public final class Main extends Shell { } } - // FIXME: needs to be changed to use javase 9 docs later - private static String JAVADOC_BASE = "http://download.java.net/jdk9/docs/api/"; + private static String JAVADOC_BASE = "https://docs.oracle.com/javase/9/docs/api/"; private static void openBrowserForJavadoc(String relativeUrl) { try { diff --git a/nashorn/src/jdk.scripting.nashorn.shell/share/classes/module-info.java b/nashorn/src/jdk.scripting.nashorn.shell/share/classes/module-info.java index 790fc62b366..2ed4857862b 100644 --- a/nashorn/src/jdk.scripting.nashorn.shell/share/classes/module-info.java +++ b/nashorn/src/jdk.scripting.nashorn.shell/share/classes/module-info.java @@ -25,6 +25,8 @@ /** * Nashorn shell module + * + * @since 9 */ module jdk.scripting.nashorn.shell { requires java.desktop; diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForOfLoopTree.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForOfLoopTree.java index d95e2ed638e..999c4d3e3f9 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForOfLoopTree.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForOfLoopTree.java @@ -38,7 +38,7 @@ package jdk.nashorn.api.tree; */ public interface ForOfLoopTree extends LoopTree { /** - * The for..in left hand side expression. + * The for..of left hand side expression. * * @return the left hand side expression */ @@ -52,7 +52,7 @@ public interface ForOfLoopTree extends LoopTree { ExpressionTree getExpression(); /** - * The statement contained in this for..in statement. + * The statement contained in this for..of statement. * * @return the statement */ diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/TreeVisitor.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/TreeVisitor.java index ea8fc0d4222..70c124d453c 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/TreeVisitor.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/TreeVisitor.java @@ -30,7 +30,7 @@ package jdk.nashorn.api.tree; * Classes implementing this interface are used to operate * on a tree when the kind of tree is unknown at compile time. * When a visitor is passed to an tree's {@link Tree#accept - * accept} method, the visitXYZ method most applicable + * accept} method, the visitXyz method most applicable * to that tree is invoked. * *

    Classes implementing this interface may or may not throw a diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/codegen/SpillObjectCreator.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/codegen/SpillObjectCreator.java index c4e4aae312a..c23920bf751 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/codegen/SpillObjectCreator.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/codegen/SpillObjectCreator.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010-2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/codegen/TypeMap.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/codegen/TypeMap.java index a26e6b93f56..f554a3cdada 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/codegen/TypeMap.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/codegen/TypeMap.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010-2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/objects/NativeDataView.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/objects/NativeDataView.java index 44d06065592..759c168bbbd 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/objects/NativeDataView.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/objects/NativeDataView.java @@ -416,7 +416,7 @@ public class NativeDataView extends ScriptObject { * @return 32-bit unsigned int value at the byteOffset */ @Function(attributes = Attribute.NOT_ENUMERABLE, arity = 1) - public static long getUint32(final Object self, final Object byteOffset, final Object littleEndian) { + public static double getUint32(final Object self, final Object byteOffset, final Object littleEndian) { try { return 0xFFFFFFFFL & getBuffer(self, littleEndian).getInt(JSType.toInt32(byteOffset)); } catch (final IllegalArgumentException iae) { @@ -432,7 +432,7 @@ public class NativeDataView extends ScriptObject { * @return 32-bit unsigned int value at the byteOffset */ @SpecializedFunction - public static long getUint32(final Object self, final int byteOffset) { + public static double getUint32(final Object self, final int byteOffset) { try { return JSType.toUint32(getBuffer(self, false).getInt(JSType.toInt32(byteOffset))); } catch (final IllegalArgumentException iae) { @@ -449,7 +449,7 @@ public class NativeDataView extends ScriptObject { * @return 32-bit unsigned int value at the byteOffset */ @SpecializedFunction - public static long getUint32(final Object self, final int byteOffset, final boolean littleEndian) { + public static double getUint32(final Object self, final int byteOffset, final boolean littleEndian) { try { return JSType.toUint32(getBuffer(self, littleEndian).getInt(JSType.toInt32(byteOffset))); } catch (final IllegalArgumentException iae) { @@ -837,9 +837,9 @@ public class NativeDataView extends ScriptObject { * @return undefined */ @SpecializedFunction - public static Object setUint32(final Object self, final int byteOffset, final long value) { + public static Object setUint32(final Object self, final int byteOffset, final double value) { try { - getBuffer(self, false).putInt(byteOffset, (int)value); + getBuffer(self, false).putInt(byteOffset, (int) JSType.toUint32(value)); return UNDEFINED; } catch (final IllegalArgumentException iae) { throw rangeError(iae, "dataview.offset"); @@ -856,9 +856,9 @@ public class NativeDataView extends ScriptObject { * @return undefined */ @SpecializedFunction - public static Object setUint32(final Object self, final int byteOffset, final long value, final boolean littleEndian) { + public static Object setUint32(final Object self, final int byteOffset, final double value, final boolean littleEndian) { try { - getBuffer(self, littleEndian).putInt(byteOffset, (int)value); + getBuffer(self, littleEndian).putInt(byteOffset, (int) JSType.toUint32(value)); return UNDEFINED; } catch (final IllegalArgumentException iae) { throw rangeError(iae, "dataview.offset"); diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/Context.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/Context.java index a40ed5f22ce..aeec38cc796 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/Context.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/Context.java @@ -51,9 +51,7 @@ import java.lang.module.ModuleFinder; import java.lang.module.ModuleReader; import java.lang.module.ModuleReference; import java.lang.reflect.Field; -import java.lang.reflect.Layer; import java.lang.reflect.Modifier; -import java.lang.reflect.Module; import java.net.MalformedURLException; import java.net.URL; import java.nio.file.Path; @@ -378,7 +376,7 @@ public final class Context { static final boolean javaSqlFound, javaSqlRowsetFound; static { - final Layer boot = Layer.boot(); + final ModuleLayer boot = ModuleLayer.boot(); javaSqlFound = boot.findModule("java.sql").isPresent(); javaSqlRowsetFound = boot.findModule("java.sql.rowset").isPresent(); } @@ -1334,7 +1332,7 @@ public final class Context { * @return the new Module */ static Module createModuleTrusted(final ModuleDescriptor descriptor, final ClassLoader loader) { - return createModuleTrusted(Layer.boot(), descriptor, loader); + return createModuleTrusted(ModuleLayer.boot(), descriptor, loader); } /** @@ -1346,7 +1344,7 @@ public final class Context { * @param loader the class loader of the module * @return the new Module */ - static Module createModuleTrusted(final Layer parent, final ModuleDescriptor descriptor, final ClassLoader loader) { + static Module createModuleTrusted(final ModuleLayer parent, final ModuleDescriptor descriptor, final ClassLoader loader) { final String mn = descriptor.name(); final ModuleReference mref = new ModuleReference(descriptor, null) { @@ -1372,10 +1370,10 @@ public final class Context { }; final Configuration cf = parent.configuration() - .resolveRequires(finder, ModuleFinder.of(), Set.of(mn)); + .resolve(finder, ModuleFinder.of(), Set.of(mn)); - final PrivilegedAction pa = () -> parent.defineModules(cf, name -> loader); - final Layer layer = AccessController.doPrivileged(pa, GET_LOADER_ACC_CTXT); + final PrivilegedAction pa = () -> parent.defineModules(cf, name -> loader); + final ModuleLayer layer = AccessController.doPrivileged(pa, GET_LOADER_ACC_CTXT); final Module m = layer.findModule(mn).get(); assert m.getLayer() == layer; @@ -1796,9 +1794,9 @@ public final class Context { collect(Collectors.toSet()); } - final Layer boot = Layer.boot(); + final ModuleLayer boot = ModuleLayer.boot(); final Configuration conf = boot.configuration(). - resolveRequires(mf, ModuleFinder.of(), rootMods); + resolve(mf, ModuleFinder.of(), rootMods); final String firstMod = rootMods.iterator().next(); return boot.defineModulesWithOneLoader(conf, cl).findLoader(firstMod); } diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/NashornLoader.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/NashornLoader.java index c9d48053bd3..cc86b464355 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/NashornLoader.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/NashornLoader.java @@ -34,7 +34,6 @@ import java.lang.reflect.Method; import java.net.MalformedURLException; import java.net.URL; import java.net.URLClassLoader; -import java.lang.reflect.Module; import java.security.AccessController; import java.security.CodeSource; import java.security.Permission; diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/ScriptLoader.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/ScriptLoader.java index 4a223527876..d0e0ca14899 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/ScriptLoader.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/ScriptLoader.java @@ -26,9 +26,10 @@ package jdk.nashorn.internal.runtime; import java.lang.module.ModuleDescriptor; -import java.lang.reflect.Module; +import java.lang.module.ModuleDescriptor.Modifier; import java.security.CodeSource; import java.util.Objects; +import java.util.Set; /** * Responsible for loading script generated classes. @@ -69,12 +70,11 @@ final class ScriptLoader extends NashornLoader { private Module createModule(final String moduleName) { final Module structMod = context.getStructLoader().getModule(); final ModuleDescriptor.Builder builder = - ModuleDescriptor.module(moduleName) - .requires("java.base") + ModuleDescriptor.newModule(moduleName, Set.of(Modifier.SYNTHETIC)) .requires("java.logging") .requires(NASHORN_MODULE.getName()) .requires(structMod.getName()) - .contains(SCRIPTS_PKG); + .packages(Set.of(SCRIPTS_PKG)); if (Context.javaSqlFound) { builder.requires("java.sql"); diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/ScriptRuntime.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/ScriptRuntime.java index bf34f1f14a1..8a914ddfd03 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/ScriptRuntime.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/ScriptRuntime.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -56,6 +56,8 @@ import jdk.nashorn.internal.ir.debug.JSONWriter; import jdk.nashorn.internal.objects.AbstractIterator; import jdk.nashorn.internal.objects.Global; import jdk.nashorn.internal.objects.NativeObject; +import jdk.nashorn.internal.objects.NativeJava; +import jdk.nashorn.internal.objects.NativeArray; import jdk.nashorn.internal.parser.Lexer; import jdk.nashorn.internal.runtime.arrays.ArrayIndex; import jdk.nashorn.internal.runtime.linker.Bootstrap; @@ -398,6 +400,30 @@ public final class ScriptRuntime { if (itr != null) { return itr; } + + if (obj instanceof Map) { + return new Iterator() { + private Iterator iter = ((Map)obj).entrySet().iterator(); + + @Override + public boolean hasNext() { + return iter.hasNext(); + } + + @Override + public Object next() { + Map.Entry next = (Map.Entry)iter.next(); + Object[] keyvalue = new Object[]{next.getKey(), next.getValue()}; + NativeArray array = NativeJava.from(null, keyvalue); + return array; + } + + @Override + public void remove() { + iter.remove(); + } + }; + } } final Global global = Global.instance(); diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/SpillProperty.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/SpillProperty.java index 26a5048fad7..ec197ed77ae 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/SpillProperty.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/SpillProperty.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010-2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/StructureLoader.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/StructureLoader.java index 075540a4eda..f1c9ef315b0 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/StructureLoader.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/StructureLoader.java @@ -31,8 +31,9 @@ import static jdk.nashorn.internal.codegen.CompilerConstants.JS_OBJECT_DUAL_FIEL import static jdk.nashorn.internal.codegen.CompilerConstants.JS_OBJECT_SINGLE_FIELD_PREFIX; import java.lang.module.ModuleDescriptor; -import java.lang.reflect.Module; +import java.lang.module.ModuleDescriptor.Modifier; import java.security.ProtectionDomain; +import java.util.Set; import jdk.nashorn.internal.codegen.ObjectClassGenerator; /** @@ -62,12 +63,11 @@ final class StructureLoader extends NashornLoader { } private Module createModule(final String moduleName) { - final ModuleDescriptor descriptor - = ModuleDescriptor.module(moduleName) - .requires("java.base") - .requires(NASHORN_MODULE.getName()) - .contains(SCRIPTS_PKG) - .build(); + final ModuleDescriptor descriptor = + ModuleDescriptor.newModule(moduleName, Set.of(Modifier.SYNTHETIC)) + .requires(NASHORN_MODULE.getName()) + .packages(Set.of(SCRIPTS_PKG)) + .build(); final Module mod = Context.createModuleTrusted(descriptor, this); loadModuleManipulator(); diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/linker/JSObjectLinker.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/linker/JSObjectLinker.java index 6f2ee8cd7b8..8b324246e23 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/linker/JSObjectLinker.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/linker/JSObjectLinker.java @@ -176,6 +176,8 @@ final class JSObjectLinker implements TypeBasedGuardingDynamicLinker { final int index = getIndex((Number)key); if (index > -1) { return ((JSObject)jsobj).getSlot(index); + } else { + return ((JSObject)jsobj).getMember(JSType.toString(key)); } } else if (isString(key)) { final String name = key.toString(); @@ -193,7 +195,12 @@ final class JSObjectLinker implements TypeBasedGuardingDynamicLinker { if (key instanceof Integer) { ((JSObject)jsobj).setSlot((Integer)key, value); } else if (key instanceof Number) { - ((JSObject)jsobj).setSlot(getIndex((Number)key), value); + final int index = getIndex((Number)key); + if (index > -1) { + ((JSObject)jsobj).setSlot(index, value); + } else { + ((JSObject)jsobj).setMember(JSType.toString(key), value); + } } else if (isString(key)) { ((JSObject)jsobj).setMember(key.toString(), value); } diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/linker/JavaAdapterClassLoader.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/linker/JavaAdapterClassLoader.java index a488e6cd4cb..06f035c4b5e 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/linker/JavaAdapterClassLoader.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/runtime/linker/JavaAdapterClassLoader.java @@ -27,7 +27,6 @@ package jdk.nashorn.internal.runtime.linker; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; -import java.lang.reflect.Module; import java.security.AccessControlContext; import java.security.AccessController; import java.security.PrivilegedAction; @@ -115,7 +114,11 @@ final class JavaAdapterClassLoader { @Override public Class loadClass(final String name, final boolean resolve) throws ClassNotFoundException { try { - Context.checkPackageAccess(name); + final int i = name.lastIndexOf('.'); + if(i != -1){ + final String pkgName = name.substring(0,i); + Context.checkPackageAccess(pkgName); + } return super.loadClass(name, resolve); } catch (final SecurityException se) { // we may be implementing an interface or extending a class that was diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/scripts/ModuleGraphManipulator.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/scripts/ModuleGraphManipulator.java index b3e165ad226..72e0be1d255 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/scripts/ModuleGraphManipulator.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/scripts/ModuleGraphManipulator.java @@ -25,7 +25,6 @@ package jdk.nashorn.internal.scripts; -import java.lang.reflect.Module; import jdk.nashorn.api.scripting.JSObject; /** diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/module-info.java b/nashorn/src/jdk.scripting.nashorn/share/classes/module-info.java index 83b41891f51..00aeab11923 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/module-info.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/module-info.java @@ -89,6 +89,9 @@ arrays and back, and so on.

    Other non-standard built-in objects

    In addition to {@code Java}, Nashorn also exposes some other non-standard built-in objects: {@code JSAdapter}, {@code JavaImporter}, {@code Packages} + +@moduleGraph +@since 9 */ module jdk.scripting.nashorn { requires java.logging; diff --git a/nashorn/test/TEST.ROOT b/nashorn/test/TEST.ROOT index 08e6c7f53f2..2c826e5b639 100644 --- a/nashorn/test/TEST.ROOT +++ b/nashorn/test/TEST.ROOT @@ -8,7 +8,10 @@ keys=intermittent randomness groups=TEST.groups # Minimum jtreg version -requiredVersion=4.2 b04 +requiredVersion=4.2 b07 # Use new module options useNewOptions=true + +# Use --patch-module instead of -Xmodule: +useNewPatchModule=true diff --git a/nashorn/test/script/basic/JDK-8150218.js b/nashorn/test/script/basic/JDK-8150218.js index 72dffa2cd6f..6263a0fcd3f 100644 --- a/nashorn/test/script/basic/JDK-8150218.js +++ b/nashorn/test/script/basic/JDK-8150218.js @@ -1,21 +1,21 @@ /* - * Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. - * + * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). - * + * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * + * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. diff --git a/nashorn/test/script/basic/JDK-8170594.js b/nashorn/test/script/basic/JDK-8170594.js index 6365500aafd..7f74e9803c4 100644 --- a/nashorn/test/script/basic/JDK-8170594.js +++ b/nashorn/test/script/basic/JDK-8170594.js @@ -1,21 +1,21 @@ /* - * Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. - * + * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). - * + * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * + * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. diff --git a/nashorn/test/script/basic/JDK-8171849.js b/nashorn/test/script/basic/JDK-8171849.js index febc97cee11..cce68742e6e 100644 --- a/nashorn/test/script/basic/JDK-8171849.js +++ b/nashorn/test/script/basic/JDK-8171849.js @@ -1,21 +1,21 @@ /* - * Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. - * + * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). - * + * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * + * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. diff --git a/nashorn/test/script/basic/JDK-8176511.js b/nashorn/test/script/basic/JDK-8176511.js new file mode 100644 index 00000000000..08fbd551ddb --- /dev/null +++ b/nashorn/test/script/basic/JDK-8176511.js @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * JDK-8176511: JSObject property access is broken for numeric keys outside the int range + * + * @test + * @run + */ + + +var reassignWithNewGlobal = loadWithNewGlobal({ + script: '(function (o, i) { o[i] = o[i]; })', name: 'internal.js' + +}); + +function test(i) { + var o = {}; + o[i] = true; + var before = JSON.stringify(o); + reassignWithNewGlobal(o, i); + var after = JSON.stringify(o); + Assert.assertEquals(before, after); +} + +test(-2147483649); +test(-2147483648); +test(2147483647); +test(2147483648); + diff --git a/nashorn/test/script/basic/JDK-8181191.js b/nashorn/test/script/basic/JDK-8181191.js new file mode 100644 index 00000000000..4f4ef496d1f --- /dev/null +++ b/nashorn/test/script/basic/JDK-8181191.js @@ -0,0 +1,52 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * JDK-8181191: getUint32 returning Long + * + * @test + * @run + */ + + +function uint32(x) { + var buffer = new ArrayBuffer(16); + var dataview = new DataView(buffer); + dataview.setUint32(0, x); + return dataview.getUint32(0); +} + +Assert.assertTrue(typeof uint32(0x7f) === 'number'); +Assert.assertTrue(typeof uint32(0x80) === 'number'); +Assert.assertTrue(typeof uint32(0xffffffff) === 'number'); +Assert.assertTrue(typeof uint32(0x100000000) === 'number'); + +Assert.assertTrue(uint32(0x7f) === 0x7f); +Assert.assertTrue(uint32(0x80) === 0x80); +Assert.assertTrue(uint32(0xffffffff) === 0xffffffff); +Assert.assertTrue(uint32(0x100000000) === 0x0); + +Assert.assertTrue(uint32(0x7f) === uint32(0x7f)); +Assert.assertTrue(uint32(0x80) === uint32(0x80)); +Assert.assertTrue(uint32(0xffffffff) === uint32(0xffffffff)); +Assert.assertTrue(uint32(0x100000000) === uint32(0x100000000)); diff --git a/nashorn/test/script/basic/es6/JDK-8156743.js b/nashorn/test/script/basic/es6/JDK-8156743.js new file mode 100644 index 00000000000..d44b8476a6c --- /dev/null +++ b/nashorn/test/script/basic/es6/JDK-8156743.js @@ -0,0 +1,75 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * JDK-8156743: ES6 for..of should work for Java Maps and Sets + * + * @test + * @run + * @option --language=es6 + */ + +var map = new Map([ + [1, 'one'], + [2, 'two'], + [3, 'three'] +]); + +var set = new Set(['red', 'green', 'blue']); + +var HashMap = Java.type("java.util.HashMap"); +var jmap = new HashMap(); +jmap.put(1, 'one'); +jmap.put(2, 'two'); +jmap.put(3, 'three'); + +var HashSet = Java.type("java.util.HashSet"); +var jset = new HashSet(); +jset.add('red'); +jset.add('green'); +jset.add('blue'); + +for(var keyvalue of map){ + print(keyvalue[0],keyvalue[1]); +} + +for(var keyvalue of jmap){ + print(keyvalue[0],keyvalue[1]); +} + +for(var keyvalue of map){ + print(keyvalue); +} + +for(var keyvalue of jmap){ + print(keyvalue); +} + +for(var element of set){ + print(element); +} + +for(var element of jset){ + print(element); +} + diff --git a/nashorn/test/script/basic/es6/JDK-8156743.js.EXPECTED b/nashorn/test/script/basic/es6/JDK-8156743.js.EXPECTED new file mode 100644 index 00000000000..80c8bb7ca20 --- /dev/null +++ b/nashorn/test/script/basic/es6/JDK-8156743.js.EXPECTED @@ -0,0 +1,18 @@ +1 one +2 two +3 three +1 one +2 two +3 three +1,one +2,two +3,three +1,one +2,two +3,three +red +green +blue +red +green +blue diff --git a/nashorn/test/script/basic/es6/JDK-8168373.js b/nashorn/test/script/basic/es6/JDK-8168373.js index af26e73533e..56d58b7da35 100644 --- a/nashorn/test/script/basic/es6/JDK-8168373.js +++ b/nashorn/test/script/basic/es6/JDK-8168373.js @@ -1,21 +1,21 @@ /* - * Copyright (c) 2016 Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. - * + * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). - * + * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * + * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. @@ -36,8 +36,8 @@ function r(x) { return x } // "read" try { // Try creates control flow edges from assignments into catch blocks. // Lexically scoped, never read int variable (undefined at catch block) but still with a cf edge into catch block. // Since it's never read, it's not written either (Nashorn optimizes some dead writes). - let x = 0; - if (p()) { throw {}; } // We need `p()` so this block doesn't get optimized away, for possibility of a `throw` + let x = 0; + if (p()) { throw {}; } // We need `p()` so this block doesn't get optimized away, for possibility of a `throw` x = 0.0; // change the type of x to double r(x); // read x otherwise it's optimized away } catch (e) {} // under the bug, "throw" will try to widen unwritten int x to double for here and cause a verifier error diff --git a/nashorn/test/src/jdk/nashorn/test/models/Reflector.java b/nashorn/test/src/jdk/nashorn/test/models/Reflector.java index 9722694bab0..72f2938d0d4 100644 --- a/nashorn/test/src/jdk/nashorn/test/models/Reflector.java +++ b/nashorn/test/src/jdk/nashorn/test/models/Reflector.java @@ -29,7 +29,6 @@ import java.lang.reflect.Constructor; import java.lang.reflect.Executable; import java.lang.reflect.Field; import java.lang.reflect.Method; -import java.lang.reflect.Module; import jdk.nashorn.internal.runtime.Context; /** diff --git a/test/TestCommon.gmk b/test/TestCommon.gmk index 4aecf79a0fb..4529d7375a6 100644 --- a/test/TestCommon.gmk +++ b/test/TestCommon.gmk @@ -370,7 +370,7 @@ endif # Give tests access to JT_JAVA, see JDK-8141609 JTREG_BASIC_OPTIONS += -e:JDK8_HOME=${JT_JAVA} # Set other vm and test options -JTREG_TEST_OPTIONS = $(JAVA_ARGS:%=-javaoptions:%) $(JAVA_OPTIONS:%=-vmoption:%) $(JAVA_VM_ARGS:%=-vmoption:%) +JTREG_TEST_OPTIONS += $(JAVA_ARGS:%=-javaoptions:%) $(JAVA_OPTIONS:%=-vmoption:%) $(JAVA_VM_ARGS:%=-vmoption:%) ifeq ($(IGNORE_MARKED_TESTS), true) # Option to tell jtreg to not run tests marked with "ignore" diff --git a/test/lib/RedefineClassHelper.java b/test/lib/RedefineClassHelper.java index 75768092365..2c236907a7a 100644 --- a/test/lib/RedefineClassHelper.java +++ b/test/lib/RedefineClassHelper.java @@ -23,7 +23,7 @@ import java.io.PrintWriter; import java.lang.instrument.*; -import jdk.test.lib.InMemoryJavaCompiler; +import jdk.test.lib.compiler.InMemoryJavaCompiler; /* * Helper class to write tests that redefine classes. diff --git a/test/lib/jdk/test/lib/wrappers/InfiniteLoop.java b/test/lib/jdk/test/lib/InfiniteLoop.java similarity index 98% rename from test/lib/jdk/test/lib/wrappers/InfiniteLoop.java rename to test/lib/jdk/test/lib/InfiniteLoop.java index dbee901f8c0..15097b66ff5 100644 --- a/test/lib/jdk/test/lib/wrappers/InfiniteLoop.java +++ b/test/lib/jdk/test/lib/InfiniteLoop.java @@ -21,7 +21,7 @@ * questions. */ -package jdk.test.lib.wrappers; +package jdk.test.lib; import java.util.Objects; diff --git a/test/lib/jdk/test/lib/JDKToolLauncher.java b/test/lib/jdk/test/lib/JDKToolLauncher.java index 38e7b4530bf..6c264700215 100644 --- a/test/lib/jdk/test/lib/JDKToolLauncher.java +++ b/test/lib/jdk/test/lib/JDKToolLauncher.java @@ -24,9 +24,7 @@ package jdk.test.lib; import java.util.ArrayList; -import java.util.Arrays; import java.util.List; -import jdk.test.lib.process.ProcessTools; /** * A utility for constructing command lines for starting JDK tool processes. @@ -59,7 +57,6 @@ public class JDKToolLauncher { } else { executable = JDKToolFinder.getTestJDKTool(tool); } - vmArgs.addAll(Arrays.asList(ProcessTools.getPlatformSpecificVMArgs())); } /** diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/LockFreeLogManager.java b/test/lib/jdk/test/lib/LockFreeLogger.java similarity index 73% rename from jdk/test/lib/testlibrary/jdk/testlibrary/LockFreeLogManager.java rename to test/lib/jdk/test/lib/LockFreeLogger.java index f895018be44..4e96b9abccd 100644 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/LockFreeLogManager.java +++ b/test/lib/jdk/test/lib/LockFreeLogger.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,10 +21,10 @@ * questions. */ -package jdk.testlibrary; +package jdk.test.lib; import java.util.Collection; -import java.util.Formatter; +import java.util.Comparator; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentLinkedQueue; @@ -32,32 +32,28 @@ import java.util.concurrent.atomic.AtomicInteger; import java.util.stream.Collectors; /** - * A log manager designed specifically to allow collecting ordered log messages + * A logger designed specifically to allow collecting ordered log messages * in a multi-threaded environment without involving any kind of locking. *

    * It is particularly useful in situations when one needs to assert various * details about the tested thread state or the locks it hold while also wanting * to produce diagnostic log messages. *

    - * The log manager does not provide any guarantees about the completness of the + * The logger does not provide any guarantees about the completness of the * logs written from different threads - it is up to the caller to make sure * {@code toString()} method is called only when all the activity has ceased * and the per-thread logs contain all the necessary data. * * @author Jaroslav Bachorik **/ -public class LockFreeLogManager { +public class LockFreeLogger { private final AtomicInteger logCntr = new AtomicInteger(0); private final Collection> allRecords = new ConcurrentLinkedQueue<>(); - private final ThreadLocal> records = new ThreadLocal>() { - @Override - protected Map initialValue() { - Map m = new ConcurrentHashMap<>(); - allRecords.add(m); - return m; - } + private final ThreadLocal> records = ThreadLocal.withInitial(ConcurrentHashMap::new); - }; + public LockFreeLogger() { + allRecords.add(records.get()); + } /** * Log a message @@ -66,9 +62,7 @@ public class LockFreeLogManager { */ public void log(String format, Object ... params) { int id = logCntr.getAndIncrement(); - try (Formatter formatter = new Formatter()) { - records.get().put(id, formatter.format(format, params).toString()); - } + records.get().put(id, String.format(format, params)); } /** @@ -82,9 +76,9 @@ public class LockFreeLogManager { @Override public String toString() { return allRecords.stream() - .flatMap(m->m.entrySet().stream()) - .sorted((l, r)->l.getKey().compareTo(r.getKey())) - .map(e->e.getValue()) + .flatMap(m -> m.entrySet().stream()) + .sorted(Comparator.comparing(Map.Entry::getKey)) + .map(Map.Entry::getValue) .collect(Collectors.joining()); } } diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/NetworkConfiguration.java b/test/lib/jdk/test/lib/NetworkConfiguration.java similarity index 66% rename from jdk/test/lib/testlibrary/jdk/testlibrary/NetworkConfiguration.java rename to test/lib/jdk/test/lib/NetworkConfiguration.java index 77544d2bd92..b8a4720643a 100644 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/NetworkConfiguration.java +++ b/test/lib/jdk/test/lib/NetworkConfiguration.java @@ -21,7 +21,7 @@ * questions. */ -package jdk.testlibrary; +package jdk.test.lib; import java.io.PrintStream; import java.io.UncheckedIOException; @@ -35,8 +35,8 @@ import java.util.HashMap; import java.util.LinkedList; import java.util.List; import java.util.Map; -import java.util.Optional; import java.util.function.Predicate; +import java.util.stream.Collectors; import java.util.stream.Stream; import static java.net.NetworkInterface.getNetworkInterfaces; import static java.util.Collections.list; @@ -47,17 +47,12 @@ import static java.util.Collections.list; */ public class NetworkConfiguration { - static final boolean isWindows = - System.getProperty("os.name").startsWith("Windows"); - static final boolean isMacOS = - System.getProperty("os.name").contains("OS X"); - private Map> ip4Interfaces; private Map> ip6Interfaces; - private NetworkConfiguration(Map> ip4Interfaces, - Map> ip6Interfaces) - { + private NetworkConfiguration( + Map> ip4Interfaces, + Map> ip6Interfaces) { this.ip4Interfaces = ip4Interfaces; this.ip6Interfaces = ip6Interfaces; } @@ -74,44 +69,38 @@ public class NetworkConfiguration { * Returns a stream of interfaces suitable for IPv4 functional tests. */ public Stream ip4Interfaces() { - return ip4Interfaces.keySet().stream() - .filter(NetworkConfiguration::isNotExcludedInterface) - .filter(hasIp4Addresses); + return ip4Interfaces.keySet() + .stream() + .filter(NetworkConfiguration::isNotExcludedInterface) + .filter(hasIp4Addresses); } /** * Returns a stream of interfaces suitable for IPv6 functional tests. */ public Stream ip6Interfaces() { - return ip6Interfaces.keySet().stream() - .filter(NetworkConfiguration::isNotExcludedInterface) - .filter(hasIp6Addresses); + return ip6Interfaces.keySet() + .stream() + .filter(NetworkConfiguration::isNotExcludedInterface) + .filter(hasIp6Addresses); } private static boolean isNotExcludedInterface(NetworkInterface nif) { - if (isMacOS && nif.getName().contains("awdl")) + if (Platform.isOSX() && nif.getName().contains("awdl")) { return false; + } String dName = nif.getDisplayName(); - if (isWindows && dName != null && dName.contains("Teredo")) + if (Platform.isWindows() && dName != null && dName.contains("Teredo")) { return false; + } return true; } - private final Predicate hasIp4Addresses = nif -> { - Optional addr = ip4Interfaces.get(nif).stream() - .filter(a -> !a.isAnyLocalAddress()) - .findAny(); + private final Predicate hasIp4Addresses = nif -> + ip4Interfaces.get(nif).stream().anyMatch(a -> !a.isAnyLocalAddress()); - return addr.isPresent(); - }; - - private final Predicate hasIp6Addresses = nif -> { - Optional addr = ip6Interfaces.get(nif).stream() - .filter(a -> !a.isAnyLocalAddress()) - .findAny(); - - return addr.isPresent(); - }; + private final Predicate hasIp6Addresses = nif -> + ip6Interfaces.get(nif).stream().anyMatch(a -> !a.isAnyLocalAddress()); /** @@ -130,14 +119,10 @@ public class NetworkConfiguration { private final Predicate supportsIp4Multicast = nif -> { try { - if (!nif.supportsMulticast() || nif.isLoopback()) + if (!nif.supportsMulticast() || nif.isLoopback()) { return false; - - Optional addr = ip4Interfaces.get(nif).stream() - .filter(a -> !a.isAnyLocalAddress()) - .findAny(); - - return addr.isPresent(); + } + return hasIp4Addresses.test(nif); } catch (IOException e) { throw new UncheckedIOException(e); } @@ -145,14 +130,11 @@ public class NetworkConfiguration { private final Predicate supportsIp6Multicast = nif -> { try { - if (!nif.supportsMulticast() || nif.isLoopback()) + if (!nif.supportsMulticast() || nif.isLoopback()) { return false; + } - Optional addr = ip6Interfaces.get(nif).stream() - .filter(a -> !a.isAnyLocalAddress()) - .findAny(); - - return addr.isPresent(); + return hasIp6Addresses.test(nif); } catch (IOException e) { throw new UncheckedIOException(e); } @@ -170,14 +152,14 @@ public class NetworkConfiguration { * Returns all IPv4 addresses on all "functional" interfaces. */ public Stream ip4Addresses() { - return ip4Interfaces().flatMap(nif -> ip4Addresses(nif)); + return ip4Interfaces().flatMap(this::ip4Addresses); } /** * Returns all IPv6 addresses on all "functional" interfaces. */ public Stream ip6Addresses() { - return ip6Interfaces().flatMap(nif -> ip6Addresses(nif)); + return ip6Interfaces().flatMap(this::ip6Addresses); } /** @@ -204,18 +186,20 @@ public class NetworkConfiguration { List nifs = list(getNetworkInterfaces()); for (NetworkInterface nif : nifs) { // ignore interfaces that are down - if (!nif.isUp() || nif.isPointToPoint()) + if (!nif.isUp() || nif.isPointToPoint()) { continue; + } List ip4Addresses = new LinkedList<>(); List ip6Addresses = new LinkedList<>(); ip4Interfaces.put(nif, ip4Addresses); ip6Interfaces.put(nif, ip6Addresses); for (InetAddress addr : list(nif.getInetAddresses())) { - if (addr instanceof Inet4Address) - ip4Addresses.add((Inet4Address)addr); - else if (addr instanceof Inet6Address) - ip6Addresses.add((Inet6Address)addr); + if (addr instanceof Inet4Address) { + ip4Addresses.add((Inet4Address) addr); + } else if (addr instanceof Inet6Address) { + ip6Addresses.add((Inet6Address) addr); + } } } return new NetworkConfiguration(ip4Interfaces, ip6Interfaces); @@ -223,28 +207,49 @@ public class NetworkConfiguration { @Override public String toString() { - StringBuilder sb = new StringBuilder(); - interfaces().forEach(nif -> sb.append(interfaceInformation(nif))); - return sb.toString(); + return interfaces().map(NetworkConfiguration::interfaceInformation) + .collect(Collectors.joining()); } /** Returns detailed information for the given interface. */ public static String interfaceInformation(NetworkInterface nif) { StringBuilder sb = new StringBuilder(); try { - sb.append("Display name: " + nif.getDisplayName() + "\n"); - sb.append("Name: " + nif.getName() + "\n"); - for (InetAddress inetAddress : list(nif.getInetAddresses())) - sb.append("InetAddress: " + inetAddress + "\n"); - sb.append("Up? " + nif.isUp() + "\n"); - sb.append("Loopback? " + nif.isLoopback() + "\n"); - sb.append("PointToPoint? " + nif.isPointToPoint() + "\n"); - sb.append("Supports multicast? " + nif.supportsMulticast() + "\n"); - sb.append("Virtual? " + nif.isVirtual() + "\n"); - sb.append("Hardware address: " + - Arrays.toString(nif.getHardwareAddress()) + "\n"); - sb.append("MTU: " + nif.getMTU() + "\n"); - sb.append("Index: " + nif.getIndex() + "\n"); + sb.append("Display name: ") + .append(nif.getDisplayName()) + .append("\n"); + sb.append("Name: ") + .append(nif.getName()) + .append("\n"); + for (InetAddress inetAddress : list(nif.getInetAddresses())) { + sb.append("InetAddress: ") + .append(inetAddress) + .append("\n"); + } + sb.append("Up? ") + .append(nif.isUp()) + .append("\n"); + sb.append("Loopback? ") + .append(nif.isLoopback()) + .append("\n"); + sb.append("PointToPoint? ") + .append(nif.isPointToPoint()) + .append("\n"); + sb.append("Supports multicast? ") + .append(nif.supportsMulticast()) + .append("\n"); + sb.append("Virtual? ") + .append(nif.isVirtual()) + .append("\n"); + sb.append("Hardware address: ") + .append(Arrays.toString(nif.getHardwareAddress())) + .append("\n"); + sb.append("MTU: ") + .append(nif.getMTU()) + .append("\n"); + sb.append("Index: ") + .append(nif.getIndex()) + .append("\n"); sb.append("\n"); return sb.toString(); } catch (IOException e) { @@ -256,9 +261,9 @@ public class NetworkConfiguration { public static void printSystemConfiguration(PrintStream out) { try { out.println("*** all system network interface configuration ***"); - List nifs = list(getNetworkInterfaces()); - for (NetworkInterface nif : nifs) + for (NetworkInterface nif : list(getNetworkInterfaces())) { out.print(interfaceInformation(nif)); + } out.println("*** end ***"); } catch (IOException e) { throw new UncheckedIOException(e); diff --git a/test/lib/jdk/test/lib/Platform.java b/test/lib/jdk/test/lib/Platform.java index 26bbf1bae94..75720134be6 100644 --- a/test/lib/jdk/test/lib/Platform.java +++ b/test/lib/jdk/test/lib/Platform.java @@ -23,6 +23,10 @@ package jdk.test.lib; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; import java.util.regex.Pattern; public class Platform { @@ -228,7 +232,7 @@ public class Platform { public static boolean canPtraceAttachLinux() throws Exception { // SELinux deny_ptrace: - String deny_ptrace = Utils.fileAsString("/sys/fs/selinux/booleans/deny_ptrace"); + String deny_ptrace = fileAsString("/sys/fs/selinux/booleans/deny_ptrace"); if (deny_ptrace != null && deny_ptrace.contains("1")) { // ptrace will be denied: return false; @@ -239,7 +243,7 @@ public class Platform { // 1 - restricted ptrace: a process must be a children of the inferior or user is root // 2 - only processes with CAP_SYS_PTRACE may use ptrace or user is root // 3 - no attach: no processes may use ptrace with PTRACE_ATTACH - String ptrace_scope = Utils.fileAsString("/proc/sys/kernel/yama/ptrace_scope"); + String ptrace_scope = fileAsString("/proc/sys/kernel/yama/ptrace_scope"); if (ptrace_scope != null) { if (ptrace_scope.startsWith("3")) { return false; @@ -265,4 +269,10 @@ public class Platform { .matcher(osArch) .matches(); } + + private static String fileAsString(String filename) throws IOException { + Path filePath = Paths.get(filename); + if (!Files.exists(filePath)) return null; + return new String(Files.readAllBytes(filePath)); + } } diff --git a/test/lib/jdk/test/lib/RandomFactory.java b/test/lib/jdk/test/lib/RandomFactory.java new file mode 100644 index 00000000000..8930a380008 --- /dev/null +++ b/test/lib/jdk/test/lib/RandomFactory.java @@ -0,0 +1,103 @@ +/* + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package jdk.test.lib; + +import java.util.Random; +import java.util.SplittableRandom; + +/** + * Factory class which generates and prints to STDOUT a long-valued seed + * for use in initializing a PRNG. An instance of {@code Random} or + * {@code SplittableRandom} may likewise be obtained. + */ +public class RandomFactory { + /** + * Attempt to obtain the seed from the value of the "seed" property. + * @return The seed or {@code null} if the "seed" property was not set or + * could not be parsed. + */ + private static Long getSystemSeed() { + Long seed = null; + try { + // note that Long.valueOf(null) also throws a + // NumberFormatException so if the property is undefined this + // will still work correctly + seed = Long.valueOf(System.getProperty("seed")); + } catch (NumberFormatException e) { + // do nothing: seed is still null + } + + return seed; + } + + /** + * Obtain a seed from an independent PRNG. + * + * @return A random seed. + */ + private static long getRandomSeed() { + return new Random().nextLong(); + } + + /** + * Obtain and print to STDOUT a seed appropriate for initializing a PRNG. + * If the system property "seed" is set and has value which may be correctly + * parsed it is used, otherwise a seed is generated using an independent + * PRNG. + * + * @return The seed. + */ + public static long getSeed() { + Long seed = getSystemSeed(); + if (seed == null) { + seed = getRandomSeed(); + } + System.out.println("Seed from RandomFactory = "+seed+"L"); + return seed; + } + + /** + * Obtain and print to STDOUT a seed and use it to initialize a new + * {@code Random} instance which is returned. If the system + * property "seed" is set and has value which may be correctly parsed it + * is used, otherwise a seed is generated using an independent PRNG. + * + * @return The {@code Random} instance. + */ + public static Random getRandom() { + return new Random(getSeed()); + } + + /** + * Obtain and print to STDOUT a seed and use it to initialize a new + * {@code SplittableRandom} instance which is returned. If the system + * property "seed" is set and has value which may be correctly parsed it + * is used, otherwise a seed is generated using an independent PRNG. + * + * @return The {@code SplittableRandom} instance. + */ + public static SplittableRandom getSplittableRandom() { + return new SplittableRandom(getSeed()); + } +} diff --git a/test/lib/jdk/test/lib/wrappers/TimeLimitedRunner.java b/test/lib/jdk/test/lib/TimeLimitedRunner.java similarity index 99% rename from test/lib/jdk/test/lib/wrappers/TimeLimitedRunner.java rename to test/lib/jdk/test/lib/TimeLimitedRunner.java index 73d53b43b12..cea92f34405 100644 --- a/test/lib/jdk/test/lib/wrappers/TimeLimitedRunner.java +++ b/test/lib/jdk/test/lib/TimeLimitedRunner.java @@ -21,7 +21,7 @@ * questions. */ -package jdk.test.lib.wrappers; +package jdk.test.lib; import java.util.Objects; import java.util.concurrent.Callable; diff --git a/test/lib/jdk/test/lib/apps/LingeredApp.java b/test/lib/jdk/test/lib/apps/LingeredApp.java index 8632a835695..22a123ccbb5 100644 --- a/test/lib/jdk/test/lib/apps/LingeredApp.java +++ b/test/lib/jdk/test/lib/apps/LingeredApp.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -143,7 +143,7 @@ public class LingeredApp { if (appProcess == null) { throw new RuntimeException("Process is not alive"); } - return appProcess.getPid(); + return appProcess.pid(); } /** diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/FilterClassLoader.java b/test/lib/jdk/test/lib/classloader/FilterClassLoader.java similarity index 93% rename from jdk/test/lib/testlibrary/jdk/testlibrary/FilterClassLoader.java rename to test/lib/jdk/test/lib/classloader/FilterClassLoader.java index fc4e82857f4..327b1d27a7d 100644 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/FilterClassLoader.java +++ b/test/lib/jdk/test/lib/classloader/FilterClassLoader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -20,7 +20,8 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package jdk.testlibrary; + +package jdk.test.lib.classloader; import java.util.function.Predicate; /** diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/ParentLastURLClassLoader.java b/test/lib/jdk/test/lib/classloader/ParentLastURLClassLoader.java similarity index 93% rename from jdk/test/lib/testlibrary/jdk/testlibrary/ParentLastURLClassLoader.java rename to test/lib/jdk/test/lib/classloader/ParentLastURLClassLoader.java index 5537ebd3047..71d8953b812 100644 --- a/jdk/test/lib/testlibrary/jdk/testlibrary/ParentLastURLClassLoader.java +++ b/test/lib/jdk/test/lib/classloader/ParentLastURLClassLoader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -20,7 +20,8 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package jdk.testlibrary; + +package jdk.test.lib.classloader; import java.net.URL; import java.net.URLClassLoader; diff --git a/test/lib/jdk/test/lib/cli/CommandLineOptionTest.java b/test/lib/jdk/test/lib/cli/CommandLineOptionTest.java index f794ef36090..71369150b1c 100644 --- a/test/lib/jdk/test/lib/cli/CommandLineOptionTest.java +++ b/test/lib/jdk/test/lib/cli/CommandLineOptionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,6 +28,7 @@ import java.util.ArrayList; import java.util.Collections; import java.util.function.BooleanSupplier; +import jdk.test.lib.management.InputArguments; import jdk.test.lib.process.ExitCode; import jdk.test.lib.process.ProcessTools; import jdk.test.lib.process.OutputAnalyzer; @@ -105,7 +106,7 @@ public abstract class CommandLineOptionTest { throws Throwable { List finalOptions = new ArrayList<>(); if (addTestVMOptions) { - Collections.addAll(finalOptions, ProcessTools.getVmInputArgs()); + Collections.addAll(finalOptions, InputArguments.getVmInputArgs()); Collections.addAll(finalOptions, Utils.getTestJavaOpts()); } Collections.addAll(finalOptions, options); @@ -199,6 +200,10 @@ public abstract class CommandLineOptionTest { throws Throwable { List finalOptions = new ArrayList<>(); finalOptions.add(CommandLineOptionTest.getVMTypeOption()); + String extraFlagForEmulated = CommandLineOptionTest.getVMTypeOptionForEmulated(); + if (extraFlagForEmulated != null) { + finalOptions.add(extraFlagForEmulated); + } Collections.addAll(finalOptions, options); CommandLineOptionTest.verifyJVMStartup(expectedMessages, @@ -390,6 +395,10 @@ public abstract class CommandLineOptionTest { String... additionalVMOpts) throws Throwable { List finalOptions = new ArrayList<>(); finalOptions.add(CommandLineOptionTest.getVMTypeOption()); + String extraFlagForEmulated = CommandLineOptionTest.getVMTypeOptionForEmulated(); + if (extraFlagForEmulated != null) { + finalOptions.add(extraFlagForEmulated); + } Collections.addAll(finalOptions, additionalVMOpts); CommandLineOptionTest.verifyOptionValue(optionName, expectedValue, @@ -497,6 +506,18 @@ public abstract class CommandLineOptionTest { throw new RuntimeException("Unknown VM mode."); } + /** + * @return addtional VMoptions(Emulated related) required to start a new VM with the same type as current. + */ + private static String getVMTypeOptionForEmulated() { + if (Platform.isServer() && !Platform.isEmulatedClient()) { + return "-XX:-NeverActAsServerClassMachine"; + } else if (Platform.isEmulatedClient()) { + return "-XX:+NeverActAsServerClassMachine"; + } + return null; + } + private final BooleanSupplier predicate; /** diff --git a/jdk/test/lib/testlibrary/CompilerUtils.java b/test/lib/jdk/test/lib/compiler/CompilerUtils.java similarity index 91% rename from jdk/test/lib/testlibrary/CompilerUtils.java rename to test/lib/jdk/test/lib/compiler/CompilerUtils.java index 261c2c8f930..8ac607aeb1f 100644 --- a/jdk/test/lib/testlibrary/CompilerUtils.java +++ b/test/lib/jdk/test/lib/compiler/CompilerUtils.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,6 +21,8 @@ * questions. */ +package jdk.test.lib.compiler; + import javax.tools.JavaCompiler; import javax.tools.StandardJavaFileManager; import javax.tools.StandardLocation; @@ -37,7 +39,6 @@ import java.util.stream.Collectors; * This class consists exclusively of static utility methods for invoking the * java compiler. */ - public final class CompilerUtils { private CompilerUtils() { } @@ -56,14 +57,14 @@ public final class CompilerUtils { * @throws UnsupportedOperationException * if there is no system java compiler */ - public static boolean compile(Path source, Path destination, String ... options) + public static boolean compile(Path source, Path destination, String... options) throws IOException { JavaCompiler compiler = ToolProvider.getSystemJavaCompiler(); if (compiler == null) { // no compiler available - throw new UnsupportedOperationException("Unable to get system java compiler. " + - "Perhaps, jdk.compiler module is not available."); + throw new UnsupportedOperationException("Unable to get system java compiler. " + + "Perhaps, jdk.compiler module is not available."); } StandardJavaFileManager jfm = compiler.getStandardFileManager(null, null, null); @@ -73,9 +74,9 @@ public final class CompilerUtils { .collect(Collectors.toList()); Files.createDirectories(destination); - jfm.setLocation(StandardLocation.CLASS_PATH, Collections.EMPTY_LIST); + jfm.setLocation(StandardLocation.CLASS_PATH, Collections.emptyList()); jfm.setLocationFromPaths(StandardLocation.CLASS_OUTPUT, - Arrays.asList(destination)); + Collections.singletonList(destination)); List opts = Arrays.asList(options); JavaCompiler.CompilationTask task diff --git a/test/lib/jdk/test/lib/InMemoryJavaCompiler.java b/test/lib/jdk/test/lib/compiler/InMemoryJavaCompiler.java similarity index 74% rename from test/lib/jdk/test/lib/InMemoryJavaCompiler.java rename to test/lib/jdk/test/lib/compiler/InMemoryJavaCompiler.java index 5fb78e4441f..e174b320180 100644 --- a/test/lib/jdk/test/lib/InMemoryJavaCompiler.java +++ b/test/lib/jdk/test/lib/compiler/InMemoryJavaCompiler.java @@ -21,14 +21,16 @@ * questions. */ -package jdk.test.lib; +package jdk.test.lib.compiler; import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.OutputStream; import java.net.URI; +import java.util.ArrayList; import java.util.Arrays; +import java.util.List; import javax.tools.ForwardingJavaFileManager; import javax.tools.FileObject; @@ -37,6 +39,7 @@ import javax.tools.JavaCompiler.CompilationTask; import javax.tools.JavaFileObject; import javax.tools.JavaFileObject.Kind; import javax.tools.SimpleJavaFileObject; +import javax.tools.StandardLocation; import javax.tools.ToolProvider; /** @@ -53,7 +56,7 @@ import javax.tools.ToolProvider; * *

      * {@code
    - * import jdk.test.lib.InMemoryJavaCompiler;
    + * import jdk.test.lib.compiler.InMemoryJavaCompiler;
      * import jdk.test.lib.ByteClassLoader;
      *
      * class Example {
    @@ -104,11 +107,24 @@ public class InMemoryJavaCompiler {
         }
     
         private static class FileManagerWrapper extends ForwardingJavaFileManager {
    -        private MemoryJavaFileObject file;
    +        private static final Location PATCH_LOCATION = new Location() {
    +            @Override
    +            public String getName() {
    +                return "patch module location";
    +            }
     
    -        public FileManagerWrapper(MemoryJavaFileObject file) {
    +            @Override
    +            public boolean isOutputLocation() {
    +                return false;
    +            }
    +        };
    +        private final MemoryJavaFileObject file;
    +        private final String moduleOverride;
    +
    +        public FileManagerWrapper(MemoryJavaFileObject file, String moduleOverride) {
                 super(getCompiler().getStandardFileManager(null, null, null));
                 this.file = file;
    +            this.moduleOverride = moduleOverride;
             }
     
             @Override
    @@ -121,6 +137,28 @@ public class InMemoryJavaCompiler {
                 }
                 return file;
             }
    +
    +        @Override
    +        public Location getLocationForModule(Location location, JavaFileObject fo) throws IOException {
    +            if (fo == file && moduleOverride != null) {
    +                return PATCH_LOCATION;
    +            }
    +            return super.getLocationForModule(location, fo);
    +        }
    +
    +        @Override
    +        public String inferModuleName(Location location) throws IOException {
    +            if (location == PATCH_LOCATION) {
    +                return moduleOverride;
    +            }
    +            return super.inferModuleName(location);
    +        }
    +
    +        @Override
    +        public boolean hasLocation(Location location) {
    +            return super.hasLocation(location) || location == StandardLocation.PATCH_MODULE_PATH;
    +        }
    +
         }
     
         /**
    @@ -148,6 +186,15 @@ public class InMemoryJavaCompiler {
         }
     
         private static CompilationTask getCompilationTask(MemoryJavaFileObject file, String... options) {
    -        return getCompiler().getTask(null, new FileManagerWrapper(file), null, Arrays.asList(options), null, Arrays.asList(file));
    +        List opts = new ArrayList<>();
    +        String moduleOverride = null;
    +        for (String opt : options) {
    +            if (opt.startsWith("-Xmodule:")) {
    +                moduleOverride = opt.substring("-Xmodule:".length());
    +            } else {
    +                opts.add(opt);
    +            }
    +        }
    +        return getCompiler().getTask(null, new FileManagerWrapper(file, moduleOverride), null, opts, null, Arrays.asList(file));
         }
     }
    diff --git a/jdk/test/lib/testlibrary/ModuleInfoMaker.java b/test/lib/jdk/test/lib/compiler/ModuleInfoMaker.java
    similarity index 89%
    rename from jdk/test/lib/testlibrary/ModuleInfoMaker.java
    rename to test/lib/jdk/test/lib/compiler/ModuleInfoMaker.java
    index 5e4f15a6774..f6438a678ca 100644
    --- a/jdk/test/lib/testlibrary/ModuleInfoMaker.java
    +++ b/test/lib/jdk/test/lib/compiler/ModuleInfoMaker.java
    @@ -21,6 +21,8 @@
      * questions.
      */
     
    +package jdk.test.lib.compiler;
    +
     import java.io.BufferedWriter;
     import java.io.IOException;
     import java.nio.file.Files;
    @@ -30,21 +32,20 @@ import java.util.regex.Matcher;
     import java.util.regex.Pattern;
     import java.util.stream.Stream;
     
    -import static org.testng.Assert.assertTrue;
    -
     /**
      * Utility class for creating test modules.
      */
     public class ModuleInfoMaker {
    -    private static String MODULE_INFO_JAVA = "module-info.java";
    -    private static Pattern MODULE_PATTERN =
    +    private static final String MODULE_INFO_JAVA = "module-info.java";
    +    private static final Pattern MODULE_PATTERN =
             Pattern.compile("module\\s+((?:\\w+\\.)*)");
    -    private static Pattern PACKAGE_PATTERN =
    +    private static final Pattern PACKAGE_PATTERN =
                            Pattern.compile("package\\s+(((?:\\w+\\.)*)(?:\\w+))");
    -    private static Pattern CLASS_PATTERN =
    +    private static final Pattern CLASS_PATTERN =
               Pattern.compile("(?:public\\s+)?(?:class|enum|interface)\\s+(\\w+)");
     
         private final Path dir;
    +
         public ModuleInfoMaker(Path dir) {
             this.dir = dir;
         }
    @@ -69,12 +70,13 @@ public class ModuleInfoMaker {
             throws IOException
         {
             Path msrc = dir.resolve(module);
    -        Stream args =
    +        String[] args =
                 Stream.concat(Arrays.stream(options),
                               Stream.of("--module-source-path",
    -                                    dir.toString()));
    -        assertTrue(CompilerUtils.compile(msrc, dest, args.toArray(String[]::new)),
    -                   "Fail to compile " + module);
    +                                    dir.toString())).toArray(String[]::new);
    +        if (!CompilerUtils.compile(msrc, dest, args)) {
    +            throw new Error("Fail to compile " + module);
    +        }
         }
     
         static class JavaSource {
    diff --git a/test/lib/jdk/test/lib/hprof/parser/HprofReader.java b/test/lib/jdk/test/lib/hprof/parser/HprofReader.java
    index cdc505d00b2..5ef40a33562 100644
    --- a/test/lib/jdk/test/lib/hprof/parser/HprofReader.java
    +++ b/test/lib/jdk/test/lib/hprof/parser/HprofReader.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -35,6 +35,7 @@ package jdk.test.lib.hprof.parser;
     import java.io.*;
     import java.util.Date;
     import java.util.Hashtable;
    +import java.util.Map;
     import jdk.test.lib.hprof.model.ArrayTypeCodes;
     import jdk.test.lib.hprof.model.*;
     
    @@ -357,6 +358,22 @@ public class HprofReader extends Reader /* imports */ implements ArrayTypeCodes
             return snapshot;
         }
     
    +    public String printStackTraces() {
    +        StringBuffer output = new StringBuffer();
    +        for (Map.Entry entry : stackTraces.entrySet()) {
    +            StackFrame[] frames = entry.getValue().getFrames();
    +            output.append("SerialNo " + entry.getKey() + "\n");
    +            for (int i = 0; i < frames.length; i++) {
    +                output.append("  " + frames[i].getClassName() + "." + frames[i].getMethodName()
    +                        + frames[i].getMethodSignature() + " (" + frames[i].getSourceFileName()
    +                        + ":" + frames[i].getLineNumber() + ")" + "\n");
    +            }
    +        }
    +
    +        System.out.println(output);
    +        return output.toString();
    +    }
    +
         private void skipBytes(long length) throws IOException {
             while (length > 0) {
                 long skipped = in.skip(length);
    diff --git a/test/lib/jdk/test/lib/hprof/parser/Reader.java b/test/lib/jdk/test/lib/hprof/parser/Reader.java
    index 5263035df72..cbbfeb46f7f 100644
    --- a/test/lib/jdk/test/lib/hprof/parser/Reader.java
    +++ b/test/lib/jdk/test/lib/hprof/parser/Reader.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -94,4 +94,42 @@ public abstract class Reader {
                 }
             }
         }
    +
    +    /**
    +     * Get Stack Traces from a Hprof file.
    +     *
    +     * @param heapFile The name of a file containing a heap dump
    +     */
    +    public static String getStack(String heapFile, int debugLevel)
    +            throws IOException {
    +        int dumpNumber = 1;
    +        int pos = heapFile.lastIndexOf('#');
    +        if (pos > -1) {
    +            String num = heapFile.substring(pos+1, heapFile.length());
    +            try {
    +                dumpNumber = Integer.parseInt(num, 10);
    +            } catch (java.lang.NumberFormatException ex) {
    +                String msg = "In file name \"" + heapFile
    +                             + "\", a dump number was "
    +                             + "expected after the :, but \""
    +                             + num + "\" was found instead.";
    +                System.err.println(msg);
    +                throw new IOException(msg);
    +            }
    +            heapFile = heapFile.substring(0, pos);
    +        }
    +        try (PositionDataInputStream in = new PositionDataInputStream(
    +                new BufferedInputStream(new FileInputStream(heapFile)))) {
    +            int i = in.readInt();
    +            if (i == HprofReader.MAGIC_NUMBER) {
    +                HprofReader r
    +                    = new HprofReader(heapFile, in, dumpNumber,
    +                                      true, debugLevel);
    +                r.read();
    +                return r.printStackTraces();
    +            } else {
    +                throw new IOException("Unrecognized magic number: " + i);
    +            }
    +        }
    +    }
     }
    diff --git a/test/lib/jdk/test/lib/DynamicVMOption.java b/test/lib/jdk/test/lib/management/DynamicVMOption.java
    similarity index 99%
    rename from test/lib/jdk/test/lib/DynamicVMOption.java
    rename to test/lib/jdk/test/lib/management/DynamicVMOption.java
    index 17f545e126e..786f1d85b22 100644
    --- a/test/lib/jdk/test/lib/DynamicVMOption.java
    +++ b/test/lib/jdk/test/lib/management/DynamicVMOption.java
    @@ -20,7 +20,8 @@
      * or visit www.oracle.com if you need additional information or have any
      * questions.
      */
    -package jdk.test.lib;
    +
    +package jdk.test.lib.management;
     
     import com.sun.management.HotSpotDiagnosticMXBean;
     import java.lang.management.ManagementFactory;
    diff --git a/test/lib/jdk/test/lib/management/InputArguments.java b/test/lib/jdk/test/lib/management/InputArguments.java
    new file mode 100644
    index 00000000000..dca3a023cf2
    --- /dev/null
    +++ b/test/lib/jdk/test/lib/management/InputArguments.java
    @@ -0,0 +1,41 @@
    +/*
    + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
    + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    + *
    + * This code is free software; you can redistribute it and/or modify it
    + * under the terms of the GNU General Public License version 2 only, as
    + * published by the Free Software Foundation.
    + *
    + * This code is distributed in the hope that it will be useful, but WITHOUT
    + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    + * version 2 for more details (a copy is included in the LICENSE file that
    + * accompanied this code).
    + *
    + * You should have received a copy of the GNU General Public License version
    + * 2 along with this work; if not, write to the Free Software Foundation,
    + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    + *
    + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    + * or visit www.oracle.com if you need additional information or have any
    + * questions.
    + */
    +
    +package jdk.test.lib.management;
    +
    +import java.lang.management.ManagementFactory;
    +import java.lang.management.RuntimeMXBean;
    +import java.util.List;
    +
    +public class InputArguments {
    +    /**
    +     * Gets the array of strings containing input arguments passed to the VM
    +     *
    +     * @return arguments
    +     */
    +    public static String[] getVmInputArgs() {
    +        RuntimeMXBean runtime = ManagementFactory.getRuntimeMXBean();
    +        List args = runtime.getInputArguments();
    +        return args.toArray(new String[args.size()]);
    +    }
    +}
    diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/management/ThreadMXBeanTool.java b/test/lib/jdk/test/lib/management/ThreadMXBeanTool.java
    similarity index 91%
    rename from jdk/test/lib/testlibrary/jdk/testlibrary/management/ThreadMXBeanTool.java
    rename to test/lib/jdk/test/lib/management/ThreadMXBeanTool.java
    index b3f4417a898..eeb4297f500 100644
    --- a/jdk/test/lib/testlibrary/jdk/testlibrary/management/ThreadMXBeanTool.java
    +++ b/test/lib/jdk/test/lib/management/ThreadMXBeanTool.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -21,12 +21,11 @@
      * questions.
      */
     
    -package jdk.testlibrary.management;
    +package jdk.test.lib.management;
     
     import java.lang.management.ManagementFactory;
     import java.lang.management.ThreadInfo;
     import java.lang.management.ThreadMXBean;
    -import java.util.concurrent.TimeoutException;
     
     /**
      * A few utility methods to use ThreadMXBean.
    @@ -34,7 +33,7 @@ import java.util.concurrent.TimeoutException;
     public final class ThreadMXBeanTool {
     
         /**
    -     * Waits until {@link Thread} is in the certain {@link State}
    +     * Waits until {@link Thread} is in the certain {@link Thread.State}
          * and blocking on {@code object}.
          *
          * @param state The thread state
    diff --git a/test/lib/jdk/test/lib/process/OutputAnalyzer.java b/test/lib/jdk/test/lib/process/OutputAnalyzer.java
    index 572610d788d..73936b26548 100644
    --- a/test/lib/jdk/test/lib/process/OutputAnalyzer.java
    +++ b/test/lib/jdk/test/lib/process/OutputAnalyzer.java
    @@ -24,6 +24,7 @@
     package jdk.test.lib.process;
     
     import java.io.IOException;
    +import java.io.PrintStream;
     import java.util.Arrays;
     import java.util.List;
     import java.util.regex.Matcher;
    @@ -415,6 +416,25 @@ public final class OutputAnalyzer {
           System.err.println(msg);
       }
     
    +  /**
    +   * Print the stdout buffer to the given {@code PrintStream}.
    +   *
    +   * @return this OutputAnalyzer
    +   */
    +  public OutputAnalyzer outputTo(PrintStream out) {
    +      out.println(getStdout());
    +      return this;
    +  }
    +
    +  /**
    +   * Print the stderr buffer to the given {@code PrintStream}.
    +   *
    +   * @return this OutputAnalyzer
    +   */
    +  public OutputAnalyzer errorTo(PrintStream out) {
    +      out.println(getStderr());
    +      return this;
    +  }
     
       /**
        * Get the contents of the output buffer (stdout and stderr)
    diff --git a/test/lib/jdk/test/lib/process/ProcessTools.java b/test/lib/jdk/test/lib/process/ProcessTools.java
    index 3f4bbb7fa79..eff0f361edb 100644
    --- a/test/lib/jdk/test/lib/process/ProcessTools.java
    +++ b/test/lib/jdk/test/lib/process/ProcessTools.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -28,13 +28,10 @@ import java.io.IOException;
     import java.io.InputStream;
     import java.io.OutputStream;
     import java.io.PrintStream;
    -import java.lang.management.ManagementFactory;
    -import java.lang.management.RuntimeMXBean;
     import java.util.ArrayList;
     import java.util.Arrays;
     import java.util.Collections;
     import java.util.concurrent.CountDownLatch;
    -import java.util.List;
     import java.util.Map;
     import java.util.concurrent.ExecutionException;
     import java.util.concurrent.Future;
    @@ -45,7 +42,6 @@ import java.util.function.Consumer;
     import java.util.stream.Collectors;
     
     import jdk.test.lib.JDKToolFinder;
    -import jdk.test.lib.Platform;
     import jdk.test.lib.Utils;
     
     public final class ProcessTools {
    @@ -66,23 +62,23 @@ public final class ProcessTools {
         }
     
         /**
    -    * Pumps stdout and stderr from running the process into a String.
    -    *
    -    * @param processHandler ProcessHandler to run.
    -    * @return Output from process.
    -    * @throws IOException If an I/O error occurs.
    -    */
    +     * Pumps stdout and stderr from running the process into a String.
    +     *
    +     * @param processHandler ProcessHandler to run.
    +     * @return Output from process.
    +     * @throws IOException If an I/O error occurs.
    +     */
         public static OutputBuffer getOutput(ProcessBuilder processBuilder) throws IOException {
             return getOutput(processBuilder.start());
         }
     
         /**
    -    * Pumps stdout and stderr the running process into a String.
    -    *
    -    * @param process Process to pump.
    -    * @return Output from process.
    -    * @throws IOException If an I/O error occurs.
    -    */
    +     * Pumps stdout and stderr the running process into a String.
    +     *
    +     * @param process Process to pump.
    +     * @return Output from process.
    +     * @throws IOException If an I/O error occurs.
    +     */
         public static OutputBuffer getOutput(Process process) throws IOException {
             ByteArrayOutputStream stderrBuffer = new ByteArrayOutputStream();
             ByteArrayOutputStream stdoutBuffer = new ByteArrayOutputStream();
    @@ -302,40 +298,16 @@ public final class ProcessTools {
          * @return Process id
          */
         public static long getProcessId() throws Exception {
    -        return ProcessHandle.current().getPid();
    -    }
    -    /**
    -     * Gets the array of strings containing input arguments passed to the VM
    -     *
    -     * @return arguments
    -     */
    -    public static String[] getVmInputArgs() {
    -        RuntimeMXBean runtime = ManagementFactory.getRuntimeMXBean();
    -        List args = runtime.getInputArguments();
    -        return args.toArray(new String[args.size()]);
    +        return ProcessHandle.current().pid();
         }
     
    -    /**
    -     * Get platform specific VM arguments (e.g. -d64 on 64bit Solaris)
    -     *
    -     * @return String[] with platform specific arguments, empty if there are
    -     *         none
    -     */
    -    public static String[] getPlatformSpecificVMArgs() {
    -
    -    if (Platform.is64bit() && Platform.isSolaris()) {
    -            return new String[] { "-d64" };
    -        }
    -
    -        return new String[] {};
    -    }
     
     
         /**
          * Create ProcessBuilder using the java launcher from the jdk to be tested and
          * with any platform specific arguments prepended
          */
    -    public static ProcessBuilder createJavaProcessBuilder(String... command) throws Exception {
    +    public static ProcessBuilder createJavaProcessBuilder(String... command) {
             return createJavaProcessBuilder(false, command);
         }
     
    @@ -348,12 +320,11 @@ public final class ProcessTools {
          * @param command Arguments to pass to the java command.
          * @return The ProcessBuilder instance representing the java command.
          */
    -    public static ProcessBuilder createJavaProcessBuilder(boolean addTestVmAndJavaOptions, String... command) throws Exception {
    +    public static ProcessBuilder createJavaProcessBuilder(boolean addTestVmAndJavaOptions, String... command) {
             String javapath = JDKToolFinder.getJDKTool("java");
     
             ArrayList args = new ArrayList<>();
             args.add(javapath);
    -        Collections.addAll(args, getPlatformSpecificVMArgs());
     
             args.add("-cp");
             args.add(System.getProperty("java.class.path"));
    @@ -384,26 +355,6 @@ public final class ProcessTools {
             }
         }
     
    -    /**
    -     * Executes a test jvm process, waits for it to finish and returns the process output.
    -     * The default jvm options from the test's run command, jtreg, test.vm.opts and test.java.opts, are added.
    -     * The java from the test.jdk is used to execute the command.
    -     *
    -     * The command line will be like:
    -     * {test.jdk}/bin/java {test.fromRun.opts} {test.vm.opts} {test.java.opts} cmds
    -     *
    -     * @param cmds User specifed arguments.
    -     * @return The output from the process.
    -     */
    -    public static OutputAnalyzer executeTestJvmAllArgs(String... cmds) throws Throwable {
    -        List argsList = new ArrayList<>();
    -        String[] testArgs = getVmInputArgs();
    -        Collections.addAll(argsList, testArgs);
    -        Collections.addAll(argsList, Utils.addTestJavaOpts(cmds));
    -        ProcessBuilder pb = createJavaProcessBuilder(argsList.toArray(new String[argsList.size()]));
    -        return executeProcess(pb);
    -    }
    -
         /**
          * Executes a test jvm process, waits for it to finish and returns the process output.
          * The default jvm options from jtreg, test.vm.opts and test.java.opts, are added.
    @@ -414,7 +365,7 @@ public final class ProcessTools {
          *
          * The jvm process will have exited before this method returns.
          *
    -     * @param cmds User specifed arguments.
    +     * @param cmds User specified arguments.
          * @return The output from the process.
          */
         public static OutputAnalyzer executeTestJvm(String... cmds) throws Exception {
    @@ -422,6 +373,15 @@ public final class ProcessTools {
             return executeProcess(pb);
         }
     
    +    /**
    +     * @see #executeTestJvm(String...)
    +     * @param cmds User specified arguments.
    +     * @return The output from the process.
    +     */
    +    public static OutputAnalyzer executeTestJava(String... cmds) throws Exception {
    +        return executeTestJvm(cmds);
    +    }
    +
         /**
          * Executes a process, waits for it to finish and returns the process output.
          * The process will have exited before this method returns.
    @@ -580,8 +540,8 @@ public final class ProcessTools {
             }
     
             @Override
    -        public long getPid() {
    -            return p.getPid();
    +        public long pid() {
    +            return p.pid();
             }
     
             @Override
    diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/FileUtils.java b/test/lib/jdk/test/lib/util/FileUtils.java
    similarity index 88%
    rename from jdk/test/lib/testlibrary/jdk/testlibrary/FileUtils.java
    rename to test/lib/jdk/test/lib/util/FileUtils.java
    index 9c41b8e7580..8bbaded9586 100644
    --- a/jdk/test/lib/testlibrary/jdk/testlibrary/FileUtils.java
    +++ b/test/lib/jdk/test/lib/util/FileUtils.java
    @@ -21,7 +21,9 @@
      * questions.
      */
     
    -package jdk.testlibrary;
    +package jdk.test.lib.util;
    +
    +import jdk.test.lib.Platform;
     
     import java.io.IOException;
     import java.nio.file.DirectoryNotEmptyException;
    @@ -40,11 +42,9 @@ import java.util.concurrent.TimeUnit;
      * Common library for various test file utility functions.
      */
     public final class FileUtils {
    -
    -    private static final boolean isWindows =
    -                            System.getProperty("os.name").startsWith("Windows");
    -    private static final int RETRY_DELETE_MILLIS = isWindows ? 500 : 0;
    -    private static final int MAX_RETRY_DELETE_TIMES = isWindows ? 15 : 0;
    +    private static final boolean IS_WINDOWS = Platform.isWindows();
    +    private static final int RETRY_DELETE_MILLIS = IS_WINDOWS ? 500 : 0;
    +    private static final int MAX_RETRY_DELETE_TIMES = IS_WINDOWS ? 15 : 0;
     
         /**
          * Deletes a file, retrying if necessary.
    @@ -59,9 +59,7 @@ public final class FileUtils {
          * @throws IOException
          *         if an I/O error occurs
          */
    -    public static void deleteFileWithRetry(Path path)
    -        throws IOException
    -    {
    +    public static void deleteFileWithRetry(Path path) throws IOException {
             try {
                 deleteFileWithRetry0(path);
             } catch (InterruptedException x) {
    @@ -83,20 +81,18 @@ public final class FileUtils {
          * @throws IOException
          *         if an I/O error occurs
          */
    -    public static void deleteFileIfExistsWithRetry(Path path)
    -        throws IOException
    -    {
    +    public static void deleteFileIfExistsWithRetry(Path path) throws IOException {
             try {
    -            if(Files.exists(path))
    +            if (Files.exists(path)) {
                     deleteFileWithRetry0(path);
    +            }
             } catch (InterruptedException x) {
                 throw new IOException("Interrupted while deleting.", x);
             }
         }
     
         private static void deleteFileWithRetry0(Path path)
    -        throws IOException, InterruptedException
    -    {
    +            throws IOException, InterruptedException {
             int times = 0;
             IOException ioe = null;
             while (true) {
    @@ -104,8 +100,9 @@ public final class FileUtils {
                     Files.delete(path);
                     while (Files.exists(path)) {
                         times++;
    -                    if (times > MAX_RETRY_DELETE_TIMES)
    +                    if (times > MAX_RETRY_DELETE_TIMES) {
                             throw new IOException("File still exists after " + times + " waits.");
    +                    }
                         Thread.sleep(RETRY_DELETE_MILLIS);
                     }
                     break;
    @@ -114,13 +111,15 @@ public final class FileUtils {
                 } catch (IOException x) {
                     // Backoff/retry in case another process is accessing the file
                     times++;
    -                if (ioe == null)
    +                if (ioe == null) {
                         ioe = x;
    -                else
    +                } else {
                         ioe.addSuppressed(x);
    +                }
     
    -                if (times > MAX_RETRY_DELETE_TIMES)
    +                if (times > MAX_RETRY_DELETE_TIMES) {
                         throw ioe;
    +                }
                     Thread.sleep(RETRY_DELETE_MILLIS);
                 }
             }
    @@ -138,24 +137,24 @@ public final class FileUtils {
          *          following exceptions are added as suppressed exceptions of the
          *          first one caught, which is then re-thrown.
          */
    -    public static void deleteFileTreeWithRetry(Path dir)
    -         throws IOException
    -    {
    +    public static void deleteFileTreeWithRetry(Path dir) throws IOException {
             IOException ioe = null;
             final List excs = deleteFileTreeUnchecked(dir);
             if (!excs.isEmpty()) {
                 ioe = excs.remove(0);
    -            for (IOException x : excs)
    +            for (IOException x : excs) {
                     ioe.addSuppressed(x);
    +            }
             }
    -        if (ioe != null)
    +        if (ioe != null) {
                 throw ioe;
    +        }
         }
     
         public static List deleteFileTreeUnchecked(Path dir) {
             final List excs = new ArrayList<>();
             try {
    -            java.nio.file.Files.walkFileTree(dir, new SimpleFileVisitor() {
    +            java.nio.file.Files.walkFileTree(dir, new SimpleFileVisitor<>() {
                     @Override
                     public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) {
                         try {
    @@ -204,7 +203,7 @@ public final class FileUtils {
          */
         public static boolean areFileSystemsAccessible() throws IOException {
             boolean areFileSystemsAccessible = true;
    -        if (!isWindows) {
    +        if (!IS_WINDOWS) {
                 // try to check whether 'df' hangs
                 System.out.println("\n--- df output ---");
                 System.out.flush();
    diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/JarUtils.java b/test/lib/jdk/test/lib/util/JarUtils.java
    similarity index 98%
    rename from jdk/test/lib/testlibrary/jdk/testlibrary/JarUtils.java
    rename to test/lib/jdk/test/lib/util/JarUtils.java
    index 07fd00c19e6..76705f5395c 100644
    --- a/jdk/test/lib/testlibrary/jdk/testlibrary/JarUtils.java
    +++ b/test/lib/jdk/test/lib/util/JarUtils.java
    @@ -1,5 +1,5 @@
     /*
    - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
    + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
      * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
      *
      * This code is free software; you can redistribute it and/or modify it
    @@ -21,7 +21,7 @@
      * questions.
      */
     
    -package jdk.testlibrary;
    +package jdk.test.lib.util;
     
     import java.io.FileInputStream;
     import java.io.FileNotFoundException;
    diff --git a/jdk/test/lib/testlibrary/jdk/testlibrary/SerializationUtils.java b/test/lib/jdk/test/lib/util/SerializationUtils.java
    similarity index 70%
    rename from jdk/test/lib/testlibrary/jdk/testlibrary/SerializationUtils.java
    rename to test/lib/jdk/test/lib/util/SerializationUtils.java
    index 3dbc66692db..3b6e65aefd7 100644
    --- a/jdk/test/lib/testlibrary/jdk/testlibrary/SerializationUtils.java
    +++ b/test/lib/jdk/test/lib/util/SerializationUtils.java
    @@ -21,31 +21,36 @@
      * questions.
      */
     
    -package jdk.testlibrary;
    +package jdk.test.lib.util;
     
    -import java.io.*;
    +import java.io.ByteArrayInputStream;
    +import java.io.ByteArrayOutputStream;
    +import java.io.IOException;
    +import java.io.ObjectInputStream;
    +import java.io.ObjectOutputStream;
     
     /**
      * Common library for various test serialization utility functions.
      */
     public final class SerializationUtils {
    -    /*
    +    /**
          * Serialize an object into byte array.
          */
    -    public static byte[] serialize(Object obj) throws Exception {
    -        try (ByteArrayOutputStream bs = new ByteArrayOutputStream();
    -                ObjectOutputStream out = new ObjectOutputStream(bs);) {
    +    public static byte[] serialize(Object obj) throws IOException {
    +        ByteArrayOutputStream bs = new ByteArrayOutputStream();
    +        try (ObjectOutputStream out = new ObjectOutputStream(bs)) {
                 out.writeObject(obj);
    -            return bs.toByteArray();
             }
    +        return bs.toByteArray();
         }
     
    -    /*
    +    /**
          * Deserialize an object from byte array.
          */
    -    public static Object deserialize(byte[] ba) throws Exception {
    -        try (ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(ba));) {
    +    public static Object deserialize(byte[] ba) throws IOException, ClassNotFoundException {
    +        try (ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(ba))) {
                 return in.readObject();
             }
         }
    +    private SerializationUtils() {}
     }
    diff --git a/test/make/TestMakeBase.gmk b/test/make/TestMakeBase.gmk
    index 0bed3ea447c..60a7a6a3b67 100644
    --- a/test/make/TestMakeBase.gmk
    +++ b/test/make/TestMakeBase.gmk
    @@ -1,5 +1,5 @@
     #
    -# Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
    +# Copyright (c) 2014, 2017, Oracle and/or its affiliates. All rights reserved.
     # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     #
     # This code is free software; you can redistribute it and/or modify it
    @@ -179,7 +179,7 @@ test-vardep:
     	test "some string value1" = "`$(CAT) $(VARDEP_DIR)/target-file`"
     	test -e $(VARDEP_FLAG_FILE)
             #
    -        # Make the target file again and verify that the value is updated with 
    +        # Make the target file again and verify that the value is updated with
             # the new value
             #
     	$(SLEEP_ON_MAC)
    @@ -340,6 +340,61 @@ $(eval $(call assert-equals, \
         RelativePath, \
     ))
     
    +################################################################################
    +# Test ParseKeywordVariable
    +
    +KWBASE := APA=banan;GURKA=tomat;COUNT=1%202%203%204%205;SUM=1+2+3+4+5;MANY_WORDS=I have the best words.
    +
    +$(eval $(call ParseKeywordVariable, KWBASE, \
    +    KEYWORDS := APA GURKA SUM, \
    +    STRING_KEYWORDS := COUNT MANY_WORDS, \
    +))
    +
    +$(eval $(call assert-equals, \
    +    $(KWBASE_APA), \
    +    banan, \
    +    ParseKeywordVariable failed to parse APA, \
    +))
    +
    +$(eval $(call assert-equals, \
    +    $(KWBASE_COUNT), \
    +    1 2 3 4 5, \
    +    ParseKeywordVariable failed to parse COUNT, \
    +))
    +
    +$(eval $(call assert-equals, \
    +    $(KWBASE_SUM), \
    +    1+2+3+4+5, \
    +    ParseKeywordVariable failed to parse SUM, \
    +))
    +
    +$(eval $(call assert-equals, \
    +    $(KWBASE_MANY_WORDS), \
    +    I have the best words., \
    +    ParseKeywordVariable failed to parse MANY_WORDS, \
    +))
    +
    +# Simulate variable set from command line by using "override"
    +override KWBASE_WEIRD_GURKA := paprika
    +KWBASE_WEIRD := ;;APA=banan;;;GURKA=apelsin;APA=skansen;;
    +
    +$(eval $(call ParseKeywordVariable, KWBASE_WEIRD, \
    +    KEYWORDS := APA GURKA SUM, \
    +    STRING_KEYWORDS := COUNT, \
    +))
    +
    +$(eval $(call assert-equals, \
    +    $(KWBASE_WEIRD_APA), \
    +    skansen, \
    +    ParseKeywordVariable failed to overwrite APA, \
    +))
    +
    +$(eval $(call assert-equals, \
    +    $(KWBASE_WEIRD_GURKA), \
    +    paprika, \
    +    ParseKeywordVariable failed to preserve GURKA, \
    +))
    +
     ################################################################################
     
     all: $(TEST_TARGETS)
    

  • Modules 
    " + "" - + "methodThatReturnsTypeParameterA(​(E[] e)", "
    public E[] "
    -                + "methodThatReturnsTypeParameterA(E[] e)
    \n", "
    <T extends java.lang.Object & java.lang.Comparable<? super T>>" + "
    T
    " + "" - + "methodtThatReturnsTypeParametersB(java.util.Collection<? extends T> coll)", + + "methodtThatReturnsTypeParametersB​(java.util.Collection<? extends T> coll)", "
    Returns TypeParameters
    \n", // Method takes a TypeVariable "
    <X extends java.lang.Throwable>
    " @@ -154,7 +155,7 @@ public class TestNewLanguageFeatures extends JavadocTester { + "
    " + "" - + "orElseThrow(java.util.function.Supplier<? extends X> exceptionSupplier)" + + "orElseThrow​(java.util.function.Supplier<? extends X> exceptionSupplier)" ); checkOutput("pkg/Wildcards.html", true, @@ -208,7 +209,7 @@ public class TestNewLanguageFeatures extends JavadocTester { // Handle multiple bounds. //============================================================== checkOutput("pkg/MultiTypeParameters.html", true, - "public <T extends java.lang.Number & java.lang.Runnable> T foo(T t)"); + "public <T extends java.lang.Number & java.lang.Runnable> T foo​(T t)"); //============================================================== // Test Class-Use Documentation for Type Parameters. @@ -231,7 +232,7 @@ public class TestNewLanguageFeatures extends JavadocTester { "ClassUseTest1." + "method" - + "(T t)
    Fields in pkg2 with type parameters of " + "type " @@ -272,7 +273,7 @@ public class TestNewLanguageFeatures extends JavadocTester { "
    " + "ClassUseTest1.method" - + "(T t)ClassUseTest2." + "method" - + "(T t)
    Fields in pkg2 declared as ParamTest" @@ -336,7 +337,7 @@ public class TestNewLanguageFeatures extends JavadocTester { "
    ClassUseTest2." + "method" - + "(T t)
    Methods in pkg2 that return types with " + "arguments of type
    ClassUseTest3" + ".method(T t)<T extends " + "ParamTest2<java.util.List<? extends Foo4 ", "ClassUseTest3." + "method(T t)" + + "html#method-T-\">method​(T t)" + "
    Methods in pkg2 that return types with " @@ -433,7 +434,7 @@ public class TestNewLanguageFeatures extends JavadocTester { + "
    voidClassUseTest3." + "method(java." + + "html#method-java.util.Set-\">method​(java." + "util.Set<Foo4> p)
    Constructor parameters in " + "required=1994)\n" - + "public AnnotationTypeUsage()", + + "public AnnotationTypeUsage​()", // METHOD "
    @AnnotationType("
    @@ -556,9 +557,9 @@ public class TestNewLanguageFeatures extends JavadocTester {
                     + "=\"Method Annotation\",\n"
                     + "                "
                     + "required=1994)\n"
    -                + "public void method()
    ", + + "public void method​()", // METHOD PARAMS - "
    public void methodWithParams("
    +                "
    public void methodWithParams​("
                     + ""
                     + "@AnnotationType("
                     + "optional=\"Parameter Annotation\",",
                     // CONSTRUCTOR PARAMS
    -                "
    public AnnotationTypeUsage(public AnnotationTypeUsage​("
                     + "@AnnotationType("
                     + "optional=\"Constructor Param Annotation\",@AnnotationTypeUndocumented(optional=\"Constructor Annotation\",\n"
                     + "                required=1994)\n"
    -                + "public AnnotationTypeUsage()",
    +                + "public AnnotationTypeUsage​()",
                     // METHOD
                     "@AnnotationTypeUndocumented(optional=\"Method Annotation\",\n"
                     + "                required=1994)\n"
    -                + "public void method()");
    +                + "public void method​()");
     
             //=================================
             // Make sure annotation types do not
    diff --git a/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/C.java b/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/C.java
    index 09b8a237794..735a2d5f241 100644
    --- a/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/C.java
    +++ b/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/C.java
    @@ -71,4 +71,9 @@ public class C {
          * caseA 
    • end of sentence.
    • more
    */ public void caseA() {} + + /** + * caseB
    A block quote example:
    + */ + public void caseB() {} } diff --git a/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/Negative.java b/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/Negative.java new file mode 100644 index 00000000000..0bbe3f3b19a --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/Negative.java @@ -0,0 +1,29 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +public class Negative { + /** + * case1: A hanging < :
    xx
    < + */ + public void case1() {} +} diff --git a/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/TestNonInlineHtmlTagRemoval.java b/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/TestNonInlineHtmlTagRemoval.java index f1f85b51b0e..b24fb819962 100644 --- a/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/TestNonInlineHtmlTagRemoval.java +++ b/langtools/test/jdk/javadoc/doclet/testNonInlineHtmlTagRemoval/TestNonInlineHtmlTagRemoval.java @@ -23,7 +23,7 @@ /* * @test - * @bug 8048628 + * @bug 8048628 8174715 * @summary Verify html inline tags are removed correctly in the first sentence. * @library ../lib * @modules jdk.javadoc/jdk.javadoc.internal.tool @@ -39,8 +39,8 @@ public class TestNonInlineHtmlTagRemoval extends JavadocTester { } @Test - void test() { - javadoc("-d", "out", + void testPositive() { + javadoc("-d", "out1", "-sourcepath", testSrc, testSrc("C.java")); checkExit(Exit.OK); @@ -55,6 +55,18 @@ public class TestNonInlineHtmlTagRemoval extends JavadocTester { "
    case7 end of sentence.
    ", "
    case8 end of sentence.
    ", "
    case9 end of sentence.
    ", - "
    caseA end of sentence.
    "); + "
    caseA end of sentence.
    ", + "
    caseB A block quote example:
    "); + } + + @Test + void testNegative() { + javadoc("-d", "out2", + "-sourcepath", testSrc, + testSrc("Negative.java")); + checkExit(Exit.ERROR); + + checkOutput("Negative.html", true, + "
    case1: A hanging < : xx<
    "); } } diff --git a/langtools/test/jdk/javadoc/doclet/testOptions/TestOptions.java b/langtools/test/jdk/javadoc/doclet/testOptions/TestOptions.java index 69bbcf4adf7..9d90916ecf8 100644 --- a/langtools/test/jdk/javadoc/doclet/testOptions/TestOptions.java +++ b/langtools/test/jdk/javadoc/doclet/testOptions/TestOptions.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 4749567 8071982 + * @bug 4749567 8071982 8175200 * @summary Test the output for -header, -footer, -nooverview, -nodeprecatedlist, -nonavbar, -notree, -stylesheetfile options. * @author Bhavesh Patel * @library ../lib @@ -148,7 +148,7 @@ public class TestOptions extends JavadocTester { "
    public java.lang.Object someProperty
    ", "
    public java.lang.Object someProperty()
    "); + + "\"../src-html/linksource/Properties.html#line.31\">someProperty​()
    "); checkOutput("src-html/linksource/Properties.html", true, "Source code", @@ -161,9 +161,9 @@ public class TestOptions extends JavadocTester { "
    public int "
                     + "field
    ", "
    public "
    -                + "SomeClass()
    ", + + "SomeClass​()
    ", "
    public int "
    -                + "method()
    "); + + "method​()
    "); checkOutput("src-html/linksource/SomeClass.html", true, "Source code", diff --git a/langtools/test/jdk/javadoc/doclet/testOverridenMethods/TestBadOverride.java b/langtools/test/jdk/javadoc/doclet/testOverridenMethods/TestBadOverride.java new file mode 100644 index 00000000000..9681686258e --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testOverridenMethods/TestBadOverride.java @@ -0,0 +1,59 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8174839 8175200 + * @summary Bad overriding method should not crash + * @library ../lib + * @modules jdk.javadoc/jdk.javadoc.internal.tool + * @build JavadocTester + * @run main TestBadOverride + */ + +public class TestBadOverride extends JavadocTester { + + /** + * The entry point of the test. + * @param args the array of command line arguments. + */ + public static void main(String... args) throws Exception { + TestBadOverride tester = new TestBadOverride(); + tester.runTests(); + } + + @Test + void test() { + javadoc("-d", "out", + "-sourcepath", testSrc, + "pkg4"); + checkExit(Exit.OK); + + checkOutput("pkg4/Foo.html", true, + "
  • \n" + + "

    toString

    \n" + + "
    public void toString​()
    \n" + + "
    Why can't I do this ?
    \n" + + "
  • "); + } +} diff --git a/langtools/test/tools/javac/diags/examples/XModuleWithModulePath/XModuleWithModulePath.java b/langtools/test/jdk/javadoc/doclet/testOverridenMethods/pkg4/Foo.java similarity index 82% rename from langtools/test/tools/javac/diags/examples/XModuleWithModulePath/XModuleWithModulePath.java rename to langtools/test/jdk/javadoc/doclet/testOverridenMethods/pkg4/Foo.java index eaffab89d3e..fded7417892 100644 --- a/langtools/test/tools/javac/diags/examples/XModuleWithModulePath/XModuleWithModulePath.java +++ b/langtools/test/jdk/javadoc/doclet/testOverridenMethods/pkg4/Foo.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -21,7 +21,11 @@ * questions. */ -// key: compiler.err.xmodule.no.module.sourcepath -// options: -Xmodule:java.compiler --module-source-path src +package pkg4; -class XModuleWithModulePath {} +public class Foo { + /** + * Why can't I do this ? + */ + public void toString() {} +} diff --git a/langtools/test/jdk/javadoc/doclet/testOverview/TestOverview.java b/langtools/test/jdk/javadoc/doclet/testOverview/TestOverview.java new file mode 100644 index 00000000000..e4f105b8d86 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testOverview/TestOverview.java @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8173302 + * @summary make sure the overview-summary and module-summary pages don't + * don't have the See link, and the overview is copied correctly. + * @library ../lib + * @modules jdk.javadoc/jdk.javadoc.internal.tool + * @build JavadocTester + * @run main TestOverview + */ + +public class TestOverview extends JavadocTester { + + public static void main(String... args) throws Exception { + TestOverview tester = new TestOverview(); + tester.runTests(); + } + + @Test + void test1() { + javadoc("-d", "out-1", + "-doctitle", "Document Title", + "-windowtitle", "Window Title", + "-overview", testSrc("overview.html"), + "-sourcepath", testSrc("src"), + "p1", "p2"); + checkExit(Exit.OK); + checkOutput("overview-summary.html", true, + "
    \n" + + "

    Document Title

    \n" + + "
    \n" + + "
    \n" + + "
    This is line1. This is line 2.
    \n" + + "
    \n" + + "
    " + ); + } + + @Test + void test2() { + javadoc("-d", "out-2", + "-doctitle", "Document Title", + "-windowtitle", "Window Title", + "-overview", testSrc("overview.html"), + "-sourcepath", testSrc("msrc"), + "p1", "p2"); + checkExit(Exit.OK); + checkOutput("overview-summary.html", true, + "
    \n" + + "

    Document Title

    \n" + + "
    \n" + + "
    \n" + + "
    This is line1. This is line 2.
    \n" + + "
    \n" + + "
    " + ); + } +} diff --git a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/doclets/package-info.java b/langtools/test/jdk/javadoc/doclet/testOverview/msrc/module-info.java similarity index 88% rename from langtools/src/jdk.javadoc/share/classes/jdk/javadoc/doclets/package-info.java rename to langtools/test/jdk/javadoc/doclet/testOverview/msrc/module-info.java index 057c7713823..c5d6328c3da 100644 --- a/langtools/src/jdk.javadoc/share/classes/jdk/javadoc/doclets/package-info.java +++ b/langtools/test/jdk/javadoc/doclet/testOverview/msrc/module-info.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,8 @@ */ /** - * This package contains standard, supported doclets. - */ -package jdk.javadoc.doclets; - + * Test module acme. + */ +module acme { + exports p1; +} diff --git a/langtools/test/jdk/javadoc/doclet/testOverview/msrc/p1/C.java b/langtools/test/jdk/javadoc/doclet/testOverview/msrc/p1/C.java new file mode 100644 index 00000000000..db9ab5db919 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testOverview/msrc/p1/C.java @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package p1; + +public class C {} diff --git a/langtools/test/jdk/javadoc/doclet/testOverview/msrc/p2/C2.java b/langtools/test/jdk/javadoc/doclet/testOverview/msrc/p2/C2.java new file mode 100644 index 00000000000..65039aa6be7 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testOverview/msrc/p2/C2.java @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package p2; + +public class C2 {} diff --git a/langtools/test/jdk/javadoc/doclet/testOverview/overview.html b/langtools/test/jdk/javadoc/doclet/testOverview/overview.html new file mode 100644 index 00000000000..07351cdc861 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testOverview/overview.html @@ -0,0 +1,6 @@ + + + + This is line1. This is line 2. + + diff --git a/langtools/test/jdk/javadoc/doclet/testOverview/src/p1/C.java b/langtools/test/jdk/javadoc/doclet/testOverview/src/p1/C.java new file mode 100644 index 00000000000..db9ab5db919 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testOverview/src/p1/C.java @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package p1; + +public class C {} diff --git a/langtools/test/jdk/javadoc/doclet/testOverview/src/p2/C2.java b/langtools/test/jdk/javadoc/doclet/testOverview/src/p2/C2.java new file mode 100644 index 00000000000..65039aa6be7 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testOverview/src/p2/C2.java @@ -0,0 +1,26 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package p2; + +public class C2 {} diff --git a/langtools/test/jdk/javadoc/doclet/testPrivateClasses/TestPrivateClasses.java b/langtools/test/jdk/javadoc/doclet/testPrivateClasses/TestPrivateClasses.java index ea95afe0b02..3ff5a7fee4c 100644 --- a/langtools/test/jdk/javadoc/doclet/testPrivateClasses/TestPrivateClasses.java +++ b/langtools/test/jdk/javadoc/doclet/testPrivateClasses/TestPrivateClasses.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 4780441 4874845 4978816 8014017 8016328 8025633 8026567 + * @bug 4780441 4874845 4978816 8014017 8016328 8025633 8026567 8175200 * @summary Make sure that when the -private flag is not used, members * inherited from package private class are documented in the child. * @@ -74,7 +74,7 @@ public class TestPrivateClasses extends JavadocTester { + "\n" + "", // Method is documented as though it is declared in the inheriting method. - "
    public void methodInheritedFromParent(int p1)",
    +                "
    public void methodInheritedFromParent​(int p1)",
                     "
    \n" + "
    All Implemented Interfaces:
    \n" + "
    " @@ -96,12 +96,12 @@ public class TestPrivateClasses extends JavadocTester { // Should not document comments from private inherited interfaces "
    " + "" + - "methodInterface(int p1)\n" + + "methodInterface​(int p1)\n" + "
    Comment from interface.
    \n
    " + "" + - "methodInterface2(int p1)\n" + + "methodInterface2​(int p1)\n" + "
    Comment from interface.
    \n
    \n" + + "
    Test comment for a class which has an " + + "anchor_with_name and\n" + + " an anchor_with_id.
    \n" + + "
    " + "test1()", + + "\"../typeannos/RepeatingOnMethod.html#test1--\">test1​()", "(package private) @RepTypeUseA @RepTypeUseB java.lang.String" + "\n" + "test2" - + "()", + + "​()", "(package private) @RepTypeUseA @RepTypeUseB java.lang.String" + "\n" + "test3" - + "()", + + "​()", "(package private) @RepAllContextsA " + "@RepAllContextsB java.lang.String\n" + "test4()", + + "#test4--\">test4​()", "test5" - + "(java.lang.String parameter,\n java.lang.String " + "@RepTypeUseA @RepTypeUseA @RepMethodA\n@RepMethodB " - + "@RepMethodB\njava.lang.String test1()", + + "@RepMethodB\njava.lang.String test1​()", "" + "@RepTypeUseA @RepTypeUseA @RepTypeUseB @RepTypeUseB java.lang.String test2()", + + "title=\"annotation in typeannos\">@RepTypeUseB java.lang.String test2​()", "" + "@RepMethodA @RepTypeUseA " + "@RepTypeUseB @RepTypeUseB java.lang.String test3()", + + "\"annotation in typeannos\">@RepTypeUseB java.lang.String test3​()", "" + "@RepAllContextsA @RepAllContextsA " + "@RepAllContextsB @RepAllContextsB java.lang.String test4()", + + "title=\"annotation in typeannos\">@RepAllContextsB java.lang.String test4​()", - "java.lang.String test5(@RepTypeUseA " + "@RepTypeUseA (package private) <T> java.lang.String\n" + "genericMethod(T t)", + + "genericMethod-T-\">genericMethod​(T t)", "(package private) <T> java.lang.String\n" + "genericMethod2(genericMethod2​(@RepTypeUseA @RepTypeUseA @RepTypeUseB (package private) java.lang.String\n" + "test()", + + "test--\">test​()", - "java.lang.String test(@RepTypeUseA " + "@RepTypeUseA @RepMethodA\n@RepMethodB " - + "@RepMethodB\nvoid test()"); + + "@RepMethodB\nvoid test​()"); } } diff --git a/langtools/test/jdk/javadoc/doclet/testTypeAnnotations/typeannos/Receivers.java b/langtools/test/jdk/javadoc/doclet/testTypeAnnotations/typeannos/Receivers.java index a46dd39f7de..7bc3f5c5c4b 100644 --- a/langtools/test/jdk/javadoc/doclet/testTypeAnnotations/typeannos/Receivers.java +++ b/langtools/test/jdk/javadoc/doclet/testTypeAnnotations/typeannos/Receivers.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -53,11 +53,12 @@ class WithValue { } class WithFinal { - void plain(final @RcvrB("m") WithFinal this) { } - void generic(final @RcvrB("m") WithFinal this) { } - void withException(final @RcvrB("m") WithFinal this) throws Exception { } - String nonVoid(final @RcvrB("m") WithFinal this) { return null; } - void accept(final @RcvrB("m") WithFinal this, T r) throws Exception { } + WithFinal afield; + void plain(final @RcvrB("m") WithFinal afield) { } + void generic(final @RcvrB("m") WithFinal afield) { } + void withException(final @RcvrB("m") WithFinal afield) throws Exception { } + String nonVoid(final @RcvrB("m") WithFinal afield) { return null; } + void accept(final @RcvrB("m") WithFinal afield, T r) throws Exception { } } class WithBody { diff --git a/langtools/test/jdk/javadoc/doclet/testTypeVariableLinks/TestTypeVariableLinks.java b/langtools/test/jdk/javadoc/doclet/testTypeVariableLinks/TestTypeVariableLinks.java new file mode 100644 index 00000000000..9d1672fca26 --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testTypeVariableLinks/TestTypeVariableLinks.java @@ -0,0 +1,55 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/* + * @test + * @bug 8174805 + * @summary JavacTrees should use Types.skipTypeVars() to get the upper bound of type variables + * @library ../lib + * @modules jdk.javadoc/jdk.javadoc.internal.tool + * @build JavadocTester + * @run main TestTypeVariableLinks + */ + +public class TestTypeVariableLinks extends JavadocTester { + + public static void main(String... args) throws Exception { + TestTypeVariableLinks tester = new TestTypeVariableLinks(); + tester.runTests(); + } + + @Test + void test1() { + javadoc("-d", "out", "-sourcepath", testSrc, "-package", "pkg1"); + checkExit(Exit.OK); + + checkOutput("pkg1/C.html", true, + "
    Linking to Object.equals() Object.equals(Object)
    "); + checkOutput("pkg1/C.html", true, + "
    Linking to List.clear() List.clear()
    "); + checkOutput("pkg1/C.html", true, + "
    Linking to Additional.doAction() Additional.doAction()
    "); + checkOutput("pkg1/C.html", true, + "
    Linking to I.abstractAction() I.abstractAction()
    "); + } +} diff --git a/langtools/test/jdk/javadoc/doclet/testTypeVariableLinks/pkg1/C.java b/langtools/test/jdk/javadoc/doclet/testTypeVariableLinks/pkg1/C.java new file mode 100644 index 00000000000..5a16761de4e --- /dev/null +++ b/langtools/test/jdk/javadoc/doclet/testTypeVariableLinks/pkg1/C.java @@ -0,0 +1,53 @@ +/* + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package pkg1; + +import java.util.List; + +public class C, G extends Additional & I> { + /** + * Linking to Object.equals() {@link T#equals(Object)} + */ + public void m1() {} + /** + * Linking to List.clear() {@link F#clear()} + */ + public void m2() {} + /** + * Linking to Additional.doAction() {@link G#doAction()} + */ + public void m3() {} + /** + * Linking to I.abstractAction() {@link G#abstractAction()} + */ + public void m4() {} +} + +class Additional { + public void doAction() {} +} + +interface I { + void abstractAction(); +} diff --git a/langtools/test/jdk/javadoc/doclet/testUseOption/TestUseOption.java b/langtools/test/jdk/javadoc/doclet/testUseOption/TestUseOption.java index 409969beeb5..cc1e634c746 100644 --- a/langtools/test/jdk/javadoc/doclet/testUseOption/TestUseOption.java +++ b/langtools/test/jdk/javadoc/doclet/testUseOption/TestUseOption.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ /* * @test - * @bug 4496290 4985072 7006178 7068595 8016328 8050031 8048351 8081854 8071982 8162363 + * @bug 4496290 4985072 7006178 7068595 8016328 8050031 8048351 8081854 8071982 8162363 8175200 * @summary A simple test to ensure class-use files are correct. * @author jamieh * @library ../lib @@ -134,7 +134,7 @@ public class TestUseOption extends JavadocTester { "
    voidC1." + "methodInC1ThrowsThrowable" - + "()